diff options
Diffstat (limited to 'include/linux/mm.h')
-rw-r--r-- | include/linux/mm.h | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h index 709f6728fc90..e6b1210772ce 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 | ||
@@ -1330,8 +1334,10 @@ unsigned long ra_submit(struct file_ra_state *ra, | |||
1330 | 1334 | ||
1331 | /* Do stack extension */ | 1335 | /* Do stack extension */ |
1332 | extern int expand_stack(struct vm_area_struct *vma, unsigned long address); | 1336 | extern int expand_stack(struct vm_area_struct *vma, unsigned long address); |
1333 | #ifdef CONFIG_IA64 | 1337 | #if VM_GROWSUP |
1334 | extern int expand_upwards(struct vm_area_struct *vma, unsigned long address); | 1338 | extern int expand_upwards(struct vm_area_struct *vma, unsigned long address); |
1339 | #else | ||
1340 | #define expand_upwards(vma, address) do { } while (0) | ||
1335 | #endif | 1341 | #endif |
1336 | extern int expand_stack_downwards(struct vm_area_struct *vma, | 1342 | extern int expand_stack_downwards(struct vm_area_struct *vma, |
1337 | unsigned long address); | 1343 | unsigned long address); |
@@ -1357,7 +1363,15 @@ static inline unsigned long vma_pages(struct vm_area_struct *vma) | |||
1357 | return (vma->vm_end - vma->vm_start) >> PAGE_SHIFT; | 1363 | return (vma->vm_end - vma->vm_start) >> PAGE_SHIFT; |
1358 | } | 1364 | } |
1359 | 1365 | ||
1366 | #ifdef CONFIG_MMU | ||
1360 | pgprot_t vm_get_page_prot(unsigned long vm_flags); | 1367 | pgprot_t vm_get_page_prot(unsigned long vm_flags); |
1368 | #else | ||
1369 | static inline pgprot_t vm_get_page_prot(unsigned long vm_flags) | ||
1370 | { | ||
1371 | return __pgprot(0); | ||
1372 | } | ||
1373 | #endif | ||
1374 | |||
1361 | struct vm_area_struct *find_extend_vma(struct mm_struct *, unsigned long addr); | 1375 | struct vm_area_struct *find_extend_vma(struct mm_struct *, unsigned long addr); |
1362 | int remap_pfn_range(struct vm_area_struct *, unsigned long addr, | 1376 | int remap_pfn_range(struct vm_area_struct *, unsigned long addr, |
1363 | unsigned long pfn, unsigned long size, pgprot_t); | 1377 | unsigned long pfn, unsigned long size, pgprot_t); |