Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Thu, 23 Jan 2003 22:05:50 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Thu, 23 Jan 2003 22:05:50 -0500 Received: from ylug.mozilla.gr.jp ([203.141.142.92]:19209 "HELO maison.kyo-ko.org") by vger.kernel.org with SMTP id ; Thu, 23 Jan 2003 22:05:49 -0500 X-Mailer: cmail 2.61.1+20011011 on GNU Emacs 20.7.2 / Mule 4.1 =?ISO-2022-JP?B?KBskQjAqGyhCKQ==?= From: Hiroshi Miura To: vojtech@suse.cz, linux-kernel@vger.kernel.org Subject: [PATCH 2.5.59] support japanese JP106 keyboard on new console. X-Face: "7/]{D;9O-#dR'kB\tvpz_:#o|*UdC.KK/_"IN*i5VTU&EBhS6w68xQDPh]i4N%1byZ~v~X k$vdp(%V@gY!_|7x7Ht)^ih5\%\l'hcl$`sqp;%`boxPHDJB<~Sr8(e:zPKmeZ)ZPml[0v\|[V00Jm G,%5V5X9Mw7j}(8+!o>&&wmQ]Xh=j User-Agent: SEMI/1.14.4 (=?ISO-2022-JP?B?GyRCOllPJExaGyhC?=) FLIM/1.14.4 (=?ISO-2022-JP?B?GyRCM2A4Nj9ANVxBMBsoQg==?=) APEL/10.4 Emacs/20.7 (i386-debian-linux-gnu) MULE/4.1 (=?ISO-2022-JP?B?GyRCMCobKEI=?=) MIME-Version: 1.0 (generated by SEMI 1.14.4 - =?ISO-2022-JP?B?IhskQjpZGyhC?= =?ISO-2022-JP?B?GyRCTyRMWhsoQiI=?=) Content-Type: text/plain; charset=US-ASCII Message-Id: <20030124031453.0A29F11775F@triton2> Date: Fri, 24 Jan 2003 12:14:53 +0900 (JST) Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Hi, After re-writting a console layer, a japanese keyboard is not supported (or degraded). This patch fixs it. A USB keyboard driver may have same problem, but I don't have one. --- linux-2.5.59/drivers/input/keyboard/atkbd.c 2002-12-03 07:59:41.000000000 +0900 +++ edited/linux-2.5.59/drivers/input/keyboard/atkbd.c 2003-01-24 09:13:11.000000000 +0900 @@ -309,6 +309,12 @@ if (atkbd_command(atkbd, &atkbd->oldset, ATKBD_CMD_GSCANSET)) atkbd->oldset = 2; + if (atkbd->id == 0xab02) { + printk("atkbd: jp109(106) keyboard found\n"); + param[0] = atkbd_set; + atkbd_command(atkbd, param, ATKBD_CMD_SSCANSET); + return 5; + } /* * For known special keyboards we can go ahead and set the correct set. * We check for NCD PS/2 Sun, NorthGate OmniKey 101 and @@ -531,6 +537,12 @@ else memcpy(atkbd->keycode, atkbd_set2_keycode, sizeof(atkbd->keycode)); + if (atkbd->set == 5) { + atkbd->keycode[0x13] = 0x70; /* Hiragana/Katakana */ + atkbd->keycode[0x6a] = 0x7c; /* Yen, pipe 124*/ + atkbd->set = 2; + } + atkbd->dev.name = atkbd->name; atkbd->dev.phys = atkbd->phys; atkbd->dev.id.bustype = BUS_I8042; @@ -544,7 +556,7 @@ input_register_device(&atkbd->dev); - printk(KERN_INFO "input: %s on %s\n", atkbd->name, serio->phys); + printk(KERN_INFO "input: %s (0x%x) on %s\n", atkbd->name, atkbd->id, serio->phys); } -- Hiroshi Miura --- http://www.da-cha.org/ NTTDATA Corp. Marketing & Business Strategy Planning Dept. --- miurahr@nttdata.co.jp Key fingerprint = 9117 9407 5684 FBF1 4063 15B4 401D D077 04AB 8617 -- My hacking life is happy as the day is long - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/