regulator: ab8500-ext: Constify ab8500_ext_regulator_ops
authorAxel Lin <axel.lin@ingics.com>
Fri, 12 Apr 2019 14:06:56 +0000 (22:06 +0800)
committerMark Brown <broonie@kernel.org>
Mon, 15 Apr 2019 08:43:31 +0000 (09:43 +0100)
ab8500_ext_regulator_ops never need to be modified, make it const so
compiler can put it to .rodata.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/ab8500-ext.c

index f232a7a90fd55a778107e252aacb97094638b94b..95704446d89e8703b8bf8a6ba8fd38b4072b0049 100644 (file)
@@ -718,7 +718,7 @@ static int ab8500_ext_list_voltage(struct regulator_dev *rdev,
        return -EINVAL;
 }
 
-static struct regulator_ops ab8500_ext_regulator_ops = {
+static const struct regulator_ops ab8500_ext_regulator_ops = {
        .enable                 = ab8500_ext_regulator_enable,
        .disable                = ab8500_ext_regulator_disable,
        .is_enabled             = ab8500_ext_regulator_is_enabled,