Convert CONFIG_MISC_INIT_R to Kconfig
[oweals/u-boot.git] / include / configs / km / km83xx-common.h
index 5e075c8dd2a0bfe023cd978640ef8f61a1944cb4..337a9cec6621c9f474d094d16194ace0acf264db 100644 (file)
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
 /*
  * (C) Copyright 2010
  * Heiko Schocher, DENX Software Engineering, hs@denx.de.
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #ifndef __CONFIG_KM83XX_H
 #include "keymile-common.h"
 #include "km-powerpc.h"
 
-#ifndef MTDIDS_DEFAULT
-# define MTDIDS_DEFAULT        "nor0=boot"
-#endif /* MTDIDS_DEFAULT */
-
-#ifndef MTDPARTS_DEFAULT
-# define MTDPARTS_DEFAULT      "mtdparts="                     \
-       "boot:"                                                 \
-               "768k(u-boot),"                                 \
-               "128k(env),"                                    \
-               "128k(envred),"                                 \
-               "-(" CONFIG_KM_UBI_PARTITION_NAME_BOOT ");"
-#endif /* MTDPARTS_DEFAULT */
-
-#define CONFIG_MISC_INIT_R
 /*
  * System Clock Setup
  */
@@ -84,7 +69,6 @@
 #define CONFIG_SYS_INIT_RAM_LOCK
 #define CONFIG_SYS_INIT_RAM_ADDR       0xE6000000 /* Initial RAM address */
 #define CONFIG_SYS_INIT_RAM_SIZE       0x1000 /* End of used area in RAM */
-#define CONFIG_SYS_GBL_DATA_SIZE       0x100 /* num bytes initial data */
 #define CONFIG_SYS_GBL_DATA_OFFSET     (CONFIG_SYS_INIT_RAM_SIZE - \
                                                GENERATED_GBL_DATA_SIZE)
 
 /*
  * Serial Port
  */
-#define CONFIG_CONS_INDEX      1
-#define CONFIG_SYS_NS16550
 #define CONFIG_SYS_NS16550_SERIAL
 #define CONFIG_SYS_NS16550_REG_SIZE    1
 #define CONFIG_SYS_NS16550_CLK         get_bus_freq(0)
 #define CONFIG_SYS_NS16550_COM1        (CONFIG_SYS_IMMR+0x4500)
 #define CONFIG_SYS_NS16550_COM2        (CONFIG_SYS_IMMR+0x4600)
 
-/* Pass open firmware flat tree */
-#define CONFIG_OF_LIBFDT
-#define CONFIG_OF_BOARD_SETUP
-#define CONFIG_OF_STDOUT_VIA_ALIAS
-
 /*
  * QE UEC ethernet configuration
  */
  */
 
 #ifndef CONFIG_SYS_RAMBOOT
-#define CONFIG_ENV_IS_IN_FLASH
+#ifndef CONFIG_ENV_ADDR
 #define CONFIG_ENV_ADDR                (CONFIG_SYS_MONITOR_BASE + \
                                        CONFIG_SYS_MONITOR_LEN)
+#endif
 #define CONFIG_ENV_SECT_SIZE   0x20000 /* 128K(one sector) for env */
+#ifndef CONFIG_ENV_OFFSET
 #define CONFIG_ENV_OFFSET      (CONFIG_SYS_MONITOR_LEN)
+#endif
 
 /* Address and size of Redundant Environment Sector    */
 #define CONFIG_ENV_OFFSET_REDUND       (CONFIG_ENV_OFFSET + \
 #define CONFIG_ENV_SIZE_REDUND (CONFIG_ENV_SIZE)
 
 #else /* CFG_SYS_RAMBOOT */
-#define CONFIG_SYS_NO_FLASH            /* Flash is not usable now */
-#define CONFIG_ENV_IS_NOWHERE          /* Store ENV in memory only */
 #define CONFIG_ENV_ADDR                (CONFIG_SYS_MONITOR_BASE - 0x1000)
 #define CONFIG_ENV_SIZE                0x2000
 #endif /* CFG_SYS_RAMBOOT */
 
 #define CONFIG_KM_IVM_BUS              2       /* I2C2 (Mux-Port 1)*/
 
-/* I2C SYSMON (LM75, AD7414 is almost compatible) */
-#define CONFIG_DTT_LM75                /* ON Semi's LM75 */
-#define CONFIG_DTT_SENSORS     {0, 1, 2, 3}    /* Sensor addresses */
-#define CONFIG_SYS_DTT_MAX_TEMP        70
-#define CONFIG_SYS_DTT_HYSTERESIS      3
-#define CONFIG_SYS_DTT_BUS_NUM         1
-
 #if defined(CONFIG_CMD_NAND)
 #define CONFIG_NAND_KMETER1
 #define CONFIG_SYS_MAX_NAND_DEVICE     1
 #define CONFIG_SYS_NAND_BASE           CONFIG_SYS_KMBEC_FPGA_BASE
 #endif
 
-#if defined(CONFIG_PCI)
-#define CONFIG_CMD_PCI
-#endif
-
 /*
  * For booting Linux, the board info and command line data
  * have to be in the first 8 MB of memory, since this is
        CONFIG_KM_DEF_ENV                                               \
        CONFIG_KM_DEF_ARCH                                              \
        "newenv="                                                       \
-               "prot off 0xF00C0000 +0x40000 && "                      \
-               "era 0xF00C0000 +0x40000\0"                             \
+               "prot off "__stringify(CONFIG_ENV_ADDR)" +0x40000 && "  \
+               "era "__stringify(CONFIG_ENV_ADDR)" +0x40000\0"         \
        "unlock=yes\0"                                                  \
        ""