mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
To: Arnd Bergmann <arnd@arndb.de>,
	"J. Bruce Fields" <bfields@fieldses.org>,
	Jeff Layton <jlayton@kernel.org>
Cc: Chuck Lever <chuck.lever@oracle.com>,
	Trond Myklebust <trond.myklebust@primarydata.com>,
	Kinglong Mee <kinglongmee@gmail.com>,
	linux-nfs@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] NFSD: hide unused svcxdr_dupstr()
Date: Fri, 19 Jan 2018 22:58:27 +0100	[thread overview]
Message-ID: <428ce7f4-8e01-48ae-a406-262966c63180@prevas.dk> (raw)
In-Reply-To: <20180119145410.1096453-1-arnd@arndb.de>

On 2018-01-19 15:54, Arnd Bergmann wrote:
> There is now only one caller left for svcxdr_dupstr() and this is inside
> of an #ifdef, so we can get a warning when the option is disabled:
> 
> fs/nfsd/nfs4xdr.c:241:1: error: 'svcxdr_dupstr' defined but not used [-Werror=unused-function]
> 
> This adds another #ifdef around the definition.

Why not instead do

-#ifdef CONFIG_NFSD_V4_SECURITY_LABEL
-       if (bmval[2] & FATTR4_WORD2_SECURITY_LABEL) {
+       if (IS_ENABLED(CONFIG_NFSD_V4_SECURITY_LABEL) && bmval[2] &
FATTR4_WORD2_SECURITY_LABEL)

(sorry for whitespace damage, not a real patch).

Rasmus

  parent reply	other threads:[~2018-01-19 22:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-19 14:54 Arnd Bergmann
2018-01-19 16:15 ` Chuck Lever
2018-01-19 16:27   ` Bruce Fields
2018-01-19 21:58 ` Rasmus Villemoes [this message]
2018-01-22 17:26   ` J. Bruce Fields

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=428ce7f4-8e01-48ae-a406-262966c63180@prevas.dk \
    --to=rasmus.villemoes@prevas.dk \
    --cc=arnd@arndb.de \
    --cc=bfields@fieldses.org \
    --cc=chuck.lever@oracle.com \
    --cc=jlayton@kernel.org \
    --cc=kinglongmee@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nfs@vger.kernel.org \
    --cc=trond.myklebust@primarydata.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®