53 for (i = priv->
base.min, p = 0; i < priv->
base.max; i++) {
54 if (nv_rd32(priv, 0x002600 + (i * 4)) & 0x80000000)
55 nv_wo32(cur, p++ * 4, i);
60 nv_wr32(priv, 0x0032f4, cur->
addr >> 12);
61 nv_wr32(priv, 0x0032ec, p);
62 nv_wr32(priv, 0x002500, 0x00000101);
76 switch (nv_engidx(object->
engine)) {
84 nv_engctx(ectx)->addr = nv_gpuobj(base)->addr >> 12;
85 nv_wo32(base->
eng, addr + 0x00, 0x00190000);
90 nv_wo32(base->
eng, addr + 0x10, 0x00000000);
91 nv_wo32(base->
eng, addr + 0x14, 0x00000000);
107 switch (nv_engidx(object->
engine)) {
115 nv_wo32(base->
eng, addr + 0x00, 0x00000000);
116 nv_wo32(base->
eng, addr + 0x04, 0x00000000);
117 nv_wo32(base->
eng, addr + 0x08, 0x00000000);
118 nv_wo32(base->
eng, addr + 0x0c, 0x00000000);
119 nv_wo32(base->
eng, addr + 0x10, 0x00000000);
120 nv_wo32(base->
eng, addr + 0x14, 0x00000000);
135 me = nv_mask(priv, 0x00b860, 0x00000001, 0x00000001);
138 nv_wr32(priv, 0x0032fc, nv_gpuobj(base)->addr >> 12);
139 if (!
nv_wait_ne(priv, 0x0032fc, 0xffffffff, 0xffffffff)) {
140 nv_error(priv,
"channel %d unload timeout\n", chan->
base.chid);
145 nv_wr32(priv, 0x00b860, me);
157 context = nv_gpuobj(
object)->node->offset >> 4;
159 context = 0x00000004;
161 switch (nv_engidx(object->
engine)) {
192 if (size <
sizeof(*args))
201 *pobject = nv_object(chan);
205 nv_parent(chan)->context_attach = nv50_fifo_context_attach;
206 nv_parent(chan)->context_detach = nv50_fifo_context_detach;
207 nv_parent(chan)->object_attach = nv50_fifo_object_attach;
218 nv_wo32(base->
ramfc, 0x3c, 0x003f6078);
219 nv_wo32(base->
ramfc, 0x44, 0x01003fff);
220 nv_wo32(base->
ramfc, 0x48, chan->
base.pushgpu->node->offset >> 4);
221 nv_wo32(base->
ramfc, 0x4c, 0xffffffff);
222 nv_wo32(base->
ramfc, 0x60, 0x7fffffff);
223 nv_wo32(base->
ramfc, 0x78, 0x00000000);
224 nv_wo32(base->
ramfc, 0x7c, 0x30000001);
225 nv_wo32(base->
ramfc, 0x80, ((chan->
ramht->bits - 9) << 27) |
227 (chan->
ramht->base.node->offset >> 4));
242 u64 ioffset, ilength;
245 if (size <
sizeof(*args))
254 *pobject = nv_object(chan);
258 nv_parent(chan)->context_attach = nv50_fifo_context_attach;
259 nv_parent(chan)->context_detach = nv50_fifo_context_detach;
260 nv_parent(chan)->object_attach = nv50_fifo_object_attach;
268 ilength = log2i(args->
ilength / 8);
270 nv_wo32(base->
ramfc, 0x3c, 0x403f6078);
271 nv_wo32(base->
ramfc, 0x44, 0x01003fff);
272 nv_wo32(base->
ramfc, 0x48, chan->
base.pushgpu->node->offset >> 4);
275 nv_wo32(base->
ramfc, 0x60, 0x7fffffff);
276 nv_wo32(base->
ramfc, 0x78, 0x00000000);
277 nv_wo32(base->
ramfc, 0x7c, 0x30000001);
278 nv_wo32(base->
ramfc, 0x80, ((chan->
ramht->bits - 9) << 27) |
280 (chan->
ramht->base.node->offset >> 4));
307 nv_wr32(priv, 0x002600 + (chid * 4), 0x80000000 | ramfc->
addr >> 12);
320 nv_mask(priv, 0x002600 + (chid * 4), 0x80000000, 0x00000000);
322 nv_wr32(priv, 0x002600 + (chid * 4), 0x00000000);
328 nv50_fifo_ofuncs_dma = {
329 .ctor = nv50_fifo_chan_ctor_dma,
331 .init = nv50_fifo_chan_init,
338 nv50_fifo_ofuncs_ind = {
339 .ctor = nv50_fifo_chan_ctor_ind,
341 .init = nv50_fifo_chan_init,
348 nv50_fifo_sclass[] = {
369 *pobject = nv_object(base);
400 nouveau_gpuobj_ref(
NULL, &base->
pgd);
401 nouveau_gpuobj_ref(
NULL, &base->
eng);
411 .ctor = nv50_fifo_context_ctor,
433 *pobject = nv_object(priv);
447 nv_subdev(priv)->unit = 0x00000100;
449 nv_engine(priv)->cclass = &nv50_fifo_cclass;
450 nv_engine(priv)->sclass = nv50_fifo_sclass;
475 nv_mask(priv, 0x000200, 0x00000100, 0x00000000);
476 nv_mask(priv, 0x000200, 0x00000100, 0x00000100);
477 nv_wr32(priv, 0x00250c, 0x6f3cfc34);
478 nv_wr32(priv, 0x002044, 0x01003fff);
480 nv_wr32(priv, 0x002100, 0xffffffff);
481 nv_wr32(priv, 0x002140, 0xffffffff);
483 for (i = 0; i < 128; i++)
484 nv_wr32(priv, 0x002600 + (i * 4), 0x00000000);
487 nv_wr32(priv, 0x003200, 0x00000001);
488 nv_wr32(priv, 0x003250, 0x00000001);
489 nv_wr32(priv, 0x002500, 0x00000001);
497 .ctor = nv50_fifo_ctor,