]> git.ipfire.org Git - thirdparty/ipxe.git/commitdiff
[build] Use dynamic keyboard map by default in UEFI builds 1745/head
authorMichael Brown <mcb30@ipxe.org>
Tue, 30 Jun 2026 09:38:37 +0000 (10:38 +0100)
committerMichael Brown <mcb30@ipxe.org>
Tue, 30 Jun 2026 09:47:19 +0000 (10:47 +0100)
As described in commit 05cb930 ("[build] Extend default configuration
for non-BIOS builds"), the default configuration for EFI needs to
allow for the unfortunate fact that users will not be able to rebuild
the Secure Boot binaries for themselves.

The keyboard map currently defaults to "us" (i.e. no keyboard
remapping) on all platforms.  Switch to using the "dynamic" keyboard
map by default for EFI platforms.

Do not use the "dynamic" keyboard map by default on Linux platforms
(where the input character read by iPXE has already passed through the
host's keyboard mapping) or on RISC-V SBI (where input is expected to
come via a serial port rather than a directly attached keyboard).

Requested-by: Simon Fonteneau <blog@lesfourmisduweb.org>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/config/console.h

index 9ba1bb6d78bc5e9e654d2ecbcfba524ff959ab86..60d7aa838e75d43611e0f3174d7b991ce9ff027d 100644 (file)
@@ -83,6 +83,12 @@ FILE_SECBOOT ( PERMITTED );
 #define KEYBOARD_MAP   us      /* Default US keyboard map */
 //#define KEYBOARD_MAP dynamic /* Runtime selectable keyboard map */
 
+/* Use dynamic keyboard by default on EFI platforms */
+#if defined ( PLATFORM_efi )
+  #undef KEYBOARD_MAP
+  #define KEYBOARD_MAP dynamic
+#endif
+
 /*****************************************************************************
  *
  * Log levels