Commit 375e13ca authored by Alexander Viro's avatar Alexander Viro Committed by Stephen Hemminger

[netdrvr pcnet32] Added missing check and cleanup for register_netdev() failure in pcnet32

parent fdb030f8
......@@ -806,11 +806,12 @@ pcnet32_probe1(unsigned long ioaddr, unsigned int irq_line, int shared,
dev->tx_timeout = pcnet32_tx_timeout;
dev->watchdog_timeo = (5*HZ);
/* Fill in the generic fields of the device structure. */
if (register_netdev(dev))
goto err_free_consistent;
lp->next = pcnet32_dev;
pcnet32_dev = dev;
/* Fill in the generic fields of the device structure. */
register_netdev(dev);
printk(KERN_INFO "%s: registered as %s\n",dev->name, lp->name);
cards_found++;
return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment