core.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. #ifndef __NV50_KMS_CORE_H__
  2. #define __NV50_KMS_CORE_H__
  3. #include "disp.h"
  4. #include "atom.h"
  5. struct nv50_core {
  6. const struct nv50_core_func *func;
  7. struct nv50_dmac chan;
  8. };
  9. int nv50_core_new(struct nouveau_drm *, struct nv50_core **);
  10. void nv50_core_del(struct nv50_core **);
  11. struct nv50_core_func {
  12. void (*init)(struct nv50_core *);
  13. void (*ntfy_init)(struct nouveau_bo *, u32 offset);
  14. int (*ntfy_wait_done)(struct nouveau_bo *, u32 offset,
  15. struct nvif_device *);
  16. void (*update)(struct nv50_core *, u32 *interlock, bool ntfy);
  17. const struct nv50_head_func *head;
  18. const struct nv50_outp_func {
  19. void (*ctrl)(struct nv50_core *, int or, u32 ctrl,
  20. struct nv50_head_atom *);
  21. } *dac, *pior, *sor;
  22. };
  23. int core507d_new(struct nouveau_drm *, s32, struct nv50_core **);
  24. int core507d_new_(const struct nv50_core_func *, struct nouveau_drm *, s32,
  25. struct nv50_core **);
  26. void core507d_init(struct nv50_core *);
  27. void core507d_ntfy_init(struct nouveau_bo *, u32);
  28. int core507d_ntfy_wait_done(struct nouveau_bo *, u32, struct nvif_device *);
  29. void core507d_update(struct nv50_core *, u32 *, bool);
  30. extern const struct nv50_outp_func dac507d;
  31. extern const struct nv50_outp_func sor507d;
  32. extern const struct nv50_outp_func pior507d;
  33. int core827d_new(struct nouveau_drm *, s32, struct nv50_core **);
  34. int core907d_new(struct nouveau_drm *, s32, struct nv50_core **);
  35. extern const struct nv50_outp_func dac907d;
  36. extern const struct nv50_outp_func sor907d;
  37. int core917d_new(struct nouveau_drm *, s32, struct nv50_core **);
  38. int corec37d_new(struct nouveau_drm *, s32, struct nv50_core **);
  39. extern const struct nv50_outp_func sorc37d;
  40. #endif