Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 332459
b: refs/heads/master
c: 027ef6c
h: refs/heads/master
i:
  332457: c2dc17e
  332455: f61831d
v: v3
  • Loading branch information
Andrea Arcangeli authored and Linus Torvalds committed Oct 9, 2012
1 parent 7d7ebfd commit d11a9ca
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 00ea8990aadf754bbbb46ae85d4f2afba19508d8
refs/heads/master: 027ef6c87853b0a9df53175063028edb4950d476
11 changes: 8 additions & 3 deletions trunk/arch/x86/include/asm/pgtable.h
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,7 @@ static inline unsigned long pmd_pfn(pmd_t pmd)

static inline int pmd_large(pmd_t pte)
{
return (pmd_flags(pte) & (_PAGE_PSE | _PAGE_PRESENT)) ==
(_PAGE_PSE | _PAGE_PRESENT);
return pmd_flags(pte) & _PAGE_PSE;
}

#ifdef CONFIG_TRANSPARENT_HUGEPAGE
Expand Down Expand Up @@ -415,7 +414,13 @@ static inline int pte_hidden(pte_t pte)

static inline int pmd_present(pmd_t pmd)
{
return pmd_flags(pmd) & _PAGE_PRESENT;
/*
* Checking for _PAGE_PSE is needed too because
* split_huge_page will temporarily clear the present bit (but
* the _PAGE_PSE flag will remain set at all times while the
* _PAGE_PRESENT bit is clear).
*/
return pmd_flags(pmd) & (_PAGE_PRESENT | _PAGE_PROTNONE | _PAGE_PSE);
}

static inline int pmd_none(pmd_t pmd)
Expand Down

0 comments on commit d11a9ca

Please sign in to comment.