diff options
Diffstat (limited to 'drivers/video/omap2/displays/panel-taal.c')
-rw-r--r-- | drivers/video/omap2/displays/panel-taal.c | 38 |
1 files changed, 14 insertions, 24 deletions
diff --git a/drivers/video/omap2/displays/panel-taal.c b/drivers/video/omap2/displays/panel-taal.c index 80c3f6ab1a94..00c5c615585f 100644 --- a/drivers/video/omap2/displays/panel-taal.c +++ b/drivers/video/omap2/displays/panel-taal.c | |||
@@ -198,12 +198,6 @@ struct taal_data { | |||
198 | bool te_enabled; | 198 | bool te_enabled; |
199 | 199 | ||
200 | atomic_t do_update; | 200 | atomic_t do_update; |
201 | struct { | ||
202 | u16 x; | ||
203 | u16 y; | ||
204 | u16 w; | ||
205 | u16 h; | ||
206 | } update_region; | ||
207 | int channel; | 201 | int channel; |
208 | 202 | ||
209 | struct delayed_work te_timeout_work; | 203 | struct delayed_work te_timeout_work; |
@@ -1188,6 +1182,10 @@ static int taal_power_on(struct omap_dss_device *dssdev) | |||
1188 | if (r) | 1182 | if (r) |
1189 | goto err; | 1183 | goto err; |
1190 | 1184 | ||
1185 | r = dsi_enable_video_output(dssdev, td->channel); | ||
1186 | if (r) | ||
1187 | goto err; | ||
1188 | |||
1191 | td->enabled = 1; | 1189 | td->enabled = 1; |
1192 | 1190 | ||
1193 | if (!td->intro_printed) { | 1191 | if (!td->intro_printed) { |
@@ -1217,6 +1215,8 @@ static void taal_power_off(struct omap_dss_device *dssdev) | |||
1217 | struct taal_data *td = dev_get_drvdata(&dssdev->dev); | 1215 | struct taal_data *td = dev_get_drvdata(&dssdev->dev); |
1218 | int r; | 1216 | int r; |
1219 | 1217 | ||
1218 | dsi_disable_video_output(dssdev, td->channel); | ||
1219 | |||
1220 | r = taal_dcs_write_0(td, MIPI_DCS_SET_DISPLAY_OFF); | 1220 | r = taal_dcs_write_0(td, MIPI_DCS_SET_DISPLAY_OFF); |
1221 | if (!r) | 1221 | if (!r) |
1222 | r = taal_sleep_in(td); | 1222 | r = taal_sleep_in(td); |
@@ -1394,12 +1394,8 @@ static irqreturn_t taal_te_isr(int irq, void *data) | |||
1394 | if (old) { | 1394 | if (old) { |
1395 | cancel_delayed_work(&td->te_timeout_work); | 1395 | cancel_delayed_work(&td->te_timeout_work); |
1396 | 1396 | ||
1397 | r = omap_dsi_update(dssdev, td->channel, | 1397 | r = omap_dsi_update(dssdev, td->channel, taal_framedone_cb, |
1398 | td->update_region.x, | 1398 | dssdev); |
1399 | td->update_region.y, | ||
1400 | td->update_region.w, | ||
1401 | td->update_region.h, | ||
1402 | taal_framedone_cb, dssdev); | ||
1403 | if (r) | 1399 | if (r) |
1404 | goto err; | 1400 | goto err; |
1405 | } | 1401 | } |
@@ -1444,26 +1440,20 @@ static int taal_update(struct omap_dss_device *dssdev, | |||
1444 | goto err; | 1440 | goto err; |
1445 | } | 1441 | } |
1446 | 1442 | ||
1447 | r = omap_dsi_prepare_update(dssdev, &x, &y, &w, &h, true); | 1443 | /* XXX no need to send this every frame, but dsi break if not done */ |
1448 | if (r) | 1444 | r = taal_set_update_window(td, 0, 0, |
1449 | goto err; | 1445 | td->panel_config->timings.x_res, |
1450 | 1446 | td->panel_config->timings.y_res); | |
1451 | r = taal_set_update_window(td, x, y, w, h); | ||
1452 | if (r) | 1447 | if (r) |
1453 | goto err; | 1448 | goto err; |
1454 | 1449 | ||
1455 | if (td->te_enabled && panel_data->use_ext_te) { | 1450 | if (td->te_enabled && panel_data->use_ext_te) { |
1456 | td->update_region.x = x; | ||
1457 | td->update_region.y = y; | ||
1458 | td->update_region.w = w; | ||
1459 | td->update_region.h = h; | ||
1460 | barrier(); | ||
1461 | schedule_delayed_work(&td->te_timeout_work, | 1451 | schedule_delayed_work(&td->te_timeout_work, |
1462 | msecs_to_jiffies(250)); | 1452 | msecs_to_jiffies(250)); |
1463 | atomic_set(&td->do_update, 1); | 1453 | atomic_set(&td->do_update, 1); |
1464 | } else { | 1454 | } else { |
1465 | r = omap_dsi_update(dssdev, td->channel, x, y, w, h, | 1455 | r = omap_dsi_update(dssdev, td->channel, taal_framedone_cb, |
1466 | taal_framedone_cb, dssdev); | 1456 | dssdev); |
1467 | if (r) | 1457 | if (r) |
1468 | goto err; | 1458 | goto err; |
1469 | } | 1459 | } |