therm             200 drivers/char/ds1620.c static void ds1620_write_state(struct therm *therm)
therm             203 drivers/char/ds1620.c 	ds1620_out(THERM_WRITE_TL, 9, therm->lo);
therm             204 drivers/char/ds1620.c 	ds1620_out(THERM_WRITE_TH, 9, therm->hi);
therm             208 drivers/char/ds1620.c static void ds1620_read_state(struct therm *therm)
therm             210 drivers/char/ds1620.c 	therm->lo = cvt_9_to_int(ds1620_in(THERM_READ_TL, 9));
therm             211 drivers/char/ds1620.c 	therm->hi = cvt_9_to_int(ds1620_in(THERM_READ_TH, 9));
therm             239 drivers/char/ds1620.c 	struct therm therm;
therm             241 drivers/char/ds1620.c 		struct therm __user *therm;
therm             255 drivers/char/ds1620.c 			if (get_user(therm.hi, uarg.i))
therm             257 drivers/char/ds1620.c 			therm.lo = therm.hi - 3;
therm             259 drivers/char/ds1620.c 			if (copy_from_user(&therm, uarg.therm, sizeof(therm)))
therm             263 drivers/char/ds1620.c 		therm.lo <<= 1;
therm             264 drivers/char/ds1620.c 		therm.hi <<= 1;
therm             266 drivers/char/ds1620.c 		ds1620_write_state(&therm);
therm             271 drivers/char/ds1620.c 		ds1620_read_state(&therm);
therm             273 drivers/char/ds1620.c 		therm.lo >>= 1;
therm             274 drivers/char/ds1620.c 		therm.hi >>= 1;
therm             277 drivers/char/ds1620.c 			if (put_user(therm.hi, uarg.i))
therm             280 drivers/char/ds1620.c 			if (copy_to_user(uarg.therm, &therm, sizeof(therm)))
therm             336 drivers/char/ds1620.c 	struct therm th;
therm             368 drivers/char/ds1620.c 	struct therm th, th_start;
therm              72 drivers/gpu/drm/nouveau/include/nvif/device.h #define nvxx_therm(a) nvxx_device(a)->therm
therm             153 drivers/gpu/drm/nouveau/include/nvkm/core/device.h 	struct nvkm_therm *therm;
therm             226 drivers/gpu/drm/nouveau/include/nvkm/core/device.h 	int (*therm   )(struct nvkm_device *, int idx, struct nvkm_therm **);
therm              55 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm              58 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	      therm->attr_get(therm, NVKM_THERM_ATTR_THRS_FAN_BOOST) * 1000);
therm              67 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm              73 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	therm->attr_set(therm, NVKM_THERM_ATTR_THRS_FAN_BOOST,
therm              88 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm              91 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	 therm->attr_get(therm, NVKM_THERM_ATTR_THRS_FAN_BOOST_HYST) * 1000);
therm             100 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             106 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	therm->attr_set(therm, NVKM_THERM_ATTR_THRS_FAN_BOOST_HYST,
therm             121 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             124 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	ret = therm->attr_get(therm, NVKM_THERM_ATTR_FAN_MAX_DUTY);
therm             137 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             140 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	ret = therm->attr_get(therm, NVKM_THERM_ATTR_FAN_MIN_DUTY);
therm             153 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             160 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	ret = therm->attr_set(therm, NVKM_THERM_ATTR_FAN_MIN_DUTY, value);
therm             176 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             183 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	ret = therm->attr_set(therm, NVKM_THERM_ATTR_FAN_MAX_DUTY, value);
therm             326 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             328 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!therm || !therm->attr_get || nvkm_therm_temp_get(therm) < 0)
therm             350 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             352 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!therm || !therm->attr_get || !therm->fan_get ||
therm             353 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	    therm->fan_get(therm) < 0)
therm             389 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             391 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!therm || !therm->attr_get || nvkm_therm_fan_sense(therm) < 0)
therm             421 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             424 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!therm || !therm->attr_get)
therm             431 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		ret = nvkm_therm_temp_get(therm);
therm             435 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = therm->attr_get(therm, NVKM_THERM_ATTR_THRS_DOWN_CLK)
therm             439 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = therm->attr_get(therm, NVKM_THERM_ATTR_THRS_DOWN_CLK_HYST)
therm             443 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = therm->attr_get(therm, NVKM_THERM_ATTR_THRS_CRITICAL)
therm             447 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = therm->attr_get(therm, NVKM_THERM_ATTR_THRS_CRITICAL_HYST)
therm             451 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = therm->attr_get(therm, NVKM_THERM_ATTR_THRS_SHUTDOWN)
therm             455 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = therm->attr_get(therm, NVKM_THERM_ATTR_THRS_SHUTDOWN_HYST)
therm             470 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             472 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!therm)
therm             479 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = nvkm_therm_fan_sense(therm);
therm             524 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             526 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!therm || !therm->attr_get || !therm->fan_get)
therm             531 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = therm->attr_get(therm, NVKM_THERM_ATTR_FAN_MODE);
therm             536 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		*val = therm->fan_get(therm);
therm             579 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             581 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!therm || !therm->attr_set)
therm             586 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		return therm->attr_set(therm, NVKM_THERM_ATTR_THRS_DOWN_CLK,
therm             589 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		return therm->attr_set(therm, NVKM_THERM_ATTR_THRS_DOWN_CLK_HYST,
therm             592 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		return therm->attr_set(therm, NVKM_THERM_ATTR_THRS_CRITICAL,
therm             595 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		return therm->attr_set(therm, NVKM_THERM_ATTR_THRS_CRITICAL_HYST,
therm             598 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		return therm->attr_set(therm, NVKM_THERM_ATTR_THRS_SHUTDOWN,
therm             601 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		return therm->attr_set(therm, NVKM_THERM_ATTR_THRS_SHUTDOWN_HYST,
therm             613 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             615 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!therm || !therm->attr_set)
therm             620 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		return therm->fan_set(therm, val);
therm             622 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		return therm->attr_set(therm, NVKM_THERM_ATTR_FAN_MODE, val);
therm             719 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	struct nvkm_therm *therm = nvxx_therm(&drm->client.device);
therm             727 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (!iccsense && !therm && !volt) {
therm             737 drivers/gpu/drm/nouveau/nouveau_hwmon.c 	if (therm && therm->attr_get && therm->attr_set) {
therm             738 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		if (nvkm_therm_temp_get(therm) >= 0)
therm             740 drivers/gpu/drm/nouveau/nouveau_hwmon.c 		if (therm->fan_get && therm->fan_get(therm) >= 0)
therm             486 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             512 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             538 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             564 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             590 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             616 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             642 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             668 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             694 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             720 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             746 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             772 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             798 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             827 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv50_therm_new,
therm             853 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             879 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             905 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = nv40_therm_new,
therm             934 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm             966 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm             998 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm            1030 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm            1062 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm            1094 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm            1126 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm            1159 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1193 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1226 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1258 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm            1290 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = g84_therm_new,
therm            1323 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1359 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1396 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1432 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1468 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1505 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1542 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1579 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gt215_therm_new,
therm            1614 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gf119_therm_new,
therm            1650 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gf119_therm_new,
therm            1686 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gk104_therm_new,
therm            1725 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gk104_therm_new,
therm            1764 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gk104_therm_new,
therm            1828 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gk104_therm_new,
therm            1866 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gk104_therm_new,
therm            1904 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gk104_therm_new,
therm            1942 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gk104_therm_new,
therm            1980 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gm107_therm_new,
therm            2014 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gm107_therm_new,
therm            2047 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gm200_therm_new,
therm            2082 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gm200_therm_new,
therm            2117 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gm200_therm_new,
therm            2174 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2210 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2246 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2282 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2318 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2354 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2418 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2458 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2493 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2528 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2563 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2598 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	.therm = gp100_therm_new,
therm            2662 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	_(THERM   , device->therm   , &device->therm->subdev);
therm            2747 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	nvkm_therm_clkgate_fini(device->therm, suspend);
therm            2837 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 	nvkm_therm_clkgate_enable(device->therm);
therm            3168 drivers/gpu/drm/nouveau/nvkm/engine/device/base.c 		_(NVKM_SUBDEV_THERM   ,    therm);
therm            2335 drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c 		nvkm_therm_clkgate_init(device->therm, gr->func->clkgate_pack);
therm              32 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	u32 therm = 0;
therm              36 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 			therm = nvbios_rd32(bios, bit_P.offset + 12);
therm              38 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 			therm = nvbios_rd32(bios, bit_P.offset + 16);
therm              46 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	if (!therm)
therm              49 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	*ver = nvbios_rd08(bios, therm + 0);
therm              50 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	*hdr = nvbios_rd08(bios, therm + 1);
therm              51 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	*len = nvbios_rd08(bios, therm + 2);
therm              52 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	*cnt = nvbios_rd08(bios, therm + 3);
therm              53 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	return therm + nvbios_rd08(bios, therm + 1);
therm              60 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	u32 therm = therm_table(bios, ver, &hdr, len, &cnt);
therm              61 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 	if (therm && idx < cnt)
therm              62 drivers/gpu/drm/nouveau/nvkm/subdev/bios/therm.c 		return therm + idx * *len;
therm              57 drivers/gpu/drm/nouveau/nvkm/subdev/bus/nv31.c 		struct nvkm_therm *therm = device->therm;
therm              58 drivers/gpu/drm/nouveau/nvkm/subdev/bus/nv31.c 		if (therm)
therm              59 drivers/gpu/drm/nouveau/nvkm/subdev/bus/nv31.c 			nvkm_subdev_intr(&therm->subdev);
therm              72 drivers/gpu/drm/nouveau/nvkm/subdev/bus/nv50.c 		struct nvkm_therm *therm = device->therm;
therm              73 drivers/gpu/drm/nouveau/nvkm/subdev/bus/nv50.c 		if (therm)
therm              74 drivers/gpu/drm/nouveau/nvkm/subdev/bus/nv50.c 			nvkm_subdev_intr(&therm->subdev);
therm             164 drivers/gpu/drm/nouveau/nvkm/subdev/clk/base.c 	struct nvkm_therm *therm = device->therm;
therm             176 drivers/gpu/drm/nouveau/nvkm/subdev/clk/base.c 	if (therm) {
therm             177 drivers/gpu/drm/nouveau/nvkm/subdev/clk/base.c 		ret = nvkm_therm_cstate(therm, pstate->fanspeed, +1);
therm             206 drivers/gpu/drm/nouveau/nvkm/subdev/clk/base.c 	if (therm) {
therm             207 drivers/gpu/drm/nouveau/nvkm/subdev/clk/base.c 		ret = nvkm_therm_cstate(therm, pstate->fanspeed, -1);
therm              98 drivers/gpu/drm/nouveau/nvkm/subdev/fb/gf100.c 		nvkm_therm_clkgate_init(device->therm,
therm              30 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_temp_get(struct nvkm_therm *therm)
therm              32 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (therm->func->temp_get)
therm              33 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->func->temp_get(therm);
therm              38 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_update_trip(struct nvkm_therm *therm)
therm              40 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvbios_therm_trip_point *trip = therm->fan->bios.trip,
therm              42 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 				       *last_trip = therm->last_trip;
therm              43 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	u8  temp = therm->func->temp_get(therm);
therm              48 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	for (i = 0; i < therm->fan->bios.nr_fan_trip; i++) {
therm              60 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->last_trip = cur_trip;
therm              63 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->last_trip = NULL;
therm              70 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_compute_linear_duty(struct nvkm_therm *therm, u8 linear_min_temp,
therm              73 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	u8  temp = therm->func->temp_get(therm);
therm              78 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->fan->bios.min_duty;
therm              80 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->fan->bios.max_duty;
therm              84 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	duty *= (therm->fan->bios.max_duty - therm->fan->bios.min_duty);
therm              86 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	duty += therm->fan->bios.min_duty;
therm              91 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_update_linear(struct nvkm_therm *therm)
therm              93 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	u8  min = therm->fan->bios.linear_min_temp;
therm              94 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	u8  max = therm->fan->bios.linear_max_temp;
therm              95 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	return nvkm_therm_compute_linear_duty(therm, min, max);
therm              99 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_update_linear_fallback(struct nvkm_therm *therm)
therm             101 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	u8 max = therm->bios_sensor.thrs_fan_boost.temp;
therm             102 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	return nvkm_therm_compute_linear_duty(therm, 30, max);
therm             106 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_update(struct nvkm_therm *therm, int mode)
therm             108 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             115 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	spin_lock_irqsave(&therm->lock, flags);
therm             117 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		mode = therm->mode;
therm             118 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->mode = mode;
therm             122 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		nvkm_timer_alarm(tmr, 0, &therm->alarm);
therm             123 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		duty = nvkm_therm_fan_get(therm);
therm             129 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		switch(therm->fan->bios.fan_mode) {
therm             131 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 			duty = nvkm_therm_update_trip(therm);
therm             134 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 			duty = nvkm_therm_update_linear(therm);
therm             137 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 			if (therm->cstate) {
therm             138 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 				duty = therm->cstate;
therm             141 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 				duty = nvkm_therm_update_linear_fallback(therm);
therm             149 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		nvkm_timer_alarm(tmr, 0, &therm->alarm);
therm             154 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		nvkm_timer_alarm(tmr, 1000000000ULL, &therm->alarm);
therm             155 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	spin_unlock_irqrestore(&therm->lock, flags);
therm             159 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		nvkm_therm_fan_set(therm, immd, duty);
therm             164 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_cstate(struct nvkm_therm *therm, int fan, int dir)
therm             166 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             167 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (!dir || (dir < 0 && fan < therm->cstate) ||
therm             168 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		    (dir > 0 && fan > therm->cstate)) {
therm             170 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->cstate = fan;
therm             171 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		nvkm_therm_update(therm, -1);
therm             179 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_therm *therm =
therm             181 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_update(therm, -1);
therm             185 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_fan_mode(struct nvkm_therm *therm, int mode)
therm             187 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             203 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	    therm->func->temp_get(therm) < 0)
therm             206 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (therm->mode == mode)
therm             210 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_update(therm, mode);
therm             215 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_attr_get(struct nvkm_therm *therm, enum nvkm_therm_attr_type type)
therm             219 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->fan->bios.min_duty;
therm             221 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->fan->bios.max_duty;
therm             223 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->mode;
therm             225 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->bios_sensor.thrs_fan_boost.temp;
therm             227 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->bios_sensor.thrs_fan_boost.hysteresis;
therm             229 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->bios_sensor.thrs_down_clock.temp;
therm             231 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->bios_sensor.thrs_down_clock.hysteresis;
therm             233 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->bios_sensor.thrs_critical.temp;
therm             235 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->bios_sensor.thrs_critical.hysteresis;
therm             237 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->bios_sensor.thrs_shutdown.temp;
therm             239 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return therm->bios_sensor.thrs_shutdown.hysteresis;
therm             246 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_attr_set(struct nvkm_therm *therm,
therm             253 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		if (value > therm->fan->bios.max_duty)
therm             254 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 			value = therm->fan->bios.max_duty;
therm             255 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->fan->bios.min_duty = value;
therm             260 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		if (value < therm->fan->bios.min_duty)
therm             261 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 			value = therm->fan->bios.min_duty;
therm             262 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->fan->bios.max_duty = value;
therm             265 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		return nvkm_therm_fan_mode(therm, value);
therm             267 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->bios_sensor.thrs_fan_boost.temp = value;
therm             268 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->program_alarms(therm);
therm             271 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->bios_sensor.thrs_fan_boost.hysteresis = value;
therm             272 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->program_alarms(therm);
therm             275 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->bios_sensor.thrs_down_clock.temp = value;
therm             276 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->program_alarms(therm);
therm             279 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->bios_sensor.thrs_down_clock.hysteresis = value;
therm             280 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->program_alarms(therm);
therm             283 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->bios_sensor.thrs_critical.temp = value;
therm             284 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->program_alarms(therm);
therm             287 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->bios_sensor.thrs_critical.hysteresis = value;
therm             288 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->program_alarms(therm);
therm             291 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->bios_sensor.thrs_shutdown.temp = value;
therm             292 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->program_alarms(therm);
therm             295 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->bios_sensor.thrs_shutdown.hysteresis = value;
therm             296 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->program_alarms(therm);
therm             304 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_clkgate_enable(struct nvkm_therm *therm)
therm             306 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (!therm || !therm->func->clkgate_enable || !therm->clkgating_enabled)
therm             309 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_debug(&therm->subdev,
therm             311 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->func->clkgate_enable(therm);
therm             315 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_clkgate_fini(struct nvkm_therm *therm, bool suspend)
therm             317 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (!therm || !therm->func->clkgate_fini || !therm->clkgating_enabled)
therm             320 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_debug(&therm->subdev,
therm             323 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->func->clkgate_fini(therm, suspend);
therm             327 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_clkgate_oneinit(struct nvkm_therm *therm)
therm             329 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (!therm->func->clkgate_enable || !therm->clkgating_enabled)
therm             332 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_info(&therm->subdev, "Clockgating enabled\n");
therm             338 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_therm *therm = nvkm_therm(subdev);
therm             339 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (therm->func->intr)
therm             340 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->intr(therm);
therm             346 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_therm *therm = nvkm_therm(subdev);
therm             348 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (therm->func->fini)
therm             349 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->fini(therm);
therm             351 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_fan_fini(therm, suspend);
therm             352 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_sensor_fini(therm, suspend);
therm             355 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->suspend = therm->mode;
therm             356 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->mode = NVKM_THERM_CTRL_NONE;
therm             365 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_therm *therm = nvkm_therm(subdev);
therm             366 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_sensor_ctor(therm);
therm             367 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_ic_ctor(therm);
therm             368 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_fan_ctor(therm);
therm             369 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_fan_mode(therm, NVKM_THERM_CTRL_AUTO);
therm             370 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_sensor_preinit(therm);
therm             371 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_clkgate_oneinit(therm);
therm             378 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_therm *therm = nvkm_therm(subdev);
therm             380 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (therm->func->init)
therm             381 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		therm->func->init(therm);
therm             383 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (therm->suspend >= 0) {
therm             385 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		if (therm->suspend > 0)
therm             386 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 			nvkm_therm_fan_set(therm, true, therm->fan->percent);
therm             388 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 		nvkm_therm_fan_mode(therm, therm->suspend);
therm             391 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_sensor_init(therm);
therm             392 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_fan_init(therm);
therm             397 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_clkgate_init(struct nvkm_therm *therm,
therm             400 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (!therm || !therm->func->clkgate_init || !therm->clkgating_enabled)
therm             403 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->func->clkgate_init(therm, p);
therm             409 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_therm *therm = nvkm_therm(subdev);
therm             410 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	kfree(therm->fan);
therm             411 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	return therm;
therm             424 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c nvkm_therm_ctor(struct nvkm_therm *therm, struct nvkm_device *device,
therm             427 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_subdev_ctor(&nvkm_therm, device, index, &therm->subdev);
therm             428 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->func = func;
therm             430 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_alarm_init(&therm->alarm, nvkm_therm_alarm);
therm             431 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	spin_lock_init(&therm->lock);
therm             432 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	spin_lock_init(&therm->sensor.alarm_program_lock);
therm             434 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->fan_get = nvkm_therm_fan_user_get;
therm             435 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->fan_set = nvkm_therm_fan_user_set;
therm             436 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->attr_get = nvkm_therm_attr_get;
therm             437 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->attr_set = nvkm_therm_attr_set;
therm             438 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->mode = therm->suspend = -1; /* undefined */
therm             440 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	therm->clkgating_enabled = nvkm_boolopt(device->cfgopt,
therm             448 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	struct nvkm_therm *therm;
therm             450 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	if (!(therm = *ptherm = kzalloc(sizeof(*therm), GFP_KERNEL)))
therm             453 drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c 	nvkm_therm_ctor(therm, device, index, func);
therm              34 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	struct nvkm_therm *therm = fan->parent;
therm              35 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm              53 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	duty = fan->get(therm);
therm              74 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	ret = fan->set(therm, duty);
therm             112 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_get(struct nvkm_therm *therm)
therm             114 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	return therm->fan->get(therm);
therm             118 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_set(struct nvkm_therm *therm, bool immediate, int percent)
therm             120 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	return nvkm_fan_update(therm->fan, immediate, percent);
therm             124 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_sense(struct nvkm_therm *therm)
therm             126 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	struct nvkm_device *device = therm->subdev.device;
therm             132 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	if (therm->func->fan_sense)
therm             133 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		return therm->func->fan_sense(therm);
therm             135 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	if (therm->fan->tach.func == DCB_GPIO_UNUSED)
therm             143 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	prev = nvkm_gpio_get(gpio, 0, therm->fan->tach.func,
therm             144 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 				      therm->fan->tach.line);
therm             149 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		cur = nvkm_gpio_get(gpio, 0, therm->fan->tach.func,
therm             150 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 					     therm->fan->tach.line);
therm             169 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_user_get(struct nvkm_therm *therm)
therm             171 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	return nvkm_therm_fan_get(therm);
therm             175 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_user_set(struct nvkm_therm *therm, int percent)
therm             177 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	if (therm->mode != NVKM_THERM_CTRL_MANUAL)
therm             180 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	return nvkm_therm_fan_set(therm, true, percent);
therm             184 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_set_defaults(struct nvkm_therm *therm)
therm             186 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->bios.pwm_freq = 0;
therm             187 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->bios.min_duty = 0;
therm             188 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->bios.max_duty = 100;
therm             189 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->bios.bump_period = 500;
therm             190 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->bios.slow_down_period = 2000;
therm             191 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->bios.linear_min_temp = 40;
therm             192 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->bios.linear_max_temp = 85;
therm             196 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_safety_checks(struct nvkm_therm *therm)
therm             198 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	if (therm->fan->bios.min_duty > 100)
therm             199 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		therm->fan->bios.min_duty = 100;
therm             200 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	if (therm->fan->bios.max_duty > 100)
therm             201 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		therm->fan->bios.max_duty = 100;
therm             203 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	if (therm->fan->bios.min_duty > therm->fan->bios.max_duty)
therm             204 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		therm->fan->bios.min_duty = therm->fan->bios.max_duty;
therm             208 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_init(struct nvkm_therm *therm)
therm             214 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_fini(struct nvkm_therm *therm, bool suspend)
therm             216 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	struct nvkm_timer *tmr = therm->subdev.device->timer;
therm             218 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		nvkm_timer_alarm(tmr, 0, &therm->fan->alarm);
therm             223 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c nvkm_therm_fan_ctor(struct nvkm_therm *therm)
therm             225 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             240 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 			ret = nvkm_fanpwm_create(therm, &func);
therm             242 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 				ret = nvkm_fantog_create(therm, &func);
therm             248 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		ret = nvkm_fannil_create(therm);
therm             253 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	nvkm_debug(subdev, "FAN control: %s\n", therm->fan->type);
therm             256 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->percent = nvkm_therm_fan_get(therm);
therm             260 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 			     &therm->fan->tach);
therm             262 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		therm->fan->tach.func = DCB_GPIO_UNUSED;
therm             265 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	therm->fan->parent = therm;
therm             266 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	nvkm_alarm_init(&therm->fan->alarm, nvkm_fan_alarm);
therm             267 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	spin_lock_init(&therm->fan->lock);
therm             270 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	nvkm_therm_fan_set_defaults(therm);
therm             271 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	nvbios_perf_fan_parse(bios, &therm->fan->perf);
therm             272 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	if (!nvbios_fan_parse(bios, &therm->fan->bios)) {
therm             274 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 		if (nvbios_therm_fan_parse(bios, &therm->fan->bios))
therm             277 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fan.c 	nvkm_therm_fan_safety_checks(therm);
therm              27 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fannil.c nvkm_fannil_get(struct nvkm_therm *therm)
therm              33 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fannil.c nvkm_fannil_set(struct nvkm_therm *therm, int percent)
therm              39 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fannil.c nvkm_fannil_create(struct nvkm_therm *therm)
therm              44 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fannil.c 	therm->fan = priv;
therm              38 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c nvkm_fanpwm_get(struct nvkm_therm *therm)
therm              40 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	struct nvkm_fanpwm *fan = (void *)therm->fan;
therm              41 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	struct nvkm_device *device = therm->subdev.device;
therm              47 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	ret = therm->func->pwm_get(therm, fan->func.line, &divs, &duty);
therm              59 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c nvkm_fanpwm_set(struct nvkm_therm *therm, int percent)
therm              61 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	struct nvkm_fanpwm *fan = (void *)therm->fan;
therm              62 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	int card_type = therm->subdev.device->card_type;
therm              69 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 		if (therm->func->pwm_clock)
therm              70 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 			divs = therm->func->pwm_clock(therm, fan->func.line);
therm              78 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	ret = therm->func->pwm_set(therm, fan->func.line, divs, duty);
therm              80 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 		ret = therm->func->pwm_ctrl(therm, fan->func.line, true);
therm              85 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c nvkm_fanpwm_create(struct nvkm_therm *therm, struct dcb_gpio_func *func)
therm              87 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	struct nvkm_device *device = therm->subdev.device;
therm              96 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	    !therm->func->pwm_ctrl || info.type == NVBIOS_THERM_FAN_TOGGLE ||
therm              97 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	     therm->func->pwm_get(therm, func->line, &divs, &duty) == -ENODEV)
therm             101 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fanpwm.c 	therm->fan = &fan->base;
therm              41 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 	struct nvkm_therm *therm = fan->base.parent;
therm              42 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 	struct nvkm_device *device = therm->subdev.device;
therm              74 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c nvkm_fantog_get(struct nvkm_therm *therm)
therm              76 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 	struct nvkm_fantog *fan = (void *)therm->fan;
therm              81 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c nvkm_fantog_set(struct nvkm_therm *therm, int percent)
therm              83 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 	struct nvkm_fantog *fan = (void *)therm->fan;
therm              84 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 	if (therm->func->pwm_ctrl)
therm              85 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 		therm->func->pwm_ctrl(therm, fan->func.line, false);
therm              91 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c nvkm_fantog_create(struct nvkm_therm *therm, struct dcb_gpio_func *func)
therm              96 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 	if (therm->func->pwm_ctrl) {
therm              97 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 		ret = therm->func->pwm_ctrl(therm, func->line, false);
therm             103 drivers/gpu/drm/nouveau/nvkm/subdev/therm/fantog.c 	therm->fan = &fan->base;
therm              30 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c g84_temp_get(struct nvkm_therm *therm)
therm              32 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvkm_device *device = therm->subdev.device;
therm              41 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c g84_sensor_setup(struct nvkm_therm *therm)
therm              43 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvkm_device *device = therm->subdev.device;
therm              54 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c g84_therm_program_alarms(struct nvkm_therm *therm)
therm              56 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvbios_therm_sensor *sensor = &therm->bios_sensor;
therm              57 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm              61 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	spin_lock_irqsave(&therm->sensor.alarm_program_lock, flags);
therm              78 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	spin_unlock_irqrestore(&therm->sensor.alarm_program_lock, flags);
therm              95 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c g84_therm_threshold_hyst_emulation(struct nvkm_therm *therm,
therm             100 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvkm_device *device = therm->subdev.device;
therm             105 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	prev_state = nvkm_therm_sensor_get_threshold_state(therm, thrs_name);
therm             118 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	cur = therm->func->temp_get(therm);
therm             124 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	nvkm_therm_sensor_set_threshold_state(therm, thrs_name, new_state);
therm             135 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	nvkm_therm_sensor_event(therm, thrs_name, direction);
therm             139 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c g84_therm_intr(struct nvkm_therm *therm)
therm             141 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             143 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvbios_therm_sensor *sensor = &therm->bios_sensor;
therm             147 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	spin_lock_irqsave(&therm->sensor.alarm_program_lock, flags);
therm             153 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 		g84_therm_threshold_hyst_emulation(therm, 0x20414, 24,
therm             161 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 		g84_therm_threshold_hyst_emulation(therm, 0x20480, 20,
therm             169 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 		g84_therm_threshold_hyst_emulation(therm, 0x204c4, 21,
therm             177 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 		g84_therm_threshold_hyst_emulation(therm, 0x204c0, 22,
therm             190 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	spin_unlock_irqrestore(&therm->sensor.alarm_program_lock, flags);
therm             194 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c g84_therm_fini(struct nvkm_therm *therm)
therm             196 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvkm_device *device = therm->subdev.device;
therm             207 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c g84_therm_init(struct nvkm_therm *therm)
therm             209 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	g84_sensor_setup(therm);
therm             228 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	struct nvkm_therm *therm;
therm             231 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	ret = nvkm_therm_new_(&g84_therm, device, index, &therm);
therm             232 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	*ptherm = therm;
therm             237 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	nvkm_therm_sensor_set_threshold_state(therm, NVKM_THERM_THRS_SHUTDOWN,
therm             239 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	nvkm_therm_sensor_set_threshold_state(therm, NVKM_THERM_THRS_FANBOOST,
therm             241 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	nvkm_therm_sensor_set_threshold_state(therm, NVKM_THERM_THRS_CRITICAL,
therm             243 drivers/gpu/drm/nouveau/nvkm/subdev/therm/g84.c 	nvkm_therm_sensor_set_threshold_state(therm, NVKM_THERM_THRS_DOWNCLOCK,
therm              32 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf100.c gf100_clkgate_init(struct nvkm_therm *therm,
therm              35 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf100.c 	struct nvkm_device *device = therm->subdev.device;
therm              44 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf100.c 		nvkm_trace(&therm->subdev, "{ 0x%06x, %d, 0x%08x }\n",
therm              47 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf100.c 			nvkm_trace(&therm->subdev, "\t0x%06x = 0x%08x\n",
therm              27 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c pwm_info(struct nvkm_therm *therm, int line)
therm              29 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm              53 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c gf119_fan_pwm_ctrl(struct nvkm_therm *therm, int line, bool enable)
therm              55 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	struct nvkm_device *device = therm->subdev.device;
therm              57 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	int indx = pwm_info(therm, line);
therm              67 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c gf119_fan_pwm_get(struct nvkm_therm *therm, int line, u32 *divs, u32 *duty)
therm              69 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	struct nvkm_device *device = therm->subdev.device;
therm              70 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	int indx = pwm_info(therm, line);
therm              89 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c gf119_fan_pwm_set(struct nvkm_therm *therm, int line, u32 divs, u32 duty)
therm              91 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	struct nvkm_device *device = therm->subdev.device;
therm              92 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	int indx = pwm_info(therm, line);
therm             106 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c gf119_fan_pwm_clock(struct nvkm_therm *therm, int line)
therm             108 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	struct nvkm_device *device = therm->subdev.device;
therm             109 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	int indx = pwm_info(therm, line);
therm             119 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c gf119_therm_init(struct nvkm_therm *therm)
therm             121 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	struct nvkm_device *device = therm->subdev.device;
therm             123 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	g84_sensor_setup(therm);
therm             127 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 	if (therm->fan->tach.func != DCB_GPIO_UNUSED) {
therm             128 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gf119.c 		nvkm_mask(device, 0x00d79c, 0x000000ff, therm->fan->tach.line);
therm              32 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	struct gk104_therm *therm = gk104_therm(base);
therm              33 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	struct nvkm_device *dev = therm->base.subdev.device;
therm              34 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	const struct gk104_clkgate_engine_info *order = therm->clkgate_order;
therm              46 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	nvkm_wr32(dev, 0x020288, therm->idle_filter->fecs);
therm              47 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	nvkm_wr32(dev, 0x02028c, therm->idle_filter->hubmmu);
therm              61 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	struct gk104_therm *therm = gk104_therm(base);
therm              62 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	struct nvkm_device *dev = therm->base.subdev.device;
therm              63 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	const struct gk104_clkgate_engine_info *order = therm->clkgate_order;
therm             116 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	struct gk104_therm *therm = kzalloc(sizeof(*therm), GFP_KERNEL);
therm             118 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	if (!therm)
therm             121 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	nvkm_therm_ctor(&therm->base, device, index, func);
therm             122 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	*ptherm = &therm->base;
therm             123 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	therm->clkgate_order = clkgate_order;
therm             124 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gk104.c 	therm->idle_filter = idle_filter;
therm              27 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gm107.c gm107_fan_pwm_ctrl(struct nvkm_therm *therm, int line, bool enable)
therm              34 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gm107.c gm107_fan_pwm_get(struct nvkm_therm *therm, int line, u32 *divs, u32 *duty)
therm              36 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gm107.c 	struct nvkm_device *device = therm->subdev.device;
therm              43 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gm107.c gm107_fan_pwm_set(struct nvkm_therm *therm, int line, u32 divs, u32 duty)
therm              45 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gm107.c 	struct nvkm_device *device = therm->subdev.device;
therm              52 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gm107.c gm107_fan_pwm_clock(struct nvkm_therm *therm, int line)
therm              54 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gm107.c 	return therm->subdev.device->crystal * 1000;
therm              27 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gp100.c gp100_temp_get(struct nvkm_therm *therm)
therm              29 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gp100.c 	struct nvkm_device *device = therm->subdev.device;
therm              30 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gp100.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm              29 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gt215.c gt215_therm_fan_sense(struct nvkm_therm *therm)
therm              31 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gt215.c 	struct nvkm_device *device = therm->subdev.device;
therm              40 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gt215.c gt215_therm_init(struct nvkm_therm *therm)
therm              42 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gt215.c 	struct nvkm_device *device = therm->subdev.device;
therm              43 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gt215.c 	struct dcb_gpio_func *tach = &therm->fan->tach;
therm              45 drivers/gpu/drm/nouveau/nvkm/subdev/therm/gt215.c 	g84_sensor_setup(therm);
therm              33 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 	struct nvkm_therm *therm = data;
therm              34 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 	struct nvbios_therm_sensor *sensor = &therm->bios_sensor;
therm              49 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 	nvkm_debug(&therm->subdev,
therm              53 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 	therm->ic = client;
therm              83 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c nvkm_therm_ic_ctor(struct nvkm_therm *therm)
therm              85 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 	struct nvkm_device *device = therm->subdev.device;
therm             102 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 				   probe_monitoring_device, therm);
therm             103 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 		if (therm->ic)
therm             114 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 				   probe_monitoring_device, therm);
therm             115 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 		if (therm->ic)
therm             126 drivers/gpu/drm/nouveau/nvkm/subdev/therm/ic.c 			   probe_monitoring_device, therm);
therm              30 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c nv40_sensor_style(struct nvkm_therm *therm)
therm              32 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	switch (therm->subdev.device->chipset) {
therm              53 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c nv40_sensor_setup(struct nvkm_therm *therm)
therm              55 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	struct nvkm_device *device = therm->subdev.device;
therm              56 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	enum nv40_sensor_style style = nv40_sensor_style(therm);
therm              73 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c nv40_temp_get(struct nvkm_therm *therm)
therm              75 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	struct nvkm_device *device = therm->subdev.device;
therm              76 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	struct nvbios_therm_sensor *sensor = &therm->bios_sensor;
therm              77 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	enum nv40_sensor_style style = nv40_sensor_style(therm);
therm             106 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c nv40_fan_pwm_ctrl(struct nvkm_therm *therm, int line, bool enable)
therm             108 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             121 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c nv40_fan_pwm_get(struct nvkm_therm *therm, int line, u32 *divs, u32 *duty)
therm             123 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             149 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c nv40_fan_pwm_set(struct nvkm_therm *therm, int line, u32 divs, u32 duty)
therm             151 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             168 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c nv40_therm_intr(struct nvkm_therm *therm)
therm             170 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             183 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c nv40_therm_init(struct nvkm_therm *therm)
therm             185 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv40.c 	nv40_sensor_setup(therm);
therm              28 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c pwm_info(struct nvkm_therm *therm, int *line, int *ctrl, int *indx)
therm              30 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm              55 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c nv50_fan_pwm_ctrl(struct nvkm_therm *therm, int line, bool enable)
therm              57 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	struct nvkm_device *device = therm->subdev.device;
therm              59 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	int ctrl, id, ret = pwm_info(therm, &line, &ctrl, &id);
therm              66 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c nv50_fan_pwm_get(struct nvkm_therm *therm, int line, u32 *divs, u32 *duty)
therm              68 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	struct nvkm_device *device = therm->subdev.device;
therm              69 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	int ctrl, id, ret = pwm_info(therm, &line, &ctrl, &id);
therm              83 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c nv50_fan_pwm_set(struct nvkm_therm *therm, int line, u32 divs, u32 duty)
therm              85 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	struct nvkm_device *device = therm->subdev.device;
therm              86 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	int ctrl, id, ret = pwm_info(therm, &line, &ctrl, &id);
therm              96 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c nv50_fan_pwm_clock(struct nvkm_therm *therm, int line)
therm              98 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	struct nvkm_device *device = therm->subdev.device;
therm             121 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c nv50_sensor_setup(struct nvkm_therm *therm)
therm             123 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	struct nvkm_device *device = therm->subdev.device;
therm             129 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c nv50_temp_get(struct nvkm_therm *therm)
therm             131 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	struct nvkm_device *device = therm->subdev.device;
therm             132 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	struct nvbios_therm_sensor *sensor = &therm->bios_sensor;
therm             154 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c nv50_therm_init(struct nvkm_therm *therm)
therm             156 drivers/gpu/drm/nouveau/nvkm/subdev/therm/nv50.c 	nv50_sensor_setup(therm);
therm              35 drivers/gpu/drm/nouveau/nvkm/subdev/therm/priv.h void nvkm_therm_ctor(struct nvkm_therm *therm, struct nvkm_device *device,
therm              27 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_temp_set_defaults(struct nvkm_therm *therm)
therm              29 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.offset_constant = 0;
therm              31 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.thrs_fan_boost.temp = 90;
therm              32 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.thrs_fan_boost.hysteresis = 3;
therm              34 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.thrs_down_clock.temp = 95;
therm              35 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.thrs_down_clock.hysteresis = 3;
therm              37 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.thrs_critical.temp = 105;
therm              38 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.thrs_critical.hysteresis = 5;
therm              40 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.thrs_shutdown.temp = 135;
therm              41 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->bios_sensor.thrs_shutdown.hysteresis = 5; /*not that it matters */
therm              45 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_temp_safety_checks(struct nvkm_therm *therm)
therm              47 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	struct nvbios_therm_sensor *s = &therm->bios_sensor;
therm              58 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_sensor_set_threshold_state(struct nvkm_therm *therm,
therm              62 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->sensor.alarm_state[thrs] = st;
therm              67 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_sensor_get_threshold_state(struct nvkm_therm *therm,
therm              70 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	return therm->sensor.alarm_state[thrs];
therm              81 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_sensor_event(struct nvkm_therm *therm, enum nvkm_therm_thrs thrs,
therm              84 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm              89 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	int temperature = therm->func->temp_get(therm);
therm             106 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 			nvkm_therm_fan_set(therm, true, 100);
therm             107 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 			nvkm_therm_fan_mode(therm, NVKM_THERM_CTRL_AUTO);
therm             111 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 		if (therm->emergency.downclock)
therm             112 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 			therm->emergency.downclock(therm, active);
therm             115 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 		if (therm->emergency.pause)
therm             116 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 			therm->emergency.pause(therm, active);
therm             137 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_threshold_hyst_polling(struct nvkm_therm *therm,
therm             143 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	int temp = therm->func->temp_get(therm);
therm             145 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	prev_state = nvkm_therm_sensor_get_threshold_state(therm, thrs_name);
therm             157 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_therm_sensor_set_threshold_state(therm, thrs_name, new_state);
therm             158 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_therm_sensor_event(therm, thrs_name, direction);
therm             164 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	struct nvkm_therm *therm =
therm             166 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	struct nvbios_therm_sensor *sensor = &therm->bios_sensor;
therm             167 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	struct nvkm_timer *tmr = therm->subdev.device->timer;
therm             170 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	spin_lock_irqsave(&therm->sensor.alarm_program_lock, flags);
therm             172 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_therm_threshold_hyst_polling(therm, &sensor->thrs_fan_boost,
therm             175 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_therm_threshold_hyst_polling(therm,
therm             179 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_therm_threshold_hyst_polling(therm, &sensor->thrs_critical,
therm             182 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_therm_threshold_hyst_polling(therm, &sensor->thrs_shutdown,
therm             185 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	spin_unlock_irqrestore(&therm->sensor.alarm_program_lock, flags);
therm             188 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	if (therm->func->temp_get(therm) >= 0)
therm             193 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_program_alarms_polling(struct nvkm_therm *therm)
therm             195 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	struct nvbios_therm_sensor *sensor = &therm->bios_sensor;
therm             197 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_debug(&therm->subdev,
therm             208 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	alarm_timer_callback(&therm->sensor.therm_poll_alarm);
therm             212 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_sensor_init(struct nvkm_therm *therm)
therm             214 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	therm->func->program_alarms(therm);
therm             219 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_sensor_fini(struct nvkm_therm *therm, bool suspend)
therm             221 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	struct nvkm_timer *tmr = therm->subdev.device->timer;
therm             223 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 		nvkm_timer_alarm(tmr, 0, &therm->sensor.therm_poll_alarm);
therm             228 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_sensor_preinit(struct nvkm_therm *therm)
therm             232 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	if (therm->func->temp_get(therm) < 0)
therm             235 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_debug(&therm->subdev, "internal sensor: %s\n", sensor_avail);
therm             239 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c nvkm_therm_sensor_ctor(struct nvkm_therm *therm)
therm             241 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	struct nvkm_subdev *subdev = &therm->subdev;
therm             244 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_alarm_init(&therm->sensor.therm_poll_alarm, alarm_timer_callback);
therm             246 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_therm_temp_set_defaults(therm);
therm             248 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 				      &therm->bios_sensor))
therm             250 drivers/gpu/drm/nouveau/nvkm/subdev/therm/temp.c 	nvkm_therm_temp_safety_checks(therm);
therm              92 drivers/hwmon/stts751.c 	int therm;
therm             430 drivers/hwmon/stts751.c 	return snprintf(buf, PAGE_SIZE, "%d\n", priv->therm);
therm             456 drivers/hwmon/stts751.c 	priv->hyst = temp - (priv->therm - priv->hyst);
therm             457 drivers/hwmon/stts751.c 	priv->therm = temp;
therm             488 drivers/hwmon/stts751.c 	temp = clamp_val(temp, -64000, priv->therm);
therm             491 drivers/hwmon/stts751.c 	temp = priv->therm - temp;
therm             729 drivers/hwmon/stts751.c 	ret = stts751_read_reg8(priv, &priv->therm, STTS751_REG_TLIM);
therm             736 drivers/hwmon/stts751.c 	priv->hyst = priv->therm - tmp;
therm             746 drivers/hwmon/stts751.c static SENSOR_DEVICE_ATTR_RW(temp1_crit, therm, 0);
therm             987 drivers/infiniband/hw/hfi1/pcie.c 	u64 reg, therm;
therm            1068 drivers/infiniband/hw/hfi1/pcie.c 	therm = read_csr(dd, ASIC_CFG_THERM_POLL_EN);
therm            1069 drivers/infiniband/hw/hfi1/pcie.c 	if (therm) {
therm            1428 drivers/infiniband/hw/hfi1/pcie.c 	if (therm) {