MAGIC_SYSRQ problem: Do USB keyboards generate scancode 0x54

From: Chan Shih-Ping (cshihpin@dso.org.sg)
Date: Sat Mar 18 2000 - 10:22:45 EST


Hi all,

I have come across two USB keyboards that do not generate
the scancode 0x54 (== default SYSRQ_KEY) with Alt-PrtSc (SysRq).
These are a SGI USB keyboard and the Microsoft USB Natural keyboard.
Kind of makes it difficult to get MAGIC_SYSRQ to work.
The SGI keyboard is particularly weird as the key with (numbersign,
asciitilde) generates 0x54!

(Scancodes generated by Alt-PrtSc are the scancodes for Alt and PrtSc).

Is this typical of all USB keyboards??

I would like to propose that the SYSRQ_KEY be determined on the fly
by the sysrq_enabled kernel variable. (After all it is currently only
used as a on/off flag - by leveraging its actual variable one
can adapt to different weirdo keyboards without a kernel recompile.)

Scenario:

In a default setting:
        
        echo "84" > /proc/sys/kernel/sysrq
        # 84 = keycode of SysRq
With a USB keyboard without scancode 0x54, switch SYSRQ_KEY to PrtSc

        echo "99" > /proc/sys/kernel/sysrq
        # 99 = keycode of PrtSc

Comments? If this is a viable idea I will submit a patch.

Chan Shih-Ping (Richard) <cshihpin@dso.org.sg>
DSO National Laboratories
20 Science Park Drive
Singapore 118230
Key fingerprint = EA3D 4BCB CF7B 8B41 A42D FAB5 3098 C5A6 0DBE 78F2

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Thu Mar 23 2000 - 21:00:24 EST