diff options
| author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2008-04-19 12:17:29 -0400 |
|---|---|---|
| committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2008-04-19 12:17:29 -0400 |
| commit | adf6d34e460387ee3e8f1e1875d52bff51212c7d (patch) | |
| tree | 88ef100143e6184103a608f82dfd232bf6376eaf /arch/x86/kernel/step.c | |
| parent | d1964dab60ce7c104dd21590e987a8787db18051 (diff) | |
| parent | 3760d31f11bfbd0ead9eaeb8573e0602437a9d7c (diff) | |
Merge branch 'omap2-upstream' into devel
Diffstat (limited to 'arch/x86/kernel/step.c')
| -rw-r--r-- | arch/x86/kernel/step.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/arch/x86/kernel/step.c b/arch/x86/kernel/step.c index 9d406cdc847f..071ff4798236 100644 --- a/arch/x86/kernel/step.c +++ b/arch/x86/kernel/step.c | |||
| @@ -140,6 +140,9 @@ static int enable_single_step(struct task_struct *child) | |||
| 140 | */ | 140 | */ |
| 141 | static void write_debugctlmsr(struct task_struct *child, unsigned long val) | 141 | static void write_debugctlmsr(struct task_struct *child, unsigned long val) |
| 142 | { | 142 | { |
| 143 | if (child->thread.debugctlmsr == val) | ||
| 144 | return; | ||
| 145 | |||
| 143 | child->thread.debugctlmsr = val; | 146 | child->thread.debugctlmsr = val; |
| 144 | 147 | ||
| 145 | if (child != current) | 148 | if (child != current) |
| @@ -165,11 +168,11 @@ static void enable_step(struct task_struct *child, bool block) | |||
| 165 | write_debugctlmsr(child, | 168 | write_debugctlmsr(child, |
| 166 | child->thread.debugctlmsr | DEBUGCTLMSR_BTF); | 169 | child->thread.debugctlmsr | DEBUGCTLMSR_BTF); |
| 167 | } else { | 170 | } else { |
| 168 | write_debugctlmsr(child, | 171 | write_debugctlmsr(child, |
| 169 | child->thread.debugctlmsr & ~DEBUGCTLMSR_BTF); | 172 | child->thread.debugctlmsr & ~DEBUGCTLMSR_BTF); |
| 170 | 173 | ||
| 171 | if (!child->thread.debugctlmsr) | 174 | if (!child->thread.debugctlmsr) |
| 172 | clear_tsk_thread_flag(child, TIF_DEBUGCTLMSR); | 175 | clear_tsk_thread_flag(child, TIF_DEBUGCTLMSR); |
| 173 | } | 176 | } |
| 174 | } | 177 | } |
| 175 | 178 | ||
