>>> On 18.11.15 at 14:08, <malcolm.cross...@citrix.com> wrote: > On 18/11/15 12:07, Ian Campbell wrote: >> (Maybe I should have said "like a bit lock with 32 or 64 bits, setting any >> of which corresponds to acquiring the lock" ;-)) >> > Not quite, setting the per cpu read area "takes" the read lock for the > particular > resource you passed into the percpu rwlock implementation. Writers of another > resource > ($resource1) will safely ignore readers of ($resource0). > > The global barrier will however make _all_ readers take the per-$resource > read lock. > An optimisation could be to have a barrier variable per-$resource (stored in > the > struct grant_table in this case).
As said before, I don't view this as an optimization, but as a requirement (to eliminate the nesting restriction). Jan _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel