* [PATCH] smack: Fix gcc warning from unused smack_syslog_lock mutex in smackfs.c
@ 2015-03-23 18:03 Paul Gortmaker
2015-03-23 19:28 ` Casey Schaufler
2015-03-25 14:40 ` Casey Schaufler
0 siblings, 2 replies; 3+ messages in thread
From: Paul Gortmaker @ 2015-03-23 18:03 UTC (permalink / raw)
To: Casey Schaufler, James Morris, Serge E. Hallyn
Cc: linux-security-module, linux-kernel, Paul Gortmaker
In commit 00f84f3f2e9d088f06722f4351d67f5f577abe22 ("Smack: Make the
syslog control configurable") this mutex was added, but the rest of
the final commit never actually made use of it, resulting in:
In file included from include/linux/mutex.h:29:0,
from include/linux/notifier.h:13,
from include/linux/memory_hotplug.h:6,
from include/linux/mmzone.h:821,
from include/linux/gfp.h:5,
from include/linux/slab.h:14,
from include/linux/security.h:27,
from security/smack/smackfs.c:21:
security/smack/smackfs.c:63:21: warning: ‘smack_syslog_lock’ defined but not used [-Wunused-variable]
static DEFINE_MUTEX(smack_syslog_lock);
^
A git grep shows no other instances/references to smack_syslog_lock.
Delete it, assuming that the mutex addition was just a leftover from
an earlier work in progress version of the change.
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
---
security/smack/smackfs.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/security/smack/smackfs.c b/security/smack/smackfs.c
index bce4e8f1b267..558a46d76129 100644
--- a/security/smack/smackfs.c
+++ b/security/smack/smackfs.c
@@ -61,7 +61,6 @@ enum smk_inos {
*/
static DEFINE_MUTEX(smack_cipso_lock);
static DEFINE_MUTEX(smack_ambient_lock);
-static DEFINE_MUTEX(smack_syslog_lock);
static DEFINE_MUTEX(smk_netlbladdr_lock);
/*
--
2.2.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] smack: Fix gcc warning from unused smack_syslog_lock mutex in smackfs.c
2015-03-23 18:03 [PATCH] smack: Fix gcc warning from unused smack_syslog_lock mutex in smackfs.c Paul Gortmaker
@ 2015-03-23 19:28 ` Casey Schaufler
2015-03-25 14:40 ` Casey Schaufler
1 sibling, 0 replies; 3+ messages in thread
From: Casey Schaufler @ 2015-03-23 19:28 UTC (permalink / raw)
To: Paul Gortmaker, James Morris, Serge E. Hallyn
Cc: linux-security-module, linux-kernel, Casey Schaufler
On 3/23/2015 11:03 AM, Paul Gortmaker wrote:
> In commit 00f84f3f2e9d088f06722f4351d67f5f577abe22 ("Smack: Make the
> syslog control configurable") this mutex was added, but the rest of
> the final commit never actually made use of it, resulting in:
>
> In file included from include/linux/mutex.h:29:0,
> from include/linux/notifier.h:13,
> from include/linux/memory_hotplug.h:6,
> from include/linux/mmzone.h:821,
> from include/linux/gfp.h:5,
> from include/linux/slab.h:14,
> from include/linux/security.h:27,
> from security/smack/smackfs.c:21:
> security/smack/smackfs.c:63:21: warning: ‘smack_syslog_lock’ defined but not used [-Wunused-variable]
> static DEFINE_MUTEX(smack_syslog_lock);
> ^
>
> A git grep shows no other instances/references to smack_syslog_lock.
> Delete it, assuming that the mutex addition was just a leftover from
> an earlier work in progress version of the change.
>
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Acked-by: Casey Schaufler <casey@schaufler-ca.com>
I will take this patch into my smack-for-4.1 branch. Thank you.
> ---
> security/smack/smackfs.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/security/smack/smackfs.c b/security/smack/smackfs.c
> index bce4e8f1b267..558a46d76129 100644
> --- a/security/smack/smackfs.c
> +++ b/security/smack/smackfs.c
> @@ -61,7 +61,6 @@ enum smk_inos {
> */
> static DEFINE_MUTEX(smack_cipso_lock);
> static DEFINE_MUTEX(smack_ambient_lock);
> -static DEFINE_MUTEX(smack_syslog_lock);
> static DEFINE_MUTEX(smk_netlbladdr_lock);
>
> /*
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] smack: Fix gcc warning from unused smack_syslog_lock mutex in smackfs.c
2015-03-23 18:03 [PATCH] smack: Fix gcc warning from unused smack_syslog_lock mutex in smackfs.c Paul Gortmaker
2015-03-23 19:28 ` Casey Schaufler
@ 2015-03-25 14:40 ` Casey Schaufler
1 sibling, 0 replies; 3+ messages in thread
From: Casey Schaufler @ 2015-03-25 14:40 UTC (permalink / raw)
To: Paul Gortmaker, James Morris, Serge E. Hallyn
Cc: linux-security-module, linux-kernel
On 3/23/2015 11:03 AM, Paul Gortmaker wrote:
> In commit 00f84f3f2e9d088f06722f4351d67f5f577abe22 ("Smack: Make the
> syslog control configurable") this mutex was added, but the rest of
> the final commit never actually made use of it, resulting in:
>
> In file included from include/linux/mutex.h:29:0,
> from include/linux/notifier.h:13,
> from include/linux/memory_hotplug.h:6,
> from include/linux/mmzone.h:821,
> from include/linux/gfp.h:5,
> from include/linux/slab.h:14,
> from include/linux/security.h:27,
> from security/smack/smackfs.c:21:
> security/smack/smackfs.c:63:21: warning: ‘smack_syslog_lock’ defined but not used [-Wunused-variable]
> static DEFINE_MUTEX(smack_syslog_lock);
> ^
>
> A git grep shows no other instances/references to smack_syslog_lock.
> Delete it, assuming that the mutex addition was just a leftover from
> an earlier work in progress version of the change.
>
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Applied to git://git.gitorious.org/smack-next/kernel.git#smack-for-4.1
> ---
> security/smack/smackfs.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/security/smack/smackfs.c b/security/smack/smackfs.c
> index bce4e8f1b267..558a46d76129 100644
> --- a/security/smack/smackfs.c
> +++ b/security/smack/smackfs.c
> @@ -61,7 +61,6 @@ enum smk_inos {
> */
> static DEFINE_MUTEX(smack_cipso_lock);
> static DEFINE_MUTEX(smack_ambient_lock);
> -static DEFINE_MUTEX(smack_syslog_lock);
> static DEFINE_MUTEX(smk_netlbladdr_lock);
>
> /*
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-03-25 14:40 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-23 18:03 [PATCH] smack: Fix gcc warning from unused smack_syslog_lock mutex in smackfs.c Paul Gortmaker
2015-03-23 19:28 ` Casey Schaufler
2015-03-25 14:40 ` Casey Schaufler
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.