Received: by 2002:ab2:1689:0:b0:1f7:5705:b850 with SMTP id d9csp1896368lqa; Tue, 30 Apr 2024 02:27:49 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX6YLni4we+njBCQAA0RG/pAC05/+27KVfW2vwOkpk3IS+r2zuHf8xrdf4xyMQxY18PHSIqESEGCashdsmeJEVLgcb4jxUmSEQerSeQ/A== X-Google-Smtp-Source: AGHT+IH8rNuGHjygSnXor3oqqISXnzcX6G4oeGii08+rCkZPmKc9538TdXvtFbOZDuimqGXYvHlF X-Received: by 2002:a05:6870:6f05:b0:23c:b686:c84 with SMTP id qw5-20020a0568706f0500b0023cb6860c84mr4723346oab.44.1714469269120; Tue, 30 Apr 2024 02:27:49 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714469269; cv=pass; d=google.com; s=arc-20160816; b=DH1juLxFJhu3u1yzP8iojZ09wW6d/sxolViuTBLGhjgKV9zqcFeL8hAkwg+NceGTt0 MuhE+8wO3mlCoSzp4Pu82Z9OBkQMy/D8UC3OyCRw9lNBao3fdpFpqxS9tuDZtu4/YuaS Fuc6Hz5z+I8acYhzvcVXyP4R0IKLCpllbqMDSUciJkkNFCHBDkY0DyyYx18rkkGvDnRK 1LxAZp5g9thJVMPweAAvPF5Fe05qvv3WpbWjL4+jXayyFQLuKHY6K11NPVoMrSKESv56 42Nz3EwkGhONbqYqI/5yfh0A7VLB7XpgPyFL96yZllKMgaIs/s0D3WiQ+rgntPXKHlht kidQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=7iJ+HhpR5xS1NIdRXohsDpAsZ+ySrJwbYzJ1VO+vaqM=; fh=WzinSAfJjQwQsWhpsrf2fBMcmep3NnSwaYa0TI1U7L8=; b=O0+mlV07J4AljowbtH8t1RyefL63nFoBc+/XNk1s7ET/Db+7aX4ByzANejpQRINsnE qmfZjhVKP4Ep5pIM0azbiRZPu0mah9OlFx+RihwLf1OWzGCvRSAacADTamLMML2LaHPm G5FklZH8AMWUJecHEYY+kzlZoZhyNCmYptni3ozTTGYoeL38EJlXrxQ9JoTxf53+mSGc VhengfzZztyWacBxVZP8pbpXF+W+IiXHZtmDQUbzdNaPVVkyftj58T0quSd+0NHUVPqT L7gfBEuoj3anB6JISJYvlX8QYIBBXfZid4HyJWmHPshIXBeFt0aDnY4XtW6bJXr38/bh 8hIg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=UFnUfh6P; arc=pass (i=1 spf=pass spfdomain=redhat.com dkim=pass dkdomain=redhat.com dmarc=pass fromdomain=redhat.com); spf=pass (google.com: domain of linux-kernel+bounces-163660-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-163660-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id q14-20020a056a00084e00b006ee1508edb3si21660662pfk.123.2024.04.30.02.27.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Apr 2024 02:27:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-163660-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=UFnUfh6P; arc=pass (i=1 spf=pass spfdomain=redhat.com dkim=pass dkdomain=redhat.com dmarc=pass fromdomain=redhat.com); spf=pass (google.com: domain of linux-kernel+bounces-163660-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-163660-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com 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 sy.mirrors.kernel.org (Postfix) with ESMTPS id E26E4B238EA for ; Tue, 30 Apr 2024 09:23:22 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BD52F1C230C; Tue, 30 Apr 2024 09:19:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="UFnUfh6P" Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (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 8863C1C2304 for ; Tue, 30 Apr 2024 09:18:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.129.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714468740; cv=none; b=j1/1DKbjn+JPcLcpt/x4ASOHJ40GlCkVBuh2+MyTSj0x7JS/WX4ukjk5rJ2uAO3qJWCfIBY6zQuBqVJt+SV5RmVyTEaBZmiRuGmV5nR4j9ASjgVPkVkPgJYNC743lba3+8SV63hBWjfXM+Aj7mj2ahqWE4+Yg34Q8Nxj9lowJvM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714468740; c=relaxed/simple; bh=DYnXJHD9kJ9V1r0+3XVdouBDhuhgaU3D2u8eA1TSSOI=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=uToBjEYuHeQlLnIrTGvSsfTkCWEI1ooZ/Hk5f9gTwzhQgLx2Q+CZ7p6uPNE2HR6+ksV5sKb6gQ7uWxRoRFJiJP9i+lrNA04voF7mUBUokEUv3MM6zO1po1SbuEUnZ3OO9xMuQoahdxn91ODA4KcUyH76I1+TfidIYlY8E1e3ecg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=UFnUfh6P; arc=none smtp.client-ip=170.10.129.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1714468738; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=7iJ+HhpR5xS1NIdRXohsDpAsZ+ySrJwbYzJ1VO+vaqM=; b=UFnUfh6PHGTeNolyCdDGnku477ldgC2mYG+qXkSpetBJYYRExv5uwCObK5MUf2nYndOlWs /rXXtBzZ31Ub8gdNVhgMa/bmc/4FpMCCZBpR4ewN43EF11UU/eHk4xgFiI6Y33SZ0cPmIP JM37ZlRuIXZrmdiRW0soBlzDqA66T/s= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-557-xATXoSjZMLeETUBX2KF7LA-1; Tue, 30 Apr 2024 05:18:55 -0400 X-MC-Unique: xATXoSjZMLeETUBX2KF7LA-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 346FB1C0AF42; Tue, 30 Apr 2024 09:18:54 +0000 (UTC) Received: from vschneid-thinkpadt14sgen2i.remote.csb (unknown [10.39.193.247]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 69271492BC7; Tue, 30 Apr 2024 09:18:51 +0000 (UTC) From: Valentin Schneider To: rcu@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Frederic Weisbecker , "Paul E. McKenney" , Peter Zijlstra , Neeraj Upadhyay , Joel Fernandes , Josh Triplett , Boqun Feng , Steven Rostedt , Mathieu Desnoyers , Lai Jiangshan , Zqiang Subject: [PATCH v2 17/27] rcu: Rename rcu_dynticks_in_eqs() into rcu_watching_in_eqs() Date: Tue, 30 Apr 2024 11:17:21 +0200 Message-ID: <20240430091740.1826862-18-vschneid@redhat.com> In-Reply-To: <20240430091740.1826862-1-vschneid@redhat.com> References: <20240430091740.1826862-1-vschneid@redhat.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.10 The context_tracking.state RCU_DYNTICKS subvariable has been renamed to RCU_WATCHING, reflect that change in the related helpers. Signed-off-by: Valentin Schneider --- kernel/rcu/tree.c | 8 ++++---- kernel/rcu/tree_exp.h | 2 +- kernel/rcu/tree_stall.h | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c index 857c2565efeac..d772755ccd564 100644 --- a/kernel/rcu/tree.c +++ b/kernel/rcu/tree.c @@ -308,9 +308,9 @@ static int rcu_watching_snap(int cpu) /* * Return true if the snapshot returned from rcu_watching_snap() - * indicates that RCU is in an extended quiescent state. + * indicates that RCU in an extended quiescent state (not watching). */ -static bool rcu_dynticks_in_eqs(int snap) +static bool rcu_watching_in_eqs(int snap) { return !(snap & CT_RCU_WATCHING); } @@ -771,7 +771,7 @@ 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_dynticks_in_eqs(rdp->dynticks_snap)) { + if (rcu_watching_in_eqs(rdp->dynticks_snap)) { trace_rcu_fqs(rcu_state.name, rdp->gp_seq, rdp->cpu, TPS("dti")); rcu_gpnum_ovf(rdp->mynode, rdp); return 1; @@ -4798,7 +4798,7 @@ rcu_boot_init_percpu_data(int cpu) rdp->grpmask = leaf_node_cpu_bit(rdp->mynode, cpu); INIT_WORK(&rdp->strict_work, strict_work_handler); WARN_ON_ONCE(ct->nesting != 1); - WARN_ON_ONCE(rcu_dynticks_in_eqs(rcu_watching_snap(cpu))); + WARN_ON_ONCE(rcu_watching_in_eqs(rcu_watching_snap(cpu))); rdp->barrier_seq_snap = rcu_state.barrier_sequence; rdp->rcu_ofl_gp_seq = rcu_state.gp_seq; rdp->rcu_ofl_gp_state = RCU_GP_CLEANED; diff --git a/kernel/rcu/tree_exp.h b/kernel/rcu/tree_exp.h index 50ec57304c1b7..68dea1427c8bd 100644 --- a/kernel/rcu/tree_exp.h +++ b/kernel/rcu/tree_exp.h @@ -358,7 +358,7 @@ static void __sync_rcu_exp_select_node_cpus(struct rcu_exp_work *rewp) mask_ofl_test |= mask; } else { snap = rcu_watching_snap(cpu); - if (rcu_dynticks_in_eqs(snap)) + if (rcu_watching_in_eqs(snap)) mask_ofl_test |= mask; else rdp->exp_dynticks_snap = snap; diff --git a/kernel/rcu/tree_stall.h b/kernel/rcu/tree_stall.h index 4fa23f9fc207f..589f1be8ff921 100644 --- a/kernel/rcu/tree_stall.h +++ b/kernel/rcu/tree_stall.h @@ -501,7 +501,7 @@ static void print_cpu_stall_info(int cpu) } delta = rcu_seq_ctr(rdp->mynode->gp_seq - rdp->rcu_iw_gp_seq); falsepositive = rcu_is_gp_kthread_starving(NULL) && - rcu_dynticks_in_eqs(rcu_watching_snap(cpu)); + rcu_watching_in_eqs(rcu_watching_snap(cpu)); rcuc_starved = rcu_is_rcuc_kthread_starving(rdp, &j); if (rcuc_starved) // Print signed value, as negative values indicate a probable bug. -- 2.43.0