aboutsummaryrefslogtreecommitdiffstats
path: root/security/keys/encrypted-keys/masterkey_trusted.c
diff options
context:
space:
mode:
authorMimi Zohar <zohar@linux.vnet.ibm.com>2012-01-17 20:39:51 +0000
committerJames Morris <jmorris@namei.org>2012-01-18 10:41:29 +1100
commitee0b31a25a010116f44fca6c96f4516d417793dd (patch)
treed7670d202d0f4888b5213ed73d88c9a80bd05b74 /security/keys/encrypted-keys/masterkey_trusted.c
parentKEYS: Add missing smp_rmb() primitives to the keyring search code (diff)
downloadlinux-dev-ee0b31a25a010116f44fca6c96f4516d417793dd.tar.xz
linux-dev-ee0b31a25a010116f44fca6c96f4516d417793dd.zip
keys: fix trusted/encrypted keys sparse rcu_assign_pointer messages
Define rcu_assign_keypointer(), which uses the key payload.rcudata instead of payload.data, to resolve the CONFIG_SPARSE_RCU_POINTER message: "incompatible types in comparison expression (different address spaces)" Replace the rcu_assign_pointer() calls in encrypted/trusted keys with rcu_assign_keypointer(). Signed-off-by: Mimi Zohar <zohar@us.ibm.com> Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: James Morris <jmorris@namei.org>
Diffstat (limited to '')
-rw-r--r--security/keys/encrypted-keys/masterkey_trusted.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/security/keys/encrypted-keys/masterkey_trusted.c b/security/keys/encrypted-keys/masterkey_trusted.c
index df87272e3f51..8c16c3e472e7 100644
--- a/security/keys/encrypted-keys/masterkey_trusted.c
+++ b/security/keys/encrypted-keys/masterkey_trusted.c
@@ -18,6 +18,8 @@
#include <linux/module.h>
#include <linux/err.h>
#include <keys/trusted-type.h>
+#include <keys/encrypted-type.h>
+#include "encrypted.h"
/*
* request_trusted_key - request the trusted key