From: Grant Grundler <grundler@cup.hp.com>
To: "Gunneswara Marripudi" <raomg@cup.hp.com>
Cc: parisc-linux@puffin.external.hp.com
Subject: Re: Question on Linux DMA routines
Date: Thu, 30 Nov 2000 09:31:14 -0800 [thread overview]
Message-ID: <200011301731.JAA29335@milano.cup.hp.com> (raw)
In-Reply-To: Your message of "Thu, 30 Nov 2000 01:03:25 PST." <01c05aac$657dec80$0f0d8421@hpinddm>
"Gunneswara Marripudi" wrote:
> Hi Grant,
>
> I have a quick question on Linux 2.3 DMA routines.
2.3 is dead. You mean 2.4.
> If I allocate and map memory using pci_alloc_consistent(),
> do I still need to call pci_dma_sync_single() if there is a
> need to ensure the coherency? The documentation on it
> at DMA-mapping.txt is ambiguous (at least to me).
No - it's not needed.
> - Consistent DMA mappings which are usually mapped at driver
> 113 initialization, unmapped at the end and for which the hardware should
> 114 guarantee that the device and the cpu can access the data
> 115 in parallel and will see updates made by each other without any
> 116 explicit software flushing.
> 117
> 118 Think of "consistent" as "synchronous" or "coherent".
>
>
> It says that h/w should guarantee the consistency and I'm not sure
> what if the underlying platform is not fully coherent.
The HW *is* fully coherent when the CPU doesn't cache the pages.
Only systems with PCX-L/L2 CPU (need to) operate this way.
All other platforms have an I/O MMU which manages the coherency.
You might be confused because HPUX doesn't ever use uncached memory
for I/O since it has dma_sync() macro instead. And device driver writers
are "trained" to use that.
grant
Grant Grundler
Unix Systems Enablement Lab
+1.408.447.7253
next parent reply other threads:[~2000-11-30 17:29 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <01c05aac$657dec80$0f0d8421@hpinddm>
2000-11-30 17:31 ` Grant Grundler [this message]
2000-11-30 18:01 ` Question on Linux DMA routines Grant Grundler
2000-11-30 20:09 ` Richard Hirst
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=200011301731.JAA29335@milano.cup.hp.com \
--to=grundler@cup.hp.com \
--cc=parisc-linux@puffin.external.hp.com \
--cc=raomg@cup.hp.com \
/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