From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B1A79C43332 for ; Sat, 21 Mar 2020 10:26:56 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 91E89206F9 for ; Sat, 21 Mar 2020 10:26:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728369AbgCUK0y (ORCPT ); Sat, 21 Mar 2020 06:26:54 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:37966 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726652AbgCUK0x (ORCPT ); Sat, 21 Mar 2020 06:26:53 -0400 Received: from p5de0bf0b.dip0.t-ipconnect.de ([93.224.191.11] helo=nanos.tec.linutronix.de) by Galois.linutronix.de with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1jFbKR-0001Rx-D7; Sat, 21 Mar 2020 11:26:07 +0100 Received: by nanos.tec.linutronix.de (Postfix, from userid 1000) id C6E72FFC8D; Sat, 21 Mar 2020 11:26:06 +0100 (CET) From: Thomas Gleixner To: paulmck@kernel.org Cc: LKML , Peter Zijlstra , Linus Torvalds , Ingo Molnar , Will Deacon , Joel Fernandes , Steven Rostedt , Randy Dunlap , Sebastian Andrzej Siewior , Logan Gunthorpe , Kurt Schwemmer , Bjorn Helgaas , linux-pci@vger.kernel.org, Felipe Balbi , Greg Kroah-Hartman , linux-usb@vger.kernel.org, Kalle Valo , "David S. Miller" , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, Oleg Nesterov , Davidlohr Bueso , Michael Ellerman , Arnd Bergmann , linuxppc-dev@lists.ozlabs.org Subject: Re: [patch V2 08/15] Documentation: Add lock ordering and nesting documentation In-Reply-To: <20200321022930.GU3199@paulmck-ThinkPad-P72> References: <20200320160145.GN3199@paulmck-ThinkPad-P72> <87mu8apzxr.fsf@nanos.tec.linutronix.de> <20200320210243.GT3199@paulmck-ThinkPad-P72> <874kuipsbw.fsf@nanos.tec.linutronix.de> <20200321022930.GU3199@paulmck-ThinkPad-P72> Date: Sat, 21 Mar 2020 11:26:06 +0100 Message-ID: <875zeyrold.fsf@nanos.tec.linutronix.de> MIME-Version: 1.0 Content-Type: text/plain X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org "Paul E. McKenney" writes: > On Fri, Mar 20, 2020 at 11:36:03PM +0100, Thomas Gleixner wrote: >> I agree that what I tried to express is hard to parse, but it's at least >> halfways correct :) > > Apologies! That is what I get for not looking it up in the source. :-/ > > OK, so I am stupid enough not only to get it wrong, but also to try again: > > ... Other types of wakeups would normally unconditionally set the > task state to RUNNING, but that does not work here because the task > must remain blocked until the lock becomes available. Therefore, > when a non-lock wakeup attempts to awaken a task blocked waiting > for a spinlock, it instead sets the saved state to RUNNING. Then, > when the lock acquisition completes, the lock wakeup sets the task > state to the saved state, in this case setting it to RUNNING. > > Is that better? Definitely! Thanks for all the editorial work! tglx