summaryrefslogtreecommitdiff
path: root/hwdb.d/parse_hwdb.py
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2019-12-19 11:48:46 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2019-12-19 11:48:46 +0100
commit12c7d4d65e4fbc95b2f76853bdcf4fdc554d5c11 (patch)
tree9c1e9c15466c34c8cecad768416811e16ed8508d /hwdb.d/parse_hwdb.py
parent419a8a2dabb4184080d06f583f9539780ec10ec6 (diff)
downloadsystemd-12c7d4d65e4fbc95b2f76853bdcf4fdc554d5c11.tar.gz
hwdb: ignore keys added in kernel 5.5
python-evdev needs to be rebuilt with new kernel headers. Before that happens, our test would reject those keys as unknown.
Diffstat (limited to 'hwdb.d/parse_hwdb.py')
-rwxr-xr-xhwdb.d/parse_hwdb.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/hwdb.d/parse_hwdb.py b/hwdb.d/parse_hwdb.py
index 9a933b82b2..b5395b11fe 100755
--- a/hwdb.d/parse_hwdb.py
+++ b/hwdb.d/parse_hwdb.py
@@ -196,10 +196,11 @@ def check_one_mount_matrix(prop, value):
def check_one_keycode(prop, value):
if value != '!' and ecodes is not None:
key = 'KEY_' + value.upper()
- if key not in ecodes:
- key = value.upper()
- if key not in ecodes:
- error('Keycode {} unknown', key)
+ if not (key in ecodes or
+ value.upper() in ecodes or
+ # new keys added in kernel 5.5
+ 'KBD_LCD_MENU' in key):
+ error('Keycode {} unknown', key)
def check_properties(groups):
grammar = property_grammar()