Re: [PATCH v11 1/7] locking/mutex: Remove wakeups from under mutex::wait_lock
From: John Stultz
Date: Fri Jul 12 2024 - 15:55:02 EST
On Fri, Jul 12, 2024 at 7:52 AM Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
>
> On Tue, Jul 09, 2024 at 01:31:44PM -0700, John Stultz wrote:
> > @@ -405,8 +409,10 @@ ww_mutex_set_context_fastpath(struct ww_mutex *lock, struct ww_acquire_ctx *ctx)
> > * die or wound us.
> > */
> > lock_wait_lock(&lock->base);
> > - __ww_mutex_check_waiters(&lock->base, ctx);
> > + __ww_mutex_check_waiters(&lock->base, ctx, &wake_q);
>
> preempt_disable()
>
> > unlock_wait_lock(&lock->base);
> > +
> > + wake_up_q(&wake_q);
>
> preempt_enable();
Ah. Will fix for the next version. Thank you for the review and
pointing this out!
-john