Add board_name to CONFIG_ENV_VARS_UBOOT_CONFIG
authorStephen Warren <swarren@nvidia.com>
Wed, 31 Oct 2012 11:17:28 +0000 (11:17 +0000)
committerTom Rini <trini@ti.com>
Fri, 2 Nov 2012 22:13:30 +0000 (15:13 -0700)
CONFIG_ENV_VARS_UBOOT_CONFIG creates environment variables indicating
which configuration U-Boot was built for. Some U-Boot binaries run on
multiple boards, and hence this information may not uniquley describe
the HW that U-Boot is actually running on. Another patch introduces
environment variable board_name to represent that. In order to avoid
scripts having to check $board_name, use it if set, and then fall back
to using $board, make CONFIG_ENV_VARS_UBOOT_CONFIG also set a default
value for board_name, so that variable is always available.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
include/env_default.h

index 375e5ca15ca12b2f61d548512b8c49adf4ea5e20..a1db73a2c559324c2360bded35188335a7da51ee 100644 (file)
@@ -118,6 +118,7 @@ const uchar default_environment[] = {
        "arch="         CONFIG_SYS_ARCH                 "\0"
        "cpu="          CONFIG_SYS_CPU                  "\0"
        "board="        CONFIG_SYS_BOARD                "\0"
+       "board_name="   CONFIG_SYS_BOARD                "\0"
 #ifdef CONFIG_SYS_VENDOR
        "vendor="       CONFIG_SYS_VENDOR               "\0"
 #endif