From: Stefano Stabellini Subject: Re: xen dom0 2.6.32.15 kernel BUG at drivers/xen/grant-table.c:583 Date: Mon, 14 Jun 2010 11:57:16 +0100 Message-ID: References: <4C15E000.7060509@nets.rwth-aachen.de> Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Return-path: In-Reply-To: <4C15E000.7060509@nets.rwth-aachen.de> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Arnd Hannemann Cc: "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org On Mon, 14 Jun 2010, Arnd Hannemann wrote: > Hi, > > we have regular but hard to reproduce (wait for a day or two starting domUs) kernel panics (see below) with latest > "xen/stable-2.6.32.x" git tree. > > Any idea, anyone? > this CS from origin/xen/dom0/gntdev should fix your problem: sstabellini@kaball-desktop:~/xensource/linux-pvops-latest$ git show ad469f0da31bc16b945f9a06710b9d45434d0091 commit ad469f0da31bc16b945f9a06710b9d45434d0091 Author: Stefano Stabellini Date: Wed Jun 9 12:34:02 2010 -0700 xen/gntdev: use spinlocks rather than rwsem for locking The mmu notifier mechanism calls its callbacks with an rcu lock, which disables preemption. This means we cannot use any blocking synchronization for locking. Convert all the rwsemas to plain spinlocks. This requires that the memory allocation and copying to/from userspace be split from the actual datastructure updates since they can't be done under spinlock. Signed-off-by: Stefano Stabellini Signed-off-by: Jeremy Fitzhardinge