include/linux/hugetlb.h: use bool instead of int for hugepage_migration_supported()
PATCH 33/162 include/linux/hugetlb.h: use bool instead of int for hugepage_migration_supported()
From: Chen Gang <[email protected]>
Subject: include/linux/hugetlb.h: use bool instead of int for hugepage_migration_supported()
It is used as a pure bool function within kernel source wide.
Signed-off-by Chen Gang <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
include/linux/hugetlb.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
include/linux/hugetlb.h renamed from include/linux/hugetlb.h~include-linux-hugetlbh-use-bool-instead-of-int-for-hugepage_migration_supported +3 -3
@@ -452,12 +452,12 @@ static inline pgoff_t basepage_index(strextern void dissolve_free_huge_pages (unsigned long start_pfn,unsigned long end_pfn); -static inline int hugepage_migration_supported (struct hstate *h) +static inline bool hugepage_migration_supported (struct hstate *h) {#ifdef CONFIG_ARCH_ENABLE_HUGEPAGE_MIGRATION return huge_page_shift (h) ==PMD_SHIFT ;#else -return 0 ; +return false;#endif }
@@ -519,7 +519,7 @@ static inline pgoff_t basepage_index(strreturn page->index; }#define dissolve_free_huge_pages (s, e) do {} while (0) -#define hugepage_migration_supported (h) 0 +#define hugepage_migration_supported (h) falsestatic inline spinlock_t *huge_pte_lockptr (struct hstate *h,struct mm_struct *mm,pte_t *pte)
_