summaryrefslogtreecommitdiffstats
path: root/security/apparmor/include/policy.h
diff options
context:
space:
mode:
authorKevin Hilman <khilman@linaro.org>2013-10-12 00:01:14 +0200
committerKevin Hilman <khilman@linaro.org>2013-10-12 00:01:36 +0200
commitf797bd4a02056dceb3c0fc9813d991eb4ee62a19 (patch)
treecd6b17d308f2711fd2493f877905054a54fb4285 /security/apparmor/include/policy.h
parentMerge tag 'renesas-soc2-for-v3.13' of git://git.kernel.org/pub/scm/linux/kern... (diff)
parentARM: keystone: Enable I2C and SPI bus support (diff)
downloadlinux-f797bd4a02056dceb3c0fc9813d991eb4ee62a19.tar.xz
linux-f797bd4a02056dceb3c0fc9813d991eb4ee62a19.zip
Merge tag 'keystone-soc-for-arm-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/ssantosh/linux-keystone into next/soc
From Santosh Shilimkar: SOC updates for Keystone II devices: - Clock tree support - Clock management support using PM core - Keystone config update for EMDA with ack from Vinod - Enable SPI and I2C drivers * tag 'keystone-soc-for-arm-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/ssantosh/linux-keystone: (510 commits) ARM: keystone: Enable I2C and SPI bus support ARM: keystone: Select TI_EDMA to be able to enable SPI driver dma: Allow TI_EDMA selectable for ARCH_KEYSTONE ARM: dts: keystone: Add the SPI nodes ARM: dts: keystone: Add i2c device nodes ARM: keystone: add PM domain support for clock management ARM: keystone: Enable clock drivers ARM: dts: keystone: Add clock phandle to UART nodes ARM: dts: keystone: Add clock tree data to devicetree +Linux 3.12-rc4 Signed-off-by: Kevin Hilman <khilman@linaro.org>
Diffstat (limited to 'security/apparmor/include/policy.h')
-rw-r--r--security/apparmor/include/policy.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/security/apparmor/include/policy.h b/security/apparmor/include/policy.h
index f2d4b6348cbc..c28b0f20ab53 100644
--- a/security/apparmor/include/policy.h
+++ b/security/apparmor/include/policy.h
@@ -360,7 +360,9 @@ static inline void aa_put_replacedby(struct aa_replacedby *p)
static inline void __aa_update_replacedby(struct aa_profile *orig,
struct aa_profile *new)
{
- struct aa_profile *tmp = rcu_dereference(orig->replacedby->profile);
+ struct aa_profile *tmp;
+ tmp = rcu_dereference_protected(orig->replacedby->profile,
+ mutex_is_locked(&orig->ns->lock));
rcu_assign_pointer(orig->replacedby->profile, aa_get_profile(new));
orig->flags |= PFLAG_INVALID;
aa_put_profile(tmp);