aboutsummaryrefslogtreecommitdiff
path: root/target-i386/seg_helper.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@twiddle.net>2015-09-15 11:45:08 -0700
committerEduardo Habkost <ehabkost@redhat.com>2015-10-23 12:59:27 -0200
commit93d00d0fbe4711061834730fb70525d167b6f908 (patch)
tree32e7d5e9545ff139ca92912129eae886cb28d438 /target-i386/seg_helper.c
parente265e3e48049fbece9eaf536aa00ca41aa3c54d0 (diff)
target-i386: Introduce cpu_x86_update_dr7
This moves the last of the iteration over breakpoints into the bpt_helper.c file. This also allows us to make several breakpoint functions static. Signed-off-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'target-i386/seg_helper.c')
-rw-r--r--target-i386/seg_helper.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/target-i386/seg_helper.c b/target-i386/seg_helper.c
index 1cbe559366..20ee892224 100644
--- a/target-i386/seg_helper.c
+++ b/target-i386/seg_helper.c
@@ -501,13 +501,7 @@ static void switch_tss_ra(CPUX86State *env, int tss_selector,
#ifndef CONFIG_USER_ONLY
/* reset local breakpoints */
if (env->dr[7] & DR7_LOCAL_BP_MASK) {
- for (i = 0; i < DR7_MAX_BP; i++) {
- if (hw_local_breakpoint_enabled(env->dr[7], i) &&
- !hw_global_breakpoint_enabled(env->dr[7], i)) {
- hw_breakpoint_remove(env, i);
- }
- }
- env->dr[7] &= ~DR7_LOCAL_BP_MASK;
+ cpu_x86_update_dr7(env, env->dr[7] & ~DR7_LOCAL_BP_MASK);
}
#endif
}