Skip to content

Commit

Permalink
ARM: OMAP2+: Convert NAND to retrieve GPMC settings from DT
Browse files Browse the repository at this point in the history
When booting with device-tree, retrieve GPMC settings for NAND from
the device-tree blob. This will allow us to remove all static settings
stored in the gpmc-nand.c in the future once the migration to
device-tree is complete.

Signed-off-by: Jon Hunter <jon-hunter@ti.com>
Tested-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
  • Loading branch information
Jon Hunter committed Apr 4, 2013
1 parent cdd6928 commit acc7998
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions arch/arm/mach-omap2/gpmc-nand.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,12 +137,16 @@ int gpmc_nand_init(struct omap_nand_platform_data *gpmc_nand_data,
return err;
}

s.device_nand = true;

/* Enable RD PIN Monitoring Reg */
if (gpmc_nand_data->dev_ready) {
s.wait_on_read = true;
s.wait_on_write = true;
if (gpmc_nand_data->of_node) {
gpmc_read_settings_dt(gpmc_nand_data->of_node, &s);
} else {
s.device_nand = true;

/* Enable RD PIN Monitoring Reg */
if (gpmc_nand_data->dev_ready) {
s.wait_on_read = true;
s.wait_on_write = true;
}
}

if (gpmc_nand_data->devsize == NAND_BUSWIDTH_16)
Expand Down

0 comments on commit acc7998

Please sign in to comment.