Skip to contentSkip to conversation

Remove #ifdefs from linux/mm.h

PATCH New David Howells 1 participant 1 message Dec 15, 2004 MM core

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Remove #ifdefs from linux/mm.h

The attached patch removes some now unnecessary #ifdefs from linux/mm.h. This is possible because we're now using the proper vm_area_struct structure.

---
warthog>lsdiff nommu-ifdef-2610rc3.diff
linux-2.6.10-rc3-mm1-base/include/linux/mm.h

include/linux/mm.h +0 -4
diff -uNrp linux-2.6.10-rc3-mm1-base/include/linux/mm.h linux-2.6.10-rc3-mm1-nommu-rb/include/linux/mm.h
@@ -724,14 +724,12 @@ struct vm_area_struct *vma_prio_tree_nex
 	for (prio_tree_iter_init(iter, root, begin, end), vma = NULL;	\
 		(vma = vma_prio_tree_next(vma, iter)); )
 
-#ifdef CONFIG_MMU
 static inline void vma_nonlinear_insert(struct vm_area_struct *vma,
 					struct list_head *list)
 {
 	vma->shared.vm_set.parent = NULL;
 	list_add_tail(&vma->shared.vm_set.list, list);
 }
-#endif
 
 /* mmap.c */
 extern void vma_adjust(struct vm_area_struct *vma, unsigned long start,
@@ -849,7 +847,6 @@ static inline void __vm_stat_account(str
 }
 #endif /* CONFIG_PROC_FS */
 
-#ifdef CONFIG_MMU
 static inline void vm_stat_account(struct vm_area_struct *vma)
 {
 	__vm_stat_account(vma->vm_mm, vma->vm_flags, vma->vm_file,
@@ -861,7 +858,6 @@ static inline void vm_stat_unaccount(str
 	__vm_stat_account(vma->vm_mm, vma->vm_flags, vma->vm_file,
 							-vma_pages(vma));
 }
-#endif
 
 /* update per process rss and vm hiwater data */
 extern void update_mem_hiwater(void);