From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Egger, Christoph" Subject: Re: [PATCH 1/2] gnttab: Introduce rwlock to protect updates to grant table state Date: Tue, 2 Dec 2014 14:03:15 +0100 Message-ID: <547DB893.9020605@amazon.de> References: <1417514784-15749-1-git-send-email-chegger@amazon.de> <1417514784-15749-2-git-send-email-chegger@amazon.de> <547DB21A.3090009@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <547DB21A.3090009@linaro.org> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Julien Grall , xen-devel@lists.xen.org Cc: Keir Fraser , Matt Wilson , Jan Beulich List-Id: xen-devel@lists.xenproject.org On 2014/12/02 13:35, Julien Grall wrote: > Hi Christoph, > > On 02/12/14 10:06, Christoph Egger wrote: >> diff --git a/xen/arch/x86/mm.c b/xen/arch/x86/mm.c >> index 522c43d..37c13b1 100644 >> --- a/xen/arch/x86/mm.c >> +++ b/xen/arch/x86/mm.c >> @@ -4565,7 +4565,7 @@ int xenmem_add_to_physmap_one( >> mfn = virt_to_mfn(d->shared_info); >> break; >> case XENMAPSPACE_grant_table: >> - spin_lock(&d->grant_table->lock); >> + write_lock(&d->grant_table->lock); >> >> if ( d->grant_table->gt_version == 0 ) >> d->grant_table->gt_version = 1; >> @@ -4587,7 +4587,7 @@ int xenmem_add_to_physmap_one( >> mfn = virt_to_mfn(d->grant_table->shared_raw[idx]); >> } >> >> - spin_unlock(&d->grant_table->lock); >> + write_unlock(&d->grant_table->lock); >> break; >> case XENMAPSPACE_gmfn_range: >> case XENMAPSPACE_gmfn: > > You forgot to modify the ARM bits which is using the spinlock. See > arch/arm/mm.c I can do the change. But I don't have ARM hardware nor the build infrastructure. I need your help with compiling and testing on/for ARM. Alternatively you can send me a patch I can add to or squash into my patch series. Christoph