pcm052: board: Add code to setup LED default states
authorLukasz Majewski <lukma@denx.de>
Wed, 13 Feb 2019 21:46:57 +0000 (22:46 +0100)
committerStefano Babic <sbabic@denx.de>
Sat, 13 Apr 2019 18:30:08 +0000 (20:30 +0200)
As one has moved to DM based LEDs, this code is required to setup the
default state.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
board/phytec/pcm052/pcm052.c

index d4f170a5034b7dccd228b984441eb5760ce09f9d..721e25105a321e0edd4685015499f7c00de8f626 100644 (file)
@@ -13,6 +13,7 @@
 #include <asm/arch/ddrmc-vf610.h>
 #include <asm/arch/crm_regs.h>
 #include <asm/arch/clock.h>
+#include <led.h>
 #include <environment.h>
 
 DECLARE_GLOBAL_DATA_PTR;
@@ -314,6 +315,9 @@ int board_late_init(void)
        struct src *psrc = (struct src *)SRC_BASE_ADDR;
        u32 reg;
 
+       if (IS_ENABLED(CONFIG_LED))
+               led_default_state();
+
        /*
         * BK4r1 handle emergency/service SD card boot
         * Checking the SBMR1 register BOOTCFG1 byte: