ARM: barrier: allow options to be passed to memory barrier instructions
authorWill Deacon <will.deacon@arm.com>
Fri, 10 May 2013 17:07:19 +0000 (18:07 +0100)
committerChristoffer Dall <christoffer.dall@linaro.org>
Thu, 2 Oct 2014 15:19:27 +0000 (17:19 +0200)
commit0db5306859a69c38c695400c34bde7b7df5f1806
treee3d2cf7a31720bfbc5c56e20e875e5427e30646f
parent8032ebeefc762abdcc8f14f08e9e1d3839996063
ARM: barrier: allow options to be passed to memory barrier instructions

On ARMv7, the memory barrier instructions take an optional `option'
field which can be used to constrain the effects of a memory barrier
based on shareability and access type.

This patch allows the caller to pass these options if required, and
updates the smp_*() barriers to request inner-shareable barriers,
affecting only stores for the _wmb variant. wmb() is also changed to
use the -st version of dsb.

Reported-by: Albin Tonnerre <albin.tonnerre@arm.com>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
(cherry picked from commit 3ea128065ed20d33bd02ff6dab689f88e38000be)
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
arch/arm/include/asm/assembler.h
arch/arm/include/asm/barrier.h