Skip to content

Commit 28c015a

Browse files
Murali Karichericomputersforpeace
authored andcommitted
mtd: davinci-nand: disable subpage write for keystone-nand
Sub page write doesn't work because of hw issue in controller found on Keystone SOCs. AEMIF controller is also used on DaVinci SOCs which don't seems to have any issue. So add "ti,keysone-nand" compatible to nand driver in order to set NAND_NO_SUBPAGE_WRITE option. Cc: Warner Losh <[email protected]> Signed-off-by: Murali Karicheri <[email protected]> Signed-off-by: Ivan Khoronzhuk <[email protected]> Acked-by: Santosh Shilimkar <[email protected]> Signed-off-by: Brian Norris <[email protected]>
1 parent c9eaa44 commit 28c015a

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

drivers/mtd/nand/davinci_nand.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -523,6 +523,7 @@ static struct nand_ecclayout hwecc4_2048 = {
523523
#if defined(CONFIG_OF)
524524
static const struct of_device_id davinci_nand_of_match[] = {
525525
{.compatible = "ti,davinci-nand", },
526+
{.compatible = "ti,keystone-nand", },
526527
{},
527528
};
528529
MODULE_DEVICE_TABLE(of, davinci_nand_of_match);
@@ -581,6 +582,11 @@ static struct davinci_nand_pdata
581582
of_property_read_bool(pdev->dev.of_node,
582583
"ti,davinci-nand-use-bbt"))
583584
pdata->bbt_options = NAND_BBT_USE_FLASH;
585+
586+
if (of_device_is_compatible(pdev->dev.of_node,
587+
"ti,keystone-nand")) {
588+
pdata->options |= NAND_NO_SUBPAGE_WRITE;
589+
}
584590
}
585591

586592
return dev_get_platdata(&pdev->dev);

0 commit comments

Comments
 (0)