diff options
author | Alexander Beregalov <a.beregalov@gmail.com> | 2009-05-26 12:35:26 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-05-26 20:35:03 -0700 |
commit | 39738e161f7315bfa8f31a91d2262f93d818a7cd (patch) | |
tree | 97777f397e4b2ef76a44d8eb539b2c3e39718337 /drivers/net/3c527.c | |
parent | 646cdb32831eebe8c2f742c293d0d266326854d9 (diff) | |
download | op-kernel-dev-39738e161f7315bfa8f31a91d2262f93d818a7cd.zip op-kernel-dev-39738e161f7315bfa8f31a91d2262f93d818a7cd.tar.gz |
3c5xx: convert printk() to pr_<foo>()
Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/3c527.c')
-rw-r--r-- | drivers/net/3c527.c | 46 |
1 files changed, 21 insertions, 25 deletions
diff --git a/drivers/net/3c527.c b/drivers/net/3c527.c index b61073c..c10ca30 100644 --- a/drivers/net/3c527.c +++ b/drivers/net/3c527.c @@ -125,8 +125,6 @@ static const char* cardname = DRV_NAME; #define NET_DEBUG 2 #endif -#undef DEBUG_IRQ - static unsigned int mc32_debug = NET_DEBUG; /* The number of low I/O ports used by the ethercard. */ @@ -351,15 +349,15 @@ static int __init mc32_probe1(struct net_device *dev, int slot) /* Time to play MCA games */ if (mc32_debug && version_printed++ == 0) - printk(KERN_DEBUG "%s", version); + pr_debug("%s", version); - printk(KERN_INFO "%s: %s found in slot %d:", dev->name, cardname, slot); + pr_info("%s: %s found in slot %d: ", dev->name, cardname, slot); POS = mca_read_stored_pos(slot, 2); if(!(POS&1)) { - printk(" disabled.\n"); + pr_cont("disabled.\n"); return -ENODEV; } @@ -370,7 +368,7 @@ static int __init mc32_probe1(struct net_device *dev, int slot) POS = mca_read_stored_pos(slot, 4); if(!(POS&1)) { - printk("memory window disabled.\n"); + pr_cont("memory window disabled.\n"); return -ENODEV; } @@ -379,7 +377,7 @@ static int __init mc32_probe1(struct net_device *dev, int slot) i=(POS>>4)&3; if(i==3) { - printk("invalid memory window.\n"); + pr_cont("invalid memory window.\n"); return -ENODEV; } @@ -392,11 +390,11 @@ static int __init mc32_probe1(struct net_device *dev, int slot) if(!request_region(dev->base_addr, MC32_IO_EXTENT, cardname)) { - printk("io 0x%3lX, which is busy.\n", dev->base_addr); + pr_cont("io 0x%3lX, which is busy.\n", dev->base_addr); return -EBUSY; } - printk("io 0x%3lX irq %d mem 0x%lX (%dK)\n", + pr_cont("io 0x%3lX irq %d mem 0x%lX (%dK)\n", dev->base_addr, dev->irq, dev->mem_start, i/1024); @@ -416,7 +414,7 @@ static int __init mc32_probe1(struct net_device *dev, int slot) dev->dev_addr[i] = mca_read_pos(slot,3); } - printk("%s: Address %pM", dev->name, dev->dev_addr); + pr_info("%s: Address %pM ", dev->name, dev->dev_addr); mca_write_pos(slot, 6, 0); mca_write_pos(slot, 7, 0); @@ -424,9 +422,9 @@ static int __init mc32_probe1(struct net_device *dev, int slot) POS = mca_read_stored_pos(slot, 4); if(POS&2) - printk(" : BNC port selected.\n"); + pr_cont(": BNC port selected.\n"); else - printk(" : AUI port selected.\n"); + pr_cont(": AUI port selected.\n"); POS=inb(dev->base_addr+HOST_CTRL); POS|=HOST_CTRL_ATTN|HOST_CTRL_RESET; @@ -447,7 +445,7 @@ static int __init mc32_probe1(struct net_device *dev, int slot) err = request_irq(dev->irq, &mc32_interrupt, IRQF_SHARED | IRQF_SAMPLE_RANDOM, DRV_NAME, dev); if (err) { release_region(dev->base_addr, MC32_IO_EXTENT); - printk(KERN_ERR "%s: unable to get IRQ %d.\n", DRV_NAME, dev->irq); + pr_err("%s: unable to get IRQ %d.\n", DRV_NAME, dev->irq); goto err_exit_ports; } @@ -463,7 +461,7 @@ static int __init mc32_probe1(struct net_device *dev, int slot) i++; if(i == 1000) { - printk(KERN_ERR "%s: failed to boot adapter.\n", dev->name); + pr_err("%s: failed to boot adapter.\n", dev->name); err = -ENODEV; goto err_exit_irq; } @@ -475,10 +473,10 @@ static int __init mc32_probe1(struct net_device *dev, int slot) if(base>0) { if(base < 0x0C) - printk(KERN_ERR "%s: %s%s.\n", dev->name, failures[base-1], + pr_err("%s: %s%s.\n", dev->name, failures[base-1], base<0x0A?" test failure":""); else - printk(KERN_ERR "%s: unknown failure %d.\n", dev->name, base); + pr_err("%s: unknown failure %d.\n", dev->name, base); err = -ENODEV; goto err_exit_irq; } @@ -494,7 +492,7 @@ static int __init mc32_probe1(struct net_device *dev, int slot) udelay(50); if(n>100) { - printk(KERN_ERR "%s: mailbox read fail (%d).\n", dev->name, i); + pr_err("%s: mailbox read fail (%d).\n", dev->name, i); err = -ENODEV; goto err_exit_irq; } @@ -527,7 +525,7 @@ static int __init mc32_probe1(struct net_device *dev, int slot) init_completion(&lp->execution_cmd); init_completion(&lp->xceiver_cmd); - printk("%s: Firmware Rev %d. %d RX buffers, %d TX buffers. Base of 0x%08X.\n", + pr_info("%s: Firmware Rev %d. %d RX buffers, %d TX buffers. Base of 0x%08X.\n", dev->name, lp->exec_box->data[12], lp->rx_len, lp->tx_len, lp->base); dev->netdev_ops = &netdev_ops; @@ -939,7 +937,7 @@ static int mc32_open(struct net_device *dev) */ if(mc32_command(dev, 8, descnumbuffs, 4)) { - printk("%s: %s rejected our buffer configuration!\n", + pr_info("%s: %s rejected our buffer configuration!\n", dev->name, cardname); mc32_close(dev); return -ENOBUFS; @@ -995,7 +993,7 @@ static int mc32_open(struct net_device *dev) static void mc32_timeout(struct net_device *dev) { - printk(KERN_WARNING "%s: transmit timed out?\n", dev->name); + pr_warning("%s: transmit timed out?\n", dev->name); /* Try to restart the adaptor. */ netif_wake_queue(dev); } @@ -1335,11 +1333,9 @@ static irqreturn_t mc32_interrupt(int irq, void *dev_id) { status=inb(ioaddr+HOST_CMD); -#ifdef DEBUG_IRQ - printk("Status TX%d RX%d EX%d OV%d BC%d\n", + pr_debug("Status TX%d RX%d EX%d OV%d BC%d\n", (status&7), (status>>3)&7, (status>>6)&1, (status>>7)&1, boguscount); -#endif switch(status&7) { @@ -1354,7 +1350,7 @@ static irqreturn_t mc32_interrupt(int irq, void *dev_id) complete(&lp->xceiver_cmd); break; default: - printk("%s: strange tx ack %d\n", dev->name, status&7); + pr_notice("%s: strange tx ack %d\n", dev->name, status&7); } status>>=3; switch(status&7) @@ -1376,7 +1372,7 @@ static irqreturn_t mc32_interrupt(int irq, void *dev_id) mc32_start_transceiver(dev); break; default: - printk("%s: strange rx ack %d\n", + pr_notice("%s: strange rx ack %d\n", dev->name, status&7); } status>>=3; |