From: Ingo Molnar <mingo@elte.hu>
To: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>,
dhaval@linux.vnet.ibm.com, mel@csn.ul.ie,
vatsa@linux.vnet.ibm.com, linux-kernel@vger.kernel.org,
"Rafael J. Wysocki" <rjw@sisk.pl>,
linuxppc-dev@ozlabs.org,
Alexey Zaytsev <alexey.zaytsev@gmail.com>
Subject: Re: [BUG] 2.6.29-rc1 - Badness at kernel/sched.c:4440 with CONFIG_DEBUG_PREEMPT
Date: Mon, 12 Jan 2009 13:05:38 +0100 [thread overview]
Message-ID: <20090112120538.GB24266@elte.hu> (raw)
In-Reply-To: <20090112113914.GC8409@linux.vnet.ibm.com>
* Kamalesh Babulal <kamalesh@linux.vnet.ibm.com> wrote:
> Hi Ingo,
>
> While booting up 2.6.29-rc1 kernel on powerpc machine, Kernel
> Badness warning is seen, when compiled with CONFIG_DEBUG_PREEMPT=y
> kernel warning is not seen after reverting the patch.
>
> commit 7317d7b87edb41a9135e30be1ec3f7ef817c53dd
> Author: Nick Piggin <nickpiggin@yahoo.com.au>
> Date: Tue Sep 30 20:50:27 2008 +1000
>
> sched: improve preempt debugging
thanks. This has been bisected before by Alexey Zaytsev so i've now
reverted the commit in tip/sched/urgent and will send it to Linus ASAP.
The revert commit can be found below.
Ingo
--------------------->
>From 01e3eb82278bf45221fc38b391bc5ee0f6a314d6 Mon Sep 17 00:00:00 2001
From: Ingo Molnar <mingo@elte.hu>
Date: Mon, 12 Jan 2009 13:00:50 +0100
Subject: [PATCH] Revert "sched: improve preempt debugging"
This reverts commit 7317d7b87edb41a9135e30be1ec3f7ef817c53dd.
This has been reported (and bisected) by Alexey Zaytsev and
Kamalesh Babulal to produce annoying warnings during bootup
on both x86 and powerpc.
kernel_locked() is not a valid test in IRQ context (we update the
BKL's ->lock_depth and the preempt count separately and non-atomicalyy),
so we cannot put it into the generic preempt debugging checks which
can run in IRQ contexts too.
Reported-and-bisected-by: Alexey Zaytsev <alexey.zaytsev@gmail.com>
Reported-and-bisected-by: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
kernel/sched.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/kernel/sched.c b/kernel/sched.c
index 8be2c13..3b630d8 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -4440,7 +4440,7 @@ void __kprobes sub_preempt_count(int val)
/*
* Underflow?
*/
- if (DEBUG_LOCKS_WARN_ON(val > preempt_count() - (!!kernel_locked())))
+ if (DEBUG_LOCKS_WARN_ON(val > preempt_count()))
return;
/*
* Is the spinlock portion underflowing?
prev parent reply other threads:[~2009-01-12 12:05 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-12 11:39 [BUG] 2.6.29-rc1 - Badness at kernel/sched.c:4440 with CONFIG_DEBUG_PREEMPT Kamalesh Babulal
2009-01-12 12:05 ` Ingo Molnar [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=20090112120538.GB24266@elte.hu \
--to=mingo@elte.hu \
--cc=alexey.zaytsev@gmail.com \
--cc=dhaval@linux.vnet.ibm.com \
--cc=kamalesh@linux.vnet.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@ozlabs.org \
--cc=mel@csn.ul.ie \
--cc=nickpiggin@yahoo.com.au \
--cc=rjw@sisk.pl \
--cc=vatsa@linux.vnet.ibm.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