nv40.c 14.4 KB
Newer Older
1
/*
2
 * Copyright 2012 Red Hat Inc.
3
 *
4 5 6 7 8 9
 * Permission is hereby granted, free of charge, to any person obtaining a
 * copy of this software and associated documentation files (the "Software"),
 * to deal in the Software without restriction, including without limitation
 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
 * and/or sell copies of the Software, and to permit persons to whom the
 * Software is furnished to do so, subject to the following conditions:
10
 *
11 12
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
13
 *
14 15 16 17 18 19 20
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
 * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
 * OTHER DEALINGS IN THE SOFTWARE.
21
 *
22
 * Authors: Ben Skeggs
23
 */
24 25
#include "nv40.h"
#include "regs.h"
26

27
#include <core/client.h>
28 29 30
#include <core/handle.h>
#include <subdev/fb.h>
#include <subdev/timer.h>
31
#include <engine/fifo.h>
32

33
struct nv40_gr_priv {
34
	struct nvkm_gr base;
35
	u32 size;
36
};
37

38
struct nv40_gr_chan {
39
	struct nvkm_gr_chan base;
40 41
};

42
static u64
43
nv40_gr_units(struct nvkm_gr *gr)
44
{
45
	struct nv40_gr_priv *priv = (void *)gr;
46 47 48 49

	return nv_rd32(priv, 0x1540);
}

50 51 52 53
/*******************************************************************************
 * Graphics object classes
 ******************************************************************************/

54
static int
55 56 57
nv40_gr_object_ctor(struct nvkm_object *parent, struct nvkm_object *engine,
		    struct nvkm_oclass *oclass, void *data, u32 size,
		    struct nvkm_object **pobject)
58
{
59
	struct nvkm_gpuobj *obj;
60 61
	int ret;

62 63
	ret = nvkm_gpuobj_create(parent, engine, oclass, 0, parent,
				 20, 16, 0, &obj);
64
	*pobject = nv_object(obj);
65 66 67
	if (ret)
		return ret;

68 69 70 71 72 73 74 75
	nv_wo32(obj, 0x00, nv_mclass(obj));
	nv_wo32(obj, 0x04, 0x00000000);
	nv_wo32(obj, 0x08, 0x00000000);
#ifdef __BIG_ENDIAN
	nv_mo32(obj, 0x08, 0x01000000, 0x01000000);
#endif
	nv_wo32(obj, 0x0c, 0x00000000);
	nv_wo32(obj, 0x10, 0x00000000);
76 77 78
	return 0;
}

79
static struct nvkm_ofuncs
80 81
nv40_gr_ofuncs = {
	.ctor = nv40_gr_object_ctor,
82 83 84 85 86
	.dtor = _nvkm_gpuobj_dtor,
	.init = _nvkm_gpuobj_init,
	.fini = _nvkm_gpuobj_fini,
	.rd32 = _nvkm_gpuobj_rd32,
	.wr32 = _nvkm_gpuobj_wr32,
87
};
88

89
static struct nvkm_oclass
90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106
nv40_gr_sclass[] = {
	{ 0x0012, &nv40_gr_ofuncs, NULL }, /* beta1 */
	{ 0x0019, &nv40_gr_ofuncs, NULL }, /* clip */
	{ 0x0030, &nv40_gr_ofuncs, NULL }, /* null */
	{ 0x0039, &nv40_gr_ofuncs, NULL }, /* m2mf */
	{ 0x0043, &nv40_gr_ofuncs, NULL }, /* rop */
	{ 0x0044, &nv40_gr_ofuncs, NULL }, /* patt */
	{ 0x004a, &nv40_gr_ofuncs, NULL }, /* gdi */
	{ 0x0062, &nv40_gr_ofuncs, NULL }, /* surf2d */
	{ 0x0072, &nv40_gr_ofuncs, NULL }, /* beta4 */
	{ 0x0089, &nv40_gr_ofuncs, NULL }, /* sifm */
	{ 0x008a, &nv40_gr_ofuncs, NULL }, /* ifc */
	{ 0x009f, &nv40_gr_ofuncs, NULL }, /* imageblit */
	{ 0x3062, &nv40_gr_ofuncs, NULL }, /* surf2d (nv40) */
	{ 0x3089, &nv40_gr_ofuncs, NULL }, /* sifm (nv40) */
	{ 0x309e, &nv40_gr_ofuncs, NULL }, /* swzsurf (nv40) */
	{ 0x4097, &nv40_gr_ofuncs, NULL }, /* curie */
107 108 109
	{},
};

