aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mm.h
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2010-08-31 03:45:21 -0400
committerIngo Molnar <mingo@elte.hu>2010-08-31 03:45:46 -0400
commitdaab7fc734a53fdeaf844b7c03053118ad1769da (patch)
tree575deb3cdcc6dda562acaed6f7c29bc81ae01cf2 /include/linux/mm.h
parent774ea0bcb27f57b6fd521b3b6c43237782fed4b9 (diff)
parent2bfc96a127bc1cc94d26bfaa40159966064f9c8c (diff)
Merge commit 'v2.6.36-rc3' into x86/memblock
Conflicts: arch/x86/kernel/trampoline.c mm/memblock.c Merge reason: Resolve the conflicts, update to latest upstream. Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/mm.h')
-rw-r--r--include/linux/mm.h25
1 files changed, 24 insertions, 1 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h
index 993e85f0afcb..c0cceded7683 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -78,7 +78,11 @@ extern unsigned int kobjsize(const void *objp);
78#define VM_MAYSHARE 0x00000080 78#define VM_MAYSHARE 0x00000080
79 79
80#define VM_GROWSDOWN 0x00000100 /* general info on the segment */ 80#define VM_GROWSDOWN 0x00000100 /* general info on the segment */
81#if defined(CONFIG_STACK_GROWSUP) || defined(CONFIG_IA64)
81#define VM_GROWSUP 0x00000200 82#define VM_GROWSUP 0x00000200
83#else
84#define VM_GROWSUP 0x00000000
85#endif
82#define VM_PFNMAP 0x00000400 /* Page-ranges managed without "struct page", just pure PFN */ 86#define VM_PFNMAP 0x00000400 /* Page-ranges managed without "struct page", just pure PFN */
83#define VM_DENYWRITE 0x00000800 /* ETXTBSY on write attempts.. */ 87#define VM_DENYWRITE 0x00000800 /* ETXTBSY on write attempts.. */
84 88
@@ -815,6 +819,7 @@ static inline void unmap_shared_mapping_range(struct address_space *mapping,
815} 819}
816 820
817extern void truncate_pagecache(struct inode *inode, loff_t old, loff_t new); 821extern void truncate_pagecache(struct inode *inode, loff_t old, loff_t new);
822extern void truncate_setsize(struct inode *inode, loff_t newsize);
818extern int vmtruncate(struct inode *inode, loff_t offset); 823extern int vmtruncate(struct inode *inode, loff_t offset);
819extern int vmtruncate_range(struct inode *inode, loff_t offset, loff_t end); 824extern int vmtruncate_range(struct inode *inode, loff_t offset, loff_t end);
820 825
@@ -1331,8 +1336,10 @@ unsigned long ra_submit(struct file_ra_state *ra,
1331 1336
1332/* Do stack extension */ 1337/* Do stack extension */
1333extern int expand_stack(struct vm_area_struct *vma, unsigned long address); 1338extern int expand_stack(struct vm_area_struct *vma, unsigned long address);
1334#ifdef CONFIG_IA64 1339#if VM_GROWSUP
1335extern int expand_upwards(struct vm_area_struct *vma, unsigned long address); 1340extern int expand_upwards(struct vm_area_struct *vma, unsigned long address);
1341#else
1342 #define expand_upwards(vma, address) do { } while (0)
1336#endif 1343#endif
1337extern int expand_stack_downwards(struct vm_area_struct *vma, 1344extern int expand_stack_downwards(struct vm_area_struct *vma,
1338 unsigned long address); 1345 unsigned long address);
@@ -1358,7 +1365,15 @@ static inline unsigned long vma_pages(struct vm_area_struct *vma)
1358 return (vma->vm_end - vma->vm_start) >> PAGE_SHIFT; 1365 return (vma->vm_end - vma->vm_start) >> PAGE_SHIFT;
1359} 1366}
1360 1367
1368#ifdef CONFIG_MMU
1361pgprot_t vm_get_page_prot(unsigned long vm_flags); 1369pgprot_t vm_get_page_prot(unsigned long vm_flags);
1370#else
1371static inline pgprot_t vm_get_page_prot(unsigned long vm_flags)
1372{
1373 return __pgprot(0);
1374}
1375#endif
1376
1362struct vm_area_struct *find_extend_vma(struct mm_struct *, unsigned long addr); 1377struct vm_area_struct *find_extend_vma(struct mm_struct *, unsigned long addr);
1363int remap_pfn_range(struct vm_area_struct *, unsigned long addr, 1378int remap_pfn_range(struct vm_area_struct *, unsigned long addr,
1364 unsigned long pfn, unsigned long size, pgprot_t); 1379 unsigned long pfn, unsigned long size, pgprot_t);
@@ -1467,6 +1482,14 @@ extern int sysctl_memory_failure_recovery;
1467extern void shake_page(struct page *p, int access); 1482extern void shake_page(struct page *p, int access);
1468extern atomic_long_t mce_bad_pages; 1483extern atomic_long_t mce_bad_pages;
1469extern int soft_offline_page(struct page *page, int flags); 1484extern int soft_offline_page(struct page *page, int flags);
1485#ifdef CONFIG_MEMORY_FAILURE
1486int is_hwpoison_address(unsigned long addr);
1487#else
1488static inline int is_hwpoison_address(unsigned long addr)
1489{
1490 return 0;
1491}
1492#endif
1470 1493
1471extern void dump_page(struct page *page); 1494extern void dump_page(struct page *page);
1472 1495