[U-Boot] [PATCH] nios2: configure STATUS_LED_BOOT

Thomas Chou thomas at wytron.com.tw
Sat Sep 5 15:04:02 CEST 2015


Define STATUS_LED_BOOT. So the boot LED will be initialized
in board_init_r(), and show the boot progress.

Though the boot LED is set to blinking in board_init_r(),
only the powerpc and nios2 really support blinking. All other
archs just turn the LED on and can not blink.

After the commit "nios2: Switch to generic timer", with the
removal of call to status_led_tick(), nios2 can not blink LED.
But it doesn't really matter, because U-Boot usually runs a very
short time. It should be enough to turn boot LED on and off
during boot process.

Signed-off-by: Thomas Chou <thomas at wytron.com.tw>
---
 include/configs/nios2-generic.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/include/configs/nios2-generic.h b/include/configs/nios2-generic.h
index 10f9a34..66ad2f0 100644
--- a/include/configs/nios2-generic.h
+++ b/include/configs/nios2-generic.h
@@ -58,8 +58,9 @@
 #define LED_PIO_RSTVAL			0xff
 
 #define STATUS_LED_BIT			0	/* Bit-0 on GPIO */
-#define STATUS_LED_STATE		1	/* Blinking */
+#define STATUS_LED_STATE		STATUS_LED_ON
 #define STATUS_LED_PERIOD	(CONFIG_SYS_HZ / 2)	/* 500 msec */
+#define STATUS_LED_BOOT			STATUS_LED_BIT
 
 /*
  * BOOTP options
-- 
2.1.4



More information about the U-Boot mailing list