aboutsummaryrefslogtreecommitdiffstats
path: root/security/smack
diff options
context:
space:
mode:
Diffstat (limited to 'security/smack')
-rw-r--r--security/smack/smack_lsm.c15
-rw-r--r--security/smack/smackfs.c4
2 files changed, 10 insertions, 9 deletions
diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c
index 4215971434e6..5d2ec5650e61 100644
--- a/security/smack/smack_lsm.c
+++ b/security/smack/smack_lsm.c
@@ -574,8 +574,8 @@ static int smack_inode_getattr(struct vfsmount *mnt, struct dentry *dentry)
574 * 574 *
575 * Returns 0 if access is permitted, an error code otherwise 575 * Returns 0 if access is permitted, an error code otherwise
576 */ 576 */
577static int smack_inode_setxattr(struct dentry *dentry, char *name, 577static int smack_inode_setxattr(struct dentry *dentry, const char *name,
578 void *value, size_t size, int flags) 578 const void *value, size_t size, int flags)
579{ 579{
580 int rc = 0; 580 int rc = 0;
581 581
@@ -604,8 +604,8 @@ static int smack_inode_setxattr(struct dentry *dentry, char *name,
604 * Set the pointer in the inode blob to the entry found 604 * Set the pointer in the inode blob to the entry found
605 * in the master label list. 605 * in the master label list.
606 */ 606 */
607static void smack_inode_post_setxattr(struct dentry *dentry, char *name, 607static void smack_inode_post_setxattr(struct dentry *dentry, const char *name,
608 void *value, size_t size, int flags) 608 const void *value, size_t size, int flags)
609{ 609{
610 struct inode_smack *isp; 610 struct inode_smack *isp;
611 char *nsp; 611 char *nsp;
@@ -641,7 +641,7 @@ static void smack_inode_post_setxattr(struct dentry *dentry, char *name,
641 * 641 *
642 * Returns 0 if access is permitted, an error code otherwise 642 * Returns 0 if access is permitted, an error code otherwise
643 */ 643 */
644static int smack_inode_getxattr(struct dentry *dentry, char *name) 644static int smack_inode_getxattr(struct dentry *dentry, const char *name)
645{ 645{
646 return smk_curacc(smk_of_inode(dentry->d_inode), MAY_READ); 646 return smk_curacc(smk_of_inode(dentry->d_inode), MAY_READ);
647} 647}
@@ -655,7 +655,7 @@ static int smack_inode_getxattr(struct dentry *dentry, char *name)
655 * 655 *
656 * Returns 0 if access is permitted, an error code otherwise 656 * Returns 0 if access is permitted, an error code otherwise
657 */ 657 */
658static int smack_inode_removexattr(struct dentry *dentry, char *name) 658static int smack_inode_removexattr(struct dentry *dentry, const char *name)
659{ 659{
660 int rc = 0; 660 int rc = 0;
661 661
@@ -1242,7 +1242,7 @@ static void smack_set_catset(char *catset, struct netlbl_lsm_secattr *sap)
1242 int rc; 1242 int rc;
1243 int byte; 1243 int byte;
1244 1244
1245 if (catset == 0) 1245 if (!catset)
1246 return; 1246 return;
1247 1247
1248 sap->flags |= NETLBL_SECATTR_MLS_CAT; 1248 sap->flags |= NETLBL_SECATTR_MLS_CAT;
@@ -2495,6 +2495,7 @@ struct security_operations smack_ops = {
2495 .task_wait = smack_task_wait, 2495 .task_wait = smack_task_wait,
2496 .task_reparent_to_init = cap_task_reparent_to_init, 2496 .task_reparent_to_init = cap_task_reparent_to_init,
2497 .task_to_inode = smack_task_to_inode, 2497 .task_to_inode = smack_task_to_inode,
2498 .task_prctl = cap_task_prctl,
2498 2499
2499 .ipc_permission = smack_ipc_permission, 2500 .ipc_permission = smack_ipc_permission,
2500 2501
diff --git a/security/smack/smackfs.c b/security/smack/smackfs.c
index 5d1bee0fa513..271a835fbbe3 100644
--- a/security/smack/smackfs.c
+++ b/security/smack/smackfs.c
@@ -317,7 +317,7 @@ static const struct file_operations smk_load_ops = {
317/** 317/**
318 * smk_cipso_doi - initialize the CIPSO domain 318 * smk_cipso_doi - initialize the CIPSO domain
319 */ 319 */
320void smk_cipso_doi(void) 320static void smk_cipso_doi(void)
321{ 321{
322 int rc; 322 int rc;
323 struct cipso_v4_doi *doip; 323 struct cipso_v4_doi *doip;
@@ -351,7 +351,7 @@ void smk_cipso_doi(void)
351/** 351/**
352 * smk_unlbl_ambient - initialize the unlabeled domain 352 * smk_unlbl_ambient - initialize the unlabeled domain
353 */ 353 */
354void smk_unlbl_ambient(char *oldambient) 354static void smk_unlbl_ambient(char *oldambient)
355{ 355{
356 int rc; 356 int rc;
357 struct netlbl_audit audit_info; 357 struct netlbl_audit audit_info;