From a88a3a8607e2aa7bbd5848f5d1f80c8cb0d55715 Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Fri, 10 Feb 2023 12:24:44 -0500 Subject: [PATCH] Document grace period polling in rcu-api.md Signed-off-by: Mathieu Desnoyers Change-Id: I74631072d19cbe1212be6d1ab4f08778d59f67dd --- doc/rcu-api.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/doc/rcu-api.md b/doc/rcu-api.md index e8ec022..4163eef 100644 --- a/doc/rcu-api.md +++ b/doc/rcu-api.md @@ -60,6 +60,26 @@ started: this is not a reader-writer lock. The duration actually waited is called an RCU grace period. +```c +struct urcu_gp_poll_state start_poll_synchronize_rcu(void); +``` + +Start polling on grace period. The returned poll state should be +queried using `poll_state_synchronize_rcu` to check whether the +grace period has completed. + +`start_poll_synchronize_rcu` should be called from registered RCU +read-side threads. For the QSBR flavor, the caller should be online. + + +```c +bool poll_state_synchronize_rcu(struct urcu_gp_poll_state state); +``` + +Poll the grace period state. Return true if quiescence was reached since +the grace period was started, return false otherwise. + + ```c void call_rcu(struct rcu_head *head, void (*func)(struct rcu_head *head)); -- 2.34.1