lkml.org 
[lkml]   [2007]   [Jun]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: __get_free_pages: can GFP_DMA omit GFP_KERNEL and GFP_ATOMIC?
On Mon, 4 Jun 2007, Christoph Lameter wrote:

> On Sun, 3 Jun 2007, Robert P. J. Day wrote:
>
> > first, can a call to __get_free_pages to allocate DMA-able
> > memory omit specifying either of GFP_KERNEL or GFP_ATOMIC?
> > love's book on kernel development strongly suggests you need to
> > specify one or the other, but there are a few instances in the
> > tree like this:
>
> Sure that seems to be equivalent to GFP_ATOMIC with no access to
> emergency pool memory.
>
> > and, second, i only noticed this as i was going to submit a
> > short patch to replace __get_free_pages calls for DMA-able memory
> > with the existing equivalent macro __get_dma_pages. is that still
> > considered a worthwhile cleanup? there's not that many examples
> > of it, and it would just make things consistent.
>
> Sure.

all right, then some of those __get_free_pages() calls would translate
to calls of the form __get_dma_pages(0, ...) -- is that what you're
saying? or would it be equivalent and preferable to put GFP_ATOMIC in
there just so it looks not so weird?

rday
--
========================================================================
Robert P. J. Day
Linux Consulting, Training and Annoying Kernel Pedantry
Waterloo, Ontario, CANADA

http://fsdev.net/wiki/index.php?title=Main_Page
========================================================================
-
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-06-04 20:57    [W:0.064 / U:0.620 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site