X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=lustre%2Fdoc%2Fllapi_path2parent.3;h=cd8b6136b5aa2dd28d68a5c08ca9ec0800e6471d;hb=05e6ccd344e7eba44e43230fa2fa0a1b3b6115c4;hp=d5e8a40517415a012b2d79e74b69db9d0497dc79;hpb=d1df59199f295075063265b654301efb4571f8c0;p=fs%2Flustre-release.git diff --git a/lustre/doc/llapi_path2parent.3 b/lustre/doc/llapi_path2parent.3 index d5e8a40..cd8b613 100644 --- a/lustre/doc/llapi_path2parent.3 +++ b/lustre/doc/llapi_path2parent.3 @@ -7,11 +7,11 @@ in Lustre. .B #include .PP .BI "int llapi_path2parent(const char *" path ", unsigned int " linkno "," -.BI " lustre_fid *" parent_fid ", char *" name "," +.BI " struct lu_fid *" parent_fid ", char *" name "," .BI " size_t " name_size ); .BI "int llapi_fd2parent(int " fd ", unsigned int " linkno "," -.BI " lustre_fid *" parent_fid ", char *" name "," +.BI " struct lu_fid *" parent_fid ", char *" name "," .BI " size_t " name_size ); .sp .fi @@ -22,29 +22,31 @@ for link number .I linkno stores the FID of the parent directory into .I parent_fid -and the zero-terminated name of the entry into the buffer +and the NUL-terminated name of the entry into the buffer .I name which is expected to be of size .IR name_size . - -The function +If +.I linkno +should be initialized to +.B -1 +when starting to iterate over all links of a file. The function .B llapi_fd2parent() behaves similarly except that it operates on an open file descriptor instead of a path. .sp .SH RETURN VALUES .LP -.B llapi_path2fid() -and -.B llapi_fd2fid() -return 0 on success or a negative errno value on failure. +0 is returned on success or a negative errno value on failure. .SH ERRORS .TP 15 .SM -ENODATA -linkno has reached the link count. +linkno has reached the total link count of the file. .TP .SM -ENOTTY .I path +or +.I fd does not reside on a Lustre filesystem. .TP .SM -ENOENT @@ -55,9 +57,12 @@ does not exist. An invalid argument was specified. .TP .SM -EOVERFLOW -The given buffer was too small. +The given buffer was too small to hold the pathname. .TP .SM -EPERM The file cannot be open by user or CAP_DAC_READ_SEARCH is not granted. .SH "SEE ALSO" +.BR lfs-path2fid (1), +.BR llapi_fid2path (3), +.BR llapi_path2fid (3), .BR lustreapi (7)