All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sasha Levin <sasha.levin@oracle.com>
To: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Cc: linux-kernel@vger.kernel.org, cl@linux.com, brouer@redhat.com,
	akpm@linux-foundation.org
Subject: Re: [PATCH] mm/slub: use unchecked percpu access within preemptible sections
Date: Wed, 21 Jan 2015 21:27:41 -0500	[thread overview]
Message-ID: <54C0601D.5050006@oracle.com> (raw)
In-Reply-To: <20150122015904.GF21444@js1304-P5Q-DELUXE>

On 01/21/2015 08:59 PM, Joonsoo Kim wrote:
> On Tue, Jan 20, 2015 at 11:31:43PM -0500, Sasha Levin wrote:
>> > Commit "mm/slub: optimize alloc/free fastpath by removing preemption on/off"
>> > has added access to percpu memory while the code is preemptible.
>> > 
>> > While those accesses are okay, this creates a huge amount of warnings from
>> > the code that checks for that.
>> > 
>> > Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
> Hello,
> 
> I already sent the patch to fix this issue and it is in mmotm, but,
> not be released yet.
> 
> https://lkml.org/lkml/2015/1/19/17

The patch you sent out still has the issue. The one I sent goes on top of
it.

+	do {
+		tid = this_cpu_read(s->cpu_slab->tid); <=== checked percpu access
+		c = raw_cpu_ptr(s->cpu_slab);
+	} while (IS_ENABLED(CONFIG_PREEMPT) && unlikely(tid != c->tid));


Thanks,
Sasha


  reply	other threads:[~2015-01-22  2:28 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-21  4:31 [PATCH] mm/slub: use unchecked percpu access within preemptible sections Sasha Levin
2015-01-22  1:59 ` Joonsoo Kim
2015-01-22  2:27   ` Sasha Levin [this message]
2015-01-22  5:13     ` Joonsoo Kim

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=54C0601D.5050006@oracle.com \
    --to=sasha.levin@oracle.com \
    --cc=akpm@linux-foundation.org \
    --cc=brouer@redhat.com \
    --cc=cl@linux.com \
    --cc=iamjoonsoo.kim@lge.com \
    --cc=linux-kernel@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.