diff options
author | Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> | 2022-09-09 20:28:38 +0200 |
---|---|---|
committer | Daniel Lezcano <daniel.lezcano@linaro.org> | 2022-10-04 11:21:18 +0200 |
commit | c7114365e3b7566cba86902123538c7d9bb62b7a (patch) | |
tree | f4fe829d9ea18bbe8b4fa806bf0779be33ffa302 /drivers/thermal | |
parent | thermal/drivers/qcom: Drop false build dependency of all QCOM drivers on QCOM... (diff) | |
download | linux-c7114365e3b7566cba86902123538c7d9bb62b7a.tar.xz linux-c7114365e3b7566cba86902123538c7d9bb62b7a.zip |
thermal/drivers/rcar_thermal: Constify static thermal_zone_device_ops
The only usage of rcar_thermal_zone_of_ops is to pass its address to
devm_thermal_of_zone_register(), which takes a pointer to const struct
thermal_zone_device_ops. Make it const to allow the compiler to put
it in read-only memory.
Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Link: https://lore.kernel.org/r/20220909182838.11154-1-prabhakar.mahadev-lad.rj@bp.renesas.com
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Diffstat (limited to 'drivers/thermal')
-rw-r--r-- | drivers/thermal/rcar_thermal.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/thermal/rcar_thermal.c b/drivers/thermal/rcar_thermal.c index 4df42d70d867..61c2b8855cb8 100644 --- a/drivers/thermal/rcar_thermal.c +++ b/drivers/thermal/rcar_thermal.c @@ -316,7 +316,7 @@ static int rcar_thermal_get_trip_temp(struct thermal_zone_device *zone, return 0; } -static struct thermal_zone_device_ops rcar_thermal_zone_of_ops = { +static const struct thermal_zone_device_ops rcar_thermal_zone_of_ops = { .get_temp = rcar_thermal_get_temp, }; |