Skip to content

Commit

Permalink
x86: cpa: fix split thinko
Browse files Browse the repository at this point in the history
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
  • Loading branch information
Thomas Gleixner authored and Ingo Molnar committed Jan 30, 2008
1 parent 3c1df68 commit a72a08a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions arch/x86/mm/pageattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -216,8 +216,12 @@ __change_page_attr(unsigned long address, unsigned long pfn, pgprot_t prot)
prot = static_protections(prot, address);

if (level == PG_LEVEL_4K) {
WARN_ON_ONCE(pgprot_val(prot) & _PAGE_PSE);
set_pte_atomic(kpte, pfn_pte(pfn, canon_pgprot(prot)));
} else {
/* Clear the PSE bit for the 4k level pages ! */
pgprot_val(prot) = pgprot_val(prot) & ~_PAGE_PSE;

err = split_large_page(kpte, address);
if (!err)
goto repeat;
Expand Down

0 comments on commit a72a08a

Please sign in to comment.