Lines Matching refs:device
34 struct nvkm_device *device = clk->base.subdev.device; in read_div() local
35 switch (device->chipset) { in read_div()
41 return nvkm_rd32(device, 0x004700); in read_div()
45 return nvkm_rd32(device, 0x004800); in read_div()
55 struct nvkm_device *device = subdev->device; in read_pll_src() local
57 u32 rsel = nvkm_rd32(device, 0x00e18c); in read_pll_src()
60 switch (device->chipset) { in read_pll_src()
73 coef = nvkm_rd32(device, 0x00e81c + (id * 0x0c)); in read_pll_src()
82 coef = nvkm_rd32(device, 0x00e81c); in read_pll_src()
90 rsel = nvkm_rd32(device, 0x00c050); in read_pll_src()
108 coef = nvkm_rd32(device, 0x00e81c + (id * 0x28)); in read_pll_src()
109 P = (nvkm_rd32(device, 0x00e824 + (id * 0x28)) >> 16) & 7; in read_pll_src()
128 struct nvkm_device *device = subdev->device; in read_pll_ref() local
129 u32 src, mast = nvkm_rd32(device, 0x00c040); in read_pll_ref()
160 struct nvkm_device *device = clk->base.subdev.device; in read_pll() local
161 u32 mast = nvkm_rd32(device, 0x00c040); in read_pll()
162 u32 ctrl = nvkm_rd32(device, base + 0); in read_pll()
163 u32 coef = nvkm_rd32(device, base + 4); in read_pll()
170 if (device->chipset != 0xa0) in read_pll()
196 struct nvkm_device *device = subdev->device; in nv50_clk_read() local
197 u32 mast = nvkm_rd32(device, 0x00c040); in nv50_clk_read()
202 return device->crystal; in nv50_clk_read()
221 P = (nvkm_rd32(device, 0x004028) & 0x00070000) >> 16; in nv50_clk_read()
230 P = (nvkm_rd32(device, 0x004020) & 0x00070000) >> 16; in nv50_clk_read()
242 P = (nvkm_rd32(device, 0x004008) & 0x00070000) >> 16; in nv50_clk_read()
243 if (nvkm_rd32(device, 0x004008) & 0x00000200) { in nv50_clk_read()
257 switch (device->chipset) { in nv50_clk_read()
266 if (device->chipset == 0xa0) /* wtf?? */ in nv50_clk_read()
294 switch (device->chipset) { in nv50_clk_read()
331 ret = nvbios_pll_parse(subdev->device->bios, reg, &pll); in calc_pll()
373 struct nvkm_device *device = subdev->device; in nv50_clk_calc() local
402 if (device->chipset != 0x98) in nv50_clk_calc()
410 if (device->chipset != 0x98) in nv50_clk_calc()
453 if (device->chipset < 0x92) in nv50_clk_calc()
509 nv50_clk_new_(const struct nvkm_clk_func *func, struct nvkm_device *device, in nv50_clk_new_() argument
517 ret = nvkm_clk_ctor(func, device, index, allow_reclock, &clk->base); in nv50_clk_new_()
527 switch (device->chipset) { in nv50_clk_new_()
558 nv50_clk_new(struct nvkm_device *device, int index, struct nvkm_clk **pclk) in nv50_clk_new() argument
560 return nv50_clk_new_(&nv50_clk, device, index, false, pclk); in nv50_clk_new()