use "#ifdef __KERNEL" to avoid compile error in input.h
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 23 lines · Andrew Morton
Hi all,
In
linux/input.h, structinput_device_iduses typekernel_ulong_t,
which is defined inlinux/mod_devicetable.h, but which is only included when__KERNEL__is defined. So structinput_device_idshould also be exported only in kernel mode.Signed-off-by Luke Yang <[email protected]>include/linux/input.h +1
-0@@ -805,6 +805,7 @@ #define FF_AUTOCENTER 0x61#define FF_MAX 0x7f +#ifdef __KERNEL__ struct input_device_id { kernel_ulong_t flags;
include/linux/input.h struct input_device_id { · line 830
Quoted 7 lines
include/linux/input.h +1
-0@@ -823,6 +824,7 @@ struct input_device_id { kernel_ulong_t driver_info; }; +#endif /* * Structure for hotplug & device<->driver matching.
Ooops, there is problem with the patch. The script/mod/file2alias.c
need the struct input_device_id, and it defines the "kernel_ulong_t" by itself... Dmitry, any thought on how to solve the problem?
--
Best regards,
Luke Yang
[email protected]