diff options
author | Artem Bityutskiy <Artem.Bityutskiy@nokia.com> | 2010-07-12 17:38:07 +0400 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2010-08-04 15:43:51 +0400 |
commit | 49b368a6b3e803fe4f0a10c14f8fde3f20998f04 (patch) | |
tree | 2e6077341970ccabb6f93222a36b42a30b105a12 /arch/arm | |
parent | 7590d1defdc720a97a9e186f45f529c4ae1b40f7 (diff) | |
download | linux-49b368a6b3e803fe4f0a10c14f8fde3f20998f04.tar.xz |
omap: device: improve errors handling
Do not forget to check the 'platform_device_add_data()' error code
in 'omap_device_build_ss()'.
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Acked-by: Nishanth Menon <nm@ti.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/plat-omap/omap_device.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/arm/plat-omap/omap_device.c b/arch/arm/plat-omap/omap_device.c index ea0d659fcb1c..d2b160942ccc 100644 --- a/arch/arm/plat-omap/omap_device.c +++ b/arch/arm/plat-omap/omap_device.c @@ -407,7 +407,9 @@ struct omap_device *omap_device_build_ss(const char *pdev_name, int pdev_id, od->pdev.num_resources = res_count; od->pdev.resource = res; - platform_device_add_data(&od->pdev, pdata, pdata_len); + ret = platform_device_add_data(&od->pdev, pdata, pdata_len); + if (ret) + goto odbs_exit4; od->pm_lats = pm_lats; od->pm_lats_cnt = pm_lats_cnt; |