aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorToby Slight <tslight@pm.me>2026-03-29 13:16:57 +0000
committerVladimir Kondratyev <wulf@FreeBSD.org>2026-03-29 13:16:57 +0000
commitbb8230f838c8d5f8d362a0dad4809908b44ae379 (patch)
tree4f13214a9b7a1a34d41fedb3d48fb2ea38e6b9ac /sys
parent103325323c7daf9fe6c9a6c71aa5c90974c9dff4 (diff)
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/hid/hkbd.c10
-rw-r--r--sys/dev/usb/input/ukbd.c10
2 files changed, 20 insertions, 0 deletions
diff --git a/sys/dev/hid/hkbd.c b/sys/dev/hid/hkbd.c
index 9ab02e940089..c98f4be69169 100644
--- a/sys/dev/hid/hkbd.c
+++ b/sys/dev/hid/hkbd.c
@@ -623,6 +623,16 @@ static uint32_t
hkbd_apple_fn(uint32_t keycode)
{
switch (keycode) {
+ case 0x0b: return 0x50; /* H -> LEFT ARROW */
+ case 0x0d: return 0x51; /* J -> DOWN ARROW */
+ case 0x0e: return 0x52; /* K -> UP ARROW */
+ case 0x0f: return 0x4f; /* L -> RIGHT ARROW */
+ case 0x36: return 0x4a; /* COMMA -> HOME */
+ case 0x37: return 0x4d; /* DOT -> END */
+ case 0x18: return 0x4b; /* U -> PGUP */
+ case 0x07: return 0x4e; /* D -> PGDN */
+ case 0x16: return 0x47; /* S -> SCROLLLOCK */
+ case 0x13: return 0x46; /* P -> SYSRQ/PRTSC */
case 0x28: return 0x49; /* RETURN -> INSERT */
case 0x2a: return 0x4c; /* BACKSPACE -> DEL */
case 0x50: return 0x4a; /* LEFT ARROW -> HOME */
diff --git a/sys/dev/usb/input/ukbd.c b/sys/dev/usb/input/ukbd.c
index 3ebdf1e9747d..37deb5c56fbd 100644
--- a/sys/dev/usb/input/ukbd.c
+++ b/sys/dev/usb/input/ukbd.c
@@ -677,6 +677,16 @@ static uint32_t
ukbd_apple_fn(uint32_t keycode)
{
switch (keycode) {
+ case 0x0b: return 0x50; /* H -> LEFT ARROW */
+ case 0x0d: return 0x51; /* J -> DOWN ARROW */
+ case 0x0e: return 0x52; /* K -> UP ARROW */
+ case 0x0f: return 0x4f; /* L -> RIGHT ARROW */
+ case 0x36: return 0x4a; /* COMMA -> HOME */
+ case 0x37: return 0x4d; /* DOT -> END */
+ case 0x18: return 0x4b; /* U -> PGUP */
+ case 0x07: return 0x4e; /* D -> PGDN */
+ case 0x16: return 0x47; /* S -> SCROLLLOCK */
+ case 0x13: return 0x46; /* P -> SYSRQ/PRTSC */
case 0x28: return 0x49; /* RETURN -> INSERT */
case 0x2a: return 0x4c; /* BACKSPACE -> DEL */
case 0x50: return 0x4a; /* LEFT ARROW -> HOME */