diff options
author | Miguel de Icaza <miguel@nuclecu.unam.mx> | 1997-07-31 22:57:10 +0000 |
---|---|---|
committer | Miguel de Icaza <miguel@nuclecu.unam.mx> | 1997-07-31 22:57:10 +0000 |
commit | 9765588f1533bde5f6af8056525368b301d72989 (patch) | |
tree | eecfacde0115baf8cd67323981b2e20404fc683d /include/linux | |
parent | 5fd44fa07fcc1a00e75622a2ae5f6463a6c06be0 (diff) |
Changes required to share a piece of memory between kernel in
interrupt-land and a user application.
Vmalloc is now an inline function that calls vmalloc_prot with
the original protection bits used in vmalloc.
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/mm.h | 2 | ||||
-rw-r--r-- | include/linux/vmalloc.h | 11 |
2 files changed, 10 insertions, 3 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h index bfde668c7..674f69479 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -273,7 +273,7 @@ extern void zap_page_range(struct mm_struct *mm, unsigned long address, unsigned extern int copy_page_range(struct mm_struct *dst, struct mm_struct *src, struct vm_area_struct *vma); extern int remap_page_range(unsigned long from, unsigned long to, unsigned long size, pgprot_t prot); extern int zeromap_page_range(unsigned long from, unsigned long size, pgprot_t prot); - +extern int vmap_page_range (unsigned long from, unsigned long size, unsigned long vaddr); extern void vmtruncate(struct inode * inode, unsigned long offset); extern void handle_mm_fault(struct task_struct *tsk,struct vm_area_struct *vma, unsigned long address, int write_access); diff --git a/include/linux/vmalloc.h b/include/linux/vmalloc.h index 40072ab47..ad7447530 100644 --- a/include/linux/vmalloc.h +++ b/include/linux/vmalloc.h @@ -15,10 +15,17 @@ struct vm_struct { struct vm_struct * get_vm_area(unsigned long size); void vfree(void * addr); -void * vmalloc(unsigned long size); +void * vmalloc_prot(unsigned long size, pgprot_t prot); +void * vmalloc_uncached(unsigned long size); + +extern inline void * vmalloc(unsigned long size) +{ + vmalloc_prot (size, PAGE_KERNEL); +} + int vread(char *buf, char *addr, int count); void vmfree_area_pages(unsigned long address, unsigned long size); -int vmalloc_area_pages(unsigned long address, unsigned long size); +int vmalloc_area_pages(unsigned long address, unsigned long size, pgprot_t prot); extern inline void set_pgdir(unsigned long address, pgd_t entry) { |