static int nfs_create_rpc_client(struct nfs_client *clp,
                                 const struct rpc_timeout *timeparms,
                                 rpc_authflavor_t flavor,
-                                int flags)
+                                int discrtry, int noresvport)
 {
        struct rpc_clnt         *clnt = NULL;
        struct rpc_create_args args = {
                .program        = &nfs_program,
                .version        = clp->rpc_ops->version,
                .authflavor     = flavor,
-               .flags          = flags,
        };
 
+       if (discrtry)
+               args.flags |= RPC_CLNT_CREATE_DISCRTRY;
+       if (noresvport)
+               args.flags |= RPC_CLNT_CREATE_NONPRIVPORT;
+
        if (!IS_ERR(clp->cl_rpcclient))
                return 0;
 
         * Create a client RPC handle for doing FSSTAT with UNIX auth only
         * - RFC 2623, sec 2.3.2
         */
-       error = nfs_create_rpc_client(clp, timeparms, RPC_AUTH_UNIX, 0);
+       error = nfs_create_rpc_client(clp, timeparms, RPC_AUTH_UNIX, 0, 0);
        if (error < 0)
                goto error;
        nfs_mark_client_ready(clp, NFS_CS_READY);
        clp->rpc_ops = &nfs_v4_clientops;
 
        error = nfs_create_rpc_client(clp, timeparms, authflavour,
-                                       RPC_CLNT_CREATE_DISCRTRY);
+                                     1, 0);
        if (error < 0)
                goto error;
        memcpy(clp->cl_ipaddr, ip_addr, sizeof(clp->cl_ipaddr));