Re: kmalloc() of 4MB causes "kernel BUG at slab.c:1542!"

Timur Tabi (ttabi@interactivesi.com)
Wed, 17 Jan 2001 14:39:57 -0600


** Reply to message from Brian Pomerantz <bapper@piratehaven.org> on Wed, 17
Jan 2001 12:17:19 -0800

> The most you can kmalloc() is 128KB unless this has changed in the 2.4
> kernel which I doubt. If you want a region of memory that large, use
> vmalloc(). Of course, this doesn't guarantee a contiguous region.

Couldn't you also use get_free_pages (commonly abbreviated as "gfp")? You can
alloc up to 2MB chunks on an x86 I think.

-- 
Timur Tabi - ttabi@interactivesi.com
Interactive Silicon - http://www.interactivesi.com

When replying to a mailing-list message, please direct the reply to the mailing list only. Don't send another copy to me. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/