From: Simon Glass Date: Wed, 11 Dec 2019 17:47:21 -0700 Subject: [PATCH 02/35] common: Move main_loop() to init.h In-Reply-To: <20191212004755.11091-2-sjg@chromium.org> References: <20191212004755.11091-2-sjg@chromium.org> Message-ID: <20191212004755.11091-3-sjg@chromium.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Move this function out of common.h and into a better place. Signed-off-by: Simon Glass --- common/board_r.c | 1 + common/main.c | 1 + include/common.h | 3 --- include/init.h | 7 +++++++ 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/common/board_r.c b/common/board_r.c index 5464172259..cda90bd385 100644 --- a/common/board_r.c +++ b/common/board_r.c @@ -25,6 +25,7 @@ #include #include #include +#include #include #if defined(CONFIG_CMD_KGDB) #include diff --git a/common/main.c b/common/main.c index a94df7ae04..ec8994ad45 100644 --- a/common/main.c +++ b/common/main.c @@ -12,6 +12,7 @@ #include #include #include +#include #include /* diff --git a/include/common.h b/include/common.h index fecfa27747..f1a3d32547 100644 --- a/include/common.h +++ b/include/common.h @@ -64,9 +64,6 @@ void hang (void) __attribute__ ((noreturn)); #include -/* common/main.c */ -void main_loop (void); - int checkflash(void); int checkdram(void); extern u8 __dtb_dt_begin[]; /* embedded device tree blob */ diff --git a/include/init.h b/include/init.h index 8b65b2afe4..105afc6c3c 100644 --- a/include/init.h +++ b/include/init.h @@ -210,6 +210,13 @@ void pci_init_board(void); void trap_init(unsigned long reloc_addr); +/** + * main_loop() - Enter the main loop of U-Boot + * + * This normally runs the command line. + */ +void main_loop(void); + #endif /* __ASSEMBLY__ */ /* Put only stuff here that the assembler can digest */ -- 2.24.0.525.g8f36a354ae-goog