From: Michal Suchanek Date: Thu, 15 Jun 2017 10:50:05 +0000 (+0200) Subject: hwdb: weed out key defines which do not designate events X-Git-Tag: v234~74^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F6099%2Fhead;p=thirdparty%2Fsystemd.git hwdb: weed out key defines which do not designate events The defines KEY_MAX KEY_CNT KEY_MIN_INTERESTING BTN_MISC BTN_MOUSE BTN_JOYSTICK BTN_GAMEPAD BTN_DIGI BTN_WHEEL BTN_TRIGGER_HAPPY mark start/end of key blocks and do not designate events. Exclude them from the list of recognized key events. --- diff --git a/src/udev/generate-keyboard-keys-list.sh b/src/udev/generate-keyboard-keys-list.sh index 83bf4a97d22..7a74e0dae1e 100755 --- a/src/udev/generate-keyboard-keys-list.sh +++ b/src/udev/generate-keyboard-keys-list.sh @@ -1,4 +1,6 @@ #!/bin/sh -eu -$1 -dM -include linux/input.h - / { next } + /^#define[ \t]+(KEY|BTN)_[^ ]+[ \t]+[0-9BK]/ { print $2 } +'