From: Michael Brown Date: Wed, 9 Feb 2022 21:54:47 +0000 (+0000) Subject: [usb] Support keyboard remapping via the native USB keyboard driver X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=468980db2b99f54ffec7d2a44c281308b4eec3c0;p=thirdparty%2Fipxe.git [usb] Support keyboard remapping via the native USB keyboard driver Signed-off-by: Michael Brown --- diff --git a/src/drivers/usb/usbkbd.c b/src/drivers/usb/usbkbd.c index a8ab6ab76..397ed77ec 100644 --- a/src/drivers/usb/usbkbd.c +++ b/src/drivers/usb/usbkbd.c @@ -29,6 +29,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL ); #include #include #include +#include #include #include "usbkbd.h" @@ -122,6 +123,10 @@ static unsigned int usbkbd_map ( unsigned int keycode, unsigned int modifiers, key = 0; } + /* Remap key if applicable */ + if ( keycode < USBKBD_KEY_CAPS_LOCK ) + key = key_remap ( key ); + return key; }