aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2
diff options
context:
space:
mode:
authorRoger Quadros <rogerq@ti.com>2014-08-29 12:11:51 -0400
committerRoger Quadros <rogerq@ti.com>2014-10-30 11:20:58 -0400
commit7604baf365a3bd46007be6fbd2e43ac4a46ce928 (patch)
tree6a641978195f7aeb57e6d3122d7a805320e68a5e /arch/arm/mach-omap2
parent80323742eab6aca28ebe91cbca84a3d5ab940f4d (diff)
ARM: OMAP2+: gpmc: Error out if timings fail in gpmc_probe_generic_child()
gpmc_cs_set_timings() returns non-zero if there was an error while setting the GPMC timings. e.g. Timing was too large to be accomodated with current GPMC clock frequency and available timing range. Fail in this case, else we risk operating a NOR device with non compliant timings. Signed-off-by: Roger Quadros <rogerq@ti.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com> Acked-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2')
-rw-r--r--arch/arm/mach-omap2/gpmc.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/arch/arm/mach-omap2/gpmc.c b/arch/arm/mach-omap2/gpmc.c
index 45f680f965ed..f5d9dd256d63 100644
--- a/arch/arm/mach-omap2/gpmc.c
+++ b/arch/arm/mach-omap2/gpmc.c
@@ -1562,7 +1562,12 @@ static int gpmc_probe_generic_child(struct platform_device *pdev,
1562 goto err; 1562 goto err;
1563 1563
1564 gpmc_read_timings_dt(child, &gpmc_t); 1564 gpmc_read_timings_dt(child, &gpmc_t);
1565 gpmc_cs_set_timings(cs, &gpmc_t); 1565 ret = gpmc_cs_set_timings(cs, &gpmc_t);
1566 if (ret) {
1567 dev_err(&pdev->dev, "failed to set gpmc timings for: %s\n",
1568 child->name);
1569 goto err;
1570 }
1566 1571
1567no_timings: 1572no_timings:
1568 if (of_platform_device_create(child, NULL, &pdev->dev)) 1573 if (of_platform_device_create(child, NULL, &pdev->dev))