command: Remove the cmd_tbl_t typedef
[oweals/u-boot.git] / arch / m68k / lib / bootm.c
index fa9c4930814e470a058419ded5878386c246bd6b..b912d130d6ad401f2e73605260871f61022db997 100644 (file)
@@ -1,17 +1,18 @@
+// SPDX-License-Identifier: GPL-2.0+
 /*
  * (C) Copyright 2003
  * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #include <common.h>
+#include <bootstage.h>
 #include <command.h>
+#include <env.h>
 #include <image.h>
+#include <lmb.h>
 #include <u-boot/zlib.h>
 #include <bzlib.h>
 #include <watchdog.h>
-#include <environment.h>
 #include <asm/byteorder.h>
 #ifdef CONFIG_SHOW_BOOT_PROGRESS
 # include <status_led.h>
@@ -48,7 +49,8 @@ void arch_lmb_reserve(struct lmb *lmb)
        lmb_reserve(lmb, sp, (CONFIG_SYS_SDRAM_BASE + gd->ram_size - sp));
 }
 
-int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *images)
+int do_bootm_linux(int flag, int argc, char *const argv[],
+                  bootm_headers_t *images)
 {
        int ret;
        bd_t  *kbd;
@@ -113,7 +115,8 @@ static void set_clocks_in_mhz (bd_t *kbd)
 {
        char *s;
 
-       if ((s = getenv("clocks_in_mhz")) != NULL) {
+       s = env_get("clocks_in_mhz");
+       if (s) {
                /* convert all clock information to MHz */
                kbd->bi_intfreq /= 1000000L;
                kbd->bi_busfreq /= 1000000L;