s390/mm: forward check for huge pmds to pmd_large()
authorDominik Dingel <dingel@linux.vnet.ibm.com>
Thu, 25 Jun 2015 21:59:49 +0000 (14:59 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 26 Jun 2015 00:00:35 +0000 (17:00 -0700)
We already do the check in pmd_large, so we can just forward the call.

Signed-off-by: Dominik Dingel <dingel@linux.vnet.ibm.com>
Acked-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/s390/mm/hugetlbpage.c

index 3bbfd4f43ed77914bd631ece8340e37faeccbb5e..fb4bf2c4379e47585eac7ede67f0030cd701c1fa 100644 (file)
@@ -141,10 +141,7 @@ pte_t *huge_pte_offset(struct mm_struct *mm, unsigned long addr)
 
 int pmd_huge(pmd_t pmd)
 {
-       if (!MACHINE_HAS_HPAGE)
-               return 0;
-
-       return !!(pmd_val(pmd) & _SEGMENT_ENTRY_LARGE);
+       return pmd_large(pmd);
 }
 
 int pud_huge(pud_t pud)