Messages in this thread | | | Date | Tue, 15 Feb 2005 11:48:27 +0100 | From | Andrea Arcangeli <> | Subject | Re: fix iounmap and a pageattr memleak (x86 and x86-64) |
| |
On Tue, Feb 15, 2005 at 11:39:15AM +0100, Andi Kleen wrote: > On Tue, Feb 15, 2005 at 12:15:54AM +0100, Andrea Arcangeli wrote: > > Hello, > > > > the fix for this bug in 2.6.11-rc3 for this bug is wrong, I thought I > > Can you describe what exactly is wrong?
the wrong thing is that if I change the size of the guard page in vmalloc.c, the arch code will break. the guard page is a debugging knob, people may want to remove it someday to save virtual address space, and they shouldn't be required to look after N architectures.
Plus people will keep forgetting that p->size has the guard page included if you don't fix it the right way, x86-64 and x86 have been corrupting the pageattr of the next physical pages because of that for a long time.
Plus if you applied the best fix in vmalloc.c, you wouldn't even need to touch x86 and x86-64 arch dependent code, you could call change_page_attr on p->size without having to do -PAGE_SIZE.
At least you should define a VMALLOC_GUARD_PAGE_SIZE, or something, the hardcoding of p->size-PAGE_SIZE looks wrong to me. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |