Revert to Fedora kernel-2.6.17-1.2187_FC5 patched with vs2.0.2.1; there are too many...
[linux-2.6.git] / drivers / net / lance.c
index 5b4dbfe..bb5ad47 100644 (file)
@@ -326,7 +326,7 @@ MODULE_PARM_DESC(dma, "LANCE/PCnet ISA DMA channel (ignored for some devices)");
 MODULE_PARM_DESC(irq, "LANCE/PCnet IRQ number (ignored for some devices)");
 MODULE_PARM_DESC(lance_debug, "LANCE/PCnet debug level (0-7)");
 
-int __init init_module(void)
+int init_module(void)
 {
        struct net_device *dev;
        int this_dev, found = 0;
@@ -968,7 +968,8 @@ static int lance_start_xmit(struct sk_buff *skb, struct net_device *dev)
        /* The old LANCE chips doesn't automatically pad buffers to min. size. */
        if (chip_table[lp->chip_version].flags & LANCE_MUST_PAD) {
                if (skb->len < ETH_ZLEN) {
-                       if (skb_padto(skb, ETH_ZLEN))
+                       skb = skb_padto(skb, ETH_ZLEN);
+                       if (skb == NULL)
                                goto out;
                        lp->tx_ring[entry].length = -ETH_ZLEN;
                }