diff options
author | Eric Van Hensbergen <ericvh@ericvh-desktop.(none)> | 2008-03-05 08:08:09 -0500 |
---|---|---|
committer | Eric Van Hensbergen <ericvh@opteron.9grid.us> | 2008-05-14 20:23:25 -0400 |
commit | ee443996a35c1e04f210cafd43d5a98d41e46085 (patch) | |
tree | 58ee72b69a02d9dbb3a98e402a4561baba0eb9a8 /fs/9p/vfs_inode.c | |
parent | b32a09db4fb9a87246ba4e7726a979ac4709ad97 (diff) |
9p: Documentation updates
The kernel-doc comments of much of the 9p system have been in disarray since
reorganization. This patch fixes those problems, adds additional documentation
and a template book which collects the 9p information.
Signed-off-by: Eric Van Hensbergen <ericvh@gmail.com>
Diffstat (limited to 'fs/9p/vfs_inode.c')
-rw-r--r-- | fs/9p/vfs_inode.c | 50 |
1 files changed, 37 insertions, 13 deletions
diff --git a/fs/9p/vfs_inode.c b/fs/9p/vfs_inode.c index 6a28842052ea..40fa807bd929 100644 --- a/fs/9p/vfs_inode.c +++ b/fs/9p/vfs_inode.c | |||
@@ -129,6 +129,12 @@ static int p9mode2unixmode(struct v9fs_session_info *v9ses, int mode) | |||
129 | return res; | 129 | return res; |
130 | } | 130 | } |
131 | 131 | ||
132 | /** | ||
133 | * v9fs_uflags2omode- convert posix open flags to plan 9 mode bits | ||
134 | * @uflags: flags to convert | ||
135 | * | ||
136 | */ | ||
137 | |||
132 | int v9fs_uflags2omode(int uflags) | 138 | int v9fs_uflags2omode(int uflags) |
133 | { | 139 | { |
134 | int ret; | 140 | int ret; |
@@ -312,6 +318,14 @@ error: | |||
312 | } | 318 | } |
313 | */ | 319 | */ |
314 | 320 | ||
321 | /** | ||
322 | * v9fs_inode_from_fid - populate an inode by issuing a attribute request | ||
323 | * @v9ses: session information | ||
324 | * @fid: fid to issue attribute request for | ||
325 | * @sb: superblock on which to create inode | ||
326 | * | ||
327 | */ | ||
328 | |||
315 | static struct inode * | 329 | static struct inode * |
316 | v9fs_inode_from_fid(struct v9fs_session_info *v9ses, struct p9_fid *fid, | 330 | v9fs_inode_from_fid(struct v9fs_session_info *v9ses, struct p9_fid *fid, |
317 | struct super_block *sb) | 331 | struct super_block *sb) |
@@ -384,9 +398,12 @@ v9fs_open_created(struct inode *inode, struct file *file) | |||
384 | 398 | ||
385 | /** | 399 | /** |
386 | * v9fs_create - Create a file | 400 | * v9fs_create - Create a file |
401 | * @v9ses: session information | ||
402 | * @dir: directory that dentry is being created in | ||
387 | * @dentry: dentry that is being created | 403 | * @dentry: dentry that is being created |
388 | * @perm: create permissions | 404 | * @perm: create permissions |
389 | * @mode: open mode | 405 | * @mode: open mode |
406 | * @extension: 9p2000.u extension string to support devices, etc. | ||
390 | * | 407 | * |
391 | */ | 408 | */ |
392 | static struct p9_fid * | 409 | static struct p9_fid * |
@@ -461,7 +478,7 @@ error: | |||
461 | 478 | ||
462 | /** | 479 | /** |
463 | * v9fs_vfs_create - VFS hook to create files | 480 | * v9fs_vfs_create - VFS hook to create files |
464 | * @inode: directory inode that is being created | 481 | * @dir: directory inode that is being created |
465 | * @dentry: dentry that is being deleted | 482 | * @dentry: dentry that is being deleted |
466 | * @mode: create permissions | 483 | * @mode: create permissions |
467 | * @nd: path information | 484 | * @nd: path information |
@@ -519,7 +536,7 @@ error: | |||
519 | 536 | ||
520 | /** | 537 | /** |
521 | * v9fs_vfs_mkdir - VFS mkdir hook to create a directory | 538 | * v9fs_vfs_mkdir - VFS mkdir hook to create a directory |
522 | * @inode: inode that is being unlinked | 539 | * @dir: inode that is being unlinked |
523 | * @dentry: dentry that is being unlinked | 540 | * @dentry: dentry that is being unlinked |
524 | * @mode: mode for new directory | 541 | * @mode: mode for new directory |
525 | * | 542 | * |
@@ -703,9 +720,9 @@ done: | |||
703 | 720 | ||
704 | /** | 721 | /** |
705 | * v9fs_vfs_getattr - retrieve file metadata | 722 | * v9fs_vfs_getattr - retrieve file metadata |
706 | * @mnt - mount information | 723 | * @mnt: mount information |
707 | * @dentry - file to get attributes on | 724 | * @dentry: file to get attributes on |
708 | * @stat - metadata structure to populate | 725 | * @stat: metadata structure to populate |
709 | * | 726 | * |
710 | */ | 727 | */ |
711 | 728 | ||
@@ -928,7 +945,7 @@ done: | |||
928 | /** | 945 | /** |
929 | * v9fs_vfs_readlink - read a symlink's location | 946 | * v9fs_vfs_readlink - read a symlink's location |
930 | * @dentry: dentry for symlink | 947 | * @dentry: dentry for symlink |
931 | * @buf: buffer to load symlink location into | 948 | * @buffer: buffer to load symlink location into |
932 | * @buflen: length of buffer | 949 | * @buflen: length of buffer |
933 | * | 950 | * |
934 | */ | 951 | */ |
@@ -996,10 +1013,12 @@ static void *v9fs_vfs_follow_link(struct dentry *dentry, struct nameidata *nd) | |||
996 | * v9fs_vfs_put_link - release a symlink path | 1013 | * v9fs_vfs_put_link - release a symlink path |
997 | * @dentry: dentry for symlink | 1014 | * @dentry: dentry for symlink |
998 | * @nd: nameidata | 1015 | * @nd: nameidata |
1016 | * @p: unused | ||
999 | * | 1017 | * |
1000 | */ | 1018 | */ |
1001 | 1019 | ||
1002 | static void v9fs_vfs_put_link(struct dentry *dentry, struct nameidata *nd, void *p) | 1020 | static void |
1021 | v9fs_vfs_put_link(struct dentry *dentry, struct nameidata *nd, void *p) | ||
1003 | { | 1022 | { |
1004 | char *s = nd_get_link(nd); | 1023 | char *s = nd_get_link(nd); |
1005 | 1024 | ||
@@ -1008,6 +1027,15 @@ static void v9fs_vfs_put_link(struct dentry *dentry, struct nameidata *nd, void | |||
1008 | __putname(s); | 1027 | __putname(s); |
1009 | } | 1028 | } |
1010 | 1029 | ||
1030 | /** | ||
1031 | * v9fs_vfs_mkspecial - create a special file | ||
1032 | * @dir: inode to create special file in | ||
1033 | * @dentry: dentry to create | ||
1034 | * @mode: mode to create special file | ||
1035 | * @extension: 9p2000.u format extension string representing special file | ||
1036 | * | ||
1037 | */ | ||
1038 | |||
1011 | static int v9fs_vfs_mkspecial(struct inode *dir, struct dentry *dentry, | 1039 | static int v9fs_vfs_mkspecial(struct inode *dir, struct dentry *dentry, |
1012 | int mode, const char *extension) | 1040 | int mode, const char *extension) |
1013 | { | 1041 | { |
@@ -1037,7 +1065,7 @@ static int v9fs_vfs_mkspecial(struct inode *dir, struct dentry *dentry, | |||
1037 | * @dentry: dentry for symlink | 1065 | * @dentry: dentry for symlink |
1038 | * @symname: symlink data | 1066 | * @symname: symlink data |
1039 | * | 1067 | * |
1040 | * See 9P2000.u RFC for more information | 1068 | * See Also: 9P2000.u RFC for more information |
1041 | * | 1069 | * |
1042 | */ | 1070 | */ |
1043 | 1071 | ||
@@ -1058,10 +1086,6 @@ v9fs_vfs_symlink(struct inode *dir, struct dentry *dentry, const char *symname) | |||
1058 | * | 1086 | * |
1059 | */ | 1087 | */ |
1060 | 1088 | ||
1061 | /* XXX - lots of code dup'd from symlink and creates, | ||
1062 | * figure out a better reuse strategy | ||
1063 | */ | ||
1064 | |||
1065 | static int | 1089 | static int |
1066 | v9fs_vfs_link(struct dentry *old_dentry, struct inode *dir, | 1090 | v9fs_vfs_link(struct dentry *old_dentry, struct inode *dir, |
1067 | struct dentry *dentry) | 1091 | struct dentry *dentry) |
@@ -1098,7 +1122,7 @@ clunk_fid: | |||
1098 | * @dir: inode destination for new link | 1122 | * @dir: inode destination for new link |
1099 | * @dentry: dentry for file | 1123 | * @dentry: dentry for file |
1100 | * @mode: mode for creation | 1124 | * @mode: mode for creation |
1101 | * @dev_t: device associated with special file | 1125 | * @rdev: device associated with special file |
1102 | * | 1126 | * |
1103 | */ | 1127 | */ |
1104 | 1128 | ||