Received: by 2002:a05:6a10:6006:0:0:0:0 with SMTP id w6csp250045pxa; Thu, 27 Aug 2020 00:49:59 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy+idO4U/zdCJp0KaTm9Bpz5rN1GOFzFZSNmpDglcQkphsKczwsbGYcbbROxg/SPvvv7HFT X-Received: by 2002:a17:906:bb06:: with SMTP id jz6mr20408030ejb.248.1598514599011; Thu, 27 Aug 2020 00:49:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598514599; cv=none; d=google.com; s=arc-20160816; b=02k8gW02dxD7jkUaRAO0pos7b/aCpkLSX9NrYjPzpokLkzdcgG/oZ8xp6Azsmo9XE9 r1JjBG06CYDigAwNLfGQTaQ9OXPTd7QB6+w9MbBgkBTPTmNLoYmnrk3h5QIgFkOZe0M2 uKLUljKotyO2rbw8l9wxtqfiRY36l8RY5OhtOJOZhfBXq3UKxwjyAlmi8LpKxDcccxgO 5HwAKYKZ8d8VQZSrmN+Xz9J+TxDjYm9onRyvccIxYkJBJMvTNFS1d3zZliRYVdl6YBnY IhvFLYDuEztvbJ0KuYiEYAbFi5TgfVE7FR4aGjeQQHiNf1XvAYUlPcqNBopn4L05MnRf rzcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=1x9RtyT+zN/ZOJdCo9mX7Qqd1GAx7JmJgX/A552ZdjQ=; b=O+FMwi16VYsyu5Lvb7ymm3EEXmGg8ZikwBiomjdZ+84rbeoIc7noxRKQBgiLfY1ziv NDN+/0nB1Cq43ekvvVU3DnBTShTSDRTtxfjSVHeRVRIcGsgsE1K+sP8e3bTAK3pcWbNF ASF6juid/YkqXUV+GuvIJqSfJqH89Rlg6K9kjMSdm0vt9gPBJiQqzwiaWPCBWwJtQIKk xVtAZMNBMTKAiz1g5iMv2mJxecUvo9aC/+Cv5D1lMH4vux2l2041CsUBTAnDj+BwmfeY My2wWOnCUf9G2inZneq/Mabf7K7ZtVhmZ+m6RJNlPJUVaGbLqSr5GCx+TPGl9EWZdiR2 cazw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=AoAiIWDB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a15si1108191edr.470.2020.08.27.00.49.36; Thu, 27 Aug 2020 00:49:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=AoAiIWDB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728375AbgH0HsO (ORCPT + 99 others); Thu, 27 Aug 2020 03:48:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51534 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728116AbgH0HsL (ORCPT ); Thu, 27 Aug 2020 03:48:11 -0400 Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:8b0:10b:1231::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2F808C061264 for ; Thu, 27 Aug 2020 00:48:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.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=1x9RtyT+zN/ZOJdCo9mX7Qqd1GAx7JmJgX/A552ZdjQ=; b=AoAiIWDBL/K9/4O+iAp2R8pTuU hdOOPr+eUiOux/hYpv7++nDy3qa4rm1qoxamt86Fj1fxXMaj5iJft4xdrDef1Oxx9qprR9AzcBHnj nX3Av4Q/AnTUbKt/jFprKOx8E/vJQu9VDMCiXs95FSPt9leJvOtoofDFSe5ghohxImtssM2Jm1OHl /fI98XGLJMRcey/Fr+ZmqtYXiZbpcz5q6ofZTNE/2bzxhtBDws4yaxlkqQApbwXscOT7S1rBqJ+ta C9IdkJG6hfEPaU8OIzBiHeNFNaAgOBIvlCjOqijVRC2dw0ugFInpu34NRkdFq8h4/l/BQ2Nq7SwnL EOc0m5kg==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by merlin.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1kBCdW-0001xG-7w; Thu, 27 Aug 2020 07:47:54 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 02252305C10; Thu, 27 Aug 2020 09:47:48 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id E01B52C187882; Thu, 27 Aug 2020 09:47:48 +0200 (CEST) Date: Thu, 27 Aug 2020 09:47:48 +0200 From: peterz@infradead.org To: Joel Fernandes Cc: linux-kernel@vger.kernel.org, mingo@kernel.org, will@kernel.org, npiggin@gmail.com, elver@google.com, jgross@suse.com, paulmck@kernel.org, rostedt@goodmis.org, rjw@rjwysocki.net, svens@linux.ibm.com, tglx@linutronix.de Subject: Re: [PATCH v2 03/11] sched,idle,rcu: Push rcu_idle deeper into the idle path Message-ID: <20200827074748.GY2674@hirez.programming.kicks-ass.net> References: <20200821084738.508092956@infradead.org> <20200821085348.310943801@infradead.org> <20200827011826.GA1942571@google.com> <20200827012419.GB1942571@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200827012419.GB1942571@google.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Aug 26, 2020 at 09:24:19PM -0400, Joel Fernandes wrote: > On Wed, Aug 26, 2020 at 09:18:26PM -0400, Joel Fernandes wrote: > > On Fri, Aug 21, 2020 at 10:47:41AM +0200, Peter Zijlstra wrote: > > > Lots of things take locks, due to a wee bug, rcu_lockdep didn't notice > > > that the locking tracepoints were using RCU. > > > > > > Push rcu_idle_{enter,exit}() as deep as possible into the idle paths, > > > this also resolves a lot of _rcuidle()/RCU_NONIDLE() usage. > > > > > > Specifically, sched_clock_idle_wakeup_event() will use ktime which > > > will use seqlocks which will tickle lockdep, and > > > stop_critical_timings() uses lock. > > > > I was wondering if those tracepoints should just use _rcuidle variant of the > > trace call. But that's a terrible idea considering that would add unwanted > > overhead I think. > > > > Reviewed-by: Joel Fernandes (Google) > > BTW, if tracepoint is converted to use RCU-trace flavor, then these kinds of > issues go away, no? That RCU flavor is always watching. All trace_*_rcuidle() and RCU_NONIDLE() usage is a bug IMO. Ideally RCU-trace goes away too.