linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* CPM2 early console
@ 2005-09-22 13:11 Kalle Pokki
  0 siblings, 0 replies; 25+ messages in thread
From: Kalle Pokki @ 2005-09-22 13:11 UTC (permalink / raw)
  To: linuxppc-embedded

Hello,

I'm trying to get vanilla 2.6.13.1 running on an EP8248 board without 
much success. I created my own platform files and have the kernel 
booting, but the execution is permanently stuck in the 
cpm_uart_console_write() function in the first while ((bdp->cbd_sc & 
BD_SC_READY) != 0) statement.

I don't have any COP debugger for this processor family, so the only 
debugging aid is the two leds onboard... It's clear that the buffer 
descriptor is not in sync with the CPM, but I have no clue what the 
address of the buffer descriptor is.

It seems this code is rather new, and I'm wondering if any of you have 
some patches that are not in the mainline kernel yet. Has anyone tested 
this with a 8248 processor? If so, could you please send your .config to 
me in case I made some errors in the platform definition.

^ permalink raw reply	[flat|nested] 25+ messages in thread
* RE: CPM2 early console
@ 2005-09-22 16:02 Rune Torgersen
  2005-09-22 16:05 ` Kumar Gala
  2005-09-23 10:55 ` Kalle Pokki
  0 siblings, 2 replies; 25+ messages in thread
From: Rune Torgersen @ 2005-09-22 16:02 UTC (permalink / raw)
  To: Kalle Pokki, linuxppc-embedded

[-- Attachment #1: Type: text/plain, Size: 740 bytes --]

There is a bug in the SMC init code, wher the base address for the SMC's
is not reinitialized by the kernel, so if the SMC is not initialized by
the bootloader, it will not work.

If that is the case, try this patch.

-----Original Message-----
From: Rune Torgersen 
Sent: Tuesday, August 23, 2005 15:19
To: linuxppc-embedded@ozlabs.org
Subject: [PATCH] ppc32: Fix baseaddress for SMC 1 and 2

Base addess register for SMC 1 and 2 are never initialized. 
This means that they will not work unless a bootloader already
configured them.
The DPRAM already have space reserved, this patch just makes sure 
the base addess register is updated correctly on initialization.

Signed-off-by: Rune Torgersen <runet@innovsys.com>


[-- Attachment #2: smc_baseparam.patch --]
[-- Type: application/octet-stream, Size: 1065 bytes --]

--- linux/drivers/serial/cpm_uart/cpm_uart_cpm2.c	2005-08-23 09:01:37.000000000 -0500
+++ linux-innsys/drivers/serial/cpm_uart/cpm_uart_cpm2.c	2005-08-23 15:11:14.000000000 -0500
@@ -257,6 +257,7 @@ int cpm_uart_init_portdesc(void)
 	cpm_uart_ports[UART_SMC1].smcp = (smc_t *) & cpm2_immr->im_smc[0];
 	cpm_uart_ports[UART_SMC1].smcup =
 	    (smc_uart_t *) & cpm2_immr->im_dprambase[PROFF_SMC1];
+	*(ushort *)(&cpm2_immr->im_dprambase[PROFF_SMC1_BASE]) = PROFF_SMC1;
 	cpm_uart_ports[UART_SMC1].port.mapbase =
 	    (unsigned long)&cpm2_immr->im_smc[0];
 	cpm_uart_ports[UART_SMC1].smcp->smc_smcm |= (SMCM_RX | SMCM_TX);
@@ -269,6 +270,7 @@ int cpm_uart_init_portdesc(void)
 	cpm_uart_ports[UART_SMC2].smcp = (smc_t *) & cpm2_immr->im_smc[1];
 	cpm_uart_ports[UART_SMC2].smcup =
 	    (smc_uart_t *) & cpm2_immr->im_dprambase[PROFF_SMC2];
+	*(ushort *)(&cpm2_immr->im_dprambase[PROFF_SMC2_BASE]) = PROFF_SMC2;
 	cpm_uart_ports[UART_SMC2].port.mapbase =
 	    (unsigned long)&cpm2_immr->im_smc[1];
 	cpm_uart_ports[UART_SMC2].smcp->smc_smcm |= (SMCM_RX | SMCM_TX);

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

end of thread, other threads:[~2005-10-04 16:04 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-09-22 13:11 CPM2 early console Kalle Pokki
  -- strict thread matches above, loose matches on Subject: below --
2005-09-22 16:02 Rune Torgersen
2005-09-22 16:05 ` Kumar Gala
2005-09-23 10:55 ` Kalle Pokki
2005-09-27 14:11   ` Kalle Pokki
2005-09-27 16:39     ` Dan Malek
2005-09-27 20:35       ` Kalle Pokki
2005-09-27 20:48         ` Dan Malek
2005-09-28 10:20           ` Kalle Pokki
2005-09-29 12:24             ` Kalle Pokki
2005-09-29 12:50               ` Dan Malek
2005-09-30 13:22               ` Alex Zeffertt
2005-09-30 13:42                 ` Alex Zeffertt
2005-09-30 20:16                   ` Kalle Pokki
2005-09-30 13:58                 ` Dan Malek
2005-09-30 20:10                   ` Kalle Pokki
2005-09-30 20:28                     ` Dan Malek
2005-10-01  5:57                       ` Kalle Pokki
2005-10-01  8:24                         ` Roger Larsson
2005-10-02 16:59                         ` Dan Malek
2005-10-03  7:04                           ` Kalle Pokki
2005-10-04  8:13                             ` Kalle Pokki
2005-10-04  9:59                               ` Alex Zeffertt
2005-10-04 10:16                                 ` Kalle Pokki
2005-10-04 16:04                               ` Dan Malek

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).