diff options
author | Tomi Valkeinen <tomi.valkeinen@nokia.com> | 2010-03-02 05:13:55 -0500 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@nokia.com> | 2010-03-02 10:24:18 -0500 |
commit | 21df20fcfb4e88f4cd4991e9e67de549e6480adf (patch) | |
tree | e75764923d09f257dae21c913dcdfe10431e20db | |
parent | 1189b7ff6485ebf1039440c34150360fab7cfb01 (diff) |
OMAP: DSS2: Taal: Fix TE when resuming
TE was not initialized properly on power on, which broke TE when resuming
from suspend.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
-rw-r--r-- | drivers/video/omap2/displays/panel-taal.c | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/drivers/video/omap2/displays/panel-taal.c b/drivers/video/omap2/displays/panel-taal.c index 2b5777621779..fcd6a61a91eb 100644 --- a/drivers/video/omap2/displays/panel-taal.c +++ b/drivers/video/omap2/displays/panel-taal.c | |||
@@ -63,6 +63,8 @@ | |||
63 | /* #define TAAL_USE_ESD_CHECK */ | 63 | /* #define TAAL_USE_ESD_CHECK */ |
64 | #define TAAL_ESD_CHECK_PERIOD msecs_to_jiffies(5000) | 64 | #define TAAL_ESD_CHECK_PERIOD msecs_to_jiffies(5000) |
65 | 65 | ||
66 | static int _taal_enable_te(struct omap_dss_device *dssdev, bool enable); | ||
67 | |||
66 | struct taal_data { | 68 | struct taal_data { |
67 | struct backlight_device *bldev; | 69 | struct backlight_device *bldev; |
68 | 70 | ||
@@ -666,6 +668,10 @@ static int taal_power_on(struct omap_dss_device *dssdev) | |||
666 | 668 | ||
667 | taal_dcs_write_0(DCS_DISPLAY_ON); | 669 | taal_dcs_write_0(DCS_DISPLAY_ON); |
668 | 670 | ||
671 | r = _taal_enable_te(dssdev, td->te_enabled); | ||
672 | if (r) | ||
673 | goto err; | ||
674 | |||
669 | #ifdef TAAL_USE_ESD_CHECK | 675 | #ifdef TAAL_USE_ESD_CHECK |
670 | queue_delayed_work(td->esd_wq, &td->esd_work, TAAL_ESD_CHECK_PERIOD); | 676 | queue_delayed_work(td->esd_wq, &td->esd_work, TAAL_ESD_CHECK_PERIOD); |
671 | #endif | 677 | #endif |
@@ -828,13 +834,11 @@ static int taal_sync(struct omap_dss_device *dssdev) | |||
828 | return 0; | 834 | return 0; |
829 | } | 835 | } |
830 | 836 | ||
831 | static int taal_enable_te(struct omap_dss_device *dssdev, bool enable) | 837 | static int _taal_enable_te(struct omap_dss_device *dssdev, bool enable) |
832 | { | 838 | { |
833 | struct taal_data *td = dev_get_drvdata(&dssdev->dev); | 839 | struct taal_data *td = dev_get_drvdata(&dssdev->dev); |
834 | int r; | 840 | int r; |
835 | 841 | ||
836 | dsi_bus_lock(); | ||
837 | |||
838 | td->te_enabled = enable; | 842 | td->te_enabled = enable; |
839 | 843 | ||
840 | if (enable) | 844 | if (enable) |
@@ -848,6 +852,17 @@ static int taal_enable_te(struct omap_dss_device *dssdev, bool enable) | |||
848 | * Panel bug? Needs more studying */ | 852 | * Panel bug? Needs more studying */ |
849 | msleep(100); | 853 | msleep(100); |
850 | 854 | ||
855 | return r; | ||
856 | } | ||
857 | |||
858 | static int taal_enable_te(struct omap_dss_device *dssdev, bool enable) | ||
859 | { | ||
860 | int r; | ||
861 | |||
862 | dsi_bus_lock(); | ||
863 | |||
864 | r = _taal_enable_te(dssdev, enable); | ||
865 | |||
851 | dsi_bus_unlock(); | 866 | dsi_bus_unlock(); |
852 | 867 | ||
853 | return r; | 868 | return r; |