[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <1244586879.24481.19.camel@pasglop>
Date: Wed, 10 Jun 2009 08:34:39 +1000
From: Benjamin Herrenschmidt <benh@...nel.crashing.org>
To: subrata@...ux.vnet.ibm.com
Cc: Greg KH <greg@...ah.com>, fmhess@...rs.sourceforge.net,
Ian Abbott <abbotti@....co.uk>,
David Miller <davem@...emloft.net>, sachinp@...ux.vnet.ibm.com,
sfr@...b.auug.org.au, linux-kernel@...r.kernel.org,
Linuxppc-dev@...abs.org, linux-next@...r.kernel.org,
paulus@...ba.org, Geert.Uytterhoeven@...ycom.com,
geert@...ux-m68k.org
Subject: Re: [BUILD FAILURE 01/04] Next June 04:PPC64 randconfig
[drivers/staging/comedi/drivers.o]
> > In any case, doing PAGE_KERNEL_NOCACHE for DMA memory is incorrect on
> > many architectures. So at this stage, there's no much option but ifdef I
> > suspect for now until this is fixed properly.
>
> Ok. But, i am not sure whether Greg will agree to this. If, Ok, is the
> following patch i sent earlier Ok ?
>
> http://lkml.org/lkml/2009/6/5/462,
Not really.
You probably want to use a constant (call it MY_DMA_MAP_PGPROT), and
in a header, you have a bunch of ifdef's that set it to PAGE_KERNEL,
PAGE_KERNEL_NOCACHE or PAGE_KERNEL_NC depending on what's needed.
Today, you can pretty much assume that
- x86*, sparc*, ia64*, alpha, ... needs PAGE_KERNEL
- powerpc needs PAGE_KERNEL if !CONFIG_NOT_COHERENT_CACHE
- powerpc needs PAGE_KERNEL_NC if CONFIG_NOT_COHERENT_CACHE
- ARM and MIPS, I think, needs PAGE_KERNEL_NOCACHE
- ... others I don't know.
Cheers,
Ben.
> Regards--
> Subrata
>
> >
> > It does make sense to want to have some memory like that shared between
> > user space and DMA, though I don't know what the right approach that
> > works on all archs is at this stage. Worth asking the Alsa guys, I think
> > they have similar issues :-)
> >
> > But doing double buffering might do the trick fine for now.
> >
> > Cheers,
> > Ben.
> >
> >
> >
> >
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists