lkml.org 
[lkml]   [2003]   [Jan]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH][2.4] etherleak fix for via-rhine
Use skb_padto to plug that leak. Patch is already in ac, 2.5. Please apply.

--- linux-2.4.21-pre4/drivers/net/via-rhine.c.org Thu Jan 30 10:38:32 2003
+++ linux-2.4.21-pre4/drivers/net/via-rhine.c Thu Jan 30 10:46:57 2003
@@ -1239,6 +1239,12 @@
/* Calculate the next Tx descriptor entry. */
entry = np->cur_tx % TX_RING_SIZE;

+ if (skb->len < ETH_ZLEN) {
+ skb = skb_padto(skb, ETH_ZLEN);
+ if (skb == NULL)
+ return 0;
+ }
+
np->tx_skbuff[entry] = skb;

if ((np->drv_flags & ReqTxAlign) &&
\
 
 \ /
  Last update: 2005-03-22 13:32    [W:0.032 / U:4.232 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site