* [PATCH] fsnotify: inotify: pass mark connector to fsnotify_recalc_mask()
@ 2026-02-14 5:12 Sun Jian
2026-02-16 13:37 ` Jan Kara
0 siblings, 1 reply; 2+ messages in thread
From: Sun Jian @ 2026-02-14 5:12 UTC (permalink / raw)
To: Jan Kara; +Cc: Amir Goldstein, linux-fsdevel, linux-kernel, Sun Jian
fsnotify_recalc_mask() expects a plain struct fsnotify_mark_connector *,
but inode->i_fsnotify_marks is an __rcu pointer. Use fsn_mark->connector
instead to avoid sparse "different address spaces" warnings.
Signed-off-by: Sun Jian <sun.jian.kdev@gmail.com>
---
fs/notify/inotify/inotify_user.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/notify/inotify/inotify_user.c b/fs/notify/inotify/inotify_user.c
index b372fb2c56bd..9a5f2af94659 100644
--- a/fs/notify/inotify/inotify_user.c
+++ b/fs/notify/inotify/inotify_user.c
@@ -573,7 +573,7 @@ static int inotify_update_existing_watch(struct fsnotify_group *group,
/* update the inode with this new fsn_mark */
if (dropped || do_inode)
- fsnotify_recalc_mask(inode->i_fsnotify_marks);
+ fsnotify_recalc_mask(fsn_mark->connector);
}
--
2.43.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] fsnotify: inotify: pass mark connector to fsnotify_recalc_mask()
2026-02-14 5:12 [PATCH] fsnotify: inotify: pass mark connector to fsnotify_recalc_mask() Sun Jian
@ 2026-02-16 13:37 ` Jan Kara
0 siblings, 0 replies; 2+ messages in thread
From: Jan Kara @ 2026-02-16 13:37 UTC (permalink / raw)
To: Sun Jian; +Cc: Jan Kara, Amir Goldstein, linux-fsdevel, linux-kernel
On Sat 14-02-26 13:12:17, Sun Jian wrote:
> fsnotify_recalc_mask() expects a plain struct fsnotify_mark_connector *,
> but inode->i_fsnotify_marks is an __rcu pointer. Use fsn_mark->connector
> instead to avoid sparse "different address spaces" warnings.
>
> Signed-off-by: Sun Jian <sun.jian.kdev@gmail.com>
Thanks. The patch looks good to me. I'll queue it in my tree once the merge
window closes.
Honza
> ---
> fs/notify/inotify/inotify_user.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/notify/inotify/inotify_user.c b/fs/notify/inotify/inotify_user.c
> index b372fb2c56bd..9a5f2af94659 100644
> --- a/fs/notify/inotify/inotify_user.c
> +++ b/fs/notify/inotify/inotify_user.c
> @@ -573,7 +573,7 @@ static int inotify_update_existing_watch(struct fsnotify_group *group,
>
> /* update the inode with this new fsn_mark */
> if (dropped || do_inode)
> - fsnotify_recalc_mask(inode->i_fsnotify_marks);
> + fsnotify_recalc_mask(fsn_mark->connector);
>
> }
>
> --
> 2.43.0
>
--
Jan Kara <jack@suse.com>
SUSE Labs, CR
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-02-16 13:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-02-14 5:12 [PATCH] fsnotify: inotify: pass mark connector to fsnotify_recalc_mask() Sun Jian
2026-02-16 13:37 ` Jan Kara
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®