[RFC] ARM/serial: add a DCC based console driver

Sascha Hauer s.hauer at pengutronix.de
Tue Mar 13 09:24:55 EDT 2012


On Tue, Mar 13, 2012 at 02:16:46PM +0100, Juergen Beisert wrote:
> Hi,
> 
> please find attached an DCC based driver for Barebox to be able to get early 
> boot messages. It acts as a regular serial console and can be used in 
> conjunction with a JTAG debugger. This is really useful when no serial 
> console is available (don't ask why...) and the bootloader hangs prior it can 
> enable a network based console.
> 
> One issue is still present and I need some hints what might be going wrong 
> here:
> 
> Sending chars via DCC blocks for ever, when I'm using a simple
> while loop waiting for the DCC_OUTPUT_BUSY to be cleared. After adding a 
> timeout loop I receive every other char at the JTAG side. When I write the 
> char to the DCC even if it timeout, I receive *every* char. Only some chars 
> are lost when I reduce the timeout value below 750 us.
> Any idea? I checked the kernel source, but they doing the same: Waiting for 
> the DCC_OUTPUT_BUSY to be cleared and timeout after a specific amount of 
> loops (but without writing the char in this case).
> 
> Comments are welcome.

You are probably not aware that we already have such a driver in
drivers/serial/arm_dcc.c.

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |



More information about the barebox mailing list