[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Xen-devel] [PATCH v7 5/9] PCI: Add pci_iomap_wc() variants
- To: Casey Leedom <leedom@xxxxxxxxxxx>
- From: Arnd Bergmann <arnd@xxxxxxxx>
- Date: Thu, 25 Jun 2015 22:44:07 +0200
- Cc: linux-fbdev <linux-fbdev@xxxxxxxxxxxxxxx>, "Michael S. Tsirkin" <mst@xxxxxxxxxx>, Benjamin Herrenschmidt <benh@xxxxxxxxxxxxxxxxxxx>, Ville Syrjälä <syrjala@xxxxxx>, Dave Hansen <dave.hansen@xxxxxxxxxxxxxxx>, "linux-pci@xxxxxxxxxxxxxxx" <linux-pci@xxxxxxxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, Davidlohr Bueso <dbueso@xxxxxxx>, Tomi Valkeinen <tomi.valkeinen@xxxxxx>, Mel Gorman <mgorman@xxxxxxx>, Suresh Siddha <sbsiddha@xxxxxxxxx>, Dave Airlie <airlied@xxxxxxxxxx>, Ingo Molnar <mingo@xxxxxxx>, Borislav Petkov <bp@xxxxxxx>, Jean-Christophe Plagniol-Villard <plagnioj@xxxxxxxxxxxx>, Antonino Daplas <adaplas@xxxxxxxxx>, "Luis R. Rodriguez" <mcgrof@xxxxxxxx>, Stefan Bader <stefan.bader@xxxxxxxxxxxxx>, Daniel Vetter <daniel.vetter@xxxxxxxx>, Bjorn Helgaas <bhelgaas@xxxxxxxxxx>, Thomas Gleixner <tglx@xxxxxxxxxxxxx>, Vlastimil Babka <vbabka@xxxxxxx>, Juergen Gross <jgross@xxxxxxxx>, Toshi Kani <toshi.kani@xxxxxx>, "linux-kernel@xxxxxxxxxxxxxxx" <linux-kernel@xxxxxxxxxxxxxxx>, Andy Lutomirski <luto@xxxxxxxxxxxxxx>, David Vrabel <david.vrabel@xxxxxxxxxx>, "venkatesh.pallipadi@xxxxxxxxx" <venkatesh.pallipadi@xxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>
- Delivery-date: Thu, 25 Jun 2015 20:50:06 +0000
- List-id: Xen developer discussion <xen-devel.lists.xen.org>
On Thursday 25 June 2015 15:01:56 Casey Leedom wrote:
>
> Is there a reference I can read on this so I can understand
> when and where we can use the __raw_*() APIs? Can these
> Raw Read/Write operations be reordered with respect to
> each other or are the use of the various flavors of SYNC
> instructions just to maintain order between Cached Memory
> Accesses and I/O Instructions?
The interpretation is not consistent across architectures.
My best description would be that the __raw_*() accessors should
only be used for accessing RAM areas that are known to have no
side-effects and can be read in any size (8-bit to 64-bit wide),
any alignment, and do not have a specific endianess.
If you are dealing with MMIO registers that have a fixed endianess
and size, the correct accessor would be readl_relaxed(), which
is like readl() but lacks the barriers on certain architectures.
Arnd
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|