]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
nfs41: remove uneeded checks in callback processing
authorAndy Adamson <andros@netapp.com>
Thu, 14 Jan 2010 22:45:06 +0000 (17:45 -0500)
committerTrond Myklebust <Trond.Myklebust@netapp.com>
Wed, 10 Feb 2010 13:30:57 +0000 (08:30 -0500)
All callback operations have arguments to decode and require processing.
The preprocess_nfs4X_op functions catch unsupported or illegal ops so
decode_args and process_op pointers are always non NULL.

Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
fs/nfs/callback_xdr.c

index d3e07f4699496c8e0bbed7e2426973b9dfcb7a7a..a6f2ded72b1766cc7aae39a775cdda0e990100cd 100644 (file)
@@ -630,9 +630,8 @@ static __be32 process_op(uint32_t minorversion, int nop,
 
        maxlen = xdr_out->end - xdr_out->p;
        if (maxlen > 0 && maxlen < PAGE_SIZE) {
-               if (likely(op->decode_args != NULL))
-                       status = op->decode_args(rqstp, xdr_in, argp);
-               if (likely(status == 0 && op->process_op != NULL))
+               status = op->decode_args(rqstp, xdr_in, argp);
+               if (likely(status == 0))
                        status = op->process_op(argp, resp);
        } else
                status = htonl(NFS4ERR_RESOURCE);