diff options
author | Chunfeng Yun <chunfeng.yun@mediatek.com> | 2020-10-14 15:08:30 +0800 |
---|---|---|
committer | Marek Vasut <marex@denx.de> | 2020-10-20 00:49:05 +0200 |
commit | 252bd2e3caeab1c8f446d4a2116f5af6af89b87c (patch) | |
tree | f4e244d17be266c73741e0235f9983d5452e450e /drivers | |
parent | e09b88cd083d8066b530676c8eb72ef1949e7d5e (diff) | |
download | u-boot-252bd2e3caeab1c8f446d4a2116f5af6af89b87c.zip u-boot-252bd2e3caeab1c8f446d4a2116f5af6af89b87c.tar.gz u-boot-252bd2e3caeab1c8f446d4a2116f5af6af89b87c.tar.bz2 |
usb: gadget: Add bcdDevice for the MTU3 USB Gadget Controller
Add an entry in usb_gadget_controller_number() for the MTU3
gadget controller. It is used to bind the USB Ethernet driver.
Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/usb/gadget/gadget_chips.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/usb/gadget/gadget_chips.h b/drivers/usb/gadget/gadget_chips.h index 587204c..0cdf47c 100644 --- a/drivers/usb/gadget/gadget_chips.h +++ b/drivers/usb/gadget/gadget_chips.h @@ -161,6 +161,12 @@ #define gadget_is_max3420(g) 0 #endif +#ifdef CONFIG_USB_MTU3_GADGET +#define gadget_is_mtu3(g) (!strcmp("mtu3-gadget", (g)->name)) +#else +#define gadget_is_mtu3(g) 0 +#endif + /** * usb_gadget_controller_number - support bcdDevice id convention * @gadget: the controller being driven @@ -224,5 +230,7 @@ static inline int usb_gadget_controller_number(struct usb_gadget *gadget) return 0x24; else if (gadget_is_max3420(gadget)) return 0x25; + else if (gadget_is_mtu3(gadget)) + return 0x26; return -ENOENT; } |