]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
Remove CONFIG_BOARDNAME and CONFIG_BOARD_NAME
authorTom Rini <trini@konsulko.com>
Tue, 22 Mar 2022 01:33:32 +0000 (21:33 -0400)
committerTom Rini <trini@konsulko.com>
Fri, 1 Apr 2022 14:28:46 +0000 (10:28 -0400)
Both of these variables are used in a few hard-coded ways to set some
string values or print something to the user.  In almost all cases, it's
just as useful to hard-code the value used.  The exception here is
printing something closer to correct board name for p1_p2_rdb machines.
This can be done using something from the device tree, but for now
hard-code a non-CONFIG based value instead.

Signed-off-by: Tom Rini <trini@konsulko.com>
board/freescale/p1_p2_rdb_pc/p1_p2_rdb_pc.c
board/ge/bx50v3/bx50v3.c
include/configs/T102xRDB.h
include/configs/el6x_common.h
include/configs/ge_bx50v3.h
include/configs/opos6uldev.h
include/configs/p1_p2_rdb_pc.h

index 19ece12296315cd1cb012d2654c12639b55524de..b6f0d2042677991d72ba602ca42de64ece52068a 100644 (file)
@@ -160,6 +160,14 @@ int board_early_init_f(void)
        return 0;
 }
 
