diff options
author | Rikard Falkeborn <rikard.falkeborn@gmail.com> | 2020-09-22 21:26:52 +0200 |
---|---|---|
committer | Lee Jones <lee.jones@linaro.org> | 2020-11-19 08:34:21 +0000 |
commit | a0fa0abeb508360bea82a84ce83aea49769641d3 (patch) | |
tree | ba35f9cd055d9e3ca5de75decd26b4bb57ece7ea /drivers/mfd/da9150-core.c | |
parent | f8d86e2998e91d5a9f62b4934445d1ecadd00b30 (diff) | |
download | linux-stable-a0fa0abeb508360bea82a84ce83aea49769641d3.tar.gz linux-stable-a0fa0abeb508360bea82a84ce83aea49769641d3.tar.bz2 linux-stable-a0fa0abeb508360bea82a84ce83aea49769641d3.zip |
mfd: da9xxx-core: Constify static struct resource
Constify a number of static struct resource. The only usage of the
structs are to assign their address to the resources field in the
mfd_cell struct. This allows the compiler to put them in read-only
memory. Done with the help of Coccinelle.
Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com>
Acked-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'drivers/mfd/da9150-core.c')
-rw-r--r-- | drivers/mfd/da9150-core.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/mfd/da9150-core.c b/drivers/mfd/da9150-core.c index 7f0aa1e8db96..d8b0cde48589 100644 --- a/drivers/mfd/da9150-core.c +++ b/drivers/mfd/da9150-core.c @@ -350,18 +350,18 @@ static const struct regmap_irq_chip da9150_regmap_irq_chip = { .num_irqs = ARRAY_SIZE(da9150_irqs), }; -static struct resource da9150_gpadc_resources[] = { +static const struct resource da9150_gpadc_resources[] = { DEFINE_RES_IRQ_NAMED(DA9150_IRQ_GPADC, "GPADC"), }; -static struct resource da9150_charger_resources[] = { +static const struct resource da9150_charger_resources[] = { DEFINE_RES_IRQ_NAMED(DA9150_IRQ_CHG, "CHG_STATUS"), DEFINE_RES_IRQ_NAMED(DA9150_IRQ_TJUNC, "CHG_TJUNC"), DEFINE_RES_IRQ_NAMED(DA9150_IRQ_VFAULT, "CHG_VFAULT"), DEFINE_RES_IRQ_NAMED(DA9150_IRQ_VBUS, "CHG_VBUS"), }; -static struct resource da9150_fg_resources[] = { +static const struct resource da9150_fg_resources[] = { DEFINE_RES_IRQ_NAMED(DA9150_IRQ_FG, "FG"), }; |