From: Daniel Stodden Subject: Re: Tapdisk2 problem Date: Sun, 15 Aug 2010 12:35:38 -0700 Message-ID: <1281900938.2427.56.camel@ramone.somacoma.net> References: <1280930679.3277.11.camel@luis-port> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <1280930679.3277.11.camel@luis-port> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: "luis.silva@axiomasoft.pt" , Keir Fraser Cc: "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org On Wed, 2010-08-04 at 10:04 -0400, Lu=C3=ADs Silva wrote: > Hello, >=20 > I'm using both xen 4.0.1-rc5 and the latest pv_ops dom0 kernel (branch > xen/stable-2.6.32.x), but I'm having some problems with tapdisk2... >=20 > Basically, if I create a tap device (tapdisk2 -n > aio:/var/lib/libvirt/images/srv-001-ub1004.img), when I try to > terminate it by issuing "echo 1 > /sys/class/blktap2/blktap0/remove", > the last command hangs and tapdisk2 hangs using 100% cpu. >=20 > This happens both on manual device destruction and on virtual machine > shutdown. I don't know exactly what triggered this behaviour, but I > suspect kernel changes. >=20 > Can anyone confirm this behaviour? Yes, with a broken userland. I thought Ian's dot-private patches to ring.h made it into testing? changeset: 21707:feee0abed6aa user: Keir Fraser date: Fri Jul 02 18:58:02 2010 +0100 summary: blktap2: make protocol specific usage of shared sring explic= it The problem is that the kernel has those changes. What's going to happen is that if tapdisk2 anticipates the ring 'message' at offset 17, not 16 as intended, it will fail to find/clear the ring message, while the kernel will keep it spinning through select(), and that's what you're seeing. Keir, okay to just pull that stuff? Daniel