+#if defined(CONFIG_TARGET_P1020RDB_PC)
+#define BOARD_NAME "P1020RDB-PC"
+#elif defined(CONFIG_TARGET_P1020RDB_PD)
+#define BOARD_NAME "P1020RDB-PD"
+#elif defined(CONFIG_TARGET_P2020RDB)
+#define BOARD_NAME "P2020RDB-PC"
+#endif
+
 int checkboard(void)
 {
        struct cpld_data *cpld_data = (void *)(CONFIG_SYS_CPLD_BASE);
@@ -167,7 +175,8 @@ int checkboard(void)
        u8 in, out, io_config, val;
        int bus_num = CONFIG_SYS_SPD_BUS_NUM;
 
-       printf("Board: %s CPLD: V%d.%d PCBA: V%d.0\n", CONFIG_BOARDNAME,
+       /* FIXME: This should just use the model from the device tree or similar */
+       printf("Board: %s CPLD: V%d.%d PCBA: V%d.0\n", BOARD_NAME,
                in_8(&cpld_data->cpld_rev_major) & 0x0F,
                in_8(&cpld_data->cpld_rev_minor) & 0x0F,
                in_8(&cpld_data->pcba_rev) & 0x0F);
index ed700f4e1da532eecb3ae3efbadb592d07d77232..4e9d841fe29169c7e9ad562c95a5860889633749 100644 (file)
@@ -547,7 +547,7 @@ int last_stage_init(void)
 
 int checkboard(void)
 {
-       printf("BOARD: %s\n", CONFIG_BOARD_NAME);
+       printf("BOARD: General Electric Bx50v3\n");
        return 0;
 }
 
index 1fa1fc09aaa78a34763ce842612f3ed0e6480c5e..d9c72a8d2fd52bbf0cb08065aa393f3c24ebdc7a 100644 (file)
 #define __USB_PHY_TYPE         utmi
 
 #ifdef CONFIG_ARCH_T1024
-#define CONFIG_BOARDNAME t1024rdb
-#define BANK_INTLV cs0_cs1
+#define ARCH_EXTRA_ENV_SETTINGS \
+       "bank_intlv=cs0_cs1\0"                  \
+       "ramdiskfile=t1024rdb/ramdisk.uboot\0"  \
+       "fdtfile=t1024rdb/t1024rdb.dtb\0"
 #else
-#define CONFIG_BOARDNAME t1023rdb
-#define BANK_INTLV  null
+#define ARCH_EXTRA_ENV_SETTINGS \
+       "bank_intlv=null\0"                     \
+       "ramdiskfile=t1023rdb/ramdisk.uboot\0"  \
+       "fdtfile=t1023rdb/t1023rdb.dtb\0"
 #endif
 
 #define        CONFIG_EXTRA_ENV_SETTINGS                               \
+       ARCH_EXTRA_ENV_SETTINGS                                 \
        "hwconfig=fsl_ddr:ctlr_intlv=cacheline,"                \
-       "bank_intlv=" __stringify(BANK_INTLV) "\0"              \
        "usb1:dr_mode=host,phy_type=" __stringify(__USB_PHY_TYPE) "\0"  \
-       "ramdiskfile=" __stringify(CONFIG_BOARDNAME) "/ramdisk.uboot\0" \
-       "fdtfile=" __stringify(CONFIG_BOARDNAME) "/"            \
-       __stringify(CONFIG_BOARDNAME) ".dtb\0"                  \
        "uboot=" __stringify(CONFIG_UBOOTPATH) "\0"             \
        "ubootaddr=" __stringify(CONFIG_SYS_TEXT_BASE) "\0"     \
        "bootargs=root=/dev/ram rw console=ttyS0,115200\0" \
index 4764d22520acb0ed8e239b01602ba6addf03c0fd..bcd7b84cf3828d833824f9f677fcc0ba9d99f177 100644 (file)
@@ -10,8 +10,6 @@
 
 #include <linux/stringify.h>
 
-#define CONFIG_BOARD_NAME              EL6Q
-
 #include "mx6_common.h"
 
 #ifdef CONFIG_SPL
 
 #define CONFIG_MXC_UART_BASE   UART2_BASE
 
-#define CONFIG_BOARD_NAME      EL6Q
-
 #define CONFIG_EXTRA_ENV_SETTINGS                                               \
-       "board="__stringify(CONFIG_BOARD_NAME)"\0"                              \
+       "board=EL6Q\0"                                                          \
        "cma_size="__stringify(EL6Q_CMA_SIZE)"\0"                               \
        "chp_size="__stringify(EL6Q_COHERENT_POOL_SIZE)"\0"                     \
        "console=" CONSOLE_DEV "\0"                                     \
index 402c5bfacbe37ea10c7bbc4249b045199db910d9..8d467e420f1ca15f0fdf40f3bf30b2249b3ad25d 100644 (file)
@@ -14,8 +14,6 @@
 #include <asm/arch/imx-regs.h>
 #include <asm/mach-imx/gpio.h>
 
-#define CONFIG_BOARD_NAME      "General Electric Bx50v3"
-
 #include "mx6_common.h"
 #include <linux/sizes.h>
 
index a27093fc9551de0e8a0c313b65a3cc1a207ca897..1f2887105fff5cad93fe3b34daffe6a45276c275 100644 (file)
 /* Environment is stored in the eMMC boot partition */
 
 #define CONFIG_ENV_VERSION     100
-#define CONFIG_BOARD_NAME      opos6ul
 #define ACFG_CONSOLE_DEV        ttymxc0
 #define CONFIG_SYS_AUTOLOAD     "no"
-#define CONFIG_ROOTPATH         "/tftpboot/" __stringify(CONFIG_BOARD_NAME) "-root"
+#define CONFIG_ROOTPATH         "/tftpboot/opos6ul-root"
 
 #define CONFIG_EXTRA_ENV_SETTINGS \
        "env_version="          __stringify(CONFIG_ENV_VERSION)         "\0"                    \
        "consoledev="           __stringify(ACFG_CONSOLE_DEV)           "\0"                    \
-       "board_name="           __stringify(CONFIG_BOARD_NAME)          "\0"                    \
+       "board_name=opos6ul\0"                                                                  \
        "fdt_addr=0x88000000\0"                                                                 \
        "fdt_high=0xffffffff\0"                                                                 \
-       "fdt_name="           __stringify(CONFIG_BOARD_NAME)          "dev\0"                   \
+       "fdt_name=opos6uldev\0"                                                                 \
        "initrd_high=0xffffffff\0"                                                              \
        "ip_dyn=yes\0"                                                                          \
        "stdin=serial\0"                                                                        \
@@ -65,7 +64,7 @@
        "mmcpart=2\0"                                                                           \
        "mmcroot=/dev/mmcblk0p2 ro\0"                                                           \
        "mmcrootfstype=ext4 rootwait\0"                                                         \
-       "kernelimg="           __stringify(CONFIG_BOARD_NAME)          "-linux.bin\0"           \
+       "kernelimg=opos6ul-linux.bin\0"                                                         \
        "splashpos=0,0\0"                                                                       \
        "splashimage="          __stringify(CONFIG_SYS_LOAD_ADDR)       "\0"                    \
        "videomode=video=ctfb:x:800,y:480,depth:18,pclk:33033,le:96,ri:96,up:20,lo:21,hs:64,vs:4,sync:0,vmode:0\0" \
index 64a5269076af1d1b9a3be9ad1cb1ea64094d791d..a6523753d5cadf0fd29a8e5f7cb915a7f1a6ec15 100644 (file)
@@ -13,7 +13,6 @@
 #include <linux/stringify.h>
 
 #if defined(CONFIG_TARGET_P1020RDB_PC)
-#define CONFIG_BOARDNAME "P1020RDB-PC"
 #define CONFIG_VSC7385_ENET
 #define CONFIG_SLIC
 #define __SW_BOOT_MASK         0x03
@@ -39,7 +38,6 @@
  * 011101 800 800 400 667 PCIe-2 Core0 boot; Core1 hold-off
  */
 #if defined(CONFIG_TARGET_P1020RDB_PD)
-#define CONFIG_BOARDNAME "P1020RDB-PD"
 #define CONFIG_VSC7385_ENET
 #define CONFIG_SLIC
 #define __SW_BOOT_MASK         0x03
@@ -55,7 +53,6 @@
 #endif
 
 #if defined(CONFIG_TARGET_P2020RDB)
-#define CONFIG_BOARDNAME "P2020RDB-PC"
 #define CONFIG_VSC7385_ENET
 #define __SW_BOOT_MASK         0x03
 #define __SW_BOOT_NOR          0xc8