]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ptrace/x86: simplify the "disable" logic in ptrace_write_dr7()
authorOleg Nesterov <oleg@redhat.com>
Fri, 7 Jun 2013 00:09:35 +0000 (10:09 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Mon, 17 Jun 2013 08:20:15 +0000 (18:20 +1000)
commit3c8af0541b524faeeb088bf41eac6739f759b4bd
treea4e1cf572fdb62b30f8999e344c21e74bc2cb9f1
parente9d03579ff60f6b474080c28a56b60c42f2289a0
ptrace/x86: simplify the "disable" logic in ptrace_write_dr7()

ptrace_write_dr7() looks unnecessarily overcomplicated.  We can factor out
ptrace_modify_breakpoint() and do not do "continue" twice, just we need to
pass the proper "disabled" argument to ptrace_modify_breakpoint().

Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Acked-by: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jan Kratochvil <jan.kratochvil@redhat.com>
Cc: Michael Neuling <mikey@neuling.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Will Deacon <will.deacon@arm.com>
Cc: Prasad <prasad@linux.vnet.ibm.com>
Cc: Russell King <linux@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/x86/kernel/ptrace.c