From: James Bottomley <James.Bottomley@steeleye.com>
To: "Christopher Friesen" <cfriesen@nortelnetworks.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: how is processor cache coherency maintained for device drivers
Date: Sun, 11 Nov 2001 08:55:52 -0800 [thread overview]
Message-ID: <200111111655.fABGtr610172@localhost.localdomain> (raw)
> I'm trying to help track down some infrequent and difficult to
> reproduce pci bus parity errors that we're seeing on a cPCI card, and
> one of the things that has been suggested is that it may have
> something to do with DMA coherency between devices and the processor.
> Can someone point me to the proper code/information that deals with
> how the processor knows that the memory corresponding to the ethernet
> device is no longer up-to-date? Is it somehow marked as
> non-cacheable, or is it snooped, explicitly flushed, or what?
This is extremely architecture specific. Some, like the x86, have a fully
coherent architecture, so the caches snoop the bus for invalidations. Others
(older parisc) are completely incoherent and won't invalidate the CPU cache
unless explicitly told to do so.
The code for all this is in:
asm/io.h for the basic dma_cache_* functions
asm/pci.h for the pci bus pci_dma_* functions
See Documentation/DMA-mapping.txt for a partial explanation of the
implementation.
> The platform in question is a Motorola MCPN765 card, with a PPC7400
> processor, running a modified 2.2.17 kernel.
I believe (although you should take better advice from the PPC people) that
the powerpc is completely cache coherent, so any coherency problems you may be
having would be due to the hardware, not the kernel.
James Bottomley
next reply other threads:[~2001-11-11 16:56 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-11-11 16:55 James Bottomley [this message]
2001-11-12 21:59 ` Mike Fedyk
-- strict thread matches above, loose matches on Subject: below --
2001-11-09 21:46 Christopher Friesen
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=200111111655.fABGtr610172@localhost.localdomain \
--to=james.bottomley@steeleye.com \
--cc=cfriesen@nortelnetworks.com \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®