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>,
Uladzislau Rezki <uladzislau.rezki@sony.com>,
Boqun Feng <boqun.feng@gmail.com>,
Neeraj Upadhyay <quic_neeraju@quicinc.com>,
Joel Fernandes <joel@joelfernandes.org>
Subject: [PATCH 1/4] rcu: Remove needless polling work requeue for further waiter
Date: Wed, 16 Mar 2022 15:42:52 +0100 [thread overview]
Message-ID: <20220316144255.336021-2-frederic@kernel.org> (raw)
In-Reply-To: <20220316144255.336021-1-frederic@kernel.org>
If another expedited polling site is waiting for the next grace period,
there is no need to requeue the work because it is guaranteed to be
either already queued or executing the actual polling upon completion.
Signed-off-by: Frederic Weisbecker <frederic@kernel.org>
Cc: Neeraj Upadhyay <quic_neeraju@quicinc.com>
Cc: Boqun Feng <boqun.feng@gmail.com>
Cc: Uladzislau Rezki <uladzislau.rezki@sony.com>
Cc: Joel Fernandes <joel@joelfernandes.org>
---
kernel/rcu/tree_exp.h | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/kernel/rcu/tree_exp.h b/kernel/rcu/tree_exp.h
index a6cb02a4d27c..b6fd857f34ba 100644
--- a/kernel/rcu/tree_exp.h
+++ b/kernel/rcu/tree_exp.h
@@ -919,9 +919,7 @@ static void sync_rcu_do_polled_gp(struct work_struct *wp)
__synchronize_rcu_expedited(true);
raw_spin_lock_irqsave(&rnp->exp_poll_lock, flags);
s = rnp->exp_seq_poll_rq;
- if (!(s & 0x1) && !sync_exp_work_done(s))
- queue_work(rcu_gp_wq, &rnp->exp_poll_wq);
- else
+ if (!(s & 0x1) && sync_exp_work_done(s))
rnp->exp_seq_poll_rq |= 0x1;
raw_spin_unlock_irqrestore(&rnp->exp_poll_lock, flags);
}
--
2.25.1
next prev parent reply other threads:[~2022-03-16 14:43 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-16 14:42 [RFC PATCH 0/4] rcu: Expedited GP polling improvements Frederic Weisbecker
2022-03-16 14:42 ` Frederic Weisbecker [this message]
2022-03-16 14:42 ` [PATCH 2/4] rcu: No need to reset the poll request flag before completion Frederic Weisbecker
2022-03-30 11:27 ` Frederic Weisbecker
2022-03-30 17:57 ` Paul E. McKenney
2022-03-16 14:42 ` [PATCH 3/4] rcu: Perform early sequence fetch for polling locklessly Frederic Weisbecker
2022-03-16 14:42 ` [PATCH 4/4] rcu: Name internal polling flag Frederic Weisbecker
2022-03-17 9:42 ` Neeraj Upadhyay
2022-03-17 15:33 ` Frederic Weisbecker
2022-03-22 2:11 ` Paul E. McKenney
2022-03-22 10:32 ` Frederic Weisbecker
2022-03-24 1:04 ` Paul E. McKenney
2022-03-24 1:19 ` Paul E. McKenney
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220316144255.336021-2-frederic@kernel.org \
--to=frederic@kernel.org \
--cc=boqun.feng@gmail.com \
--cc=joel@joelfernandes.org \
--cc=linux-kernel@vger.kernel.org \
--cc=paulmck@kernel.org \
--cc=quic_neeraju@quicinc.com \
--cc=uladzislau.rezki@sony.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox