2022-06-02 08:05:07

by Yang Li

[permalink] [raw]
Subject: [PATCH -next v2] ubifs: Fix some kernel-doc comments

Remove warnings found by running scripts/kernel-doc,
which is caused by using 'make W=1'.
fs/ubifs/journal.c:1221: warning: Function parameter or member
'old_inode' not described in 'ubifs_jnl_rename'
fs/ubifs/journal.c:1221: warning: Function parameter or member 'old_nm'
not described in 'ubifs_jnl_rename'
fs/ubifs/journal.c:1221: warning: Function parameter or member
'new_inode' not described in 'ubifs_jnl_rename'
fs/ubifs/journal.c:1221: warning: Function parameter or member 'new_nm'
not described in 'ubifs_jnl_rename'
fs/ubifs/journal.c:1221: warning: Function parameter or member
'whiteout' not described in 'ubifs_jnl_rename'
fs/ubifs/journal.c:1221: warning: Excess function parameter 'old_dentry'
description in 'ubifs_jnl_rename'
fs/ubifs/journal.c:1221: warning: Excess function parameter 'new_dentry'
description in 'ubifs_jnl_rename'

Reported-by: Abaci Robot <[email protected]>
Signed-off-by: Yang Li <[email protected]>
---
fs/ubifs/journal.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/fs/ubifs/journal.c b/fs/ubifs/journal.c
index 75dab0ae3939..61f72a557655 100644
--- a/fs/ubifs/journal.c
+++ b/fs/ubifs/journal.c
@@ -1201,9 +1201,13 @@ int ubifs_jnl_xrename(struct ubifs_info *c, const struct inode *fst_dir,
* ubifs_jnl_rename - rename a directory entry.
* @c: UBIFS file-system description object
* @old_dir: parent inode of directory entry to rename
- * @old_dentry: directory entry to rename
+ * @old_inode: directory entry's inode to rename
+ * @old_nm: name of the old directory entry to rename
* @new_dir: parent inode of directory entry to rename
- * @new_dentry: new directory entry (or directory entry to replace)
+ * @new_inode: new directory entry's inode (or directory entry's inode to
+ * replace)
+ * @new_nm: new name of the new directory entry
+ * @whiteout: whiteout inode
* @sync: non-zero if the write-buffer has to be synchronized
*
* This function implements the re-name operation which may involve writing up
--
2.20.1.7.g153144c



2022-07-08 11:34:21

by Zhihao Cheng

[permalink] [raw]
Subject: Re: [PATCH -next v2] ubifs: Fix some kernel-doc comments

?? 2022/6/2 14:55, Yang Li д??:
> Remove warnings found by running scripts/kernel-doc,
> which is caused by using 'make W=1'.
> fs/ubifs/journal.c:1221: warning: Function parameter or member
> 'old_inode' not described in 'ubifs_jnl_rename'
> fs/ubifs/journal.c:1221: warning: Function parameter or member 'old_nm'
> not described in 'ubifs_jnl_rename'
> fs/ubifs/journal.c:1221: warning: Function parameter or member
> 'new_inode' not described in 'ubifs_jnl_rename'
> fs/ubifs/journal.c:1221: warning: Function parameter or member 'new_nm'
> not described in 'ubifs_jnl_rename'
> fs/ubifs/journal.c:1221: warning: Function parameter or member
> 'whiteout' not described in 'ubifs_jnl_rename'
> fs/ubifs/journal.c:1221: warning: Excess function parameter 'old_dentry'
> description in 'ubifs_jnl_rename'
> fs/ubifs/journal.c:1221: warning: Excess function parameter 'new_dentry'
> description in 'ubifs_jnl_rename'
>
> Reported-by: Abaci Robot <[email protected]>
> Signed-off-by: Yang Li <[email protected]>
> ---
Reviewed-by: Zhihao Cheng <[email protected]>
> fs/ubifs/journal.c | 8 ++++++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/fs/ubifs/journal.c b/fs/ubifs/journal.c
> index 75dab0ae3939..61f72a557655 100644
> --- a/fs/ubifs/journal.c
> +++ b/fs/ubifs/journal.c
> @@ -1201,9 +1201,13 @@ int ubifs_jnl_xrename(struct ubifs_info *c, const struct inode *fst_dir,
> * ubifs_jnl_rename - rename a directory entry.
> * @c: UBIFS file-system description object
> * @old_dir: parent inode of directory entry to rename
> - * @old_dentry: directory entry to rename
> + * @old_inode: directory entry's inode to rename
> + * @old_nm: name of the old directory entry to rename
> * @new_dir: parent inode of directory entry to rename
> - * @new_dentry: new directory entry (or directory entry to replace)
> + * @new_inode: new directory entry's inode (or directory entry's inode to
> + * replace)
> + * @new_nm: new name of the new directory entry
> + * @whiteout: whiteout inode
> * @sync: non-zero if the write-buffer has to be synchronized
> *
> * This function implements the re-name operation which may involve writing up
>

2023-07-12 07:58:30

by Zhihao Cheng

[permalink] [raw]
Subject: Re: [PATCH -next v2] ubifs: Fix some kernel-doc comments

?? 2023/7/12 15:46, Yang Li д??:
> Add description of @time and @flags in ubifs_update_time().
>
> to silence the warnings:
> fs/ubifs/file.c:1383: warning: Function parameter or member 'time' not described in 'ubifs_update_time'
> fs/ubifs/file.c:1383: warning: Function parameter or member 'flags' not described in 'ubifs_update_time'
>
> Reported-by: Abaci Robot <[email protected]>
> Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=5848
> Signed-off-by: Yang Li <[email protected]>
> ---
>
> --change in v2:
> According to Zhihao's suggestion, add a more accurate description to @flags.
>
> fs/ubifs/file.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/fs/ubifs/file.c b/fs/ubifs/file.c
> index 436b27d7c58f..860497532555 100644
> --- a/fs/ubifs/file.c
> +++ b/fs/ubifs/file.c
> @@ -1375,6 +1375,9 @@ static inline int mctime_update_needed(const struct inode *inode,
> /**
> * ubifs_update_time - update time of inode.
> * @inode: inode to update
> + * @time: timespec structure to hold the current time value
> + * @flags: time updating control flag determines updating
> + * which time fields of @inode
> *
> * This function updates time of the inode.
> */
>

Reviewed-by: Zhihao Cheng <[email protected]>