On Mon, Jul 28, 2008 at 09:26:57AM -0400, Daniel Veillard wrote: > On Fri, Jul 25, 2008 at 04:17:30PM -0400, Guido Günther wrote: > > Hi, > > attached is some basic support for host device passthrough. It enables > > you to passthrough usb devices in qemu/kvm via: > > > > <devices> > > <hostdev type='usb' vendor='0204' product='6025'/> > > you meant type='pci' there right ? > > > <hostdev type='usb' bus='001' device='007'/> > > </devices> > > Hum, on the format level I think this need a bit more discussion. > the type is better caracterized as a bus informations. > Also I'm not sure if we should keep a flat single element or > (expecting possible further complex descriptions later) go for a > more structured description like Yes, we need deeper XML structure for the source info > <hostdev type='pci'> > <source vendor='0204' product='6025'/> > </hostdev> > > I think an hypervisor could remap the actual port/addresses > of a device so a target may make sense in the future (or not). Yes, for SCSI at least we need target info, and if we can query the mapped target address from the underlying hypervisor we should display it. > > > I didn't implement unplug yet since this needs some modifications to > > qemu/kvm to be able to identify the correct device to unplug. > > Does this look reasonable? > > I also think we need to clarify the naming conventions, are numbers > provided decimal, if yes then is an 0x hexadecimal version allowed too. > I also see how a more high level description might be useful, > > <hostdev type='usb'> > <source vendor='Sennheiser'/> > </hostdev> > > or > > <hostdev type='usb'> > <source product='headset'/> > </hostdev> We should stick to ID numbers in the domain XML - allowing decimal or hex is nice. For descriptive names 'Sennheiser' or 'headset', we should only provide that info in the device enumeration APIs http://www.redhat.com/archives/libvir-list/2008-April/msg00005.html Management tools / admins can use this to map to the ID number from a human readable name if relevant. Daniel -- |: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :| |: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :| -- Libvir-list mailing list Libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list