Skip to content

Commit

Permalink
Merge tag 'for-linus-20140507' of git://git.infradead.org/linux-mtd
Browse files Browse the repository at this point in the history
Pull MTD fix from Brian Norris:
 "A single update for Keystone SoC's, whose NAND controller does not
  support subpage programming"

* tag 'for-linus-20140507' of git://git.infradead.org/linux-mtd:
  mtd: davinci-nand: disable subpage write for keystone-nand
  • Loading branch information
Linus Torvalds committed May 7, 2014
2 parents 7ceeff4 + 28c015a commit 9f1eb57
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions drivers/mtd/nand/davinci_nand.c
Original file line number Diff line number Diff line change
Expand Up @@ -523,6 +523,7 @@ static struct nand_ecclayout hwecc4_2048 = {
#if defined(CONFIG_OF)
static const struct of_device_id davinci_nand_of_match[] = {
{.compatible = "ti,davinci-nand", },
{.compatible = "ti,keystone-nand", },
{},
};
MODULE_DEVICE_TABLE(of, davinci_nand_of_match);
Expand Down Expand Up @@ -581,6 +582,11 @@ static struct davinci_nand_pdata
of_property_read_bool(pdev->dev.of_node,
"ti,davinci-nand-use-bbt"))
pdata->bbt_options = NAND_BBT_USE_FLASH;

if (of_device_is_compatible(pdev->dev.of_node,
"ti,keystone-nand")) {
pdata->options |= NAND_NO_SUBPAGE_WRITE;
}
}

return dev_get_platdata(&pdev->dev);
Expand Down

0 comments on commit 9f1eb57

Please sign in to comment.