Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

regulator: tps65023: Constify static data

Driver does not modify static data with regulator description (struct
tps_driver_data), so make it const for code safety.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://patch.msgid.link/20240909-regulator-const-v1-8-8934704a5787@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Krzysztof Kozlowski and committed by
Mark Brown
7fb636dc 5ec424af

+3 -3
+3 -3
drivers/regulator/tps65023-regulator.c
··· 242 242 TPS65023_REGULATOR_LDO(2, TPS65023_LDO2_VSEL_table, 0x70), 243 243 }; 244 244 245 - static struct tps_driver_data tps65020_drv_data = { 245 + static const struct tps_driver_data tps65020_drv_data = { 246 246 .desc = tps65020_regulators, 247 247 .core_regulator = TPS65023_DCDC_3, 248 248 }; 249 249 250 - static struct tps_driver_data tps65021_drv_data = { 250 + static const struct tps_driver_data tps65021_drv_data = { 251 251 .desc = tps65021_regulators, 252 252 .core_regulator = TPS65023_DCDC_3, 253 253 }; 254 254 255 - static struct tps_driver_data tps65023_drv_data = { 255 + static const struct tps_driver_data tps65023_drv_data = { 256 256 .desc = tps65023_regulators, 257 257 .core_regulator = TPS65023_DCDC_1, 258 258 };