EKKANE-63:[Kane]:[factory]Modify the tm lcd power on/off sequence
authorwangjiao <wangjiao1@huaqin.com>
Wed, 31 Oct 2018 08:33:46 +0000 (16:33 +0800)
committerxiest1 <xiest1@lenovo.com>
Tue, 5 Nov 2019 09:29:51 +0000 (17:29 +0800)
Change-Id: I01e270af86e6904c4b20d16456593ffdcd03ff4a
Signed-off-by: wangjiao <wangjiao1@huaqin.com>
arch/arm64/boot/dts/exynos/exynos9610-display-lcd.dtsi
drivers/video/fbdev/exynos/dpu20/dsim_drv.c
drivers/video/fbdev/exynos/dpu20/panels/hix83112a_mipi_lcd.c

index 0951116d3f981dea09465d89133845df32e67f74..1c174883d03254c4ff5fb81b6e60c9ea3321993e 100755 (executable)
                                timing,v-porch = <36 27 5>;
                                timing,dsi-hs-clk = <1386>;
                                /* TODO : pms value to be set */
-                               timing,pmsk = <3 317 1 0>;
+                               timing,pmsk = <3 320 1 0>;
                                timing,dsi-escape-clk = <20>;
                                mic_en = <0>;           /* 0: Disable, 1: Enable */
                                mic_ratio = <0>;        /* 0: 1/2 mic, 1: 1/3 mic */
index 7b6423083e6db8a315336dee3d841ef10782c871..fa64f574a69796546732cd094eff015d086fa3f6 100755 (executable)
@@ -634,7 +634,7 @@ int dsim_reset_panel(struct dsim_device *dsim)
 
        gpio_free(res->lcd_reset);
 
-       usleep_range(10000, 11000);
+       usleep_range(50000, 60000);
 
        dsim_dbg("%s -\n", __func__);
        return 0;
@@ -699,6 +699,17 @@ int dsim_set_panel_power(struct dsim_device *dsim, bool on)
                        }
                }
        } else {
+               if (res->lcd_power[2] > 0) {
+                       ret = gpio_request_one(res->lcd_power[2],
+                                       GPIOF_OUT_INIT_LOW, "lcd_power2");
+                       if (ret < 0) {
+                               dsim_err("failed 3nd LCD power off\n");
+                               return -EINVAL;
+                       }
+                       gpio_free(res->lcd_power[2]);
+                       usleep_range(5000, 6000);
+               }
+
                ret = gpio_request_one(res->lcd_reset, GPIOF_OUT_INIT_LOW,
                                "lcd_reset");
                if (ret < 0) {
@@ -706,17 +717,7 @@ int dsim_set_panel_power(struct dsim_device *dsim, bool on)
                        return -EINVAL;
                }
                gpio_free(res->lcd_reset);
-
-               if (res->lcd_power[0] > 0) {
-                       ret = gpio_request_one(res->lcd_power[0],
-                                       GPIOF_OUT_INIT_LOW, "lcd_power0");
-                       if (ret < 0) {
-                               dsim_err("failed LCD power off\n");
-                               return -EINVAL;
-                       }
-                       gpio_free(res->lcd_power[0]);
-                       usleep_range(5000, 6000);
-               }
+               usleep_range(1000, 2000);
 
                if (res->lcd_power[1] > 0) {
                        ret = gpio_request_one(res->lcd_power[1],
@@ -729,14 +730,14 @@ int dsim_set_panel_power(struct dsim_device *dsim, bool on)
                        usleep_range(5000, 6000);
                }
 
-               if (res->lcd_power[2] > 0) {
-                       ret = gpio_request_one(res->lcd_power[2],
-                                       GPIOF_OUT_INIT_LOW, "lcd_power2");
+               if (res->lcd_power[0] > 0) {
+                       ret = gpio_request_one(res->lcd_power[0],
+                                       GPIOF_OUT_INIT_LOW, "lcd_power0");
                        if (ret < 0) {
-                               dsim_err("failed 3nd LCD power off\n");
+                               dsim_err("failed LCD power off\n");
                                return -EINVAL;
                        }
-                       gpio_free(res->lcd_power[2]);
+                       gpio_free(res->lcd_power[0]);
                        usleep_range(5000, 6000);
                }
 
index 8e6a1d2284a73fc3f91a1b648d511a5d24530868..5b744a37a880fafdf94af608a54848ddfb110caf 100755 (executable)
@@ -402,7 +402,10 @@ static int hix83112a_displayon(struct dsim_device *dsim)
 
 static int hix83112a_suspend(struct dsim_device *dsim)
 {
-       return 0;
+       dsim_info("%s +\n", __func__);
+       hix83112a_lcd_disable(dsim->id);
+       dsim_info("%s -\n", __func__);
+       return 1;
 }
 
 static int hix83112a_resume(struct dsim_device *dsim)