aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/exportfs.h
diff options
context:
space:
mode:
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>2011-01-29 08:13:25 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2011-03-14 09:15:28 -0400
commit5fe0c2378884e68beb532f5890cc0e3539ac747b (patch)
treebe25414052184e146049ea6466854366559d5528 /include/linux/exportfs.h
parentc8b91accfa1059d5565443193d89572eca2f5dd6 (diff)
exportfs: Return the minimum required handle size
The exportfs encode handle function should return the minimum required handle size. This helps user to find out the handle size by passing 0 handle size in the first step and then redoing to the call again with the returned handle size value. Acked-by: Serge Hallyn <serue@us.ibm.com> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'include/linux/exportfs.h')
-rw-r--r--include/linux/exportfs.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/linux/exportfs.h b/include/linux/exportfs.h
index 28028988c862..65afdfd31b7b 100644
--- a/include/linux/exportfs.h
+++ b/include/linux/exportfs.h
@@ -121,8 +121,10 @@ struct fid {
121 * set, the encode_fh() should store sufficient information so that a good 121 * set, the encode_fh() should store sufficient information so that a good
122 * attempt can be made to find not only the file but also it's place in the 122 * attempt can be made to find not only the file but also it's place in the
123 * filesystem. This typically means storing a reference to de->d_parent in 123 * filesystem. This typically means storing a reference to de->d_parent in
124 * the filehandle fragment. encode_fh() should return the number of bytes 124 * the filehandle fragment. encode_fh() should return the fileid_type on
125 * stored or a negative error code such as %-ENOSPC 125 * success and on error returns 255 (if the space needed to encode fh is
126 * greater than @max_len*4 bytes). On error @max_len contains the minimum
127 * size(in 4 byte unit) needed to encode the file handle.
126 * 128 *
127 * fh_to_dentry: 129 * fh_to_dentry:
128 * @fh_to_dentry is given a &struct super_block (@sb) and a file handle 130 * @fh_to_dentry is given a &struct super_block (@sb) and a file handle