1 #ifndef __NVKM_PMU_PRIV_H__ 2 #define __NVKM_PMU_PRIV_H__ 3 #define nvkm_pmu(p) container_of((p), struct nvkm_pmu, subdev) 4 #include <subdev/pmu.h> 5 #include <subdev/pmu/fuc/os.h> 6 7 int nvkm_pmu_ctor(const struct nvkm_pmu_func *, struct nvkm_device *, 8 int index, struct nvkm_pmu *); 9 int nvkm_pmu_new_(const struct nvkm_pmu_func *, struct nvkm_device *, 10 int index, struct nvkm_pmu **); 11 12 struct nvkm_pmu_func { 13 struct { 14 u32 *data; 15 u32 size; 16 } code; 17 18 struct { 19 u32 *data; 20 u32 size; 21 } data; 22 23 void (*reset)(struct nvkm_pmu *); 24 int (*init)(struct nvkm_pmu *); 25 void (*fini)(struct nvkm_pmu *); 26 void (*intr)(struct nvkm_pmu *); 27 int (*send)(struct nvkm_pmu *, u32 reply[2], u32 process, 28 u32 message, u32 data0, u32 data1); 29 void (*recv)(struct nvkm_pmu *); 30 void (*pgob)(struct nvkm_pmu *, bool); 31 }; 32 33 void gt215_pmu_reset(struct nvkm_pmu *); 34 int gt215_pmu_init(struct nvkm_pmu *); 35 void gt215_pmu_fini(struct nvkm_pmu *); 36 void gt215_pmu_intr(struct nvkm_pmu *); 37 void gt215_pmu_recv(struct nvkm_pmu *); 38 int gt215_pmu_send(struct nvkm_pmu *, u32[2], u32, u32, u32, u32); 39 40 void gk110_pmu_pgob(struct nvkm_pmu *, bool); 41 #endif 42