linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Takashi Iwai <tiwai@suse.de>
Cc: linuxppc-dev <linuxppc-dev@lists.ozlabs.org>
Subject: Re: [PATCH] powerpc: Implement dma_mmap_coherent()
Date: Fri, 25 Mar 2011 20:11:57 +1100	[thread overview]
Message-ID: <1301044317.2402.475.camel@pasglop> (raw)
In-Reply-To: <s5h62r7vd2w.wl%tiwai@suse.de>

On Fri, 2011-03-25 at 09:06 +0100, Takashi Iwai wrote:
> > @@ -52,6 +53,7 @@ extern void __dma_sync_page(struct page *page,
> unsigned long offset,
> >  #define __dma_free_coherent(size, addr)              ((void)0)
> >  #define __dma_sync(addr, size, rw)           ((void)0)
> >  #define __dma_sync_page(pg, off, sz, rw)     ((void)0)
> > +#define __dma_get_coherent_pfn(cpu_addr)     (0)
> 
> Just nitpicking: shouldn't we define some real thing like
>         page_to_pfn(virt_to_page(cpu_addr))
> or put something to trigger an error?  Setting a bogus zero can be
> easily overlooked, I'm afraid.

Yes, all those variants are bogus if you noticed :-) The trick is that
they aren't actually called when CONFIG_NOT_COHERENT_CACHE is not set
anyways, with the exception of __dma_sync(), so I want to just remove
them all. But I'll do that in a separate patch.

Cheers,
Ben.

  reply	other threads:[~2011-03-25  9:12 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-25  6:50 [PATCH] powerpc: Implement dma_mmap_coherent() Benjamin Herrenschmidt
2011-03-25  8:06 ` Takashi Iwai
2011-03-25  9:11   ` Benjamin Herrenschmidt [this message]
2011-03-25  9:13     ` Takashi Iwai
2011-03-29  0:30 ` Benjamin Herrenschmidt
  -- strict thread matches above, loose matches on Subject: below --
2011-03-31 20:39 Gerhard Pircher
2011-03-31 21:05 ` Benjamin Herrenschmidt

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=1301044317.2402.475.camel@pasglop \
    --to=benh@kernel.crashing.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=tiwai@suse.de \
    /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).