Thread (60 messages) flat view 60 messages, 3 authors, 2007-08-24

Re: [PATCH 10/20] bootwrapper: Add CPM serial driver.

From: Scott Wood <hidden>
Date: 2007-08-21 16:15:53

David Gibson wrote:
quoted
diff --git a/arch/powerpc/boot/serial.c b/arch/powerpc/boot/serial.c
index 944f0ee..d47f8e0 100644
--- a/arch/powerpc/boot/serial.c
+++ b/arch/powerpc/boot/serial.c
@@ -121,6 +121,11 @@ int serial_console_init(void)
		rc = ns16550_console_init(devp, &serial_cd);
	else if (dt_is_compatible(devp, "marvell,mpsc"))
		rc = mpsc_console_init(devp, &serial_cd);
+	else if (dt_is_compatible(devp, "fsl,cpm1-scc-uart") ||
+	         dt_is_compatible(devp, "fsl,cpm1-smc-uart") ||
+	         dt_is_compatible(devp, "fsl,cpm2-scc-uart") ||
+	         dt_is_compatible(devp, "fsl,cpm2-smc-uart"))
+		rc = cpm_console_init(devp, &serial_cd);

If all these variants admit a compatible driver, there really should
be defined a compatible value that they all include in the device
tree.
That's what I did last time, and several people complained. :-)

The issue was that while there is a lot in common between these 
variants, there's no one common subset that can be used to drive the 
device without knowledge of what variant it is (or knowledge of where 
the firmware placed the descriptors).
But I guess you'd still need all these tests for device trees
which didn't have it.
Nah, this is a new binding.

-Scott
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help