From mboxrd@z Thu Jan 1 00:00:00 1970 From: George Dunlap Subject: Re: [PATCH v6 2/2] xl: Add commands for usb hot-plug Date: Thu, 25 Apr 2013 13:04:28 +0100 Message-ID: <51791BCC.2030708@eu.citrix.com> References: <1366387166-21197-1-git-send-email-george.dunlap@eu.citrix.com> <1366387166-21197-2-git-send-email-george.dunlap@eu.citrix.com> <1366807503.20256.333.camel@zakaz.uk.xensource.com> <51790282.8090903@eu.citrix.com> <1366889888.20256.514.camel@zakaz.uk.xensource.com> <51791A3E.1080801@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <51791A3E.1080801@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: Ian Campbell Cc: "sstanisi@cbnco.com" , Roger Pau Monne , Ian Jackson , "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org On 04/25/2013 12:57 PM, George Dunlap wrote: > On 04/25/2013 12:38 PM, Ian Campbell wrote: >> On Thu, 2013-04-25 at 11:16 +0100, George Dunlap wrote: >>>>> + for (i = 0; i < num; i++) { >>>>> + printf("%8s ", (dev[i].protocol==LIBXL_USB_PROTOCOL_PV)?"pv":"dm"); >>>> >>>> You can use libxl_usb_protocol_to_string here. >>> >>> Could do, but I didn't necessarily want the long version ("devicemodel"). >> >> TBH the more I think about it the more I think DM/DEVICEMODEL in this >> interface is leaking an implementation detail, after all the user >> doesn't really care who/what is emulating a USB controller. >> >> Protocol = {PV,OHCI,XHCI}? > > As we covered before: > > 1. I have no way of selecting OHCI vs XHCI at this point > > 2. Even if I did, why should the caller have to keep track of what kind > of USB hardware is exposed to the guest? They should be able to just > say "Add" and have stuff sorted out. > > In addition: > > 3. The point of saying DEVICEMODEL is that it's not PV. An HVM guest > may be able to do either, and should be allowed to choose. If your problem is with the name, we could call it EMULATED instead. -George