]> nv-tegra.nvidia Code Review - linux-3.10.git/commitdiff
KEYS: Permit key_serial() to be called with a const key pointer
authorDavid Howells <dhowells@redhat.com>
Wed, 18 Jan 2012 10:04:29 +0000 (10:04 +0000)
committerJames Morris <jmorris@namei.org>
Thu, 19 Jan 2012 05:17:35 +0000 (16:17 +1100)
Permit key_serial() to be called with a const key pointer.

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: James Morris <jmorris@namei.org>
include/linux/key.h

index bfc014c57351c5bf1d96e850691b1aad5ad4b284..5253471cd2ea32ec8459ef5023432b745b395771 100644 (file)
@@ -271,7 +271,7 @@ extern int keyring_add_key(struct key *keyring,
 
 extern struct key *key_lookup(key_serial_t id);
 
-static inline key_serial_t key_serial(struct key *key)
+static inline key_serial_t key_serial(const struct key *key)
 {
        return key ? key->serial : 0;
 }