summaryrefslogtreecommitdiff
path: root/arch/avr32
diff options
context:
space:
mode:
authorGraeme Russ <graeme.russ@gmail.com>2011-09-01 00:52:06 +0000
committerSimon Glass <sjg@chromium.org>2011-10-04 14:48:19 -0700
commit74e9c40925267986a64d174b8a82bb249e131c16 (patch)
tree3e7d5abb8588b018fe2593f4de68a156b5b9b583 /arch/avr32
parent56380ae05fc0b667d753528f764f3bb1144627c4 (diff)
console: Implement pre-console buffer
Allow redirection of console output prior to console initialisation to a temporary buffer. To enable this functionality, the board (or arch) must define: - CONFIG_PRE_CONSOLE_BUFFER - Enable pre-console buffer - CONFIG_PRE_CON_BUF_ADDR - Base address of pre-console buffer - CONFIG_PRE_CON_BUF_SZ - Size of pre-console buffer (in bytes) The pre-console buffer will buffer the last CONFIG_PRE_CON_BUF_SZ bytes Any earlier characters are silently dropped. Signed-off-by: Graeme Russ <graeme.russ@gmail.com> Change-Id: I3c4caad276b9e981ebea0a0fb79d85ee3a3bcb7d Reviewed-on: http://gerrit.chromium.org/gerrit/8686 Reviewed-by: Che-Liang Chiou <clchiou@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'arch/avr32')
-rw-r--r--arch/avr32/include/asm/global_data.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/avr32/include/asm/global_data.h b/arch/avr32/include/asm/global_data.h
index 4ef8fc570f..5c654bd5e0 100644
--- a/arch/avr32/include/asm/global_data.h
+++ b/arch/avr32/include/asm/global_data.h
@@ -38,6 +38,9 @@ typedef struct global_data {
unsigned long baudrate;
unsigned long stack_end; /* highest stack address */
unsigned long have_console; /* serial_init() was called */
+#ifdef CONFIG_PRE_CONSOLE_BUFFER
+ unsigned long precon_buf_idx; /* Pre-Console buffer index */
+#endif
unsigned long reloc_off; /* Relocation Offset */
unsigned long env_addr; /* Address of env struct */
unsigned long env_valid; /* Checksum of env valid? */