1 #ifndef __NV50_KMS_CORE_H__ 2 #define __NV50_KMS_CORE_H__ 3 #include "disp.h" 4 #include "atom.h" 5 6 struct nv50_core { 7 const struct nv50_core_func *func; 8 struct nv50_dmac chan; 9 bool assign_windows; 10 }; 11 12 int nv50_core_new(struct nouveau_drm *, struct nv50_core **); 13 void nv50_core_del(struct nv50_core **); 14 15 struct nv50_core_func { 16 void (*init)(struct nv50_core *); 17 void (*ntfy_init)(struct nouveau_bo *, u32 offset); 18 int (*ntfy_wait_done)(struct nouveau_bo *, u32 offset, 19 struct nvif_device *); 20 void (*update)(struct nv50_core *, u32 *interlock, bool ntfy); 21 22 struct { 23 void (*owner)(struct nv50_core *); 24 } wndw; 25 26 const struct nv50_head_func *head; 27 const struct nv50_outp_func { 28 void (*ctrl)(struct nv50_core *, int or, u32 ctrl, 29 struct nv50_head_atom *); 30 } *dac, *pior, *sor; 31 }; 32 33 int core507d_new(struct nouveau_drm *, s32, struct nv50_core **); 34 int core507d_new_(const struct nv50_core_func *, struct nouveau_drm *, s32, 35 struct nv50_core **); 36 void core507d_init(struct nv50_core *); 37 void core507d_ntfy_init(struct nouveau_bo *, u32); 38 int core507d_ntfy_wait_done(struct nouveau_bo *, u32, struct nvif_device *); 39 void core507d_update(struct nv50_core *, u32 *, bool); 40 41 extern const struct nv50_outp_func dac507d; 42 extern const struct nv50_outp_func sor507d; 43 extern const struct nv50_outp_func pior507d; 44 45 int core827d_new(struct nouveau_drm *, s32, struct nv50_core **); 46 47 int core907d_new(struct nouveau_drm *, s32, struct nv50_core **); 48 extern const struct nv50_outp_func dac907d; 49 extern const struct nv50_outp_func sor907d; 50 51 int core917d_new(struct nouveau_drm *, s32, struct nv50_core **); 52 53 int corec37d_new(struct nouveau_drm *, s32, struct nv50_core **); 54 int corec37d_ntfy_wait_done(struct nouveau_bo *, u32, struct nvif_device *); 55 void corec37d_update(struct nv50_core *, u32 *, bool); 56 void corec37d_wndw_owner(struct nv50_core *); 57 extern const struct nv50_outp_func sorc37d; 58 59 int corec57d_new(struct nouveau_drm *, s32, struct nv50_core **); 60 #endif 61