From: Pravin Shelar <pshelar@nicira.com>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: cl@linux.com, penberg@kernel.org, mpm@selenic.com,
linux-kernel@vger.kernel.org, linux-mm@kvack.org,
jesse@nicira.com, abhide@nicira.com
Subject: Re: [PATCH v2] mm: Fix slab->page _count corruption.
Date: Mon, 14 May 2012 17:13:17 -0700 [thread overview]
Message-ID: <CALnjE+qGpJCf6FOb37DjJfh5qHfJuF7DBmbqDNYR7KJ3Ux41Uw@mail.gmail.com> (raw)
In-Reply-To: <1337034892.8512.652.camel@edumazet-glaptop>
On Mon, May 14, 2012 at 3:34 PM, Eric Dumazet <eric.dumazet@gmail.com> wrote:
> On Mon, 2012-05-14 at 15:29 -0700, Pravin B Shelar wrote:
>> On arches that do not support this_cpu_cmpxchg_double slab_lock is used
>> to do atomic cmpxchg() on double word which contains page->_count.
>> page count can be changed from get_page() or put_page() without taking
>> slab_lock. That corrupts page counter.
>>
>> Following patch fixes it by moving page->_count out of cmpxchg_double
>> data. So that slub does no change it while updating slub meta-data in
>> struct page.
>
> I say again : Page is owned by slub, so get_page() or put_page() is not
> allowed ?
>
This is already done in multiple subsystem in Linux kernel. e.g.
ocfs, xfs, etc.
So object from slab can be passed to IO using DMA. I don't think this
rule you referring to is enforced anywhere.
Thanks,
Pravin.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2012-05-15 0:13 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-14 22:29 Pravin B Shelar
2012-05-14 22:34 ` Eric Dumazet
2012-05-15 0:13 ` Pravin Shelar [this message]
2012-05-15 14:04 ` Christoph Lameter
2012-05-16 17:49 ` Pravin Shelar
2012-05-16 17:51 ` Christoph Lameter
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=CALnjE+qGpJCf6FOb37DjJfh5qHfJuF7DBmbqDNYR7KJ3Ux41Uw@mail.gmail.com \
--to=pshelar@nicira.com \
--cc=abhide@nicira.com \
--cc=cl@linux.com \
--cc=eric.dumazet@gmail.com \
--cc=jesse@nicira.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mpm@selenic.com \
--cc=penberg@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox