diff options
author | Joe Perches <joe@perches.com> | 2011-05-09 05:45:22 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-05-09 15:51:15 -0400 |
commit | 726b65ad444dd142e34d0087fcbba03d16b34ca6 (patch) | |
tree | ee4e56b9d7aea7dbb10ce0fe57706232f42d6b74 /drivers/net/tulip/interrupt.c | |
parent | 163ef0b5922b14751e93218bdf2c9fe8f74b9c9d (diff) |
tulip: Convert uses of KERN_DEBUG
Convert logging messages to more current styles.
Added -DDEBUG to Makefile to maintain current message logging.
This could be converted to a specific CONFIG_TULIP_DEBUG option.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tulip/interrupt.c')
-rw-r--r-- | drivers/net/tulip/interrupt.c | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/drivers/net/tulip/interrupt.c b/drivers/net/tulip/interrupt.c index 0013642903ee..5350d753e0ff 100644 --- a/drivers/net/tulip/interrupt.c +++ b/drivers/net/tulip/interrupt.c | |||
@@ -125,12 +125,12 @@ int tulip_poll(struct napi_struct *napi, int budget) | |||
125 | #endif | 125 | #endif |
126 | 126 | ||
127 | if (tulip_debug > 4) | 127 | if (tulip_debug > 4) |
128 | printk(KERN_DEBUG " In tulip_rx(), entry %d %08x\n", | 128 | netdev_dbg(dev, " In tulip_rx(), entry %d %08x\n", |
129 | entry, tp->rx_ring[entry].status); | 129 | entry, tp->rx_ring[entry].status); |
130 | 130 | ||
131 | do { | 131 | do { |
132 | if (ioread32(tp->base_addr + CSR5) == 0xffffffff) { | 132 | if (ioread32(tp->base_addr + CSR5) == 0xffffffff) { |
133 | printk(KERN_DEBUG " In tulip_poll(), hardware disappeared\n"); | 133 | netdev_dbg(dev, " In tulip_poll(), hardware disappeared\n"); |
134 | break; | 134 | break; |
135 | } | 135 | } |
136 | /* Acknowledge current RX interrupt sources. */ | 136 | /* Acknowledge current RX interrupt sources. */ |
@@ -145,9 +145,9 @@ int tulip_poll(struct napi_struct *napi, int budget) | |||
145 | if (tp->dirty_rx + RX_RING_SIZE == tp->cur_rx) | 145 | if (tp->dirty_rx + RX_RING_SIZE == tp->cur_rx) |
146 | break; | 146 | break; |
147 | 147 | ||
148 | if (tulip_debug > 5) | 148 | if (tulip_debug > 5) |
149 | printk(KERN_DEBUG "%s: In tulip_rx(), entry %d %08x\n", | 149 | netdev_dbg(dev, "In tulip_rx(), entry %d %08x\n", |
150 | dev->name, entry, status); | 150 | entry, status); |
151 | 151 | ||
152 | if (++work_done >= budget) | 152 | if (++work_done >= budget) |
153 | goto not_done; | 153 | goto not_done; |
@@ -184,9 +184,9 @@ int tulip_poll(struct napi_struct *napi, int budget) | |||
184 | } | 184 | } |
185 | } else { | 185 | } else { |
186 | /* There was a fatal error. */ | 186 | /* There was a fatal error. */ |
187 | if (tulip_debug > 2) | 187 | if (tulip_debug > 2) |
188 | printk(KERN_DEBUG "%s: Receive error, Rx status %08x\n", | 188 | netdev_dbg(dev, "Receive error, Rx status %08x\n", |
189 | dev->name, status); | 189 | status); |
190 | dev->stats.rx_errors++; /* end of a packet.*/ | 190 | dev->stats.rx_errors++; /* end of a packet.*/ |
191 | if (pkt_len > 1518 || | 191 | if (pkt_len > 1518 || |
192 | (status & RxDescRunt)) | 192 | (status & RxDescRunt)) |
@@ -367,16 +367,16 @@ static int tulip_rx(struct net_device *dev) | |||
367 | int received = 0; | 367 | int received = 0; |
368 | 368 | ||
369 | if (tulip_debug > 4) | 369 | if (tulip_debug > 4) |
370 | printk(KERN_DEBUG " In tulip_rx(), entry %d %08x\n", | 370 | netdev_dbg(dev, "In tulip_rx(), entry %d %08x\n", |
371 | entry, tp->rx_ring[entry].status); | 371 | entry, tp->rx_ring[entry].status); |
372 | /* If we own the next entry, it is a new packet. Send it up. */ | 372 | /* If we own the next entry, it is a new packet. Send it up. */ |
373 | while ( ! (tp->rx_ring[entry].status & cpu_to_le32(DescOwned))) { | 373 | while ( ! (tp->rx_ring[entry].status & cpu_to_le32(DescOwned))) { |
374 | s32 status = le32_to_cpu(tp->rx_ring[entry].status); | 374 | s32 status = le32_to_cpu(tp->rx_ring[entry].status); |
375 | short pkt_len; | 375 | short pkt_len; |
376 | 376 | ||
377 | if (tulip_debug > 5) | 377 | if (tulip_debug > 5) |
378 | printk(KERN_DEBUG "%s: In tulip_rx(), entry %d %08x\n", | 378 | netdev_dbg(dev, "In tulip_rx(), entry %d %08x\n", |
379 | dev->name, entry, status); | 379 | entry, status); |
380 | if (--rx_work_limit < 0) | 380 | if (--rx_work_limit < 0) |
381 | break; | 381 | break; |
382 | 382 | ||
@@ -404,16 +404,16 @@ static int tulip_rx(struct net_device *dev) | |||
404 | /* Ingore earlier buffers. */ | 404 | /* Ingore earlier buffers. */ |
405 | if ((status & 0xffff) != 0x7fff) { | 405 | if ((status & 0xffff) != 0x7fff) { |
406 | if (tulip_debug > 1) | 406 | if (tulip_debug > 1) |
407 | dev_warn(&dev->dev, | 407 | netdev_warn(dev, |
408 | "Oversized Ethernet frame spanned multiple buffers, status %08x!\n", | 408 | "Oversized Ethernet frame spanned multiple buffers, status %08x!\n", |
409 | status); | 409 | status); |
410 | dev->stats.rx_length_errors++; | 410 | dev->stats.rx_length_errors++; |
411 | } | 411 | } |
412 | } else { | 412 | } else { |
413 | /* There was a fatal error. */ | 413 | /* There was a fatal error. */ |
414 | if (tulip_debug > 2) | 414 | if (tulip_debug > 2) |
415 | printk(KERN_DEBUG "%s: Receive error, Rx status %08x\n", | 415 | netdev_dbg(dev, "Receive error, Rx status %08x\n", |
416 | dev->name, status); | 416 | status); |
417 | dev->stats.rx_errors++; /* end of a packet.*/ | 417 | dev->stats.rx_errors++; /* end of a packet.*/ |
418 | if (pkt_len > 1518 || | 418 | if (pkt_len > 1518 || |
419 | (status & RxDescRunt)) | 419 | (status & RxDescRunt)) |
@@ -573,8 +573,8 @@ irqreturn_t tulip_interrupt(int irq, void *dev_instance) | |||
573 | #endif /* CONFIG_TULIP_NAPI */ | 573 | #endif /* CONFIG_TULIP_NAPI */ |
574 | 574 | ||
575 | if (tulip_debug > 4) | 575 | if (tulip_debug > 4) |
576 | printk(KERN_DEBUG "%s: interrupt csr5=%#8.8x new csr5=%#8.8x\n", | 576 | netdev_dbg(dev, "interrupt csr5=%#8.8x new csr5=%#8.8x\n", |
577 | dev->name, csr5, ioread32(ioaddr + CSR5)); | 577 | csr5, ioread32(ioaddr + CSR5)); |
578 | 578 | ||
579 | 579 | ||
580 | if (csr5 & (TxNoBuf | TxDied | TxIntr | TimerInt)) { | 580 | if (csr5 & (TxNoBuf | TxDied | TxIntr | TimerInt)) { |
@@ -605,8 +605,8 @@ irqreturn_t tulip_interrupt(int irq, void *dev_instance) | |||
605 | /* There was an major error, log it. */ | 605 | /* There was an major error, log it. */ |
606 | #ifndef final_version | 606 | #ifndef final_version |
607 | if (tulip_debug > 1) | 607 | if (tulip_debug > 1) |
608 | printk(KERN_DEBUG "%s: Transmit error, Tx status %08x\n", | 608 | netdev_dbg(dev, "Transmit error, Tx status %08x\n", |
609 | dev->name, status); | 609 | status); |
610 | #endif | 610 | #endif |
611 | dev->stats.tx_errors++; | 611 | dev->stats.tx_errors++; |
612 | if (status & 0x4104) | 612 | if (status & 0x4104) |
@@ -804,8 +804,8 @@ irqreturn_t tulip_interrupt(int irq, void *dev_instance) | |||
804 | } | 804 | } |
805 | 805 | ||
806 | if (tulip_debug > 4) | 806 | if (tulip_debug > 4) |
807 | printk(KERN_DEBUG "%s: exiting interrupt, csr5=%#04x\n", | 807 | netdev_dbg(dev, "exiting interrupt, csr5=%#04x\n", |
808 | dev->name, ioread32(ioaddr + CSR5)); | 808 | ioread32(ioaddr + CSR5)); |
809 | 809 | ||
810 | return IRQ_HANDLED; | 810 | return IRQ_HANDLED; |
811 | } | 811 | } |