blob: 3af3c6426a6e7785091a3a97d1c780d30fde7384 [file] [log] [blame]
Alex Deucher65388342010-03-05 19:22:24 -05001/*
2 * Copyright 2009 Advanced Micro Devices, Inc.
3 *
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
10 *
11 * The above copyright notice and this permission notice (including the next
12 * paragraph) shall be included in all copies or substantial portions of the
13 * Software.
14 *
15 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
18 * THE COPYRIGHT HOLDER(S) AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
19 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
20 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21 * DEALINGS IN THE SOFTWARE.
22 *
23 * Authors:
24 * Alex Deucher <alexander.deucher@amd.com>
25 */
Jerome Glisse3ce0a232009-09-08 10:10:24 +100026
Paul Gortmaker50af5ea2012-01-20 18:35:53 -050027#include <linux/bug.h>
Jerome Glisse3ce0a232009-09-08 10:10:24 +100028#include <linux/types.h>
29#include <linux/kernel.h>
30
Alex Deucher65388342010-03-05 19:22:24 -050031/*
32 * R6xx+ cards need to use the 3D engine to blit data which requires
33 * quite a bit of hw state setup. Rather than pull the whole 3D driver
34 * (which normally generates the 3D state) into the DRM, we opt to use
35 * statically generated state tables. The regsiter state and shaders
36 * were hand generated to support blitting functionality. See the 3D
37 * driver or documentation for descriptions of the registers and
38 * shader instructions.
39 */
40
Jerome Glisse3ce0a232009-09-08 10:10:24 +100041const u32 r6xx_default_state[] =
42{
Alex Deucher8c119e92010-07-26 12:39:00 -040043 0xc0002400, /* START_3D_CMDBUF */
Jerome Glisse3ce0a232009-09-08 10:10:24 +100044 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -040045
46 0xc0012800, /* CONTEXT_CONTROL */
Jerome Glisse3ce0a232009-09-08 10:10:24 +100047 0x80000000,
48 0x80000000,
Alex Deucher8c119e92010-07-26 12:39:00 -040049
Jerome Glisse3ce0a232009-09-08 10:10:24 +100050 0xc0016800,
51 0x00000010,
Alex Deucher8c119e92010-07-26 12:39:00 -040052 0x00008000, /* WAIT_UNTIL */
53
Jerome Glisse3ce0a232009-09-08 10:10:24 +100054 0xc0016800,
55 0x00000542,
Alex Deucher8c119e92010-07-26 12:39:00 -040056 0x07000003, /* TA_CNTL_AUX */
57
Jerome Glisse3ce0a232009-09-08 10:10:24 +100058 0xc0016800,
59 0x000005c5,
Alex Deucher8c119e92010-07-26 12:39:00 -040060 0x00000000, /* VC_ENHANCE */
61
Jerome Glisse3ce0a232009-09-08 10:10:24 +100062 0xc0016800,
63 0x00000363,
Alex Deucher8c119e92010-07-26 12:39:00 -040064 0x00000000, /* SQ_DYN_GPR_CNTL_PS_FLUSH_REQ */
65
Jerome Glisse3ce0a232009-09-08 10:10:24 +100066 0xc0016800,
67 0x0000060c,
Alex Deucher8c119e92010-07-26 12:39:00 -040068 0x82000000, /* DB_DEBUG */
69
Jerome Glisse3ce0a232009-09-08 10:10:24 +100070 0xc0016800,
71 0x0000060e,
Alex Deucher8c119e92010-07-26 12:39:00 -040072 0x01020204, /* DB_WATERMARKS */
73
Alex Deuchereb544432010-07-27 18:57:06 -040074 0xc0026f00,
Jerome Glisse3ce0a232009-09-08 10:10:24 +100075 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -040076 0x00000000, /* SQ_VTX_BASE_VTX_LOC */
Alex Deucher8c119e92010-07-26 12:39:00 -040077 0x00000000, /* SQ_VTX_START_INST_LOC */
78
Jerome Glisse3ce0a232009-09-08 10:10:24 +100079 0xc0096900,
80 0x0000022a,
Alex Deucher8c119e92010-07-26 12:39:00 -040081 0x00000000, /* SQ_ESGS_RING_ITEMSIZE */
Jerome Glisse3ce0a232009-09-08 10:10:24 +100082 0x00000000,
83 0x00000000,
84 0x00000000,
85 0x00000000,
86 0x00000000,
87 0x00000000,
88 0x00000000,
89 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -040090
Jerome Glisse3ce0a232009-09-08 10:10:24 +100091 0xc0016900,
92 0x00000004,
Alex Deucher8c119e92010-07-26 12:39:00 -040093 0x00000000, /* DB_DEPTH_INFO */
94
Alex Deuchereb544432010-07-27 18:57:06 -040095 0xc0026900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +100096 0x0000000a,
Alex Deucher8c119e92010-07-26 12:39:00 -040097 0x00000000, /* DB_STENCIL_CLEAR */
Alex Deucher8c119e92010-07-26 12:39:00 -040098 0x00000000, /* DB_DEPTH_CLEAR */
99
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000100 0xc0016900,
101 0x00000200,
Alex Deucher8c119e92010-07-26 12:39:00 -0400102 0x00000000, /* DB_DEPTH_CONTROL */
103
Alex Deuchereb544432010-07-27 18:57:06 -0400104 0xc0026900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000105 0x00000343,
Alex Deucher8c119e92010-07-26 12:39:00 -0400106 0x00000060, /* DB_RENDER_CONTROL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400107 0x00000040, /* DB_RENDER_OVERRIDE */
108
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000109 0xc0016900,
110 0x00000351,
Alex Deucher8c119e92010-07-26 12:39:00 -0400111 0x0000aa00, /* DB_ALPHA_TO_MASK */
112
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400113 0xc00f6900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400114 0x00000100,
115 0x00000800, /* VGT_MAX_VTX_INDX */
116 0x00000000, /* VGT_MIN_VTX_INDX */
117 0x00000000, /* VGT_INDX_OFFSET */
Alex Deucherd0623a32010-07-27 11:17:44 -0400118 0x00000000, /* VGT_MULTI_PRIM_IB_RESET_INDX */
Alex Deucher8c119e92010-07-26 12:39:00 -0400119 0x00000000, /* SX_ALPHA_TEST_CONTROL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400120 0x00000000, /* CB_BLEND_RED */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000121 0x00000000,
122 0x00000000,
123 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400124 0x00000000, /* CB_FOG_RED */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000125 0x00000000,
126 0x00000000,
Alex Deucherd0623a32010-07-27 11:17:44 -0400127 0x00000000, /* DB_STENCILREFMASK */
128 0x00000000, /* DB_STENCILREFMASK_BF */
Alex Deucherd0623a32010-07-27 11:17:44 -0400129 0x00000000, /* SX_ALPHA_REF */
130
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000131 0xc0046900,
132 0x0000030c,
Alex Deucher8c119e92010-07-26 12:39:00 -0400133 0x01000000, /* CB_CLRCMP_CNTL */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000134 0x00000000,
135 0x00000000,
136 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400137
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000138 0xc0046900,
139 0x00000048,
Alex Deucher8c119e92010-07-26 12:39:00 -0400140 0x3f800000, /* CB_CLEAR_RED */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000141 0x00000000,
142 0x3f800000,
143 0x3f800000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400144
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000145 0xc0016900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000146 0x00000080,
Alex Deucher8c119e92010-07-26 12:39:00 -0400147 0x00000000, /* PA_SC_WINDOW_OFFSET */
148
Alex Deuchereb544432010-07-27 18:57:06 -0400149 0xc00a6900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000150 0x00000083,
Alex Deucher8c119e92010-07-26 12:39:00 -0400151 0x0000ffff, /* PA_SC_CLIP_RECT_RULE */
Alex Deuchereb544432010-07-27 18:57:06 -0400152 0x00000000, /* PA_SC_CLIPRECT_0_TL */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000153 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000154 0x00000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000155 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000156 0x00000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000157 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000158 0x00000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000159 0x20002000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400160 0x00000000, /* PA_SC_EDGERULE */
161
Alex Deucher363c6a12010-07-26 13:47:54 -0400162 0xc0406900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000163 0x00000094,
Alex Deucher8c119e92010-07-26 12:39:00 -0400164 0x80000000, /* PA_SC_VPORT_SCISSOR_0_TL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400165 0x20002000, /* PA_SC_VPORT_SCISSOR_0_BR */
Alex Deucher8c119e92010-07-26 12:39:00 -0400166 0x80000000, /* PA_SC_VPORT_SCISSOR_1_TL */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000167 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000168 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000169 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000170 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000171 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000172 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000173 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000174 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000175 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000176 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000177 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000178 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000179 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000180 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000181 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000182 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000183 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000184 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000185 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000186 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000187 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000188 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000189 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000190 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000191 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000192 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000193 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000194 0x80000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000195 0x20002000,
Alex Deucher363c6a12010-07-26 13:47:54 -0400196 0x00000000, /* PA_SC_VPORT_ZMIN_0 */
197 0x3f800000,
198 0x00000000,
199 0x3f800000,
200 0x00000000,
201 0x3f800000,
202 0x00000000,
203 0x3f800000,
204 0x00000000,
205 0x3f800000,
206 0x00000000,
207 0x3f800000,
208 0x00000000,
209 0x3f800000,
210 0x00000000,
211 0x3f800000,
212 0x00000000,
213 0x3f800000,
214 0x00000000,
215 0x3f800000,
216 0x00000000,
217 0x3f800000,
218 0x00000000,
219 0x3f800000,
220 0x00000000,
221 0x3f800000,
222 0x00000000,
223 0x3f800000,
224 0x00000000,
225 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000226 0x00000000,
227 0x3f800000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400228
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400229 0xc0026900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000230 0x00000292,
Alex Deucher8c119e92010-07-26 12:39:00 -0400231 0x00000000, /* PA_SC_MPASS_PS_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400232 0x00004010, /* PA_SC_MODE_CNTL */
233
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400234 0xc0096900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400235 0x00000300,
236 0x00000000, /* PA_SC_LINE_CNTL */
237 0x00000000, /* PA_SC_AA_CONFIG */
Alex Deucherd0623a32010-07-27 11:17:44 -0400238 0x0000002d, /* PA_SU_VTX_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400239 0x3f800000, /* PA_CL_GB_VERT_CLIP_ADJ */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000240 0x3f800000,
241 0x3f800000,
242 0x3f800000,
Alex Deucherd0623a32010-07-27 11:17:44 -0400243 0x00000000, /* PA_SC_SAMPLE_LOCS_MCTX */
244 0x00000000,
245
246 0xc0016900,
247 0x00000312,
248 0xffffffff, /* PA_SC_AA_MASK */
Alex Deucher8c119e92010-07-26 12:39:00 -0400249
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400250 0xc0066900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000251 0x0000037e,
Alex Deucher8c119e92010-07-26 12:39:00 -0400252 0x00000000, /* PA_SU_POLY_OFFSET_DB_FMT_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400253 0x00000000, /* PA_SU_POLY_OFFSET_CLAMP */
Alex Deucher8c119e92010-07-26 12:39:00 -0400254 0x00000000, /* PA_SU_POLY_OFFSET_FRONT_SCALE */
Alex Deucher8c119e92010-07-26 12:39:00 -0400255 0x00000000, /* PA_SU_POLY_OFFSET_FRONT_OFFSET */
Alex Deucherd0623a32010-07-27 11:17:44 -0400256 0x00000000, /* PA_SU_POLY_OFFSET_BACK_SCALE */
Alex Deucherd0623a32010-07-27 11:17:44 -0400257 0x00000000, /* PA_SU_POLY_OFFSET_BACK_OFFSET */
Alex Deucher8c119e92010-07-26 12:39:00 -0400258
Alex Deuchereb544432010-07-27 18:57:06 -0400259 0xc0046900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000260 0x000001b6,
Alex Deucher8c119e92010-07-26 12:39:00 -0400261 0x00000000, /* SPI_INPUT_Z */
Alex Deucher8c119e92010-07-26 12:39:00 -0400262 0x00000000, /* SPI_FOG_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400263 0x00000000, /* SPI_FOG_FUNC_SCALE */
Alex Deucher8c119e92010-07-26 12:39:00 -0400264 0x00000000, /* SPI_FOG_FUNC_BIAS */
265
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000266 0xc0016900,
267 0x00000225,
Alex Deucher8c119e92010-07-26 12:39:00 -0400268 0x00000000, /* SQ_PGM_START_FS */
269
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000270 0xc0016900,
271 0x00000229,
Alex Deucher8c119e92010-07-26 12:39:00 -0400272 0x00000000, /* SQ_PGM_RESOURCES_FS */
273
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000274 0xc0016900,
275 0x00000237,
Alex Deucher8c119e92010-07-26 12:39:00 -0400276 0x00000000, /* SQ_PGM_CF_OFFSET_FS */
277
Alex Deuchereb544432010-07-27 18:57:06 -0400278 0xc0026900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000279 0x000002a8,
Alex Deucher8c119e92010-07-26 12:39:00 -0400280 0x00000000, /* VGT_INSTANCE_STEP_RATE_0 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400281 0x00000000, /* VGT_INSTANCE_STEP_RATE_1 */
282
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400283 0xc0116900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400284 0x00000280,
285 0x00000000, /* PA_SU_POINT_SIZE */
286 0x00000000, /* PA_SU_POINT_MINMAX */
Alex Deucherd0623a32010-07-27 11:17:44 -0400287 0x00000008, /* PA_SU_LINE_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400288 0x00000000, /* PA_SC_LINE_STIPPLE */
Alex Deucher8c119e92010-07-26 12:39:00 -0400289 0x00000000, /* VGT_OUTPUT_PATH_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400290 0x00000000, /* VGT_HOS_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400291 0x00000000, /* VGT_HOS_MAX_TESS_LEVEL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400292 0x00000000, /* VGT_HOS_MIN_TESS_LEVEL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400293 0x00000000, /* VGT_HOS_REUSE_DEPTH */
Alex Deucher8c119e92010-07-26 12:39:00 -0400294 0x00000000, /* VGT_GROUP_PRIM_TYPE */
Alex Deucher8c119e92010-07-26 12:39:00 -0400295 0x00000000, /* VGT_GROUP_FIRST_DECR */
Alex Deucher8c119e92010-07-26 12:39:00 -0400296 0x00000000, /* VGT_GROUP_DECR */
Alex Deucher8c119e92010-07-26 12:39:00 -0400297 0x00000000, /* VGT_GROUP_VECT_0_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400298 0x00000000, /* VGT_GROUP_VECT_1_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400299 0x00000000, /* VGT_GROUP_VECT_0_FMT_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400300 0x00000000, /* VGT_GROUP_VECT_1_FMT_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400301 0x00000000, /* VGT_GS_MODE */
302
303 0xc0016900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000304 0x000002a1,
Alex Deucher8c119e92010-07-26 12:39:00 -0400305 0x00000000, /* VGT_PRIMITIVEID_EN */
306
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000307 0xc0016900,
308 0x000002a5,
Alex Deucher8c119e92010-07-26 12:39:00 -0400309 0x00000000, /* VGT_MULTI_PRIM_ID_RESET_EN */
310
Alex Deuchereb544432010-07-27 18:57:06 -0400311 0xc0036900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000312 0x000002ac,
Alex Deucher8c119e92010-07-26 12:39:00 -0400313 0x00000000, /* VGT_STRMOUT_EN */
Alex Deucher8c119e92010-07-26 12:39:00 -0400314 0x00000000, /* VGT_REUSE_OFF */
Alex Deucher8c119e92010-07-26 12:39:00 -0400315 0x00000000, /* VGT_VTX_CNT_EN */
316
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000317 0xc0016900,
318 0x000002c8,
Alex Deucher8c119e92010-07-26 12:39:00 -0400319 0x00000000, /* VGT_STRMOUT_BUFFER_EN */
320
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400321 0xc0076900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400322 0x00000202,
323 0x00cc0000, /* CB_COLOR_CONTROL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400324 0x00000210, /* DB_SHADER_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400325 0x00010000, /* PA_CL_CLIP_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400326 0x00000244, /* PA_SU_SC_MODE_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400327 0x00000100, /* PA_CL_VTE_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400328 0x00000000, /* PA_CL_VS_OUT_CNTL */
329 0x00000000, /* PA_CL_NANINF_CNTL */
330
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400331 0xc0026900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400332 0x0000008e,
333 0x0000000f, /* CB_TARGET_MASK */
Alex Deucher8c119e92010-07-26 12:39:00 -0400334 0x0000000f, /* CB_SHADER_MASK */
335
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000336 0xc0016900,
337 0x000001e8,
Alex Deucher8c119e92010-07-26 12:39:00 -0400338 0x00000001, /* CB_SHADER_CONTROL */
339
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000340 0xc0016900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400341 0x00000185,
342 0x00000000, /* SPI_VS_OUT_ID_0 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400343
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000344 0xc0016900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400345 0x00000191,
346 0x00000b00, /* SPI_PS_INPUT_CNTL_0 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400347
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400348 0xc0056900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000349 0x000001b1,
Alex Deucher8c119e92010-07-26 12:39:00 -0400350 0x00000000, /* SPI_VS_OUT_CONFIG */
Alex Deucherd0623a32010-07-27 11:17:44 -0400351 0x00000000, /* SPI_THREAD_GROUPING */
Alex Deucher8c119e92010-07-26 12:39:00 -0400352 0x00000001, /* SPI_PS_IN_CONTROL_0 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400353 0x00000000, /* SPI_PS_IN_CONTROL_1 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400354 0x00000000, /* SPI_INTERP_CONTROL_0 */
Alex Deucherd0623a32010-07-27 11:17:44 -0400355
356 0xc0036e00, /* SET_SAMPLER */
357 0x00000000,
358 0x00000012,
359 0x00000000,
360 0x00000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000361};
362
363const u32 r7xx_default_state[] =
364{
Alex Deucher8c119e92010-07-26 12:39:00 -0400365 0xc0012800, /* CONTEXT_CONTROL */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000366 0x80000000,
367 0x80000000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400368
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000369 0xc0016800,
370 0x00000010,
Alex Deucher8c119e92010-07-26 12:39:00 -0400371 0x00008000, /* WAIT_UNTIL */
372
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000373 0xc0016800,
374 0x00000542,
Alex Deucher8c119e92010-07-26 12:39:00 -0400375 0x07000002, /* TA_CNTL_AUX */
376
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000377 0xc0016800,
378 0x000005c5,
Alex Deucher8c119e92010-07-26 12:39:00 -0400379 0x00000000, /* VC_ENHANCE */
380
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000381 0xc0016800,
382 0x00000363,
Alex Deucher8c119e92010-07-26 12:39:00 -0400383 0x00004000, /* SQ_DYN_GPR_CNTL_PS_FLUSH_REQ */
384
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000385 0xc0016800,
386 0x0000060c,
Alex Deucher8c119e92010-07-26 12:39:00 -0400387 0x00000000, /* DB_DEBUG */
388
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000389 0xc0016800,
390 0x0000060e,
Alex Deucher8c119e92010-07-26 12:39:00 -0400391 0x00420204, /* DB_WATERMARKS */
392
Alex Deuchereb544432010-07-27 18:57:06 -0400393 0xc0026f00,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000394 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400395 0x00000000, /* SQ_VTX_BASE_VTX_LOC */
Alex Deucher8c119e92010-07-26 12:39:00 -0400396 0x00000000, /* SQ_VTX_START_INST_LOC */
397
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000398 0xc0096900,
399 0x0000022a,
Alex Deucher8c119e92010-07-26 12:39:00 -0400400 0x00000000, /* SQ_ESGS_RING_ITEMSIZE */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000401 0x00000000,
402 0x00000000,
403 0x00000000,
404 0x00000000,
405 0x00000000,
406 0x00000000,
407 0x00000000,
408 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400409
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000410 0xc0016900,
411 0x00000004,
Alex Deucher8c119e92010-07-26 12:39:00 -0400412 0x00000000, /* DB_DEPTH_INFO */
413
Alex Deuchereb544432010-07-27 18:57:06 -0400414 0xc0026900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000415 0x0000000a,
Alex Deucher8c119e92010-07-26 12:39:00 -0400416 0x00000000, /* DB_STENCIL_CLEAR */
Alex Deucher8c119e92010-07-26 12:39:00 -0400417 0x00000000, /* DB_DEPTH_CLEAR */
418
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000419 0xc0016900,
420 0x00000200,
Alex Deucher8c119e92010-07-26 12:39:00 -0400421 0x00000000, /* DB_DEPTH_CONTROL */
422
Alex Deuchereb544432010-07-27 18:57:06 -0400423 0xc0026900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000424 0x00000343,
Alex Deucher8c119e92010-07-26 12:39:00 -0400425 0x00000060, /* DB_RENDER_CONTROL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400426 0x00000000, /* DB_RENDER_OVERRIDE */
427
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000428 0xc0016900,
429 0x00000351,
Alex Deucher8c119e92010-07-26 12:39:00 -0400430 0x0000aa00, /* DB_ALPHA_TO_MASK */
431
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400432 0xc0096900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400433 0x00000100,
434 0x00000800, /* VGT_MAX_VTX_INDX */
435 0x00000000, /* VGT_MIN_VTX_INDX */
436 0x00000000, /* VGT_INDX_OFFSET */
Alex Deucherd0623a32010-07-27 11:17:44 -0400437 0x00000000, /* VGT_MULTI_PRIM_IB_RESET_INDX */
Alex Deucher8c119e92010-07-26 12:39:00 -0400438 0x00000000, /* SX_ALPHA_TEST_CONTROL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400439 0x00000000, /* CB_BLEND_RED */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000440 0x00000000,
441 0x00000000,
442 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400443
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400444 0xc0036900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400445 0x0000010c,
446 0x00000000, /* DB_STENCILREFMASK */
447 0x00000000, /* DB_STENCILREFMASK_BF */
Alex Deucherd0623a32010-07-27 11:17:44 -0400448 0x00000000, /* SX_ALPHA_REF */
449
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000450 0xc0046900,
Alex Deucher8c119e92010-07-26 12:39:00 -0400451 0x0000030c, /* CB_CLRCMP_CNTL */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000452 0x01000000,
453 0x00000000,
454 0x00000000,
455 0x00000000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400456
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000457 0xc0016900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000458 0x00000080,
Alex Deucher8c119e92010-07-26 12:39:00 -0400459 0x00000000, /* PA_SC_WINDOW_OFFSET */
460
Alex Deuchereb544432010-07-27 18:57:06 -0400461 0xc00a6900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000462 0x00000083,
Alex Deucher8c119e92010-07-26 12:39:00 -0400463 0x0000ffff, /* PA_SC_CLIP_RECT_RULE */
Alex Deuchereb544432010-07-27 18:57:06 -0400464 0x00000000, /* PA_SC_CLIPRECT_0_TL */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000465 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000466 0x00000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000467 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000468 0x00000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000469 0x20002000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000470 0x00000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000471 0x20002000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400472 0xaaaaaaaa, /* PA_SC_EDGERULE */
473
Alex Deucher363c6a12010-07-26 13:47:54 -0400474 0xc0406900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000475 0x00000094,
Alex Deucher8c119e92010-07-26 12:39:00 -0400476 0x80000000, /* PA_SC_VPORT_SCISSOR_0_TL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400477 0x20002000, /* PA_SC_VPORT_SCISSOR_0_BR */
Alex Deucher363c6a12010-07-26 13:47:54 -0400478 0x80000000, /* PA_SC_VPORT_SCISSOR_1_TL */
479 0x20002000,
480 0x80000000,
481 0x20002000,
482 0x80000000,
483 0x20002000,
484 0x80000000,
485 0x20002000,
486 0x80000000,
487 0x20002000,
488 0x80000000,
489 0x20002000,
490 0x80000000,
491 0x20002000,
492 0x80000000,
493 0x20002000,
494 0x80000000,
495 0x20002000,
496 0x80000000,
497 0x20002000,
498 0x80000000,
499 0x20002000,
500 0x80000000,
501 0x20002000,
502 0x80000000,
503 0x20002000,
504 0x80000000,
505 0x20002000,
506 0x80000000,
507 0x20002000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400508 0x00000000, /* PA_SC_VPORT_ZMIN_0 */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000509 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000510 0x00000000,
511 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000512 0x00000000,
513 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000514 0x00000000,
515 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000516 0x00000000,
517 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000518 0x00000000,
519 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000520 0x00000000,
521 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000522 0x00000000,
523 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000524 0x00000000,
525 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000526 0x00000000,
527 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000528 0x00000000,
529 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000530 0x00000000,
531 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000532 0x00000000,
533 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000534 0x00000000,
535 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000536 0x00000000,
537 0x3f800000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000538 0x00000000,
539 0x3f800000,
Alex Deucher8c119e92010-07-26 12:39:00 -0400540
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400541 0xc0026900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000542 0x00000292,
Alex Deucher8c119e92010-07-26 12:39:00 -0400543 0x00000000, /* PA_SC_MPASS_PS_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400544 0x00514000, /* PA_SC_MODE_CNTL */
545
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400546 0xc0096900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400547 0x00000300,
548 0x00000000, /* PA_SC_LINE_CNTL */
549 0x00000000, /* PA_SC_AA_CONFIG */
Alex Deucherd0623a32010-07-27 11:17:44 -0400550 0x0000002d, /* PA_SU_VTX_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400551 0x3f800000, /* PA_CL_GB_VERT_CLIP_ADJ */
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000552 0x3f800000,
553 0x3f800000,
554 0x3f800000,
Alex Deucherd0623a32010-07-27 11:17:44 -0400555 0x00000000, /* PA_SC_SAMPLE_LOCS_MCTX */
556 0x00000000,
557
558 0xc0016900,
559 0x00000312,
560 0xffffffff, /* PA_SC_AA_MASK */
Alex Deucher8c119e92010-07-26 12:39:00 -0400561
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400562 0xc0066900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000563 0x0000037e,
Alex Deucher8c119e92010-07-26 12:39:00 -0400564 0x00000000, /* PA_SU_POLY_OFFSET_DB_FMT_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400565 0x00000000, /* PA_SU_POLY_OFFSET_CLAMP */
Alex Deucher8c119e92010-07-26 12:39:00 -0400566 0x00000000, /* PA_SU_POLY_OFFSET_FRONT_SCALE */
Alex Deucher8c119e92010-07-26 12:39:00 -0400567 0x00000000, /* PA_SU_POLY_OFFSET_FRONT_OFFSET */
Alex Deucherd0623a32010-07-27 11:17:44 -0400568 0x00000000, /* PA_SU_POLY_OFFSET_BACK_SCALE */
Alex Deucherd0623a32010-07-27 11:17:44 -0400569 0x00000000, /* PA_SU_POLY_OFFSET_BACK_OFFSET */
Alex Deucher8c119e92010-07-26 12:39:00 -0400570
Alex Deuchereb544432010-07-27 18:57:06 -0400571 0xc0046900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000572 0x000001b6,
Alex Deucher8c119e92010-07-26 12:39:00 -0400573 0x00000000, /* SPI_INPUT_Z */
Alex Deucher8c119e92010-07-26 12:39:00 -0400574 0x00000000, /* SPI_FOG_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400575 0x00000000, /* SPI_FOG_FUNC_SCALE */
Alex Deucher8c119e92010-07-26 12:39:00 -0400576 0x00000000, /* SPI_FOG_FUNC_BIAS */
577
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000578 0xc0016900,
579 0x00000225,
Alex Deucher8c119e92010-07-26 12:39:00 -0400580 0x00000000, /* SQ_PGM_START_FS */
581
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000582 0xc0016900,
583 0x00000229,
Alex Deucher8c119e92010-07-26 12:39:00 -0400584 0x00000000, /* SQ_PGM_RESOURCES_FS */
585
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000586 0xc0016900,
587 0x00000237,
Alex Deucher8c119e92010-07-26 12:39:00 -0400588 0x00000000, /* SQ_PGM_CF_OFFSET_FS */
589
Alex Deuchereb544432010-07-27 18:57:06 -0400590 0xc0026900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000591 0x000002a8,
Alex Deucher8c119e92010-07-26 12:39:00 -0400592 0x00000000, /* VGT_INSTANCE_STEP_RATE_0 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400593 0x00000000, /* VGT_INSTANCE_STEP_RATE_1 */
594
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400595 0xc0116900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400596 0x00000280,
597 0x00000000, /* PA_SU_POINT_SIZE */
598 0x00000000, /* PA_SU_POINT_MINMAX */
Alex Deucherd0623a32010-07-27 11:17:44 -0400599 0x00000008, /* PA_SU_LINE_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400600 0x00000000, /* PA_SC_LINE_STIPPLE */
Alex Deucher8c119e92010-07-26 12:39:00 -0400601 0x00000000, /* VGT_OUTPUT_PATH_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400602 0x00000000, /* VGT_HOS_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400603 0x00000000, /* VGT_HOS_MAX_TESS_LEVEL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400604 0x00000000, /* VGT_HOS_MIN_TESS_LEVEL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400605 0x00000000, /* VGT_HOS_REUSE_DEPTH */
Alex Deucher8c119e92010-07-26 12:39:00 -0400606 0x00000000, /* VGT_GROUP_PRIM_TYPE */
Alex Deucher8c119e92010-07-26 12:39:00 -0400607 0x00000000, /* VGT_GROUP_FIRST_DECR */
Alex Deucher8c119e92010-07-26 12:39:00 -0400608 0x00000000, /* VGT_GROUP_DECR */
Alex Deucher8c119e92010-07-26 12:39:00 -0400609 0x00000000, /* VGT_GROUP_VECT_0_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400610 0x00000000, /* VGT_GROUP_VECT_1_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400611 0x00000000, /* VGT_GROUP_VECT_0_FMT_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400612 0x00000000, /* VGT_GROUP_VECT_1_FMT_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400613 0x00000000, /* VGT_GS_MODE */
614
615 0xc0016900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000616 0x000002a1,
Alex Deucher8c119e92010-07-26 12:39:00 -0400617 0x00000000, /* VGT_PRIMITIVEID_EN */
618
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000619 0xc0016900,
620 0x000002a5,
Alex Deucher8c119e92010-07-26 12:39:00 -0400621 0x00000000, /* VGT_MULTI_PRIM_ID_RESET_EN */
622
Alex Deuchereb544432010-07-27 18:57:06 -0400623 0xc0036900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000624 0x000002ac,
Alex Deucher8c119e92010-07-26 12:39:00 -0400625 0x00000000, /* VGT_STRMOUT_EN */
Alex Deucher8c119e92010-07-26 12:39:00 -0400626 0x00000000, /* VGT_REUSE_OFF */
Alex Deucher8c119e92010-07-26 12:39:00 -0400627 0x00000000, /* VGT_VTX_CNT_EN */
628
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000629 0xc0016900,
630 0x000002c8,
Alex Deucher8c119e92010-07-26 12:39:00 -0400631 0x00000000, /* VGT_STRMOUT_BUFFER_EN */
632
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400633 0xc0076900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400634 0x00000202,
635 0x00cc0000, /* CB_COLOR_CONTROL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400636 0x00000210, /* DB_SHADER_CNTL */
Alex Deucher8c119e92010-07-26 12:39:00 -0400637 0x00010000, /* PA_CL_CLIP_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400638 0x00000244, /* PA_SU_SC_MODE_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400639 0x00000100, /* PA_CL_VTE_CNTL */
Alex Deucherd0623a32010-07-27 11:17:44 -0400640 0x00000000, /* PA_CL_VS_OUT_CNTL */
641 0x00000000, /* PA_CL_NANINF_CNTL */
642
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400643 0xc0026900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400644 0x0000008e,
645 0x0000000f, /* CB_TARGET_MASK */
Alex Deucher8c119e92010-07-26 12:39:00 -0400646 0x0000000f, /* CB_SHADER_MASK */
647
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000648 0xc0016900,
649 0x000001e8,
Alex Deucher8c119e92010-07-26 12:39:00 -0400650 0x00000001, /* CB_SHADER_CONTROL */
651
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000652 0xc0016900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400653 0x00000185,
654 0x00000000, /* SPI_VS_OUT_ID_0 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400655
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000656 0xc0016900,
Alex Deucherd0623a32010-07-27 11:17:44 -0400657 0x00000191,
658 0x00000b00, /* SPI_PS_INPUT_CNTL_0 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400659
Alex Deucher43a7d2d2010-07-27 11:20:54 -0400660 0xc0056900,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000661 0x000001b1,
Alex Deucher8c119e92010-07-26 12:39:00 -0400662 0x00000000, /* SPI_VS_OUT_CONFIG */
Alex Deucherd0623a32010-07-27 11:17:44 -0400663 0x00000001, /* SPI_THREAD_GROUPING */
Alex Deucher8c119e92010-07-26 12:39:00 -0400664 0x00000001, /* SPI_PS_IN_CONTROL_0 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400665 0x00000000, /* SPI_PS_IN_CONTROL_1 */
Alex Deucher8c119e92010-07-26 12:39:00 -0400666 0x00000000, /* SPI_INTERP_CONTROL_0 */
Alex Deucherd0623a32010-07-27 11:17:44 -0400667
668 0xc0036e00, /* SET_SAMPLER */
669 0x00000000,
670 0x00000012,
671 0x00000000,
672 0x00000000,
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000673};
674
675/* same for r6xx/r7xx */
676const u32 r6xx_vs[] =
677{
678 0x00000004,
679 0x81000000,
680 0x0000203c,
681 0x94000b08,
682 0x00004000,
683 0x14200b1a,
684 0x00000000,
685 0x00000000,
686 0x3c000000,
687 0x68cd1000,
Cédric Cano4eace7f2011-02-11 19:45:38 -0500688#ifdef __BIG_ENDIAN
689 0x000a0000,
690#else
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000691 0x00080000,
Cédric Cano4eace7f2011-02-11 19:45:38 -0500692#endif
Jerome Glisse3ce0a232009-09-08 10:10:24 +1000693 0x00000000,
694};
695
696const u32 r6xx_ps[] =
697{
698 0x00000002,
699 0x80800000,
700 0x00000000,
701 0x94200688,
702 0x00000010,
703 0x000d1000,
704 0xb0800000,
705 0x00000000,
706};
707
708const u32 r6xx_ps_size = ARRAY_SIZE(r6xx_ps);
709const u32 r6xx_vs_size = ARRAY_SIZE(r6xx_vs);
710const u32 r6xx_default_size = ARRAY_SIZE(r6xx_default_state);
711const u32 r7xx_default_size = ARRAY_SIZE(r7xx_default_state);