summaryrefslogtreecommitdiff
path: root/firmware/target/arm/rk27xx
diff options
context:
space:
mode:
authorAndrew Ryabinin <ryabinin.a.a@gmail.com>2013-02-16 18:10:15 +0400
committerAndrew Ryabinin <ryabinin.a.a@gmail.com>2013-02-16 18:21:36 +0400
commit3fd11c370e91b1dcd762743fb5ed6b12001c0de7 (patch)
treee3c1a2bd107d24d5ad832b1781bfb2e854f4a010 /firmware/target/arm/rk27xx
parent527b1885a14d8f624a5ab38e9b9e977c525fa691 (diff)
hm60x: Fix white screen bug.
Lcd should be reseted after power is supplied. Change-Id: I2a47ffb7d9b20d9ef2ad90aee15f4ada2fdd7f2e
Diffstat (limited to 'firmware/target/arm/rk27xx')
-rw-r--r--firmware/target/arm/rk27xx/lcd-hifiman.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/firmware/target/arm/rk27xx/lcd-hifiman.c b/firmware/target/arm/rk27xx/lcd-hifiman.c
index 1c42921a42..58f957b613 100644
--- a/firmware/target/arm/rk27xx/lcd-hifiman.c
+++ b/firmware/target/arm/rk27xx/lcd-hifiman.c
@@ -30,6 +30,15 @@
static bool display_on = false;
+static void reset_lcd(void)
+{
+ GPIO_PCCON |= (1<<7);
+ GPIO_PCDR &= ~(1<<7);
+ udelay(10);
+ GPIO_PCDR |= (1<<7);
+ udelay(5000);
+}
+
void lcd_v1_display_init(void)
{
unsigned int x, y;
@@ -286,6 +295,7 @@ static void lcd_v2_update_rect(int x, int y, int width, int height)
void lcd_display_init(void)
{
+ reset_lcd();
identify_lcd();
if (lcd_type == LCD_V1)
lcd_v1_display_init();
@@ -323,6 +333,7 @@ void lcd_update_rect(int x, int y, int width, int height)
void lcd_display_init(void)
{
+ reset_lcd();
lcd_v1_display_init();
}