channv50.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. #ifndef __NV50_FIFO_CHAN_H__
  2. #define __NV50_FIFO_CHAN_H__
  3. #define nv50_fifo_chan(p) container_of((p), struct nv50_fifo_chan, base)
  4. #include "chan.h"
  5. #include "nv50.h"
  6. struct nv50_fifo_chan {
  7. struct nv50_fifo *fifo;
  8. struct nvkm_fifo_chan base;
  9. struct nvkm_gpuobj *ramfc;
  10. struct nvkm_gpuobj *cache;
  11. struct nvkm_gpuobj *eng;
  12. struct nvkm_gpuobj *pgd;
  13. struct nvkm_ramht *ramht;
  14. struct nvkm_vm *vm;
  15. struct nvkm_gpuobj *engn[NVKM_SUBDEV_NR];
  16. };
  17. int nv50_fifo_chan_ctor(struct nv50_fifo *, u64 vm, u64 push,
  18. const struct nvkm_oclass *, struct nv50_fifo_chan *);
  19. void *nv50_fifo_chan_dtor(struct nvkm_fifo_chan *);
  20. void nv50_fifo_chan_fini(struct nvkm_fifo_chan *);
  21. void nv50_fifo_chan_engine_dtor(struct nvkm_fifo_chan *, struct nvkm_engine *);
  22. void nv50_fifo_chan_object_dtor(struct nvkm_fifo_chan *, int);
  23. int g84_fifo_chan_ctor(struct nv50_fifo *, u64 vm, u64 push,
  24. const struct nvkm_oclass *, struct nv50_fifo_chan *);
  25. extern const struct nvkm_fifo_chan_oclass nv50_fifo_dma_oclass;
  26. extern const struct nvkm_fifo_chan_oclass nv50_fifo_gpfifo_oclass;
  27. extern const struct nvkm_fifo_chan_oclass g84_fifo_dma_oclass;
  28. extern const struct nvkm_fifo_chan_oclass g84_fifo_gpfifo_oclass;
  29. #endif