aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/arm
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2009-01-22 17:29:42 -0500
committerRussell King <rmk+kernel@arm.linux.org.uk>2009-01-24 18:21:33 -0500
commitfb22d72782b023cda5e9876d3381f30932a64f91 (patch)
tree0b5e4d15854aa11cb2554b52b67b2f7b045a03dc /drivers/net/arm
parent0b23a0efec9ab691a5bb902f9255892c8ddfd434 (diff)
[NET] am79c961a: fix spin_lock usage
spin_lock functions take a pointer to the lock, not the lock itself. This error was noticed by compiling ebsa110_defconfig for linux-rt where the locking functions obviously are more picky about their arguments. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Cc: Roel Kluin <12o3l@tiscali.nl> Cc: Steven Rostedt <srostedt@redhat.com> Cc: netdev@vger.kernel.org Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/net/arm')
-rw-r--r--drivers/net/arm/am79c961a.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/net/arm/am79c961a.c b/drivers/net/arm/am79c961a.c
index 0c628a9e5339..c2d012fcc29b 100644
--- a/drivers/net/arm/am79c961a.c
+++ b/drivers/net/arm/am79c961a.c
@@ -208,9 +208,9 @@ am79c961_init_for_open(struct net_device *dev)
208 /* 208 /*
209 * Stop the chip. 209 * Stop the chip.
210 */ 210 */
211 spin_lock_irqsave(priv->chip_lock, flags); 211 spin_lock_irqsave(&priv->chip_lock, flags);
212 write_rreg (dev->base_addr, CSR0, CSR0_BABL|CSR0_CERR|CSR0_MISS|CSR0_MERR|CSR0_TINT|CSR0_RINT|CSR0_STOP); 212 write_rreg (dev->base_addr, CSR0, CSR0_BABL|CSR0_CERR|CSR0_MISS|CSR0_MERR|CSR0_TINT|CSR0_RINT|CSR0_STOP);
213 spin_unlock_irqrestore(priv->chip_lock, flags); 213 spin_unlock_irqrestore(&priv->chip_lock, flags);
214 214
215 write_ireg (dev->base_addr, 5, 0x00a0); /* Receive address LED */ 215 write_ireg (dev->base_addr, 5, 0x00a0); /* Receive address LED */
216 write_ireg (dev->base_addr, 6, 0x0081); /* Collision LED */ 216 write_ireg (dev->base_addr, 6, 0x0081); /* Collision LED */
@@ -332,10 +332,10 @@ am79c961_close(struct net_device *dev)
332 netif_stop_queue(dev); 332 netif_stop_queue(dev);
333 netif_carrier_off(dev); 333 netif_carrier_off(dev);
334 334
335 spin_lock_irqsave(priv->chip_lock, flags); 335 spin_lock_irqsave(&priv->chip_lock, flags);
336 write_rreg (dev->base_addr, CSR0, CSR0_STOP); 336 write_rreg (dev->base_addr, CSR0, CSR0_STOP);
337 write_rreg (dev->base_addr, CSR3, CSR3_MASKALL); 337 write_rreg (dev->base_addr, CSR3, CSR3_MASKALL);
338 spin_unlock_irqrestore(priv->chip_lock, flags); 338 spin_unlock_irqrestore(&priv->chip_lock, flags);
339 339
340 free_irq (dev->irq, dev); 340 free_irq (dev->irq, dev);
341 341
@@ -391,7 +391,7 @@ static void am79c961_setmulticastlist (struct net_device *dev)
391 am79c961_mc_hash(dmi, multi_hash); 391 am79c961_mc_hash(dmi, multi_hash);
392 } 392 }
393 393
394 spin_lock_irqsave(priv->chip_lock, flags); 394 spin_lock_irqsave(&priv->chip_lock, flags);
395 395
396 stopped = read_rreg(dev->base_addr, CSR0) & CSR0_STOP; 396 stopped = read_rreg(dev->base_addr, CSR0) & CSR0_STOP;
397 397
@@ -405,9 +405,9 @@ static void am79c961_setmulticastlist (struct net_device *dev)
405 * Spin waiting for chip to report suspend mode 405 * Spin waiting for chip to report suspend mode
406 */ 406 */
407 while ((read_rreg(dev->base_addr, CTRL1) & CTRL1_SPND) == 0) { 407 while ((read_rreg(dev->base_addr, CTRL1) & CTRL1_SPND) == 0) {
408 spin_unlock_irqrestore(priv->chip_lock, flags); 408 spin_unlock_irqrestore(&priv->chip_lock, flags);
409 nop(); 409 nop();
410 spin_lock_irqsave(priv->chip_lock, flags); 410 spin_lock_irqsave(&priv->chip_lock, flags);
411 } 411 }
412 } 412 }
413 413
@@ -429,7 +429,7 @@ static void am79c961_setmulticastlist (struct net_device *dev)
429 write_rreg(dev->base_addr, CTRL1, 0); 429 write_rreg(dev->base_addr, CTRL1, 0);
430 } 430 }
431 431
432 spin_unlock_irqrestore(priv->chip_lock, flags); 432 spin_unlock_irqrestore(&priv->chip_lock, flags);
433} 433}
434 434
435static void am79c961_timeout(struct net_device *dev) 435static void am79c961_timeout(struct net_device *dev)
@@ -467,10 +467,10 @@ am79c961_sendpacket(struct sk_buff *skb, struct net_device *dev)
467 am_writeword (dev, hdraddr + 2, TMD_OWN|TMD_STP|TMD_ENP); 467 am_writeword (dev, hdraddr + 2, TMD_OWN|TMD_STP|TMD_ENP);
468 priv->txhead = head; 468 priv->txhead = head;
469 469
470 spin_lock_irqsave(priv->chip_lock, flags); 470 spin_lock_irqsave(&priv->chip_lock, flags);
471 write_rreg (dev->base_addr, CSR0, CSR0_TDMD|CSR0_IENA); 471 write_rreg (dev->base_addr, CSR0, CSR0_TDMD|CSR0_IENA);
472 dev->trans_start = jiffies; 472 dev->trans_start = jiffies;
473 spin_unlock_irqrestore(priv->chip_lock, flags); 473 spin_unlock_irqrestore(&priv->chip_lock, flags);
474 474
475 /* 475 /*
476 * If the next packet is owned by the ethernet device, 476 * If the next packet is owned by the ethernet device,