diff mbox

[U-Boot,v2,22/24] intern: disable lcd-stdout

Message ID OFAF752F63.287DD673-ONC1257DE1.0044A1EB-C1257DE1.0044BE35@br-automation.com
State Rejected
Headers show

Commit Message

Hannes Schmelzer Feb. 3, 2015, 12:30 p.m. UTC
Hi all,

please ignore this "internal" patch.
This is was an accident.

best regards,
Hannes



From:   Hannes Petermaier <oe5hpm@oevsv.at>
To:     u-boot@lists.denx.de
Date:   03.02.2015 13:26
Subject:        [U-Boot] [PATCH v2 22/24] intern: disable lcd-stdout
Sent by:        "U-Boot" <u-boot-bounces@lists.denx.de>



on B&R boards we want not redirect console to screen.

Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at>

---
Changes for V2: None
---
 README       |    7 +++++++
 common/lcd.c |   10 ++++++----
 2 files changed, 13 insertions(+), 4 deletions(-)

                 memset(&lcddev, 0, sizeof(lcddev));
@@ -213,6 +212,9 @@ int drv_lcd_init(void)
                 rc = stdio_register(&lcddev);
 
                 return (rc == 0) ? 1 : rc;
+#else
+                return 0;
+#endif
 }
 
 
/*----------------------------------------------------------------------*/
diff mbox

Patch

diff --git a/README b/README
index fefa71c..8f9865c 100644
--- a/README
+++ b/README
@@ -1959,6 +1959,13 @@  CBFS (Coreboot Filesystem) support
                                 Normally display is black on white 
background; define
                                 CONFIG_SYS_WHITE_ON_BLACK to get it 
inverted.
 
+                                CONFIG_LCD_NOSTDOUT
+                                Normally 'stdout' is redirected to 
LCD-screen after
+                                initialization. Define 
CONFIG_LCD_NOSTDOUT to avoid this.
+                                Useful in case where only lcd_puts(...), 
lcd_printf(...)
+                                functions of the framework are used and 
'normal' u-boot
+                                console remains e.g. on serial-line.
+
                                 CONFIG_LCD_ALIGNMENT
 
                                 Normally the LCD is page-aligned 
(typically 4KB). If this is
diff --git a/common/lcd.c b/common/lcd.c
index cc34b8a..3ed6d20 100644
--- a/common/lcd.c
+++ b/common/lcd.c
@@ -194,12 +194,11 @@  __weak int lcd_get_size(int *line_length)
 
 int drv_lcd_init(void)
 {
-                struct stdio_dev lcddev;
-                int rc;
-
                 lcd_base = map_sysmem(gd->fb_base, 0);
-
                 lcd_init(lcd_base);                             /* LCD 
initialization */
+#ifndef CONFIG_LCD_NOSTDOUT
+                struct stdio_dev lcddev;
+                int rc;
 
                 /* Device initialization */