Thread (20 messages) 20 messages, 5 authors, 2015-02-02

[PATCH v2 1/4] tty: serial: Add 8250 earlycon to support noinit option

From: Peter Hurley <hidden>
Date: 2015-02-02 03:27:20
Also in: linux-devicetree, linux-serial, lkml

On 02/01/2015 09:45 PM, Eddie Huang wrote:
Hi Peter,

On Sun, 2015-02-01 at 11:27 -0500, Peter Hurley wrote:
quoted
Hi Eddie,

On 01/12/2015 08:08 AM, Eddie Huang wrote:
quoted
Add earlycon support not only baudrate option, but also add noinit option.
If use noinit option, 8250 earlycon will not init serial hardware and use
loader setting.
I see this went into Greg's tty-testing branch.

The only point of this is to not program the divisor, right?
In this case, yes.
quoted
I ask because early_serial8250_setup() could already handle this without
extra options by simply not doing divisor programming if no baud option is
present.
MTK support high speed UART, which means baudrate can be more than
115200. You can reference mtk8250_set_termios() function in 8250_mtk.c.
Unfortunately, the early_serial8250_setup() can not handle high speed
case. This is why I add noinit parameter.
Thanks, that's what I thought; I just wanted to verify.
Besides, I think "no baud option" is a little tricky, and maybe someday
someone not only care about divisor, but also flow. Legacy earlyprintk
and other uart drivers like msm_serial.c also don't init uart hardware.
My point is the 8250 earlycon should only be doing hardware initialization
if there is an option string (of the form <baud><parity><bits>), because
if there's no baud option, programming the divisor is pointless.

And to specify any other line control option the baud must be specified.
So to program any other setting would require the proper option string.

Regards,
Peter Hurley
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help