/linux-6.1.9/drivers/gpu/drm/nouveau/nvkm/subdev/therm/ |
D | base.c | 30 nvkm_therm_temp_get(struct nvkm_therm *therm) in nvkm_therm_temp_get() argument 32 if (therm->func->temp_get) in nvkm_therm_temp_get() 33 return therm->func->temp_get(therm); in nvkm_therm_temp_get() 38 nvkm_therm_update_trip(struct nvkm_therm *therm) in nvkm_therm_update_trip() argument 40 struct nvbios_therm_trip_point *trip = therm->fan->bios.trip, in nvkm_therm_update_trip() 42 *last_trip = therm->last_trip; in nvkm_therm_update_trip() 43 u8 temp = therm->func->temp_get(therm); in nvkm_therm_update_trip() 48 for (i = 0; i < therm->fan->bios.nr_fan_trip; i++) { in nvkm_therm_update_trip() 60 therm->last_trip = cur_trip; in nvkm_therm_update_trip() 63 therm->last_trip = NULL; in nvkm_therm_update_trip() [all …]
|
D | temp.c | 27 nvkm_therm_temp_set_defaults(struct nvkm_therm *therm) in nvkm_therm_temp_set_defaults() argument 29 therm->bios_sensor.offset_constant = 0; in nvkm_therm_temp_set_defaults() 31 therm->bios_sensor.thrs_fan_boost.temp = 90; in nvkm_therm_temp_set_defaults() 32 therm->bios_sensor.thrs_fan_boost.hysteresis = 3; in nvkm_therm_temp_set_defaults() 34 therm->bios_sensor.thrs_down_clock.temp = 95; in nvkm_therm_temp_set_defaults() 35 therm->bios_sensor.thrs_down_clock.hysteresis = 3; in nvkm_therm_temp_set_defaults() 37 therm->bios_sensor.thrs_critical.temp = 105; in nvkm_therm_temp_set_defaults() 38 therm->bios_sensor.thrs_critical.hysteresis = 5; in nvkm_therm_temp_set_defaults() 40 therm->bios_sensor.thrs_shutdown.temp = 135; in nvkm_therm_temp_set_defaults() 41 therm->bios_sensor.thrs_shutdown.hysteresis = 5; /*not that it matters */ in nvkm_therm_temp_set_defaults() [all …]
|
D | fan.c | 34 struct nvkm_therm *therm = fan->parent; in nvkm_fan_update() local 35 struct nvkm_subdev *subdev = &therm->subdev; in nvkm_fan_update() 53 duty = fan->get(therm); in nvkm_fan_update() 74 ret = fan->set(therm, duty); in nvkm_fan_update() 112 nvkm_therm_fan_get(struct nvkm_therm *therm) in nvkm_therm_fan_get() argument 114 return therm->fan->get(therm); in nvkm_therm_fan_get() 118 nvkm_therm_fan_set(struct nvkm_therm *therm, bool immediate, int percent) in nvkm_therm_fan_set() argument 120 return nvkm_fan_update(therm->fan, immediate, percent); in nvkm_therm_fan_set() 124 nvkm_therm_fan_sense(struct nvkm_therm *therm) in nvkm_therm_fan_sense() argument 126 struct nvkm_device *device = therm->subdev.device; in nvkm_therm_fan_sense() [all …]
|
D | g84.c | 30 g84_temp_get(struct nvkm_therm *therm) in g84_temp_get() argument 32 struct nvkm_device *device = therm->subdev.device; in g84_temp_get() 41 g84_sensor_setup(struct nvkm_therm *therm) in g84_sensor_setup() argument 43 struct nvkm_device *device = therm->subdev.device; in g84_sensor_setup() 54 g84_therm_program_alarms(struct nvkm_therm *therm) in g84_therm_program_alarms() argument 56 struct nvbios_therm_sensor *sensor = &therm->bios_sensor; in g84_therm_program_alarms() 57 struct nvkm_subdev *subdev = &therm->subdev; in g84_therm_program_alarms() 61 spin_lock_irqsave(&therm->sensor.alarm_program_lock, flags); in g84_therm_program_alarms() 78 spin_unlock_irqrestore(&therm->sensor.alarm_program_lock, flags); in g84_therm_program_alarms() 95 g84_therm_threshold_hyst_emulation(struct nvkm_therm *therm, in g84_therm_threshold_hyst_emulation() argument [all …]
|
D | fanpwm.c | 38 nvkm_fanpwm_get(struct nvkm_therm *therm) in nvkm_fanpwm_get() argument 40 struct nvkm_fanpwm *fan = (void *)therm->fan; in nvkm_fanpwm_get() 41 struct nvkm_device *device = therm->subdev.device; in nvkm_fanpwm_get() 47 ret = therm->func->pwm_get(therm, fan->func.line, &divs, &duty); in nvkm_fanpwm_get() 59 nvkm_fanpwm_set(struct nvkm_therm *therm, int percent) in nvkm_fanpwm_set() argument 61 struct nvkm_fanpwm *fan = (void *)therm->fan; in nvkm_fanpwm_set() 62 int card_type = therm->subdev.device->card_type; in nvkm_fanpwm_set() 69 if (therm->func->pwm_clock) in nvkm_fanpwm_set() 70 divs = therm->func->pwm_clock(therm, fan->func.line); in nvkm_fanpwm_set() 78 ret = therm->func->pwm_set(therm, fan->func.line, divs, duty); in nvkm_fanpwm_set() [all …]
|
D | Kbuild | 2 nvkm-y += nvkm/subdev/therm/base.o 3 nvkm-y += nvkm/subdev/therm/fan.o 4 nvkm-y += nvkm/subdev/therm/fannil.o 5 nvkm-y += nvkm/subdev/therm/fanpwm.o 6 nvkm-y += nvkm/subdev/therm/fantog.o 7 nvkm-y += nvkm/subdev/therm/ic.o 8 nvkm-y += nvkm/subdev/therm/temp.o 9 nvkm-y += nvkm/subdev/therm/nv40.o 10 nvkm-y += nvkm/subdev/therm/nv50.o 11 nvkm-y += nvkm/subdev/therm/g84.o [all …]
|
D | gf119.c | 27 pwm_info(struct nvkm_therm *therm, int line) in pwm_info() argument 29 struct nvkm_subdev *subdev = &therm->subdev; in pwm_info() 54 gf119_fan_pwm_ctrl(struct nvkm_therm *therm, int line, bool enable) in gf119_fan_pwm_ctrl() argument 56 struct nvkm_device *device = therm->subdev.device; in gf119_fan_pwm_ctrl() 58 int indx = pwm_info(therm, line); in gf119_fan_pwm_ctrl() 68 gf119_fan_pwm_get(struct nvkm_therm *therm, int line, u32 *divs, u32 *duty) in gf119_fan_pwm_get() argument 70 struct nvkm_device *device = therm->subdev.device; in gf119_fan_pwm_get() 71 int indx = pwm_info(therm, line); in gf119_fan_pwm_get() 90 gf119_fan_pwm_set(struct nvkm_therm *therm, int line, u32 divs, u32 duty) in gf119_fan_pwm_set() argument 92 struct nvkm_device *device = therm->subdev.device; in gf119_fan_pwm_set() [all …]
|
D | nv50.c | 28 pwm_info(struct nvkm_therm *therm, int *line, int *ctrl, int *indx) in pwm_info() argument 30 struct nvkm_subdev *subdev = &therm->subdev; in pwm_info() 55 nv50_fan_pwm_ctrl(struct nvkm_therm *therm, int line, bool enable) in nv50_fan_pwm_ctrl() argument 57 struct nvkm_device *device = therm->subdev.device; in nv50_fan_pwm_ctrl() 59 int ctrl, id, ret = pwm_info(therm, &line, &ctrl, &id); in nv50_fan_pwm_ctrl() 66 nv50_fan_pwm_get(struct nvkm_therm *therm, int line, u32 *divs, u32 *duty) in nv50_fan_pwm_get() argument 68 struct nvkm_device *device = therm->subdev.device; in nv50_fan_pwm_get() 69 int ctrl, id, ret = pwm_info(therm, &line, &ctrl, &id); in nv50_fan_pwm_get() 83 nv50_fan_pwm_set(struct nvkm_therm *therm, int line, u32 divs, u32 duty) in nv50_fan_pwm_set() argument 85 struct nvkm_device *device = therm->subdev.device; in nv50_fan_pwm_set() [all …]
|
D | nv40.c | 30 nv40_sensor_style(struct nvkm_therm *therm) in nv40_sensor_style() argument 32 switch (therm->subdev.device->chipset) { in nv40_sensor_style() 53 nv40_sensor_setup(struct nvkm_therm *therm) in nv40_sensor_setup() argument 55 struct nvkm_device *device = therm->subdev.device; in nv40_sensor_setup() 56 enum nv40_sensor_style style = nv40_sensor_style(therm); in nv40_sensor_setup() 73 nv40_temp_get(struct nvkm_therm *therm) in nv40_temp_get() argument 75 struct nvkm_device *device = therm->subdev.device; in nv40_temp_get() 76 struct nvbios_therm_sensor *sensor = &therm->bios_sensor; in nv40_temp_get() 77 enum nv40_sensor_style style = nv40_sensor_style(therm); in nv40_temp_get() 106 nv40_fan_pwm_ctrl(struct nvkm_therm *therm, int line, bool enable) in nv40_fan_pwm_ctrl() argument [all …]
|
D | gk104.c | 32 struct gk104_therm *therm = gk104_therm(base); in gk104_clkgate_enable() local 33 struct nvkm_device *dev = therm->base.subdev.device; in gk104_clkgate_enable() 34 const struct gk104_clkgate_engine_info *order = therm->clkgate_order; in gk104_clkgate_enable() 46 nvkm_wr32(dev, 0x020288, therm->idle_filter->fecs); in gk104_clkgate_enable() 47 nvkm_wr32(dev, 0x02028c, therm->idle_filter->hubmmu); in gk104_clkgate_enable() 61 struct gk104_therm *therm = gk104_therm(base); in gk104_clkgate_fini() local 62 struct nvkm_device *dev = therm->base.subdev.device; in gk104_clkgate_fini() 63 const struct gk104_clkgate_engine_info *order = therm->clkgate_order; in gk104_clkgate_fini() 115 struct gk104_therm *therm = kzalloc(sizeof(*therm), GFP_KERNEL); in gk104_therm_new_() local 117 if (!therm) in gk104_therm_new_() [all …]
|
D | fantog.c | 41 struct nvkm_therm *therm = fan->base.parent; in nvkm_fantog_update() local 42 struct nvkm_device *device = therm->subdev.device; in nvkm_fantog_update() 74 nvkm_fantog_get(struct nvkm_therm *therm) in nvkm_fantog_get() argument 76 struct nvkm_fantog *fan = (void *)therm->fan; in nvkm_fantog_get() 81 nvkm_fantog_set(struct nvkm_therm *therm, int percent) in nvkm_fantog_set() argument 83 struct nvkm_fantog *fan = (void *)therm->fan; in nvkm_fantog_set() 84 if (therm->func->pwm_ctrl) in nvkm_fantog_set() 85 therm->func->pwm_ctrl(therm, fan->func.line, false); in nvkm_fantog_set() 91 nvkm_fantog_create(struct nvkm_therm *therm, struct dcb_gpio_func *func) in nvkm_fantog_create() argument 96 if (therm->func->pwm_ctrl) { in nvkm_fantog_create() [all …]
|
D | ic.c | 33 struct nvkm_therm *therm = data; in probe_monitoring_device() local 34 struct nvbios_therm_sensor *sensor = &therm->bios_sensor; in probe_monitoring_device() 49 nvkm_debug(&therm->subdev, in probe_monitoring_device() 53 therm->ic = client; in probe_monitoring_device() 83 nvkm_therm_ic_ctor(struct nvkm_therm *therm) in nvkm_therm_ic_ctor() argument 85 struct nvkm_device *device = therm->subdev.device; in nvkm_therm_ic_ctor() 102 probe_monitoring_device, therm); in nvkm_therm_ic_ctor() 103 if (therm->ic) in nvkm_therm_ic_ctor() 114 probe_monitoring_device, therm); in nvkm_therm_ic_ctor() 115 if (therm->ic) in nvkm_therm_ic_ctor() [all …]
|
D | gm107.c | 27 gm107_fan_pwm_ctrl(struct nvkm_therm *therm, int line, bool enable) in gm107_fan_pwm_ctrl() argument 34 gm107_fan_pwm_get(struct nvkm_therm *therm, int line, u32 *divs, u32 *duty) in gm107_fan_pwm_get() argument 36 struct nvkm_device *device = therm->subdev.device; in gm107_fan_pwm_get() 43 gm107_fan_pwm_set(struct nvkm_therm *therm, int line, u32 divs, u32 duty) in gm107_fan_pwm_set() argument 45 struct nvkm_device *device = therm->subdev.device; in gm107_fan_pwm_set() 52 gm107_fan_pwm_clock(struct nvkm_therm *therm, int line) in gm107_fan_pwm_clock() argument 54 return therm->subdev.device->crystal * 1000; in gm107_fan_pwm_clock()
|
D | gt215.c | 29 gt215_therm_fan_sense(struct nvkm_therm *therm) in gt215_therm_fan_sense() argument 31 struct nvkm_device *device = therm->subdev.device; in gt215_therm_fan_sense() 40 gt215_therm_init(struct nvkm_therm *therm) in gt215_therm_init() argument 42 struct nvkm_device *device = therm->subdev.device; in gt215_therm_init() 43 struct dcb_gpio_func *tach = &therm->fan->tach; in gt215_therm_init() 45 g84_sensor_setup(therm); in gt215_therm_init()
|
D | fannil.c | 27 nvkm_fannil_get(struct nvkm_therm *therm) in nvkm_fannil_get() argument 33 nvkm_fannil_set(struct nvkm_therm *therm, int percent) in nvkm_fannil_set() argument 39 nvkm_fannil_create(struct nvkm_therm *therm) in nvkm_fannil_create() argument 44 therm->fan = priv; in nvkm_fannil_create()
|
D | gf100.c | 32 gf100_clkgate_init(struct nvkm_therm *therm, in gf100_clkgate_init() argument 35 struct nvkm_device *device = therm->subdev.device; in gf100_clkgate_init() 44 nvkm_trace(&therm->subdev, "{ 0x%06x, %d, 0x%08x }\n", in gf100_clkgate_init() 47 nvkm_trace(&therm->subdev, "\t0x%06x = 0x%08x\n", in gf100_clkgate_init()
|
D | gp100.c | 27 gp100_temp_get(struct nvkm_therm *therm) in gp100_temp_get() argument 29 struct nvkm_device *device = therm->subdev.device; in gp100_temp_get() 30 struct nvkm_subdev *subdev = &therm->subdev; in gp100_temp_get()
|
/linux-6.1.9/drivers/gpu/drm/nouveau/ |
D | nouveau_hwmon.c | 55 struct nvkm_therm *therm = nvxx_therm(&drm->client.device); in nouveau_hwmon_temp1_auto_point1_temp() local 58 therm->attr_get(therm, NVKM_THERM_ATTR_THRS_FAN_BOOST) * 1000); in nouveau_hwmon_temp1_auto_point1_temp() 67 struct nvkm_therm *therm = nvxx_therm(&drm->client.device); in nouveau_hwmon_set_temp1_auto_point1_temp() local 73 therm->attr_set(therm, NVKM_THERM_ATTR_THRS_FAN_BOOST, in nouveau_hwmon_set_temp1_auto_point1_temp() 88 struct nvkm_therm *therm = nvxx_therm(&drm->client.device); in nouveau_hwmon_temp1_auto_point1_temp_hyst() local 91 therm->attr_get(therm, NVKM_THERM_ATTR_THRS_FAN_BOOST_HYST) * 1000); in nouveau_hwmon_temp1_auto_point1_temp_hyst() 100 struct nvkm_therm *therm = nvxx_therm(&drm->client.device); in nouveau_hwmon_set_temp1_auto_point1_temp_hyst() local 106 therm->attr_set(therm, NVKM_THERM_ATTR_THRS_FAN_BOOST_HYST, in nouveau_hwmon_set_temp1_auto_point1_temp_hyst() 121 struct nvkm_therm *therm = nvxx_therm(&drm->client.device); in nouveau_hwmon_get_pwm1_max() local 124 ret = therm->attr_get(therm, NVKM_THERM_ATTR_FAN_MAX_DUTY); in nouveau_hwmon_get_pwm1_max() [all …]
|
/linux-6.1.9/drivers/char/ |
D | ds1620.c | 200 static void ds1620_write_state(struct therm *therm) in ds1620_write_state() argument 203 ds1620_out(THERM_WRITE_TL, 9, therm->lo); in ds1620_write_state() 204 ds1620_out(THERM_WRITE_TH, 9, therm->hi); in ds1620_write_state() 208 static void ds1620_read_state(struct therm *therm) in ds1620_read_state() argument 210 therm->lo = cvt_9_to_int(ds1620_in(THERM_READ_TL, 9)); in ds1620_read_state() 211 therm->hi = cvt_9_to_int(ds1620_in(THERM_READ_TH, 9)); in ds1620_read_state() 239 struct therm therm; in ds1620_ioctl() local 241 struct therm __user *therm; in ds1620_ioctl() member 255 if (get_user(therm.hi, uarg.i)) in ds1620_ioctl() 257 therm.lo = therm.hi - 3; in ds1620_ioctl() [all …]
|
/linux-6.1.9/drivers/gpu/drm/nouveau/nvkm/subdev/bios/ |
D | therm.c | 32 u32 therm = 0; in therm_table() local 36 therm = nvbios_rd32(bios, bit_P.offset + 12); in therm_table() 38 therm = nvbios_rd32(bios, bit_P.offset + 16); in therm_table() 46 if (!therm) in therm_table() 49 *ver = nvbios_rd08(bios, therm + 0); in therm_table() 50 *hdr = nvbios_rd08(bios, therm + 1); in therm_table() 51 *len = nvbios_rd08(bios, therm + 2); in therm_table() 52 *cnt = nvbios_rd08(bios, therm + 3); in therm_table() 53 return therm + nvbios_rd08(bios, therm + 1); in therm_table() 60 u32 therm = therm_table(bios, ver, &hdr, len, &cnt); in nvbios_therm_entry() local [all …]
|
/linux-6.1.9/drivers/gpu/drm/nouveau/nvkm/subdev/bus/ |
D | nv31.c | 57 struct nvkm_therm *therm = device->therm; in nv31_bus_intr() local 58 if (therm) in nv31_bus_intr() 59 nvkm_subdev_intr(&therm->subdev); in nv31_bus_intr()
|
D | nv50.c | 72 struct nvkm_therm *therm = device->therm; in nv50_bus_intr() local 73 if (therm) in nv50_bus_intr() 74 nvkm_subdev_intr(&therm->subdev); in nv50_bus_intr()
|
/linux-6.1.9/drivers/gpu/drm/nouveau/nvkm/engine/device/ |
D | base.c | 485 .therm = { 0x00000001, nv40_therm_new }, 511 .therm = { 0x00000001, nv40_therm_new }, 537 .therm = { 0x00000001, nv40_therm_new }, 563 .therm = { 0x00000001, nv40_therm_new }, 589 .therm = { 0x00000001, nv40_therm_new }, 615 .therm = { 0x00000001, nv40_therm_new }, 641 .therm = { 0x00000001, nv40_therm_new }, 667 .therm = { 0x00000001, nv40_therm_new }, 693 .therm = { 0x00000001, nv40_therm_new }, 719 .therm = { 0x00000001, nv40_therm_new }, [all …]
|
/linux-6.1.9/Documentation/devicetree/bindings/thermal/ |
D | qcom-spmi-adc-tm5.yaml | 180 conn-therm@4f { 195 conn-therm@0 { 219 xo-therm@44 { 225 conn-therm@47 { 240 pmk8350-xo-therm@0 { 248 conn-therm@1 {
|
/linux-6.1.9/drivers/hwmon/ |
D | stts751.c | 92 int therm; member 430 return sysfs_emit(buf, "%d\n", priv->therm); in therm_show() 456 priv->hyst = temp - (priv->therm - priv->hyst); in therm_store() 457 priv->therm = temp; in therm_store() 488 temp = clamp_val(temp, -64000, priv->therm); in hyst_store() 491 temp = priv->therm - temp; in hyst_store() 729 ret = stts751_read_reg8(priv, &priv->therm, STTS751_REG_TLIM); in stts751_read_chip_config() 736 priv->hyst = priv->therm - tmp; in stts751_read_chip_config() 746 static SENSOR_DEVICE_ATTR_RW(temp1_crit, therm, 0);
|