From e76959aba50811c2aec70fe86561b7eaad85d0d6 Mon Sep 17 00:00:00 2001 From: Roger Quadros Date: Thu, 11 Jan 2024 15:19:19 +0200 Subject: [PATCH] mtd: rawnand: omap_gpmc: fix OF based partition parsing for NAND Set NAND chip ofnode and device so OF based partition parsing can work. Signed-off-by: Roger Quadros Link: https://www.mail-archive.com/u-boot@lists.denx.de/msg499178.html Signed-off-by: Dario Binacchi --- drivers/mtd/nand/raw/omap_gpmc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/mtd/nand/raw/omap_gpmc.c b/drivers/mtd/nand/raw/omap_gpmc.c index c430f6d31c..2f8fa7d73d 100644 --- a/drivers/mtd/nand/raw/omap_gpmc.c +++ b/drivers/mtd/nand/raw/omap_gpmc.c @@ -1189,6 +1189,8 @@ static int gpmc_nand_probe(struct udevice *dev) base = devm_ioremap(dev, res.start, resource_size(&res)); gpmc_nand_init(nand, base); + mtd->dev = dev; + nand_set_flash_node(nand, dev_ofnode(dev)); ret = nand_scan(mtd, CONFIG_SYS_NAND_MAX_CHIPS); if (ret) -- 2.39.5