aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/8390.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2006-06-23 01:15:09 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2006-06-23 01:15:09 -0400
commit065a3e17baa36d1d48eb7376138820035b44775e (patch)
tree556abb5dbeaad98fc5a66bd56f6a647dfbd22182 /drivers/net/8390.c
parent45c091bb2d453ce4a8b06cf19872ec7a77fc4799 (diff)
parentbfcbb00855db21dacd3c154ea13ec3fdd98e747b (diff)
Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6: (33 commits) [PATCH] myri10ge - drop workaround pci_save_state() disabling MSI [PATCH] myri10ge - drop workaround for the missing AER ext cap on nVidia CK804 via-velocity: the link is not correctly detected when the device starts [PATCH] add b44 to maintainers [PATCH] WAN: ioremap() failure checks in drivers [PATCH] WAN: register_hdlc_device() doesn't need dev_alloc_name() [PATCH] skb_padto()-area fixes in 8390, wavelan [PATCH] make drivers/net/forcedeth.c:nv_update_pause() static [PATCH] network driver for Hilscher netx [PATCH] Dereference in tokenring/olympic.c [PATCH] Array overrun in drivers/net/wireless/wavelan.c [PATCH] Remove useless check in drivers/net/pcmcia/xirc2ps_cs.c [PATCH] 8139cp: add ethtool eeprom support [PATCH] 8139cp: fix eeprom read command length [PATCH] b44: update b44 Kconfig entry [PATCH] b44: update version to 1.01 [PATCH] b44: add wol for old nic [PATCH] b44: add parameter [PATCH] b44: add wol [PATCH] b44: fix manual speed/duplex/autoneg settings ...
Diffstat (limited to 'drivers/net/8390.c')
-rw-r--r--drivers/net/8390.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/net/8390.c b/drivers/net/8390.c
index f87027420081..86be96af9c8f 100644
--- a/drivers/net/8390.c
+++ b/drivers/net/8390.c
@@ -275,12 +275,14 @@ static int ei_start_xmit(struct sk_buff *skb, struct net_device *dev)
275 struct ei_device *ei_local = (struct ei_device *) netdev_priv(dev); 275 struct ei_device *ei_local = (struct ei_device *) netdev_priv(dev);
276 int send_length = skb->len, output_page; 276 int send_length = skb->len, output_page;
277 unsigned long flags; 277 unsigned long flags;
278 char buf[ETH_ZLEN];
279 char *data = skb->data;
278 280
279 if (skb->len < ETH_ZLEN) { 281 if (skb->len < ETH_ZLEN) {
280 skb = skb_padto(skb, ETH_ZLEN); 282 memset(buf, 0, ETH_ZLEN); /* more efficient than doing just the needed bits */
281 if (skb == NULL) 283 memcpy(buf, data, skb->len);
282 return 0;
283 send_length = ETH_ZLEN; 284 send_length = ETH_ZLEN;
285 data = buf;
284 } 286 }
285 287
286 /* Mask interrupts from the ethercard. 288 /* Mask interrupts from the ethercard.
@@ -347,7 +349,7 @@ static int ei_start_xmit(struct sk_buff *skb, struct net_device *dev)
347 * trigger the send later, upon receiving a Tx done interrupt. 349 * trigger the send later, upon receiving a Tx done interrupt.
348 */ 350 */
349 351
350 ei_block_output(dev, send_length, skb->data, output_page); 352 ei_block_output(dev, send_length, data, output_page);
351 353
352 if (! ei_local->txing) 354 if (! ei_local->txing)
353 { 355 {