diff options
author | Julia Lawall <Julia.Lawall@lip6.fr> | 2015-12-19 16:31:24 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2015-12-23 01:00:00 +0100 |
commit | b0d6dd3ba3c3f41bface6623a18d08439cb195bb (patch) | |
tree | e6a9d0b8c4129f4d9184d2010c13abbed3b45ff3 /drivers/regulator/wm8350-regulator.c | |
parent | regulator: da9*: constify regulator_ops structures (diff) | |
download | linux-b0d6dd3ba3c3f41bface6623a18d08439cb195bb.tar.xz linux-b0d6dd3ba3c3f41bface6623a18d08439cb195bb.zip |
regulator: wm8*: constify regulator_ops structures
The regulator_ops structures are never modified, so declare them as const.
Done with the help of Coccinelle.
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/regulator/wm8350-regulator.c')
-rw-r--r-- | drivers/regulator/wm8350-regulator.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/regulator/wm8350-regulator.c b/drivers/regulator/wm8350-regulator.c index 95f6b040186e..da9106bd2109 100644 --- a/drivers/regulator/wm8350-regulator.c +++ b/drivers/regulator/wm8350-regulator.c @@ -941,7 +941,7 @@ static unsigned int wm8350_dcdc_get_optimum_mode(struct regulator_dev *rdev, return mode; } -static struct regulator_ops wm8350_dcdc_ops = { +static const struct regulator_ops wm8350_dcdc_ops = { .set_voltage_sel = regulator_set_voltage_sel_regmap, .get_voltage_sel = regulator_get_voltage_sel_regmap, .list_voltage = regulator_list_voltage_linear, @@ -958,7 +958,7 @@ static struct regulator_ops wm8350_dcdc_ops = { .set_suspend_mode = wm8350_dcdc_set_suspend_mode, }; -static struct regulator_ops wm8350_dcdc2_5_ops = { +static const struct regulator_ops wm8350_dcdc2_5_ops = { .enable = regulator_enable_regmap, .disable = regulator_disable_regmap, .is_enabled = regulator_is_enabled_regmap, @@ -966,7 +966,7 @@ static struct regulator_ops wm8350_dcdc2_5_ops = { .set_suspend_disable = wm8350_dcdc25_set_suspend_disable, }; -static struct regulator_ops wm8350_ldo_ops = { +static const struct regulator_ops wm8350_ldo_ops = { .map_voltage = regulator_map_voltage_linear_range, .set_voltage_sel = regulator_set_voltage_sel_regmap, .get_voltage_sel = regulator_get_voltage_sel_regmap, @@ -980,7 +980,7 @@ static struct regulator_ops wm8350_ldo_ops = { .set_suspend_disable = wm8350_ldo_set_suspend_disable, }; -static struct regulator_ops wm8350_isink_ops = { +static const struct regulator_ops wm8350_isink_ops = { .set_current_limit = wm8350_isink_set_current, .get_current_limit = wm8350_isink_get_current, .enable = wm8350_isink_enable, |