On Mon, Sep 29, 2008 at 10:23:25AM -0700, Arjan van de Ven wrote:
pci_iomap() returns a "void __iomem *".
readl/writel take "void __iomem *" as an argument.
See build_mmio_read() in include/asm-x86/io.h
I think the assumption is the other way around: use of ioread/iowrite
assumes use of io_remap(). pci_iomap is the PCI wrapper around io_remap().
You just want a simpler wrapper (and I agree, it really could without
the extra arg).
But in any case, we can document pci_iomap() to be whatever you think
we should be exporting. pci_iomap() is not currently documented in
Documentation/. Or at least grep isn't seeing it.
You are right about that.
Would calling the API "pci_iomap_bar()" to keep the naming consistent help
make it more acceptable?
(And adding documentation for both would be good too...I can do
that if the new API gets accepted.)
hth,
grant
--