From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Warren Date: Tue, 20 Mar 2012 18:34:56 -0600 Subject: [U-Boot] [PATCH 2/5] Add board_panic_no_console() to deal with early critical errors In-Reply-To: References: <1332188824-5447-1-git-send-email-sjg@chromium.org> <1332188824-5447-2-git-send-email-sjg@chromium.org> Message-ID: <4F692230.4010509@wwwdotorg.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 03/20/2012 05:22 PM, Simon Glass wrote: > On Tue, Mar 20, 2012 at 3:26 PM, Graeme Russ wrote: ... >> OK, so what about in panic(): >> - If gd->have_console is not set: >> o call the board specific setup_panic_uarts() >> o call print_pre_console_buffer() passing panic_putc() >> o call panic_putc() for all characters in str[] >> - If gd->have_console is set: >> o call putc() for all characters in str[] >> >> setup_panic_uarts() and panic_putc() are overriden in the board files > > I think this is where we got to last time. > > The act of calling this pre-console panic function is destructive - it > may hang the board and output data to UARTs. Why would it hang? Well, I assume you're talking about hanging before actually emitting the panic text, rather than looping afterwards as a deliberate choice. I'd consider an accidental hang that prevented the message being seen as a bug.