diff options
author | Scott Wood <scottwood@freescale.com> | 2007-10-01 15:20:58 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-10-10 19:54:04 -0400 |
commit | 31a5bb04d59931eb4657826213a439d37d12d4a9 (patch) | |
tree | 865af87dcb382e4cf035c9ccf5bf3ea094f2a712 /drivers/net/fs_enet/mac-fec.c | |
parent | 2b5b3a604a672be1d41728ed9e448ca3c9c23242 (diff) |
fs_enet: sparse fixes
Mostly a bunch of __iomem annotations.
Signed-off-by: Scott Wood <scottwood@freescale.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/fs_enet/mac-fec.c')
-rw-r--r-- | drivers/net/fs_enet/mac-fec.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/drivers/net/fs_enet/mac-fec.c b/drivers/net/fs_enet/mac-fec.c index 924d6617cd30..c1fee48517e3 100644 --- a/drivers/net/fs_enet/mac-fec.c +++ b/drivers/net/fs_enet/mac-fec.c | |||
@@ -83,7 +83,7 @@ | |||
83 | */ | 83 | */ |
84 | #define FEC_RESET_DELAY 50 | 84 | #define FEC_RESET_DELAY 50 |
85 | 85 | ||
86 | static int whack_reset(fec_t * fecp) | 86 | static int whack_reset(fec_t __iomem *fecp) |
87 | { | 87 | { |
88 | int i; | 88 | int i; |
89 | 89 | ||
@@ -159,7 +159,7 @@ static int allocate_bd(struct net_device *dev) | |||
159 | struct fs_enet_private *fep = netdev_priv(dev); | 159 | struct fs_enet_private *fep = netdev_priv(dev); |
160 | const struct fs_platform_info *fpi = fep->fpi; | 160 | const struct fs_platform_info *fpi = fep->fpi; |
161 | 161 | ||
162 | fep->ring_base = dma_alloc_coherent(fep->dev, | 162 | fep->ring_base = (void __force __iomem *)dma_alloc_coherent(fep->dev, |
163 | (fpi->tx_ring + fpi->rx_ring) * | 163 | (fpi->tx_ring + fpi->rx_ring) * |
164 | sizeof(cbd_t), &fep->ring_mem_addr, | 164 | sizeof(cbd_t), &fep->ring_mem_addr, |
165 | GFP_KERNEL); | 165 | GFP_KERNEL); |
@@ -177,7 +177,7 @@ static void free_bd(struct net_device *dev) | |||
177 | if(fep->ring_base) | 177 | if(fep->ring_base) |
178 | dma_free_coherent(fep->dev, (fpi->tx_ring + fpi->rx_ring) | 178 | dma_free_coherent(fep->dev, (fpi->tx_ring + fpi->rx_ring) |
179 | * sizeof(cbd_t), | 179 | * sizeof(cbd_t), |
180 | fep->ring_base, | 180 | (void __force *)fep->ring_base, |
181 | fep->ring_mem_addr); | 181 | fep->ring_mem_addr); |
182 | } | 182 | } |
183 | 183 | ||
@@ -189,7 +189,7 @@ static void cleanup_data(struct net_device *dev) | |||
189 | static void set_promiscuous_mode(struct net_device *dev) | 189 | static void set_promiscuous_mode(struct net_device *dev) |
190 | { | 190 | { |
191 | struct fs_enet_private *fep = netdev_priv(dev); | 191 | struct fs_enet_private *fep = netdev_priv(dev); |
192 | fec_t *fecp = fep->fec.fecp; | 192 | fec_t __iomem *fecp = fep->fec.fecp; |
193 | 193 | ||
194 | FS(fecp, r_cntrl, FEC_RCNTRL_PROM); | 194 | FS(fecp, r_cntrl, FEC_RCNTRL_PROM); |
195 | } | 195 | } |
@@ -237,7 +237,7 @@ static void set_multicast_one(struct net_device *dev, const u8 *mac) | |||
237 | static void set_multicast_finish(struct net_device *dev) | 237 | static void set_multicast_finish(struct net_device *dev) |
238 | { | 238 | { |
239 | struct fs_enet_private *fep = netdev_priv(dev); | 239 | struct fs_enet_private *fep = netdev_priv(dev); |
240 | fec_t *fecp = fep->fec.fecp; | 240 | fec_t __iomem *fecp = fep->fec.fecp; |
241 | 241 | ||
242 | /* if all multi or too many multicasts; just enable all */ | 242 | /* if all multi or too many multicasts; just enable all */ |
243 | if ((dev->flags & IFF_ALLMULTI) != 0 || | 243 | if ((dev->flags & IFF_ALLMULTI) != 0 || |
@@ -271,7 +271,7 @@ static void restart(struct net_device *dev) | |||
271 | u32 cptr; | 271 | u32 cptr; |
272 | #endif | 272 | #endif |
273 | struct fs_enet_private *fep = netdev_priv(dev); | 273 | struct fs_enet_private *fep = netdev_priv(dev); |
274 | fec_t *fecp = fep->fec.fecp; | 274 | fec_t __iomem *fecp = fep->fec.fecp; |
275 | const struct fs_platform_info *fpi = fep->fpi; | 275 | const struct fs_platform_info *fpi = fep->fpi; |
276 | dma_addr_t rx_bd_base_phys, tx_bd_base_phys; | 276 | dma_addr_t rx_bd_base_phys, tx_bd_base_phys; |
277 | int r; | 277 | int r; |
@@ -399,7 +399,7 @@ static void stop(struct net_device *dev) | |||
399 | { | 399 | { |
400 | struct fs_enet_private *fep = netdev_priv(dev); | 400 | struct fs_enet_private *fep = netdev_priv(dev); |
401 | const struct fs_platform_info *fpi = fep->fpi; | 401 | const struct fs_platform_info *fpi = fep->fpi; |
402 | fec_t *fecp = fep->fec.fecp; | 402 | fec_t __iomem *fecp = fep->fec.fecp; |
403 | 403 | ||
404 | struct fec_info* feci= fep->phydev->bus->priv; | 404 | struct fec_info* feci= fep->phydev->bus->priv; |
405 | 405 | ||
@@ -461,7 +461,7 @@ static void post_free_irq(struct net_device *dev, int irq) | |||
461 | static void napi_clear_rx_event(struct net_device *dev) | 461 | static void napi_clear_rx_event(struct net_device *dev) |
462 | { | 462 | { |
463 | struct fs_enet_private *fep = netdev_priv(dev); | 463 | struct fs_enet_private *fep = netdev_priv(dev); |
464 | fec_t *fecp = fep->fec.fecp; | 464 | fec_t __iomem *fecp = fep->fec.fecp; |
465 | 465 | ||
466 | FW(fecp, ievent, FEC_NAPI_RX_EVENT_MSK); | 466 | FW(fecp, ievent, FEC_NAPI_RX_EVENT_MSK); |
467 | } | 467 | } |
@@ -469,7 +469,7 @@ static void napi_clear_rx_event(struct net_device *dev) | |||
469 | static void napi_enable_rx(struct net_device *dev) | 469 | static void napi_enable_rx(struct net_device *dev) |
470 | { | 470 | { |
471 | struct fs_enet_private *fep = netdev_priv(dev); | 471 | struct fs_enet_private *fep = netdev_priv(dev); |
472 | fec_t *fecp = fep->fec.fecp; | 472 | fec_t __iomem *fecp = fep->fec.fecp; |
473 | 473 | ||
474 | FS(fecp, imask, FEC_NAPI_RX_EVENT_MSK); | 474 | FS(fecp, imask, FEC_NAPI_RX_EVENT_MSK); |
475 | } | 475 | } |
@@ -477,7 +477,7 @@ static void napi_enable_rx(struct net_device *dev) | |||
477 | static void napi_disable_rx(struct net_device *dev) | 477 | static void napi_disable_rx(struct net_device *dev) |
478 | { | 478 | { |
479 | struct fs_enet_private *fep = netdev_priv(dev); | 479 | struct fs_enet_private *fep = netdev_priv(dev); |
480 | fec_t *fecp = fep->fec.fecp; | 480 | fec_t __iomem *fecp = fep->fec.fecp; |
481 | 481 | ||
482 | FC(fecp, imask, FEC_NAPI_RX_EVENT_MSK); | 482 | FC(fecp, imask, FEC_NAPI_RX_EVENT_MSK); |
483 | } | 483 | } |
@@ -485,7 +485,7 @@ static void napi_disable_rx(struct net_device *dev) | |||
485 | static void rx_bd_done(struct net_device *dev) | 485 | static void rx_bd_done(struct net_device *dev) |
486 | { | 486 | { |
487 | struct fs_enet_private *fep = netdev_priv(dev); | 487 | struct fs_enet_private *fep = netdev_priv(dev); |
488 | fec_t *fecp = fep->fec.fecp; | 488 | fec_t __iomem *fecp = fep->fec.fecp; |
489 | 489 | ||
490 | FW(fecp, r_des_active, 0x01000000); | 490 | FW(fecp, r_des_active, 0x01000000); |
491 | } | 491 | } |
@@ -493,7 +493,7 @@ static void rx_bd_done(struct net_device *dev) | |||
493 | static void tx_kickstart(struct net_device *dev) | 493 | static void tx_kickstart(struct net_device *dev) |
494 | { | 494 | { |
495 | struct fs_enet_private *fep = netdev_priv(dev); | 495 | struct fs_enet_private *fep = netdev_priv(dev); |
496 | fec_t *fecp = fep->fec.fecp; | 496 | fec_t __iomem *fecp = fep->fec.fecp; |
497 | 497 | ||
498 | FW(fecp, x_des_active, 0x01000000); | 498 | FW(fecp, x_des_active, 0x01000000); |
499 | } | 499 | } |
@@ -501,7 +501,7 @@ static void tx_kickstart(struct net_device *dev) | |||
501 | static u32 get_int_events(struct net_device *dev) | 501 | static u32 get_int_events(struct net_device *dev) |
502 | { | 502 | { |
503 | struct fs_enet_private *fep = netdev_priv(dev); | 503 | struct fs_enet_private *fep = netdev_priv(dev); |
504 | fec_t *fecp = fep->fec.fecp; | 504 | fec_t __iomem *fecp = fep->fec.fecp; |
505 | 505 | ||
506 | return FR(fecp, ievent) & FR(fecp, imask); | 506 | return FR(fecp, ievent) & FR(fecp, imask); |
507 | } | 507 | } |
@@ -509,7 +509,7 @@ static u32 get_int_events(struct net_device *dev) | |||
509 | static void clear_int_events(struct net_device *dev, u32 int_events) | 509 | static void clear_int_events(struct net_device *dev, u32 int_events) |
510 | { | 510 | { |
511 | struct fs_enet_private *fep = netdev_priv(dev); | 511 | struct fs_enet_private *fep = netdev_priv(dev); |
512 | fec_t *fecp = fep->fec.fecp; | 512 | fec_t __iomem *fecp = fep->fec.fecp; |
513 | 513 | ||
514 | FW(fecp, ievent, int_events); | 514 | FW(fecp, ievent, int_events); |
515 | } | 515 | } |
@@ -520,7 +520,7 @@ static void ev_error(struct net_device *dev, u32 int_events) | |||
520 | ": %s FEC ERROR(s) 0x%x\n", dev->name, int_events); | 520 | ": %s FEC ERROR(s) 0x%x\n", dev->name, int_events); |
521 | } | 521 | } |
522 | 522 | ||
523 | int get_regs(struct net_device *dev, void *p, int *sizep) | 523 | static int get_regs(struct net_device *dev, void *p, int *sizep) |
524 | { | 524 | { |
525 | struct fs_enet_private *fep = netdev_priv(dev); | 525 | struct fs_enet_private *fep = netdev_priv(dev); |
526 | 526 | ||
@@ -532,12 +532,12 @@ int get_regs(struct net_device *dev, void *p, int *sizep) | |||
532 | return 0; | 532 | return 0; |
533 | } | 533 | } |
534 | 534 | ||
535 | int get_regs_len(struct net_device *dev) | 535 | static int get_regs_len(struct net_device *dev) |
536 | { | 536 | { |
537 | return sizeof(fec_t); | 537 | return sizeof(fec_t); |
538 | } | 538 | } |
539 | 539 | ||
540 | void tx_restart(struct net_device *dev) | 540 | static void tx_restart(struct net_device *dev) |
541 | { | 541 | { |
542 | /* nothing */ | 542 | /* nothing */ |
543 | } | 543 | } |