Message ID | 20130109093834.13789.270.stgit@localhost.localdomain (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Bruce, sorry, forgot to add: Reported-by: Toralf Förster <toralf.foerster@gmx.de> 09.01.2013 13:38, Stanislav Kinsbursky ?????: > If CONFIG_LOCKDEP is disabled, then there would be a warning like this: > > CC [M] fs/nfsd/nfs4state.o > fs/nfsd/nfs4state.c: In function ‘free_client’: > fs/nfsd/nfs4state.c:1051:19: warning: unused variable ‘nn’ [-Wunused-variable] > > So, let's add "maybe_unused" tag to this variable. > > Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com> > --- > fs/nfsd/nfs4state.c | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c > index 8f7362c..739a6c2 100644 > --- a/fs/nfsd/nfs4state.c > +++ b/fs/nfsd/nfs4state.c > @@ -1048,7 +1048,7 @@ static struct nfs4_client *alloc_client(struct xdr_netobj name) > static inline void > free_client(struct nfs4_client *clp) > { > - struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id); > + struct nfsd_net __maybe_unused *nn = net_generic(clp->net, nfsd_net_id); > > lockdep_assert_held(&nn->client_lock); > while (!list_empty(&clp->cl_sessions)) { >
On Wed, Jan 09, 2013 at 01:39:04PM +0400, Stanislav Kinsbursky wrote: > Bruce, sorry, forgot to add: > > Reported-by: Toralf Förster <toralf.foerster@gmx.de> Thanks, added that, and committing for 3.9.--b. > > 09.01.2013 13:38, Stanislav Kinsbursky ?????: > >If CONFIG_LOCKDEP is disabled, then there would be a warning like this: > > > > CC [M] fs/nfsd/nfs4state.o > >fs/nfsd/nfs4state.c: In function ‘free_client’: > >fs/nfsd/nfs4state.c:1051:19: warning: unused variable ‘nn’ [-Wunused-variable] > > > >So, let's add "maybe_unused" tag to this variable. > > > >Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com> > >--- > > fs/nfsd/nfs4state.c | 2 +- > > 1 files changed, 1 insertions(+), 1 deletions(-) > > > >diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c > >index 8f7362c..739a6c2 100644 > >--- a/fs/nfsd/nfs4state.c > >+++ b/fs/nfsd/nfs4state.c > >@@ -1048,7 +1048,7 @@ static struct nfs4_client *alloc_client(struct xdr_netobj name) > > static inline void > > free_client(struct nfs4_client *clp) > > { > >- struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id); > >+ struct nfsd_net __maybe_unused *nn = net_generic(clp->net, nfsd_net_id); > > > > lockdep_assert_held(&nn->client_lock); > > while (!list_empty(&clp->cl_sessions)) { > > > > > -- > Best regards, > Stanislav Kinsbursky -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index 8f7362c..739a6c2 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c @@ -1048,7 +1048,7 @@ static struct nfs4_client *alloc_client(struct xdr_netobj name) static inline void free_client(struct nfs4_client *clp) { - struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id); + struct nfsd_net __maybe_unused *nn = net_generic(clp->net, nfsd_net_id); lockdep_assert_held(&nn->client_lock); while (!list_empty(&clp->cl_sessions)) {
If CONFIG_LOCKDEP is disabled, then there would be a warning like this: CC [M] fs/nfsd/nfs4state.o fs/nfsd/nfs4state.c: In function ‘free_client’: fs/nfsd/nfs4state.c:1051:19: warning: unused variable ‘nn’ [-Wunused-variable] So, let's add "maybe_unused" tag to this variable. Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com> --- fs/nfsd/nfs4state.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html