Re: [PATCH 16 of 66] special pmd_trans_* functions

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Andrea Arcangeli
Date: Thursday, November 25, 2010 - 10:10 am

On Thu, Nov 18, 2010 at 12:51:12PM +0000, Mel Gorman wrote:

It doesn't seem to fail build on x86-64 and x86, so it should build
for all other archs too. I'm keeping this incremental at the end just
in case.

diff --git a/include/asm-generic/pgtable.h b/include/asm-generic/pgtable.h
--- a/include/asm-generic/pgtable.h
+++ b/include/asm-generic/pgtable.h
@@ -471,10 +471,20 @@ extern void untrack_pfn_vma(struct vm_ar
 #endif
 
 #ifndef CONFIG_TRANSPARENT_HUGEPAGE
-#define pmd_trans_huge(pmd) 0
-#define pmd_trans_splitting(pmd) 0
+static inline int pmd_trans_huge(pmd_t pmd)
+{
+	return 0;
+}
+static inline int pmd_trans_splitting(pmd_t pmd)
+{
+	return 0;
+}
 #ifndef __HAVE_ARCH_PMD_WRITE
-#define pmd_write(pmd)	({ BUG(); 0; })
+static inline int pmd_write(pmd_t pmd)
+{
+	BUG();
+	return 0;
+}
 #endif /* __HAVE_ARCH_PMD_WRITE */
 #endif
 
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 16 of 66] special pmd_trans_* functions, Andrea Arcangeli, (Wed Nov 3, 8:27 am)
Re: [PATCH 16 of 66] special pmd_trans_* functions, Mel Gorman, (Thu Nov 18, 5:51 am)
Re: [PATCH 16 of 66] special pmd_trans_* functions, Andrea Arcangeli, (Thu Nov 25, 10:10 am)