Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --- u-boot/board/sunxi/board.c 2016-08-24 12:16:55.454029885 +0200
- +++ u-boot.patched/board/sunxi/board.c 2016-08-24 12:00:16.000000000 +0200
- @@ -618,9 +618,7 @@ static void setup_environment(const void
- {
- char serial_string[17] = { 0 };
- unsigned int sid[4];
- - uint8_t mac_addr[6];
- - char ethaddr[16];
- - int i, ret;
- + int ret;
- ret = sunxi_get_sid(sid);
- if (ret == 0 && sid[0] != 0) {
- @@ -645,6 +643,10 @@ static void setup_environment(const void
- if ((sid[3] & 0xffffff) == 0)
- sid[3] |= 0x800000;
- +#if defined(CONFIG_CMD_NET)
- + uint8_t mac_addr[6];
- + char ethaddr[16];
- + int i;
- for (i = 0; i < 4; i++) {
- sprintf(ethaddr, "ethernet%d", i);
- if (!fdt_get_alias(fdt, ethaddr))
- @@ -668,6 +670,7 @@ static void setup_environment(const void
- eth_setenv_enetaddr(ethaddr, mac_addr);
- }
- +#endif
- if (!getenv("serial#")) {
- snprintf(serial_string, sizeof(serial_string),
- --- u-boot/include/configs/sunxi-common.h 2016-08-24 12:16:55.774029888 +0200
- +++ u-boot.patched/include/configs/sunxi-common.h 2016-08-24 11:50:59.000000000 +0200
- @@ -497,7 +497,14 @@ extern int soft_i2c_gpio_scl;
- "ext2load mmc 0 0x48000000 uImage && " \
- "bootm 0x48000000\0"
- #else
- -#define BOOTCMD_SUNXI_COMPAT
- +#define BOOTCMD_SUNXI_COMPAT \
- + "bootcmd_sunxi=" \
- + "if load mmc 0 0x44000000 uEnv.txt; then " \
- + "echo Loaded environment from uEnv.txt; " \
- + "env import -t 0x44000000 ${filesize}; " \
- + "fi;" \
- + "run bootcmd;\0"
- +#define CONFIG_BOOTCOMMAND "run bootcmd_sunxi"
- #endif
- #include <config_distro_bootcmd.h>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement