Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-only */
0002 /*
0003  * Register definitions for Samsung LTV350QV Quarter VGA LCD Panel
0004  *
0005  * Copyright (C) 2006, 2007 Atmel Corporation
0006  */
0007 #ifndef __LTV350QV_H
0008 #define __LTV350QV_H
0009 
0010 #define LTV_OPC_INDEX   0x74
0011 #define LTV_OPC_DATA    0x76
0012 
0013 #define LTV_ID      0x00        /* ID Read */
0014 #define LTV_IFCTL   0x01        /* Display Interface Control */
0015 #define LTV_DATACTL 0x02        /* Display Data Control */
0016 #define LTV_ENTRY_MODE  0x03        /* Entry Mode */
0017 #define LTV_GATECTL1    0x04        /* Gate Control 1 */
0018 #define LTV_GATECTL2    0x05        /* Gate Control 2 */
0019 #define LTV_VBP     0x06        /* Vertical Back Porch */
0020 #define LTV_HBP     0x07        /* Horizontal Back Porch */
0021 #define LTV_SOTCTL  0x08        /* Source Output Timing Control */
0022 #define LTV_PWRCTL1 0x09        /* Power Control 1 */
0023 #define LTV_PWRCTL2 0x0a        /* Power Control 2 */
0024 #define LTV_GAMMA(x)    (0x10 + (x))    /* Gamma control */
0025 
0026 /* Bit definitions for LTV_IFCTL */
0027 #define LTV_IM          (1 << 15)
0028 #define LTV_NMD         (1 << 14)
0029 #define LTV_SSMD        (1 << 13)
0030 #define LTV_REV         (1 <<  7)
0031 #define LTV_NL(x)       (((x) & 0x001f) << 0)
0032 
0033 /* Bit definitions for LTV_DATACTL */
0034 #define LTV_DS_SAME     (0 << 12)
0035 #define LTV_DS_D_TO_S       (1 << 12)
0036 #define LTV_DS_S_TO_D       (2 << 12)
0037 #define LTV_CHS_384     (0 <<  9)
0038 #define LTV_CHS_480     (1 <<  9)
0039 #define LTV_CHS_492     (2 <<  9)
0040 #define LTV_DF_RGB      (0 <<  6)
0041 #define LTV_DF_RGBX     (1 <<  6)
0042 #define LTV_DF_XRGB     (2 <<  6)
0043 #define LTV_RGB_RGB     (0 <<  2)
0044 #define LTV_RGB_BGR     (1 <<  2)
0045 #define LTV_RGB_GRB     (2 <<  2)
0046 #define LTV_RGB_RBG     (3 <<  2)
0047 
0048 /* Bit definitions for LTV_ENTRY_MODE */
0049 #define LTV_VSPL_ACTIVE_LOW (0 << 15)
0050 #define LTV_VSPL_ACTIVE_HIGH    (1 << 15)
0051 #define LTV_HSPL_ACTIVE_LOW (0 << 14)
0052 #define LTV_HSPL_ACTIVE_HIGH    (1 << 14)
0053 #define LTV_DPL_SAMPLE_RISING   (0 << 13)
0054 #define LTV_DPL_SAMPLE_FALLING  (1 << 13)
0055 #define LTV_EPL_ACTIVE_LOW  (0 << 12)
0056 #define LTV_EPL_ACTIVE_HIGH (1 << 12)
0057 #define LTV_SS_LEFT_TO_RIGHT    (0 <<  8)
0058 #define LTV_SS_RIGHT_TO_LEFT    (1 <<  8)
0059 #define LTV_STB         (1 <<  1)
0060 
0061 /* Bit definitions for LTV_GATECTL1 */
0062 #define LTV_CLW(x)      (((x) & 0x0007) << 12)
0063 #define LTV_GAON        (1 <<  5)
0064 #define LTV_SDR         (1 <<  3)
0065 
0066 /* Bit definitions for LTV_GATECTL2 */
0067 #define LTV_NW_INV_FRAME    (0 << 14)
0068 #define LTV_NW_INV_1LINE    (1 << 14)
0069 #define LTV_NW_INV_2LINE    (2 << 14)
0070 #define LTV_DSC         (1 << 12)
0071 #define LTV_GIF         (1 <<  8)
0072 #define LTV_FHN         (1 <<  7)
0073 #define LTV_FTI(x)      (((x) & 0x0003) << 4)
0074 #define LTV_FWI(x)      (((x) & 0x0003) << 0)
0075 
0076 /* Bit definitions for LTV_SOTCTL */
0077 #define LTV_SDT(x)      (((x) & 0x0007) << 10)
0078 #define LTV_EQ(x)       (((x) & 0x0007) <<  2)
0079 
0080 /* Bit definitions for LTV_PWRCTL1 */
0081 #define LTV_VCOM_DISABLE    (1 << 14)
0082 #define LTV_VCOMOUT_ENABLE  (1 << 11)
0083 #define LTV_POWER_ON        (1 <<  9)
0084 #define LTV_DRIVE_CURRENT(x)    (((x) & 0x0007) << 4)   /* 0=off, 5=max */
0085 #define LTV_SUPPLY_CURRENT(x)   (((x) & 0x0007) << 0)   /* 0=off, 5=max */
0086 
0087 /* Bit definitions for LTV_PWRCTL2 */
0088 #define LTV_VCOML_ENABLE    (1 << 13)
0089 #define LTV_VCOML_VOLTAGE(x)    (((x) & 0x001f) << 8)   /* 0=1V, 31=-1V */
0090 #define LTV_VCOMH_VOLTAGE(x)    (((x) & 0x001f) << 0)   /* 0=3V, 31=4.5V */
0091 
0092 #endif /* __LTV350QV_H */