Received: by 2002:ab2:6991:0:b0:1f7:f6c3:9cb1 with SMTP id v17csp476522lqo; Wed, 8 May 2024 05:56:32 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCV8B4UGdMEvmx/edKXoI8OWtNBdhkERx+Yo9bjQStrsiMzfECjvFy7HwzUrLku5N8bmj0QJuLvV/nkq5912stKw6MfoE2Rph69B65VIgQ== X-Google-Smtp-Source: AGHT+IHCWrYuR5xwQ4RICMGm8ZyegjmzqP8/5CEBMueWWx8x+C4CH8VJVp7ehlCHjKUK6QaI3aLo X-Received: by 2002:a05:6358:741f:b0:186:1908:4c4f with SMTP id e5c5f4694b2df-192d2d28ed8mr299164855d.13.1715172991992; Wed, 08 May 2024 05:56:31 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715172991; cv=pass; d=google.com; s=arc-20160816; b=ZTRsN+nK7CXJ5olzeRe4AW0kXUd+MM78KFYJZh+oUy/WKe7cSAXWJIELxPM6P7Tnq0 HW0GJNeerKTl0C9y9lbOZ3Nm4vuaqodMkz1791oAHqDyba75BfYKW4VEJkx/TldpR59/ If52L4J6lTcpcFaNqiJLd66lJzmJdFNqJH35/3hao93kBmbYMJKDgQahK6Z0i9M5RR9j QIm+ZMEi/KtLnWt0Q0Tx0OHGdsEBNVlEeW5CFNdsrgONAPkHNKIF1twn30EEITDpAjTc vFKH/94wnz6m6pny+2HNtu0A2i2fn/xq+vpeREBo3RSu6tbWAhgdtNQBEz4JuDMqj6+/ FJQg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :references:message-id:subject:cc:to:from:date:dkim-signature; bh=AFX7epc56GdxP6YX/if7jE9kam6l8moWdV43XYBcqfk=; fh=EXeh0QXD8yIO7zRa1z9rYWjTgJJfRYmA7W9VW6WYneg=; b=q4XyQ7gYKwkaObgwbak5/Ga7zTvv2sVibQHJWmqsn8nW3an3OOAoL2PBA+qqriFYRS 3RkmUN0r3VRsQSH7onTQR1irfFEXhglDEY58WH19jNsSqpdwOy39DBR0d2inEeKsVcsx l/3PziKAtIgdYFM3Q7I5bbetrxhwrcShW++s0KSbMO5pX1VE6L1rJ+nx4kSInKSD1svu xszLE6F94NJ27hc+R+OFy2JDSOpuMeSoUNy/OIeDZMlBjEthNZ42O9narS29kSDQQ1EL BZ49bVW+NdRJ1cyWHXVlKH96SQTfziwIyYOTeCebxShdN0v7gax085C5wkM6G0V0w4qm gwDQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=VPMc4kPr; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-173261-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-173261-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id p16-20020a63e650000000b006229f0d8dfesi7706809pgj.832.2024.05.08.05.56.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 May 2024 05:56:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-173261-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=VPMc4kPr; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-173261-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-173261-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 2CA34286D7A for ; Wed, 8 May 2024 12:56:02 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 521306BB4C; Wed, 8 May 2024 12:55:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="VPMc4kPr" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7AF645577E; Wed, 8 May 2024 12:55:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715172947; cv=none; b=atS1B5wBuaSDo2lqIHsg2DWUs6cwEY0mAriYuOGoHHT8X7j2vVPBfwAZ2QUhMJNMINOG5pLDJZglsO2RHde58wg8caukSBjcaxmk9zcLZ05ajQwhQuHVF7sxXvTmx0D85SCAUvkt41REwRuEb3hft7nzCvWy+ulkrVK/S7bGCmU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715172947; c=relaxed/simple; bh=HFjEV6bitERe7TiGEuLCCfdbBkzxSKIi/HLyB6z3Y38=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=lNrME1sz7z1BaGw63RSD2c2wzQX6YYBZuWUAhhlD2uTQxsXc0puA/X1uT41JQiWHHsuZRffWGYbjdxClwCoUU5lQeJTe675jCUS/pgi20JZ2stG9PtCazyYqXUOAHZ7E9Ds9JdGR2tAaTKqPtcXkaAp25HfGsPNfS3enfTUus7c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=VPMc4kPr; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id A5E7FC4AF17; Wed, 8 May 2024 12:55:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1715172947; bh=HFjEV6bitERe7TiGEuLCCfdbBkzxSKIi/HLyB6z3Y38=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=VPMc4kPrKIUE897oq43s3XFEpz2n3ycWxi0zvc9DYiOdRCTdo62ThwUuhhywj8g1b WCtSTXwqNq9GoIf3iZd8V+N4XRp8EdKbXRo63BRuhTzJlxR2xKWAonPVp4if/6gmCd CeHKj7nOamyHUIyx+tfCPxYowTgX4ufLg6n8s78MftECQZDlICoECPYOw2FkX/flY7 RXrg2khU1N0dN1H5ZP+Ll4YbAf/1S333GDxQeVLBnJStGL31Hj9Z1xIVioiVbmGmG1 1VQ1iCdQWkTVHsMA8IaXb7W2d8TKyaK5EU0UVVHgewDpAYkrCTpurDvEs+YLonKkmk kgef35TYEvL7A== Date: Wed, 8 May 2024 14:55:44 +0200 From: Frederic Weisbecker To: Valentin Schneider Cc: rcu@vger.kernel.org, linux-kernel@vger.kernel.org, "Paul E. McKenney" , Peter Zijlstra , Neeraj Upadhyay , Joel Fernandes , Josh Triplett , Boqun Feng , Steven Rostedt , Mathieu Desnoyers , Lai Jiangshan , Zqiang Subject: Re: [PATCH v2 20/27] rcu: Rename struct rcu_data .dynticks_snap into .watching_snap Message-ID: References: <20240430091740.1826862-1-vschneid@redhat.com> <20240430091740.1826862-21-vschneid@redhat.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20240430091740.1826862-21-vschneid@redhat.com> Le Tue, Apr 30, 2024 at 11:17:24AM +0200, Valentin Schneider a ?crit : > The context_tracking.state RCU_DYNTICKS subvariable has been renamed to > RCU_WATCHING, and the snapshot helpers are now prefix by > "rcu_watching". Reflect that change into the storage variables for these > snapshots. > > Signed-off-by: Valentin Schneider > --- > .../RCU/Design/Data-Structures/Data-Structures.rst | 4 ++-- > kernel/rcu/tree.c | 6 +++--- > kernel/rcu/tree.h | 2 +- > 3 files changed, 6 insertions(+), 6 deletions(-) > > diff --git a/Documentation/RCU/Design/Data-Structures/Data-Structures.rst b/Documentation/RCU/Design/Data-Structures/Data-Structures.rst > index 5389cc49bea13..de76c624fe93e 100644 > --- a/Documentation/RCU/Design/Data-Structures/Data-Structures.rst > +++ b/Documentation/RCU/Design/Data-Structures/Data-Structures.rst > @@ -921,10 +921,10 @@ This portion of the ``rcu_data`` structure is declared as follows: > > :: > > - 1 int dynticks_snap; > + 1 int watching_snap; > 2 unsigned long dynticks_fqs; > > -The ``->dynticks_snap`` field is used to take a snapshot of the > +The ``->watching_snap`` field is used to take a snapshot of the > corresponding CPU's dyntick-idle state when forcing quiescent states, Not sure if it's handled in forecoming patches but: s/dyntick-idle/watching > and is therefore accessed from other CPUs. Finally, the > ``->dynticks_fqs`` field is used to count the number of times this CPU Looks like this one is a leftover... > diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c > index d3f3a049904fc..73b95240a1a6c 100644 > --- a/kernel/rcu/tree.c > +++ b/kernel/rcu/tree.c > @@ -770,8 +770,8 @@ static void rcu_gpnum_ovf(struct rcu_node *rnp, struct rcu_data *rdp) > */ > static int dyntick_save_progress_counter(struct rcu_data *rdp) > { > - rdp->dynticks_snap = rcu_watching_snap(rdp->cpu); > - if (rcu_watching_in_eqs(rdp->dynticks_snap)) { > + rdp->watching_snap = rcu_watching_snap(rdp->cpu); > + if (rcu_watching_in_eqs(rdp->watching_snap)) { > trace_rcu_fqs(rcu_state.name, rdp->gp_seq, rdp->cpu, TPS("dti")); > rcu_gpnum_ovf(rdp->mynode, rdp); > return 1; > @@ -803,7 +803,7 @@ static int rcu_implicit_dynticks_qs(struct rcu_data *rdp) > * read-side critical section that started before the beginning > * of the current RCU grace period. > */ > - if (rcu_watching_changed_since(rdp, rdp->dynticks_snap)) { > + if (rcu_watching_changed_since(rdp, rdp->watching_snap)) { > trace_rcu_fqs(rcu_state.name, rdp->gp_seq, rdp->cpu, TPS("dti")); > rcu_gpnum_ovf(rnp, rdp); > return 1; > diff --git a/kernel/rcu/tree.h b/kernel/rcu/tree.h > index affcb92a358c3..ac153e365355d 100644 > --- a/kernel/rcu/tree.h > +++ b/kernel/rcu/tree.h > @@ -206,7 +206,7 @@ struct rcu_data { > long blimit; /* Upper limit on a processed batch */ > > /* 3) dynticks interface. */ > - int dynticks_snap; /* Per-GP tracking for dynticks. */ > + int watching_snap; /* Per-GP tracking for dynticks. */ /* Per-GP tracking for watching */ Thanks. > bool rcu_need_heavy_qs; /* GP old, so heavy quiescent state! */ > bool rcu_urgent_qs; /* GP old need light quiescent state. */ > bool rcu_forced_tick; /* Forced tick to provide QS. */ > -- > 2.43.0 >