Patchwork [2/3] net: phy: mdio: add missing __iomem annotation

login
register
mail settings
Submitter Jingoo Han
Date Aug. 6, 2013, 8:32 a.m.
Message ID <000201ce927f$8e339490$aa9abdb0$@samsung.com>
Download mbox | patch
Permalink /patch/264910/
State Accepted
Delegated to: David Miller
Headers show

Comments

Jingoo Han - Aug. 6, 2013, 8:32 a.m.
Added missing __iomem annotation in order to fix the following
sparse warnings:

drivers/net/phy/mdio-mux-mmioreg.c:51:27: warning: incorrect type in initializer (different address spaces)
drivers/net/phy/mdio-mux-mmioreg.c:51:27:    expected void *p
drivers/net/phy/mdio-mux-mmioreg.c:51:27:    got void [noderef] <asn:2>*
drivers/net/phy/mdio-mux-mmioreg.c:57:21: warning: incorrect type in argument 1 (different address spaces)
drivers/net/phy/mdio-mux-mmioreg.c:57:21:    expected void const volatile [noderef] <asn:2>*addr
drivers/net/phy/mdio-mux-mmioreg.c:57:21:    got void *p
drivers/net/phy/mdio-mux-mmioreg.c:60:25: warning: incorrect type in argument 2 (different address spaces)
drivers/net/phy/mdio-mux-mmioreg.c:60:25:    expected void volatile [noderef] <asn:2>*addr
drivers/net/phy/mdio-mux-mmioreg.c:60:25:    got void *p
drivers/net/phy/mdio-mux-mmioreg.c:64:25: warning: incorrect type in argument 1 (different address spaces)
drivers/net/phy/mdio-mux-mmioreg.c:64:25:    expected void volatile [noderef] <asn:2>*addr
drivers/net/phy/mdio-mux-mmioreg.c:64:25:    got void *p

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
 drivers/net/phy/mdio-mux-mmioreg.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
David Miller - Aug. 7, 2013, 11:59 p.m.
From: Jingoo Han <jg1.han@samsung.com>
Date: Tue, 06 Aug 2013 17:32:58 +0900

> Added missing __iomem annotation in order to fix the following
> sparse warnings:
> 
> drivers/net/phy/mdio-mux-mmioreg.c:51:27: warning: incorrect type in initializer (different address spaces)
> drivers/net/phy/mdio-mux-mmioreg.c:51:27:    expected void *p
> drivers/net/phy/mdio-mux-mmioreg.c:51:27:    got void [noderef] <asn:2>*
> drivers/net/phy/mdio-mux-mmioreg.c:57:21: warning: incorrect type in argument 1 (different address spaces)
> drivers/net/phy/mdio-mux-mmioreg.c:57:21:    expected void const volatile [noderef] <asn:2>*addr
> drivers/net/phy/mdio-mux-mmioreg.c:57:21:    got void *p
> drivers/net/phy/mdio-mux-mmioreg.c:60:25: warning: incorrect type in argument 2 (different address spaces)
> drivers/net/phy/mdio-mux-mmioreg.c:60:25:    expected void volatile [noderef] <asn:2>*addr
> drivers/net/phy/mdio-mux-mmioreg.c:60:25:    got void *p
> drivers/net/phy/mdio-mux-mmioreg.c:64:25: warning: incorrect type in argument 1 (different address spaces)
> drivers/net/phy/mdio-mux-mmioreg.c:64:25:    expected void volatile [noderef] <asn:2>*addr
> drivers/net/phy/mdio-mux-mmioreg.c:64:25:    got void *p
> 
> Signed-off-by: Jingoo Han <jg1.han@samsung.com>

Applied.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/drivers/net/phy/mdio-mux-mmioreg.c b/drivers/net/phy/mdio-mux-mmioreg.c
index 9733bd2..f8e305d 100644
--- a/drivers/net/phy/mdio-mux-mmioreg.c
+++ b/drivers/net/phy/mdio-mux-mmioreg.c
@@ -48,7 +48,7 @@  static int mdio_mux_mmioreg_switch_fn(int current_child, int desired_child,
 	struct mdio_mux_mmioreg_state *s = data;
 
 	if (current_child ^ desired_child) {
-		void *p = ioremap(s->phys, 1);
+		void __iomem *p = ioremap(s->phys, 1);
 		uint8_t x, y;
 
 		if (!p)