Skip to contentSkip to conversation

rtc: rtc-ds1742: Make of_device_id array const

PATCH In review Jingoo Han 2 participants 6 messages May 7, 2014 Real time clock (RTC)

lore
Share & tools
lore

Jingoo Han

author
#0 lore raw

PATCH 1/5 rtc: rtc-ds1742: Make of_device_id array const

Make of_device_id array const, because all OF functions handle it as const.

---
 drivers/rtc/rtc-ds1742.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/rtc/rtc-ds1742.c +1 -1
index 942103d..c6b2191 100644
@@ -219,7 +219,7 @@ static int ds1742_rtc_remove(struct platform_device *pdev)
 	return 0;
 }
 
-static struct of_device_id __maybe_unused ds1742_rtc_of_match[] = {
+static const struct of_device_id __maybe_unused ds1742_rtc_of_match[] = {
 	{ .compatible = "maxim,ds1742", },
 	{ }
 };
Signature · 1 line
1.7.10.4
author
#1 lore raw

PATCH 2/5 rtc: rtc-hym8563: Make of_device_id array const

Make of_device_id array const, because all OF functions handle it as const.

---
 drivers/rtc/rtc-hym8563.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/rtc/rtc-hym8563.c +1 -1
index bd628a6..5620c24 100644
@@ -582,7 +582,7 @@ static const struct i2c_device_id hym8563_id[] = {
 };
 MODULE_DEVICE_TABLE(i2c, hym8563_id);
 
-static struct of_device_id hym8563_dt_idtable[] = {
+static const struct of_device_id hym8563_dt_idtable[] = {
 	{ .compatible = "haoyu,hym8563" },
 	{},
 };
Signature · 1 line
1.7.10.4
Acked-by on v1 2/5
#2 lore raw

Re: [PATCH 2/5] rtc: rtc-hym8563: Make of_device_id array const

Am Mittwoch, 7. Mai 2014, 17:34:42 schrieb Jingoo Han:

Quoted 4 lines

Make of_device_id array const, because all OF functions handle it as const.

Quoted 17 lines
---
 drivers/rtc/rtc-hym8563.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/rtc/rtc-hym8563.c +1 -1
index bd628a6..5620c24 100644
@@ -582,7 +582,7 @@ static const struct i2c_device_id hym8563_id[] = {
 };
 MODULE_DEVICE_TABLE(i2c, hym8563_id);
 
-static struct of_device_id hym8563_dt_idtable[] = {
+static const struct of_device_id hym8563_dt_idtable[] = {
 	{ .compatible = "haoyu,hym8563" },
 	{},
 };
author
#3 lore raw

PATCH 3/5 rtc: isl12057: Make of_device_id array const

In reply to Jingoo Han

Make of_device_id array const, because all OF functions handle it as const.

---
 drivers/rtc/rtc-isl12057.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/rtc/rtc-isl12057.c +1 -1
index 41bd76a..455b601 100644
@@ -278,7 +278,7 @@ static int isl12057_probe(struct i2c_client *client,
 }
 
 #ifdef CONFIG_OF
-static struct of_device_id isl12057_dt_match[] = {
+static const struct of_device_id isl12057_dt_match[] = {
 	{ .compatible = "isl,isl12057" },
 	{ },
 };
Signature · 1 line
1.7.10.4
author
#4 lore raw

PATCH 4/5 rtc: rtc-mv: Make of_device_id array const

In reply to Jingoo Han

Make of_device_id array const, because all OF functions handle it as const.

---
 drivers/rtc/rtc-mv.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/rtc/rtc-mv.c +1 -1
index d15a999..6aaec2f 100644
@@ -319,7 +319,7 @@ static int __exit mv_rtc_remove(struct platform_device *pdev)
 }
 
 #ifdef CONFIG_OF
-static struct of_device_id rtc_mv_of_match_table[] = {
+static const struct of_device_id rtc_mv_of_match_table[] = {
 	{ .compatible = "marvell,orion-rtc", },
 	{}
 };
Signature · 1 line
1.7.10.4
author
#5 lore raw

PATCH 5/5 rtc: rtc-palmas: Make of_device_id array const

In reply to Jingoo Han

Make of_device_id array const, because all OF functions handle it as const.

---
 drivers/rtc/rtc-palmas.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/rtc/rtc-palmas.c +1 -1
index c360d62..4dfe2d7 100644
@@ -352,7 +352,7 @@ static SIMPLE_DEV_PM_OPS(palmas_rtc_pm_ops, palmas_rtc_suspend,
 			 palmas_rtc_resume);
 
 #ifdef CONFIG_OF
-static struct of_device_id of_palmas_rtc_match[] = {
+static const struct of_device_id of_palmas_rtc_match[] = {
 	{ .compatible = "ti,palmas-rtc"},
 	{ },
 };
Signature · 1 line
1.7.10.4