| 5d4c6c13 | 13-Mar-2026 |
Benjamin Tissoires <bentiss@kernel.org> |
selftests/hid: fix compilation when bpf_wq and hid_device are not exported
This can happen in situations when CONFIG_HID_SUPPORT is set to no, or some complex situations where struct bpf_wq is not e
selftests/hid: fix compilation when bpf_wq and hid_device are not exported
This can happen in situations when CONFIG_HID_SUPPORT is set to no, or some complex situations where struct bpf_wq is not exported.
So do the usual dance of hiding them before including vmlinux.h, and then redefining them and make use of CO-RE to have the correct offsets.
Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202603111558.KLCIxsZB-lkp@intel.com/ Fixes: fe8d561db3e8 ("selftests/hid: add wq test for hid_bpf_input_report()") Cc: stable@vger.kernel.org Acked-by: Jiri Kosina <jkosina@suse.com> Reviewed-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
show more ...
|
| f287ba59 | 22-Dec-2025 |
Peter Hutterer <peter.hutterer@who-t.net> |
selftests/hid: add a test for the Digitizer/Button Type pressurepad
We have to resort to a bit of a hack: python-libevdev gets the properties from libevdev at module init time. If libevdev hasn't be
selftests/hid: add a test for the Digitizer/Button Type pressurepad
We have to resort to a bit of a hack: python-libevdev gets the properties from libevdev at module init time. If libevdev hasn't been rebuilt with the new property it won't be automatically populated. So we hack around this by constructing the property manually.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
show more ...
|
| 4f36fdab | 22-Dec-2025 |
Peter Hutterer <peter.hutterer@who-t.net> |
selftests/hid: use a enum class for the different button types
Instead of multiple spellings of a string-provided argument, let's make this a tad more type-safe and use an enum here.
And while we d
selftests/hid: use a enum class for the different button types
Instead of multiple spellings of a string-provided argument, let's make this a tad more type-safe and use an enum here.
And while we do this fix the two wrong devices: - elan_04f3_313a (HP ZBook Fury 15) is discrete button pad - dell_044e_1220 (Dell Precision 7740) is a discrete button pad
Equivalent hid-tools commit https://gitlab.freedesktop.org/libevdev/hid-tools/-/commit/8300a55bf4213c6a252cab8cb5b34c9ddb191625
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
show more ...
|
| 1d6628f7 | 22-Dec-2025 |
Peter Hutterer <peter.hutterer@who-t.net> |
selftests/hid: require hidtools 0.12
Not all our tests really require it but since it's likely pip-installed anyway it's trivial to require the new version, just in case we want to start cleaning up
selftests/hid: require hidtools 0.12
Not all our tests really require it but since it's likely pip-installed anyway it's trivial to require the new version, just in case we want to start cleaning up other bits.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
show more ...
|
| 8c62074f | 12-Sep-2025 |
Benjamin Tissoires <bentiss@kernel.org> |
selftests/hid: hidraw: forge wrong ioctls and tests them
We also need coverage for when the malicious user is not using the proper ioctls definitions and tries to work around the driver.
Most of th
selftests/hid: hidraw: forge wrong ioctls and tests them
We also need coverage for when the malicious user is not using the proper ioctls definitions and tries to work around the driver.
Most of the scaffholding has been generated by claude-4-sonnet and then carefully reviewed.
Suggested-by: Arnd Bergmann <arnd@kernel.org> Signed-off-by: Benjamin Tissoires <bentiss@kernel.org> Signed-off-by: Jiri Kosina <jkosina@suse.com>
show more ...
|
| 1aee3a44 | 09-Jul-2025 |
Benjamin Tissoires <bentiss@kernel.org> |
selftests/hid: sync python tests to hid-tools 0.10
hid-tools 0.10 fixes one inconvenience introduced by commit 6a9e76f75c1a ("HID: multitouch: Disable touchpad on firmware level while not in use")
selftests/hid: sync python tests to hid-tools 0.10
hid-tools 0.10 fixes one inconvenience introduced by commit 6a9e76f75c1a ("HID: multitouch: Disable touchpad on firmware level while not in use")
This change added a new callback when a hid-nultitouch device is opened or closed to put the underlying device into a given operating mode. However, in the test cases, that means that while the single threaded test is run, it opens the device but has to react to the device while the open() is still running. hid-tools now implements a minimal thread to circumvent this.
This makes the HID kernel tests in sync with hid-tools 0.10.
This has the net effect of running the full HID python testsuite in 6 minutes instead of 1 hour.
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Link: https://patch.msgid.link/20250709-wip-fix-ci-v1-3-b7df4c271cf8@kernel.org Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
show more ...
|
| 642f9b2d | 09-Jul-2025 |
Benjamin Tissoires <bentiss@kernel.org> |
selftests/hid: sync the python tests to hid-tools 0.8
Instead of backporting one by one each commits, let's pull them in bulk and refer to the hid-tools project for a detailed history.
The short su
selftests/hid: sync the python tests to hid-tools 0.8
Instead of backporting one by one each commits, let's pull them in bulk and refer to the hid-tools project for a detailed history.
The short summary is: - make use of dataclass when possible, to avoid tuples - wacom: remove unused uhdev parameter - various small fixes not worth mentioning
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Link: https://patch.msgid.link/20250709-wip-fix-ci-v1-2-b7df4c271cf8@kernel.org Signed-off-by: Benjamin Tissoires <bentiss@kernel.org>
show more ...
|