diff options
author | Frederic Weisbecker <fweisbec@gmail.com> | 2009-07-24 20:05:23 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-08-02 14:03:57 +0200 |
commit | 716a42348cdaf04534b15fbdc9c83e25baebfed5 (patch) | |
tree | 5a49fe4c0ff258ee03478994ffc7fbe8032a340f /include/linux/of_mdio.h | |
parent | a004cd42181409eda70804ded240a791f4564d61 (diff) | |
download | lwn-716a42348cdaf04534b15fbdc9c83e25baebfed5.tar.gz lwn-716a42348cdaf04534b15fbdc9c83e25baebfed5.zip |
sched: Fix cond_resched_lock() in !CONFIG_PREEMPT
The might_sleep() test inside cond_resched_lock() assumes the
spinlock is held and then preemption is disabled. This is true
with CONFIG_PREEMPT but the preempt_count() doesn't change
otherwise.
Check by starting from the appropriate preempt offset depending
on the config.
Reported-by: Li Zefan <lizf@cn.fujitsu.com>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
LKML-Reference: <1248458723-12146-1-git-send-email-fweisbec@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/of_mdio.h')
0 files changed, 0 insertions, 0 deletions