WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH] Test tap devices in testDeviceComplete()

To: Christoph Egger <Christoph.Egger@xxxxxxx>
Subject: Re: [Xen-devel] [PATCH] Test tap devices in testDeviceComplete()
From: Jiri Denemark <jdenemar@xxxxxxxxxx>
Date: Tue, 10 Mar 2009 10:57:38 +0100
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Tue, 10 Mar 2009 02:58:43 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <200903101031.47873.Christoph.Egger@xxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20090310091923.GA6865@xxxxxxxxxx> <200903101031.47873.Christoph.Egger@xxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.18 (2008-05-17)
> > XendDomainInfo.testDeviceComplete() should check block devices have
> > shutdown correctly but it only considers vbd class devices and ignores tap
> > devices. The attached patch changes testDeviceComplete() to wait for both
> > vbd and tap devices to be shutdown correctly.
> 
> Has this also been tested with PV guests ?  In that case, there are no tap 
> devices to shutdown.

Hmm, testDeviceComplete() is called after _releaseDevices(), which destroys
all devices. And even for a PV guest, I can see tap devices in
/vm/UUID/device/tap tree in xenstore.

vm = ""
 0829a755-d2ed-607e-5847-ce9ec19e7422 = ""
  image = "(linux (kernel ) (videoram 4) (notes..."
   ostype = "linux"
   kernel = "/var/run/xend/boot/boot_kernel.QsXCO7"
   cmdline = "ro root=LABEL=/ selinux=0"
   ramdisk = "/var/run/xend/boot/boot_ramdisk.UzyMl2"
  device = ""
   tap = ""
    51712 = ""
     frontend = "/local/domain/2/device/vbd/51712"
     frontend-id = "2"
     backend-id = "0"
     backend = "/local/domain/0/backend/tap/2/51712"

That is, that device will be destroyed by _releaseDevices although not tested
by testDeviceComplete to be completed.

Anyway, this is a bit hard to test, as this code patch is only used when
guest's kernel lacks SUSPEND_CANCEL feature, which is present in current Xen
kernels. While, I have a kernel without this feature, it also lacks some other
parts and the guest crashes...

On the other hand, I tested this on older Xen tools which match the kernel.
This code path hasn't really changed since than.

Jirka

-- 
Immorality: the morality of those who are having a better time.
                -- H. L. Mencken

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>