All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH V2 1/3] input: Add some extra PNP keyboard types
@ 2010-05-17 15:38 Matthew Garrett
  2010-05-17 15:38 ` [PATCH V2 2/3] input: Add a PNP entry to the aux device list Matthew Garrett
  2010-05-17 15:38 ` [PATCH V2 3/3] input: Default to only using PNP for i8042 probing on x86 Matthew Garrett
  0 siblings, 2 replies; 6+ messages in thread
From: Matthew Garrett @ 2010-05-17 15:38 UTC (permalink / raw)
  To: linux-input; +Cc: dmitry.torokhov, linux-kernel, torvalds, Matthew Garrett

Some Japanese machines declare their keyboard with a different PNP ID.
Add it to the list of probed device IDs. While we're at it, add all the
other IDs that Windows binds to - we'll probably never see them in the
real world, but it doesn't hurt.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
---
 drivers/input/serio/i8042-x86ia64io.h |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/drivers/input/serio/i8042-x86ia64io.h b/drivers/input/serio/i8042-x86ia64io.h
index ead0494..871a74c 100644
--- a/drivers/input/serio/i8042-x86ia64io.h
+++ b/drivers/input/serio/i8042-x86ia64io.h
@@ -660,8 +660,21 @@ static int i8042_pnp_aux_probe(struct pnp_dev *dev, const struct pnp_device_id *
 }
 
 static struct pnp_device_id pnp_kbd_devids[] = {
+	{ .id = "PNP0300", .driver_data = 0 },
+	{ .id = "PNP0301", .driver_data = 0 },
+	{ .id = "PNP0302", .driver_data = 0 },
 	{ .id = "PNP0303", .driver_data = 0 },
+	{ .id = "PNP0304", .driver_data = 0 },
+	{ .id = "PNP0305", .driver_data = 0 },
+	{ .id = "PNP0306", .driver_data = 0 },
+	{ .id = "PNP0309", .driver_data = 0 },
+	{ .id = "PNP030a", .driver_data = 0 },
 	{ .id = "PNP030b", .driver_data = 0 },
+	{ .id = "PNP0320", .driver_data = 0 },
+	{ .id = "PNP0343", .driver_data = 0 },
+	{ .id = "PNP0344", .driver_data = 0 },
+	{ .id = "PNP0345", .driver_data = 0 },
+	{ .id = "CPQA0D7", .driver_data = 0 },
 	{ .id = "", },
 };
 
-- 
1.7.0.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH V2 2/3] input: Add a PNP entry to the aux device list
  2010-05-17 15:38 [PATCH V2 1/3] input: Add some extra PNP keyboard types Matthew Garrett
@ 2010-05-17 15:38 ` Matthew Garrett
  2010-05-17 15:38 ` [PATCH V2 3/3] input: Default to only using PNP for i8042 probing on x86 Matthew Garrett
  1 sibling, 0 replies; 6+ messages in thread
From: Matthew Garrett @ 2010-05-17 15:38 UTC (permalink / raw)
  To: linux-input; +Cc: dmitry.torokhov, linux-kernel, torvalds, Matthew Garrett

Windows checks for an ALPS PS/2 device in PNP. Add it on the off-chance
that there's a machine that expresses this without also providing a
compatibility ID.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
---
 drivers/input/serio/i8042-x86ia64io.h |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/input/serio/i8042-x86ia64io.h b/drivers/input/serio/i8042-x86ia64io.h
index 871a74c..6168469 100644
--- a/drivers/input/serio/i8042-x86ia64io.h
+++ b/drivers/input/serio/i8042-x86ia64io.h
@@ -685,6 +685,7 @@ static struct pnp_driver i8042_pnp_kbd_driver = {
 };
 
 static struct pnp_device_id pnp_aux_devids[] = {
+	{ .id = "AUI0200", .driver_data = 0 },
 	{ .id = "FJC6000", .driver_data = 0 },
 	{ .id = "FJC6001", .driver_data = 0 },
 	{ .id = "PNP0f03", .driver_data = 0 },
-- 
1.7.0.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH V2 3/3] input: Default to only using PNP for i8042 probing on x86
  2010-05-17 15:38 [PATCH V2 1/3] input: Add some extra PNP keyboard types Matthew Garrett
  2010-05-17 15:38 ` [PATCH V2 2/3] input: Add a PNP entry to the aux device list Matthew Garrett
@ 2010-05-17 15:38 ` Matthew Garrett
  2010-05-17 20:52   ` Linus Torvalds
  1 sibling, 1 reply; 6+ messages in thread
From: Matthew Garrett @ 2010-05-17 15:38 UTC (permalink / raw)
  To: linux-input; +Cc: dmitry.torokhov, linux-kernel, torvalds, Matthew Garrett

Experimenting with Windows has revealed that it will not probe the
keyboard controller unless a valid PNPACPI device is present. Change our
behaviour to match - users can override by using the existing
i8042.nopnp=1 parameter.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
---
 drivers/input/serio/i8042-x86ia64io.h |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/drivers/input/serio/i8042-x86ia64io.h b/drivers/input/serio/i8042-x86ia64io.h
index 6168469..a5b5926 100644
--- a/drivers/input/serio/i8042-x86ia64io.h
+++ b/drivers/input/serio/i8042-x86ia64io.h
@@ -1,6 +1,8 @@
 #ifndef _I8042_X86IA64IO_H
 #define _I8042_X86IA64IO_H
 
+#include <linux/acpi.h>
+
 /*
  * This program is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 as published by
@@ -744,9 +746,10 @@ static int __init i8042_pnp_init(void)
 
 	if (!i8042_pnp_kbd_devices && !i8042_pnp_aux_devices) {
 		i8042_pnp_exit();
-#if defined(__ia64__)
-		return -ENODEV;
-#else
+
+		if (!acpi_disabled)
+			return -ENODEV;
+
 		printk(KERN_INFO "PNP: No PS/2 controller found. Probing ports directly.\n");
 		return 0;
 #endif
-- 
1.7.0.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH V2 3/3] input: Default to only using PNP for i8042 probing on x86
  2010-05-17 15:38 ` [PATCH V2 3/3] input: Default to only using PNP for i8042 probing on x86 Matthew Garrett
