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] USB virtualization question

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-devel] USB virtualization question
From: Mark Williamson <mark.williamson@xxxxxxxxxxxx>
Date: Fri, 6 May 2005 14:18:33 +0100
Cc: Xin Zhao <zhaoxin@xxxxxxxxxxxxxx>
Delivery-date: Fri, 06 May 2005 13:56:30 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <Pine.LNX.4.58.0505060231140.28693@xxxxxxxxxxxxxxxxxxxxx>
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/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <Pine.LNX.4.58.0505060231140.28693@xxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.8
> Is it possible to differentiate multiple USB ports and assign one port to
> be used only by a specified virtual machine when doing usb virtualization?
>
> As USB devices are enumerated, I don't see a way to do that.

Domain 0 retains control of the USB host controller.
1. When you plug in a USB device, dom0 will do generic USB configuration 
operations like assigning it an address.
2. Then it'll probe its device drivers to see if any of them are interested - 
at this port, the USB backend driver will recognise that the device is 
plugged into a port it's interested in.
3. The USB backend driver informs the frontend that there's a device on the 
port.
4. The frontend domain does the generic config tasks like assigning an 
address.  The backend "fakes out" the SET_ADDRESS operation, otherwise dom0 
won't know what address the device has ;-)

For data path operations, USB requests are queued into the device channel by 
the frontend.  The backend is responsible for checking that the requests are 
safe (i.e. address only the correct domain's memory) and then proxying them 
to the device itself.

The advantages of this design are:
1. flexible - give any attached device to a domain, from any individual port
2. safe - don't have to trust a domain not to access forbidden memory 
(although you do trust the device itself isn't malicious or exploitable)
3. dom0 doesn't have to have a driver for the device itself, as long as the 
target domain can drive it.

HTH,
Mark

> Any insignts on this issue?
>
> Thanks in advance!
>
> -x
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/xen-devel

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

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