From: Andi Kleen Fix vmalloc overflow with 4levels. Signed-off-by: Andi Kleen Signed-off-by: Andrew Morton --- 25-akpm/mm/vmalloc.c | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) diff -puN mm/vmalloc.c~4level-fix-vmalloc-overflow mm/vmalloc.c --- 25/mm/vmalloc.c~4level-fix-vmalloc-overflow Fri Nov 5 16:16:52 2004 +++ 25-akpm/mm/vmalloc.c Fri Nov 5 16:16:52 2004 @@ -213,7 +213,7 @@ int map_vm_area(struct vm_struct *area, err = -ENOMEM; break; } - next = (address + PGDIR_SIZE) & PGDIR_MASK; + next = (address + PML4_SIZE) & PML4_MASK; if (next < address || next > end) next = end; if (map_area_pgd(pgd, address, next, prot, pages)) { _