Commit af85852d authored by J. Bruce Fields's avatar J. Bruce Fields Committed by Linus Torvalds

[PATCH] nfsd4: reindent do_open_lookup()

Minor rearrangement, cleanup of do_open_lookup().  No change in behavior.
Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
Acked-by: default avatarNeil Brown <neilb@suse.de>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 75b2bd55
...@@ -106,27 +106,25 @@ do_open_lookup(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_o ...@@ -106,27 +106,25 @@ do_open_lookup(struct svc_rqst *rqstp, struct svc_fh *current_fh, struct nfsd4_o
open->op_fname.len, &open->op_iattr, open->op_fname.len, &open->op_iattr,
&resfh, open->op_createmode, &resfh, open->op_createmode,
(u32 *)open->op_verf.data, &open->op_truncate); (u32 *)open->op_verf.data, &open->op_truncate);
} } else {
else {
status = nfsd_lookup(rqstp, current_fh, status = nfsd_lookup(rqstp, current_fh,
open->op_fname.data, open->op_fname.len, &resfh); open->op_fname.data, open->op_fname.len, &resfh);
fh_unlock(current_fh); fh_unlock(current_fh);
} }
if (status)
goto out;
if (!status) { set_change_info(&open->op_cinfo, current_fh);
set_change_info(&open->op_cinfo, current_fh);
/* set reply cache */ /* set reply cache */
fh_dup2(current_fh, &resfh); fh_dup2(current_fh, &resfh);
open->op_stateowner->so_replay.rp_openfh_len = open->op_stateowner->so_replay.rp_openfh_len = resfh.fh_handle.fh_size;
resfh.fh_handle.fh_size; memcpy(open->op_stateowner->so_replay.rp_openfh,
memcpy(open->op_stateowner->so_replay.rp_openfh, &resfh.fh_handle.fh_base, resfh.fh_handle.fh_size);
&resfh.fh_handle.fh_base,
resfh.fh_handle.fh_size);
status = do_open_permission(rqstp, current_fh, open, MAY_NOP); status = do_open_permission(rqstp, current_fh, open, MAY_NOP);
}
out:
fh_put(&resfh); fh_put(&resfh);
return status; return status;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment