mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/3] Split patches sent earlier
@ 2025-09-26  9:27 Dominique Martinet via B4 Relay
  2025-09-26  9:27 ` [PATCH 1/3] 9p: clean up comment typos Dominique Martinet via B4 Relay
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Dominique Martinet via B4 Relay @ 2025-09-26  9:27 UTC (permalink / raw)
  To: Randall P. Embry, Eric Van Hensbergen, Latchesar Ionkov,
	Christian Schoenebeck
  Cc: v9fs, linux-kernel, Dominique Martinet

This was a pretty simple patch overall but "bullet point" commits are
not great for later debugging, so just split this commit in 3:
https://lkml.kernel.org/r/20250925122802.72580-1-rpembry@gmail.com

Randall, I kept you as author, so please comment if you have anything to
say about commit messages or anything else, and I'll pick these up and
push to Linus in a couple of weeks.

Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
---
Randall P. Embry (3):
      9p: clean up comment typos
      9p: fix /sys/fs/9p/caches overwriting itself
      9p: sysfs_init: don't hardcode error to ENOMEM

 fs/9p/v9fs.c | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)
---
base-commit: 8f5ae30d69d7543eee0d70083daf4de8fe15d585
change-id: 20250926-v9fs_misc-36320aef88d9

Best regards,
-- 
Dominique Martinet <asmadeus@codewreck.org>



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

* [PATCH 1/3] 9p: clean up comment typos
  2025-09-26  9:27 [PATCH 0/3] Split patches sent earlier Dominique Martinet via B4 Relay
@ 2025-09-26  9:27 ` Dominique Martinet via B4 Relay
  2025-09-26  9:27 ` [PATCH 2/3] 9p: fix /sys/fs/9p/caches overwriting itself Dominique Martinet via B4 Relay
  2025-09-26  9:27 ` [PATCH 3/3] 9p: sysfs_init: don't hardcode error to ENOMEM Dominique Martinet via B4 Relay
  2 siblings, 0 replies; 4+ messages in thread
From: Dominique Martinet via B4 Relay @ 2025-09-26  9:27 UTC (permalink / raw)
  To: Randall P. Embry, Eric Van Hensbergen, Latchesar Ionkov,
	Christian Schoenebeck
  Cc: v9fs, linux-kernel, Dominique Martinet

From: "Randall P. Embry" <rpembry@gmail.com>

Fix a few minor typos in comments (e.g. "trasnport" → "transport").

Signed-off-by: Randall P. Embry <rpembry@gmail.com>
Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
---
 fs/9p/v9fs.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/fs/9p/v9fs.c b/fs/9p/v9fs.c
index 77e9c4387c1dfd4de8a54e9b6f676bdf987dbdc9..01e70a464b6039231df272e43b4ebdd3b5afb967 100644
--- a/fs/9p/v9fs.c
+++ b/fs/9p/v9fs.c
@@ -438,8 +438,7 @@ struct p9_fid *v9fs_session_init(struct v9fs_session_info *v9ses,
 		v9ses->flags &= ~V9FS_ACCESS_MASK;
 		v9ses->flags |= V9FS_ACCESS_USER;
 	}
