kdb: remove redundant check for scancode 0xe0
Subsystems (2)
PATCH 1/1 kdb: remove redundant check for scancode 0xe0
The check for scancode 0xe0 is always false because earlier on the scan code is masked with 0x7f so there are never going to be values greater than 0x7f. Remove the redundant check.
--- kernel/debug/kdb/kdb_keyboard.c | 3 --- 1 file changed, 3 deletions(-)
kernel/debug/kdb/kdb_keyboard.c +0 -3
@@ -145,9 +145,6 @@ int kdb_get_kbd_char(void)return CTRL ('F' ); } -if (scancode ==0xe0 ) -return -1 ; -/* * For Japanese 86/106 keyboards * See comment in drivers/char/pc_keyb.c.
Signature · 1 line
2.49.0
Hi,
Quoted 15 lines · Colin Ian King
The check for scancode
0xe0is always false because earlier on the scan code is masked with0x7fso there are never going to be values greater than0x7f. Remove the redundant check.Signed-off-by Colin Ian King <[email protected]>--- kernel/debug/kdb/kdb_keyboard.c | 3 --- 1 file changed, 3 deletions(-)kernel/debug/kdb/kdb_keyboard.c +0
-0
kernel/debug/kdb/kdb_keyboard.c int kdb_get_kbd_char(void) · line 150
Quoted 6 lines
kernel/debug/kdb/kdb_keyboard.c +0
-3@@ -145,9 +145,6 @@ int kdb_get_kbd_char(void)return CTRL ('F' ); } -if (scancode ==0xe0 ) -return -1 ; -
What a glorious bit of undocumented code. I agree that this is dead code and should be safe to remove.
Quoted 5 lines · Colin Ian King
The check for scancode
0xe0is always false because earlier on the scan code is masked with0x7fso there are never going to be values greater than0x7f. Remove the redundant check.
Applied, thanks!
[1/1] kdb: remove redundant check for scancode 0xe0
commit: fdbdd0ccb30af18d3b29e714ac8d5ab6163279e0
Best regards,
Signature · 1 line
Daniel Thompson (RISCstar) <[email protected]>