linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 0/1] Bind-mounting memfds
@ 2026-01-29 17:35 Snaipe
  2026-01-29 17:35 ` [RFC PATCH 1/1] fs,ns: allow copying of shm_mnt mount trees Snaipe
  0 siblings, 1 reply; 5+ messages in thread
From: Snaipe @ 2026-01-29 17:35 UTC (permalink / raw)
  To: linux-fsdevel; +Cc: linux-mm

From: "Franklin \"Snaipe\" Mathieu" <me@snai.pe>

Hi folks,

I'm sending this patch that allows the use of open_tree on a memfd with
the intent of bind-mounting it.

I am unsure about the execution of this patch. shm_mnt fails the is_mounted
check, but unlike pidfs and nsfs I can't compare the dentry's d_op
against a known dentry ops global.

I opted for a simple check of path->mnt against shm_mnt but I'm not sure
it's the best approach. Please advise if there's anything better,
otherwise, the patch itself should be straigtforward enough.

Franklin "Snaipe" Mathieu (1):
  fs,ns: allow copying of shm_mnt mount trees

 fs/namespace.c | 8 ++++++++
 mm/internal.h  | 2 ++
 mm/shmem.c     | 2 +-
 3 files changed, 11 insertions(+), 1 deletion(-)

-- 
2.52.0



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

end of thread, other threads:[~2026-02-04 16:51 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-01-29 17:35 [RFC PATCH 0/1] Bind-mounting memfds Snaipe
2026-01-29 17:35 ` [RFC PATCH 1/1] fs,ns: allow copying of shm_mnt mount trees Snaipe
2026-01-30  8:38   ` Johannes Thumshirn
2026-01-30 14:17     ` Snaipe
2026-02-04 16:51   ` Christian Brauner

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