From: Jan Beulich Date: Thu, 15 May 2008 12:24:52 +0000 (+0100) Subject: x86/xen: fix arbitrary_virt_to_machine() X-Git-Tag: v2.6.26-rc4~11^2~3 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=de067814d6b69030d0030e1c5b3dbaf0385aae41;p=linux-2.6 x86/xen: fix arbitrary_virt_to_machine() While I realize that the function isn't currently being used, I still think an obvious mistake like this should be corrected. Signed-off-by: Jan Beulich Acked-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner --- diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c index 126766d43a..3525ef523a 100644 --- a/arch/x86/xen/mmu.c +++ b/arch/x86/xen/mmu.c @@ -60,7 +60,7 @@ xmaddr_t arbitrary_virt_to_machine(unsigned long address) { unsigned int level; pte_t *pte = lookup_address(address, &level); - unsigned offset = address & PAGE_MASK; + unsigned offset = address & ~PAGE_MASK; BUG_ON(pte == NULL);