]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - drivers/video/atmel_lcdfb.c
atmel_lcd: Allow contrast polarity to be either positive or negative
[karo-tx-uboot.git] / drivers / video / atmel_lcdfb.c
index db867638f6310e2491fa017426793edc1d715cf0..c02ffd8036394fdc6eacaadcb52c6226a6ca1ef0 100644 (file)
@@ -143,8 +143,9 @@ void lcd_ctrl_init(void *lcdbase)
 
        /* Set contrast */
        value = ATMEL_LCDC_PS_DIV8 |
-               ATMEL_LCDC_POL_POSITIVE |
                ATMEL_LCDC_ENA_PWMENABLE;
+       if (!panel_info.vl_cont_pol_low)
+               value |= ATMEL_LCDC_POL_POSITIVE;
        lcdc_writel(panel_info.mmio, ATMEL_LCDC_CONTRAST_CTR, value);
        lcdc_writel(panel_info.mmio, ATMEL_LCDC_CONTRAST_VAL, ATMEL_LCDC_CVAL_DEFAULT);