]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
distro_bootcmd: read DHCP boot script name from a variable
authorStephen Warren <swarren@nvidia.com>
Mon, 19 Jan 2015 23:39:11 +0000 (16:39 -0700)
committerTom Rini <trini@ti.com>
Fri, 30 Jan 2015 14:19:16 +0000 (09:19 -0500)
Modify $bootcmd_dhcp to read the downloaded script filename from an
environment variable rather than hard-coding it. This allows the user
(or another script) to select a different script name if they want,
without editing the whole value of $bootcmd_dhcp.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
include/config_distro_bootcmd.h

index 90ab21a7279af5fc5a4669df3464021dc1a6eedc..49674f4537541c6014cb2259976c21ee36dab2d3 100644 (file)
 #define BOOTENV_DEV_DHCP(devtypeu, devtypel, instance) \
        "bootcmd_dhcp=" \
                BOOTENV_RUN_USB_INIT \
-               "if dhcp ${scriptaddr} boot.scr.uimg; then " \
+               "if dhcp ${scriptaddr} ${boot_script_dhcp}; then " \
                        "source ${scriptaddr}; " \
                "fi\0"
 #define BOOTENV_DEV_NAME_DHCP(devtypeu, devtypel, instance) \
        BOOTENV_SHARED_IDE \
        "boot_prefixes=/ /boot/\0" \
        "boot_scripts=boot.scr.uimg boot.scr\0" \
+       "boot_script_dhcp=boot.scr.uimg\0" \
        BOOTENV_BOOT_TARGETS \
        \
        "boot_extlinux="                                                  \