diff options
author | Jan Beulich <jbeulich@suse.com> | 2013-01-07 13:28:29 +0100 |
---|---|---|
committer | Jan Beulich <jbeulich@suse.com> | 2013-01-07 13:28:29 +0100 |
commit | 1e86302d8c2ea279fee66ee7c2368258426ef876 (patch) | |
tree | fd827a8dc11cfe1981da9c48ef7e095c8f1c12be /xen/arch/x86/x86_64 | |
parent | 4e3c592c93d7dbe02ca36878457515d30fe931d2 (diff) | |
download | xen-1e86302d8c2ea279fee66ee7c2368258426ef876.tar.gz xen-1e86302d8c2ea279fee66ee7c2368258426ef876.tar.bz2 xen-1e86302d8c2ea279fee66ee7c2368258426ef876.zip |
x86: compat_show_guest_stack() should not truncate MFN
Re-using "addr" here was a mistake, as it is a 32-bit quantity.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Keir Fraser <keir@xen.org>
Diffstat (limited to 'xen/arch/x86/x86_64')
-rw-r--r-- | xen/arch/x86/x86_64/compat/traps.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/xen/arch/x86/x86_64/compat/traps.c b/xen/arch/x86/x86_64/compat/traps.c index 39c5656353..7add636a10 100644 --- a/xen/arch/x86/x86_64/compat/traps.c +++ b/xen/arch/x86/x86_64/compat/traps.c @@ -20,11 +20,12 @@ void compat_show_guest_stack(struct vcpu *v, struct cpu_user_regs *regs, if ( v != current ) { struct vcpu *vcpu; + unsigned long mfn; ASSERT(guest_kernel_mode(v, regs)); - addr = read_cr3() >> PAGE_SHIFT; + mfn = read_cr3() >> PAGE_SHIFT; for_each_vcpu( v->domain, vcpu ) - if ( pagetable_get_pfn(vcpu->arch.guest_table) == addr ) + if ( pagetable_get_pfn(vcpu->arch.guest_table) == mfn ) break; if ( !vcpu ) { |