linux/arch/powerpc/kernel
Michael Ellerman a2ceff5e55 [POWERPC] Fix missed hardware breakpoints across multiple threads
There is a bug in the powerpc DABR (data access breakpoint) handling,
which can result in us missing breakpoints if several threads are trying
to break on the same address.

The circumstances are that do_page_fault() calls do_dabr(), this clears
the DABR (sets it to 0) and sets up the signal which will report to
userspace that the DABR was hit. The do_signal() code will restore the DABR
value on the way out to userspace.

If we reschedule before calling do_signal(), __switch_to() will check the
cached DABR value and compare it to the new thread's value, if they match
we don't set the DABR in hardware.

So if two threads have the same DABR value, and we schedule from one to
the other after taking the interrupt for the first thread hitting the DABR,
the second thread will run without the DABR set in hardware.

The cleanest fix is to move the cache update into set_dabr(), that way we
can't forget to do it.

Reported-by: Jan Kratochvil <jan.kratochvil@redhat.com>
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2008-03-28 22:51:02 +11:00
..
vdso32 [POWERPC] vdso: Fixes for cache block sizes 2007-11-20 13:56:31 +11:00
vdso64
align.c [POWERPC] Handle alignment faults on SPE load/store instructions 2007-09-14 08:51:48 -05:00
asm-offsets.c Fix compilation of powerpc asm-offsets.c with old gcc 2008-02-07 14:54:45 -08:00
audit.c [PATCH] audit signal recipients 2007-05-11 05:38:25 -04:00
btext.c
clock.c [POWERPC] clk.h interface for platforms 2007-10-03 09:11:56 +10:00
compat_audit.c
cpu_setup_6xx.S
cpu_setup_44x.S [POWERPC] 4xx: Fix 440grx setup function to call 440A fixup 2007-12-23 13:27:37 -06:00
cpu_setup_pa6t.S
cpu_setup_ppc970.S [POWERPC] powerpc: Enable DEEPNAP power savings mode on 970MP 2006-10-16 16:32:25 +10:00
cputable.c [POWERPC} Add oprofile support for e300 2008-02-05 23:37:58 -06:00
crash.c
crash_dump.c
dma_64.c iommu sg: powerpc: convert iommu to use the IOMMU helper 2008-02-05 09:44:11 -08:00
entry_32.S
entry_64.S [POWERPC] Add 1TB workaround for PA6T 2007-10-17 22:30:09 +10:00
firmware.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
fpu.S
head_8xx.S [POWERPC] 8xx: fix swap 2008-03-07 08:42:28 -06:00
head_32.S
head_40x.S
head_44x.S [POWERPC] Reworking machine check handling and Fix 440/440A 2007-12-23 13:11:59 -06:00
head_64.S [POWERPC] Provide a way to protect 4k subpages when using 64k pages 2008-01-24 10:06:01 +11:00
head_booke.h
head_fsl_booke.S [POWERPC] 85xx: Respect KERNELBASE, PAGE_OFFSET, and PHYSICAL_START on e500 2008-01-23 19:34:36 -06:00
ibmebus.c
idle.c [POWERPC] Fix sysctl table check failure on PowerMac 2007-11-08 14:15:30 +11:00
idle_6xx.S
idle_power4.S
init_task.c [PATCH] nsproxy: move init_nsproxy into kernel/nsproxy.c 2006-10-02 07:57:20 -07:00
io.c [POWERPC] Move inline asm eieio to using eieio inline function 2007-07-10 00:33:14 -05:00
iomap.c [POWERPC] Add 64-bit resources support to pci_iomap 2007-09-20 07:36:52 -05:00
iommu.c iommu sg: powerpc: remove DMA 4GB boundary protection 2008-02-05 09:44:11 -08:00
irq.c
isa-bridge.c
kprobes.c [POWERPC] Kill sparse warnings in kprobes 2008-02-20 13:33:37 +11:00
l2cr_6xx.S Convert files to UTF-8 and some cleanups 2007-10-19 23:21:04 +02:00
legacy_serial.c [POWERPC] Fix legacy serial search for opb bus ports 2008-02-06 16:30:00 +11:00
lparcfg.c
machine_kexec.c
machine_kexec_32.c
machine_kexec_64.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
Makefile [POWERPC] Remove generated files on make clean 2008-02-14 22:11:02 +11:00
misc.S [POWERPC] Make setjmp/longjmp code usable outside of xmon 2008-01-25 22:52:50 +11:00
misc_32.S [POWERPC] Add __ucmpdi2 for 64-bit comparisons in 32-bit kernels 2008-03-13 09:39:55 +11:00
misc_64.S [POWERPC] kernel_execve is identical in 32 and 64 bit 2007-12-11 13:34:39 +11:00
module_32.c
module_64.c [POWERPC] Optimize counting distinct entries in the relocation sections 2007-12-21 15:05:58 +11:00
msi.c
nvram_64.c
of_device.c [POWERPC] Use <linux/of_{platform, device}.h> and not <asm/...> variants. 2008-01-17 14:58:57 +11:00
of_platform.c
paca.c [POWERPC] Implement SLB shadow buffer 2006-08-08 17:08:56 +10:00
pci-common.c [POWERPC] Fix bogus test for unassigned PCI resources 2008-03-13 10:09:27 +11:00
pci_32.c
pci_64.c
pci_dn.c
pmc.c [POWERPC] Made FSL Book-E PMC support more generic 2008-02-05 23:34:14 -06:00
ppc32.h powerpc: move include/asm-ppc64/ppc32.h to arch/powerpc/kernel 2005-11-03 16:03:28 +11:00
ppc_ksyms.c [POWERPC] Export empty_zero_page 2008-03-13 10:09:28 +11:00
proc_ppc64.c
process.c [POWERPC] Fix missed hardware breakpoints across multiple threads 2008-03-28 22:51:02 +11:00
prom.c [POWERPC] Fix dt_mem_next_cell() to read the full address 2008-02-20 13:33:37 +11:00
prom_init.c
prom_parse.c
ptrace.c [POWERPC] user_regset PTRACE_SETREGS regression fix 2008-03-20 10:10:56 +11:00
ptrace32.c [POWERPC] Use regset code for compat PTRACE_*REGS* calls 2008-02-07 20:40:21 +11:00
rio.c [POWERPC] Move RapidIO support code from arch/ppc 2008-01-23 19:35:15 -06:00
rtas-proc.c [POWERPC] Fix ppc_rtas_progress_show() 2007-05-17 21:11:15 +10:00
rtas-rtc.c [PATCH] powerpc: reorg RTAS delay code 2006-06-09 21:21:06 +10:00
rtas.c
rtas_flash.c
rtas_pci.c
semaphore.c
setup-common.c
setup.h [PATCH] powerpc: Make early xmon logic immune to location of early parsing 2006-05-19 15:02:12 +10:00
setup_32.c
setup_64.c [POWERPC] Fix cache line vs. block size confusion 2007-11-08 14:15:30 +11:00
signal.c [POWERPC] Implement logging of unhandled signals 2007-10-12 14:05:18 +10:00
signal.h
signal_32.c [POWERPC] arch/powerpc: Remove duplicate includes 2007-12-20 17:13:50 +11:00
signal_64.c
smp-tbsync.c
smp.c [POWERPC] Make smp_send_stop() handle panic and xmon reboot 2008-01-25 22:52:50 +11:00
softemu8xx.c [POWERPC] 8xx: Move softemu8xx.c from arch/ppc 2007-10-04 11:02:54 -05:00
suspend.c
swsusp.c
swsusp_32.S
swsusp_64.c [POWERPC] powermac: Suspend to disk on G5 2007-05-07 20:31:14 +10:00
swsusp_asm64.S
sys_ppc32.c
syscalls.c
sysfs.c
systbl.S [POWERPC] Align the sys_call_table 2007-10-11 14:36:47 +10:00
systbl_chk.c
systbl_chk.sh
tau_6xx.c
time.c taskstats scaled time cleanup 2008-02-06 10:41:00 -08:00
traps.c [POWERPC] Fix compilation for CONFIG_DEBUGGER=n and CONFIG_KEXEC=y 2008-02-07 11:40:18 +11:00
udbg.c
udbg_16550.c
vdso.c [POWERPC] vdso_do_func_patch{32,64}() must be __init 2008-02-14 22:11:02 +11:00
vecemu.c
vector.S
vio.c [POWERPC] iSeries: Fix section mismatch in viodsasd 2008-02-06 16:30:00 +11:00
vmlinux.lds.S all archs: consolidate init and exit sections in vmlinux.lds.h 2008-01-28 23:21:17 +01:00