Ticket #11212 (new defect)

Opened 21 months ago

Last modified 21 months ago

renumber XO-1.75 serial ports

Reported by: dsd Owned by: saadia
Priority: normal Milestone: Future Release
Component: kernel Version: not specified
Keywords: Cc: pgf
Action Needed: never set Verified: no
Deployments affected: Blocked By:
Blocking:

Description

The XO-1.75 has four serial ports.

  • ttyS0: quanta's debug connector
  • ttyS1: unconnected
  • ttyS2: standard serial port used for OFW/kernel messages, runs a getty during Linux operation
  • ttyS3: alternate serial port, nothing uses it by default

Paul suggests that we could unravel the mmp2/pxa layers a bit so that we can assign a better numbering scheme. Renaming ttyS2 to ttyS0 would solve a few special cases (bringing it in-line with XO-1/XO-1.5).

Change History

Changed 21 months ago by dsd

  • cc pgf added

Changed 21 months ago by dsd

See olpc_xo_1_75_init() in olpc-xo-1-75.c for where the serial ports are created (with fixed numbers) at the moment.

Changed 21 months ago by pgf

for instance, this fixes it. (thanks to jnettlet) may or may not be the right place, layering-wise.

diff --git a/arch/arm/mach-mmp/mmp2.c b/arch/arm/mach-mmp/mmp2.c
index b1f5126..dc09b72 100644
--- a/arch/arm/mach-mmp/mmp2.c
+++ b/arch/arm/mach-mmp/mmp2.c
@@ -382,10 +382,17 @@ struct sys_timer mmp2_timer = {
 };
 
 /* on-chip devices */
+#ifdef CONFIG_MACH_OLPC_XO_1_75
+MMP2_DEVICE(uart1, "pxa2xx-uart", 2, UART1, 0xd4030000, 0x30, 4, 5);
+MMP2_DEVICE(uart2, "pxa2xx-uart", 3, UART2, 0xd4017000, 0x30, 20, 21);
+MMP2_DEVICE(uart3, "pxa2xx-uart", 0, UART3, 0xd4018000, 0x30, 22, 23);
+MMP2_DEVICE(uart4, "pxa2xx-uart", 1, UART4, 0xd4016000, 0x30, 18, 19);
+#else
 MMP2_DEVICE(uart1, "pxa2xx-uart", 0, UART1, 0xd4030000, 0x30, 4, 5);
 MMP2_DEVICE(uart2, "pxa2xx-uart", 1, UART2, 0xd4017000, 0x30, 20, 21);
 MMP2_DEVICE(uart3, "pxa2xx-uart", 2, UART3, 0xd4018000, 0x30, 22, 23);
 MMP2_DEVICE(uart4, "pxa2xx-uart", 3, UART4, 0xd4016000, 0x30, 18, 19);
+#endif
 MMP2_DEVICE(twsi1, "pxa2xx-i2c", 0, TWSI1, 0xd4011000, 0x70);
 MMP2_DEVICE(twsi2, "pxa2xx-i2c", 1, TWSI2, 0xd4031000, 0x70);
 MMP2_DEVICE(twsi3, "pxa2xx-i2c", 2, TWSI3, 0xd4032000, 0x70);

Changed 21 months ago by Quozl

Documentation may need update; http://wiki.laptop.org/go/Serial_adapters#XO-1.75

Note: See TracTickets for help on using tickets.