Skip to content

Commit

Permalink
regulator: fan53555: Constify struct regmap_config and slew_rates array
Browse files Browse the repository at this point in the history
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const. Make const also
slew_rates array.

Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Krzysztof Kozlowski authored and Mark Brown committed Jan 5, 2015
1 parent 97bf6af commit 121b567
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/regulator/fan53555.c
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ static unsigned int fan53555_get_mode(struct regulator_dev *rdev)
return REGULATOR_MODE_NORMAL;
}

static int slew_rates[] = {
static const int slew_rates[] = {
64000,
32000,
16000,
Expand Down Expand Up @@ -296,7 +296,7 @@ static int fan53555_regulator_register(struct fan53555_device_info *di,
return PTR_ERR_OR_ZERO(di->rdev);
}

static struct regmap_config fan53555_regmap_config = {
static const struct regmap_config fan53555_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
};
Expand Down

0 comments on commit 121b567

Please sign in to comment.