mtd: rename CONFIG_NAND -> CONFIG_MTD_RAW_NAND
[oweals/u-boot.git] / board / birdland / bav335x / board.c
index e174336e2c9c918dabfb697ebe18f6efc560c38b..9eb851c39763d60155e0733d70bc84713c6f8c29 100644 (file)
@@ -1,15 +1,17 @@
+// SPDX-License-Identifier: GPL-2.0+
 /*
  * board.c
  *
  * Board functions for Birdland Audio BAV335x Network Processor
  *
  * Copyright (c) 2012-2014 Birdland Audio - http://birdland.com/oem
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #include <common.h>
+#include <env.h>
 #include <errno.h>
+#include <init.h>
+#include <serial.h>
 #include <spl.h>
 #include <asm/arch/cpu.h>
 #include <asm/arch/hardware.h>
@@ -28,9 +30,8 @@
 #include <cpsw.h>
 #include <power/tps65217.h>
 #include <power/tps65910.h>
-#include <environment.h>
+#include <env_internal.h>
 #include <watchdog.h>
-#include <environment.h>
 #include "board.h"
 
 DECLARE_GLOBAL_DATA_PTR;
@@ -163,7 +164,7 @@ int spl_start_uboot(void)
 #ifdef CONFIG_SPL_ENV_SUPPORT
        env_init();
        env_load();
-       if (getenv_yesno("boot_os") != 1)
+       if (env_get_yesno("boot_os") != 1)
                return 1;
 #endif
 
@@ -291,7 +292,7 @@ int board_init(void)
 #endif
 
        gd->bd->bi_boot_params = CONFIG_SYS_SDRAM_BASE + 0x100;
-#if defined(CONFIG_NOR) || defined(CONFIG_NAND)
+#if defined(CONFIG_NOR) || defined(CONFIG_MTD_RAW_NAND)
        gpmc_init();
 #endif
        return 0;
@@ -360,7 +361,7 @@ static struct cpsw_platform_data cpsw_data = {
  * Build in only these cases to avoid warnings about unused variables
  * when we build an SPL that has neither option but full U-Boot will.
  */
-#if ((defined(CONFIG_SPL_ETH_SUPPORT) || defined(CONFIG_SPL_USBETH_SUPPORT)) &&\
+#if ((defined(CONFIG_SPL_ETH_SUPPORT) || defined(CONFIG_SPL_USB_ETHER)) &&\
                defined(CONFIG_SPL_BUILD)) || \
        ((defined(CONFIG_DRIVER_TI_CPSW) || \
          defined(CONFIG_USB_ETHER) && defined(CONFIG_USB_MUSB_GADGET)) && \