From e069d4d1111e28cd893665474e1dbf2efb43dc82 Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Fri, 12 May 2017 15:01:33 +0200 Subject: [PATCH] Add evdev mappings for KEY_SOUND, KEY_UWB, KEY_WWAN and KEY_RFKILL --- ...gs-for-KEY_SOUND-KEY_UWB-KEY_WWAN-an.patch | 73 +++++++++++++++++++ xkeyboard-config.spec | 8 +- 2 files changed, 80 insertions(+), 1 deletion(-) create mode 100644 0001-Add-evdev-mappings-for-KEY_SOUND-KEY_UWB-KEY_WWAN-an.patch diff --git a/0001-Add-evdev-mappings-for-KEY_SOUND-KEY_UWB-KEY_WWAN-an.patch b/0001-Add-evdev-mappings-for-KEY_SOUND-KEY_UWB-KEY_WWAN-an.patch new file mode 100644 index 0000000..8d0e7d8 --- /dev/null +++ b/0001-Add-evdev-mappings-for-KEY_SOUND-KEY_UWB-KEY_WWAN-an.patch @@ -0,0 +1,73 @@ +From dbaf3d9ce3bf3ccdfaff44a5f340b9980bd5052e Mon Sep 17 00:00:00 2001 +From: Hans de Goede +Date: Fri, 12 May 2017 14:37:55 +0200 +Subject: [PATCH xkeyboard-config] Add evdev mappings for KEY_SOUND, KEY_UWB, + KEY_WWAN and KEY_RFKILL + +KEY_SOUND, KEY_WWAN and KEY_RFKILL are used on actual devices and +current xproto master defines keysyms for these. Add mappings for +these keys. + +The XF86UWB keysm exists for quite a while now, as does the KEY_SOUND +evdev code for it, so lets adds a mapping for that too. + +Note that this replaces the I255 to XF86Hibernate mapping in +xkb_symbols "evdev", I don't know where that came from, but it is +wrong, I255 was until now not defined in keycodes/evdev and +KEY_HIBERNATE is not defined in linux/input-event-codes.h . + +BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=100970 +Cc: Bastien Nocera +Cc: Benjamin Berg +Signed-off-by: Hans de Goede +--- + keycodes/evdev | 2 ++ + symbols/inet | 7 ++++--- + 2 files changed, 6 insertions(+), 3 deletions(-) + +diff --git a/keycodes/evdev b/keycodes/evdev +index 624ac68..51a6e26 100644 +--- a/keycodes/evdev ++++ b/keycodes/evdev +@@ -281,6 +281,8 @@ default xkb_keycodes "evdev" { + = 251; // #define KEY_BRIGHTNESS_CYCLE 243 + = 252; // #define KEY_BRIGHTNESS_ZERO 244 + = 253; // #define KEY_DISPLAY_OFF 245 ++ = 254; // #define KEY_WWAN 246 ++ = 255; // #define KEY_RFKILL 247 + + // Fake keycodes for virtual keys + = 92; +diff --git a/symbols/inet b/symbols/inet +index 5403e77..1e06aa9 100644 +--- a/symbols/inet ++++ b/symbols/inet +@@ -184,7 +184,7 @@ xkb_symbols "evdev" { + key { [ Print ] }; + // key { [ ] }; // KEY_HP + key { [ XF86WebCam ] }; +-// key { [ ] }; // KEY_SOUND ++ key { [ XF86AudioPreset ] }; + // key { [ ] }; // KEY_QUESTION + key { [ XF86Mail ] }; + key { [ XF86Messenger ] }; // KEY_CHAT +@@ -210,13 +210,14 @@ xkb_symbols "evdev" { + key { [ XF86Battery ] }; + key { [ XF86Bluetooth ] }; + key { [ XF86WLAN ] }; ++ key { [ XF86UWB ] }; + // key { [ ] }; // KEY_VIDEO_NEXT -- drive next video source + // key { [ ] }; // KEY_VIDEO_PREV -- drive previous video source + // key { [ ] }; // KEY_BRIGHTNESS_CYCLE -- bright up, max++ == min + // key { [ ] }; // KEY_BRIGHTNESS_ZERO -- brightness off + // key { [ ] }; // KEY_DISPLAY_OFF -- turn off display +-// key { [ ] }; // KEY_WIMAX +- key { [ XF86Hibernate ] }; // KEY_HIBERNATE ++ key { [ XF86WWAN ] }; // KEY_WWAN ++ key { [ XF86RFKill ] }; // KEY_RFKILL + + key { [ XF86Tools ] }; + key { [ XF86Launch5 ] }; +-- +2.12.2 + diff --git a/xkeyboard-config.spec b/xkeyboard-config.spec index d0c3617..216f8f3 100644 --- a/xkeyboard-config.spec +++ b/xkeyboard-config.spec @@ -7,7 +7,7 @@ Summary: X Keyboard Extension configuration data Name: xkeyboard-config Version: 2.20 -Release: 3%{?gitdate:.%{gitdate}git%{gitversion}}%{?dist} +Release: 4%{?gitdate:.%{gitdate}git%{gitversion}}%{?dist} License: MIT URL: http://www.freedesktop.org/wiki/Software/XKeyboardConfig @@ -19,6 +19,9 @@ Source2: commitid Source0: http://xorg.freedesktop.org/archive/individual/data/%{name}/%{name}-%{version}.tar.bz2 %endif +# Submitted upstream +Patch1: 0001-Add-evdev-mappings-for-KEY_SOUND-KEY_UWB-KEY_WWAN-an.patch + BuildArch: noarch BuildRequires: gettext @@ -108,6 +111,9 @@ rm -f $RPM_BUILD_ROOT%{_datadir}/X11/xkb/compiled %{_datadir}/pkgconfig/xkeyboard-config.pc %changelog +* Fri May 12 2017 Hans de Goede - 2.20-4 +- Add evdev mappings for KEY_SOUND, KEY_UWB, KEY_WWAN and KEY_RFKILL + * Sat Feb 11 2017 Fedora Release Engineering - 2.20-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild