Commit-ID: 5413e24c943da33306047fc091fa34fa4f261b3b Gitweb: http://git.kernel.org/tip/5413e24c943da33306047fc091fa34fa4f261b3b Author: Paul E. McKenney <paulmck@xxxxxxxxxxxxxxxxxx> AuthorDate: Tue, 15 Mar 2016 13:40:28 -0700 Committer: Paul E. McKenney <paulmck@xxxxxxxxxxxxxxxxxx> CommitDate: Thu, 31 Mar 2016 13:33:23 -0700 documentation: Sharpen up the no-readers quick quiz Signed-off-by: Paul E. McKenney <paulmck@xxxxxxxxxxxxxxxxxx> --- Documentation/RCU/Design/Requirements/Requirements.html | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/Documentation/RCU/Design/Requirements/Requirements.html b/Documentation/RCU/Design/Requirements/Requirements.html index acdad96..85cf223 100644 --- a/Documentation/RCU/Design/Requirements/Requirements.html +++ b/Documentation/RCU/Design/Requirements/Requirements.html @@ -1002,18 +1002,21 @@ obligation to wait for these new readers. <tr><th> </th></tr> <tr><th align="left">Quick Quiz:</th></tr> <tr><td> - Suppose that synchronize_rcu() did wait until all readers had completed. - Would the updater be able to rely on this? + Suppose that synchronize_rcu() did wait until <i>all</i> + readers had completed instead of waiting only on + pre-existing readers. + For how long would the updater be able to rely on there + being no readers? </td></tr> <tr><th align="left">Answer:</th></tr> <tr><td bgcolor="#ffffff"><font color="ffffff"> - No. + For no time at all. Even if <tt>synchronize_rcu()</tt> were to wait until all readers had completed, a new reader might start immediately after <tt>synchronize_rcu()</tt> completed. Therefore, the code following - <tt>synchronize_rcu()</tt> cannot rely on there being no readers - in any case. + <tt>synchronize_rcu()</tt> can <i>never</i> rely on there being + no readers. </font></td></tr> <tr><td> </td></tr> </table> -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html
![]() |