From: Hugh Dickins <hughd@google.com>
To: Dave Jones <davej@redhat.com>
Cc: Tejun Heo <tj@kernel.org>, Peter Zijlstra <peterz@infradead.org>,
Hugh Dickins <hughd@google.com>, Ingo Molnar <mingo@kernel.org>,
Ingo Molnar <mingo@redhat.com>,
Stephen Boyd <sboyd@codeaurora.org>,
Yong Zhang <yong.zhang0@gmail.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] lockdep: fix oops in processing workqueue
Date: Tue, 15 May 2012 13:36:55 -0700 (PDT) [thread overview]
Message-ID: <alpine.LSU.2.00.1205151307350.1416@eggly.anvils> (raw)
In-Reply-To: <20120515153136.GF6119@google.com>
On Tue, 15 May 2012, Tejun Heo wrote:
> On Tue, May 15, 2012 at 11:29:52AM -0400, Dave Jones wrote:
> > On Tue, May 15, 2012 at 08:10:48AM -0700, Tejun Heo wrote:
> > > >From 4d82a1debbffec129cc387aafa8f40b7bbab3297 Mon Sep 17 00:00:00 2001
> > > From: Peter Zijlstra <peterz@infradead.org>
> > > Date: Tue, 15 May 2012 08:06:19 -0700
> > >
> > > Under memory load, on x86_64, with lockdep enabled, the workqueue's
> > > process_one_work() has been seen to oops in __lock_acquire(), barfing
> > > on a 0xffffffff00000000 pointer in the lockdep_map's class_cache[].
> >
> > can you elaborate what 'memory load' means here ?
> > I'm curious if I can add something to my fuzzing tool to shake out bugs like this.
>
> I think Hugh knows and can explain this much better than I do. Hugh?
Quoting from myself, quoting from myself, on an earlier occasion:
"It's the tmpfs swapping test that I've been running, with variations,
for years. System booted with mem=700M and 1.5G swap, two repetitious
make -j20 kernel builds (of a 2.6.24 kernel: I stuck with that because
the balance of built to unbuilt source grows smaller with later kernels),
one directly in a tmpfs, the other in a 1k-block ext2 (that I drive with
ext4's CONFIG_EXT4_USE_FOR_EXT23) on /dev/loop0 on a 450MB tmpfs file."
Most of those details will be irrelevant in this case, but it's been a
useful test down the years, catching lots of bugs and races. On this
occasion I was running a variation which further puts each of the builds
in its own 300M mem cgroup, with a concurrent script which cycles around
making a new 300M mem cgroup, moving all the tasks from one old into the
new (with memory.move_charge_at_immigrate set to 3), then rmdir the old.
It was probably the moving of memcg charges (or the rmdir'ing of memcg,
which also involves moving memcg charges) which was making so many calls
to lru_add_drain_all() to show the problem - lru_add_drain_all() has to
schedule work on each cpu and then flush_work() on each.
(But it only came up as a problem in linux-next, which has added some
lockmap accesses to flush_work() - Tejun spotted that upstream could
already be vulnerable via other routes, but this was all I ever hit.)
Hugh
next prev parent reply other threads:[~2012-05-15 20:37 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-07 17:19 linux-next oops in __lock_acquire for process_one_work Hugh Dickins
2012-05-07 17:57 ` Tejun Heo
2012-05-08 13:03 ` Peter Zijlstra
2012-05-08 16:58 ` Tejun Heo
2012-05-08 17:02 ` Peter Zijlstra
2012-05-08 18:11 ` Hugh Dickins
2012-05-08 22:31 ` Peter Zijlstra
2012-05-08 22:58 ` Hugh Dickins
2012-05-09 9:25 ` Ingo Molnar
2012-05-09 20:09 ` Hugh Dickins
2012-05-10 17:52 ` Hugh Dickins
2012-05-14 21:27 ` Tejun Heo
2012-05-15 11:11 ` Peter Zijlstra
2012-05-15 15:10 ` [PATCH] lockdep: fix oops in processing workqueue Tejun Heo
2012-05-15 15:29 ` Dave Jones
2012-05-15 15:31 ` Tejun Heo
2012-05-15 20:36 ` Hugh Dickins [this message]
2012-05-08 18:05 ` linux-next oops in __lock_acquire for process_one_work Hugh Dickins
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=alpine.LSU.2.00.1205151307350.1416@eggly.anvils \
--to=hughd@google.com \
--cc=davej@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=sboyd@codeaurora.org \
--cc=tj@kernel.org \
--cc=yong.zhang0@gmail.com \
/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
all inboxes | Powered by JetHome®