lkml.org 
[lkml]   [2007]   [May]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: How to guarantee that kmalloc returns an address below 4GB
On Wed, 16 May 2007, Stefan Richter wrote:

> Cestonaro, Thilo (external) wrote:
> > is there an option for kmalloc, which I can use to allocate
> > a buffer which is in physical memory placed below 4GB?
> > Not in a remapped area.
>
> GFP_DMA32

Nope. There are no general slabs available for DMA32.

You could use a dma slab by specifying GFP_DMA. However, on i386 and
x86_64 this will get you memory in the precious first 16MB. On IA64 and
other platforms you will get memory < 4GB.

Another option is to use the page allocator and specify GFP_DMA32.

-
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/

\
 
 \ /
  Last update: 2007-05-17 20:51    [W:0.025 / U:1.564 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site