110
static struct nvkm_oclass
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
nv44_gr_sclass[] = {
	{ 0x0012, &nv40_gr_ofuncs, NULL }, /* beta1 */
	{ 0x0019, &nv40_gr_ofuncs, NULL }, /* clip */
	{ 0x0030, &nv40_gr_ofuncs, NULL }, /* null */
	{ 0x0039, &nv40_gr_ofuncs, NULL }, /* m2mf */
	{ 0x0043, &nv40_gr_ofuncs, NULL }, /* rop */
	{ 0x0044, &nv40_gr_ofuncs, NULL }, /* patt */
	{ 0x004a, &nv40_gr_ofuncs, NULL }, /* gdi */
	{ 0x0062, &nv40_gr_ofuncs, NULL }, /* surf2d */
	{ 0x0072, &nv40_gr_ofuncs, NULL }, /* beta4 */
	{ 0x0089, &nv40_gr_ofuncs, NULL }, /* sifm */
	{ 0x008a, &nv40_gr_ofuncs, NULL }, /* ifc */
	{ 0x009f, &nv40_gr_ofuncs, NULL }, /* imageblit */
	{ 0x3062, &nv40_gr_ofuncs, NULL }, /* surf2d (nv40) */
	{ 0x3089, &nv40_gr_ofuncs, NULL }, /* sifm (nv40) */
	{ 0x309e, &nv40_gr_ofuncs, NULL }, /* swzsurf (nv40) */
	{ 0x4497, &nv40_gr_ofuncs, NULL }, /* curie */
128 129 130 131 132 133
	{},
};

/*******************************************************************************
 * PGRAPH context
 ******************************************************************************/
134

135
static int
136 137 138
nv40_gr_context_ctor(struct nvkm_object *parent, struct nvkm_object *engine,
		     struct nvkm_oclass *oclass, void *data, u32 size,
		     struct nvkm_object **pobject)
139
{
140 141
	struct nv40_gr_priv *priv = (void *)engine;
	struct nv40_gr_chan *chan;
142 143
	int ret;

144 145
	ret = nvkm_gr_context_create(parent, engine, oclass, NULL, priv->size,
				     16, NVOBJ_FLAG_ZERO_ALLOC, &chan);
146
	*pobject = nv_object(chan);
147 148 149
	if (ret)
		return ret;

150 151 152 153 154 155
	nv40_grctx_fill(nv_device(priv), nv_gpuobj(chan));
	nv_wo32(chan, 0x00000, nv_gpuobj(chan)->addr >> 4);
	return 0;
}

static int
156
nv40_gr_context_fini(struct nvkm_object *object, bool suspend)
157
{
158 159
	struct nv40_gr_priv *priv = (void *)object->engine;
	struct nv40_gr_chan *chan = (void *)object;
160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176
	u32 inst = 0x01000000 | nv_gpuobj(chan)->addr >> 4;
	int ret = 0;

	nv_mask(priv, 0x400720, 0x00000001, 0x00000000);

	if (nv_rd32(priv, 0x40032c) == inst) {
		if (suspend) {
			nv_wr32(priv, 0x400720, 0x00000000);
			nv_wr32(priv, 0x400784, inst);
			nv_mask(priv, 0x400310, 0x00000020, 0x00000020);
			nv_mask(priv, 0x400304, 0x00000001, 0x00000001);
			if (!nv_wait(priv, 0x400300, 0x00000001, 0x00000000)) {
				u32 insn = nv_rd32(priv, 0x400308);
				nv_warn(priv, "ctxprog timeout 0x%08x\n", insn);
				ret = -EBUSY;
			}
		}
177

178 179 180 181 182 183 184
		nv_mask(priv, 0x40032c, 0x01000000, 0x00000000);
	}

	if (nv_rd32(priv, 0x400330) == inst)
		nv_mask(priv, 0x400330, 0x01000000, 0x00000000);

	nv_mask(priv, 0x400720, 0x00000001, 0x00000001);
185 186 187
	return ret;
}

