summaryrefslogtreecommitdiff
path: root/drivers/thermal/k3_bandgap.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/thermal/k3_bandgap.c')
-rw-r--r--drivers/thermal/k3_bandgap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/thermal/k3_bandgap.c b/drivers/thermal/k3_bandgap.c
index 22c9bcb899c3..791210458606 100644
--- a/drivers/thermal/k3_bandgap.c
+++ b/drivers/thermal/k3_bandgap.c
@@ -141,7 +141,7 @@ static int k3_bgp_read_temp(struct k3_thermal_data *devdata,
static int k3_thermal_get_temp(struct thermal_zone_device *tz, int *temp)
{
- struct k3_thermal_data *data = tz->devdata;
+ struct k3_thermal_data *data = thermal_zone_device_priv(tz);
int ret = 0;
ret = k3_bgp_read_temp(data, temp);
@@ -222,7 +222,7 @@ static int k3_bandgap_probe(struct platform_device *pdev)
goto err_alloc;
}
- if (devm_thermal_add_hwmon_sysfs(data[id].tzd))
+ if (devm_thermal_add_hwmon_sysfs(dev, data[id].tzd))
dev_warn(dev, "Failed to add hwmon sysfs attributes\n");
}