lkml.org 
[lkml]   [2001]   [Sep]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH-2.2.19] bug in cs89x0
On Tue, Sep 25, 2001 at 10:11:42AM +0200, Kapr Johnik wrote:
> Hi to all.
>
> I think I've found bug in the cs89x0 network driver in 2.2.19, which we
> are using in an embedded network router. The driver does not use
> skb_put(), instead it writes directly to skb->len and leaves skb->tail
> incorrect. Patch follows.

The same error exists in the v2.4-kernel, drivers/net/mac89x0.c


/David Weinehall

--- linux-2.4.10/drivers/net/mac89x0.c.old Wed Sep 26 00:45:44 2001
+++ linux-2.4.10/drivers/net/mac89x0.c Wed Sep 26 00:46:34 2001
@@ -524,7 +524,7 @@
lp->stats.rx_dropped++;
return;
}
- skb->len = length;
+ skb_put(skb, length);
skb->dev = dev;

memcpy_fromio(skb->data, dev->mem_start + PP_RxFrame, length);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 13:03    [W:0.031 / U:0.076 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site