From: Larry Finger <Larry.Finger@lwfinger.net>
To: Eric Biggers <ebiggers3@gmail.com>
Cc: kvalo@codeaurora.org, linux-wireless@vger.kernel.org,
netdev@vger.kernel.org, Stable <stable@vger.kernel.org>
Subject: Re: [PATCH 23/23 V2 for 3.19] rtlwifi: Fix error when accessing unmapped memory in skb
Date: Tue, 30 Dec 2014 21:31:47 -0600 [thread overview]
Message-ID: <54A36E23.2000804@lwfinger.net> (raw)
In-Reply-To: <20141231004947.GA2007@zzz>
On 12/30/2014 06:49 PM, Eric Biggers wrote:
> On Sat, Dec 27, 2014 at 02:17:37PM -0600, Larry Finger wrote:
>> These drivers use 9100-byte receive buffers, thus allocating an skb requires
>> an O(3) memory allocation. Under heavy memory loads and fragmentation, such
>> a request can fail. Previous versions of the driver have dropped the packet
>> and reused the old buffer; however, the new version introduced a bug in that
>> it released the old buffer before trying to allocate a new one. The previous
>> method is implemented here.
>
> It looks like in the out-of-memory path, pci_map_single() gets called while the
> skb is still mapped. Won't this leak the IOMMU mapping?
Good catch. I do not know much about leaking the IOMMU mapping; however it is
easy to do the unmapping before trying to allocate a new skb.
Thanks,
Larry
prev parent reply other threads:[~2014-12-31 3:32 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-27 20:17 [PATCH 23/23 V2 for 3.19] rtlwifi: Fix error when accessing unmapped memory in skb Larry Finger
2014-12-28 5:50 ` Kalle Valo
2014-12-28 6:15 ` Larry Finger
2014-12-28 6:15 ` Larry Finger
2015-01-05 9:20 ` Kalle Valo
2015-01-05 21:25 ` Larry Finger
2015-01-06 8:10 ` Kalle Valo
2014-12-31 0:49 ` Eric Biggers
2014-12-31 3:31 ` Larry Finger [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54A36E23.2000804@lwfinger.net \
--to=larry.finger@lwfinger.net \
--cc=ebiggers3@gmail.com \
--cc=kvalo@codeaurora.org \
--cc=linux-wireless@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.