[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <632CC6D1-65AB-448F-B680-06E350AFD432@kernel.crashing.org>
Date: Tue, 12 Sep 2006 17:32:13 +0200
From: Segher Boessenkool <segher@...nel.crashing.org>
To: Jeff Garzik <jgarzik@...ox.com>
Cc: Benjamin Herrenschmidt <benh@...nel.crashing.org>,
Jesse Barnes <jbarnes@...tuousgeek.org>,
Linux Kernel list <linux-kernel@...r.kernel.org>,
Alan Cox <alan@...rguk.ukuu.org.uk>,
"David S. Miller" <davem@...emloft.net>,
Paul Mackerras <paulus@...ba.org>,
Linus Torvalds <torvalds@...l.org>,
Andrew Morton <akpm@...l.org>
Subject: Re: [RFC] MMIO accessors & barriers documentation
> prepare_to_read_dma_memory() is the operation that an ethernet
> driver's RX code wants. And this is _completely_ unrelated to
> MMIO. It just wants to make sure that the device and host are
> looking at the same data. Often this involves polling a DMA
> descriptor (or index, stored inside DMA-able memory) looking for
> changes.
>
> flush_my_writes_to_dma_memory() is the operation that an ethernet
> driver's TX code wants, to precede either an MMIO "poke" or any
> other non-MMIO operation where the driver needs to be certain that
> the write is visible to the PCI device, should the PCI device
> desire to read that area of memory.
Because those are the operations, those should be the actual
function names, too (well, prefixed with pci_). Architectures
can implement them whatever way is appropriate, or perhaps default
to some ultra-strong semantics if they prefer; driver writers
should not have to know about the underlying mechanics (like why
we need which barriers).
Segher
-
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