On Sat, Jun 25, 2022 at 10:10:08AM +0200, Kegl Rohit wrote: > Hello! > > Is it possible to store the environment inside a mtd partition when > using a single qspi nand chip as storage? > CONFIG_MTD_SPI_NAND=y > > The idea is to separate the NAND into two system A/B. > [...] > > CONFIG_ENV_IS_IN_UBI will do badblock handling, but it would be a huge > overhead to create an extra ubifs mtd partition only for the > environment.
Actually it's not. The overhead of allocating a UBI volume is minimal and typical logical block sizes are small enough to not be complete overkill for something like a U-Boot environment. > > > Has anyone already created the A/B system approach with the mtd spi > nand interface and can give me some input? Maybe see here for inspiration: https://git.openwrt.org/?p=openwrt/openwrt.git;a=blob;f=package/boot/uboot-mediatek/patches/410-add-linksys-e8450.patch;h=fde679f3863ccf2e22a3e1fd299963b66041a0b9;hb=HEAD#l403