-	/*FIXME !! */
-	/* for legacy mode, fall back to V9FS_ACCESS_ANY */
+	/* FIXME: for legacy mode, fall back to V9FS_ACCESS_ANY */
 	if (!(v9fs_proto_dotu(v9ses) || v9fs_proto_dotl(v9ses)) &&
 		((v9ses->flags&V9FS_ACCESS_MASK) == V9FS_ACCESS_USER)) {
 
@@ -450,7 +449,7 @@ struct p9_fid *v9fs_session_init(struct v9fs_session_info *v9ses,
 	if (!v9fs_proto_dotl(v9ses) ||
 		!((v9ses->flags & V9FS_ACCESS_MASK) == V9FS_ACCESS_CLIENT)) {
 		/*
-		 * We support ACL checks on clinet only if the protocol is
+		 * We support ACL checks on client only if the protocol is
 		 * 9P2000.L and access is V9FS_ACCESS_CLIENT.
 		 */
 		v9ses->flags &= ~V9FS_ACL_MASK;
@@ -669,7 +668,7 @@ static int __init init_v9fs(void)
 	int err;
 
 	pr_info("Installing v9fs 9p2000 file system support\n");
-	/* TODO: Setup list of registered trasnport modules */
+	/* TODO: Setup list of registered transport modules */
 
 	err = v9fs_init_inode_cache();
 	if (err < 0) {

-- 
2.51.0



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

* [PATCH 2/3] 9p: fix /sys/fs/9p/caches overwriting itself
  2025-09-26  9:27 [PATCH 0/3] Split patches sent earlier Dominique Martinet via B4 Relay
  2025-09-26  9:27 ` [PATCH 1/3] 9p: clean up comment typos Dominique Martinet via B4 Relay
@ 2025-09-26  9:27 ` Dominique Martinet via B4 Relay
  2025-09-26  9:27 ` [PATCH 3/3] 9p: sysfs_init: don't hardcode error to ENOMEM Dominique Martinet via B4 Relay
  2 siblings, 0 replies; 4+ messages in thread
From: Dominique Martinet via B4 Relay @ 2025-09-26  9:27 UTC (permalink / raw)
  To: Randall P. Embry, Eric Van Hensbergen, Latchesar Ionkov,
	Christian Schoenebeck
  Cc: v9fs, linux-kernel, Dominique Martinet

From: "Randall P. Embry" <rpembry@gmail.com>

caches_show() overwrote its buffer on each iteration,
so only the last cache tag was visible in sysfs output.

Properly append with snprintf(buf + count, …).

Signed-off-by: Randall P. Embry <rpembry@gmail.com>
Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
---
 fs/9p/v9fs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/9p/v9fs.c b/fs/9p/v9fs.c
index 01e70a464b6039231df272e43b4ebdd3b5afb967..4d289c56578fb15e45d8e94a264977898973cb31 100644
--- a/fs/9p/v9fs.c
+++ b/fs/9p/v9fs.c
@@ -560,7 +560,7 @@ static ssize_t caches_show(struct kobject *kobj,
 	spin_lock(&v9fs_sessionlist_lock);
 	list_for_each_entry(v9ses, &v9fs_sessionlist, slist) {
 		if (v9ses->cachetag) {
-			n = snprintf(buf, limit, "%s\n", v9ses->cachetag);
+			n = snprintf(buf + count, limit, "%s\n", v9ses->cachetag);
 			if (n < 0) {
 				count = n;
 				break;

-- 
2.51.0



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

* [PATCH 3/3] 9p: sysfs_init: don't hardcode error to ENOMEM
  2025-09-26  9:27 [PATCH 0/3] Split patches sent earlier Dominique Martinet via B4 Relay
  2025-09-26  9:27 ` [PATCH 1/3] 9p: clean up comment typos Dominique Martinet via B4 Relay
  2025-09-26  9:27 ` [PATCH 2/3] 9p: fix /sys/fs/9p/caches overwriting itself Dominique Martinet via B4 Relay
@ 2025-09-26  9:27 ` Dominique Martinet via B4 Relay
  2 siblings, 0 replies; 4+ messages in thread
From: Dominique Martinet via B4 Relay @ 2025-09-26  9:27 UTC (permalink / raw)
  To: Randall P. Embry, Eric Van Hensbergen, Latchesar Ionkov,
	Christian Schoenebeck
  Cc: v9fs, linux-kernel, Dominique Martinet

From: "Randall P. Embry" <rpembry@gmail.com>

v9fs_sysfs_init() always returned -ENOMEM on failure;
return the actual sysfs_create_group() error instead.

Signed-off-by: Randall P. Embry <rpembry@gmail.com>
Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
---
 fs/9p/v9fs.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/fs/9p/v9fs.c b/fs/9p/v9fs.c
index 4d289c56578fb15e45d8e94a264977898973cb31..a020a8f00a1ac074e826a728c5a2b1ef09ec87fd 100644
--- a/fs/9p/v9fs.c
+++ b/fs/9p/v9fs.c
@@ -596,13 +596,16 @@ static const struct attribute_group v9fs_attr_group = {
 
 static int __init v9fs_sysfs_init(void)
 {
+	int ret;
+
 	v9fs_kobj = kobject_create_and_add("9p", fs_kobj);
 	if (!v9fs_kobj)
 		return -ENOMEM;
 
-	if (sysfs_create_group(v9fs_kobj, &v9fs_attr_group)) {
+	ret = sysfs_create_group(v9fs_kobj, &v9fs_attr_group);
+	if (ret) {
 		kobject_put(v9fs_kobj);
-		return -ENOMEM;
+		return ret;
 	}
 
 	return 0;

-- 
2.51.0



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

end of thread, other threads:[~2025-09-26  9:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-09-26  9:27 [PATCH 0/3] Split patches sent earlier Dominique Martinet via B4 Relay
2025-09-26  9:27 ` [PATCH 1/3] 9p: clean up comment typos Dominique Martinet via B4 Relay
2025-09-26  9:27 ` [PATCH 2/3] 9p: fix /sys/fs/9p/caches overwriting itself Dominique Martinet via B4 Relay
2025-09-26  9:27 ` [PATCH 3/3] 9p: sysfs_init: don't hardcode error to ENOMEM Dominique Martinet via B4 Relay

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®