Thomas Weißschuh df8b030d82 HID: core: remove #ifdef CONFIG_PM from hid_driver
Allow HID drivers to pass ->suspend, ->resume and ->reset_resume via
pm_ptr().
Through the usage of pm_ptr() the CONFIG_PM-dependent code will always be
compiled, protecting against bitrot.
The linker will then garbage-collect the unused function avoiding any overhead.

The only overhead in the final kernel image and at runtime are a few
extra bytes in 'struct hid_driver'.

The same approach is chosen by 'struct usb_driver' and other subsystems.

Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Link: https://lore.kernel.org/r/20231012-hid-pm_ptr-v1-1-0a71531ca93b@weissschuh.net
Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
2023-10-25 18:33:42 +02:00
..
2023-10-10 11:01:21 -07:00
2023-09-01 16:54:25 -07:00
2023-09-01 12:21:32 -07:00
2023-09-29 13:38:34 -07:00
2023-09-01 16:54:25 -07:00
2023-09-19 07:04:49 +02:00
2023-10-06 12:48:06 +10:00
2023-09-02 08:25:19 +01:00