linux-stable/arch/x86
Peter Zijlstra ba1f14fbe7 sched: Remove PREEMPT_NEED_RESCHED from generic code
While hunting a preemption issue with Alexander, Ben noticed that the
currently generic PREEMPT_NEED_RESCHED stuff is horribly broken for
load-store architectures.

We currently rely on the IPI to fold TIF_NEED_RESCHED into
PREEMPT_NEED_RESCHED, but when this IPI lands while we already have
a load for the preempt-count but before the store, the store will erase
the PREEMPT_NEED_RESCHED change.

The current preempt-count only works on load-store archs because
interrupts are assumed to be completely balanced wrt their preempt_count
fiddling; the previous preempt_count load will match the preempt_count
state after the interrupt and therefore nothing gets lost.

This patch removes the PREEMPT_NEED_RESCHED usage from generic code and
pushes it into x86 arch code; the generic code goes back to relying on
TIF_NEED_RESCHED.

Boot tested on x86_64 and compile tested on ppc64.

Reported-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Reported-and-Tested-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Peter Zijlstra <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/r/20131128132641.GP10022@twins.programming.kicks-ass.net
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2013-12-11 15:52:32 +01:00
..
boot Merge branch 'x86-efi-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2013-11-12 10:48:30 +09:00
configs x86, defconfig: Add DEVTMPFS and DEVTMPFS_MOUNT to *86*_defconfig 2013-11-04 20:01:55 -08:00
crypto crypto: sha256_ssse3 - also test for BMI2 2013-10-07 14:17:10 +08:00
ia32 constify copy_siginfo_to_user{,32}() 2013-11-09 00:16:29 -05:00
include sched: Remove PREEMPT_NEED_RESCHED from generic code 2013-12-11 15:52:32 +01:00
kernel x86/apic, doc: Justification for disabling IO APIC before Local APIC 2013-12-04 19:33:21 -08:00
kvm kvm: mmu: delay mmu audit activation 2013-11-20 11:12:56 +02:00
lguest lguest: fix GPF in guest when using gdb. 2013-09-06 08:09:28 +09:30
lib ACPI and power management updates for 3.13-rc1 2013-11-14 13:41:48 +09:00
math-emu
mm x86, mm: do not leak page->ptl for pmd page tables 2013-11-21 16:42:28 -08:00
net net: x86: bpf: don't forget to free sk_filter (v2) 2013-11-07 19:06:52 -05:00
oprofile perf: Fix arch_perf_out_copy_user default 2013-11-06 12:34:25 +01:00
pci ACPI / driver core: Store an ACPI device pointer in struct acpi_dev_node 2013-11-14 23:14:43 +01:00
platform x86/efi: Fix earlyprintk off-by-one bug 2013-11-28 20:16:56 +00:00
power x86, asmlinkage, power: Make various symbols used by the suspend asm code visible 2013-08-06 14:21:03 -07:00
realmode
syscalls unify compat fanotify_mark(2), switch to COMPAT_SYSCALL_DEFINE 2013-05-09 13:46:38 -04:00
tools Merge branch 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2013-09-04 08:39:38 -07:00
um Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml 2013-11-19 11:42:32 -08:00
vdso seqcount: Add lockdep functionality to seqcount/seqlock structures 2013-11-06 12:40:26 +01:00
video
xen Features: 2013-11-15 13:34:37 +09:00
.gitignore
Kbuild
Kconfig Kconfig cleanups for v3.13 2013-11-15 14:05:15 -08:00
Kconfig.cpu
Kconfig.debug x86/efi: Add EFI framebuffer earlyprintk support 2013-10-28 18:09:58 +00:00
Makefile x86-64, build: Always pass in -mno-sse 2013-12-03 17:40:22 -08:00
Makefile.um
Makefile_32.cpu