From: Paul Gortmaker <paul.gortmaker@windriver.com>
To: Casey Schaufler <casey@schaufler-ca.com>,
James Morris <james.l.morris@oracle.com>,
"Serge E. Hallyn" <serge@hallyn.com>
Cc: <linux-security-module@vger.kernel.org>,
<linux-kernel@vger.kernel.org>,
Paul Gortmaker <paul.gortmaker@windriver.com>
Subject: [PATCH] smack: Fix gcc warning from unused smack_syslog_lock mutex in smackfs.c
Date: Mon, 23 Mar 2015 14:03:17 -0400 [thread overview]
Message-ID: <1427133797-7333-1-git-send-email-paul.gortmaker@windriver.com> (raw)
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
next reply other threads:[~2015-03-23 18:03 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-23 18:03 Paul Gortmaker [this message]
2015-03-23 19:28 ` [PATCH] smack: Fix gcc warning from unused smack_syslog_lock mutex in smackfs.c Casey Schaufler
2015-03-25 14:40 ` Casey Schaufler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1427133797-7333-1-git-send-email-paul.gortmaker@windriver.com \
--to=paul.gortmaker@windriver.com \
--cc=casey@schaufler-ca.com \
--cc=james.l.morris@oracle.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=serge@hallyn.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox