]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
mtd: rawnand: mxs_nand: Fix use_minimum_ecc for spl driver
authorYe Li <ye.li@nxp.com>
Thu, 31 Mar 2022 05:27:47 +0000 (13:27 +0800)
committerStefano Babic <sbabic@denx.de>
Thu, 19 May 2022 19:39:36 +0000 (21:39 +0200)
Because mxs_nand_spl driver does not support DM, to use the minimum ECC
layout, it needs to handle the CONFIG_NAND_MXS_USE_MINIMUM_ECC.

Signed-off-by: Ye Li <ye.li@nxp.com>
Reviewed-by: Han Xu <han.xu@nxp.com>
drivers/mtd/nand/raw/mxs_nand.c

index ee5d7fde9ce1087cd31588883623dde6ee029adf..0c4e5595a7bb6880a2eaf6b6cc0600722e3a6562 100644 (file)
@@ -1380,6 +1380,9 @@ int mxs_nand_init_spl(struct nand_chip *nand)
        else
                nand_info->max_ecc_strength_supported = 40;
 
+       if (IS_ENABLED(CONFIG_NAND_MXS_USE_MINIMUM_ECC))
+               nand_info->use_minimum_ecc = true;
+
        err = mxs_nand_alloc_buffers(nand_info);
        if (err)
                return err;