Message ID | 20230531101736.12981-9-frederic@kernel.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp2771300vqr; Wed, 31 May 2023 03:24:47 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ42zDIMEMpi9EAWfQLNNgDN2GHIOA/Zs+QxPx6iSardrqxLZIxbR5bqrRBTFe2E0pma3zdc X-Received: by 2002:a05:6a00:2d26:b0:63b:54e4:871b with SMTP id fa38-20020a056a002d2600b0063b54e4871bmr5334044pfb.8.1685528686887; Wed, 31 May 2023 03:24:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685528686; cv=none; d=google.com; s=arc-20160816; b=j4/iBJrz6r0n8VUqYBD9NGe1d1EgQivmbjgn3RgUgbacsxm2ZvV77Yz5vM+Da+HBnu nn43nUlIAUxR0WFdKdnSX2ggeQ5MDT0Zwk12XgVswyrdDxyAUwT1hngpAzZfs7o78+Tf LS0iLFSvkYefhf3VV4djUYig7OFE05lQM3nNAiyFByL5SNZfMfQt2grzJMSEqTBr6Lo8 JpgXD4vw1yT31uVhKRP+7yFS0V7pf2YlB+Gx6vFVLCkZnU0jY7opR3iTzWsiseANhNMu uy2PV4pE5BDGTMBizKQsKBmZ5uaIYgxCtGqvuhRmIgWl5HNESLNjtjCBIbQbF/nZOUpP 5wkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=kOp5RpBJeX6/wMophl10RHO1bC2n5fO5rwlmazoCbsU=; b=DQKZuNPKpCP8dPojVKRWI2l76fJRxlCbNsJGxFmpQGj9a+zIZC74ZSIevMZ38GjDDN H+CrUjeGGDQvrXc5BDV6Su6TpnZdtvt6IglQHXsetENycFF3pLNPYVsIDRqsydHbYrtQ /OPVDUun2/0K6NlSzLhb1vlPzOdbDcfd0EkJk7lBbTGzKTWHjjgWp/Mr2Z7mNsgeehIy b3tsaXqpE+IvyTIUvxd8/WFttLbq/Ed/Hn5otaK0Vc8xRTK9n8+mc2eFBkb+TkMQ4FYl Wv8IfLjGG20oLyCchXaEm5x05mO7MDby/+OGhsRO3R0JT/kvBVIDAvQB+RT2okPybDE9 ZoNw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ePLMv+jM; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a7-20020aa794a7000000b0064d5aab3ec5si3318628pfl.156.2023.05.31.03.24.35; Wed, 31 May 2023 03:24:46 -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=@kernel.org header.s=k20201202 header.b=ePLMv+jM; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235886AbjEaKS7 (ORCPT <rfc822;andrewvogler123@gmail.com> + 99 others); Wed, 31 May 2023 06:18:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36734 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235910AbjEaKSV (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 31 May 2023 06:18:21 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5D5E0E58; Wed, 31 May 2023 03:18:10 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id BC8616395F; Wed, 31 May 2023 10:18:09 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 02BADC433EF; Wed, 31 May 2023 10:18:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1685528289; bh=fAqo46X9Mw2V2BkQzIfih4SUfDwqn3L8IoBC3xT459U=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ePLMv+jMZFPi3Hit+6vSJE2+ji1QEtu/1Aed674mJKNLlzome+1Jg43GPLnjJ2muu gSce7Q0YAsBablSP4vC2TV5+BD03NtbB8u5xHW++Ld80Q0yhYOnIw0zUqRIShaJkf9 d7e5vOF4kABaMNpamGZ8EPOqUJkWg2Fvb2TLHizOgLe7IMQEiBK27isqZDXZF2vjky 07zI8sNXooZAfWZb6TfrV4UVhOHGdcexmRnZPXv5530QkkzQFUcM939ZzZ+O8HV55g zRQttLupK1gTS2yKpzILZClL120vGPG+9wzLK4/rWUTpE7SGCIXwEzIqjj/3N/NlEv A5UthPlU6UryQ== From: Frederic Weisbecker <frederic@kernel.org> To: "Paul E . McKenney" <paulmck@kernel.org> Cc: LKML <linux-kernel@vger.kernel.org>, Frederic Weisbecker <frederic@kernel.org>, rcu <rcu@vger.kernel.org>, Uladzislau Rezki <urezki@gmail.com>, Neeraj Upadhyay <quic_neeraju@quicinc.com>, Joel Fernandes <joel@joelfernandes.org>, Giovanni Gherdovich <ggherdovich@suse.cz> Subject: [PATCH 8/9] rcu: Make segcblist flags test strict Date: Wed, 31 May 2023 12:17:35 +0200 Message-Id: <20230531101736.12981-9-frederic@kernel.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230531101736.12981-1-frederic@kernel.org> References: <20230531101736.12981-1-frederic@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1767404928380143904?= X-GMAIL-MSGID: =?utf-8?q?1767404928380143904?= |
Series |
rcu: Support for lazy callbacks on !CONFIG_RCU_NOCB_CPU
|
|
Commit Message
Frederic Weisbecker
May 31, 2023, 10:17 a.m. UTC
While testing several flags at once, make sure that all of them verify
the test. This will be necessary to check if an rdp is (de-)offloading.
Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
---
kernel/rcu/rcu_segcblist.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/rcu/rcu_segcblist.h b/kernel/rcu/rcu_segcblist.h index 620ca48e782b..36245efdf800 100644 --- a/kernel/rcu/rcu_segcblist.h +++ b/kernel/rcu/rcu_segcblist.h @@ -70,7 +70,7 @@ static inline void rcu_segcblist_clear_flags(struct rcu_segcblist *rsclp, static inline bool rcu_segcblist_test_flags(struct rcu_segcblist *rsclp, int flags) { - return READ_ONCE(rsclp->flags) & flags; + return (READ_ONCE(rsclp->flags) & flags) == flags; } /*