From: Ian Campbell Subject: Re: [PATCH v5 1/2] libxl: Introduce functions to add and remove USB devices to an HVM guest Date: Fri, 19 Apr 2013 11:50:46 +0100 Message-ID: <1366368646.19111.93.camel@zakaz.uk.xensource.com> References: <1366296408-5660-1-git-send-email-george.dunlap@eu.citrix.com> <20848.12940.847860.437708@mariner.uk.xensource.com> <51711A0C.7030408@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <51711A0C.7030408@eu.citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: George Dunlap Cc: "sstanisi@cbnco.com" , "xen-devel@lists.xen.org" , Ian Jackson , Roger Pau Monne List-Id: xen-devel@lists.xenproject.org On Fri, 2013-04-19 at 11:18 +0100, George Dunlap wrote: > > > We could add an option that says "attempt to do the remove even if > you > don't see the device in xenstore" I suppose. But I'm not really sure > how to document that in a useful way without basically describing the > internal mechanics of the command. > > There's nothing we can really do about usb-list though. You could write it to xenstore before attempting the qmp commands. That just relies on the qmp remove failing gracefully for devices which aren't actually attached. You might also be able to come up with some complicated, prepare, do it, commit in xenstore like approach -- but that's probably a) difficult (if not impossibly due to races) and b) unnecessary. Ian.