From a23d322ca1a4e72951971e3ceb8183c17e1dcb4e Mon Sep 17 00:00:00 2001 From: Gokul Sriram Palanisamy Date: Thu, 21 Dec 2017 11:50:24 +0530 Subject: [PATCH] eth: Moved eth_initialize to end of autoboot If autoboot command fails, it returns to prompt without ethernet initialized. Hence, moved it to the end of autoboot to make sure ethrernet is initialized before entering the prompt. Change-Id: I79ea6f51842c544e9eb3b97bf7658c45feb34f0b Signed-off-by: Gokul Sriram Palanisamy --- common/autoboot.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/common/autoboot.c b/common/autoboot.c index 49bc024602..21acfcf639 100644 --- a/common/autoboot.c +++ b/common/autoboot.c @@ -270,12 +270,6 @@ static int abortboot_normal(int bootdelay) #ifdef CONFIG_SILENT_CONSOLE if (abort) gd->flags &= ~GD_FLG_SILENT; -#endif -#ifdef CONFIG_IPQ_ETH_INIT_DEFER - if (abort) { - puts("\nNet: "); - eth_initialize(); - } #endif return abort; } @@ -382,4 +376,9 @@ void autoboot_command(const char *s) run_command_list(s, -1, 0); } #endif /* CONFIG_MENUKEY */ + +#ifdef CONFIG_IPQ_ETH_INIT_DEFER + puts("\nNet: "); + eth_initialize(); +#endif }