Hi Jayesh,
thanks, so I should use pci_ioremap_bar() and ioread8() and iowrite8() and the like.
What really confused me was the "re" in pci_ioremap_bar() (by the way, there is no
API called pci_ioremap(), but only pci_iomap()), suggesting that something different
may be done in these two functions apart from better error checking.
AFAIK,
pci_ioremap_bar api provides an error-proof way (relative to pci_ioremap) for PCI memory remap.
After the mapping is successful, in case you are writing a portable code, use ioread8 api which provides platform abstraction to the re mapped registers.
Hope that helps.
BR,
Jayesh