[PATCH v2] mtd: nand: ecc: Rework Kconfig dependencies

Miquel Raynal miquel.raynal at bootlin.com
Mon Jan 31 08:22:56 PST 2022


On Mon, 2022-01-31 at 14:50:32 UTC, Miquel Raynal wrote:
> Unlike "depends on", "select" does not enforce any type (y or m), which
> can lead to the following situation:
> * SPI_MXIC=y expects the NAND symbols to be built statically
> * SPI_MXIC depends on MTD_NAND_ECC
> * MTD_NAND_ECC selects MTD_NAND_CORE
> In this case MTD_NAND_CORE=m is "valid" but will trigger 'undefined
> reference' link errors.
> 
> The cleanest way to handle the situation is to use a "depends on"
> between MTD_NAND_ECC and MTD_NAND_CORE to avoid such situations.
> 
> While at modifying the MTD_NAND_ECC symbol, fix the spacing.
> 
> Signed-off-by: Miquel Raynal <miquel.raynal at bootlin.com>
> Reviewed-by: Pratyush Yadav <p.yadav at ti.com>

Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git spi-mem-ecc.

Miquel



More information about the linux-mtd mailing list