diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2011-02-19 10:55:00 -0500 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2011-02-23 11:24:14 -0500 |
commit | aa25afad2ca60d19457849ea75e9c31236f4e174 (patch) | |
tree | 24c8c815caf191af56f8de287637087c298711b2 /drivers | |
parent | 394d5aefcdecb51bbf7d6df757e73559c9692a08 (diff) |
ARM: amba: make probe() functions take const id tables
Make Primecell driver probe functions take a const pointer to their
ID tables. Drivers should never modify their ID tables in their
probe handler.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/char/hw_random/nomadik-rng.c | 2 | ||||
-rw-r--r-- | drivers/dma/amba-pl08x.c | 2 | ||||
-rw-r--r-- | drivers/dma/pl330.c | 2 | ||||
-rw-r--r-- | drivers/gpio/pl061.c | 2 | ||||
-rw-r--r-- | drivers/input/serio/ambakmi.c | 3 | ||||
-rw-r--r-- | drivers/mmc/host/mmci.c | 3 | ||||
-rw-r--r-- | drivers/rtc/rtc-pl030.c | 2 | ||||
-rw-r--r-- | drivers/rtc/rtc-pl031.c | 2 | ||||
-rw-r--r-- | drivers/spi/amba-pl022.c | 2 | ||||
-rw-r--r-- | drivers/tty/serial/amba-pl010.c | 2 | ||||
-rw-r--r-- | drivers/tty/serial/amba-pl011.c | 2 | ||||
-rw-r--r-- | drivers/video/amba-clcd.c | 2 | ||||
-rw-r--r-- | drivers/watchdog/sp805_wdt.c | 2 |
13 files changed, 15 insertions, 13 deletions
diff --git a/drivers/char/hw_random/nomadik-rng.c b/drivers/char/hw_random/nomadik-rng.c index a348c7e9aa0b..dd1d143eb8ea 100644 --- a/drivers/char/hw_random/nomadik-rng.c +++ b/drivers/char/hw_random/nomadik-rng.c | |||
@@ -39,7 +39,7 @@ static struct hwrng nmk_rng = { | |||
39 | .read = nmk_rng_read, | 39 | .read = nmk_rng_read, |
40 | }; | 40 | }; |
41 | 41 | ||
42 | static int nmk_rng_probe(struct amba_device *dev, struct amba_id *id) | 42 | static int nmk_rng_probe(struct amba_device *dev, const struct amba_id *id) |
43 | { | 43 | { |
44 | void __iomem *base; | 44 | void __iomem *base; |
45 | int ret; | 45 | int ret; |
diff --git a/drivers/dma/amba-pl08x.c b/drivers/dma/amba-pl08x.c index 07bca4970e50..e6d7228b1479 100644 --- a/drivers/dma/amba-pl08x.c +++ b/drivers/dma/amba-pl08x.c | |||
@@ -1845,7 +1845,7 @@ static inline void init_pl08x_debugfs(struct pl08x_driver_data *pl08x) | |||
1845 | } | 1845 | } |
1846 | #endif | 1846 | #endif |
1847 | 1847 | ||
1848 | static int pl08x_probe(struct amba_device *adev, struct amba_id *id) | 1848 | static int pl08x_probe(struct amba_device *adev, const struct amba_id *id) |
1849 | { | 1849 | { |
1850 | struct pl08x_driver_data *pl08x; | 1850 | struct pl08x_driver_data *pl08x; |
1851 | const struct vendor_data *vd = id->data; | 1851 | const struct vendor_data *vd = id->data; |
diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c index 7c50f6dfd3f4..6abe1ec1f2ce 100644 --- a/drivers/dma/pl330.c +++ b/drivers/dma/pl330.c | |||
@@ -657,7 +657,7 @@ static irqreturn_t pl330_irq_handler(int irq, void *data) | |||
657 | } | 657 | } |
658 | 658 | ||
659 | static int __devinit | 659 | static int __devinit |
660 | pl330_probe(struct amba_device *adev, struct amba_id *id) | 660 | pl330_probe(struct amba_device *adev, const struct amba_id *id) |
661 | { | 661 | { |
662 | struct dma_pl330_platdata *pdat; | 662 | struct dma_pl330_platdata *pdat; |
663 | struct dma_pl330_dmac *pdmac; | 663 | struct dma_pl330_dmac *pdmac; |
diff --git a/drivers/gpio/pl061.c b/drivers/gpio/pl061.c index 2975d22daffe..838ddbdf90cc 100644 --- a/drivers/gpio/pl061.c +++ b/drivers/gpio/pl061.c | |||
@@ -232,7 +232,7 @@ static void pl061_irq_handler(unsigned irq, struct irq_desc *desc) | |||
232 | desc->irq_data.chip->irq_unmask(&desc->irq_data); | 232 | desc->irq_data.chip->irq_unmask(&desc->irq_data); |
233 | } | 233 | } |
234 | 234 | ||
235 | static int pl061_probe(struct amba_device *dev, struct amba_id *id) | 235 | static int pl061_probe(struct amba_device *dev, const struct amba_id *id) |
236 | { | 236 | { |
237 | struct pl061_platform_data *pdata; | 237 | struct pl061_platform_data *pdata; |
238 | struct pl061_gpio *chip; | 238 | struct pl061_gpio *chip; |
diff --git a/drivers/input/serio/ambakmi.c b/drivers/input/serio/ambakmi.c index 92563a681d65..12abc50508e5 100644 --- a/drivers/input/serio/ambakmi.c +++ b/drivers/input/serio/ambakmi.c | |||
@@ -107,7 +107,8 @@ static void amba_kmi_close(struct serio *io) | |||
107 | clk_disable(kmi->clk); | 107 | clk_disable(kmi->clk); |
108 | } | 108 | } |
109 | 109 | ||
110 | static int __devinit amba_kmi_probe(struct amba_device *dev, struct amba_id *id) | 110 | static int __devinit amba_kmi_probe(struct amba_device *dev, |
111 | const struct amba_id *id) | ||
111 | { | 112 | { |
112 | struct amba_kmi_port *kmi; | 113 | struct amba_kmi_port *kmi; |
113 | struct serio *io; | 114 | struct serio *io; |
diff --git a/drivers/mmc/host/mmci.c b/drivers/mmc/host/mmci.c index 2d6de3e03e2d..67f17d61b978 100644 --- a/drivers/mmc/host/mmci.c +++ b/drivers/mmc/host/mmci.c | |||
@@ -713,7 +713,8 @@ static const struct mmc_host_ops mmci_ops = { | |||
713 | .get_cd = mmci_get_cd, | 713 | .get_cd = mmci_get_cd, |
714 | }; | 714 | }; |
715 | 715 | ||
716 | static int __devinit mmci_probe(struct amba_device *dev, struct amba_id *id) | 716 | static int __devinit mmci_probe(struct amba_device *dev, |
717 | const struct amba_id *id) | ||
717 | { | 718 | { |
718 | struct mmci_platform_data *plat = dev->dev.platform_data; | 719 | struct mmci_platform_data *plat = dev->dev.platform_data; |
719 | struct variant_data *variant = id->data; | 720 | struct variant_data *variant = id->data; |
diff --git a/drivers/rtc/rtc-pl030.c b/drivers/rtc/rtc-pl030.c index bbdb2f02798a..baff724cd40f 100644 --- a/drivers/rtc/rtc-pl030.c +++ b/drivers/rtc/rtc-pl030.c | |||
@@ -103,7 +103,7 @@ static const struct rtc_class_ops pl030_ops = { | |||
103 | .set_alarm = pl030_set_alarm, | 103 | .set_alarm = pl030_set_alarm, |
104 | }; | 104 | }; |
105 | 105 | ||
106 | static int pl030_probe(struct amba_device *dev, struct amba_id *id) | 106 | static int pl030_probe(struct amba_device *dev, const struct amba_id *id) |
107 | { | 107 | { |
108 | struct pl030_rtc *rtc; | 108 | struct pl030_rtc *rtc; |
109 | int ret; | 109 | int ret; |
diff --git a/drivers/rtc/rtc-pl031.c b/drivers/rtc/rtc-pl031.c index b7a6690e5b35..6568f4b37e19 100644 --- a/drivers/rtc/rtc-pl031.c +++ b/drivers/rtc/rtc-pl031.c | |||
@@ -358,7 +358,7 @@ static int pl031_remove(struct amba_device *adev) | |||
358 | return 0; | 358 | return 0; |
359 | } | 359 | } |
360 | 360 | ||
361 | static int pl031_probe(struct amba_device *adev, struct amba_id *id) | 361 | static int pl031_probe(struct amba_device *adev, const struct amba_id *id) |
362 | { | 362 | { |
363 | int ret; | 363 | int ret; |
364 | struct pl031_local *ldata; | 364 | struct pl031_local *ldata; |
diff --git a/drivers/spi/amba-pl022.c b/drivers/spi/amba-pl022.c index 71a1219a995d..95e58c70a2c9 100644 --- a/drivers/spi/amba-pl022.c +++ b/drivers/spi/amba-pl022.c | |||
@@ -2021,7 +2021,7 @@ static void pl022_cleanup(struct spi_device *spi) | |||
2021 | 2021 | ||
2022 | 2022 | ||
2023 | static int __devinit | 2023 | static int __devinit |
2024 | pl022_probe(struct amba_device *adev, struct amba_id *id) | 2024 | pl022_probe(struct amba_device *adev, const struct amba_id *id) |
2025 | { | 2025 | { |
2026 | struct device *dev = &adev->dev; | 2026 | struct device *dev = &adev->dev; |
2027 | struct pl022_ssp_controller *platform_info = adev->dev.platform_data; | 2027 | struct pl022_ssp_controller *platform_info = adev->dev.platform_data; |
diff --git a/drivers/tty/serial/amba-pl010.c b/drivers/tty/serial/amba-pl010.c index 2904aa044126..d742dd2c525c 100644 --- a/drivers/tty/serial/amba-pl010.c +++ b/drivers/tty/serial/amba-pl010.c | |||
@@ -676,7 +676,7 @@ static struct uart_driver amba_reg = { | |||
676 | .cons = AMBA_CONSOLE, | 676 | .cons = AMBA_CONSOLE, |
677 | }; | 677 | }; |
678 | 678 | ||
679 | static int pl010_probe(struct amba_device *dev, struct amba_id *id) | 679 | static int pl010_probe(struct amba_device *dev, const struct amba_id *id) |
680 | { | 680 | { |
681 | struct uart_amba_port *uap; | 681 | struct uart_amba_port *uap; |
682 | void __iomem *base; | 682 | void __iomem *base; |
diff --git a/drivers/tty/serial/amba-pl011.c b/drivers/tty/serial/amba-pl011.c index e76d7d000128..0dae46f91021 100644 --- a/drivers/tty/serial/amba-pl011.c +++ b/drivers/tty/serial/amba-pl011.c | |||
@@ -1349,7 +1349,7 @@ static struct uart_driver amba_reg = { | |||
1349 | .cons = AMBA_CONSOLE, | 1349 | .cons = AMBA_CONSOLE, |
1350 | }; | 1350 | }; |
1351 | 1351 | ||
1352 | static int pl011_probe(struct amba_device *dev, struct amba_id *id) | 1352 | static int pl011_probe(struct amba_device *dev, const struct amba_id *id) |
1353 | { | 1353 | { |
1354 | struct uart_amba_port *uap; | 1354 | struct uart_amba_port *uap; |
1355 | struct vendor_data *vendor = id->data; | 1355 | struct vendor_data *vendor = id->data; |
diff --git a/drivers/video/amba-clcd.c b/drivers/video/amba-clcd.c index 1c2c68356ea7..013c8ce57205 100644 --- a/drivers/video/amba-clcd.c +++ b/drivers/video/amba-clcd.c | |||
@@ -461,7 +461,7 @@ static int clcdfb_register(struct clcd_fb *fb) | |||
461 | return ret; | 461 | return ret; |
462 | } | 462 | } |
463 | 463 | ||
464 | static int clcdfb_probe(struct amba_device *dev, struct amba_id *id) | 464 | static int clcdfb_probe(struct amba_device *dev, const struct amba_id *id) |
465 | { | 465 | { |
466 | struct clcd_board *board = dev->dev.platform_data; | 466 | struct clcd_board *board = dev->dev.platform_data; |
467 | struct clcd_fb *fb; | 467 | struct clcd_fb *fb; |
diff --git a/drivers/watchdog/sp805_wdt.c b/drivers/watchdog/sp805_wdt.c index 9127eda2145b..0a0efe713bc8 100644 --- a/drivers/watchdog/sp805_wdt.c +++ b/drivers/watchdog/sp805_wdt.c | |||
@@ -278,7 +278,7 @@ static struct miscdevice sp805_wdt_miscdev = { | |||
278 | }; | 278 | }; |
279 | 279 | ||
280 | static int __devinit | 280 | static int __devinit |
281 | sp805_wdt_probe(struct amba_device *adev, struct amba_id *id) | 281 | sp805_wdt_probe(struct amba_device *adev, const struct amba_id *id) |
282 | { | 282 | { |
283 | int ret = 0; | 283 | int ret = 0; |
284 | 284 | ||