Re: [PATCH 08/10] srcu: Add __srcu_clone_read_lock()

From: Peter Zijlstra
Date: Wed Jul 10 2024 - 06:02:20 EST


On Tue, Jul 09, 2024 at 10:48:39PM -0700, Boqun Feng wrote:
> On Mon, Jul 08, 2024 at 11:12:49AM +0200, Peter Zijlstra wrote:
> > In order to support carrying an srcu_read_lock() section across fork,
> > where both the parent and child process will do: srcu_read_unlock(),
> > it is needed to account for the extra decrement with an extra
> > increment at fork time.
> >
>
> We also need to dup the per-task lock held stack in order to maintain
> consistent data for lockdep, right?

Urgh, not the whole stack, but yeah, we need to stick an entry on there.

Let me see if I can frob that somehow.