patch-2.3.27 linux/mm/vmalloc.c
Next file: linux/mm/vmscan.c
Previous file: linux/mm/swapfile.c
Back to the patch index
Back to the overall index
- Lines: 27
- Date:
Thu Nov 11 10:33:42 1999
- Orig file:
v2.3.26/linux/mm/vmalloc.c
- Orig date:
Wed Oct 27 16:34:12 1999
diff -u --recursive --new-file v2.3.26/linux/mm/vmalloc.c linux/mm/vmalloc.c
@@ -10,7 +10,7 @@
#include <asm/uaccess.h>
-static struct vm_struct * vmlist = NULL;
+struct vm_struct * vmlist = NULL;
static inline void free_area_pte(pmd_t * pmd, unsigned long address, unsigned long size)
{
@@ -97,7 +97,7 @@
struct page * page;
if (!pte_none(*pte))
printk(KERN_ERR "alloc_area_pte: page already exists\n");
- page = get_free_highpage(GFP_KERNEL|__GFP_HIGHMEM);
+ page = alloc_page(GFP_KERNEL|__GFP_HIGHMEM);
if (!page)
return -ENOMEM;
set_pte(pte, mk_pte(page, PAGE_KERNEL));
@@ -204,7 +204,7 @@
struct vm_struct *area;
size = PAGE_ALIGN(size);
- if (!size || size > (max_mapnr << PAGE_SHIFT)) {
+ if (!size || (size >> PAGE_SHIFT) > max_mapnr) {
BUG();
return NULL;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)