X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=drivers%2Fnet%2Fhp-plus.c;h=8239939554bc4474735fb174c8f6f02da9957180;hb=e2e3c57b271d74ed8fd4d378f1517525ef7e5921;hp=e26a3e407d706d941c2c3f758747b8270289802d;hpb=2a2ed2db353d949c06b6ef8b6913f65b39111eab;p=linux-2.6 diff --git a/drivers/net/hp-plus.c b/drivers/net/hp-plus.c index e26a3e407d..8239939554 100644 --- a/drivers/net/hp-plus.c +++ b/drivers/net/hp-plus.c @@ -112,7 +112,7 @@ static void hpp_io_block_output(struct net_device *dev, int count, static void hpp_io_get_8390_hdr(struct net_device *dev, struct e8390_pkt_hdr *hdr, int ring_page); - + /* Probe a list of addresses for an HP LAN+ adaptor. This routine is almost boilerplate. */ @@ -122,8 +122,6 @@ static int __init do_hpp_probe(struct net_device *dev) int base_addr = dev->base_addr; int irq = dev->irq; - SET_MODULE_OWNER(dev); - if (base_addr > 0x1ff) /* Check a single specified location. */ return hpp_probe1(dev, base_addr); else if (base_addr != 0) /* Don't probe at all. */ @@ -168,6 +166,7 @@ static int __init hpp_probe1(struct net_device *dev, int ioaddr) const char name[] = "HP-PC-LAN+"; int mem_start; static unsigned version_printed; + DECLARE_MAC_BUF(mac); if (!request_region(ioaddr, HP_IO_EXTENT, DRV_NAME)) return -EBUSY; @@ -182,7 +181,7 @@ static int __init hpp_probe1(struct net_device *dev, int ioaddr) if (ei_debug && version_printed++ == 0) printk(version); - printk("%s: %s at %#3x,", dev->name, name, ioaddr); + printk("%s: %s at %#3x, ", dev->name, name, ioaddr); /* Retrieve and checksum the station address. */ outw(MAC_Page, ioaddr + HP_PAGING); @@ -191,10 +190,11 @@ static int __init hpp_probe1(struct net_device *dev, int ioaddr) unsigned char inval = inb(ioaddr + 8 + i); dev->dev_addr[i] = inval; checksum += inval; - printk(" %2.2x", inval); } checksum += inb(ioaddr + 14); + printk("%s", print_mac(mac, dev->dev_addr)); + if (checksum != 0xff) { printk(" bad checksum %2.2x.\n", checksum); retval = -ENODEV; @@ -262,7 +262,7 @@ static int __init hpp_probe1(struct net_device *dev, int ioaddr) } outw(Perf_Page, ioaddr + HP_PAGING); - NS8390_init(dev, 0); + NS8390p_init(dev, 0); /* Leave the 8390 and HP chip reset. */ outw(inw(ioaddr + HPP_OPTION) & ~EnableIRQ, ioaddr + HPP_OPTION); @@ -430,7 +430,7 @@ hpp_mem_block_output(struct net_device *dev, int count, return; } - + #ifdef MODULE #define MAX_HPP_CARDS 4 /* Max number of HPP cards per module */ static struct net_device *dev_hpp[MAX_HPP_CARDS]; @@ -482,7 +482,7 @@ static void cleanup_card(struct net_device *dev) release_region(dev->base_addr - NIC_OFFSET, HP_IO_EXTENT); } -void +void __exit cleanup_module(void) { int this_dev;