[prev in list] [next in list] [prev in thread] [next in thread]
List: linux-security-module
Subject: [RFC][PATCH 1/4] trusted-keys: fix sparse rcu pointer messages
From: Mimi Zohar <zohar () linux ! vnet ! ibm ! com>
Date: 2011-12-27 15:15:20
Message-ID: 1324998923-2600-1-git-send-email-zohar () linux ! vnet ! ibm ! com
[Download RAW message or body]
Use key payload.rcudata instead of payload.data when assigning RCU
pointer to resolve CONFIG_SPARSE_RCU_POINTER message:
"incompatible types in comparison expression (different address spaces)"
Signed-off-by: Mimi Zohar <zohar@us.ibm.com>
---
security/keys/trusted.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/security/keys/trusted.c b/security/keys/trusted.c
index 0ed5fdf..39455de 100644
--- a/security/keys/trusted.c
+++ b/security/keys/trusted.c
@@ -993,7 +993,7 @@ out:
kfree(datablob);
kfree(options);
if (!ret)
- rcu_assign_pointer(key->payload.data, payload);
+ rcu_assign_pointer(key->payload.rcudata, payload);
else
kfree(payload);
return ret;
@@ -1067,7 +1067,7 @@ static int trusted_update(struct key *key, const void *data, size_t datalen)
goto out;
}
}
- rcu_assign_pointer(key->payload.data, new_p);
+ rcu_assign_pointer(key->payload.rcudata, new_p);
call_rcu(&p->rcu, trusted_rcu_free);
out:
kfree(datablob);
--
1.7.6.4
--
To unsubscribe from this list: send the line "unsubscribe linux-security-module" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic