mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 03:15:31 +09:00
ANDROID: usb: gadget: Fix dependency for f_accessory
The Android Accessory USB gadget functions use core HID functions. As
such, compiling with CONFIG_HID=m and CONFIG_USB_GADGET=y fails to link:
drivers/usb/gadget/function/f_accessory.o: In function `acc_complete_send_hid_event':
f_accessory.c:(.text+0xd54): undefined reference to `hid_report_raw_event'
drivers/usb/gadget/function/f_accessory.o: In function `acc_hid_work':
f_accessory.c:(.text+0x2a98): undefined reference to `hid_destroy_device'
f_accessory.c:(.text+0x2ad4): undefined reference to `hid_allocate_device'
f_accessory.c:(.text+0x2b64): undefined reference to `hid_add_device'
f_accessory.c:(.text+0x2d04): undefined reference to `hid_destroy_device'
drivers/usb/gadget/function/f_accessory.o: In function `acc_hid_parse':
f_accessory.c:(.text+0x2e24): undefined reference to `hid_parse_report'
drivers/usb/gadget/function/f_accessory.o: In function `acc_function_bind_configfs':
f_accessory.c:(.text+0x2f8c): undefined reference to `__hid_register_driver'
drivers/usb/gadget/function/f_accessory.o: In function `acc_function_unbind':
f_accessory.c:(.text+0x3bc8): undefined reference to `hid_unregister_driver'
drivers/usb/gadget/function/f_accessory.o: In function `acc_hid_probe':
f_accessory.c:(.text+0x3ef4): undefined reference to `hid_open_report'
f_accessory.c:(.text+0x3f18): undefined reference to `hid_hw_start'
Fix this by making the dependency on HID explicit.
Bug: 140224784
Fixes: c7b552df87 ("ANDROID: usb: gadget: f_accessory: Add Android
Accessory function")
Signed-off-by: Quentin Perret <qperret@google.com>
Change-Id: Ibd8640d7766cc7802d8275bfe3adfa007f3318fe
This commit is contained in:
@@ -385,6 +385,7 @@ config USB_CONFIGFS_F_FS
|
||||
config USB_CONFIGFS_F_ACC
|
||||
bool "Accessory gadget"
|
||||
depends on USB_CONFIGFS
|
||||
depends on HID=y
|
||||
select USB_F_ACC
|
||||
help
|
||||
USB gadget Accessory support
|
||||
|
||||
Reference in New Issue
Block a user