android_kernel_xiaomi_sm8350/arch
Stanislaw Gruszka 4dbed85a35 uml: stop gdb from deleting breakpoints when running UML
Sometimes when UML is debugged gdb miss breakpoints.

When process traced by gdb do fork, debugger remove breakpoints from
child address space. There is possibility to trace more than one fork,
but this not work with UML, I guess (only guess) there is a deadlock -
gdb waits for UML and UML waits for gdb.

When clone() is called with SIGCHLD and CLONE_VM flags, gdb see this
as PTRACE_EVENT_FORK not as PTRACE_EVENT_CLONE and remove breakpoints
from child and at the same time from traced process, because either
have the same address space.

Maybe it is possible to do fix in gdb, but I'm not sure if there is
easy way to find out if traced and child processes share memory. So I
do fix for UML, it simply do not call clone() with both SIGCHLD and
CLONE_VM flags together.  Additionally __WALL flag is used for
waitpid() to assure not miss clone and normal process events.

[ jdike - checkpatch fixes ]

Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
Signed-off-by: Jeff Dike <jdike@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-12-17 19:28:15 -08:00
..
alpha alpha: fix sg_page breakage 2007-11-27 09:19:39 +01:00
arm [ARM] 4694/1: IXP4xx: Update clockevent support for shutdown and resume 2007-12-17 17:18:01 +00:00
avr32 [AVR32] Fix wrong pt_regs in critical exception handler 2007-12-07 14:54:48 +01:00
blackfin Blackfin arch: fix bug when enable uart1 with uart0 disabled => no initial console 2007-11-21 17:04:41 +08:00
cris ide: move CONFIG_IDE_ETRAX to drivers/ide/Kconfig 2007-11-27 21:35:55 +01:00
frv FRV: arrange things such that BRA can reach from the trap table 2007-11-29 09:24:54 -08:00
h8300 Kbuild/doc: fix links to Documentation files 2007-10-30 14:26:30 -07:00
ia64 [IA64] Fix iosapic interrupt delivery mode for CPE 2007-12-07 16:13:03 -08:00
m32r m32r: Update sys_rt_sigsuspend 2007-11-28 01:24:04 +09:00
m68k m68k: export atari_keyb_init 2007-11-26 19:15:31 -08:00
m68knommu m68knommu: mark mem init functions as __init 2007-10-23 20:45:44 -07:00
mips [MIPS] Ensure that ST0_FR is never set on a 32 bit kernel 2007-12-14 17:34:30 +00:00
parisc [PARISC] print more than one character at a time for pdc console 2007-12-06 09:32:15 -08:00
powerpc Merge branch 'for-2.6.24' of master.kernel.org:/pub/scm/linux/kernel/git/galak/powerpc into merge 2007-12-14 16:46:50 +11:00
ppc [POWERPC] virtex bug fix: Use canonical value for AC97 interrupt xparams 2007-12-07 11:43:55 +11:00
s390 [S390] Make sure the restore psw masks are initialized. 2007-12-04 16:09:58 +01:00
sh sh: Support PCI IO access of SH7780 base boards. 2007-11-30 12:36:13 +09:00
sh64 sh64: Kill off duplicate includes. 2007-11-05 12:18:17 +09:00
sparc [SPARC]: Add missing of_node_put 2007-12-05 05:38:00 -08:00
sparc64 [SPARC64]: Fix two kernel linear mapping setup bugs. 2007-12-13 06:13:38 -08:00
um uml: stop gdb from deleting breakpoints when running UML 2007-12-17 19:28:15 -08:00
v850 spelling fixes: arch/v850/ 2007-10-20 01:24:05 +02:00
x86 revert "Hibernation: Use temporary page tables for kernel text mapping on x86_64" 2007-12-17 19:28:15 -08:00
xtensa [XTENSA]: Fix use of skb after netif_rx 2007-12-11 02:45:28 -08:00