netdev
[Top] [All Lists]

Re: [PATCH] forcedeth: fix random memory scribbling bug

To: Manfred Spraul <manfred@xxxxxxxxxxxxxxxx>
Subject: Re: [PATCH] forcedeth: fix random memory scribbling bug
From: Linus Torvalds <torvalds@xxxxxxxx>
Date: Sat, 24 Dec 2005 12:41:35 -0800 (PST)
Cc: Jeff Garzik <jgarzik@xxxxxxxxx>, Ayaz Abdulla <AAbdulla@xxxxxxxxxx>, Linux Kernel Mailing List <linux-kernel@xxxxxxxxxxxxxxx>, Netdev <netdev@xxxxxxxxxxx>
In-reply-to: <43ADA7D0.9010908@xxxxxxxxxxxxxxxx>
References: <43AD4ADC.8050004@xxxxxxxxxxxxxxxx> <Pine.LNX.4.64.0512241145520.14098@xxxxxxxxxxx> <43ADA7D0.9010908@xxxxxxxxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx

On Sat, 24 Dec 2005, Manfred Spraul wrote:

> Linus Torvalds wrote:
> 
> > Of course, on the alloc path, it seems to add an additional
> > "NV_RX_ALLOC_PAD" thing, so maybe the "end-data" thing makes sense.
>
> The problem is the pci_unmap_single() call that happens during nv_close() or
> the rx interrupt handler. I think it makes more sense to rely on fields in the
> individual skb instead of reading from np->rx_buf_sz. If np->rx_buf_sz changes
> inbetween, then we have a memory leak.

Fair enough. Patch applied.

                Linus

<Prev in Thread] Current Thread [Next in Thread>