GNU Linux-libre 4.14.266-gnu1
[releases.git] / drivers / gpu / drm / nouveau / nvkm / engine / fifo / changk104.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef __GK104_FIFO_CHAN_H__
3 #define __GK104_FIFO_CHAN_H__
4 #define gk104_fifo_chan(p) container_of((p), struct gk104_fifo_chan, base)
5 #include "chan.h"
6 #include "gk104.h"
7
8 struct gk104_fifo_chan {
9         struct nvkm_fifo_chan base;
10         struct gk104_fifo *fifo;
11         int runl;
12
13         struct list_head head;
14         bool killed;
15
16         struct nvkm_gpuobj *pgd;
17         struct nvkm_vm *vm;
18
19         struct {
20                 struct nvkm_gpuobj *inst;
21                 struct nvkm_vma vma;
22         } engn[NVKM_SUBDEV_NR];
23 };
24
25 int gk104_fifo_gpfifo_new(struct nvkm_fifo *, const struct nvkm_oclass *,
26                           void *data, u32 size, struct nvkm_object **);
27
28 extern const struct nvkm_fifo_chan_oclass gk104_fifo_gpfifo_oclass;
29 extern const struct nvkm_fifo_chan_oclass gk110_fifo_gpfifo_oclass;
30 extern const struct nvkm_fifo_chan_oclass gm200_fifo_gpfifo_oclass;
31 extern const struct nvkm_fifo_chan_oclass gp100_fifo_gpfifo_oclass;
32 #endif