BUG: warning at kernel/lockdep.c:2427/check_flags()
After some hours running 2.6.17-rc6-mm1 + combo-patch I've got this:
[12138.880686] BUG: warning at kernel/lockdep.c:2427/check_flags() [12138.880692] [12138.880693] Call Trace: [12138.880702] [<ffffffff80240374>] check_flags+0x86/0x201 [12138.880707] [<ffffffff80240873>] lock_acquire+0x2f/0xa3 [12138.880713] [<ffffffff8025fcae>] sys_munmap+0x5e/0xa7 [12138.880719] [<ffffffff8020944e>] system_call+0x7e/0x83 [12138.880723] [12138.880725] irq event stamp: 18146 [12138.880728] hardirqs last enabled at (18145): [<ffffffff8049dffc>] _spin_unlock_irq+0x28/0x50 [12138.880734] hardirqs last disabled at (18146): [<ffffffff8049d61e>] trace_hardirqs_off_thunk+0x35/0x67 [12138.880742] softirqs last enabled at (18112): [<ffffffff8022c1ae>] __do_softirq+0xb2/0xba [12138.880748] softirqs last disabled at (18105): [<ffffffff8020a2c2>] call_softirq+0x1e/0x28
I don't know if/how it is reproducible.
Signature · 2 lines
Paolo Ornati Linux 2.6.17-rc6-mm1-lockdep on x86_64
Quoted 17 lines · On Thu, 8 Jun 2006 21:38:09 +0200 Paolo Ornati <[email protected]> wrote:
After some hours running 2.6.17-rc6-mm1 + combo-patch I've got this:
[12138.880686] BUG: warning at kernel/lockdep.c:2427/check_flags() [12138.880692] [12138.880693] Call Trace: [12138.880702] [<ffffffff80240374>] check_flags+0x86/0x201 [12138.880707] [<ffffffff80240873>] lock_acquire+0x2f/0xa3 [12138.880713] [<ffffffff8025fcae>] sys_munmap+0x5e/0xa7 [12138.880719] [<ffffffff8020944e>] system_call+0x7e/0x83 [12138.880723] [12138.880725] irq event stamp: 18146 [12138.880728] hardirqs last enabled at (18145): [<ffffffff8049dffc>] _spin_unlock_irq+0x28/0x50 [12138.880734] hardirqs last disabled at (18146): [<ffffffff8049d61e>] trace_hardirqs_off_thunk+0x35/0x67 [12138.880742] softirqs last enabled at (18112): [<ffffffff8022c1ae>] __do_softirq+0xb2/0xba [12138.880748] softirqs last disabled at (18105): [<ffffffff8020a2c2>] call_softirq+0x1e/0x28
Quoted 1 line
I don't know if/how it is reproducible.
Wow, now I can reproduce it easly :)
Just run under "gdb" a program that segfaults:
void main(void)
{
*(int*)(0) = 1;
}and it will trigger.
Signature · 2 lines
Paolo Ornati Linux 2.6.17-rc6-mm1-lockdep on x86_64
Quoted 4 lines · Paolo Ornati
Quoted 1 line
I don't know if/how it is reproducible.
Wow, now I can reproduce it easly :)
Quoted 8 lines
Just run under "gdb" a program that segfaults:
void main(void)
{ *(int*)(0) = 1; }and it will trigger.
thanks alot, that's very helpful! I'll have a look.
Ingo
PATCH 1/1 irqflags tracing: fix x86_64 entry/exit
In reply to Paolo OrnatiQuoted 10 lines · Paolo Ornati
Wow, now I can reproduce it easly :)
Just run under "gdb" a program that segfaults:
void main(void)
{ *(int*)(0) = 1; }and it will trigger.
thanks - please try the fix below - it has solved the problem on my testbox.
Ingo
-------------
Subject: irqflags tracing: fix x86_64 entry/exit
From: Ingo Molnar <[email protected]>
the x86_64 portion of the irqflags code did not properly trace the "paranoid userspace" type of syscall/ptrace exit variant.
A testcase Paolo Ornati has discovered triggers a lock validator assert due to this bug.
--- arch/x86_64/kernel/entry.S | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-)
arch/x86_64/kernel/entry.S +6 -4
@@ -50,9 +50,10 @@ #define retint_kernel retint_restore_args #endif -.macro TRACE_IRQS_IRETQ + +.macro TRACE_IRQS_IRETQ offset=ARGOFFSET #ifdef CONFIG_TRACE_IRQFLAGS - bt $9,EFLAGS-ARGOFFSET(%rsp) /* interrupts off? */ + bt $9,EFLAGS-\offset(%rsp) /* interrupts off? */ jnc 1f TRACE_IRQS_ON 1:
@@ -809,9 +810,9 @@ error_exit: andl %edi,%edx jnz retint_careful /* - * The iret will restore flags: + * The iret might restore flags: */ - TRACE_IRQS_ON + TRACE_IRQS_IRETQ swapgs RESTORE_ARGS 0,8,0 jmp iret_label
@@ -999,6 +1000,7 @@ paranoid_exit: testl $3,CS(%rsp) jnz paranoid_userspace paranoid_swapgs: + TRACE_IRQS_IRETQ 0 swapgs paranoid_restore: RESTORE_ALL 8
Re: [patch, -rc6-mm1] irqflags tracing: fix x86_64 entry/exit
Quoted 9 lines · On Fri, 9 Jun 2006 10:59:20 +0200 Ingo Molnar <[email protected]> wrote:
Quoted 6 lines
void main(void)
{ *(int*)(0) = 1; }and it will trigger.
thanks - please try the fix below - it has solved the problem on my testbox.
Works here too.
:)
Signature · 2 lines
Paolo Ornati Linux 2.6.17-rc6-mm1-lockdep on x86_64