aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_reg.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/i915/i915_reg.h')
-rw-r--r--drivers/gpu/drm/i915/i915_reg.h71
1 files changed, 47 insertions, 24 deletions
diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
index 1687edf68795..974b3cf70618 100644
--- a/drivers/gpu/drm/i915/i915_reg.h
+++ b/drivers/gpu/drm/i915/i915_reg.h
@@ -140,6 +140,7 @@
140#define MI_NOOP MI_INSTR(0, 0) 140#define MI_NOOP MI_INSTR(0, 0)
141#define MI_USER_INTERRUPT MI_INSTR(0x02, 0) 141#define MI_USER_INTERRUPT MI_INSTR(0x02, 0)
142#define MI_WAIT_FOR_EVENT MI_INSTR(0x03, 0) 142#define MI_WAIT_FOR_EVENT MI_INSTR(0x03, 0)
143#define MI_WAIT_FOR_OVERLAY_FLIP (1<<16)
143#define MI_WAIT_FOR_PLANE_B_FLIP (1<<6) 144#define MI_WAIT_FOR_PLANE_B_FLIP (1<<6)
144#define MI_WAIT_FOR_PLANE_A_FLIP (1<<2) 145#define MI_WAIT_FOR_PLANE_A_FLIP (1<<2)
145#define MI_WAIT_FOR_PLANE_A_SCANLINES (1<<1) 146#define MI_WAIT_FOR_PLANE_A_SCANLINES (1<<1)
@@ -151,7 +152,13 @@
151#define MI_END_SCENE (1 << 4) /* flush binner and incr scene count */ 152#define MI_END_SCENE (1 << 4) /* flush binner and incr scene count */
152#define MI_BATCH_BUFFER_END MI_INSTR(0x0a, 0) 153#define MI_BATCH_BUFFER_END MI_INSTR(0x0a, 0)
153#define MI_REPORT_HEAD MI_INSTR(0x07, 0) 154#define MI_REPORT_HEAD MI_INSTR(0x07, 0)
155#define MI_OVERLAY_FLIP MI_INSTR(0x11,0)
156#define MI_OVERLAY_CONTINUE (0x0<<21)
157#define MI_OVERLAY_ON (0x1<<21)
158#define MI_OVERLAY_OFF (0x2<<21)
154#define MI_LOAD_SCAN_LINES_INCL MI_INSTR(0x12, 0) 159#define MI_LOAD_SCAN_LINES_INCL MI_INSTR(0x12, 0)
160#define MI_DISPLAY_FLIP MI_INSTR(0x14, 2)
161#define MI_DISPLAY_FLIP_PLANE(n) ((n) << 20)
155#define MI_STORE_DWORD_IMM MI_INSTR(0x20, 1) 162#define MI_STORE_DWORD_IMM MI_INSTR(0x20, 1)
156#define MI_MEM_VIRTUAL (1 << 22) /* 965+ only */ 163#define MI_MEM_VIRTUAL (1 << 22) /* 965+ only */
157#define MI_STORE_DWORD_INDEX MI_INSTR(0x21, 1) 164#define MI_STORE_DWORD_INDEX MI_INSTR(0x21, 1)
@@ -260,6 +267,8 @@
260#define HWS_PGA 0x02080 267#define HWS_PGA 0x02080
261#define HWS_ADDRESS_MASK 0xfffff000 268#define HWS_ADDRESS_MASK 0xfffff000
262#define HWS_START_ADDRESS_SHIFT 4 269#define HWS_START_ADDRESS_SHIFT 4
270#define PWRCTXA 0x2088 /* 965GM+ only */
271#define PWRCTX_EN (1<<0)
263#define IPEIR 0x02088 272#define IPEIR 0x02088
264#define IPEHR 0x0208c 273#define IPEHR 0x0208c
265#define INSTDONE 0x02090 274#define INSTDONE 0x02090
@@ -405,6 +414,13 @@
405# define GPIO_DATA_VAL_IN (1 << 12) 414# define GPIO_DATA_VAL_IN (1 << 12)
406# define GPIO_DATA_PULLUP_DISABLE (1 << 13) 415# define GPIO_DATA_PULLUP_DISABLE (1 << 13)
407 416
417#define GMBUS0 0x5100
418#define GMBUS1 0x5104
419#define GMBUS2 0x5108
420#define GMBUS3 0x510c
421#define GMBUS4 0x5110
422#define GMBUS5 0x5120
423
408/* 424/*
409 * Clock control & power management 425 * Clock control & power management
410 */ 426 */
@@ -435,7 +451,7 @@
435#define DPLLB_LVDS_P2_CLOCK_DIV_7 (1 << 24) /* i915 */ 451#define DPLLB_LVDS_P2_CLOCK_DIV_7 (1 << 24) /* i915 */
436#define DPLL_P2_CLOCK_DIV_MASK 0x03000000 /* i915 */ 452#define DPLL_P2_CLOCK_DIV_MASK 0x03000000 /* i915 */
437#define DPLL_FPA01_P1_POST_DIV_MASK 0x00ff0000 /* i915 */ 453#define DPLL_FPA01_P1_POST_DIV_MASK 0x00ff0000 /* i915 */
438#define DPLL_FPA01_P1_POST_DIV_MASK_IGD 0x00ff8000 /* IGD */ 454#define DPLL_FPA01_P1_POST_DIV_MASK_PINEVIEW 0x00ff8000 /* Pineview */
439 455
440#define I915_FIFO_UNDERRUN_STATUS (1UL<<31) 456#define I915_FIFO_UNDERRUN_STATUS (1UL<<31)
441#define I915_CRC_ERROR_ENABLE (1UL<<29) 457#define I915_CRC_ERROR_ENABLE (1UL<<29)
@@ -512,7 +528,7 @@
512 */ 528 */
513#define DPLL_FPA01_P1_POST_DIV_MASK_I830_LVDS 0x003f0000 529#define DPLL_FPA01_P1_POST_DIV_MASK_I830_LVDS 0x003f0000
514#define DPLL_FPA01_P1_POST_DIV_SHIFT 16 530#define DPLL_FPA01_P1_POST_DIV_SHIFT 16
515#define DPLL_FPA01_P1_POST_DIV_SHIFT_IGD 15 531#define DPLL_FPA01_P1_POST_DIV_SHIFT_PINEVIEW 15
516/* i830, required in DVO non-gang */ 532/* i830, required in DVO non-gang */
517#define PLL_P2_DIVIDE_BY_4 (1 << 23) 533#define PLL_P2_DIVIDE_BY_4 (1 << 23)
518#define PLL_P1_DIVIDE_BY_TWO (1 << 21) /* i830 */ 534#define PLL_P1_DIVIDE_BY_TWO (1 << 21) /* i830 */
@@ -522,7 +538,7 @@
522#define PLLB_REF_INPUT_SPREADSPECTRUMIN (3 << 13) 538#define PLLB_REF_INPUT_SPREADSPECTRUMIN (3 << 13)
523#define PLL_REF_INPUT_MASK (3 << 13) 539#define PLL_REF_INPUT_MASK (3 << 13)
524#define PLL_LOAD_PULSE_PHASE_SHIFT 9 540#define PLL_LOAD_PULSE_PHASE_SHIFT 9
525/* IGDNG */ 541/* Ironlake */
526# define PLL_REF_SDVO_HDMI_MULTIPLIER_SHIFT 9 542# define PLL_REF_SDVO_HDMI_MULTIPLIER_SHIFT 9
527# define PLL_REF_SDVO_HDMI_MULTIPLIER_MASK (7 << 9) 543# define PLL_REF_SDVO_HDMI_MULTIPLIER_MASK (7 << 9)
528# define PLL_REF_SDVO_HDMI_MULTIPLIER(x) (((x)-1) << 9) 544# define PLL_REF_SDVO_HDMI_MULTIPLIER(x) (((x)-1) << 9)
@@ -586,12 +602,12 @@
586#define FPB0 0x06048 602#define FPB0 0x06048
587#define FPB1 0x0604c 603#define FPB1 0x0604c
588#define FP_N_DIV_MASK 0x003f0000 604#define FP_N_DIV_MASK 0x003f0000
589#define FP_N_IGD_DIV_MASK 0x00ff0000 605#define FP_N_PINEVIEW_DIV_MASK 0x00ff0000
590#define FP_N_DIV_SHIFT 16 606#define FP_N_DIV_SHIFT 16
591#define FP_M1_DIV_MASK 0x00003f00 607#define FP_M1_DIV_MASK 0x00003f00
592#define FP_M1_DIV_SHIFT 8 608#define FP_M1_DIV_SHIFT 8
593#define FP_M2_DIV_MASK 0x0000003f 609#define FP_M2_DIV_MASK 0x0000003f
594#define FP_M2_IGD_DIV_MASK 0x000000ff 610#define FP_M2_PINEVIEW_DIV_MASK 0x000000ff
595#define FP_M2_DIV_SHIFT 0 611#define FP_M2_DIV_SHIFT 0
596#define DPLL_TEST 0x606c 612#define DPLL_TEST 0x606c
597#define DPLLB_TEST_SDVO_DIV_1 (0 << 22) 613#define DPLLB_TEST_SDVO_DIV_1 (0 << 22)
@@ -769,7 +785,8 @@
769 785
770/** GM965 GM45 render standby register */ 786/** GM965 GM45 render standby register */
771#define MCHBAR_RENDER_STANDBY 0x111B8 787#define MCHBAR_RENDER_STANDBY 0x111B8
772 788#define RCX_SW_EXIT (1<<23)
789#define RSX_STATUS_MASK 0x00700000
773#define PEG_BAND_GAP_DATA 0x14d68 790#define PEG_BAND_GAP_DATA 0x14d68
774 791
775/* 792/*
@@ -844,7 +861,6 @@
844#define SDVOB_HOTPLUG_INT_EN (1 << 26) 861#define SDVOB_HOTPLUG_INT_EN (1 << 26)
845#define SDVOC_HOTPLUG_INT_EN (1 << 25) 862#define SDVOC_HOTPLUG_INT_EN (1 << 25)
846#define TV_HOTPLUG_INT_EN (1 << 18) 863#define TV_HOTPLUG_INT_EN (1 << 18)
847#define CRT_EOS_INT_EN (1 << 10)
848#define CRT_HOTPLUG_INT_EN (1 << 9) 864#define CRT_HOTPLUG_INT_EN (1 << 9)
849#define CRT_HOTPLUG_FORCE_DETECT (1 << 3) 865#define CRT_HOTPLUG_FORCE_DETECT (1 << 3)
850#define CRT_HOTPLUG_ACTIVATION_PERIOD_32 (0 << 8) 866#define CRT_HOTPLUG_ACTIVATION_PERIOD_32 (0 << 8)
@@ -868,7 +884,6 @@
868 HDMID_HOTPLUG_INT_EN | \ 884 HDMID_HOTPLUG_INT_EN | \
869 SDVOB_HOTPLUG_INT_EN | \ 885 SDVOB_HOTPLUG_INT_EN | \
870 SDVOC_HOTPLUG_INT_EN | \ 886 SDVOC_HOTPLUG_INT_EN | \
871 TV_HOTPLUG_INT_EN | \
872 CRT_HOTPLUG_INT_EN) 887 CRT_HOTPLUG_INT_EN)
873 888
874 889
@@ -879,7 +894,6 @@
879#define DPC_HOTPLUG_INT_STATUS (1 << 28) 894#define DPC_HOTPLUG_INT_STATUS (1 << 28)
880#define HDMID_HOTPLUG_INT_STATUS (1 << 27) 895#define HDMID_HOTPLUG_INT_STATUS (1 << 27)
881#define DPD_HOTPLUG_INT_STATUS (1 << 27) 896#define DPD_HOTPLUG_INT_STATUS (1 << 27)
882#define CRT_EOS_INT_STATUS (1 << 12)
883#define CRT_HOTPLUG_INT_STATUS (1 << 11) 897#define CRT_HOTPLUG_INT_STATUS (1 << 11)
884#define TV_HOTPLUG_INT_STATUS (1 << 10) 898#define TV_HOTPLUG_INT_STATUS (1 << 10)
885#define CRT_HOTPLUG_MONITOR_MASK (3 << 8) 899#define CRT_HOTPLUG_MONITOR_MASK (3 << 8)
@@ -1620,7 +1634,7 @@
1620#define DP_CLOCK_OUTPUT_ENABLE (1 << 13) 1634#define DP_CLOCK_OUTPUT_ENABLE (1 << 13)
1621 1635
1622#define DP_SCRAMBLING_DISABLE (1 << 12) 1636#define DP_SCRAMBLING_DISABLE (1 << 12)
1623#define DP_SCRAMBLING_DISABLE_IGDNG (1 << 7) 1637#define DP_SCRAMBLING_DISABLE_IRONLAKE (1 << 7)
1624 1638
1625/** limit RGB values to avoid confusing TVs */ 1639/** limit RGB values to avoid confusing TVs */
1626#define DP_COLOR_RANGE_16_235 (1 << 8) 1640#define DP_COLOR_RANGE_16_235 (1 << 8)
@@ -1808,7 +1822,7 @@
1808#define DSPFW3 0x7003c 1822#define DSPFW3 0x7003c
1809#define DSPFW_HPLL_SR_EN (1<<31) 1823#define DSPFW_HPLL_SR_EN (1<<31)
1810#define DSPFW_CURSOR_SR_SHIFT 24 1824#define DSPFW_CURSOR_SR_SHIFT 24
1811#define IGD_SELF_REFRESH_EN (1<<30) 1825#define PINEVIEW_SELF_REFRESH_EN (1<<30)
1812 1826
1813/* FIFO watermark sizes etc */ 1827/* FIFO watermark sizes etc */
1814#define G4X_FIFO_LINE_SIZE 64 1828#define G4X_FIFO_LINE_SIZE 64
@@ -1824,16 +1838,16 @@
1824#define G4X_MAX_WM 0x3f 1838#define G4X_MAX_WM 0x3f
1825#define I915_MAX_WM 0x3f 1839#define I915_MAX_WM 0x3f
1826 1840
1827#define IGD_DISPLAY_FIFO 512 /* in 64byte unit */ 1841#define PINEVIEW_DISPLAY_FIFO 512 /* in 64byte unit */
1828#define IGD_FIFO_LINE_SIZE 64 1842#define PINEVIEW_FIFO_LINE_SIZE 64
1829#define IGD_MAX_WM 0x1ff 1843#define PINEVIEW_MAX_WM 0x1ff
1830#define IGD_DFT_WM 0x3f 1844#define PINEVIEW_DFT_WM 0x3f
1831#define IGD_DFT_HPLLOFF_WM 0 1845#define PINEVIEW_DFT_HPLLOFF_WM 0
1832#define IGD_GUARD_WM 10 1846#define PINEVIEW_GUARD_WM 10
1833#define IGD_CURSOR_FIFO 64 1847#define PINEVIEW_CURSOR_FIFO 64
1834#define IGD_CURSOR_MAX_WM 0x3f 1848#define PINEVIEW_CURSOR_MAX_WM 0x3f
1835#define IGD_CURSOR_DFT_WM 0 1849#define PINEVIEW_CURSOR_DFT_WM 0
1836#define IGD_CURSOR_GUARD_WM 5 1850#define PINEVIEW_CURSOR_GUARD_WM 5
1837 1851
1838/* 1852/*
1839 * The two pipe frame counter registers are not synchronized, so 1853 * The two pipe frame counter registers are not synchronized, so
@@ -1907,6 +1921,7 @@
1907#define DISPPLANE_16BPP (0x5<<26) 1921#define DISPPLANE_16BPP (0x5<<26)
1908#define DISPPLANE_32BPP_NO_ALPHA (0x6<<26) 1922#define DISPPLANE_32BPP_NO_ALPHA (0x6<<26)
1909#define DISPPLANE_32BPP (0x7<<26) 1923#define DISPPLANE_32BPP (0x7<<26)
1924#define DISPPLANE_32BPP_30BIT_NO_ALPHA (0xa<<26)
1910#define DISPPLANE_STEREO_ENABLE (1<<25) 1925#define DISPPLANE_STEREO_ENABLE (1<<25)
1911#define DISPPLANE_STEREO_DISABLE 0 1926#define DISPPLANE_STEREO_DISABLE 0
1912#define DISPPLANE_SEL_PIPE_MASK (1<<24) 1927#define DISPPLANE_SEL_PIPE_MASK (1<<24)
@@ -1918,7 +1933,7 @@
1918#define DISPPLANE_NO_LINE_DOUBLE 0 1933#define DISPPLANE_NO_LINE_DOUBLE 0
1919#define DISPPLANE_STEREO_POLARITY_FIRST 0 1934#define DISPPLANE_STEREO_POLARITY_FIRST 0
1920#define DISPPLANE_STEREO_POLARITY_SECOND (1<<18) 1935#define DISPPLANE_STEREO_POLARITY_SECOND (1<<18)
1921#define DISPPLANE_TRICKLE_FEED_DISABLE (1<<14) /* IGDNG */ 1936#define DISPPLANE_TRICKLE_FEED_DISABLE (1<<14) /* Ironlake */
1922#define DISPPLANE_TILED (1<<10) 1937#define DISPPLANE_TILED (1<<10)
1923#define DSPAADDR 0x70184 1938#define DSPAADDR 0x70184
1924#define DSPASTRIDE 0x70188 1939#define DSPASTRIDE 0x70188
@@ -1971,7 +1986,7 @@
1971# define VGA_2X_MODE (1 << 30) 1986# define VGA_2X_MODE (1 << 30)
1972# define VGA_PIPE_B_SELECT (1 << 29) 1987# define VGA_PIPE_B_SELECT (1 << 29)
1973 1988
1974/* IGDNG */ 1989/* Ironlake */
1975 1990
1976#define CPU_VGACNTRL 0x41000 1991#define CPU_VGACNTRL 0x41000
1977 1992
@@ -2117,6 +2132,7 @@
2117#define SDE_PORTC_HOTPLUG (1 << 9) 2132#define SDE_PORTC_HOTPLUG (1 << 9)
2118#define SDE_PORTB_HOTPLUG (1 << 8) 2133#define SDE_PORTB_HOTPLUG (1 << 8)
2119#define SDE_SDVOB_HOTPLUG (1 << 6) 2134#define SDE_SDVOB_HOTPLUG (1 << 6)
2135#define SDE_HOTPLUG_MASK (0xf << 8)
2120 2136
2121#define SDEISR 0xc4000 2137#define SDEISR 0xc4000
2122#define SDEIMR 0xc4004 2138#define SDEIMR 0xc4004
@@ -2157,6 +2173,13 @@
2157#define PCH_GPIOE 0xc5020 2173#define PCH_GPIOE 0xc5020
2158#define PCH_GPIOF 0xc5024 2174#define PCH_GPIOF 0xc5024
2159 2175
2176#define PCH_GMBUS0 0xc5100
2177#define PCH_GMBUS1 0xc5104
2178#define PCH_GMBUS2 0xc5108
2179#define PCH_GMBUS3 0xc510c
2180#define PCH_GMBUS4 0xc5110
2181#define PCH_GMBUS5 0xc5120
2182
2160#define PCH_DPLL_A 0xc6014 2183#define PCH_DPLL_A 0xc6014
2161#define PCH_DPLL_B 0xc6018 2184#define PCH_DPLL_B 0xc6018
2162 2185
@@ -2292,7 +2315,7 @@
2292#define FDI_DP_PORT_WIDTH_X3 (2<<19) 2315#define FDI_DP_PORT_WIDTH_X3 (2<<19)
2293#define FDI_DP_PORT_WIDTH_X4 (3<<19) 2316#define FDI_DP_PORT_WIDTH_X4 (3<<19)
2294#define FDI_TX_ENHANCE_FRAME_ENABLE (1<<18) 2317#define FDI_TX_ENHANCE_FRAME_ENABLE (1<<18)
2295/* IGDNG: hardwired to 1 */ 2318/* Ironlake: hardwired to 1 */
2296#define FDI_TX_PLL_ENABLE (1<<14) 2319#define FDI_TX_PLL_ENABLE (1<<14)
2297/* both Tx and Rx */ 2320/* both Tx and Rx */
2298#define FDI_SCRAMBLING_ENABLE (0<<7) 2321#define FDI_SCRAMBLING_ENABLE (0<<7)