Re: [PATCH v4] fs/namespace: defer RCU sync for MNT_DETACH umount

Sebastian Andrzej Siewior
2025-04-17T15:31:29Z

On 2025-04-17 17:28:20 [+0200], Christian Brauner wrote:
> > So if there's some userspace process with a broken NFS server and it
> > does umount(MNT_DETACH) it will end up hanging every other
> > umount(MNT_DETACH) on the system because the dealyed_mntput_work
> > workqueue (to my understanding) cannot make progress.
>
> Ok, "to my understanding" has been updated after going back and reading
> the delayed work code. Luckily it's not as bad as I thought it is
> because it's queued on system_wq which is multi-threaded so it's at
> least not causing everyone with MNT_DETACH to get stuck. I'm still
> skeptical how safe this all is.

I would (again) throw system_unbound_wq into the game because the former
will remain on the CPU on which has been enqueued (if speaking about
multi threading).

Sebastian