summaryrefslogtreecommitdiffstats
path: root/drivers/net/wan
diff options
context:
space:
mode:
authorJeff Garzik <jeff@garzik.org>2007-10-29 05:46:16 -0400
committerDavid S. Miller <davem@davemloft.net>2008-01-28 15:03:40 -0800
commit28fc1f5a0c375cb6375fa48e9a8b393f2a189be6 (patch)
tree95b3b517b02dd46ff0fc2728c1e70de8d6f78ed3 /drivers/net/wan
parent1b36efe07f83ecf50eddd431d067c7bf86318e87 (diff)
[netdrvr] irq handler minor cleanups in several drivers
* use irq_handler_t where appropriate * no need to use 'irq' function arg, its already stored in a data struct * rename irq handler 'irq' argument to 'dummy', where the function has been analyzed and proven not to use its first argument. * remove always-false "dev_id == NULL" test from irq handlers * remove pointless casts from void* * declance: irq argument is not const * add KERN_xxx printk prefix * fix minor whitespace weirdness Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/net/wan')
-rw-r--r--drivers/net/wan/farsync.c11
-rw-r--r--drivers/net/wan/sdla.c5
2 files changed, 6 insertions, 10 deletions
diff --git a/drivers/net/wan/farsync.c b/drivers/net/wan/farsync.c
index 12dae8e2484..cf27bf40d36 100644
--- a/drivers/net/wan/farsync.c
+++ b/drivers/net/wan/farsync.c
@@ -1498,9 +1498,9 @@ do_bottom_half_rx(struct fst_card_info *card)
* Dev_id is our fst_card_info pointer
*/
static irqreturn_t
-fst_intr(int irq, void *dev_id)
+fst_intr(int dummy, void *dev_id)
{
- struct fst_card_info *card;
+ struct fst_card_info *card = dev_id;
struct fst_port_info *port;
int rdidx; /* Event buffer indices */
int wridx;
@@ -1509,17 +1509,12 @@ fst_intr(int irq, void *dev_id)
unsigned int do_card_interrupt;
unsigned int int_retry_count;
- if ((card = dev_id) == NULL) {
- dbg(DBG_INTR, "intr: spurious %d\n", irq);
- return IRQ_NONE;
- }
-
/*
* Check to see if the interrupt was for this card
* return if not
* Note that the call to clear the interrupt is important
*/
- dbg(DBG_INTR, "intr: %d %p\n", irq, card);
+ dbg(DBG_INTR, "intr: %d %p\n", card->irq, card);
if (card->state != FST_RUNNING) {
printk_err
("Interrupt received for card %d in a non running state (%d)\n",
diff --git a/drivers/net/wan/sdla.c b/drivers/net/wan/sdla.c
index 05df0a345b6..73e2f278093 100644
--- a/drivers/net/wan/sdla.c
+++ b/drivers/net/wan/sdla.c
@@ -867,7 +867,7 @@ static void sdla_receive(struct net_device *dev)
spin_unlock_irqrestore(&sdla_lock, flags);
}
-static irqreturn_t sdla_isr(int irq, void *dev_id)
+static irqreturn_t sdla_isr(int dummy, void *dev_id)
{
struct net_device *dev;
struct frad_local *flp;
@@ -879,7 +879,8 @@ static irqreturn_t sdla_isr(int irq, void *dev_id)
if (!flp->initialized)
{
- printk(KERN_WARNING "%s: irq %d for uninitialized device.\n", dev->name, irq);
+ printk(KERN_WARNING "%s: irq %d for uninitialized device.\n",
+ dev->name, dev->irq);
return IRQ_NONE;
}