aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/hp-plus.c
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2007-10-03 20:59:30 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 19:51:42 -0400
commit0795af5729b18218767fab27c44b1384f72dc9ad (patch)
tree67c16df84aa6ec219340b8ea1b5cfb0e8150a216 /drivers/net/hp-plus.c
parent95ea36275f3c9a1d3d04c217b4b576c657c4e70e (diff)
[NET]: Introduce and use print_mac() and DECLARE_MAC_BUF()
This is nicer than the MAC_FMT stuff. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/hp-plus.c')
-rw-r--r--drivers/net/hp-plus.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/net/hp-plus.c b/drivers/net/hp-plus.c
index 8d4f810fa288..c2c4f49d7578 100644
--- a/drivers/net/hp-plus.c
+++ b/drivers/net/hp-plus.c
@@ -166,6 +166,7 @@ static int __init hpp_probe1(struct net_device *dev, int ioaddr)
166 const char name[] = "HP-PC-LAN+"; 166 const char name[] = "HP-PC-LAN+";
167 int mem_start; 167 int mem_start;
168 static unsigned version_printed; 168 static unsigned version_printed;
169 DECLARE_MAC_BUF(mac);
169 170
170 if (!request_region(ioaddr, HP_IO_EXTENT, DRV_NAME)) 171 if (!request_region(ioaddr, HP_IO_EXTENT, DRV_NAME))
171 return -EBUSY; 172 return -EBUSY;
@@ -180,7 +181,7 @@ static int __init hpp_probe1(struct net_device *dev, int ioaddr)
180 if (ei_debug && version_printed++ == 0) 181 if (ei_debug && version_printed++ == 0)
181 printk(version); 182 printk(version);
182 183
183 printk("%s: %s at %#3x,", dev->name, name, ioaddr); 184 printk("%s: %s at %#3x, ", dev->name, name, ioaddr);
184 185
185 /* Retrieve and checksum the station address. */ 186 /* Retrieve and checksum the station address. */
186 outw(MAC_Page, ioaddr + HP_PAGING); 187 outw(MAC_Page, ioaddr + HP_PAGING);
@@ -189,10 +190,11 @@ static int __init hpp_probe1(struct net_device *dev, int ioaddr)
189 unsigned char inval = inb(ioaddr + 8 + i); 190 unsigned char inval = inb(ioaddr + 8 + i);
190 dev->dev_addr[i] = inval; 191 dev->dev_addr[i] = inval;
191 checksum += inval; 192 checksum += inval;
192 printk(" %2.2x", inval);
193 } 193 }
194 checksum += inb(ioaddr + 14); 194 checksum += inb(ioaddr + 14);
195 195
196 printk("%s", print_mac(mac, dev->dev_addr));
197
196 if (checksum != 0xff) { 198 if (checksum != 0xff) {
197 printk(" bad checksum %2.2x.\n", checksum); 199 printk(" bad checksum %2.2x.\n", checksum);
198 retval = -ENODEV; 200 retval = -ENODEV;