[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH RFC V2 4/5] xl: add pvusb commands
On Mon, Jan 19, 2015 at 8:28 AM, Chunyan Liu <cyliu@xxxxxxxx> wrote: > Add pvusb commands. > > To attach a usb device to guest through pvusb, one could follow > following example: > > #xl usb-ctrl-attach test_vm version=1 num_ports=8 This doesn't allow you to specify controller name or devid. I was looking at the other device-attach code, and they all seem to have a "devicespec"-style specification. Would it make sense to do something similar? For example: xl usb-ctrl-attach test_vm name=pv-1,type=pv,version=1,ports=8 Then we could re-use this for the config file as well. > #xl usb-list test_vm > will show the usb controllers and port usage under the domain. > > #xl usb-assignable-list > will list all assignable usb devices now in host, with their > sysfs interface. (This is very useful since later we will use > sysfs interface to attach a usb devie to guest) > > #xl usb-attach test_vm 2-1.1 > will find the first usable controller:port, and attach usb > device with sysfs interface 2-1.1 (sys/bus/usb/devices/2-1.1) > to it. One could also specify which <controller> and which <port> > > #xl usb-detach test_vm 2-1.1 Long-term we want to be able to attach and detach more kinds of devices than just host devices; for example for HVM guests we want to be able to attach mice, keyboards, tablets, &c. What if we continued with the "devicespec" idea above, it might make more sense to say something like xl usb-attach test_vm type=hostdev,hostbus=X,hostaddr=Y,ctrl=pv-1 (Assuming you had a controller named pv-1, for example.) And then maybe in the future we could have something like xl usb-attach test_vm type=tablet Thoughts? -George _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |