From 0131162439508801b9f8a330fa731f04273c9337 Mon Sep 17 00:00:00 2001 From: Jean-Jacques Hiblot Date: Thu, 29 Nov 2018 10:52:46 +0100 Subject: dm: usb: create a new UCLASS ID for USB gadget devices UCLASS_USB_DEV_GENERIC was meant for USB devices connected to host controllers, not gadget devices. Adding a new UCLASS for gadget devices alone. Also move the generic DM code for USB gadgets in a separate file for clarity. Signed-off-by: Jean-Jacques Hiblot --- drivers/usb/gadget/ether.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/usb/gadget/ether.c') diff --git a/drivers/usb/gadget/ether.c b/drivers/usb/gadget/ether.c index 5a9ffd7120..3b3d9af681 100644 --- a/drivers/usb/gadget/ether.c +++ b/drivers/usb/gadget/ether.c @@ -2671,7 +2671,7 @@ int usb_ether_init(void) struct udevice *usb_dev; int ret; - ret = uclass_first_device(UCLASS_USB_DEV_GENERIC, &usb_dev); + ret = uclass_first_device(UCLASS_USB_GADGET_GENERIC, &usb_dev); if (!usb_dev || ret) { pr_err("No USB device found\n"); return ret; -- cgit