summaryrefslogtreecommitdiffstats
path: root/arch/x86
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-10-22 20:35:12 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2010-10-22 20:35:12 -0700
commit8814011679d1a47d8b0158fc991727a5859471a0 (patch)
treef5d84ea8dba4fb7e18312deb04ff51ba35f9b901 /arch/x86
parent5cc103506289de7ee0a0b526ae0381541990cad4 (diff)
parent495363d380b4f4745bd8677912688654afc44020 (diff)
downloadblackbird-obmc-linux-8814011679d1a47d8b0158fc991727a5859471a0.tar.gz
blackbird-obmc-linux-8814011679d1a47d8b0158fc991727a5859471a0.zip
Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/linux-2.6-kgdb
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/linux-2.6-kgdb: kdb,debug_core: adjust master cpu switch logic against new debug_core locking debug_core: refactor locking for master/slave cpus x86,kgdb: remove unnecessary call to kgdb_correct_hw_break() debug_core: disable hw_breakpoints on all cores in kgdb_cpu_enter() kdb,kgdb: fix sparse fixups kdb: Fix oops in kdb_unregister kdb,ftdump: Remove reference to internal kdb include kdb: Allow kernel loadable modules to add kdb shell functions debug_core: stop rcu warnings on kernel resume debug_core: move all watch dog syncs to a single function x86,kgdb: fix debugger hw breakpoint test regression in 2.6.35
Diffstat (limited to 'arch/x86')
-rw-r--r--arch/x86/kernel/kgdb.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/arch/x86/kernel/kgdb.c b/arch/x86/kernel/kgdb.c
index 852b81967a37..d81cfebb848f 100644
--- a/arch/x86/kernel/kgdb.c
+++ b/arch/x86/kernel/kgdb.c
@@ -477,8 +477,6 @@ int kgdb_arch_handle_exception(int e_vector, int signo, int err_code,
raw_smp_processor_id());
}
- kgdb_correct_hw_break();
-
return 0;
}
@@ -621,7 +619,12 @@ int kgdb_arch_init(void)
static void kgdb_hw_overflow_handler(struct perf_event *event, int nmi,
struct perf_sample_data *data, struct pt_regs *regs)
{
- kgdb_ll_trap(DIE_DEBUG, "debug", regs, 0, 0, SIGTRAP);
+ struct task_struct *tsk = current;
+ int i;
+
+ for (i = 0; i < 4; i++)
+ if (breakinfo[i].enabled)
+ tsk->thread.debugreg6 |= (DR_TRAP0 << i);
}
void kgdb_arch_late(void)
@@ -644,7 +647,7 @@ void kgdb_arch_late(void)
if (breakinfo[i].pev)
continue;
breakinfo[i].pev = register_wide_hw_breakpoint(&attr, NULL);
- if (IS_ERR(breakinfo[i].pev)) {
+ if (IS_ERR((void * __force)breakinfo[i].pev)) {
printk(KERN_ERR "kgdb: Could not allocate hw"
"breakpoints\nDisabling the kernel debugger\n");
breakinfo[i].pev = NULL;
OpenPOWER on IntegriCloud