From bf4cceb6e00915556cff80cfe70070e3dbbc14f1 Mon Sep 17 00:00:00 2001 From: Rikard Falkeborn Date: Tue, 22 Sep 2020 21:26:53 +0200 Subject: mfd: intel: 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 Reviewed-by: Andy Shevchenko Signed-off-by: Lee Jones --- drivers/mfd/intel_soc_pmic_chtdc_ti.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'drivers/mfd/intel_soc_pmic_chtdc_ti.c') diff --git a/drivers/mfd/intel_soc_pmic_chtdc_ti.c b/drivers/mfd/intel_soc_pmic_chtdc_ti.c index 64b5c3cc30e7..1c7577b881ff 100644 --- a/drivers/mfd/intel_soc_pmic_chtdc_ti.c +++ b/drivers/mfd/intel_soc_pmic_chtdc_ti.c @@ -32,23 +32,23 @@ enum { CHTDC_TI_CCEOCAL = 7, /* battery */ }; -static struct resource power_button_resources[] = { +static const struct resource power_button_resources[] = { DEFINE_RES_IRQ(CHTDC_TI_PWRBTN), }; -static struct resource thermal_resources[] = { +static const struct resource thermal_resources[] = { DEFINE_RES_IRQ(CHTDC_TI_DIETMPWARN), }; -static struct resource adc_resources[] = { +static const struct resource adc_resources[] = { DEFINE_RES_IRQ(CHTDC_TI_ADCCMPL), }; -static struct resource pwrsrc_resources[] = { +static const struct resource pwrsrc_resources[] = { DEFINE_RES_IRQ(CHTDC_TI_VBUSDET), }; -static struct resource battery_resources[] = { +static const struct resource battery_resources[] = { DEFINE_RES_IRQ(CHTDC_TI_VBATLOW), DEFINE_RES_IRQ(CHTDC_TI_CCEOCAL), }; -- cgit v1.2.1