Re: [PATCH] ARM: OMAP3: Fix omapfb's problem on OMAP3430sdp

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Sep 1, 2008 at 9:37 AM, stanley.miao <stanley.miao@xxxxxxxxxxxxx> wrote:
> In RGB565 mode, red and blue color are filtered, so the picture on LCD
> looks green and dark.
>
> Fix omapfb's problem on OMAP3430sdp.
>
> Signed-off-by: Stanley Miao <stanley.miao@xxxxxxxxxxxxx>
>
> ---
> diff --git a/drivers/video/omap/lcd_2430sdp.c
> b/drivers/video/omap/lcd_2430sdp.c
> index 9af6cd0..896a236 100644
> --- a/drivers/video/omap/lcd_2430sdp.c
> +++ b/drivers/video/omap/lcd_2430sdp.c
> @@ -23,6 +23,7 @@
>
>  #include <linux/module.h>
>  #include <linux/platform_device.h>
> +#include <linux/delay.h>
>  #include <linux/i2c/twl4030.h>
>
>  #include <mach/gpio.h>
> @@ -45,6 +46,10 @@ static unsigned enable_gpio;
>  #define ENABLE_VAUX3_DEDICATED 0x03
>  #define ENABLE_VAUX3_DEV_GRP   0x20
>
> +#define ENABLE_VPLL2_DEDICATED          0x05
> +#define ENABLE_VPLL2_DEV_GRP            0xE0
> +#define TWL4030_VPLL2_DEV_GRP           0x33
> +#define TWL4030_VPLL2_DEDICATED         0x36
>
>  #define t2_out(c, r, v) twl4030_i2c_write_u8(c, r, v)
>
> @@ -76,6 +81,11 @@ static int sdp2430_panel_enable(struct lcd_panel
> *panel)
>  {
>        u8 ded_val, ded_reg;
>        u8 grp_val, grp_reg;

The below code will execute in 2430SDP also because is_sil_rev_less_than()
will be false there.
You need some mechanism to avoid that right?

> +
> +       if(!is_sil_rev_less_than(OMAP3430_REV_ES2_0)) {
> +               t2_out(PM_RECEIVER, ENABLE_VPLL2_DEDICATED,TWL4030_VPLL2_DEDICATED);
> +               t2_out(PM_RECEIVER, ENABLE_VPLL2_DEV_GRP,TWL4030_VPLL2_DEV_GRP);
> +       }
>
>        if (machine_is_omap_3430sdp()) {
>                ded_reg = TWL4030_VAUX3_DEDICATED;
> @@ -104,6 +114,11 @@ static void sdp2430_panel_disable(struct lcd_panel
> *panel)
>  {
>        omap_set_gpio_dataout(enable_gpio, 0);
>        omap_set_gpio_dataout(backlight_gpio, 0);

Here too the same
> +       if(!is_sil_rev_less_than(OMAP3430_REV_ES2_0)) {
> +               t2_out(PM_RECEIVER, 0x0, TWL4030_VPLL2_DEDICATED);
> +               t2_out(PM_RECEIVER, 0x0, TWL4030_VPLL2_DEV_GRP);
> +               mdelay(4);
> +       }
>  }
>
>  static unsigned long sdp2430_panel_get_caps(struct lcd_panel *panel)
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux