Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp4251089rwd; Tue, 30 May 2023 02:40:52 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7vxatdb0bt9u43Bjj+LglmqtxaiyxNTGK9NIhriFbLjKj23RrqHWhLoDUunfdgR1+5uajA X-Received: by 2002:a17:90a:d305:b0:256:cf39:afce with SMTP id p5-20020a17090ad30500b00256cf39afcemr584625pju.43.1685439652041; Tue, 30 May 2023 02:40:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685439652; cv=none; d=google.com; s=arc-20160816; b=hyhQiqEm6pk6g54TzrYgx0jUq0uHLQiYMzMrpA8mQ2xTP1WC63XJu9e6IffU5aKNVb xY2wbeQqALsByllEz7z8TMrAHTM94LSHyhcx3F9OaPp6jSkNbTKYO+sGbliP1GKTre46 c7+LxUY42wErlwhkwfMF5CgX5/BCzHM5QubsPl/2Vw5eRBC6I4+g53PqYnlhDVASjRWF 8XDZ/62bYGRM4hifiuJQPeR9emTpM15BTMZMIxWpxlgyhOCdpb+r7DjfusUiOHPhDLVE aOkE7JHry3JBvm4iDweM1Uxuzk5LCWFPYAEIvEjdvaM1Pg60cR9efbp9J7gm6Kj2mNkO 03MA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=YGnwDGPWaj1wM5ohiXtoRKNtCYZ1i8Q7KV5owZIHFf0=; b=O0/NKMyIxGdRWXSEOdgU3RiFIYy5/z3nPC3umpUvXfhUl43xBOcNjYW7p5CECICAVb pAwfo7kLbZv3N4Qayi78OK6C7f/IW4b15YgSgZknqOXkmxBM4odnZr0T6IqnlvbDC11m Gl8/YA40SQ3hZRFgj2fCRmUfx6yTG22x17H3nvGN6Kain40egXCZfmRmYWrH7gDZFf41 oHRQqdyWH/084d+3bctccgPsg4jSGBkaXXYfWX59xCoW/cK2UgYLB3GWg+Hb5iNSWNCW MFufDVd1PfP1iGVyfBNVqIAloN5rlMmasyP8t2zwjS6wJ+Zh+luYnZFK5xeXjZofvevV jL7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=DjY1MJJi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id pc16-20020a17090b3b9000b0024e0f3308a0si5232865pjb.32.2023.05.30.02.40.39; Tue, 30 May 2023 02:40:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=DjY1MJJi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231196AbjE3J1i (ORCPT + 99 others); Tue, 30 May 2023 05:27:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43490 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230152AbjE3J1S (ORCPT ); Tue, 30 May 2023 05:27:18 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5C091E77; Tue, 30 May 2023 02:26:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=YGnwDGPWaj1wM5ohiXtoRKNtCYZ1i8Q7KV5owZIHFf0=; b=DjY1MJJiu6hf7xjfPEede0fXKw EXw5HsAeuiGhaxVwsAzllEUOGYYYTU2DfOei8MfAgi8mPP3FnZCJsFJcTI5NV8xSlfKocHHeZx02U wMh5+a8lqTNEEytvd9QmKxxCQf+6Vz0q2lt39tRfv15c5uYwTWWedBzls+f1+FyRWZ6mLJVpmjdjL nmxRAYDGnwnfMhJa3/Cfm3F92l0eCQRXFBiSzZwi4mThZPgCtaQhcqmrA8N2tQYlR805K3CUoGTb2 7+dYhZckEr89Dboqd3SWEwI+hf2rR9S22cowGo1cHj+O+bZERYADKgZDcNikJEeAe4cH7PzHsj0iF ljLI86ag==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1q3vcF-006AJ1-T4; Tue, 30 May 2023 09:26:07 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 75C8F3001C3; Tue, 30 May 2023 11:26:07 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 5D396214873C3; Tue, 30 May 2023 11:26:07 +0200 (CEST) Date: Tue, 30 May 2023 11:26:07 +0200 From: Peter Zijlstra To: Linus Torvalds Cc: keescook@chromium.org, gregkh@linuxfoundation.org, pbonzini@redhat.com, linux-kernel@vger.kernel.org, ojeda@kernel.org, ndesaulniers@google.com, mingo@redhat.com, will@kernel.org, longman@redhat.com, boqun.feng@gmail.com, juri.lelli@redhat.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de, bristot@redhat.com, vschneid@redhat.com, paulmck@kernel.org, frederic@kernel.org, quic_neeraju@quicinc.com, joel@joelfernandes.org, josh@joshtriplett.org, mathieu.desnoyers@efficios.com, jiangshanlai@gmail.com, rcu@vger.kernel.org, tj@kernel.org, tglx@linutronix.de Subject: Re: [PATCH v2 0/2] Lock and Pointer guards Message-ID: <20230530092607.GB149947@hirez.programming.kicks-ass.net> References: <20230526205204.861311518@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, May 27, 2023 at 12:18:04PM -0700, Linus Torvalds wrote: > And before you say "unlock order doesn't matter" - that's actually not > true. Unlock order does matter when you have things like > "spin_lock_irq()" where the irq-off region then protects other locks > too. So I had already verified that GCC keeps them ordered, I see the subthread with Ian and the documentation update request -- so all good there. Also, lockdep would scream bloody murder if you get that wrong, so I can certainly add something to the selftests that would detect this.