Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[PATCH] Fix braille keyboard keysym generation

1 view
Skip to first unread message

Samuel Thibault

unread,
Nov 17, 2009, 9:00:02 AM11/17/09
to
Keysyms stored in key_map[] are not simply K() values, but U(K())
values, as can be seen in the KDSKBENT ioctl handler. The
kernel-generated braille keysyms thus need a U() call too.

Signed-off-by: Samuel Thibault <samuel....@ens-lyon.org>

diff --git a/drivers/char/keyboard.c b/drivers/char/keyboard.c
index 737be95..82c493e 100644
--- a/drivers/char/keyboard.c
+++ b/drivers/char/keyboard.c
@@ -1249,7 +1249,7 @@ static void kbd_keycode(unsigned int keycode, int down, int hw_raw)

if (keycode >= NR_KEYS)
if (keycode >= KEY_BRL_DOT1 && keycode <= KEY_BRL_DOT8)
- keysym = K(KT_BRL, keycode - KEY_BRL_DOT1 + 1);
+ keysym = U(K(KT_BRL, keycode - KEY_BRL_DOT1 + 1));
else
return;
else
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majo...@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Andrew Morton

unread,
Nov 20, 2009, 4:30:03 PM11/20/09
to
On Tue, 17 Nov 2009 14:51:11 +0100
Samuel Thibault <samuel....@ens-lyon.org> wrote:

> Keysyms stored in key_map[] are not simply K() values, but U(K())
> values, as can be seen in the KDSKBENT ioctl handler. The
> kernel-generated braille keysyms thus need a U() call too.
>
> Signed-off-by: Samuel Thibault <samuel....@ens-lyon.org>
>
> diff --git a/drivers/char/keyboard.c b/drivers/char/keyboard.c
> index 737be95..82c493e 100644
> --- a/drivers/char/keyboard.c
> +++ b/drivers/char/keyboard.c
> @@ -1249,7 +1249,7 @@ static void kbd_keycode(unsigned int keycode, int down, int hw_raw)
>
> if (keycode >= NR_KEYS)
> if (keycode >= KEY_BRL_DOT1 && keycode <= KEY_BRL_DOT8)
> - keysym = K(KT_BRL, keycode - KEY_BRL_DOT1 + 1);
> + keysym = U(K(KT_BRL, keycode - KEY_BRL_DOT1 + 1));
> else
> return;
> else

Sorry, but I cannot work out (with a reasonable amount of effort) what
the user-visible effects of this bug are likely to be. So I am not in
a position to decide which kernel(s) this patch should be merged into.

Please be careful to include this aspect in the changelog when
appropriate, thanks.

Message has been deleted
0 new messages