https://github.com/torvalds/linux
Revision f3eab7184ddcd4867cf42e3274ba24a66e1e093d authored by Steve Capper on 22 March 2015, 14:51:51 UTC, committed by Catalin Marinas on 24 March 2015, 18:02:55 UTC
this_cpu operations were implemented for arm64 in:
 5284e1b arm64: xchg: Implement cmpxchg_double
 f97fc81 arm64: percpu: Implement this_cpu operations

Unfortunately, it is possible for pre-emption to take place between
address generation and data access. This can lead to cases where data
is being manipulated by this_cpu for a different CPU than it was
called on. Which effectively breaks the spec.

This patch disables pre-emption for the this_cpu operations
guaranteeing that address generation and data manipulation take place
without a pre-emption in-between.

Fixes: 5284e1b4bc8a ("arm64: xchg: Implement cmpxchg_double")
Fixes: f97fc810798c ("arm64: percpu: Implement this_cpu operations")
Reported-by: Mark Rutland <mark.rutland@arm.com>
Acked-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Steve Capper <steve.capper@linaro.org>
[catalin.marinas@arm.com: remove space after type cast]
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
1 parent e53f21b
History
Tip revision: f3eab7184ddcd4867cf42e3274ba24a66e1e093d authored by Steve Capper on 22 March 2015, 14:51:51 UTC
arm64: percpu: Make this_cpu accessors pre-empt safe
Tip revision: f3eab71
File Mode Size
Kconfig -rw-r--r-- 599 bytes
Makefile -rw-r--r-- 145 bytes
dir.c -rw-r--r-- 2.3 KB
efs.h -rw-r--r-- 3.8 KB
file.c -rw-r--r-- 1.1 KB
inode.c -rw-r--r-- 8.4 KB
namei.c -rw-r--r-- 2.6 KB
super.c -rw-r--r-- 8.2 KB
symlink.c -rw-r--r-- 1.2 KB

back to top