linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: bob.beckett@gmail.com (Robert Beckett)
To: linux-arm-kernel@lists.infradead.org
Subject: arm_vmregion_alloc call
Date: Mon, 2 Jul 2012 14:57:48 +0100	[thread overview]
Message-ID: <CAOmFF10btho+hqFSKpkqr_QDOWbFzOTKNHJL2FsZ9BvHM7DdHQ@mail.gmail.com> (raw)

Hello all,

I just debugged a problem with a USB driver where it was calling
dma_alloc_coherent with a GFP_DMA32 flag.
It turned out that in __dma_alloc_remap, it clears the GFP_DMA and
GFP_HIGHMEM flags when calling arm_vmregion_alloc so that it does not
clash with the slab allocator flag requirements, but it does not clear
GFP_DMA32. The GFP_SLAB_BUG_MASK includes GFP_DMA32, so this looks
like a bug to me. Should it be clearing GFP_DMA32 as well as GFP_DMA
and GFP_HIGHMEM ?

I checked in the latest kernel.org code, and the issue is still there.

Is this a bug, or should it just be calling with GFP_DMA instead of GFP_DMA32?

For now, I am working around it by using GFP_DMA in the
dma_alloc_coherent call as we have no GFP_DMA lower limit, so GFP_DMA
and GFP_DMA32 are the same on my architecture.

Any advice appreciated,

Thanks

Bob

p.s. apologies if this sent multiple times, Im trying to work around
the mailing list "suspicious header" moderation...

             reply	other threads:[~2012-07-02 13:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-02 13:57 Robert Beckett [this message]
  -- strict thread matches above, loose matches on Subject: below --
2012-07-02 13:52 arm_vmregion_alloc call Robert Beckett
     [not found] <CAOmFF13Cif=K62oHR3QEg-ni0X0EopxtOXM7LGkF9FJd2WCZKg@mail.gmail.com>
2012-07-02 13:48 ` Robert Beckett

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=CAOmFF10btho+hqFSKpkqr_QDOWbFzOTKNHJL2FsZ9BvHM7DdHQ@mail.gmail.com \
    --to=bob.beckett@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).