Soft bricked WAX620 - cannot restore

my attempts at getting decent performance out of this device with openWRT failed. When I tried to restore to stock, it died. I can get to uboot via serial, I can interact with it there. I can sent the initramFS for openwork to it and boot into that. but I cannot get it to retain anything I give it for the next boot. every boot, the first thing it does is erases its flash.

So now I cannot get back to factory and I cannot get to openWRT either.

initramFS shows partitions are still present. I just cant put anything into the rootfs or rootfs_1 partitions (mtd18 and mtd20) and expect it to still be there later. the nmrpflash tool doesnt work either. it just doesnt see the WAX620.

... because?

they don't boot. if I don't interrupt uboot, it just erases them and then complains it cant boot them

Serial recovery maybe??

I have serial on this but I cant figure out any kind of recovery strategy with that.

so it turns out, it lies! you can force it to boot just fine but you need to interrupt its boot 5 times, then permit boot on the 6th. you have to pull the power while uboot is doing its countdown to get it to notice how many times you have interrupted it

its not going back to stock, but at least its up again

I tried flashing back to stock from openWRT again. keeping with openwrt isn't a viable option as it just keeps flipping back and forth between partitions. I'm not able to convince it the last boot was successful so it just flips between the partitions.

I uses Sysupgrade -F to put the factory image back in but then it fails to boot again, even with the 5-6 interrupted boot thing. I see the following off serial when I try to boot again...

Erasing NAND...

Erasing at 0xd00000 --  25% complete.
Skipping bad block at  0x00d20000

Erasing at 0xd40000 --  75% complete.
Erasing at 0xd60000 -- 100% complete.

Writing to NAND... OK

ubi0: attaching mtd1

ubi0: scanning is finished

ubi0: attached mtd1 (name "mtd=0", size 60 MiB)

ubi0: PEB size: 131072 bytes (128 KiB), LEB size: 126976 bytes

ubi0: min./max. I/O unit sizes: 2048/2048, sub-page size 2048

ubi0: VID header offset: 2048 (aligned 2048), data offset: 4096

ubi0: good PEBs: 478, bad PEBs: 2, corrupted PEBs: 0

ubi0: user volume: 2, internal volumes: 1, max. volumes count: 128

ubi0: max/mean erase counter: 2/1, WL threshold: 4096, image sequence number: 969565451

ubi0: available PEBs: 0, total reserved PEBs: 478, PEBs reserved for bad PEB handling: 38

Read 0 bytes from volume kernel to 44000000

No size specified -> Using max size (46854144)

Config not availabale

Net:   MAC0 addr:80:cc:9c:4f:fa:df

PHY ID1: 0x4d

PHY ID2: 0xd101

EDMA ver 1 hw init

Num rings - TxDesc:1 (0-0) TxCmpl:1 (7-7)

RxDesc:1 (15-15) RxFill:1 (7-7)

ipq807x_edma_alloc_rings: successfull

ipq807x_edma_setup_ring_resources: successfull

ipq807x_edma_configure_rings: successfull

ipq807x_edma_hw_init: successfull

eth0

Net:   MAC0 addr:80:cc:9c:4f:fa:df

PHY ID1: 0x4d

PHY ID2: 0xd101

EDMA ver 1 hw init

Num rings - TxDesc:1 (0-0) TxCmpl:1 (7-7)

RxDesc:1 (15-15) RxFill:1 (7-7)

ipq807x_edma_alloc_rings: successfull

ipq807x_edma_setup_ring_resources: successfull

ipq807x_edma_configure_rings: successfull

ipq807x_edma_hw_init: successfull

, eth0

Warning: eth0 MAC addresses don't match:

Address in SROM is         80:cc:9c:4f:fa:df

Address in environment is  80:cc:9c:4f:fa:ef