linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] When checking I8042 io port, use of_find_compatible_node() instead of of_find_node_by_type()
@ 2007-06-06 16:42 Wade Farnsworth
  2007-06-07 13:05 ` Segher Boessenkool
  0 siblings, 1 reply; 5+ messages in thread
From: Wade Farnsworth @ 2007-06-06 16:42 UTC (permalink / raw)
  To: paulus; +Cc: linuxppc-dev

In check_legacy_ioport(), instead of using of_find_node_by_type() to
find the 8042 node, use of_find_compatible_node() to find either the
keyboard or mouse node.

Signed-off-by: Wade Farnsworth <wfarnsworth@mvista.com>

---

 arch/powerpc/kernel/setup-common.c |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

Index: linux-2.6-powerpc-8641/arch/powerpc/kernel/setup-common.c
===================================================================
--- linux-2.6-powerpc-8641.orig/arch/powerpc/kernel/setup-common.c
+++ linux-2.6-powerpc-8641/arch/powerpc/kernel/setup-common.c
@@ -517,7 +517,14 @@ int check_legacy_ioport(unsigned long ba
 
 	switch(base_port) {
 	case I8042_DATA_REG:
-		np = of_find_node_by_type(NULL, "8042");
+		np = of_find_compatible_node(NULL, NULL, "pnpPNP,303");
+		if (!np)
+			np = of_find_compatible_node(NULL, NULL, "pnpPNP,f03");
+		if (np) {
+			parent = of_get_parent(np);
+			of_node_put(np);
+			np = parent;
+		}
 		break;
 	case FDC_BASE: /* FDC1 */
 		np = of_find_node_by_type(NULL, "fdc");

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

end of thread, other threads:[~2007-06-07 17:52 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-06 16:42 [PATCH] When checking I8042 io port, use of_find_compatible_node() instead of of_find_node_by_type() Wade Farnsworth
2007-06-07 13:05 ` Segher Boessenkool
2007-06-07 16:26   ` Wade Farnsworth
2007-06-07 16:59     ` Segher Boessenkool
2007-06-07 17:52       ` Wade Farnsworth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).