All of lore.kernel.org
 help / color / mirror / Atom feed
* linux-next: build failure after merge of the nfsd tree
@ 2015-07-20 23:57 Stephen Rothwell
  2015-07-21  5:09 ` [PATCH v3] nfsd: Add layouts checking in client_has_state() Kinglong Mee
  2015-07-21  5:10 ` linux-next: build failure after merge of the nfsd tree Kinglong Mee
  0 siblings, 2 replies; 4+ messages in thread
From: Stephen Rothwell @ 2015-07-20 23:57 UTC (permalink / raw)
  To: J. Bruce Fields; +Cc: linux-next, linux-kernel, Kinglong Mee

Hi,

After merging the nfsd tree, today's linux-next build (powerpc
ppc64_defconfig) failed like this:

fs/nfsd/nfs4state.c: In function 'client_has_state':
fs/nfsd/nfs4state.c:2249:22: error: 'struct nfs4_client' has no member named 'cl_lo_states'
   || !list_empty(&clp->cl_lo_states)
                      ^
fs/nfsd/nfs4state.c:2252:1: warning: control reaches end of non-void function [-Wreturn-type]
 }
 ^

Caused by commit

  395b297af7bf ("nfsd: Add layouts checking in client_has_state()")

cl_lo_states is only defined when CONFIG_NFSD_PNFS is set.

I have used the nsfd tree from next-20150720 for today.

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH v3] nfsd: Add layouts checking in client_has_state()
  2015-07-20 23:57 linux-next: build failure after merge of the nfsd tree Stephen Rothwell
@ 2015-07-21  5:09 ` Kinglong Mee
  2015-07-21 21:16   ` J. Bruce Fields
  2015-07-21  5:10 ` linux-next: build failure after merge of the nfsd tree Kinglong Mee
  1 sibling, 1 reply; 4+ messages in thread
From: Kinglong Mee @ 2015-07-21  5:09 UTC (permalink / raw)
  To: Stephen Rothwell, J. Bruce Fields; +Cc: linux-nfs@vger.kernel.org, kinglongmee

Layout is a state resource, nfsd should check it too.

v2, drop unneeded updating in nfsd4_renew()
v3, fix compile error without CONFIG_NFSD_PNFS

Signed-off-by: Kinglong Mee <kinglongmee@gmail.com>
---
 fs/nfsd/nfs4state.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index 61dfb33..94a2980 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -2241,6 +2241,9 @@ static bool client_has_state(struct nfs4_client *clp)
 	 * Also note we should probably be using this in 4.0 case too.
 	 */
 	return !list_empty(&clp->cl_openowners)
+#ifdef CONFIG_NFSD_PNFS
+		|| !list_empty(&clp->cl_lo_states)
+#endif
 		|| !list_empty(&clp->cl_delegations)
 		|| !list_empty(&clp->cl_sessions);
 }
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: linux-next: build failure after merge of the nfsd tree
  2015-07-20 23:57 linux-next: build failure after merge of the nfsd tree Stephen Rothwell
  2015-07-21  5:09 ` [PATCH v3] nfsd: Add layouts checking in client_has_state() Kinglong Mee
@ 2015-07-21  5:10 ` Kinglong Mee
  1 sibling, 0 replies; 4+ messages in thread
From: Kinglong Mee @ 2015-07-21  5:10 UTC (permalink / raw)
  To: J. Bruce Fields; +Cc: Stephen Rothwell, linux-next, linux-kernel, kinglongmee

Sorry for my fault.
Please drop the old version and use the new version 3.

thanks,
Kinglong Mee

On 7/21/2015 07:57, Stephen Rothwell wrote:
> Hi,
> 
> After merging the nfsd tree, today's linux-next build (powerpc
> ppc64_defconfig) failed like this:
> 
> fs/nfsd/nfs4state.c: In function 'client_has_state':
> fs/nfsd/nfs4state.c:2249:22: error: 'struct nfs4_client' has no member named 'cl_lo_states'
>    || !list_empty(&clp->cl_lo_states)
>                       ^
> fs/nfsd/nfs4state.c:2252:1: warning: control reaches end of non-void function [-Wreturn-type]
>  }
>  ^
> 
> Caused by commit
> 
>   395b297af7bf ("nfsd: Add layouts checking in client_has_state()")
> 
> cl_lo_states is only defined when CONFIG_NFSD_PNFS is set.
> 
> I have used the nsfd tree from next-20150720 for today.
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v3] nfsd: Add layouts checking in client_has_state()
  2015-07-21  5:09 ` [PATCH v3] nfsd: Add layouts checking in client_has_state() Kinglong Mee
@ 2015-07-21 21:16   ` J. Bruce Fields
  0 siblings, 0 replies; 4+ messages in thread
From: J. Bruce Fields @ 2015-07-21 21:16 UTC (permalink / raw)
  To: Kinglong Mee; +Cc: Stephen Rothwell, linux-nfs@vger.kernel.org

On Tue, Jul 21, 2015 at 01:09:17PM +0800, Kinglong Mee wrote:
> Layout is a state resource, nfsd should check it too.
> 
> v2, drop unneeded updating in nfsd4_renew()
> v3, fix compile error without CONFIG_NFSD_PNFS

Got it, thanks.--b.

> 
> Signed-off-by: Kinglong Mee <kinglongmee@gmail.com>
> ---
>  fs/nfsd/nfs4state.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
> index 61dfb33..94a2980 100644
> --- a/fs/nfsd/nfs4state.c
> +++ b/fs/nfsd/nfs4state.c
> @@ -2241,6 +2241,9 @@ static bool client_has_state(struct nfs4_client *clp)
>  	 * Also note we should probably be using this in 4.0 case too.
>  	 */
>  	return !list_empty(&clp->cl_openowners)
> +#ifdef CONFIG_NFSD_PNFS
> +		|| !list_empty(&clp->cl_lo_states)
> +#endif
>  		|| !list_empty(&clp->cl_delegations)
>  		|| !list_empty(&clp->cl_sessions);
>  }
> -- 
> 2.4.3

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-07-21 21:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-20 23:57 linux-next: build failure after merge of the nfsd tree Stephen Rothwell
2015-07-21  5:09 ` [PATCH v3] nfsd: Add layouts checking in client_has_state() Kinglong Mee
2015-07-21 21:16   ` J. Bruce Fields
2015-07-21  5:10 ` linux-next: build failure after merge of the nfsd tree Kinglong Mee

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.