lkml.org 
[lkml]   [2023]   [Jan]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Internal vs. external barriers (was: Re: Interesting LKMM litmus test)
On Fri, Jan 20, 2023 at 11:13:00AM +0100, Jonas Oberhauser wrote:
> Perhaps we could say that reading an index without using it later is
> forbidden?
>
> flag ~empty [Srcu-lock];data;rf;[~ domain(data;[Srcu-unlock])] as
> thrown-srcu-cookie-on-floor

We already flag locks that don't have a matching unlock. I don't see
any point in worrying about whatever else happens to the index.

> So if there is an srcu_down() that produces a cookie that is read by some
> read R, and R doesn't then pass that value into an srcu_up(), the
> srcu-warranty is voided.

No, it isn't. As long as the value is passed to exactly one
srcu_up_read(), it doesn't much matter what else you do with it.

Alan

\
 
 \ /
  Last update: 2023-03-26 23:49    [W:0.173 / U:0.152 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site