After seeing a presentation on RAUC at FOSDEM I've been looking to integrate it with a Yocto based i.mx6 embedded system that I'm working on.

Everything is pretty much working but I'm just trying to understand the integration with u-boot, I've based my u-boot scripts on the one in contrib from the RAUC repository. I've had to make some changes due to an old version of u-boot and quirks of our setup, however my questions are about the general process.

As I understand it, when the system boots, the first slot from BOOT_ORDER will be selected, say slot A. Then BOOT_A_LEFT will be decremented from 3 to 2 and we will save the environment to nand flash. Is it then intended that when the OS boots successfully it should change the BOOT_A_LEFT variable in nand flash back to 3?

Following on from that, if I'm correct, this seems like a lot of writes to nand flash. Writing to nand is also not that quick for us at 3.41 seconds from within Linux, is there not a reasonable chance of corruption if the system was reset during that write?

--
Philip Downer
+44 (0)7879 470 969
pdowner@prospero-tech.com