mirror of
https://github.com/u-boot/u-boot.git
synced 2025-05-09 03:21:51 +00:00
dm: usb: eth: Support driver model with USB Ethernet
At present USB Ethernet does not work with CONFIG_DM_ETH. Add driver model support to this feature, so that it can work alongside other Ethernet devices with driver model. It was found that quite a bit of code is common in most of the USB Ethernet drivers. Add this code to the common layer to reduce the amount of duplicate code needed in USB Ethernet drivers when CONFIG_DM_ETH is used. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
This commit is contained in:
parent
a1ca92eaaf
commit
c8c2797c38
3 changed files with 206 additions and 12 deletions
|
@ -22,7 +22,7 @@
|
|||
#ifdef CONFIG_USB_STORAGE
|
||||
static int usb_stor_curr_dev = -1; /* current device */
|
||||
#endif
|
||||
#ifdef CONFIG_USB_HOST_ETHER
|
||||
#if defined(CONFIG_USB_HOST_ETHER) && !defined(CONFIG_DM_ETH)
|
||||
static int __maybe_unused usb_ether_curr_dev = -1; /* current ethernet device */
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue