All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Mika Penttilä" <mika.penttila@kolumbus.fi>
To: linux-kernel@vger.kernel.org, linux-mm <linux-mm@kvack.org>,
	Andi Kleen <ak@suse.de>
Subject: DMA32 zone unusable
Date: Wed, 16 Nov 2005 17:22:24 +0200	[thread overview]
Message-ID: <437B4EB0.3080908@kolumbus.fi> (raw)

The new DMA32 zone (which at least x86-64 has) is quite "interesting" :

#define __GFP_DMA32    ((__force gfp_t)0x04) <-----!!!!!  

#define GFP_ZONEMASK    0x03   <------!!!!!

#define gfp_zone(mask) ((__force int)((mask) & (__force gfp_t)GFP_ZONEMASK))

static inline struct page *alloc_pages_node(int nid, gfp_t gfp_mask,
                        unsigned int order)
{
    if (unlikely(order >= MAX_ORDER))
        return NULL;

    return __alloc_pages(gfp_mask, order,
        NODE_DATA(nid)->node_zonelists + gfp_zone(gfp_mask));
}


So with GFP_DMA32 you never get those pages (but DMA instead).

--Mika


WARNING: multiple messages have this Message-ID (diff)
From: "Mika Penttilä" <mika.penttila@kolumbus.fi>
To: linux-kernel@vger.kernel.org, linux-mm <linux-mm@kvack.org>,
	Andi Kleen <ak@suse.de>
Subject: DMA32 zone unusable
Date: Wed, 16 Nov 2005 17:22:24 +0200	[thread overview]
Message-ID: <437B4EB0.3080908@kolumbus.fi> (raw)

The new DMA32 zone (which at least x86-64 has) is quite "interesting" :

#define __GFP_DMA32    ((__force gfp_t)0x04) <-----!!!!!  

#define GFP_ZONEMASK    0x03   <------!!!!!

#define gfp_zone(mask) ((__force int)((mask) & (__force gfp_t)GFP_ZONEMASK))

static inline struct page *alloc_pages_node(int nid, gfp_t gfp_mask,
                        unsigned int order)
{
    if (unlikely(order >= MAX_ORDER))
        return NULL;

    return __alloc_pages(gfp_mask, order,
        NODE_DATA(nid)->node_zonelists + gfp_zone(gfp_mask));
}


So with GFP_DMA32 you never get those pages (but DMA instead).

--Mika

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

             reply	other threads:[~2005-11-16 15:22 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-16 15:22 Mika Penttilä [this message]
2005-11-16 15:22 ` DMA32 zone unusable Mika Penttilä
2005-11-16 15:53 ` Andi Kleen
2005-11-16 15:53   ` Andi Kleen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=437B4EB0.3080908@kolumbus.fi \
    --to=mika.penttila@kolumbus.fi \
    --cc=ak@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.