tsens.c (5f68d0785e5258ab5e6df9e351929973a0742c1a) tsens.c (4a16c190f761cb3a87dcbbf355f91c71ce1f8c0b)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Copyright (c) 2015, The Linux Foundation. All rights reserved.
4 * Copyright (c) 2019, 2020, Linaro Ltd.
5 */
6
7#include <linux/debugfs.h>
8#include <linux/err.h>

--- 1175 unchanged lines hidden (view full) ---

1184 &priv->sensor[i],
1185 &tsens_of_ops);
1186 if (IS_ERR(tzd))
1187 continue;
1188 priv->sensor[i].tzd = tzd;
1189 if (priv->ops->enable)
1190 priv->ops->enable(priv, i);
1191
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Copyright (c) 2015, The Linux Foundation. All rights reserved.
4 * Copyright (c) 2019, 2020, Linaro Ltd.
5 */
6
7#include <linux/debugfs.h>
8#include <linux/err.h>

--- 1175 unchanged lines hidden (view full) ---

1184 &priv->sensor[i],
1185 &tsens_of_ops);
1186 if (IS_ERR(tzd))
1187 continue;
1188 priv->sensor[i].tzd = tzd;
1189 if (priv->ops->enable)
1190 priv->ops->enable(priv, i);
1191
1192 if (devm_thermal_add_hwmon_sysfs(tzd))
1192 if (devm_thermal_add_hwmon_sysfs(priv->dev, tzd))
1193 dev_warn(priv->dev,
1194 "Failed to add hwmon sysfs attributes\n");
1195 }
1196
1197 /* VER_0 require to set MIN and MAX THRESH
1198 * These 2 regs are set using the:
1199 * - CRIT_THRESH_0 for MAX THRESH hardcoded to 120°C
1200 * - CRIT_THRESH_1 for MIN THRESH hardcoded to 0°C

--- 129 unchanged lines hidden ---
1193 dev_warn(priv->dev,
1194 "Failed to add hwmon sysfs attributes\n");
1195 }
1196
1197 /* VER_0 require to set MIN and MAX THRESH
1198 * These 2 regs are set using the:
1199 * - CRIT_THRESH_0 for MAX THRESH hardcoded to 120°C
1200 * - CRIT_THRESH_1 for MIN THRESH hardcoded to 0°C

--- 129 unchanged lines hidden ---