Therefore nfs4_process_layout_stateid should check for != 0 rather than < 0. Signed-off-by: Benny Halevy <bhalevy@xxxxxxxxxxx> --- fs/nfsd/nfs4pnfsd.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/nfsd/nfs4pnfsd.c b/fs/nfsd/nfs4pnfsd.c index 5043878..cee9aff 100644 --- a/fs/nfsd/nfs4pnfsd.c +++ b/fs/nfsd/nfs4pnfsd.c @@ -255,7 +255,7 @@ find_get_layout_state(struct nfs4_client *clp, struct nfs4_file *fp) return NULL; } -static int +static __be32 verify_stateid(struct nfs4_file *fp, stateid_t *stateid) { struct nfs4_stateid *local = NULL; @@ -316,7 +316,7 @@ nfs4_process_layout_stateid(struct nfs4_client *clp, struct nfs4_file *fp, /* verify input stateid */ status = verify_stateid(fp, stateid); - if (status < 0) { + if (status) { dprintk("%s ERROR: invalid open/deleg/lock stateid\n", __func__); goto out; -- 1.6.6.1 -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html