lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 25 Sep 2012 00:47:55 +0200
From:	Sasha Levin <levinsasha928@...il.com>
To:	Frederic Weisbecker <fweisbec@...il.com>
CC:	paulmck@...ux.vnet.ibm.com,
	Michael Wang <wangyun@...ux.vnet.ibm.com>,
	Dave Jones <davej@...hat.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: RCU idle CPU detection is broken in linux-next

Hi Frederic,

On 09/24/2012 11:29 PM, Frederic Weisbecker wrote:
> Sasha,
> 
> Can you please test the following branch:
> 
> git://github.com/fweisbec/linux-dynticks.git  rcu/idle-for-v3.7-take3
> 
> with CONFIG_RCU_USER_QS and CONFIG_RCU_USER_QS_FORCE enabled.
> 
> I hope this fixes the warning.
> The changes are:
> 
> * add "x86: Unspaghettize do_general_protection()"
> * updated "x86: Exception hooks for userspace RCU extended QS" to
> handle some missed trap handlers. Especially do_general_protection()
> because I can see the problem triggered there in Sasha's warnings. I
> fixed more handlers in the way.

I've tested the branch above, and noticed two things:

 - I had merge conflicts when pulling it on top of latest linux-next which I've resolved:

diff --cc arch/x86/kernel/traps.c
index 1ba4850,cb20776..386b079
--- a/arch/x86/kernel/traps.c
+++ b/arch/x86/kernel/traps.c
@@@ -644,8 -646,7 +647,9 @@@ EXPORT_SYMBOL_GPL(math_state_restore)
  dotraplinkage void __kprobes
  do_device_not_available(struct pt_regs *regs, long error_code)
  {
 +      BUG_ON(use_eager_fpu());
 +
+       exception_enter(regs);
  #ifdef CONFIG_MATH_EMULATION
        if (read_cr0() & X86_CR0_EM) {
                struct math_emu_info info = { };

 - While I no longer see the warnings I've originally noticed, if I run with Paul's last debug patch I see the following warning:

[  212.200137] WARNING: at arch/x86/kernel/process.c:392 cpu_idle+0x12a/0x1f0()
[  212.200141] Pid: 0, comm: swapper/3 Tainted: G        W    3.6.0-rc6-next-20120924-sasha-00030-g71f256c #5
[  212.200142] Call Trace:
[  212.200146]  [<ffffffff810799da>] ? cpu_idle+0x12a/0x1f0
[  212.200150]  [<ffffffff811078b6>] warn_slowpath_common+0x86/0xb0
[  212.200153]  [<ffffffff811079a5>] warn_slowpath_null+0x15/0x20
[  212.200156]  [<ffffffff810799da>] cpu_idle+0x12a/0x1f0
[  212.200160]  [<ffffffff839a3ee8>] ? setup_APIC_timer+0xb2/0xb6

Which is triggered by:
                        if (cpuidle_idle_call())
                                pm_idle();

                        rcu_idle_exit();
                        WARN_ON(rcu_is_cpu_idle()); <---- THIS
                        start_critical_timings();

                        /* In many cases the interrupt that ended idle
                           has already called exit_idle. But some idle
                           loops can be woken up without interrupt. */
                        WARN_ON(rcu_is_cpu_idle());
                        __exit_idle();
                        WARN_ON(rcu_is_cpu_idle());


Thanks,
Sasha
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