Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-23 Thread Simon Glass
Hi Graeme, On Thu, Mar 22, 2012 at 4:41 PM, Graeme Russ wrote: > Hi Simon, > > On Fri, Mar 23, 2012 at 10:03 AM, Simon Glass wrote: > >> I am going to have a similar problem in the SPL soon - how to deal >> with panic(). Advice gratefully accepted. > > Take a leaf out of the Linux x86 source

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-22 Thread Graeme Russ
Hi Simon, On Fri, Mar 23, 2012 at 10:03 AM, Simon Glass wrote: > I am going to have a similar problem in the SPL soon - how to deal > with panic(). Advice gratefully accepted. Take a leaf out of the Linux x86 source arch/x86/boot/main.c - This is the start of the 16-bit 'real-mode' code wh

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-22 Thread Simon Glass
Hi Wolfgang, On Thu, Mar 22, 2012 at 4:00 PM, Wolfgang Denk wrote: > Dear Simon, > > In message > you > wrote: >> >> >> Yes, it is there, sorry. >> > >> > Which commit is that? >> >> It was 295d3942: Add board_pre_console_putc to deal with early console outp= >> ut >> >> The discussion threads

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-22 Thread Wolfgang Denk
Dear Simon Glass, In message you wrote: > > I am going to have a similar problem in the SPL soon - how to deal > with panic(). Advice gratefully accepted. The SPL code is not special in this regard: initialize the console port as soon as possible; then use it. Best regards, Wolfgang Denk --

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-22 Thread Wolfgang Denk
Dear Simon, In message you wrote: > > >> Yes, it is there, sorry. > > > > Which commit is that? > > It was 295d3942: Add board_pre_console_putc to deal with early console outp= > ut > > The discussion threads are around here: > > http://lists.denx.de/pipermail/u-boot/2011-August/099620.html

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-22 Thread Doug Anderson
Stephen, On Wed, Mar 21, 2012 at 9:49 AM, Stephen Warren wrote: > I was under the impression that earlyprintk was a boolean option, and > didn't take any arguments. But, a quick grep shows that some archs do > allow it to take an argument. The ARM code that handles the option > doesn't process t

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-22 Thread Simon Glass
Hi Wolfgang, On Thu, Mar 22, 2012 at 6:25 AM, Wolfgang Denk wrote: > Dear Simon Glass, > > In message > you > wrote: >> >> >> OK, so revert that commit? >> > >> > It hasn't hit mainline yet, or has it? >> >> Yes, it is there, sorry. > > Which commit is that? It was 295d3942: Add board_pre_con

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-22 Thread Wolfgang Denk
Dear Simon Glass, In message you wrote: > > >> OK, so revert that commit? > > > > It hasn't hit mainline yet, or has it? > > Yes, it is there, sorry. Which commit is that? > > This is why initializing the serial console has always been one of the > > very, very first initialization steps in

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Simon Glass
Hi Wolfgang, On Wed, Mar 21, 2012 at 4:07 PM, Wolfgang Denk wrote: > Dear Simon Glass, > > In message > you > wrote: >> >> > No.  I do not want to see any PRE_CONSOLE_UART or pre_console_putc() >> > stuff, because this is bogus.  If you do output to a serial UART port, >> > this _is_ your cons

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Wolfgang Denk
Dear Simon Glass, In message you wrote: > > > No. I do not want to see any PRE_CONSOLE_UART or pre_console_putc() > > stuff, because this is bogus. If you do output to a serial UART port, > > this _is_ your console. Just use it in the standard war. > > > > I made my mind up: I want to get ri

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Simon Glass
Hi Wolfgang, On Wed, Mar 21, 2012 at 3:56 PM, Wolfgang Denk wrote: > Dear Simon, > > In message > you > wrote: >> >> 3. What you propose is actually very easy to implement - it just >> requires a new config like CONFIG_DEFAULT_UART or >> CONFIG_PRE_CONSOLE_UART to be defined, and used in the >

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Wolfgang Denk
Dear Stephen, In message <4f6a1d1e.2090...@wwwdotorg.org> you wrote: > > But the last few messages in this thread have all been about the > following as far as I'm concerned: > > * The U-Boot configuration defines which single UART to use for the > initial console. > > * This initial console is

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Wolfgang Denk
Dear Simon, In message you wrote: > > 3. What you propose is actually very easy to implement - it just > requires a new config like CONFIG_DEFAULT_UART or > CONFIG_PRE_CONSOLE_UART to be defined, and used in the > board_pre_console_putc() code. No. I do not want to see any PRE_CONSOLE_UART or

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Wolfgang Denk
Dear Stephen Warren, In message <4f6a01d3.3020...@wwwdotorg.org> you wrote: > > > It appears that all you are trying here is an annoying, but somewhat > > unlikely error situation. As marked above (see *), it might make > > sense to think of alternative ways to find out what the console port > >

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Stephen Warren
On 03/21/2012 11:50 AM, Simon Glass wrote: > Hi Stephen, > > On Wed, Mar 21, 2012 at 10:38 AM, Stephen Warren > wrote: >> On 03/21/2012 11:13 AM, Simon Glass wrote: >>> Hi Stephen, >>> >>> On Wed, Mar 21, 2012 at 10:09 AM, Stephen Warren >>> wrote: On 03/21/2012 10:59 AM, Simon Glass wrot

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Simon Glass
Hi Stephen, On Wed, Mar 21, 2012 at 10:38 AM, Stephen Warren wrote: > On 03/21/2012 11:13 AM, Simon Glass wrote: >> Hi Stephen, >> >> On Wed, Mar 21, 2012 at 10:09 AM, Stephen Warren >> wrote: >>> On 03/21/2012 10:59 AM, Simon Glass wrote: 3. What you propose is actually very easy to imple

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Stephen Warren
On 03/21/2012 11:13 AM, Simon Glass wrote: > Hi Stephen, > > On Wed, Mar 21, 2012 at 10:09 AM, Stephen Warren > wrote: >> On 03/21/2012 10:59 AM, Simon Glass wrote: >>> 3. What you propose is actually very easy to implement - it just >>> requires a new config like CONFIG_DEFAULT_UART or >>> CONF

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Simon Glass
Hi Stephen, On Wed, Mar 21, 2012 at 10:09 AM, Stephen Warren wrote: > On 03/21/2012 10:59 AM, Simon Glass wrote: >> 3. What you propose is actually very easy to implement - it just >> requires a new config like CONFIG_DEFAULT_UART or >> CONFIG_PRE_CONSOLE_UART to be defined, and used in the >> bo

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Stephen Warren
On 03/21/2012 10:59 AM, Simon Glass wrote: > 3. What you propose is actually very easy to implement - it just > requires a new config like CONFIG_DEFAULT_UART or > CONFIG_PRE_CONSOLE_UART to be defined, and used in the > board_pre_console_putc() code. One question here: We already have CONFIG_TEGR

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Simon Glass
Hi Stephen, On Wed, Mar 21, 2012 at 9:49 AM, Stephen Warren wrote: > On 03/21/2012 04:35 AM, Graeme Russ wrote: >> Hi Stephen, Wolfgang, >> >> On 03/21/2012 08:38 PM, Wolfgang Denk wrote: >>> Dear Simon Glass, >>> >>> In message >>> you >>> wrote: >> >>> We have standard ways of telling the Li

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Stephen Warren
On 03/21/2012 04:35 AM, Graeme Russ wrote: > Hi Stephen, Wolfgang, > > On 03/21/2012 08:38 PM, Wolfgang Denk wrote: >> Dear Simon Glass, >> >> In message >> you >> wrote: > >> We have standard ways of telling the Linux kernel what the console >> port is - the "console=" boot argument has been

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Stephen Warren
On 03/21/2012 03:38 AM, Wolfgang Denk wrote: ... > To bring this to a constructive end: > > It appears that all you are trying here is an annoying, but somewhat > unlikely error situation. As marked above (see *), it might make > sense to think of alternative ways to find out what the console por

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Graeme Russ
Hi Stephen, Wolfgang, On 03/21/2012 08:38 PM, Wolfgang Denk wrote: > Dear Simon Glass, > > In message > you > wrote: > We have standard ways of telling the Linux kernel what the console > port is - the "console=" boot argument has been working fine for many, > many years and many, many boards

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Wolfgang Denk
Dear Simon Glass, In message you wrote: > > > I agree - The board designer should specify a 'default' debug port which > > is used for all character output prior to the 'configured' console port > > being initialised. > > We can provide that, but if it is wrong for the board we are using, The

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-21 Thread Wolfgang Denk
Dear Stephen Warren, In message <4f68f3d0.6030...@wwwdotorg.org> you wrote: > > For each board, there is a single fixed UART that should be used for Thanks for this statement. I agree 100%. > both pre-console panic and the "real" console later. This is fixed by > the single static board design.

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Simon Glass
Hi Stephen, On Tue, Mar 20, 2012 at 5:42 PM, Stephen Warren wrote: > On 03/20/2012 05:33 PM, Simon Glass wrote: > ... >> We cannot select the UART via CONFIG - remember that all of these >> boards have the same U-Boot binary. Please read that again :-) The >> device tree is the only thing that di

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Graeme Russ
Hi Stehpen, On Wed, Mar 21, 2012 at 12:18 PM, Simon Glass wrote: > Hi Graeme, > > On Tue, Mar 20, 2012 at 5:39 PM, Graeme Russ wrote: >> Hi Simon >> >> On Wed, Mar 21, 2012 at 11:19 AM, Simon Glass wrote: >>> Hi Graeme, >>> >>> On Tue, Mar 20, 2012 at 5:17 PM, Graeme Russ wrote: Hi Simon,

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Simon Glass
Hi Graeme, On Tue, Mar 20, 2012 at 5:39 PM, Graeme Russ wrote: > Hi Simon > > On Wed, Mar 21, 2012 at 11:19 AM, Simon Glass wrote: >> Hi Graeme, >> >> On Tue, Mar 20, 2012 at 5:17 PM, Graeme Russ wrote: >>> Hi Simon, > >>> And we are talking about one board vendor taking a SoC and using UARTA >

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Stephen Warren
On 03/20/2012 05:33 PM, Simon Glass wrote: ... > We cannot select the UART via CONFIG - remember that all of these > boards have the same U-Boot binary. Please read that again :-) The > device tree is the only thing that distinguishes them. All of the > CONFIG options are identical for all boards.

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Graeme Russ
Hi Simon On Wed, Mar 21, 2012 at 11:19 AM, Simon Glass wrote: > Hi Graeme, > > On Tue, Mar 20, 2012 at 5:17 PM, Graeme Russ wrote: >> Hi Simon, >> And we are talking about one board vendor taking a SoC and using UARTA >> for the panic output and another board vendor deciding to use UARTB - But

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Simon Glass
Hi Graeme, On Tue, Mar 20, 2012 at 5:17 PM, Graeme Russ wrote: > Hi Simon, > > On Wed, Mar 21, 2012 at 11:02 AM, Simon Glass wrote: >> Hi Graeme, >> >> On Tue, Mar 20, 2012 at 4:52 PM, Graeme Russ wrote: >>> Hi Simon, >>> >>> On Wed, Mar 21, 2012 at 10:33 AM, Simon Glass wrote: > We canno

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Graeme Russ
Hi Simon, On Wed, Mar 21, 2012 at 11:02 AM, Simon Glass wrote: > Hi Graeme, > > On Tue, Mar 20, 2012 at 4:52 PM, Graeme Russ wrote: >> Hi Simon, >> >> On Wed, Mar 21, 2012 at 10:33 AM, Simon Glass wrote: >>> We cannot select the UART via CONFIG - remember that all of these >>> boards have the

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Simon Glass
Hi Graeme, On Tue, Mar 20, 2012 at 4:52 PM, Graeme Russ wrote: > Hi Simon, > > On Wed, Mar 21, 2012 at 10:33 AM, Simon Glass wrote: >> Hi Graeme, >> >> On Tue, Mar 20, 2012 at 4:28 PM, Graeme Russ wrote: >>> Hi Stephen, Simon, >>> >>> On Wed, Mar 21, 2012 at 8:17 AM, Stephen Warren >>> wrote:

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Graeme Russ
Hi Simon, On Wed, Mar 21, 2012 at 10:33 AM, Simon Glass wrote: > Hi Graeme, > > On Tue, Mar 20, 2012 at 4:28 PM, Graeme Russ wrote: >> Hi Stephen, Simon, >> >> On Wed, Mar 21, 2012 at 8:17 AM, Stephen Warren >> wrote: >>> On 03/20/2012 02:13 PM, Simon Glass wrote: Hi Stephen, On

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Simon Glass
Hi Graeme, On Tue, Mar 20, 2012 at 4:28 PM, Graeme Russ wrote: > Hi Stephen, Simon, > > On Wed, Mar 21, 2012 at 8:17 AM, Stephen Warren wrote: >> On 03/20/2012 02:13 PM, Simon Glass wrote: >>> Hi Stephen, >>> >>> On Tue, Mar 20, 2012 at 12:57 PM, Stephen Warren >>> wrote: This works toget

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Simon Glass
Hi Stephen, On Tue, Mar 20, 2012 at 2:17 PM, Stephen Warren wrote: > On 03/20/2012 02:13 PM, Simon Glass wrote: >> Hi Stephen, >> >> On Tue, Mar 20, 2012 at 12:57 PM, Stephen Warren >> wrote: >>> This works together with a kernel change that looks at the scratchpad >>> register to determine whi

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Graeme Russ
Hi Stephen, Simon, On Wed, Mar 21, 2012 at 8:17 AM, Stephen Warren wrote: > On 03/20/2012 02:13 PM, Simon Glass wrote: >> Hi Stephen, >> >> On Tue, Mar 20, 2012 at 12:57 PM, Stephen Warren >> wrote: >>> This works together with a kernel change that looks at the scratchpad >>> register to determ

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Stephen Warren
On 03/20/2012 02:13 PM, Simon Glass wrote: > Hi Stephen, > > On Tue, Mar 20, 2012 at 12:57 PM, Stephen Warren > wrote: >> This works together with a kernel change that looks at the scratchpad >> register to determine which of the many UARTs it should use for early >> printing: >> >> http://www.s

Re: [U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Simon Glass
Hi Stephen, On Tue, Mar 20, 2012 at 12:57 PM, Stephen Warren wrote: > This works together with a kernel change that looks at the scratchpad > register to determine which of the many UARTs it should use for early > printing: > > http://www.spinics.net/lists/arm-kernel/msg154633.html > > Note that

[U-Boot] [PATCH] tegra: Specify debugging serial port at boot.

2012-03-20 Thread Stephen Warren
This works together with a kernel change that looks at the scratchpad register to determine which of the many UARTs it should use for early printing: http://www.spinics.net/lists/arm-kernel/msg154633.html Note that this configuration only affects the kernel's decompressor and earlyprintk code. On