]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
mtd: ensure UBI is compiled when ENV_IS_IN_UBI is selected
authorMiquel Raynal <miquel.raynal@bootlin.com>
Thu, 3 Oct 2019 17:50:12 +0000 (19:50 +0200)
committerTom Rini <trini@konsulko.com>
Wed, 4 Dec 2019 18:26:17 +0000 (13:26 -0500)
UBI must be enabled when the environment is in UBI.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Boris Brezillon <boris.brezillon@bootlin.com>
configs/CHIP_pro_defconfig
env/Kconfig

index 02b51e3b641b09366d1701aa05d76bf217469d10..040a4c5895c2da633d126a7848cf986d993e5c91 100644 (file)
@@ -9,6 +9,7 @@ CONFIG_USE_PREBOOT=y
 CONFIG_SPL_I2C_SUPPORT=y
 # CONFIG_CMD_FLASH is not set
 CONFIG_CMD_MTDPARTS=y
+CONFIG_CMD_UBI=y
 CONFIG_MTDIDS_DEFAULT="nand0=sunxi-nand.0"
 CONFIG_MTDPARTS_DEFAULT="mtdparts=sunxi-nand.0:256k(spl),256k(spl-backup),2m(uboot),2m(uboot-backup),-(UBI)"
 CONFIG_DEFAULT_DEVICE_TREE="sun5i-gr8-chip-pro"
@@ -18,6 +19,7 @@ CONFIG_ENV_UBI_VOLUME="uboot-env"
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 # CONFIG_MMC is not set
 CONFIG_MTD_RAW_NAND=y
+CONFIG_MTD_UBI=y
 CONFIG_SYS_NAND_BLOCK_SIZE=0x40000
 CONFIG_SYS_NAND_PAGE_SIZE=0x1000
 CONFIG_SYS_NAND_OOBSIZE=0x100
index bc88c59cd54d1050bd24abc115e5579e6274743b..ed12609f6a5f01b638438a40c2508725b46accd7 100644 (file)
@@ -366,6 +366,8 @@ config ENV_SPI_MODE
 config ENV_IS_IN_UBI
        bool "Environment in a UBI volume"
        depends on !CHAIN_OF_TRUST
+       depends on MTD_UBI
+       depends on CMD_UBI
        help
          Define this if you have an UBI volume that you want to use for the
          environment.  This has the benefit of wear-leveling the environment