188
static struct nvkm_oclass
189
nv40_gr_cclass = {
190
	.handle = NV_ENGCTX(GR, 0x40),
191
	.ofuncs = &(struct nvkm_ofuncs) {
192
		.ctor = nv40_gr_context_ctor,
193 194
		.dtor = _nvkm_gr_context_dtor,
		.init = _nvkm_gr_context_init,
195
		.fini = nv40_gr_context_fini,
196 197
		.rd32 = _nvkm_gr_context_rd32,
		.wr32 = _nvkm_gr_context_wr32,
198 199 200 201 202 203 204
	},
};

/*******************************************************************************
 * PGRAPH engine/subdev functions
 ******************************************************************************/

205
static void
206
nv40_gr_tile_prog(struct nvkm_engine *engine, int i)
207
{
208
	struct nvkm_fb_tile *tile = &nvkm_fb(engine)->tile.region[i];
B
Ben Skeggs 已提交
209
	struct nvkm_fifo *fifo = nvkm_fifo(engine);
210
	struct nv40_gr_priv *priv = (void *)engine;
211 212
	unsigned long flags;

B
Ben Skeggs 已提交
213
	fifo->pause(fifo, &flags);
214
	nv04_gr_idle(priv);
215

216
	switch (nv_device(priv)->chipset) {
217
	case 0x40:
218
	case 0x41:
219 220
	case 0x42:
	case 0x43:
221
	case 0x45:
222
	case 0x4e:
223 224 225 226 227 228
		nv_wr32(priv, NV20_PGRAPH_TSIZE(i), tile->pitch);
		nv_wr32(priv, NV20_PGRAPH_TLIMIT(i), tile->limit);
		nv_wr32(priv, NV20_PGRAPH_TILE(i), tile->addr);
		nv_wr32(priv, NV40_PGRAPH_TSIZE1(i), tile->pitch);
		nv_wr32(priv, NV40_PGRAPH_TLIMIT1(i), tile->limit);
		nv_wr32(priv, NV40_PGRAPH_TILE1(i), tile->addr);
229 230 231 232 233 234 235 236 237 238 239 240 241 242 243
		switch (nv_device(priv)->chipset) {
		case 0x40:
		case 0x45:
			nv_wr32(priv, NV20_PGRAPH_ZCOMP(i), tile->zcomp);
			nv_wr32(priv, NV40_PGRAPH_ZCOMP1(i), tile->zcomp);
			break;
		case 0x41:
		case 0x42:
		case 0x43:
			nv_wr32(priv, NV41_PGRAPH_ZCOMP0(i), tile->zcomp);
			nv_wr32(priv, NV41_PGRAPH_ZCOMP1(i), tile->zcomp);
			break;
		default:
			break;
		}
244
		break;
245 246
	case 0x44:
	case 0x4a:
247 248 249
		nv_wr32(priv, NV20_PGRAPH_TSIZE(i), tile->pitch);
		nv_wr32(priv, NV20_PGRAPH_TLIMIT(i), tile->limit);
		nv_wr32(priv, NV20_PGRAPH_TILE(i), tile->addr);
250 251
		break;
	case 0x46:
252
	case 0x4c:
253 254 255
	case 0x47:
	case 0x49:
	case 0x4b:
256
	case 0x63:
257
	case 0x67:
258
	case 0x68:
259 260 261 262 263 264
		nv_wr32(priv, NV47_PGRAPH_TSIZE(i), tile->pitch);
		nv_wr32(priv, NV47_PGRAPH_TLIMIT(i), tile->limit);
		nv_wr32(priv, NV47_PGRAPH_TILE(i), tile->addr);
		nv_wr32(priv, NV40_PGRAPH_TSIZE1(i), tile->pitch);
		nv_wr32(priv, NV40_PGRAPH_TLIMIT1(i), tile->limit);
		nv_wr32(priv, NV40_PGRAPH_TILE1(i), tile->addr);
265 266 267 268 269 270 271 272 273 274 275 276
		switch (nv_device(priv)->chipset) {
		case 0x47:
		case 0x49:
		case 0x4b:
			nv_wr32(priv, NV47_PGRAPH_ZCOMP0(i), tile->zcomp);
			nv_wr32(priv, NV47_PGRAPH_ZCOMP1(i), tile->zcomp);
			break;
		default:
			break;
		}
		break;
	default:
277 278
		break;
	}
279

B
Ben Skeggs 已提交
280
	fifo->start(fifo, &flags);
281 282
}