@ 2010-05-17 20:52   ` Linus Torvalds
  2010-05-17 21:02     ` Matthew Garrett
  2010-05-17 21:19     ` [PATCH V3] " Matthew Garrett
  0 siblings, 2 replies; 6+ messages in thread
From: Linus Torvalds @ 2010-05-17 20:52 UTC (permalink / raw)
  To: Matthew Garrett; +Cc: linux-input, dmitry.torokhov, linux-kernel



On Mon, 17 May 2010, Matthew Garrett wrote:
> @@ -744,9 +746,10 @@ static int __init i8042_pnp_init(void)
>  
>  	if (!i8042_pnp_kbd_devices && !i8042_pnp_aux_devices) {
>  		i8042_pnp_exit();
> -#if defined(__ia64__)
> -		return -ENODEV;
> -#else
> +
> +		if (!acpi_disabled)
> +			return -ENODEV;
> +
>  		printk(KERN_INFO "PNP: No PS/2 controller found. Probing ports directly.\n");
>  		return 0;
>  #endif

This can't be right. That #endif is still there. How could this even 
compile?

Tssk, tssk.

		Linus

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH V2 3/3] input: Default to only using PNP for i8042 probing on x86
  2010-05-17 20:52   ` Linus Torvalds
@ 2010-05-17 21:02     ` Matthew Garrett
  2010-05-17 21:19     ` [PATCH V3] " Matthew Garrett
  1 sibling, 0 replies; 6+ messages in thread
From: Matthew Garrett @ 2010-05-17 21:02 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-input, dmitry.torokhov, linux-kernel

On Mon, May 17, 2010 at 01:52:39PM -0700, Linus Torvalds wrote:

> This can't be right. That #endif is still there. How could this even 
> compile?
> 
> Tssk, tssk.

Crap. Sorry, I suck. I'll resend this one.

-- 
Matthew Garrett | mjg59@srcf.ucam.org

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH V3] input: Default to only using PNP for i8042 probing on x86
  2010-05-17 20:52   ` Linus Torvalds
  2010-05-17 21:02     ` Matthew Garrett
@ 2010-05-17 21:19     ` Matthew Garrett
  1 sibling, 0 replies; 6+ messages in thread
From: Matthew Garrett @ 2010-05-17 21:19 UTC (permalink / raw)
  To: linux-input; +Cc: dmitry.torokhov, linux-kernel, torvalds, Matthew Garrett

Experimenting with Windows has revealed that it will not probe the
keyboard controller unless a valid PNPACPI device is present. Change our
behaviour to match - users can override by using the existing
i8042.nopnp=1 parameter.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
---
 drivers/input/serio/i8042-x86ia64io.h |   14 ++++++++++----
 1 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/drivers/input/serio/i8042-x86ia64io.h b/drivers/input/serio/i8042-x86ia64io.h
index 6168469..19d11f3 100644
--- a/drivers/input/serio/i8042-x86ia64io.h
+++ b/drivers/input/serio/i8042-x86ia64io.h
@@ -1,6 +1,8 @@
 #ifndef _I8042_X86IA64IO_H
 #define _I8042_X86IA64IO_H
 
+#include <linux/acpi.h>
+
 /*
  * This program is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 as published by
@@ -744,12 +746,16 @@ static int __init i8042_pnp_init(void)
 
 	if (!i8042_pnp_kbd_devices && !i8042_pnp_aux_devices) {
 		i8042_pnp_exit();
-#if defined(__ia64__)
-		return -ENODEV;
-#else
+
+		/* Non-ACPI systems are much less likely to have the
+		 * KBC declared via PNP, so if acpi is disabled fall
+		 * back to banging the ports directly */
+
+		if (!acpi_disabled)
+			return -ENODEV;
+
 		printk(KERN_INFO "PNP: No PS/2 controller found. Probing ports directly.\n");
 		return 0;
-#endif
 	}
 
 	if (i8042_pnp_kbd_devices)
-- 
1.7.0.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2010-05-17 21:20 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-05-17 15:38 [PATCH V2 1/3] input: Add some extra PNP keyboard types Matthew Garrett
2010-05-17 15:38 ` [PATCH V2 2/3] input: Add a PNP entry to the aux device list Matthew Garrett
2010-05-17 15:38 ` [PATCH V2 3/3] input: Default to only using PNP for i8042 probing on x86 Matthew Garrett
2010-05-17 20:52   ` Linus Torvalds
2010-05-17 21:02     ` Matthew Garrett
2010-05-17 21:19     ` [PATCH V3] " Matthew Garrett

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.