Re: [PATCH] usb: gadget: langwell_udc: Fix error path

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.

Rahul Ruikar wrote:

Fix for following cases
- Call device_unregister() only when device_register() is success.

   s/is success/succeeds/

- Call put_device() when device_register() fails.
- Call device_remove_file() only when device_create_file() is success.

   s/is success/succeeds/

Signed-off-by: Rahul Ruikar <rahul.ruikar@xxxxxxxxx>

[...]

diff --git a/drivers/usb/gadget/langwell_udc.h b/drivers/usb/gadget/langwell_udc.h
index 9719934..b212a70 100644
--- a/drivers/usb/gadget/langwell_udc.h
+++ b/drivers/usb/gadget/langwell_udc.h
@@ -199,7 +199,9 @@ struct langwell_udc {
 				vbus_active:1,
 				suspended:1,
 				stopped:1,
-				lpm:1;	/* LPM capability */
+				lpm:1,	/* LPM capability */
+				reg_status:1,
+				file_create:1;

   I'd rather have called this 'file_created'.

/* pci state used to access those endpoints */
 	struct pci_dev		*pdev;

WBR, Sergei
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux