linux-loongson/drivers/thermal/st
Christophe JAILLET 992e2ed0ab thermal: Constify struct thermal_zone_device_ops
'struct thermal_zone_device_ops' are not modified in these drivers.

Constifying these structures moves some data to a read-only section, so
increases overall security, especially when the structure holds some
function pointers.

On a x86_64, with allmodconfig, as an example:
Before:
======
   text	   data	    bss	    dec	    hex	filename
  28116	   5168	    128	  33412	   8284	drivers/thermal/armada_thermal.o

After:
=====
   text	   data	    bss	    dec	    hex	filename
  28244	   5040	    128	  33412	   8284	drivers/thermal/armada_thermal.o

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Reviewed-by: Frank Li <Frank.Li@nxp.com>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com> # For Armada
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Link: https://lore.kernel.org/r/5bba3bf0139e2418b306a0f9a2f1f81ef49e88a6.1748165978.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
2025-07-15 15:26:04 +02:00
..
Kconfig thermal/drivers/st: Remove syscfg based driver 2023-02-15 17:30:04 +01:00
Makefile thermal/drivers/st: Remove syscfg based driver 2023-02-15 17:30:04 +01:00
st_thermal_memmap.c thermal: Switch back to struct platform_driver::remove() 2024-11-13 16:17:57 +01:00
st_thermal.c thermal: Constify struct thermal_zone_device_ops 2025-07-15 15:26:04 +02:00
st_thermal.h thermal: Drop spaces before TABs 2024-03-11 17:14:46 +01:00
stm_thermal.c thermal: Switch back to struct platform_driver::remove() 2024-11-13 16:17:57 +01:00