283
static void
284
nv40_gr_intr(struct nvkm_subdev *subdev)
285
{
B
Ben Skeggs 已提交
286
	struct nvkm_fifo *fifo = nvkm_fifo(subdev);
287 288 289
	struct nvkm_engine *engine = nv_engine(subdev);
	struct nvkm_object *engctx;
	struct nvkm_handle *handle = NULL;
290
	struct nv40_gr_priv *priv = (void *)subdev;
291 292 293
	u32 stat = nv_rd32(priv, NV03_PGRAPH_INTR);
	u32 nsource = nv_rd32(priv, NV03_PGRAPH_NSOURCE);
	u32 nstatus = nv_rd32(priv, NV03_PGRAPH_NSTATUS);
294
	u32 inst = nv_rd32(priv, 0x40032c) & 0x000fffff;
295 296 297 298 299 300
	u32 addr = nv_rd32(priv, NV04_PGRAPH_TRAPPED_ADDR);
	u32 subc = (addr & 0x00070000) >> 16;
	u32 mthd = (addr & 0x00001ffc);
	u32 data = nv_rd32(priv, NV04_PGRAPH_TRAPPED_DATA);
	u32 class = nv_rd32(priv, 0x400160 + subc * 4) & 0xffff;
	u32 show = stat;
301 302
	int chid;

303
	engctx = nvkm_engctx_get(engine, inst);
B
Ben Skeggs 已提交
304
	chid   = fifo->chid(fifo, engctx);
305 306 307

	if (stat & NV_PGRAPH_INTR_ERROR) {
		if (nsource & NV03_PGRAPH_NSOURCE_ILLEGAL_MTHD) {
308
			handle = nvkm_handle_get_class(engctx, class);
309 310
			if (handle && !nv_call(handle->object, mthd, data))
				show &= ~NV_PGRAPH_INTR_ERROR;
311
			nvkm_handle_put(handle);
312 313 314 315 316 317 318 319 320 321 322
		}

		if (nsource & NV03_PGRAPH_NSOURCE_DMA_VTX_PROTECTION) {
			nv_mask(priv, 0x402000, 0, 0);
		}
	}

	nv_wr32(priv, NV03_PGRAPH_INTR, stat);
	nv_wr32(priv, NV04_PGRAPH_FIFO, 0x00000001);

	if (show) {
323
		nv_error(priv, "%s", "");
324
		nvkm_bitfield_print(nv10_gr_intr_name, show);
M
Marcin Slusarz 已提交
325
		pr_cont(" nsource:");
326
		nvkm_bitfield_print(nv04_gr_nsource, nsource);
M
Marcin Slusarz 已提交
327
		pr_cont(" nstatus:");
328
		nvkm_bitfield_print(nv10_gr_nstatus, nstatus);
M
Marcin Slusarz 已提交
329
		pr_cont("\n");
330 331
		nv_error(priv,
			 "ch %d [0x%08x %s] subc %d class 0x%04x mthd 0x%04x data 0x%08x\n",
332
			 chid, inst << 4, nvkm_client_name(engctx), subc,
333
			 class, mthd, data);
334
	}
335

336
	nvkm_engctx_put(engctx);
337 338 339
}

static int
340 341 342
nv40_gr_ctor(struct nvkm_object *parent, struct nvkm_object *engine,
	     struct nvkm_oclass *oclass, void *data, u32 size,
	     struct nvkm_object **pobject)
