summaryrefslogtreecommitdiff
path: root/drivers/power/supply
diff options
context:
space:
mode:
authorThomas Weißschuh <linux@weissschuh.net>2024-10-05 12:04:18 +0200
committerSebastian Reichel <sebastian.reichel@collabora.com>2024-10-15 22:14:11 +0200
commit40d00fa5a8be87812a7acb6524eb3d8fd3ea42b9 (patch)
tree963e145a51f02545c96edf093500a021d254c69d /drivers/power/supply
parent58797abed49d6b78c7af99b03b037f20c7ffb203 (diff)
power: supply: ab8500: constify resistance table
The power supply core now allows this constification. Prevent accidental or malicious modification of the data. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20241005-power-supply-battery-const-v1-2-c1f721927048@weissschuh.net Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Diffstat (limited to 'drivers/power/supply')
-rw-r--r--drivers/power/supply/ab8500_bmdata.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/power/supply/ab8500_bmdata.c b/drivers/power/supply/ab8500_bmdata.c
index 3e6ea22372b2..2fcfbbef0503 100644
--- a/drivers/power/supply/ab8500_bmdata.c
+++ b/drivers/power/supply/ab8500_bmdata.c
@@ -48,7 +48,7 @@ static struct power_supply_battery_ocv_table ocv_cap_tbl[] = {
* temperature values to work. Factory resistance is 300 mOhm and the
* resistance values to the right are percentages of 300 mOhm.
*/
-static struct power_supply_resistance_temp_table temp_to_batres_tbl_thermistor[] = {
+static const struct power_supply_resistance_temp_table temp_to_batres_tbl_thermistor[] = {
{ .temp = 40, .resistance = 40 /* 120 mOhm */ },
{ .temp = 30, .resistance = 45 /* 135 mOhm */ },
{ .temp = 20, .resistance = 55 /* 165 mOhm */ },