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

regulator: tps65217: Constify regulator_ops

These regulator_ops variables never need to be modified, make them const so
compiler can put them to .rodata.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Axel Lin and committed by
Mark Brown
2c33b50e d1030b43

+2 -2
+2 -2
drivers/regulator/tps65217-regulator.c
··· 149 149 } 150 150 151 151 /* Operations permitted on DCDCx, LDO2, LDO3 and LDO4 */ 152 - static struct regulator_ops tps65217_pmic_ops = { 152 + static const struct regulator_ops tps65217_pmic_ops = { 153 153 .is_enabled = regulator_is_enabled_regmap, 154 154 .enable = tps65217_pmic_enable, 155 155 .disable = tps65217_pmic_disable, ··· 162 162 }; 163 163 164 164 /* Operations permitted on LDO1 */ 165 - static struct regulator_ops tps65217_pmic_ldo1_ops = { 165 + static const struct regulator_ops tps65217_pmic_ldo1_ops = { 166 166 .is_enabled = regulator_is_enabled_regmap, 167 167 .enable = tps65217_pmic_enable, 168 168 .disable = tps65217_pmic_disable,