Lines Matching refs:device
34 struct nvkm_device *device = subdev->device; in gt215_pmu_send() local
39 addr = nvkm_rd32(device, 0x10a4a0); in gt215_pmu_send()
40 if (nvkm_msec(device, 2000, in gt215_pmu_send()
41 u32 tmp = nvkm_rd32(device, 0x10a4b0); in gt215_pmu_send()
60 nvkm_wr32(device, 0x10a580, 0x00000001); in gt215_pmu_send()
61 } while (nvkm_rd32(device, 0x10a580) != 0x00000001); in gt215_pmu_send()
64 nvkm_wr32(device, 0x10a1c0, 0x01000000 | (((addr & 0x07) << 4) + in gt215_pmu_send()
66 nvkm_wr32(device, 0x10a1c4, process); in gt215_pmu_send()
67 nvkm_wr32(device, 0x10a1c4, message); in gt215_pmu_send()
68 nvkm_wr32(device, 0x10a1c4, data0); in gt215_pmu_send()
69 nvkm_wr32(device, 0x10a1c4, data1); in gt215_pmu_send()
70 nvkm_wr32(device, 0x10a4a0, (addr + 1) & 0x0f); in gt215_pmu_send()
73 nvkm_wr32(device, 0x10a580, 0x00000000); in gt215_pmu_send()
90 struct nvkm_device *device = subdev->device; in gt215_pmu_recv() local
94 u32 addr = nvkm_rd32(device, 0x10a4cc); in gt215_pmu_recv()
95 if (addr == nvkm_rd32(device, 0x10a4c8)) in gt215_pmu_recv()
100 nvkm_wr32(device, 0x10a580, 0x00000002); in gt215_pmu_recv()
101 } while (nvkm_rd32(device, 0x10a580) != 0x00000002); in gt215_pmu_recv()
104 nvkm_wr32(device, 0x10a1c0, 0x02000000 | (((addr & 0x07) << 4) + in gt215_pmu_recv()
106 process = nvkm_rd32(device, 0x10a1c4); in gt215_pmu_recv()
107 message = nvkm_rd32(device, 0x10a1c4); in gt215_pmu_recv()
108 data0 = nvkm_rd32(device, 0x10a1c4); in gt215_pmu_recv()
109 data1 = nvkm_rd32(device, 0x10a1c4); in gt215_pmu_recv()
110 nvkm_wr32(device, 0x10a4cc, (addr + 1) & 0x0f); in gt215_pmu_recv()
113 nvkm_wr32(device, 0x10a580, 0x00000000); in gt215_pmu_recv()
142 struct nvkm_device *device = subdev->device; in gt215_pmu_intr() local
143 u32 disp = nvkm_rd32(device, 0x10a01c); in gt215_pmu_intr()
144 u32 intr = nvkm_rd32(device, 0x10a008) & disp & ~(disp >> 16); in gt215_pmu_intr()
147 u32 stat = nvkm_rd32(device, 0x10a16c); in gt215_pmu_intr()
151 nvkm_rd32(device, 0x10a168)); in gt215_pmu_intr()
152 nvkm_wr32(device, 0x10a16c, 0x00000000); in gt215_pmu_intr()
159 nvkm_wr32(device, 0x10a004, 0x00000040); in gt215_pmu_intr()
165 nvkm_rd32(device, 0x10a7a0), in gt215_pmu_intr()
166 nvkm_rd32(device, 0x10a7a4)); in gt215_pmu_intr()
167 nvkm_wr32(device, 0x10a004, 0x00000080); in gt215_pmu_intr()
173 nvkm_wr32(device, 0x10a004, intr); in gt215_pmu_intr()
180 nvkm_wr32(pmu->subdev.device, 0x10a014, 0x00000060); in gt215_pmu_fini()
186 struct nvkm_device *device = pmu->subdev.device; in gt215_pmu_reset() local
187 nvkm_mask(device, 0x022210, 0x00000001, 0x00000000); in gt215_pmu_reset()
188 nvkm_mask(device, 0x022210, 0x00000001, 0x00000001); in gt215_pmu_reset()
189 nvkm_rd32(device, 0x022210); in gt215_pmu_reset()
195 return nvkm_rd32(pmu->subdev.device, 0x022210) & 0x00000001; in gt215_pmu_enabled()
201 struct nvkm_device *device = pmu->subdev.device; in gt215_pmu_init() local
205 nvkm_wr32(device, 0x10a1c0, 0x01000000); in gt215_pmu_init()
207 nvkm_wr32(device, 0x10a1c4, pmu->func->data.data[i]); in gt215_pmu_init()
210 nvkm_wr32(device, 0x10a180, 0x01000000); in gt215_pmu_init()
213 nvkm_wr32(device, 0x10a188, i >> 6); in gt215_pmu_init()
214 nvkm_wr32(device, 0x10a184, pmu->func->code.data[i]); in gt215_pmu_init()
218 nvkm_wr32(device, 0x10a10c, 0x00000000); in gt215_pmu_init()
219 nvkm_wr32(device, 0x10a104, 0x00000000); in gt215_pmu_init()
220 nvkm_wr32(device, 0x10a100, 0x00000002); in gt215_pmu_init()
223 if (nvkm_msec(device, 2000, in gt215_pmu_init()
224 if (nvkm_rd32(device, 0x10a4d0)) in gt215_pmu_init()
228 pmu->send.base = nvkm_rd32(device, 0x10a4d0) & 0x0000ffff; in gt215_pmu_init()
229 pmu->send.size = nvkm_rd32(device, 0x10a4d0) >> 16; in gt215_pmu_init()
232 if (nvkm_msec(device, 2000, in gt215_pmu_init()
233 if (nvkm_rd32(device, 0x10a4dc)) in gt215_pmu_init()
237 pmu->recv.base = nvkm_rd32(device, 0x10a4dc) & 0x0000ffff; in gt215_pmu_init()
238 pmu->recv.size = nvkm_rd32(device, 0x10a4dc) >> 16; in gt215_pmu_init()
240 nvkm_wr32(device, 0x10a010, 0x000000e0); in gt215_pmu_init()
260 gt215_pmu_new(struct nvkm_device *device, int index, struct nvkm_pmu **ppmu) in gt215_pmu_new() argument
262 return nvkm_pmu_new_(>215_pmu, device, index, ppmu); in gt215_pmu_new()