* [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config
@ 2015-01-05 9:01 Krzysztof Kozlowski
2015-01-05 9:01 ` [PATCH 02/14] mfd: hi6421-pmic: " Krzysztof Kozlowski
` (13 more replies)
0 siblings, 14 replies; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/88pm860x-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/88pm860x-core.c b/drivers/mfd/88pm860x-core.c
index 3a2604580164..d2a85cde68da 100644
--- a/drivers/mfd/88pm860x-core.c
+++ b/drivers/mfd/88pm860x-core.c
@@ -1111,7 +1111,7 @@ static int verify_addr(struct i2c_client *i2c)
return 0;
}
-static struct regmap_config pm860x_regmap_config = {
+static const struct regmap_config pm860x_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
};
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 02/14] mfd: hi6421-pmic: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:56 ` Lee Jones
2015-01-05 9:01 ` [PATCH 03/14] mfd: intel_soc_pmic: " Krzysztof Kozlowski
` (12 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/hi6421-pmic-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/hi6421-pmic-core.c b/drivers/mfd/hi6421-pmic-core.c
index 321a2656fd00..7210ae28bf81 100644
--- a/drivers/mfd/hi6421-pmic-core.c
+++ b/drivers/mfd/hi6421-pmic-core.c
@@ -35,7 +35,7 @@ static const struct mfd_cell hi6421_devs[] = {
{ .name = "hi6421-regulator", },
};
-static struct regmap_config hi6421_regmap_config = {
+static const struct regmap_config hi6421_regmap_config = {
.reg_bits = 32,
.reg_stride = 4,
.val_bits = 8,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 03/14] mfd: intel_soc_pmic: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
2015-01-05 9:01 ` [PATCH 02/14] mfd: hi6421-pmic: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:56 ` Lee Jones
2015-01-05 9:01 ` [PATCH 04/14] mfd: davinci_voicecodec: " Krzysztof Kozlowski
` (11 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/intel_soc_pmic_core.h | 2 +-
drivers/mfd/intel_soc_pmic_crc.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mfd/intel_soc_pmic_core.h b/drivers/mfd/intel_soc_pmic_core.h
index 33aacd9baddc..9498d6719847 100644
--- a/drivers/mfd/intel_soc_pmic_core.h
+++ b/drivers/mfd/intel_soc_pmic_core.h
@@ -23,7 +23,7 @@ struct intel_soc_pmic_config {
unsigned long irq_flags;
struct mfd_cell *cell_dev;
int n_cell_devs;
- struct regmap_config *regmap_config;
+ const struct regmap_config *regmap_config;
struct regmap_irq_chip *irq_chip;
};
diff --git a/drivers/mfd/intel_soc_pmic_crc.c b/drivers/mfd/intel_soc_pmic_crc.c
index c85e2ecb868a..4cc1b324e971 100644
--- a/drivers/mfd/intel_soc_pmic_crc.c
+++ b/drivers/mfd/intel_soc_pmic_crc.c
@@ -111,7 +111,7 @@ static struct mfd_cell crystal_cove_dev[] = {
},
};
-static struct regmap_config crystal_cove_regmap_config = {
+static const struct regmap_config crystal_cove_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 04/14] mfd: davinci_voicecodec: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
2015-01-05 9:01 ` [PATCH 02/14] mfd: hi6421-pmic: " Krzysztof Kozlowski
2015-01-05 9:01 ` [PATCH 03/14] mfd: intel_soc_pmic: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:56 ` Lee Jones
2015-01-05 9:01 ` [PATCH 05/14] mfd: lm3533: " Krzysztof Kozlowski
` (10 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/davinci_voicecodec.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/davinci_voicecodec.c b/drivers/mfd/davinci_voicecodec.c
index c835e85539b2..9bbc642a7b9d 100644
--- a/drivers/mfd/davinci_voicecodec.c
+++ b/drivers/mfd/davinci_voicecodec.c
@@ -33,7 +33,7 @@
#include <linux/mfd/davinci_voicecodec.h>
-static struct regmap_config davinci_vc_regmap = {
+static const struct regmap_config davinci_vc_regmap = {
.reg_bits = 32,
.val_bits = 32,
};
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 05/14] mfd: lm3533: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (2 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 04/14] mfd: davinci_voicecodec: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:57 ` Lee Jones
2015-01-05 9:01 ` [PATCH 06/14] mfd: max77686: " Krzysztof Kozlowski
` (9 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/lm3533-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/lm3533-core.c b/drivers/mfd/lm3533-core.c
index 8c29f7b27324..d42fbb667d8c 100644
--- a/drivers/mfd/lm3533-core.c
+++ b/drivers/mfd/lm3533-core.c
@@ -583,7 +583,7 @@ static bool lm3533_precious_register(struct device *dev, unsigned int reg)
}
}
-static struct regmap_config regmap_config = {
+static const struct regmap_config regmap_config = {
.reg_bits = 8,
.val_bits = 8,
.max_register = LM3533_REG_MAX,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 06/14] mfd: max77686: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (3 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 05/14] mfd: lm3533: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:57 ` Lee Jones
2015-01-05 9:01 ` [PATCH 07/14] mfd: mc13xxx: i2c/spi: " Krzysztof Kozlowski
` (8 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/max77686.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mfd/max77686.c b/drivers/mfd/max77686.c
index 929795eae9fc..2b2f2ccda523 100644
--- a/drivers/mfd/max77686.c
+++ b/drivers/mfd/max77686.c
@@ -111,17 +111,17 @@ static bool max77802_is_volatile_reg(struct device *dev, unsigned int reg)
max77802_rtc_is_volatile_reg(dev, reg));
}
-static struct regmap_config max77686_regmap_config = {
+static const struct regmap_config max77686_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
};
-static struct regmap_config max77686_rtc_regmap_config = {
+static const struct regmap_config max77686_rtc_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
};
-static struct regmap_config max77802_regmap_config = {
+static const struct regmap_config max77802_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
.writeable_reg = max77802_is_accessible_reg,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 07/14] mfd: mc13xxx: i2c/spi: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (4 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 06/14] mfd: max77686: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:58 ` Lee Jones
2015-01-05 9:01 ` [PATCH 08/14] mfd: pcf50633: " Krzysztof Kozlowski
` (7 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/mc13xxx-i2c.c | 2 +-
drivers/mfd/mc13xxx-spi.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mfd/mc13xxx-i2c.c b/drivers/mfd/mc13xxx-i2c.c
index ae3addb153a2..68b844811566 100644
--- a/drivers/mfd/mc13xxx-i2c.c
+++ b/drivers/mfd/mc13xxx-i2c.c
@@ -46,7 +46,7 @@ static const struct of_device_id mc13xxx_dt_ids[] = {
};
MODULE_DEVICE_TABLE(of, mc13xxx_dt_ids);
-static struct regmap_config mc13xxx_regmap_i2c_config = {
+static const struct regmap_config mc13xxx_regmap_i2c_config = {
.reg_bits = 8,
.val_bits = 24,
diff --git a/drivers/mfd/mc13xxx-spi.c b/drivers/mfd/mc13xxx-spi.c
index 702925e242c9..58a170e45d88 100644
--- a/drivers/mfd/mc13xxx-spi.c
+++ b/drivers/mfd/mc13xxx-spi.c
@@ -48,7 +48,7 @@ static const struct of_device_id mc13xxx_dt_ids[] = {
};
MODULE_DEVICE_TABLE(of, mc13xxx_dt_ids);
-static struct regmap_config mc13xxx_regmap_spi_config = {
+static const struct regmap_config mc13xxx_regmap_spi_config = {
.reg_bits = 7,
.pad_bits = 1,
.val_bits = 24,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 08/14] mfd: pcf50633: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (5 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 07/14] mfd: mc13xxx: i2c/spi: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:58 ` Lee Jones
2015-01-05 9:01 ` [PATCH 09/14] mfd: retu: " Krzysztof Kozlowski
` (6 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/pcf50633-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/pcf50633-core.c b/drivers/mfd/pcf50633-core.c
index 43664eb69c93..6155d123a84e 100644
--- a/drivers/mfd/pcf50633-core.c
+++ b/drivers/mfd/pcf50633-core.c
@@ -183,7 +183,7 @@ static int pcf50633_resume(struct device *dev)
static SIMPLE_DEV_PM_OPS(pcf50633_pm, pcf50633_suspend, pcf50633_resume);
-static struct regmap_config pcf50633_regmap_config = {
+static const struct regmap_config pcf50633_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
};
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 09/14] mfd: retu: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (6 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 08/14] mfd: pcf50633: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:58 ` Lee Jones
2015-01-05 9:01 ` [PATCH 10/14] mfd: smsc-ece1099: " Krzysztof Kozlowski
` (5 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/retu-mfd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/retu-mfd.c b/drivers/mfd/retu-mfd.c
index 663f8a37aa6b..2d64430c719b 100644
--- a/drivers/mfd/retu-mfd.c
+++ b/drivers/mfd/retu-mfd.c
@@ -222,7 +222,7 @@ static struct regmap_bus retu_bus = {
.val_format_endian_default = REGMAP_ENDIAN_NATIVE,
};
-static struct regmap_config retu_config = {
+static const struct regmap_config retu_config = {
.reg_bits = 8,
.val_bits = 16,
};
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 10/14] mfd: smsc-ece1099: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (7 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 09/14] mfd: retu: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:58 ` Lee Jones
2015-01-05 9:01 ` [PATCH 11/14] mfd: tps65217: " Krzysztof Kozlowski
` (4 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel; +Cc: Krzysztof Kozlowski
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
drivers/mfd/smsc-ece1099.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/smsc-ece1099.c b/drivers/mfd/smsc-ece1099.c
index 90112d4cc905..03246880d484 100644
--- a/drivers/mfd/smsc-ece1099.c
+++ b/drivers/mfd/smsc-ece1099.c
@@ -24,7 +24,7 @@
#include <linux/mfd/smsc.h>
#include <linux/of_platform.h>
-static struct regmap_config smsc_regmap_config = {
+static const struct regmap_config smsc_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
.max_register = SMSC_VEN_ID_H,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 11/14] mfd: tps65217: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (8 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 10/14] mfd: smsc-ece1099: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-06 17:11 ` Tony Lindgren
2015-01-20 11:59 ` Lee Jones
2015-01-05 9:01 ` [PATCH 12/14] mfd: tps65218: " Krzysztof Kozlowski
` (3 subsequent siblings)
13 siblings, 2 replies; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel
Cc: Krzysztof Kozlowski, Tony Lindgren, linux-omap
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: linux-omap@vger.kernel.org
---
drivers/mfd/tps65217.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/tps65217.c b/drivers/mfd/tps65217.c
index 80a919a8ca97..7d1cfc1d3ce0 100644
--- a/drivers/mfd/tps65217.c
+++ b/drivers/mfd/tps65217.c
@@ -145,7 +145,7 @@ int tps65217_clear_bits(struct tps65217 *tps, unsigned int reg,
}
EXPORT_SYMBOL_GPL(tps65217_clear_bits);
-static struct regmap_config tps65217_regmap_config = {
+static const struct regmap_config tps65217_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 12/14] mfd: tps65218: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (9 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 11/14] mfd: tps65217: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-20 11:59 ` Lee Jones
2015-01-05 9:01 ` [PATCH 13/14] mfd: twl-core: Constify struct regmap_config and reg_default array Krzysztof Kozlowski
` (2 subsequent siblings)
13 siblings, 1 reply; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel
Cc: Krzysztof Kozlowski, Tony Lindgren, linux-omap
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: linux-omap@vger.kernel.org
---
drivers/mfd/tps65218.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/tps65218.c b/drivers/mfd/tps65218.c
index 0d256cb002eb..b019b3198afe 100644
--- a/drivers/mfd/tps65218.c
+++ b/drivers/mfd/tps65218.c
@@ -125,7 +125,7 @@ int tps65218_clear_bits(struct tps65218 *tps, unsigned int reg,
}
EXPORT_SYMBOL_GPL(tps65218_clear_bits);
-static struct regmap_config tps65218_regmap_config = {
+static const struct regmap_config tps65218_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
.cache_type = REGCACHE_RBTREE,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 13/14] mfd: twl-core: Constify struct regmap_config and reg_default array
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (10 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 12/14] mfd: tps65218: " Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-06 17:12 ` Tony Lindgren
2015-01-20 11:59 ` Lee Jones
2015-01-05 9:01 ` [PATCH 14/14] mfd: twl6040: " Krzysztof Kozlowski
2015-01-20 11:54 ` [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Lee Jones
13 siblings, 2 replies; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel
Cc: Krzysztof Kozlowski, Tony Lindgren, linux-omap
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const. Make array of
struct reg_default const as well.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: linux-omap@vger.kernel.org
---
drivers/mfd/twl-core.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/mfd/twl-core.c b/drivers/mfd/twl-core.c
index db11b4f40611..489674a2497e 100644
--- a/drivers/mfd/twl-core.c
+++ b/drivers/mfd/twl-core.c
@@ -207,7 +207,7 @@ static struct twl_mapping twl4030_map[] = {
{ 2, TWL5031_BASEADD_INTERRUPTS },
};
-static struct reg_default twl4030_49_defaults[] = {
+static const struct reg_default twl4030_49_defaults[] = {
/* Audio Registers */
{ 0x01, 0x00}, /* CODEC_MODE */
{ 0x02, 0x00}, /* OPTION */
@@ -306,7 +306,7 @@ static const struct regmap_access_table twl4030_49_volatile_table = {
.n_yes_ranges = ARRAY_SIZE(twl4030_49_volatile_ranges),
};
-static struct regmap_config twl4030_regmap_config[4] = {
+static const struct regmap_config twl4030_regmap_config[4] = {
{
/* Address 0x48 */
.reg_bits = 8,
@@ -369,7 +369,7 @@ static struct twl_mapping twl6030_map[] = {
{ 1, TWL6030_BASEADD_GASGAUGE },
};
-static struct regmap_config twl6030_regmap_config[3] = {
+static const struct regmap_config twl6030_regmap_config[3] = {
{
/* Address 0x48 */
.reg_bits = 8,
@@ -1087,7 +1087,7 @@ twl_probe(struct i2c_client *client, const struct i2c_device_id *id)
struct twl4030_platform_data *pdata = dev_get_platdata(&client->dev);
struct device_node *node = client->dev.of_node;
struct platform_device *pdev;
- struct regmap_config *twl_regmap_config;
+ const struct regmap_config *twl_regmap_config;
int irq_base = 0;
int status;
unsigned i, num_slaves;
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* [PATCH 14/14] mfd: twl6040: Constify struct regmap_config and reg_default array
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (11 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 13/14] mfd: twl-core: Constify struct regmap_config and reg_default array Krzysztof Kozlowski
@ 2015-01-05 9:01 ` Krzysztof Kozlowski
2015-01-06 17:12 ` Tony Lindgren
2015-01-20 12:00 ` Lee Jones
2015-01-20 11:54 ` [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Lee Jones
13 siblings, 2 replies; 31+ messages in thread
From: Krzysztof Kozlowski @ 2015-01-05 9:01 UTC (permalink / raw)
To: Samuel Ortiz, Lee Jones, linux-kernel
Cc: Krzysztof Kozlowski, Tony Lindgren, linux-omap
The regmap_config struct may be const because it is not modified by the
driver and regmap_init() accepts pointer to const. Make array of
struct reg_default const as well.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: linux-omap@vger.kernel.org
---
drivers/mfd/twl6040.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
index 9687645162ae..f71ee3dbc2a2 100644
--- a/drivers/mfd/twl6040.c
+++ b/drivers/mfd/twl6040.c
@@ -44,7 +44,7 @@
#define VIBRACTRL_MEMBER(reg) ((reg == TWL6040_REG_VIBCTLL) ? 0 : 1)
#define TWL6040_NUM_SUPPLIES (2)
-static struct reg_default twl6040_defaults[] = {
+static const struct reg_default twl6040_defaults[] = {
{ 0x01, 0x4B }, /* REG_ASICID (ro) */
{ 0x02, 0x00 }, /* REG_ASICREV (ro) */
{ 0x03, 0x00 }, /* REG_INTID */
@@ -580,7 +580,7 @@ static bool twl6040_writeable_reg(struct device *dev, unsigned int reg)
}
}
-static struct regmap_config twl6040_regmap_config = {
+static const struct regmap_config twl6040_regmap_config = {
.reg_bits = 8,
.val_bits = 8,
--
1.9.1
^ permalink raw reply related [flat|nested] 31+ messages in thread
* Re: [PATCH 11/14] mfd: tps65217: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 11/14] mfd: tps65217: " Krzysztof Kozlowski
@ 2015-01-06 17:11 ` Tony Lindgren
2015-01-20 11:59 ` Lee Jones
1 sibling, 0 replies; 31+ messages in thread
From: Tony Lindgren @ 2015-01-06 17:11 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, Lee Jones, linux-kernel, linux-omap
* Krzysztof Kozlowski <k.kozlowski@samsung.com> [150105 01:04]:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Acked-by: Tony Lindgren <tony@atomide.com>
> Cc: linux-omap@vger.kernel.org
> ---
> drivers/mfd/tps65217.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mfd/tps65217.c b/drivers/mfd/tps65217.c
> index 80a919a8ca97..7d1cfc1d3ce0 100644
> --- a/drivers/mfd/tps65217.c
> +++ b/drivers/mfd/tps65217.c
> @@ -145,7 +145,7 @@ int tps65217_clear_bits(struct tps65217 *tps, unsigned int reg,
> }
> EXPORT_SYMBOL_GPL(tps65217_clear_bits);
>
> -static struct regmap_config tps65217_regmap_config = {
> +static const struct regmap_config tps65217_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
>
> --
> 1.9.1
>
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 13/14] mfd: twl-core: Constify struct regmap_config and reg_default array
2015-01-05 9:01 ` [PATCH 13/14] mfd: twl-core: Constify struct regmap_config and reg_default array Krzysztof Kozlowski
@ 2015-01-06 17:12 ` Tony Lindgren
2015-01-20 11:59 ` Lee Jones
1 sibling, 0 replies; 31+ messages in thread
From: Tony Lindgren @ 2015-01-06 17:12 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, Lee Jones, linux-kernel, linux-omap
* Krzysztof Kozlowski <k.kozlowski@samsung.com> [150105 01:04]:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const. Make array of
> struct reg_default const as well.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Acked-by: Tony Lindgren <tony@atomide.com>
> Cc: linux-omap@vger.kernel.org
> ---
> drivers/mfd/twl-core.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/mfd/twl-core.c b/drivers/mfd/twl-core.c
> index db11b4f40611..489674a2497e 100644
> --- a/drivers/mfd/twl-core.c
> +++ b/drivers/mfd/twl-core.c
> @@ -207,7 +207,7 @@ static struct twl_mapping twl4030_map[] = {
> { 2, TWL5031_BASEADD_INTERRUPTS },
> };
>
> -static struct reg_default twl4030_49_defaults[] = {
> +static const struct reg_default twl4030_49_defaults[] = {
> /* Audio Registers */
> { 0x01, 0x00}, /* CODEC_MODE */
> { 0x02, 0x00}, /* OPTION */
> @@ -306,7 +306,7 @@ static const struct regmap_access_table twl4030_49_volatile_table = {
> .n_yes_ranges = ARRAY_SIZE(twl4030_49_volatile_ranges),
> };
>
> -static struct regmap_config twl4030_regmap_config[4] = {
> +static const struct regmap_config twl4030_regmap_config[4] = {
> {
> /* Address 0x48 */
> .reg_bits = 8,
> @@ -369,7 +369,7 @@ static struct twl_mapping twl6030_map[] = {
> { 1, TWL6030_BASEADD_GASGAUGE },
> };
>
> -static struct regmap_config twl6030_regmap_config[3] = {
> +static const struct regmap_config twl6030_regmap_config[3] = {
> {
> /* Address 0x48 */
> .reg_bits = 8,
> @@ -1087,7 +1087,7 @@ twl_probe(struct i2c_client *client, const struct i2c_device_id *id)
> struct twl4030_platform_data *pdata = dev_get_platdata(&client->dev);
> struct device_node *node = client->dev.of_node;
> struct platform_device *pdev;
> - struct regmap_config *twl_regmap_config;
> + const struct regmap_config *twl_regmap_config;
> int irq_base = 0;
> int status;
> unsigned i, num_slaves;
> --
> 1.9.1
>
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 14/14] mfd: twl6040: Constify struct regmap_config and reg_default array
2015-01-05 9:01 ` [PATCH 14/14] mfd: twl6040: " Krzysztof Kozlowski
@ 2015-01-06 17:12 ` Tony Lindgren
2015-01-20 12:00 ` Lee Jones
1 sibling, 0 replies; 31+ messages in thread
From: Tony Lindgren @ 2015-01-06 17:12 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, Lee Jones, linux-kernel, linux-omap
* Krzysztof Kozlowski <k.kozlowski@samsung.com> [150105 01:04]:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const. Make array of
> struct reg_default const as well.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Acked-by: Tony Lindgren <tony@atomide.com>
> Cc: linux-omap@vger.kernel.org
> ---
> drivers/mfd/twl6040.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
> index 9687645162ae..f71ee3dbc2a2 100644
> --- a/drivers/mfd/twl6040.c
> +++ b/drivers/mfd/twl6040.c
> @@ -44,7 +44,7 @@
> #define VIBRACTRL_MEMBER(reg) ((reg == TWL6040_REG_VIBCTLL) ? 0 : 1)
> #define TWL6040_NUM_SUPPLIES (2)
>
> -static struct reg_default twl6040_defaults[] = {
> +static const struct reg_default twl6040_defaults[] = {
> { 0x01, 0x4B }, /* REG_ASICID (ro) */
> { 0x02, 0x00 }, /* REG_ASICREV (ro) */
> { 0x03, 0x00 }, /* REG_INTID */
> @@ -580,7 +580,7 @@ static bool twl6040_writeable_reg(struct device *dev, unsigned int reg)
> }
> }
>
> -static struct regmap_config twl6040_regmap_config = {
> +static const struct regmap_config twl6040_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
>
> --
> 1.9.1
>
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
` (12 preceding siblings ...)
2015-01-05 9:01 ` [PATCH 14/14] mfd: twl6040: " Krzysztof Kozlowski
@ 2015-01-20 11:54 ` Lee Jones
13 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:54 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/88pm860x-core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks.
> diff --git a/drivers/mfd/88pm860x-core.c b/drivers/mfd/88pm860x-core.c
> index 3a2604580164..d2a85cde68da 100644
> --- a/drivers/mfd/88pm860x-core.c
> +++ b/drivers/mfd/88pm860x-core.c
> @@ -1111,7 +1111,7 @@ static int verify_addr(struct i2c_client *i2c)
> return 0;
> }
>
> -static struct regmap_config pm860x_regmap_config = {
> +static const struct regmap_config pm860x_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
> };
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 02/14] mfd: hi6421-pmic: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 02/14] mfd: hi6421-pmic: " Krzysztof Kozlowski
@ 2015-01-20 11:56 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:56 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/hi6421-pmic-core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks.
> diff --git a/drivers/mfd/hi6421-pmic-core.c b/drivers/mfd/hi6421-pmic-core.c
> index 321a2656fd00..7210ae28bf81 100644
> --- a/drivers/mfd/hi6421-pmic-core.c
> +++ b/drivers/mfd/hi6421-pmic-core.c
> @@ -35,7 +35,7 @@ static const struct mfd_cell hi6421_devs[] = {
> { .name = "hi6421-regulator", },
> };
>
> -static struct regmap_config hi6421_regmap_config = {
> +static const struct regmap_config hi6421_regmap_config = {
> .reg_bits = 32,
> .reg_stride = 4,
> .val_bits = 8,
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 03/14] mfd: intel_soc_pmic: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 03/14] mfd: intel_soc_pmic: " Krzysztof Kozlowski
@ 2015-01-20 11:56 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:56 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/intel_soc_pmic_core.h | 2 +-
> drivers/mfd/intel_soc_pmic_crc.c | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
Applied, thanks.
> diff --git a/drivers/mfd/intel_soc_pmic_core.h b/drivers/mfd/intel_soc_pmic_core.h
> index 33aacd9baddc..9498d6719847 100644
> --- a/drivers/mfd/intel_soc_pmic_core.h
> +++ b/drivers/mfd/intel_soc_pmic_core.h
> @@ -23,7 +23,7 @@ struct intel_soc_pmic_config {
> unsigned long irq_flags;
> struct mfd_cell *cell_dev;
> int n_cell_devs;
> - struct regmap_config *regmap_config;
> + const struct regmap_config *regmap_config;
> struct regmap_irq_chip *irq_chip;
> };
>
> diff --git a/drivers/mfd/intel_soc_pmic_crc.c b/drivers/mfd/intel_soc_pmic_crc.c
> index c85e2ecb868a..4cc1b324e971 100644
> --- a/drivers/mfd/intel_soc_pmic_crc.c
> +++ b/drivers/mfd/intel_soc_pmic_crc.c
> @@ -111,7 +111,7 @@ static struct mfd_cell crystal_cove_dev[] = {
> },
> };
>
> -static struct regmap_config crystal_cove_regmap_config = {
> +static const struct regmap_config crystal_cove_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
>
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 04/14] mfd: davinci_voicecodec: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 04/14] mfd: davinci_voicecodec: " Krzysztof Kozlowski
@ 2015-01-20 11:56 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:56 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/davinci_voicecodec.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks.
> diff --git a/drivers/mfd/davinci_voicecodec.c b/drivers/mfd/davinci_voicecodec.c
> index c835e85539b2..9bbc642a7b9d 100644
> --- a/drivers/mfd/davinci_voicecodec.c
> +++ b/drivers/mfd/davinci_voicecodec.c
> @@ -33,7 +33,7 @@
>
> #include <linux/mfd/davinci_voicecodec.h>
>
> -static struct regmap_config davinci_vc_regmap = {
> +static const struct regmap_config davinci_vc_regmap = {
> .reg_bits = 32,
> .val_bits = 32,
> };
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 06/14] mfd: max77686: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 06/14] mfd: max77686: " Krzysztof Kozlowski
@ 2015-01-20 11:57 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:57 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/max77686.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
Applied, thanks.
> diff --git a/drivers/mfd/max77686.c b/drivers/mfd/max77686.c
> index 929795eae9fc..2b2f2ccda523 100644
> --- a/drivers/mfd/max77686.c
> +++ b/drivers/mfd/max77686.c
> @@ -111,17 +111,17 @@ static bool max77802_is_volatile_reg(struct device *dev, unsigned int reg)
> max77802_rtc_is_volatile_reg(dev, reg));
> }
>
> -static struct regmap_config max77686_regmap_config = {
> +static const struct regmap_config max77686_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
> };
>
> -static struct regmap_config max77686_rtc_regmap_config = {
> +static const struct regmap_config max77686_rtc_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
> };
>
> -static struct regmap_config max77802_regmap_config = {
> +static const struct regmap_config max77802_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
> .writeable_reg = max77802_is_accessible_reg,
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 05/14] mfd: lm3533: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 05/14] mfd: lm3533: " Krzysztof Kozlowski
@ 2015-01-20 11:57 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:57 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/lm3533-core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks.
> diff --git a/drivers/mfd/lm3533-core.c b/drivers/mfd/lm3533-core.c
> index 8c29f7b27324..d42fbb667d8c 100644
> --- a/drivers/mfd/lm3533-core.c
> +++ b/drivers/mfd/lm3533-core.c
> @@ -583,7 +583,7 @@ static bool lm3533_precious_register(struct device *dev, unsigned int reg)
> }
> }
>
> -static struct regmap_config regmap_config = {
> +static const struct regmap_config regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
> .max_register = LM3533_REG_MAX,
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 09/14] mfd: retu: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 09/14] mfd: retu: " Krzysztof Kozlowski
@ 2015-01-20 11:58 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:58 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/retu-mfd.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks.
> diff --git a/drivers/mfd/retu-mfd.c b/drivers/mfd/retu-mfd.c
> index 663f8a37aa6b..2d64430c719b 100644
> --- a/drivers/mfd/retu-mfd.c
> +++ b/drivers/mfd/retu-mfd.c
> @@ -222,7 +222,7 @@ static struct regmap_bus retu_bus = {
> .val_format_endian_default = REGMAP_ENDIAN_NATIVE,
> };
>
> -static struct regmap_config retu_config = {
> +static const struct regmap_config retu_config = {
> .reg_bits = 8,
> .val_bits = 16,
> };
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 08/14] mfd: pcf50633: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 08/14] mfd: pcf50633: " Krzysztof Kozlowski
@ 2015-01-20 11:58 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:58 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/pcf50633-core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks.
> diff --git a/drivers/mfd/pcf50633-core.c b/drivers/mfd/pcf50633-core.c
> index 43664eb69c93..6155d123a84e 100644
> --- a/drivers/mfd/pcf50633-core.c
> +++ b/drivers/mfd/pcf50633-core.c
> @@ -183,7 +183,7 @@ static int pcf50633_resume(struct device *dev)
>
> static SIMPLE_DEV_PM_OPS(pcf50633_pm, pcf50633_suspend, pcf50633_resume);
>
> -static struct regmap_config pcf50633_regmap_config = {
> +static const struct regmap_config pcf50633_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
> };
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 07/14] mfd: mc13xxx: i2c/spi: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 07/14] mfd: mc13xxx: i2c/spi: " Krzysztof Kozlowski
@ 2015-01-20 11:58 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:58 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/mc13xxx-i2c.c | 2 +-
> drivers/mfd/mc13xxx-spi.c | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
Applied, thanks.
> diff --git a/drivers/mfd/mc13xxx-i2c.c b/drivers/mfd/mc13xxx-i2c.c
> index ae3addb153a2..68b844811566 100644
> --- a/drivers/mfd/mc13xxx-i2c.c
> +++ b/drivers/mfd/mc13xxx-i2c.c
> @@ -46,7 +46,7 @@ static const struct of_device_id mc13xxx_dt_ids[] = {
> };
> MODULE_DEVICE_TABLE(of, mc13xxx_dt_ids);
>
> -static struct regmap_config mc13xxx_regmap_i2c_config = {
> +static const struct regmap_config mc13xxx_regmap_i2c_config = {
> .reg_bits = 8,
> .val_bits = 24,
>
> diff --git a/drivers/mfd/mc13xxx-spi.c b/drivers/mfd/mc13xxx-spi.c
> index 702925e242c9..58a170e45d88 100644
> --- a/drivers/mfd/mc13xxx-spi.c
> +++ b/drivers/mfd/mc13xxx-spi.c
> @@ -48,7 +48,7 @@ static const struct of_device_id mc13xxx_dt_ids[] = {
> };
> MODULE_DEVICE_TABLE(of, mc13xxx_dt_ids);
>
> -static struct regmap_config mc13xxx_regmap_spi_config = {
> +static const struct regmap_config mc13xxx_regmap_spi_config = {
> .reg_bits = 7,
> .pad_bits = 1,
> .val_bits = 24,
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 10/14] mfd: smsc-ece1099: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 10/14] mfd: smsc-ece1099: " Krzysztof Kozlowski
@ 2015-01-20 11:58 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:58 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> ---
> drivers/mfd/smsc-ece1099.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks.
> diff --git a/drivers/mfd/smsc-ece1099.c b/drivers/mfd/smsc-ece1099.c
> index 90112d4cc905..03246880d484 100644
> --- a/drivers/mfd/smsc-ece1099.c
> +++ b/drivers/mfd/smsc-ece1099.c
> @@ -24,7 +24,7 @@
> #include <linux/mfd/smsc.h>
> #include <linux/of_platform.h>
>
> -static struct regmap_config smsc_regmap_config = {
> +static const struct regmap_config smsc_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
> .max_register = SMSC_VEN_ID_H,
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 11/14] mfd: tps65217: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 11/14] mfd: tps65217: " Krzysztof Kozlowski
2015-01-06 17:11 ` Tony Lindgren
@ 2015-01-20 11:59 ` Lee Jones
1 sibling, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:59 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel, Tony Lindgren, linux-omap
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> Cc: Tony Lindgren <tony@atomide.com>
> Cc: linux-omap@vger.kernel.org
> ---
> drivers/mfd/tps65217.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied with Tony's Ack, thanks.
> diff --git a/drivers/mfd/tps65217.c b/drivers/mfd/tps65217.c
> index 80a919a8ca97..7d1cfc1d3ce0 100644
> --- a/drivers/mfd/tps65217.c
> +++ b/drivers/mfd/tps65217.c
> @@ -145,7 +145,7 @@ int tps65217_clear_bits(struct tps65217 *tps, unsigned int reg,
> }
> EXPORT_SYMBOL_GPL(tps65217_clear_bits);
>
> -static struct regmap_config tps65217_regmap_config = {
> +static const struct regmap_config tps65217_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
>
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 12/14] mfd: tps65218: Constify struct regmap_config
2015-01-05 9:01 ` [PATCH 12/14] mfd: tps65218: " Krzysztof Kozlowski
@ 2015-01-20 11:59 ` Lee Jones
0 siblings, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:59 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel, Tony Lindgren, linux-omap
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> Cc: Tony Lindgren <tony@atomide.com>
> Cc: linux-omap@vger.kernel.org
> ---
> drivers/mfd/tps65218.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied with Tony's Ack, thanks.
> diff --git a/drivers/mfd/tps65218.c b/drivers/mfd/tps65218.c
> index 0d256cb002eb..b019b3198afe 100644
> --- a/drivers/mfd/tps65218.c
> +++ b/drivers/mfd/tps65218.c
> @@ -125,7 +125,7 @@ int tps65218_clear_bits(struct tps65218 *tps, unsigned int reg,
> }
> EXPORT_SYMBOL_GPL(tps65218_clear_bits);
>
> -static struct regmap_config tps65218_regmap_config = {
> +static const struct regmap_config tps65218_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
> .cache_type = REGCACHE_RBTREE,
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 13/14] mfd: twl-core: Constify struct regmap_config and reg_default array
2015-01-05 9:01 ` [PATCH 13/14] mfd: twl-core: Constify struct regmap_config and reg_default array Krzysztof Kozlowski
2015-01-06 17:12 ` Tony Lindgren
@ 2015-01-20 11:59 ` Lee Jones
1 sibling, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 11:59 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel, Tony Lindgren, linux-omap
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const. Make array of
> struct reg_default const as well.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> Cc: Tony Lindgren <tony@atomide.com>
> Cc: linux-omap@vger.kernel.org
> ---
> drivers/mfd/twl-core.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
Applied with Tony's Ack, thanks.
> diff --git a/drivers/mfd/twl-core.c b/drivers/mfd/twl-core.c
> index db11b4f40611..489674a2497e 100644
> --- a/drivers/mfd/twl-core.c
> +++ b/drivers/mfd/twl-core.c
> @@ -207,7 +207,7 @@ static struct twl_mapping twl4030_map[] = {
> { 2, TWL5031_BASEADD_INTERRUPTS },
> };
>
> -static struct reg_default twl4030_49_defaults[] = {
> +static const struct reg_default twl4030_49_defaults[] = {
> /* Audio Registers */
> { 0x01, 0x00}, /* CODEC_MODE */
> { 0x02, 0x00}, /* OPTION */
> @@ -306,7 +306,7 @@ static const struct regmap_access_table twl4030_49_volatile_table = {
> .n_yes_ranges = ARRAY_SIZE(twl4030_49_volatile_ranges),
> };
>
> -static struct regmap_config twl4030_regmap_config[4] = {
> +static const struct regmap_config twl4030_regmap_config[4] = {
> {
> /* Address 0x48 */
> .reg_bits = 8,
> @@ -369,7 +369,7 @@ static struct twl_mapping twl6030_map[] = {
> { 1, TWL6030_BASEADD_GASGAUGE },
> };
>
> -static struct regmap_config twl6030_regmap_config[3] = {
> +static const struct regmap_config twl6030_regmap_config[3] = {
> {
> /* Address 0x48 */
> .reg_bits = 8,
> @@ -1087,7 +1087,7 @@ twl_probe(struct i2c_client *client, const struct i2c_device_id *id)
> struct twl4030_platform_data *pdata = dev_get_platdata(&client->dev);
> struct device_node *node = client->dev.of_node;
> struct platform_device *pdev;
> - struct regmap_config *twl_regmap_config;
> + const struct regmap_config *twl_regmap_config;
> int irq_base = 0;
> int status;
> unsigned i, num_slaves;
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
* Re: [PATCH 14/14] mfd: twl6040: Constify struct regmap_config and reg_default array
2015-01-05 9:01 ` [PATCH 14/14] mfd: twl6040: " Krzysztof Kozlowski
2015-01-06 17:12 ` Tony Lindgren
@ 2015-01-20 12:00 ` Lee Jones
1 sibling, 0 replies; 31+ messages in thread
From: Lee Jones @ 2015-01-20 12:00 UTC (permalink / raw)
To: Krzysztof Kozlowski; +Cc: Samuel Ortiz, linux-kernel, Tony Lindgren, linux-omap
On Mon, 05 Jan 2015, Krzysztof Kozlowski wrote:
> The regmap_config struct may be const because it is not modified by the
> driver and regmap_init() accepts pointer to const. Make array of
> struct reg_default const as well.
>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> Cc: Tony Lindgren <tony@atomide.com>
> Cc: linux-omap@vger.kernel.org
> ---
> drivers/mfd/twl6040.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Applied with Tony's Ack, thanks.
> diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
> index 9687645162ae..f71ee3dbc2a2 100644
> --- a/drivers/mfd/twl6040.c
> +++ b/drivers/mfd/twl6040.c
> @@ -44,7 +44,7 @@
> #define VIBRACTRL_MEMBER(reg) ((reg == TWL6040_REG_VIBCTLL) ? 0 : 1)
> #define TWL6040_NUM_SUPPLIES (2)
>
> -static struct reg_default twl6040_defaults[] = {
> +static const struct reg_default twl6040_defaults[] = {
> { 0x01, 0x4B }, /* REG_ASICID (ro) */
> { 0x02, 0x00 }, /* REG_ASICREV (ro) */
> { 0x03, 0x00 }, /* REG_INTID */
> @@ -580,7 +580,7 @@ static bool twl6040_writeable_reg(struct device *dev, unsigned int reg)
> }
> }
>
> -static struct regmap_config twl6040_regmap_config = {
> +static const struct regmap_config twl6040_regmap_config = {
> .reg_bits = 8,
> .val_bits = 8,
>
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 31+ messages in thread
end of thread, other threads:[~2015-01-20 12:00 UTC | newest]
Thread overview: 31+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-05 9:01 [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Krzysztof Kozlowski
2015-01-05 9:01 ` [PATCH 02/14] mfd: hi6421-pmic: " Krzysztof Kozlowski
2015-01-20 11:56 ` Lee Jones
2015-01-05 9:01 ` [PATCH 03/14] mfd: intel_soc_pmic: " Krzysztof Kozlowski
2015-01-20 11:56 ` Lee Jones
2015-01-05 9:01 ` [PATCH 04/14] mfd: davinci_voicecodec: " Krzysztof Kozlowski
2015-01-20 11:56 ` Lee Jones
2015-01-05 9:01 ` [PATCH 05/14] mfd: lm3533: " Krzysztof Kozlowski
2015-01-20 11:57 ` Lee Jones
2015-01-05 9:01 ` [PATCH 06/14] mfd: max77686: " Krzysztof Kozlowski
2015-01-20 11:57 ` Lee Jones
2015-01-05 9:01 ` [PATCH 07/14] mfd: mc13xxx: i2c/spi: " Krzysztof Kozlowski
2015-01-20 11:58 ` Lee Jones
2015-01-05 9:01 ` [PATCH 08/14] mfd: pcf50633: " Krzysztof Kozlowski
2015-01-20 11:58 ` Lee Jones
2015-01-05 9:01 ` [PATCH 09/14] mfd: retu: " Krzysztof Kozlowski
2015-01-20 11:58 ` Lee Jones
2015-01-05 9:01 ` [PATCH 10/14] mfd: smsc-ece1099: " Krzysztof Kozlowski
2015-01-20 11:58 ` Lee Jones
2015-01-05 9:01 ` [PATCH 11/14] mfd: tps65217: " Krzysztof Kozlowski
2015-01-06 17:11 ` Tony Lindgren
2015-01-20 11:59 ` Lee Jones
2015-01-05 9:01 ` [PATCH 12/14] mfd: tps65218: " Krzysztof Kozlowski
2015-01-20 11:59 ` Lee Jones
2015-01-05 9:01 ` [PATCH 13/14] mfd: twl-core: Constify struct regmap_config and reg_default array Krzysztof Kozlowski
2015-01-06 17:12 ` Tony Lindgren
2015-01-20 11:59 ` Lee Jones
2015-01-05 9:01 ` [PATCH 14/14] mfd: twl6040: " Krzysztof Kozlowski
2015-01-06 17:12 ` Tony Lindgren
2015-01-20 12:00 ` Lee Jones
2015-01-20 11:54 ` [PATCH 01/14] mfd: 88pm860x-core: Constify struct regmap_config Lee Jones
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).