mm/thp: remove redundant CONFIG_TRANSPARENT_HUGEPAGE
authorLiu Shixin <liushixin2@huawei.com>
Mon, 29 Aug 2022 09:51:25 +0000 (17:51 +0800)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 12 Sep 2022 03:26:05 +0000 (20:26 -0700)
Simplify code by removing redundant CONFIG_TRANSPARENT_HUGEPAGE judgment.

No functional change.

Link: https://lkml.kernel.org/r/20220829095125.3284567-1-liushixin2@huawei.com
Signed-off-by: Liu Shixin <liushixin2@huawei.com>
Cc: Kefeng Wang <wangkefeng.wang@huawei.com>
Cc: Matthew Wilcox <willy@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/pgtable.h

index 5911761487de9d8999095448309df737d9d29c92..d13b4f7cc5be9869d6a5e7d0f9a20850d9c375fa 100644 (file)
@@ -1276,8 +1276,7 @@ static inline int pgd_devmap(pgd_t pgd)
 #endif
 
 #if !defined(CONFIG_TRANSPARENT_HUGEPAGE) || \
-       (defined(CONFIG_TRANSPARENT_HUGEPAGE) && \
-        !defined(CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE_PUD))
+       !defined(CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE_PUD)
 static inline int pud_trans_huge(pud_t pud)
 {
        return 0;