From: Liang Yang Date: Thu, 21 Mar 2019 12:14:01 +0000 (+0800) Subject: mtd: rawnand: meson: set oob layout ops X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=d090c25028e9df186bb0d31379f7d5605c57fa79;p=openwrt%2Fstaging%2Fblogic.git mtd: rawnand: meson: set oob layout ops Specify the oob layout operation to avoid no oob scheme defined for some nand flash. Fixes: 8fae856c5350 ("mtd: rawnand: meson: add support for Amlogic NAND flash controller") Signed-off-by: Liang Yang Tested-by: Martin Blumenstingl Signed-off-by: Miquel Raynal --- diff --git a/drivers/mtd/nand/raw/meson_nand.c b/drivers/mtd/nand/raw/meson_nand.c index 38db4fd61459..cb0b03e36a35 100644 --- a/drivers/mtd/nand/raw/meson_nand.c +++ b/drivers/mtd/nand/raw/meson_nand.c @@ -1188,6 +1188,8 @@ static int meson_nand_attach_chip(struct nand_chip *nand) return -EINVAL; } + mtd_set_ooblayout(mtd, &meson_ooblayout_ops); + ret = meson_nand_bch_mode(nand); if (ret) return -EINVAL;