nouveau_chan.h 930 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #ifndef __NOUVEAU_CHAN_H__
  2. #define __NOUVEAU_CHAN_H__
  3. #include <nvif/object.h>
  4. struct nvif_device;
  5. struct nouveau_channel {
  6. struct nvif_device *device;
  7. struct nouveau_drm *drm;
  8. int chid;
  9. struct nvif_object vram;
  10. struct nvif_object gart;
  11. struct nvif_object nvsw;
  12. struct {
  13. struct nouveau_bo *buffer;
  14. struct nvkm_vma vma;
  15. struct nvif_object ctxdma;
  16. } push;
  17. /* TODO: this will be reworked in the near future */
  18. bool accel_done;
  19. void *fence;
  20. struct {
  21. int max;
  22. int free;
  23. int cur;
  24. int put;
  25. int ib_base;
  26. int ib_max;
  27. int ib_free;
  28. int ib_put;
  29. } dma;
  30. u32 user_get_hi;
  31. u32 user_get;
  32. u32 user_put;
  33. struct nvif_object user;
  34. };
  35. int nouveau_channel_new(struct nouveau_drm *, struct nvif_device *,
  36. u32 arg0, u32 arg1, struct nouveau_channel **);
  37. void nouveau_channel_del(struct nouveau_channel **);
  38. int nouveau_channel_idle(struct nouveau_channel *);
  39. extern int nouveau_vram_pushbuf;
  40. #endif