diff options
| author | James Morris <jmorris@namei.org> | 2010-03-08 20:46:47 -0500 |
|---|---|---|
| committer | James Morris <jmorris@namei.org> | 2010-03-08 20:46:47 -0500 |
| commit | c43a7523470dc2d9947fa114a0b54317975d4c04 (patch) | |
| tree | 30a72ed1e9079f19b814263197761820f57c39ce | |
| parent | eaa5eec739637f32f8733d528ff0b94fd62b1214 (diff) | |
| parent | 634a539e16bd7a1ba31c3f832baa725565cc9f96 (diff) | |
Merge branch 'next-queue' into next
| -rw-r--r-- | security/keys/keyring.c | 6 | ||||
| -rw-r--r-- | security/security.c | 2 | ||||
| -rw-r--r-- | security/selinux/hooks.c | 2 | ||||
| -rw-r--r-- | security/selinux/include/initial_sid_to_string.h | 2 | ||||
| -rw-r--r-- | security/selinux/netlink.c | 1 | ||||
| -rw-r--r-- | security/selinux/nlmsgtab.c | 1 | ||||
| -rw-r--r-- | security/selinux/ss/policydb.c | 2 | ||||
| -rw-r--r-- | security/selinux/ss/symtab.c | 1 | ||||
| -rw-r--r-- | security/tomoyo/common.c | 10 |
9 files changed, 9 insertions, 18 deletions
diff --git a/security/keys/keyring.c b/security/keys/keyring.c index e814d2109f8e..a98fb376f249 100644 --- a/security/keys/keyring.c +++ b/security/keys/keyring.c | |||
| @@ -170,12 +170,10 @@ static void keyring_describe(const struct key *keyring, struct seq_file *m) | |||
| 170 | { | 170 | { |
| 171 | struct keyring_list *klist; | 171 | struct keyring_list *klist; |
| 172 | 172 | ||
| 173 | if (keyring->description) { | 173 | if (keyring->description) |
| 174 | seq_puts(m, keyring->description); | 174 | seq_puts(m, keyring->description); |
| 175 | } | 175 | else |
| 176 | else { | ||
| 177 | seq_puts(m, "[anon]"); | 176 | seq_puts(m, "[anon]"); |
| 178 | } | ||
| 179 | 177 | ||
| 180 | rcu_read_lock(); | 178 | rcu_read_lock(); |
| 181 | klist = rcu_dereference(keyring->payload.subscriptions); | 179 | klist = rcu_dereference(keyring->payload.subscriptions); |
diff --git a/security/security.c b/security/security.c index 687c6fd14bb6..b98334b0a576 100644 --- a/security/security.c +++ b/security/security.c | |||
| @@ -117,7 +117,7 @@ int __init security_module_enable(struct security_operations *ops) | |||
| 117 | * If there is already a security module registered with the kernel, | 117 | * If there is already a security module registered with the kernel, |
| 118 | * an error will be returned. Otherwise %0 is returned on success. | 118 | * an error will be returned. Otherwise %0 is returned on success. |
| 119 | */ | 119 | */ |
| 120 | int register_security(struct security_operations *ops) | 120 | int __init register_security(struct security_operations *ops) |
| 121 | { | 121 | { |
| 122 | if (verify(ops)) { | 122 | if (verify(ops)) { |
| 123 | printk(KERN_DEBUG "%s could not verify " | 123 | printk(KERN_DEBUG "%s could not verify " |
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 5feecb41009d..63c2d36d55ab 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c | |||
| @@ -323,7 +323,7 @@ extern int ss_initialized; | |||
| 323 | 323 | ||
| 324 | /* The file system's label must be initialized prior to use. */ | 324 | /* The file system's label must be initialized prior to use. */ |
| 325 | 325 | ||
| 326 | static char *labeling_behaviors[6] = { | 326 | static const char *labeling_behaviors[6] = { |
| 327 | "uses xattr", | 327 | "uses xattr", |
| 328 | "uses transition SIDs", | 328 | "uses transition SIDs", |
| 329 | "uses task SIDs", | 329 | "uses task SIDs", |
diff --git a/security/selinux/include/initial_sid_to_string.h b/security/selinux/include/initial_sid_to_string.h index d4fac82793ae..a59b64e3fd02 100644 --- a/security/selinux/include/initial_sid_to_string.h +++ b/security/selinux/include/initial_sid_to_string.h | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | /* This file is automatically generated. Do not edit. */ | 1 | /* This file is automatically generated. Do not edit. */ |
| 2 | static char *initial_sid_to_string[] = | 2 | static const char *initial_sid_to_string[] = |
| 3 | { | 3 | { |
| 4 | "null", | 4 | "null", |
| 5 | "kernel", | 5 | "kernel", |
diff --git a/security/selinux/netlink.c b/security/selinux/netlink.c index 1ae556446e65..7d7be296d876 100644 --- a/security/selinux/netlink.c +++ b/security/selinux/netlink.c | |||
| @@ -13,7 +13,6 @@ | |||
| 13 | #include <linux/types.h> | 13 | #include <linux/types.h> |
| 14 | #include <linux/stddef.h> | 14 | #include <linux/stddef.h> |
| 15 | #include <linux/kernel.h> | 15 | #include <linux/kernel.h> |
| 16 | #include <linux/list.h> | ||
| 17 | #include <linux/skbuff.h> | 16 | #include <linux/skbuff.h> |
| 18 | #include <linux/netlink.h> | 17 | #include <linux/netlink.h> |
| 19 | #include <linux/selinux_netlink.h> | 18 | #include <linux/selinux_netlink.h> |
diff --git a/security/selinux/nlmsgtab.c b/security/selinux/nlmsgtab.c index dd7cc6de77f9..75ec0c6ebacd 100644 --- a/security/selinux/nlmsgtab.c +++ b/security/selinux/nlmsgtab.c | |||
| @@ -11,7 +11,6 @@ | |||
| 11 | */ | 11 | */ |
| 12 | #include <linux/types.h> | 12 | #include <linux/types.h> |
| 13 | #include <linux/kernel.h> | 13 | #include <linux/kernel.h> |
| 14 | #include <linux/skbuff.h> | ||
| 15 | #include <linux/netlink.h> | 14 | #include <linux/netlink.h> |
| 16 | #include <linux/rtnetlink.h> | 15 | #include <linux/rtnetlink.h> |
| 17 | #include <linux/if.h> | 16 | #include <linux/if.h> |
diff --git a/security/selinux/ss/policydb.c b/security/selinux/ss/policydb.c index 23c6e53c102c..24ced65ac4ff 100644 --- a/security/selinux/ss/policydb.c +++ b/security/selinux/ss/policydb.c | |||
| @@ -40,7 +40,7 @@ | |||
| 40 | #define _DEBUG_HASHES | 40 | #define _DEBUG_HASHES |
| 41 | 41 | ||
| 42 | #ifdef DEBUG_HASHES | 42 | #ifdef DEBUG_HASHES |
| 43 | static char *symtab_name[SYM_NUM] = { | 43 | static const char *symtab_name[SYM_NUM] = { |
| 44 | "common prefixes", | 44 | "common prefixes", |
| 45 | "classes", | 45 | "classes", |
| 46 | "roles", | 46 | "roles", |
diff --git a/security/selinux/ss/symtab.c b/security/selinux/ss/symtab.c index 837658a98a54..bcf9f620426e 100644 --- a/security/selinux/ss/symtab.c +++ b/security/selinux/ss/symtab.c | |||
| @@ -4,7 +4,6 @@ | |||
| 4 | * Author : Stephen Smalley, <sds@epoch.ncsc.mil> | 4 | * Author : Stephen Smalley, <sds@epoch.ncsc.mil> |
| 5 | */ | 5 | */ |
| 6 | #include <linux/kernel.h> | 6 | #include <linux/kernel.h> |
| 7 | #include <linux/slab.h> | ||
| 8 | #include <linux/string.h> | 7 | #include <linux/string.h> |
| 9 | #include <linux/errno.h> | 8 | #include <linux/errno.h> |
| 10 | #include "symtab.h" | 9 | #include "symtab.h" |
diff --git a/security/tomoyo/common.c b/security/tomoyo/common.c index ff51f1026b57..8ccf12997378 100644 --- a/security/tomoyo/common.c +++ b/security/tomoyo/common.c | |||
| @@ -1367,7 +1367,6 @@ static bool tomoyo_print_path_acl(struct tomoyo_io_buffer *head, | |||
| 1367 | { | 1367 | { |
| 1368 | int pos; | 1368 | int pos; |
| 1369 | u8 bit; | 1369 | u8 bit; |
| 1370 | const char *atmark = ""; | ||
| 1371 | const char *filename; | 1370 | const char *filename; |
| 1372 | const u32 perm = ptr->perm | (((u32) ptr->perm_high) << 16); | 1371 | const u32 perm = ptr->perm | (((u32) ptr->perm_high) << 16); |
| 1373 | 1372 | ||
| @@ -1382,8 +1381,7 @@ static bool tomoyo_print_path_acl(struct tomoyo_io_buffer *head, | |||
| 1382 | continue; | 1381 | continue; |
| 1383 | msg = tomoyo_path2keyword(bit); | 1382 | msg = tomoyo_path2keyword(bit); |
| 1384 | pos = head->read_avail; | 1383 | pos = head->read_avail; |
| 1385 | if (!tomoyo_io_printf(head, "allow_%s %s%s\n", msg, | 1384 | if (!tomoyo_io_printf(head, "allow_%s %s\n", msg, filename)) |
| 1386 | atmark, filename)) | ||
| 1387 | goto out; | 1385 | goto out; |
| 1388 | } | 1386 | } |
| 1389 | head->read_bit = 0; | 1387 | head->read_bit = 0; |
| @@ -1406,8 +1404,6 @@ static bool tomoyo_print_path2_acl(struct tomoyo_io_buffer *head, | |||
| 1406 | struct tomoyo_path2_acl *ptr) | 1404 | struct tomoyo_path2_acl *ptr) |
| 1407 | { | 1405 | { |
| 1408 | int pos; | 1406 | int pos; |
| 1409 | const char *atmark1 = ""; | ||
| 1410 | const char *atmark2 = ""; | ||
| 1411 | const char *filename1; | 1407 | const char *filename1; |
| 1412 | const char *filename2; | 1408 | const char *filename2; |
| 1413 | const u8 perm = ptr->perm; | 1409 | const u8 perm = ptr->perm; |
| @@ -1421,8 +1417,8 @@ static bool tomoyo_print_path2_acl(struct tomoyo_io_buffer *head, | |||
| 1421 | continue; | 1417 | continue; |
| 1422 | msg = tomoyo_path22keyword(bit); | 1418 | msg = tomoyo_path22keyword(bit); |
| 1423 | pos = head->read_avail; | 1419 | pos = head->read_avail; |
| 1424 | if (!tomoyo_io_printf(head, "allow_%s %s%s %s%s\n", msg, | 1420 | if (!tomoyo_io_printf(head, "allow_%s %s %s\n", msg, |
| 1425 | atmark1, filename1, atmark2, filename2)) | 1421 | filename1, filename2)) |
| 1426 | goto out; | 1422 | goto out; |
| 1427 | } | 1423 | } |
| 1428 | head->read_bit = 0; | 1424 | head->read_bit = 0; |