343
{
344
	struct nv40_gr_priv *priv;
345 346
	int ret;

347
	ret = nvkm_gr_create(parent, engine, oclass, true, &priv);
348 349 350
	*pobject = nv_object(priv);
	if (ret)
		return ret;
351

352
	nv_subdev(priv)->unit = 0x00001000;
353 354 355 356
	nv_subdev(priv)->intr = nv40_gr_intr;
	nv_engine(priv)->cclass = &nv40_gr_cclass;
	if (nv44_gr_class(priv))
		nv_engine(priv)->sclass = nv44_gr_sclass;
357
	else
358 359
		nv_engine(priv)->sclass = nv40_gr_sclass;
	nv_engine(priv)->tile_prog = nv40_gr_tile_prog;
360

361
	priv->base.units = nv40_gr_units;
362 363 364 365
	return 0;
}

static int
366
nv40_gr_init(struct nvkm_object *object)
367
{
368
	struct nvkm_engine *engine = nv_engine(object);
B
Ben Skeggs 已提交
369
	struct nvkm_fb *fb = nvkm_fb(object);
370
	struct nv40_gr_priv *priv = (void *)engine;
371 372 373
	int ret, i, j;
	u32 vramsz;

374
	ret = nvkm_gr_init(&priv->base);
375 376
	if (ret)
		return ret;
377

378
	/* generate and upload context program */
379 380 381
	ret = nv40_grctx_init(nv_device(priv), &priv->size);
	if (ret)
		return ret;
382 383

	/* No context present currently */
384
	nv_wr32(priv, NV40_PGRAPH_CTXCTL_CUR, 0x00000000);
385

386 387
	nv_wr32(priv, NV03_PGRAPH_INTR   , 0xFFFFFFFF);
	nv_wr32(priv, NV40_PGRAPH_INTR_EN, 0xFFFFFFFF);
388

389 390 391 392 393 394
	nv_wr32(priv, NV04_PGRAPH_DEBUG_0, 0xFFFFFFFF);
	nv_wr32(priv, NV04_PGRAPH_DEBUG_0, 0x00000000);
	nv_wr32(priv, NV04_PGRAPH_DEBUG_1, 0x401287c0);
	nv_wr32(priv, NV04_PGRAPH_DEBUG_3, 0xe0de8055);
	nv_wr32(priv, NV10_PGRAPH_DEBUG_4, 0x00008000);
	nv_wr32(priv, NV04_PGRAPH_LIMIT_VIOL_PIX, 0x00be3c5f);
395

396 397
	nv_wr32(priv, NV10_PGRAPH_CTX_CONTROL, 0x10010100);
	nv_wr32(priv, NV10_PGRAPH_STATE      , 0xFFFFFFFF);
398

399
	j = nv_rd32(priv, 0x1540) & 0xff;
400 401 402
	if (j) {
		for (i = 0; !(j & 1); j >>= 1, i++)
			;
403
		nv_wr32(priv, 0x405000, i);
404 405
	}

406 407 408
	if (nv_device(priv)->chipset == 0x40) {
		nv_wr32(priv, 0x4009b0, 0x83280fff);
		nv_wr32(priv, 0x4009b4, 0x000000a0);
409
	} else {
410 411
		nv_wr32(priv, 0x400820, 0x83280eff);
		nv_wr32(priv, 0x400824, 0x000000a0);
412 413
	}

414
	switch (nv_device(priv)->chipset) {
415 416
	case 0x40:
	case 0x45:
417 418
		nv_wr32(priv, 0x4009b8, 0x0078e366);
		nv_wr32(priv, 0x4009bc, 0x0000014c);
419 420 421 422
		break;
	case 0x41:
	case 0x42: /* pciid also 0x00Cx */
	/* case 0x0120: XXX (pciid) */
423 424
		nv_wr32(priv, 0x400828, 0x007596ff);
		nv_wr32(priv, 0x40082c, 0x00000108);
425 426
		break;
	case 0x43:
427 428
		nv_wr32(priv, 0x400828, 0x0072cb77);
		nv_wr32(priv, 0x40082c, 0x00000108);
429 430 431 432 433 434
		break;
	case 0x44:
	case 0x46: /* G72 */
	case 0x4a:
	case 0x4c: /* G7x-based C51 */
	case 0x4e:
435 436
		nv_wr32(priv, 0x400860, 0);
		nv_wr32(priv, 0x400864, 0);
437 438 439 440
		break;
	case 0x47: /* G70 */
	case 0x49: /* G71 */
	case 0x4b: /* G73 */
441 442
		nv_wr32(priv, 0x400828, 0x07830610);
		nv_wr32(priv, 0x40082c, 0x0000016A);
443 444 445 446 447
		break;
	default:
		break;
	}

448 449
	nv_wr32(priv, 0x400b38, 0x2ffff800);
	nv_wr32(priv, 0x400b3c, 0x00006000);
450

451
	/* Tiling related stuff. */
452
	switch (nv_device(priv)->chipset) {
453 454
	case 0x44:
	case 0x4a:
455 456
		nv_wr32(priv, 0x400bc4, 0x1003d888);
		nv_wr32(priv, 0x400bbc, 0xb7a7b500);
457 458
		break;
	case 0x46:
459 460
		nv_wr32(priv, 0x400bc4, 0x0000e024);
		nv_wr32(priv, 0x400bbc, 0xb7a7b520);
461 462 463 464
		break;
	case 0x4c:
	case 0x4e:
	case 0x67:
465 466
		nv_wr32(priv, 0x400bc4, 0x1003d888);
		nv_wr32(priv, 0x400bbc, 0xb7a7b540);
467 468 469 470 471
		break;
	default:
		break;
	}

472
	/* Turn all the tiling regions off. */
B
Ben Skeggs 已提交
473
	for (i = 0; i < fb->tile.regions; i++)
474
		engine->tile_prog(engine, i);
475 476

	/* begin RAM config */
A
Alexandre Courbot 已提交
477
	vramsz = nv_device_resource_len(nv_device(priv), 0) - 1;
478
	switch (nv_device(priv)->chipset) {
479
	case 0x40:
480 481 482 483 484 485 486 487
		nv_wr32(priv, 0x4009A4, nv_rd32(priv, 0x100200));
		nv_wr32(priv, 0x4009A8, nv_rd32(priv, 0x100204));
		nv_wr32(priv, 0x4069A4, nv_rd32(priv, 0x100200));
		nv_wr32(priv, 0x4069A8, nv_rd32(priv, 0x100204));
		nv_wr32(priv, 0x400820, 0);
		nv_wr32(priv, 0x400824, 0);
		nv_wr32(priv, 0x400864, vramsz);
		nv_wr32(priv, 0x400868, vramsz);
488 489
		break;
	default:
490
		switch (nv_device(priv)->chipset) {
491 492 493 494 495 496 497
		case 0x41:
		case 0x42:
		case 0x43:
		case 0x45:
		case 0x4e:
		case 0x44:
		case 0x4a:
498 499
			nv_wr32(priv, 0x4009F0, nv_rd32(priv, 0x100200));
			nv_wr32(priv, 0x4009F4, nv_rd32(priv, 0x100204));
500
			break;
501
		default:
502 503
			nv_wr32(priv, 0x400DF0, nv_rd32(priv, 0x100200));
			nv_wr32(priv, 0x400DF4, nv_rd32(priv, 0x100204));
504
			break;
505
		}
506 507 508 509 510 511
		nv_wr32(priv, 0x4069F0, nv_rd32(priv, 0x100200));
		nv_wr32(priv, 0x4069F4, nv_rd32(priv, 0x100204));
		nv_wr32(priv, 0x400840, 0);
		nv_wr32(priv, 0x400844, 0);
		nv_wr32(priv, 0x4008A0, vramsz);
		nv_wr32(priv, 0x4008A4, vramsz);
512 513 514 515 516 517
		break;
	}

	return 0;
}

518
struct nvkm_oclass
519
nv40_gr_oclass = {
520
	.handle = NV_ENGINE(GR, 0x40),
521
	.ofuncs = &(struct nvkm_ofuncs) {
522
		.ctor = nv40_gr_ctor,
523
		.dtor = _nvkm_gr_dtor,
524
		.init = nv40_gr_init,
525
		.fini = _nvkm_gr_fini,
526 527
	},
};