when flashing, only need to erase the space we're writing

This commit is contained in:
Daniel Barlow 2023-03-18 14:50:09 +00:00
parent 3c6ec354ce
commit b85492c744

View file

@ -56,7 +56,7 @@ in {
setenv serverip ${tftp.serverip}
setenv ipaddr ${tftp.ipaddr}
tftp 0x$(printf %x ${tftp.loadAddress}) result/firmware.bin
erase 0x$(printf %x ${flash.address}) +0x$(printf %x ${flash.size})
erase 0x$(printf %x ${flash.address}) +\''${filesize})
cp.b 0x$(printf %x ${tftp.loadAddress}) 0x$(printf %x ${flash.address}) \''${filesize}
echo command line was ${builtins.toJSON (concatStringsSep " " config.boot.commandLine)}
EOF