[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen master] x86/PVH: only set accessed/busy bits for present segments
commit 7d953e82632229ca1de8df5ede76d391b04645f8 Author: Jan Beulich <jbeulich@xxxxxxxx> AuthorDate: Tue Jan 24 12:36:30 2017 +0100 Commit: Jan Beulich <jbeulich@xxxxxxxx> CommitDate: Tue Jan 24 12:36:30 2017 +0100 x86/PVH: only set accessed/busy bits for present segments Commit 366ff5f1b3 ("x86: segment attribute handling adjustments" went a little too far: We must not do such adjustments for non-present segments. Reported-by: Roger Pau Monné <roger.pau@xxxxxxxxxx> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx> Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx> Reviewed-by: Roger Pau Monné <roger.pau@xxxxxxxxxx> Tested-by: Roger Pau Monné <roger.pau@xxxxxxxxxx> --- xen/arch/x86/domain.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/xen/arch/x86/domain.c b/xen/arch/x86/domain.c index 5a4e7f9..71c0e3c 100644 --- a/xen/arch/x86/domain.c +++ b/xen/arch/x86/domain.c @@ -1374,8 +1374,10 @@ int arch_set_info_hvm_guest(struct vcpu *v, const vcpu_hvm_context_t *ctx) #define SEG(s, r) ({ \ s = (struct segment_register){ .base = (r)->s ## _base, \ .limit = (r)->s ## _limit, \ - .attr.bytes = (r)->s ## _ar | \ - (x86_seg_##s != x86_seg_tr ? 1 : 2) }; \ + .attr.bytes = (r)->s ## _ar }; \ + /* Set accessed / busy bit for present segments. */ \ + if ( s.attr.fields.p ) \ + s.attr.fields.type |= (x86_seg_##s != x86_seg_tr ? 1 : 2); \ check_segment(&s, x86_seg_ ## s); }) rc = SEG(cs, regs); -- generated by git-patchbot for /home/xen/git/xen.git#master _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxx https://lists.xenproject.org/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |