diff --git a/0001-Map-some-specific-high-keycodes-into-the-FK20-23-ran.patch b/0001-Map-some-specific-high-keycodes-into-the-FK20-23-ran.patch new file mode 100644 index 0000000000000000000000000000000000000000..e2eb6246b787e6cf467753b2690f3aa3fb92dca9 --- /dev/null +++ b/0001-Map-some-specific-high-keycodes-into-the-FK20-23-ran.patch @@ -0,0 +1,44 @@ +From f8b62da441571afd5003fd66167bf03798f19ed6 Mon Sep 17 00:00:00 2001 +From: Peter Hutterer +Date: Wed, 9 Oct 2024 14:03:41 +1000 +Subject: [PATCH xf86-input-libinput] Map some specific high keycodes into the + FK20-23 range + +These mappings have been part of xkeyboard-config for over a decade and +the likely reason they were introduced is that the corresponding evdev +keycode is > 255. + +Let's forcibly remap those in the driver here so the rest of the system +can switch to the real keycodes instead of having to map them to the +whatever X expects. + +See https://github.com/systemd/systemd/pull/34325/ + +Part-of: +(cherry picked from commit cb80d7f82d35f8068e06d45860ed958a948e15bf) +--- + src/xf86libinput.c | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/src/xf86libinput.c b/src/xf86libinput.c +index 7aebacf7501e..97b08213951c 100644 +--- a/src/xf86libinput.c ++++ b/src/xf86libinput.c +@@ -1522,6 +1522,14 @@ xf86libinput_handle_key(InputInfoPtr pInfo, struct libinput_event_keyboard *even + if ((driver_data->capabilities & CAP_KEYBOARD) == 0) + return; + ++ /* keycodes > 256 that have a historical mapping in xkeyboard-config */ ++ switch (key) { ++ case KEY_TOUCHPAD_TOGGLE: key = KEY_F21; break; ++ case KEY_TOUCHPAD_ON: key = KEY_F22; break; ++ case KEY_TOUCHPAD_OFF: key = KEY_F23; break; ++ case KEY_MICMUTE: key = KEY_F20; break; ++ } ++ + key += XORG_KEYCODE_OFFSET; + + is_press = (libinput_event_keyboard_get_key_state(event) == LIBINPUT_KEY_STATE_PRESSED); +-- +2.49.0 + diff --git a/dist b/dist new file mode 100644 index 0000000000000000000000000000000000000000..1f9f8c9bbdfdaf483d0bfdf0bf3c48d3cad6b1b9 --- /dev/null +++ b/dist @@ -0,0 +1 @@ +an9_6 diff --git a/download b/download new file mode 100644 index 0000000000000000000000000000000000000000..fe49a2b26788349e1235bcb3f1b50aeecb1d4c5f --- /dev/null +++ b/download @@ -0,0 +1 @@ +cc30d31f0ffd2653dd727aedd4372984 xf86-input-libinput-1.0.1.tar.bz2 diff --git a/xf86-input-libinput-1.0.1.tar.bz2 b/xf86-input-libinput-1.0.1.tar.bz2 deleted file mode 100644 index 20e534096dbc9d3311f161aa71bb63d948f9419b..0000000000000000000000000000000000000000 Binary files a/xf86-input-libinput-1.0.1.tar.bz2 and /dev/null differ diff --git a/xorg-x11-drv-libinput.spec b/xorg-x11-drv-libinput.spec index faabbab05e171c309b847e5fdd56a442eb24c25a..abdcc5f6f60d81a239058451220a408b36b494c8 100644 --- a/xorg-x11-drv-libinput.spec +++ b/xorg-x11-drv-libinput.spec @@ -8,7 +8,7 @@ Summary: Xorg X11 libinput input driver Name: xorg-x11-drv-libinput Version: 1.0.1 -Release: 3%{?gitdate:.%{gitdate}git%{gitversion}}%{?dist} +Release: 4%{?gitdate:.%{gitdate}git%{gitversion}}%{?dist} URL: http://www.x.org License: MIT @@ -22,6 +22,7 @@ Source1: 71-libinput-overrides-wacom.conf # Fedora-only hack for hidpi screens # https://bugzilla.redhat.com/show_bug.cgi?id=1413306 Patch01: 0001-Add-a-DPIScaleFactor-option-as-temporary-solution-to.patch +Patch02: 0001-Map-some-specific-high-keycodes-into-the-FK20-23-ran.patch BuildRequires: make BuildRequires: autoconf automake libtool @@ -78,6 +79,9 @@ Xorg X11 libinput input driver development files. %{_includedir}/xorg/libinput-properties.h %changelog +* Fri Mar 21 2025 Peter Hutterer - 1.0.1-4 +- Map some high keycodes into the FK20-FK23 range (RHEL-84833) + * Tue Aug 10 2021 Mohan Boddu - 1.0.1-3 - Rebuilt for IMA sigs, glibc 2.34, aarch64 flags Related: rhbz#1991688