diff options
author | Nitin Gupta | 2017-03-03 14:40:44 -0800 |
---|---|---|
committer | David S. Miller | 2017-03-27 21:20:22 -0700 |
commit | 59f1183dd368f12c0a80da3c91a4a42afa4e1d38 (patch) | |
tree | b5eadcd8b4f7ee29debfca7167beb8158f954124 /arch/sparc | |
parent | ad0376eb1483bd9880770b346f6592aece669e4c (diff) |
sparc64: Fix size check in huge_pte_alloc
Signed-off-by: Nitin Gupta <nitin.m.gupta@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc')
-rw-r--r-- | arch/sparc/mm/hugetlbpage.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/sparc/mm/hugetlbpage.c b/arch/sparc/mm/hugetlbpage.c index 323bc6b6e3ad..30168500603e 100644 --- a/arch/sparc/mm/hugetlbpage.c +++ b/arch/sparc/mm/hugetlbpage.c @@ -261,7 +261,7 @@ pte_t *huge_pte_alloc(struct mm_struct *mm, if (!pmd) return NULL; - if (sz == PMD_SHIFT) + if (sz >= PMD_SIZE) pte = (pte_t *)pmd; else pte = pte_alloc_map(mm, pmd, addr); |