From: Rikard Falkeborn Date: Mon, 9 Nov 2020 22:10:12 +0000 (+0100) Subject: pinctrl: renesas: Constify sh73a0_vccq_mc0_ops X-Git-Tag: accepted/tizen/unified/20230118.172025~8249^2~17^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d4aac7d439c2d9307cb5137fc285464a36978107;p=platform%2Fkernel%2Flinux-rpi.git pinctrl: renesas: Constify sh73a0_vccq_mc0_ops The only usage of sh73a0_vccq_mc0_ops is to assign its address to the ops field in the regulator_desc struct, which is a const pointer. Make it const to allow the compiler to put it in read-only memory. Signed-off-by: Rikard Falkeborn Link: https://lore.kernel.org/r/20201109221012.177478-1-rikard.falkeborn@gmail.com Signed-off-by: Geert Uytterhoeven --- diff --git a/drivers/pinctrl/renesas/pfc-sh73a0.c b/drivers/pinctrl/renesas/pfc-sh73a0.c index afabd95..96b91e9 100644 --- a/drivers/pinctrl/renesas/pfc-sh73a0.c +++ b/drivers/pinctrl/renesas/pfc-sh73a0.c @@ -4279,7 +4279,7 @@ static int sh73a0_vccq_mc0_get_voltage(struct regulator_dev *reg) return 3300000; } -static struct regulator_ops sh73a0_vccq_mc0_ops = { +static const struct regulator_ops sh73a0_vccq_mc0_ops = { .enable = sh73a0_vccq_mc0_enable, .disable = sh73a0_vccq_mc0_disable, .is_enabled = sh73a0_vccq_mc0_is_enabled,