* Disabling the serial console upsets CPM UARTS
@ 2004-08-04 21:34 Richard Williams
2004-08-04 22:47 ` Wolfgang Denk
0 siblings, 1 reply; 2+ messages in thread
From: Richard Williams @ 2004-08-04 21:34 UTC (permalink / raw)
To: linuxppc-embedded
I have seen some questions in the archive about people wanting to disable the serial console but not many answers.
We have a custom 860T product running a modified 2.4.4 kernel. The console was disabled by excluding some code in printk.c and this has resulted in strange effects with the CPM UART driver.
#undef ENABLE_SERIAL_CONSOLE
#ifdef ENABLE_SERIAL_CONSOLE
if( preferred_console < 0 )
{
if( console->index < 0 )
{
console->index = 0;
}
if(( console->setup == NULL ) || ( console->setup( console, NULL ) == 0 ))
{
console->flags |= CON_ENABLED;
console->flags |= CON_CONSDEV;
preferred_console = 0;
}
}
#endif
Disabling the console meant that serial_console_setup() is not called before rs_8xx_init() and according to the comments in uart.c, this is bad. The CPM UART's were initialised while the u-boot enabled UART was still operational. The BD's used by the u-boot enabled UART were allocated to another SMC and this caused problems when this UART was intialised (The tx buffer pointer got out of sync with the rx buffer pointer and we received characters out of order).
I tried disabling the u-boot enabled serial port before rs_8xx_init() is called and this seemed to fix the problem, until now. Another problem has cropped up (with pppd) where closing a CPM UART port causes all the other CPM UARTS's to freeze until it is opened again. Re-enabling the serial console makes the problem go away.
My questions are
1. Is there a better way to disable the serial console (or even better, allow the kernel parameter 'console=' to switch it on of off)?
2. If the console port can be changed by the 'console=' parameter, what is the purpose of the compile time configuration and selection of a console port in uart.c?
Regards,
Richard
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Disabling the serial console upsets CPM UARTS
2004-08-04 21:34 Disabling the serial console upsets CPM UARTS Richard Williams
@ 2004-08-04 22:47 ` Wolfgang Denk
0 siblings, 0 replies; 2+ messages in thread
From: Wolfgang Denk @ 2004-08-04 22:47 UTC (permalink / raw)
To: Richard Williams; +Cc: linuxppc-embedded
In message <A3240F62EF3C2749B1A25D3BC9548F4148BC29@ExchWENZ02.wenz.global.vpn> you wrote:
>
> I have seen some questions in the archive about people wanting to disable the serial console but not many answers.
Maybe there ius little to answer?
> We have a custom 860T product running a modified 2.4.4 kernel. The console was disabled by excluding some code in printk.c and this has resulted in strange effects with the CPM UART driver.
Why don't you just pass a "console=null" boot argument?
> My questions are
> 1. Is there a better way to disable the serial console (or even better, allow the kernel parameter 'console=' to switch it on of off)?
Yes, of course there is. "console=null" is all you need.
> 2. If the console port can be changed by the 'console=' parameter, what is the purpose of the compile time configuration and selection of a console port in uart.c?
To set up a default console when no console=... boot argument is present?
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-4596-87 Fax: (+49)-8142-4596-88 Email: wd@denx.de
"If people are good only because they fear punishment, and hope for
reward, then we are a sorry lot indeed." - Albert Einstein
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2004-08-04 22:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-08-04 21:34 Disabling the serial console upsets CPM UARTS Richard Williams
2004-08-04 22:47 ` Wolfgang Denk
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).