5
#define MI_FLUSH (0x04<<23)
6
#define MI_FLUSH_DW (0x26<<23)
8
#define MI_WRITE_DIRTY_STATE (1<<4)
9
#define MI_END_SCENE (1<<3)
10
#define MI_GLOBAL_SNAPSHOT_COUNT_RESET (1<<3)
11
#define MI_INHIBIT_RENDER_CACHE_FLUSH (1<<2)
12
#define MI_STATE_INSTRUCTION_CACHE_FLUSH (1<<1)
13
#define MI_INVALIDATE_MAP_CACHE (1<<0)
14
/* broadwater flush bits */
15
#define BRW_MI_GLOBAL_SNAPSHOT_RESET (1 << 3)
17
#define MI_BATCH_BUFFER_END (0xA << 23)
21
#define MI_NOOP_WRITE_ID (1<<22)
22
#define MI_NOOP_ID_MASK (1<<22 - 1)
25
#define MI_WAIT_FOR_EVENT (0x03<<23)
26
#define MI_WAIT_FOR_PIPEB_SVBLANK (1<<18)
27
#define MI_WAIT_FOR_PIPEA_SVBLANK (1<<17)
28
#define MI_WAIT_FOR_OVERLAY_FLIP (1<<16)
29
#define MI_WAIT_FOR_PIPEB_VBLANK (1<<7)
30
#define MI_WAIT_FOR_PIPEB_SCAN_LINE_WINDOW (1<<5)
31
#define MI_WAIT_FOR_PIPEA_VBLANK (1<<3)
32
#define MI_WAIT_FOR_PIPEA_SCAN_LINE_WINDOW (1<<1)
34
/* Set the scan line for MI_WAIT_FOR_PIPE?_SCAN_LINE_WINDOW */
35
#define MI_LOAD_SCAN_LINES_INCL (0x12<<23)
36
#define MI_LOAD_SCAN_LINES_DISPLAY_PIPEA (0)
37
#define MI_LOAD_SCAN_LINES_DISPLAY_PIPEB (0x1<<20)
40
#define COLOR_BLT_CMD ((2<<29)|(0x40<<22)|(0x3))
41
#define COLOR_BLT_WRITE_ALPHA (1<<21)
42
#define COLOR_BLT_WRITE_RGB (1<<20)
44
#define XY_COLOR_BLT_CMD ((2<<29)|(0x50<<22)|(0x4))
45
#define XY_COLOR_BLT_WRITE_ALPHA (1<<21)
46
#define XY_COLOR_BLT_WRITE_RGB (1<<20)
47
#define XY_COLOR_BLT_TILED (1<<11)
49
#define XY_SETUP_CLIP_BLT_CMD ((2<<29)|(3<<22)|1)
51
#define XY_SRC_COPY_BLT_CMD ((2<<29)|(0x53<<22)|6)
52
#define XY_SRC_COPY_BLT_WRITE_ALPHA (1<<21)
53
#define XY_SRC_COPY_BLT_WRITE_RGB (1<<20)
54
#define XY_SRC_COPY_BLT_SRC_TILED (1<<15)
55
#define XY_SRC_COPY_BLT_DST_TILED (1<<11)
57
#define SRC_COPY_BLT_CMD ((2<<29)|(0x43<<22)|0x4)
58
#define SRC_COPY_BLT_WRITE_ALPHA (1<<21)
59
#define SRC_COPY_BLT_WRITE_RGB (1<<20)
61
#define XY_PAT_BLT_IMMEDIATE ((2<<29)|(0x72<<22))
63
#define XY_MONO_PAT_BLT_CMD ((0x2<<29)|(0x52<<22)|0x7)
64
#define XY_MONO_PAT_VERT_SEED ((1<<10)|(1<<9)|(1<<8))
65
#define XY_MONO_PAT_HORT_SEED ((1<<14)|(1<<13)|(1<<12))
66
#define XY_MONO_PAT_BLT_WRITE_ALPHA (1<<21)
67
#define XY_MONO_PAT_BLT_WRITE_RGB (1<<20)
69
#define XY_MONO_SRC_BLT_CMD ((0x2<<29)|(0x54<<22)|(0x6))
70
#define XY_MONO_SRC_BLT_WRITE_ALPHA (1<<21)
71
#define XY_MONO_SRC_BLT_WRITE_RGB (1<<20)
74
#define BLT_WRITE_ALPHA (1<<21)
75
#define BLT_WRITE_RGB (1<<20)
76
#define BLT_SRC_TILED (1<<15)
77
#define BLT_DST_TILED (1<<11)
79
#define COLOR_BLT_CMD ((2<<29)|(0x40<<22)|(0x3))
80
#define XY_COLOR_BLT_CMD ((2<<29)|(0x50<<22)|(0x4))
81
#define XY_SETUP_CLIP_BLT_CMD ((2<<29)|(3<<22)|1)
82
#define XY_SRC_COPY_BLT_CMD ((2<<29)|(0x53<<22)|6)
83
#define SRC_COPY_BLT_CMD ((2<<29)|(0x43<<22)|0x4)
84
#define XY_PAT_BLT_IMMEDIATE ((2<<29)|(0x72<<22))
85
#define XY_MONO_PAT_BLT_CMD ((0x2<<29)|(0x52<<22)|0x7)
86
#define XY_MONO_SRC_BLT_CMD ((0x2<<29)|(0x54<<22)|(0x6))
89
#define BRW_3D(Pipeline,Opcode,Subopcode) \
91
((Pipeline) << 27) | \
94
#define PIPE_CONTROL BRW_3D(3, 2, 0)
95
#define PIPE_CONTROL_NOWRITE (0 << 14)
96
#define PIPE_CONTROL_WRITE_QWORD (1 << 14)
97
#define PIPE_CONTROL_WRITE_DEPTH (2 << 14)
98
#define PIPE_CONTROL_WRITE_TIME (3 << 14)
99
#define PIPE_CONTROL_DEPTH_STALL (1 << 13)
100
#define PIPE_CONTROL_WC_FLUSH (1 << 12)
101
#define PIPE_CONTROL_IS_FLUSH (1 << 11)
102
#define PIPE_CONTROL_TC_FLUSH (1 << 10)
103
#define PIPE_CONTROL_NOTIFY_ENABLE (1 << 8)
104
#define PIPE_CONTROL_GLOBAL_GTT (1 << 2)
105
#define PIPE_CONTROL_LOCAL_PGTT (0 << 2)
106
#define PIPE_CONTROL_DEPTH_CACHE_FLUSH (1 << 0)