All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] 9p: fix kernel-doc warning for enum p9_session_flags
@ 2026-10-02  3:58 Omokefe Emmanuel Onanaroghene
  2026-10-29  1:15 ` Dominique Martinet
  0 siblings, 1 reply; 2+ messages in thread
From: Omokefe Emmanuel Onanaroghene @ 2026-10-02  3:58 UTC (permalink / raw)
  To: ericvh, aneesh.kumar, jvrao, v9fs, linux-kernel
  Cc: ericvh, lucho, asmadeus, linux_oss, skhan,
	Omokefe Emmanuel Onanaroghene

kernel-doc cannot parse enum p9_session_flags, since its documentation
comment is followed by #define lines instead of the enum declaration:

  fs/9p/v9fs.h:31 : error: Cannot parse enum!

Move the three #define lines below the enum whose values they are
derived from, and give V9FS_ACCESS_ANY and V9FS_ACCESS_MASK their own
kernel-doc comments with the descriptions they had in the enum comment.

Also document the four enum members that had no description, using the
corresponding mount option wording from
Documentation/filesystems/9p.rst.

Fixes: 76381a42e4a5 ("fs/9p: Add access = client option to opt in acl evaluation.")
Assisted-by: LLM
Signed-off-by: Omokefe Emmanuel Onanaroghene <emmaonana18@gmail.com>
---
 fs/9p/v9fs.h | 26 ++++++++++++++++++--------
 1 file changed, 18 insertions(+), 8 deletions(-)

diff --git a/fs/9p/v9fs.h b/fs/9p/v9fs.h
index a462bcbfc7da..2f18e75f0ed0 100644
--- a/fs/9p/v9fs.h
+++ b/fs/9p/v9fs.h
@@ -21,20 +21,16 @@
  * @V9FS_ACCESS_SINGLE: only the mounting user can access the hierarchy
  * @V9FS_ACCESS_USER: a new attach will be issued for every user (default)
  * @V9FS_ACCESS_CLIENT: Just like user, but access check is performed on client.
- * @V9FS_ACCESS_ANY: use a single attach for all users
- * @V9FS_ACCESS_MASK: bit mask of different ACCESS options
  * @V9FS_POSIX_ACL: POSIX ACLs are enforced
+ * @V9FS_NO_XATTR: do not offer xattr functions on this mount
+ * @V9FS_IGNORE_QV: ignore qid.version==0 as a marker to ignore cache
+ * @V9FS_DIRECT_IO: bypass page cache on all read/write operations
+ * @V9FS_SYNC: flush writes synchronously to the server
  * @V9FS_NDENTRY_TIMEOUT_SET: Has negative dentry timeout retention time been
  *                            overridden by negtimeout mount option
  *
  * Session flags reflect options selected by users at mount time
  */
-#define	V9FS_ACCESS_ANY (V9FS_ACCESS_SINGLE | \
-			 V9FS_ACCESS_USER |   \
-			 V9FS_ACCESS_CLIENT)
-#define V9FS_ACCESS_MASK V9FS_ACCESS_ANY
-#define V9FS_ACL_MASK V9FS_POSIX_ACL
-
 enum p9_session_flags {
 	V9FS_PROTO_2000U         = 0x01,
 	V9FS_PROTO_2000L         = 0x02,
@@ -49,6 +45,20 @@ enum p9_session_flags {
 	V9FS_NDENTRY_TIMEOUT_SET = 0x400,
 };
 
+/**
+ * V9FS_ACCESS_ANY - use a single attach for all users
+ */
+#define	V9FS_ACCESS_ANY (V9FS_ACCESS_SINGLE | \
+			 V9FS_ACCESS_USER |   \
+			 V9FS_ACCESS_CLIENT)
+
+/**
+ * V9FS_ACCESS_MASK - bit mask of different ACCESS options
+ */
+#define V9FS_ACCESS_MASK V9FS_ACCESS_ANY
+
+#define V9FS_ACL_MASK V9FS_POSIX_ACL
+
 /**
  * enum p9_cache_shortcuts - human readable cache preferences
  * @CACHE_SC_NONE: disable all caches
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] 9p: fix kernel-doc warning for enum p9_session_flags
  2026-10-02  3:58 [PATCH] 9p: fix kernel-doc warning for enum p9_session_flags Omokefe Emmanuel Onanaroghene
@ 2026-10-29  1:15 ` Dominique Martinet
  0 siblings, 0 replies; 2+ messages in thread
From: Dominique Martinet @ 2026-10-29  1:15 UTC (permalink / raw)
  To: Omokefe Emmanuel Onanaroghene
  Cc: ericvh, aneesh.kumar, jvrao, v9fs, linux-kernel, ericvh, lucho,
	linux_oss, skhan

Omokefe Emmanuel Onanaroghene wrote on Fri, Oct 02, 2026 at 04:58:37AM +0100:
> kernel-doc cannot parse enum p9_session_flags, since its documentation
> comment is followed by #define lines instead of the enum declaration:
> 
>   fs/9p/v9fs.h:31 : error: Cannot parse enum!
> 
> Move the three #define lines below the enum whose values they are
> derived from, and give V9FS_ACCESS_ANY and V9FS_ACCESS_MASK their own
> kernel-doc comments with the descriptions they had in the enum comment.
> 
> Also document the four enum members that had no description, using the
> corresponding mount option wording from
> Documentation/filesystems/9p.rst.
> 
> Fixes: 76381a42e4a5 ("fs/9p: Add access = client option to opt in acl evaluation.")
> Assisted-by: LLM
> Signed-off-by: Omokefe Emmanuel Onanaroghene <emmaonana18@gmail.com>

Sure, why not; picked up.

> ---
>  fs/9p/v9fs.h | 26 ++++++++++++++++++--------
>  1 file changed, 18 insertions(+), 8 deletions(-)
> 
> diff --git a/fs/9p/v9fs.h b/fs/9p/v9fs.h
> index a462bcbfc7da..2f18e75f0ed0 100644
> --- a/fs/9p/v9fs.h
> +++ b/fs/9p/v9fs.h
> @@ -21,20 +21,16 @@
>   * @V9FS_ACCESS_SINGLE: only the mounting user can access the hierarchy
>   * @V9FS_ACCESS_USER: a new attach will be issued for every user (default)
>   * @V9FS_ACCESS_CLIENT: Just like user, but access check is performed on client.
> - * @V9FS_ACCESS_ANY: use a single attach for all users
> - * @V9FS_ACCESS_MASK: bit mask of different ACCESS options
>   * @V9FS_POSIX_ACL: POSIX ACLs are enforced
> + * @V9FS_NO_XATTR: do not offer xattr functions on this mount
> + * @V9FS_IGNORE_QV: ignore qid.version==0 as a marker to ignore cache
> + * @V9FS_DIRECT_IO: bypass page cache on all read/write operations
> + * @V9FS_SYNC: flush writes synchronously to the server

I reworded these a bit as 'flush writes' sounded a bit off.

+ * @V9FS_IGNORE_QV: ignore qid.version==0 as a marker to disable data cache
+ * @V9FS_DIRECT_IO: disable data read/write cache
+ * @V9FS_SYNC: disable data write cache

-- 
Dominique Martinet | Asmadeus

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-10-29  1:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-02  3:58 [PATCH] 9p: fix kernel-doc warning for enum p9_session_flags Omokefe Emmanuel Onanaroghene
2026-10-29  1:15 ` Dominique Martinet

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.