diff options
-rw-r--r-- | drivers/video/omap2/dss/sdi.c | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/drivers/video/omap2/dss/sdi.c b/drivers/video/omap2/dss/sdi.c index 6277c0593854..d362fe17081f 100644 --- a/drivers/video/omap2/dss/sdi.c +++ b/drivers/video/omap2/dss/sdi.c | |||
@@ -248,23 +248,22 @@ void omapdss_sdi_set_datapairs(struct omap_dss_device *dssdev, int datapairs) | |||
248 | } | 248 | } |
249 | EXPORT_SYMBOL(omapdss_sdi_set_datapairs); | 249 | EXPORT_SYMBOL(omapdss_sdi_set_datapairs); |
250 | 250 | ||
251 | static int sdi_init_display(struct omap_dss_device *dssdev) | 251 | static int sdi_init_regulator(void) |
252 | { | 252 | { |
253 | DSSDBG("SDI init\n"); | 253 | struct regulator *vdds_sdi; |
254 | 254 | ||
255 | if (sdi.vdds_sdi_reg == NULL) { | 255 | if (sdi.vdds_sdi_reg) |
256 | struct regulator *vdds_sdi; | 256 | return 0; |
257 | |||
258 | vdds_sdi = dss_get_vdds_sdi(); | ||
259 | 257 | ||
260 | if (IS_ERR(vdds_sdi)) { | 258 | vdds_sdi = dss_get_vdds_sdi(); |
261 | DSSERR("can't get VDDS_SDI regulator\n"); | ||
262 | return PTR_ERR(vdds_sdi); | ||
263 | } | ||
264 | 259 | ||
265 | sdi.vdds_sdi_reg = vdds_sdi; | 260 | if (IS_ERR(vdds_sdi)) { |
261 | DSSERR("can't get VDDS_SDI regulator\n"); | ||
262 | return PTR_ERR(vdds_sdi); | ||
266 | } | 263 | } |
267 | 264 | ||
265 | sdi.vdds_sdi_reg = vdds_sdi; | ||
266 | |||
268 | return 0; | 267 | return 0; |
269 | } | 268 | } |
270 | 269 | ||
@@ -313,7 +312,7 @@ static int sdi_probe_pdata(struct platform_device *sdidev) | |||
313 | 312 | ||
314 | dss_copy_device_pdata(dssdev, plat_dssdev); | 313 | dss_copy_device_pdata(dssdev, plat_dssdev); |
315 | 314 | ||
316 | r = sdi_init_display(dssdev); | 315 | r = sdi_init_regulator(); |
317 | if (r) { | 316 | if (r) { |
318 | DSSERR("device %s init failed: %d\n", dssdev->name, r); | 317 | DSSERR("device %s init failed: %d\n", dssdev->name, r); |
319 | dss_put_device(dssdev); | 318 | dss_put_device(dssdev); |