Messages in this thread Patch in this message | | | Subject | [PATCH] Same keyboard.c as in 2.6.0 | From | Markus Hästbacka <> | Date | Thu, 15 Jan 2004 01:47:41 +0200 |
| |
Hi list, I think many of you have run into this problem: Some of your keys doesn't work in 2.6.1.
If you linux gurus know a better way to do this - please tell.
Compiled and tested against 2.6.1-bk2
I made a small patch that makes them work as in 2.6.0: --- CUT HERE --- --- linux-2.6.1/drivers/char/keyboard.c 2004-01-09 08:59:26.000000000 +0200 +++ linux-2.6.0/drivers/char/keyboard.c 2003-12-18 04:58:46.000000000 +0200 @@ -941,16 +941,16 @@ static unsigned short x86_keycodes[256] 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, - 80, 81, 82, 83, 84, 93, 86, 87, 88, 94, 95, 85,259,375,260, 90, - 284,285,309,311,312, 91,327,328,329,331,333,335,336,337,338,339, - 367,288,302,304,350, 89,334,326,116,377,109,111,126,347,348,349, - 360,261,262,263,298,376,100,101,321,316,373,286,289,102,351,355, + 80, 81, 82, 83, 43, 85, 86, 87, 88,115,119,120,121,375,123, 90, + 284,285,309,298,312, 91,327,328,329,331,333,335,336,337,338,339, + 367,288,302,304,350, 92,334,512,116,377,109,111,373,347,348,349, + 360, 93, 94, 95, 98,376,100,101,321,316,354,286,289,102,351,355, 103,104,105,275,287,279,306,106,274,107,294,364,358,363,362,361, - 291,108,381,281,290,272,292,305,280, 99,112,257,258,359,113,114, - 264,117,271,374,379,115,125,273,121,123, 92,265,266,267,268,269, - 120,119,118,277,278,282,283,295,296,297,299,300,301,293,303,307, - 308,310,313,314,315,317,318,319,320,357,322,323,324,325,276,330, - 332,340,365,342,343,344,345,346,356,270,341,368,369,370,371,372 }; + 291,108,381,281,290,272,292,305,280, 99,112,257,258,359,270,114, + 118,117,125,374,379,115,112,125,121,123,264,265,266,267,268,269, + 271,273,276,277,278,282,283,295,296,297,299,300,301,293,303,307, + 308,310,313,314,315,317,318,319,320,357,322,323,324,325,326,330, + 332,340,365,342,343,344,345,346,356,113,341,368,369,370,371,372 }; #ifdef CONFIG_MAC_EMUMOUSEBTN extern int mac_hid_mouse_emulate_buttons(int, int, int); @@ -972,18 +972,11 @@ static int emulate_raw(struct vc_data *v if (keycode > 255 || !x86_keycodes[keycode]) return -1; - switch (keycode) { - case KEY_PAUSE: - put_queue(vc, 0xe1); - put_queue(vc, 0x1d | up_flag); - put_queue(vc, 0x45 | up_flag); - return 0; - case KEY_LANG1: - if (!up_flag) put_queue(vc, 0xf1); - return 0; - case KEY_LANG2: - if (!up_flag) put_queue(vc, 0xf2); - return 0; + if (keycode == KEY_PAUSE) { + put_queue(vc, 0xe1); + put_queue(vc, 0x1d | up_flag); + put_queue(vc, 0x45 | up_flag); + return 0; } if (keycode == KEY_SYSRQ && sysrq_alt) { --- CUT HERE --- -- "Software is like sex, it's better when it's free." Markus Hästbacka <midian at ihme dot org>[unhandled content-type:application/pgp-signature] | |