diff --git a/u-boot/common/cmd_recovery.c b/u-boot/common/cmd_recovery.c index 4456cf8a0e..eaf873cd01 100644 --- a/u-boot/common/cmd_recovery.c +++ b/u-boot/common/cmd_recovery.c @@ -109,8 +109,7 @@ static int do_run_recovery(cmd_tbl_t *cmdtp, int flag, int argc, const char *arg BLINK_LED(5); status_led_set(0, STATUS_LED_ON); - rc = run_command("mtdpart default; " - "nand erase.part U-Boot-Environment", 0); + rc = run_command("erase 0x9f040000 +0x10000", 0); if (rc < 0) return env_failed(); @@ -119,18 +118,18 @@ static int do_run_recovery(cmd_tbl_t *cmdtp, int flag, int argc, const char *arg return dhcp_failed(); rc = run_command("setenv filesize 0; " - "tftp 85000000 sysmocom-recovery.ubi", 0); + "tftp 0x81000000 sysmocom-ap2-recovery", 0); if (rc < 0) { rc = run_command("setenv filesize 0; " "set serverip 255.255.255.255; " - "tftp 85000000 sysmocom-recovery.ubi", 0); + "tftp 0x81000000 sysmocom-ap2-recovery", 0); } if (rc < 0) return tftp_failed(); - rc = run_command("nand erase.part RootFs; " - "nand write 85000000 RootFs ${filesize} ", 0); + rc = run_command("erase 0x9f050000 +0x7a0000" + "cp.b 0x81000000 0x9f050000 +0x7a0000", 0); if (rc < 0) return flash_failed();