[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 2/2] x86: fix RCU locking in PHYSDEVOP_get_free_pirq


  • To: Jan Beulich <JBeulich@xxxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxx>
  • From: Keir Fraser <keir.xen@xxxxxxxxx>
  • Date: Wed, 05 Sep 2012 14:53:18 +0100
  • Delivery-date: Wed, 05 Sep 2012 13:53:52 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xen.org>
  • Thread-index: Ac2Lbc2OuHITTc8slEqe9PECGRCCAA==
  • Thread-topic: [Xen-devel] [PATCH 2/2] x86: fix RCU locking in PHYSDEVOP_get_free_pirq

On 05/09/2012 13:45, "Jan Beulich" <JBeulich@xxxxxxxx> wrote:

>>> Apart from properly pairing locks with unlocks, also reduce the lock
>>> scope - no need to do the copy_{from,to}_guest()-s inside the protected
>>> region.
>>> 
>>> I actually wonder whether the RCU locks are needed here at all.
>> 
>> If it's a path that only acts on current domain, then no.
> 
> So for what case does rcu_lock_current_domain() then exist at all?

To match an unconditional rcu_unlock_domain() on exit paths, for operations
which can either be on current->domain or on a rcu_lock_domain_by_id().

 -- Keir



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.