From: Keir Fraser Subject: Re: [PATCH] remove redundant rcu_read_unlock Date: Wed, 28 Mar 2007 20:22:37 +0100 Message-ID: References: <20070328190626.GA7940@silverwood.ncultra.org> Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20070328190626.GA7940@silverwood.ncultra.org> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: ncmike@us.ibm.com, xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On 28/3/07 20:06, "Mike D. Day" wrote: > In the function rcu_lock_domain_by_id there is a call to > rcu_read_unlock just prior to returning. However, the intent is that > the rcu reader retain the read lock after the call has returned. This > can be verified by auditing the callers of this routine, which each > explicitly call rcu_unlock_domain, which in turn calls > rcu_read_unlock. > > -- > Remove redundant call to rcu_read_unlock. It's not redundant -- that's the error path (returning NULL). Callers do not call the unlock function in this case. -- Keir