Commit a3ae91b0 authored by Andi Kleen's avatar Andi Kleen Committed by Ingo Molnar

x86: cpa: remove unnecessary masking of address

virt_to_page does not care about the bits below the page granuality.
So don't mask them.
Signed-off-by: default avatarAndi Kleen <ak@suse.de>
Signed-off-by: default avatarHarvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 5b016432
......@@ -148,7 +148,7 @@ __change_page_attr(unsigned long address, unsigned long pfn, pgprot_t prot,
if (!kpte)
return 0;
kpte_page = virt_to_page(((unsigned long)kpte) & PAGE_MASK);
kpte_page = virt_to_page(kpte);
BUG_ON(PageLRU(kpte_page));
BUG_ON(PageCompound(kpte_page));
if (pgprot_val(prot) != pgprot_val(ref_prot)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment