Home
last modified time | relevance | path

Searched refs:tzd (Results 1 – 16 of 16) sorted by relevance

/linux/drivers/thermal/
H A Dloongson2_thermal.c98 struct thermal_zone_device *tzd = dev; in loongson2_thermal_irq_thread() local
99 struct loongson2_thermal_data *data = thermal_zone_device_priv(tzd); in loongson2_thermal_irq_thread()
103 thermal_zone_device_update(tzd, THERMAL_EVENT_UNSPECIFIED); in loongson2_thermal_irq_thread()
130 struct thermal_zone_device *tzd; in loongson2_thermal_probe() local
163 tzd = devm_thermal_of_zone_register(dev, i, data, thermal_ops); in loongson2_thermal_probe()
165 if (!IS_ERR(tzd)) in loongson2_thermal_probe()
168 if (PTR_ERR(tzd) != -ENODEV) in loongson2_thermal_probe()
171 return dev_err_probe(dev, PTR_ERR(tzd), "failed to register"); in loongson2_thermal_probe()
175 IRQF_ONESHOT, "loongson2_thermal", tzd); in loongson2_thermal_probe()
179 devm_thermal_add_hwmon_sysfs(dev, tzd); in loongson2_thermal_probe()
H A Dimx_sc_thermal.c22 struct thermal_zone_device *tzd; member
94 sensor->tzd = devm_thermal_of_zone_register(&pdev->dev, sensor->resource_id, in imx_sc_thermal_probe()
96 if (IS_ERR(sensor->tzd)) { in imx_sc_thermal_probe()
102 ret = PTR_ERR(sensor->tzd); in imx_sc_thermal_probe()
117 devm_thermal_add_hwmon_sysfs(&pdev->dev, sensor->tzd); in imx_sc_thermal_probe()
H A Damlogic_thermal.c101 struct thermal_zone_device *tzd; member
281 pdata->tzd = devm_thermal_of_zone_register(&pdev->dev, in amlogic_thermal_probe()
285 if (IS_ERR(pdata->tzd)) { in amlogic_thermal_probe()
286 ret = PTR_ERR(pdata->tzd); in amlogic_thermal_probe()
291 devm_thermal_add_hwmon_sysfs(&pdev->dev, pdata->tzd); in amlogic_thermal_probe()
H A Dthermal_of.c474 struct thermal_zone_device **ptr, *tzd; in devm_thermal_of_zone_register() local
481 tzd = thermal_of_zone_register(dev->of_node, sensor_id, data, ops); in devm_thermal_of_zone_register()
482 if (IS_ERR(tzd)) { in devm_thermal_of_zone_register()
484 return tzd; in devm_thermal_of_zone_register()
487 *ptr = tzd; in devm_thermal_of_zone_register()
490 return tzd; in devm_thermal_of_zone_register()
H A Dthermal_core.c1664 void *thermal_zone_device_priv(struct thermal_zone_device *tzd) in thermal_zone_device_priv() argument
1666 return tzd->devdata; in thermal_zone_device_priv()
1670 const char *thermal_zone_device_type(struct thermal_zone_device *tzd) in thermal_zone_device_type() argument
1672 return tzd->type; in thermal_zone_device_type()
1676 int thermal_zone_device_id(struct thermal_zone_device *tzd) in thermal_zone_device_id() argument
1678 return tzd->id; in thermal_zone_device_id()
1682 struct device *thermal_zone_device(struct thermal_zone_device *tzd) in thermal_zone_device() argument
1684 return &tzd->device; in thermal_zone_device()
/linux/drivers/thermal/tegra/
H A Dtegra30-tsensor.c77 struct thermal_zone_device *tzd; member
263 thermal_zone_device_update(tsc->tzd, THERMAL_EVENT_UNSPECIFIED); in tegra_tsensor_handle_channel_interrupt()
284 struct thermal_zone_device *tzd = tsc->tzd; in tegra_tsensor_disable_hw_channel() local
288 if (!tzd) in tegra_tsensor_disable_hw_channel()
291 err = thermal_zone_device_disable(tzd); in tegra_tsensor_disable_hw_channel()
323 static void tegra_tsensor_get_hw_channel_trips(struct thermal_zone_device *tzd, in tegra_tsensor_get_hw_channel_trips() argument
333 thermal_zone_for_each_trip(tzd, tegra_tsensor_get_trips_cb, temps); in tegra_tsensor_get_hw_channel_trips()
352 struct thermal_zone_device *tzd = tsc->tzd; in tegra_tsensor_enable_hw_channel() local
357 if (!tzd) { in tegra_tsensor_enable_hw_channel()
365 tegra_tsensor_get_hw_channel_trips(tzd, &temps); in tegra_tsensor_enable_hw_channel()
[all …]
/linux/drivers/thermal/intel/
H A Dintel_quark_dts_thermal.c115 static int soc_dts_enable(struct thermal_zone_device *tzd) in soc_dts_enable() argument
118 struct soc_sensor_entry *aux_entry = thermal_zone_device_priv(tzd); in soc_dts_enable()
143 static int soc_dts_disable(struct thermal_zone_device *tzd) in soc_dts_disable() argument
146 struct soc_sensor_entry *aux_entry = thermal_zone_device_priv(tzd); in soc_dts_disable()
245 static inline int sys_set_trip_temp(struct thermal_zone_device *tzd, in sys_set_trip_temp() argument
264 return update_trip_temp(thermal_zone_device_priv(tzd), trip_index, temp); in sys_set_trip_temp()
267 static int sys_get_curr_temp(struct thermal_zone_device *tzd, in sys_get_curr_temp() argument
292 static int sys_change_mode(struct thermal_zone_device *tzd, in sys_change_mode() argument
299 ret = soc_dts_enable(tzd); in sys_change_mode()
301 ret = soc_dts_disable(tzd); in sys_change_mode()
H A Dintel_bxt_pmic_thermal.c156 struct thermal_zone_device *tzd; in pmic_thermal_irq_handler() local
195 tzd = thermal_zone_get_zone_by_name(td->maps[i].handle); in pmic_thermal_irq_handler()
196 if (!IS_ERR(tzd)) in pmic_thermal_irq_handler()
197 thermal_zone_device_update(tzd, in pmic_thermal_irq_handler()
H A Dintel_soc_dts_iosf.c132 static int sys_set_trip_temp(struct thermal_zone_device *tzd, in sys_set_trip_temp() argument
136 struct intel_soc_dts_sensor_entry *dts = thermal_zone_device_priv(tzd); in sys_set_trip_temp()
151 static int sys_get_curr_temp(struct thermal_zone_device *tzd, in sys_get_curr_temp() argument
156 struct intel_soc_dts_sensor_entry *dts = thermal_zone_device_priv(tzd); in sys_get_curr_temp()
H A Dx86_pkg_temp_thermal.c108 static int sys_get_curr_temp(struct thermal_zone_device *tzd, int *temp) in sys_get_curr_temp() argument
110 struct zone_device *zonedev = thermal_zone_device_priv(tzd); in sys_get_curr_temp()
123 sys_set_trip_temp(struct thermal_zone_device *tzd, in sys_set_trip_temp() argument
126 struct zone_device *zonedev = thermal_zone_device_priv(tzd); in sys_set_trip_temp()
/linux/drivers/hwmon/
H A Dhwmon.c70 struct thermal_zone_device *tzd;/* thermal zone device */ member
233 struct thermal_zone_device *tzd; in hwmon_thermal_add_sensor() local
243 tzd = devm_thermal_of_zone_register(dev, index, tdata, in hwmon_thermal_add_sensor()
245 if (IS_ERR(tzd)) { in hwmon_thermal_add_sensor()
246 if (PTR_ERR(tzd) != -ENODEV) in hwmon_thermal_add_sensor()
247 return PTR_ERR(tzd); in hwmon_thermal_add_sensor()
258 tdata->tzd = tzd; in hwmon_thermal_add_sensor()
308 thermal_zone_device_update(tzdata->tzd, in hwmon_thermal_notify()
/linux/drivers/power/supply/
H A Dpower_supply_core.c1498 static int power_supply_read_temp(struct thermal_zone_device *tzd, in power_supply_read_temp() argument
1505 WARN_ON(tzd == NULL); in power_supply_read_temp()
1506 psy = thermal_zone_device_priv(tzd); in power_supply_read_temp()
1534 psy->tzd = thermal_tripless_zone_device_register(psy->desc->name, in psy_register_thermal()
1536 if (IS_ERR(psy->tzd)) in psy_register_thermal()
1537 return PTR_ERR(psy->tzd); in psy_register_thermal()
1538 ret = thermal_zone_device_enable(psy->tzd); in psy_register_thermal()
1540 thermal_zone_device_unregister(psy->tzd); in psy_register_thermal()
1549 if (IS_ERR_OR_NULL(psy->tzd)) in psy_unregister_thermal()
1551 thermal_zone_device_unregister(psy->tzd); in psy_unregister_thermal()
/linux/drivers/thermal/intel/int340x_thermal/
H A Dprocessor_thermal_device_pci.c217 static int sys_get_curr_temp(struct thermal_zone_device *tzd, int *temp) in sys_get_curr_temp() argument
219 struct proc_thermal_pci *pci_info = thermal_zone_device_priv(tzd); in sys_get_curr_temp()
228 static int sys_set_trip_temp(struct thermal_zone_device *tzd, in sys_set_trip_temp() argument
231 struct proc_thermal_pci *pci_info = thermal_zone_device_priv(tzd); in sys_set_trip_temp()
/linux/drivers/thermal/qcom/
H A Dtsens.c601 if (!s->tzd) in tsens_critical_irq_thread()
648 if (!s->tzd) in tsens_irq_thread()
653 thermal_zone_device_update(s->tzd, THERMAL_EVENT_UNSPECIFIED); in tsens_irq_thread()
1248 struct thermal_zone_device *tzd; in tsens_register() local
1252 tzd = devm_thermal_of_zone_register(priv->dev, priv->sensor[i].hw_id, in tsens_register()
1255 if (IS_ERR(tzd)) in tsens_register()
1257 priv->sensor[i].tzd = tzd; in tsens_register()
1261 devm_thermal_add_hwmon_sysfs(priv->dev, tzd); in tsens_register()
H A Dtsens.h59 struct thermal_zone_device *tzd; member
/linux/drivers/regulator/
H A Dmax8973-regulator.c472 struct thermal_zone_device *tzd; in max8973_thermal_init() local
479 tzd = devm_thermal_of_zone_register(mchip->dev, 0, mchip, in max8973_thermal_init()
481 if (IS_ERR(tzd)) { in max8973_thermal_init()
482 ret = PTR_ERR(tzd); in max8973_thermal_init()