diff options
author | Jeff Layton <jlayton@redhat.com> | 2014-03-17 07:06:57 -0400 |
---|---|---|
committer | Trond Myklebust <trond.myklebust@primarydata.com> | 2014-03-17 15:14:17 -0400 |
commit | 33912be816d96e204ed7a93690552daa39c08ea9 (patch) | |
tree | 4cfb64955c4b76595436e5efccc5aecb724c7099 /fs/nfs/nfs3proc.c | |
parent | 80a491fd40770db143d250772778ff4f89b807ef (diff) |
nfs: remove synchronous rename code
Now that nfs_rename uses the async infrastructure, we can remove this.
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Tested-by: Anna Schumaker <Anna.Schumaker@netapp.com>
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Diffstat (limited to 'fs/nfs/nfs3proc.c')
-rw-r--r-- | fs/nfs/nfs3proc.c | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/fs/nfs/nfs3proc.c b/fs/nfs/nfs3proc.c index aa9bc973f36a..251e6253fc36 100644 --- a/fs/nfs/nfs3proc.c +++ b/fs/nfs/nfs3proc.c | |||
@@ -478,41 +478,6 @@ nfs3_proc_rename_done(struct rpc_task *task, struct inode *old_dir, | |||
478 | } | 478 | } |
479 | 479 | ||
480 | static int | 480 | static int |
481 | nfs3_proc_rename(struct inode *old_dir, struct qstr *old_name, | ||
482 | struct inode *new_dir, struct qstr *new_name) | ||
483 | { | ||
484 | struct nfs_renameargs arg = { | ||
485 | .old_dir = NFS_FH(old_dir), | ||
486 | .old_name = old_name, | ||
487 | .new_dir = NFS_FH(new_dir), | ||
488 | .new_name = new_name, | ||
489 | }; | ||
490 | struct nfs_renameres res; | ||
491 | struct rpc_message msg = { | ||
492 | .rpc_proc = &nfs3_procedures[NFS3PROC_RENAME], | ||
493 | .rpc_argp = &arg, | ||
494 | .rpc_resp = &res, | ||
495 | }; | ||
496 | int status = -ENOMEM; | ||
497 | |||
498 | dprintk("NFS call rename %s -> %s\n", old_name->name, new_name->name); | ||
499 | |||
500 | res.old_fattr = nfs_alloc_fattr(); | ||
501 | res.new_fattr = nfs_alloc_fattr(); | ||
502 | if (res.old_fattr == NULL || res.new_fattr == NULL) | ||
503 | goto out; | ||
504 | |||
505 | status = rpc_call_sync(NFS_CLIENT(old_dir), &msg, 0); | ||
506 | nfs_post_op_update_inode(old_dir, res.old_fattr); | ||
507 | nfs_post_op_update_inode(new_dir, res.new_fattr); | ||
508 | out: | ||
509 | nfs_free_fattr(res.old_fattr); | ||
510 | nfs_free_fattr(res.new_fattr); | ||
511 | dprintk("NFS reply rename: %d\n", status); | ||
512 | return status; | ||
513 | } | ||
514 | |||
515 | static int | ||
516 | nfs3_proc_link(struct inode *inode, struct inode *dir, struct qstr *name) | 481 | nfs3_proc_link(struct inode *inode, struct inode *dir, struct qstr *name) |
517 | { | 482 | { |
518 | struct nfs3_linkargs arg = { | 483 | struct nfs3_linkargs arg = { |
@@ -967,7 +932,6 @@ const struct nfs_rpc_ops nfs_v3_clientops = { | |||
967 | .unlink_setup = nfs3_proc_unlink_setup, | 932 | .unlink_setup = nfs3_proc_unlink_setup, |
968 | .unlink_rpc_prepare = nfs3_proc_unlink_rpc_prepare, | 933 | .unlink_rpc_prepare = nfs3_proc_unlink_rpc_prepare, |
969 | .unlink_done = nfs3_proc_unlink_done, | 934 | .unlink_done = nfs3_proc_unlink_done, |
970 | .rename = nfs3_proc_rename, | ||
971 | .rename_setup = nfs3_proc_rename_setup, | 935 | .rename_setup = nfs3_proc_rename_setup, |
972 | .rename_rpc_prepare = nfs3_proc_rename_rpc_prepare, | 936 | .rename_rpc_prepare = nfs3_proc_rename_rpc_prepare, |
973 | .rename_done = nfs3_proc_rename_done, | 937 | .rename_done = nfs3_proc_rename_done, |