[patch] Add keymap remapping to HAL

David Zeuthen david at fubar.dk
Thu Jun 7 14:35:24 PDT 2007


On Thu, 2007-06-07 at 21:28 +0100, Richard Hughes wrote:
> In my initial testing I was using scancodes less that 127, and thus didn't
> pick up on this problem. The conversion code is the same as used in setkeycodes.
> 
> Comments? Okay to commit?

I'm a bit baffled why you put in e017 in the first place; that's what
you got out of dmesg?

> With the attached patch the keys work, and I get:
> 
> hal-setup-keymap: parsed e016:wlan to (e016, 238)
> hal-setup-keymap: parsed e017:sleep to (e017, 142)
> hal-setup-keymap: parsed e018:suspend to (e018, 205)

Should probably read something like

 hal-setup-keymap: parsed e018:suspend to (98, 205)

then. Also, suggest to prefix the debug output with 0x so it's evident
we're talking about hexadecimal, e.g. it would be

 hal-setup-keymap: parsed e018:suspend to (0x98, 0x205)

An alternative to the whole remapping thing is just to do the remapping
in hand, e.g. instead of having 

 <append key="input.keymap.data" type="strlist">e018:suspend</append> <!-- Fn+F12 hibernate -->

you'd have

 <append key="input.keymap.data" type="strlist">98:suspend</append> <!-- Fn+F12 hibernate -->

but I bet that defeats the purpose of making it easy for users to
generate these fdi files themselves. Which is a pretty important feature
I'd say - so I'm fine with doing the remapping in the tool; OK to commit
if you also apply the changes to the debug output I rambled about above.
Thanks.

     David




More information about the hal mailing list