switch vfs_path_lookup() to struct path
[deliverable/linux.git] / net / sunrpc / clnt.c
index b84d7395535e7aae2d523797134c27d8a9e57c11..304f403a04111eb3b3da9635bc3c365c5695299b 100644 (file)
@@ -97,8 +97,7 @@ static int
 rpc_setup_pipedir(struct rpc_clnt *clnt, char *dir_name)
 {
        static uint32_t clntid;
-       struct nameidata nd;
-       struct path path;
+       struct path path, dir;
        char name[15];
        struct qstr q = {
                .name = name,
@@ -113,7 +112,7 @@ rpc_setup_pipedir(struct rpc_clnt *clnt, char *dir_name)
        path.mnt = rpc_get_mount();
        if (IS_ERR(path.mnt))
                return PTR_ERR(path.mnt);
-       error = vfs_path_lookup(path.mnt->mnt_root, path.mnt, dir_name, 0, &nd);
+       error = vfs_path_lookup(path.mnt->mnt_root, path.mnt, dir_name, 0, &dir);
        if (error)
                goto err;
 
@@ -121,7 +120,7 @@ rpc_setup_pipedir(struct rpc_clnt *clnt, char *dir_name)
                q.len = snprintf(name, sizeof(name), "clnt%x", (unsigned int)clntid++);
                name[sizeof(name) - 1] = '\0';
                q.hash = full_name_hash(q.name, q.len);
-               path.dentry = rpc_create_client_dir(nd.path.dentry, &q, clnt);
+               path.dentry = rpc_create_client_dir(dir.dentry, &q, clnt);
                if (!IS_ERR(path.dentry))
                        break;
                error = PTR_ERR(path.dentry);
@@ -132,11 +131,11 @@ rpc_setup_pipedir(struct rpc_clnt *clnt, char *dir_name)
                        goto err_path_put;
                }
        }
-       path_put(&nd.path);
+       path_put(&dir);
        clnt->cl_path = path;
        return 0;
 err_path_put:
-       path_put(&nd.path);
+       path_put(&dir);
 err:
        rpc_put_mount();
        return error;
@@ -1061,7 +1060,7 @@ call_allocate(struct rpc_task *task)
 
        dprintk("RPC: %5u rpc_buffer allocation failed\n", task->tk_pid);
 
-       if (RPC_IS_ASYNC(task) || !signalled()) {
+       if (RPC_IS_ASYNC(task) || !fatal_signal_pending(current)) {
                task->tk_action = call_allocate;
                rpc_delay(task, HZ>>4);
                return;
@@ -1175,6 +1174,9 @@ call_bind_status(struct rpc_task *task)
                        status = -EOPNOTSUPP;
                        break;
                }
+               if (task->tk_rebind_retry == 0)
+                       break;
+               task->tk_rebind_retry--;
                rpc_delay(task, 3*HZ);
                goto retry_timeout;
        case -ETIMEDOUT:
This page took 0.024686 seconds and 5 git commands to generate.