mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: Oleg Drokin <oleg.drokin@intel.com>,
	Andreas Dilger <andreas.dilger@intel.com>,
	James Simmons <jsimmons@infradead.org>
Cc: Mel Gorman <mgorman@techsingularity.net>,
	Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	"John L. Hammond" <john.hammond@intel.com>,
	lustre-devel@lists.lustre.org, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH 2/2] staging: lustre: hide unused variable
Date: Mon, 29 Aug 2016 14:20:01 +0200	[thread overview]
Message-ID: <20160829122023.3018966-2-arnd@arndb.de> (raw)
In-Reply-To: <20160829122023.3018966-1-arnd@arndb.de>

After a code cleanup, we get a harmless warning about a variable
that is unused when CONFIG_FS_POSIX_ACL is disabled:

drivers/staging/lustre/lustre/llite/xattr.c: In function 'll_xattr_get_common':
drivers/staging/lustre/lustre/llite/xattr.c:312:24: error: unused variable 'lli' [-Werror=unused-variable]

This puts the variable declaration into the same #ifdef.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 1e1f9ff406fd ("staging: lustre: llite: break ll_getxattr_common into 2 functions")
---
 drivers/staging/lustre/lustre/llite/xattr.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/staging/lustre/lustre/llite/xattr.c b/drivers/staging/lustre/lustre/llite/xattr.c
index f252c26ec30f..7b8d4699a71a 100644
--- a/drivers/staging/lustre/lustre/llite/xattr.c
+++ b/drivers/staging/lustre/lustre/llite/xattr.c
@@ -309,7 +309,9 @@ static int ll_xattr_get_common(const struct xattr_handler *handler,
 {
 	char fullname[strlen(handler->prefix) + strlen(name) + 1];
 	struct ll_sb_info *sbi = ll_i2sbi(inode);
+#ifdef CONFIG_FS_POSIX_ACL
 	struct ll_inode_info *lli = ll_i2info(inode);
+#endif
 	int rc;
 
 	CDEBUG(D_VFSTRACE, "VFS Op:inode="DFID"(%p)\n",
-- 
2.9.0

  reply	other threads:[~2016-08-29 12:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-29 12:20 [PATCH 1/2] staging: lustre: fix unstable pages tracking Arnd Bergmann
2016-08-29 12:20 ` Arnd Bergmann [this message]
2016-09-01  1:59   ` [PATCH 2/2] staging: lustre: hide unused variable James Simmons
2016-09-01  1:58 ` [PATCH 1/2] staging: lustre: fix unstable pages tracking James Simmons

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=20160829122023.3018966-2-arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=andreas.dilger@intel.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=john.hammond@intel.com \
    --cc=jsimmons@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lustre-devel@lists.lustre.org \
    --cc=mgorman@techsingularity.net \
    --cc=oleg.drokin@intel.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

all inboxes | Powered by JetHome®