Commit a74fe1194b8da1dcee7529ba14999381bb9c25d9
Committed by
Eric Miao
1 parent
8c568df9d7
Exists in
master
and in
39 other branches
ARM: pxa/raumfeld: display initialisation fixes
The display requires some milliseconds between GPIO_TFT_VA_EN and GPIO_DISPLAY_ENABLE. Reorder initialisation to comply with the display spec. Also tune timings for better compliance with the spec. Signed-off-by: Sven Neumann <s.neumann@raumfeld.com> Acked-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
Showing 1 changed file with 15 additions and 14 deletions Side-by-side Diff
arch/arm/mach-pxa/raumfeld.c
... | ... | @@ -573,10 +573,10 @@ |
573 | 573 | .xres = 480, |
574 | 574 | .yres = 272, |
575 | 575 | .bpp = 16, |
576 | - .hsync_len = 4, | |
576 | + .hsync_len = 41, | |
577 | 577 | .left_margin = 2, |
578 | 578 | .right_margin = 1, |
579 | - .vsync_len = 1, | |
579 | + .vsync_len = 10, | |
580 | 580 | .upper_margin = 3, |
581 | 581 | .lower_margin = 1, |
582 | 582 | .sync = 0, |
583 | 583 | |
584 | 584 | |
... | ... | @@ -596,30 +596,31 @@ |
596 | 596 | { |
597 | 597 | int ret; |
598 | 598 | |
599 | - pxa_set_fb_info(NULL, &raumfeld_sharp_lcd_info); | |
600 | - | |
601 | - /* Hardware revision 2 has the backlight regulator controlled | |
602 | - * by an LT3593, earlier and later devices use PWM for that. */ | |
603 | - if ((system_rev & 0xff) == 2) { | |
604 | - platform_device_register(&raumfeld_lt3593_device); | |
605 | - } else { | |
606 | - mfp_cfg_t raumfeld_pwm_pin_config = GPIO17_PWM0_OUT; | |
607 | - pxa3xx_mfp_config(&raumfeld_pwm_pin_config, 1); | |
608 | - platform_device_register(&raumfeld_pwm_backlight_device); | |
609 | - } | |
610 | - | |
611 | 599 | ret = gpio_request(GPIO_TFT_VA_EN, "display VA enable"); |
612 | 600 | if (ret < 0) |
613 | 601 | pr_warning("Unable to request GPIO_TFT_VA_EN\n"); |
614 | 602 | else |
615 | 603 | gpio_direction_output(GPIO_TFT_VA_EN, 1); |
616 | 604 | |
605 | + msleep(100); | |
606 | + | |
617 | 607 | ret = gpio_request(GPIO_DISPLAY_ENABLE, "display enable"); |
618 | 608 | if (ret < 0) |
619 | 609 | pr_warning("Unable to request GPIO_DISPLAY_ENABLE\n"); |
620 | 610 | else |
621 | 611 | gpio_direction_output(GPIO_DISPLAY_ENABLE, 1); |
622 | 612 | |
613 | + /* Hardware revision 2 has the backlight regulator controlled | |
614 | + * by an LT3593, earlier and later devices use PWM for that. */ | |
615 | + if ((system_rev & 0xff) == 2) { | |
616 | + platform_device_register(&raumfeld_lt3593_device); | |
617 | + } else { | |
618 | + mfp_cfg_t raumfeld_pwm_pin_config = GPIO17_PWM0_OUT; | |
619 | + pxa3xx_mfp_config(&raumfeld_pwm_pin_config, 1); | |
620 | + platform_device_register(&raumfeld_pwm_backlight_device); | |
621 | + } | |
622 | + | |
623 | + pxa_set_fb_info(NULL, &raumfeld_sharp_lcd_info); | |
623 | 624 | platform_device_register(&pxa3xx_device_gcu); |
624 | 625 | } |
625 | 626 |