Subject: Re: Regarding consistent_alloc

From: Matt Porter <[email-masked]>
Date: Fri, 6 Dec 2002 11:29:01 -0700

On Fri, Dec 06, 2002 at 11:56:22AM -0500, Dan Malek wrote:
> Matt Porter wrote:
>
>  > ....  If you
> > want the kernel virtual address then you can apply __va to that.
>
> Errr....no, you can't.  That would give you the cached mapping.
> You need to hang on to both the dma_handle (the phys address token)
> and the virtual address returned by the function.  That's why both
> are returned.

That's what I said...but you clipped it out.  Once again,
consistent_alloc provides the caller everything they need.
An uncached mapping, a phys address, and from that you can use
__va() to get the cached mapping.

Seemed clear enough to me the first time.  My definition of a
"kernel virtual address" is the lowmem cached mapping.  If
I meant the uncached mapping I would have said it was a "kernel
vmalloc address" or something. :)

Regards,
--
Matt Porter
[email-masked]
This is Linux Country. On a quiet night, you can hear Windows reboot.

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/