summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-mvebu
diff options
context:
space:
mode:
authorThomas Petazzoni2015-01-16 17:11:28 +0100
committerAndrew Lunn2015-01-19 23:05:42 +0100
commita0b5cd4ac2d6542d524d8063961bf914b5df1efa (patch)
treeb60b511e481131f8db2e069260c8ab9a17656179 /arch/arm/mach-mvebu
parentMerge branch 'mvebu/fixes-3' into mvebu/soc (diff)
downloadkernel-qcow2-linux-a0b5cd4ac2d6542d524d8063961bf914b5df1efa.tar.gz
kernel-qcow2-linux-a0b5cd4ac2d6542d524d8063961bf914b5df1efa.tar.xz
kernel-qcow2-linux-a0b5cd4ac2d6542d524d8063961bf914b5df1efa.zip
bus: mvebu-mbus: use automatic I/O synchronization barriers
Instead of using explicit I/O synchronization barriers shoehorned inside the streaming DMA mappings API (in arch/arm/mach-mvebu/coherency.c), we are switching to use automatic I/O synchronization barrier. The primary motivation for this change is that explicit I/O synchronization barriers are not only needed for streaming DMA mappings (which can easily be done by overriding the dma_map_ops), but also for coherent DMA mappings (which is a lot less easy to do, since the kernel assumes such mappings are coherent and don't require any sort of cache maintenance operation to ensure the consistency of the buffers). Switching to automatic I/O synchronization barriers will also allow us to use the existing arm_coherent_dma_ops instead of our custom arm_dma_ops. In order to use automatic I/O synchronization barriers, this commit changes mvebu-mbus in two ways: - It enables automatic I/O synchronization barriers in the 0x84 register of the MBus bridge, by enabling such barriers for all MBus units. This enables automatic barriers for the on-SoC peripherals that are doing DMA. - It enables the SyncEnable bit in the MBus windows, so that PCIe devices also use automatic I/O synchronization barrier. This automatic synchronization barrier relies on the assumption that at least one register of a given hardware unit is read before the driver accesses the DMA mappings modified by this unit. This assumption is guaranteed for PCI devices by vertue of the PCI standard, and we can reasonably verify that this assumption is also true for the limited number of platform drivers doing DMA used on Marvell EBU platforms. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Diffstat (limited to 'arch/arm/mach-mvebu')
0 files changed, 0 insertions, 0 deletions