[PATCH v2] drivers/base: make devtmpfs_context_ops static

Alexey Suchkov posted 1 patch 3 weeks, 1 day ago
drivers/base/devtmpfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[PATCH v2] drivers/base: make devtmpfs_context_ops static
Posted by Alexey Suchkov 3 weeks, 1 day ago
The devtmpfs_context_ops symbol is only used within devtmpfs.c.
Marking it static removes compiler warnings and limits symbol visibility.

Changes since v1:
- Use real name in From and Signed-off-by

Signed-off-by: Alexey Suchkov <aleks.koyf@gmail.com>
---
 drivers/base/devtmpfs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/base/devtmpfs.c b/drivers/base/devtmpfs.c
index 194b44075..748ad3698 100644
--- a/drivers/base/devtmpfs.c
+++ b/drivers/base/devtmpfs.c
@@ -85,7 +85,7 @@ static int devtmpfs_get_tree(struct fs_context *fc)
 }
 
 /* Ops are filled in during init depending on underlying shmem or ramfs type */
-struct fs_context_operations devtmpfs_context_ops = {};
+static struct fs_context_operations devtmpfs_context_ops = {};
 
 /* Call the underlying initialization and set to our ops */
 static int devtmpfs_init_fs_context(struct fs_context *fc)
-- 
2.52.0
Re: [PATCH v2] drivers/base: make devtmpfs_context_ops static
Posted by Danilo Krummrich 3 weeks ago
On Fri Jan 16, 2026 at 4:42 PM CET, Alexey Suchkov wrote:
> The devtmpfs_context_ops symbol is only used within devtmpfs.c.
> Marking it static removes compiler warnings and limits symbol visibility.
>
> Changes since v1:
> - Use real name in From and Signed-off-by
>
> Signed-off-by: Alexey Suchkov <aleks.koyf@gmail.com>

This is already fixed by [1]. Note that the patch was already sent at Jan 8, but
due to a typo didn't make it to the list.

[1] https://patch.msgid.link/20260116150745.1330145-1-ben.dooks@codethink.co.uk
Re: [PATCH] drivers/base: make devtmpfs_context_ops static
Posted by Alexey Suchkov 3 weeks ago
Hi Danilo,

> This is already fixed by [1]. Note that the patch was already sent at Jan 8, but
> due to a typo didn't make it to the list.

Thanks for the pointer. Since this is already fixed by another patch,
I'll drop mine. Thank you!