1
0
Fork 0
alistair23-linux/drivers/usb/common
Yoshihiro Shimoda fa82796609 usb: Change usb_of_get_companion_dev() place to usb/common
Since renesas_usb3 udc driver calls usb_of_get_companion_dev()
which is on usb/core/of.c, build error like below happens if we
disable CONFIG_USB because the usb/core/ needs CONFIG_USB:

ERROR: "usb_of_get_companion_dev" [drivers/usb/gadget/udc/renesas_usb3.ko] undefined!

According to the usb/gadget/Kconfig, "NOTE:  Gadget support
** DOES NOT ** depend on host-side CONFIG_USB !!".
So, to fix the issue, this patch changes the usb_of_get_companion_dev()
place from usb/core/of.c to usb/common/common.c to be called by both
host and gadget.

Reported-by: John Garry <john.garry@huawei.com>
Fixes: 39facfa01c ("usb: gadget: udc: renesas_usb3: Add register of usb role switch")
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-09-10 20:40:29 +02:00
..
Makefile usb: common: Small class for USB role switches 2018-03-22 13:40:10 +01:00
common.c usb: Change usb_of_get_companion_dev() place to usb/common 2018-09-10 20:40:29 +02:00
led.c USB: common: Remove redundant license text 2017-11-04 11:55:39 +01:00
roles.c usb: common: Small class for USB role switches 2018-03-22 13:40:10 +01:00
ulpi.c USB: ulpi: fix bus-node lookup 2017-11-28 15:17:48 +01:00
usb-otg-fsm.c USB: common: Remove redundant license text 2017-11-04 11:55:39 +01:00