]> git.baikalelectronics.ru Git - kernel.git/commit
HID: intel-ish-hid: fix module device-id handling
authorArnd Bergmann <arnd@arndb.de>
Thu, 11 Nov 2021 08:56:33 +0000 (09:56 +0100)
committerJiri Kosina <jkosina@suse.cz>
Thu, 11 Nov 2021 21:45:40 +0000 (22:45 +0100)
commit94b46e6322fd3cdc06c307396ddaf503f8b115f5
tree6881766bd1e96d0d0bc47467b37bd7eda5f272f6
parent0fb3d997aa800324f0611257147e7bc57d9e5362
HID: intel-ish-hid: fix module device-id handling

A late addititon to the intel-ish-hid framework caused a build failure
with clang, and introduced an ABI to the module loader that stops working
if any driver ever needs to bind to more than one UUID:

drivers/hid/intel-ish-hid/ishtp-fw-loader.c:1067:4: error: initializer element is not a compile-time constant

Change the ishtp_device_id to have correct documentation and a driver_data
field like all the other ones, and change the drivers to use the ID table
as the primary identification in a way that works with all compilers
and avoids duplciating the identifiers.

Fixes: f5907df0442d ("platform/x86: isthp_eclite: only load for matching devices")
Fixes: 9de942550c4a ("platform/chrome: chros_ec_ishtp: only load for matching devices")
Fixes: 58c9c4096c2c ("HID: intel-ish-hid: hid-client: only load for matching devices")
Fixes: 560b267ea65c ("HID: intel-ish-hid: fw-loader: only load for matching devices")
Fixes: 08c5c58bf21c ("HID: intel-ish-hid: use constants for modaliases")
Fixes: a0f8c97dca41 ("HID: intel-ish-hid: add support for MODULE_DEVICE_TABLE()")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
[jkosina@suse.cz: fix ecl_ishtp_cl_driver.id initialization]
[jkosina@suse.cz: fix conflict with already fixed kerneldoc]
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/intel-ish-hid/ishtp-fw-loader.c
drivers/hid/intel-ish-hid/ishtp-hid-client.c
drivers/hid/intel-ish-hid/ishtp/bus.c
drivers/platform/chrome/cros_ec_ishtp.c
drivers/platform/x86/intel/ishtp_eclite.c
include/linux/intel-ish-client-if.h
include/linux/mod_devicetable.h