Bug 1271408 - RFE: qemu: support configuring # of ports for qemu usb3 controller
RFE: qemu: support configuring # of ports for qemu usb3 controller
Status: CLOSED UPSTREAM
Product: Virtualization Tools
Classification: Community
Component: libvirt (Show other bugs)
unspecified
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Libvirt Maintainers
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-10-13 18:15 EDT by Cole Robinson
Modified: 2016-05-04 05:46 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-05-03 09:03:51 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Cole Robinson 2015-10-13 18:15:46 EDT
According to Gerd here:

https://bugzilla.redhat.com/show_bug.cgi?id=1135488#c10

qemu's xhci controller has a configurable number of ports. libvirt should support that, since the default is only 4.
Comment 1 Cole Robinson 2015-10-13 18:23:54 EDT
Gerd, is this all that's required to give the xhci controller ex. 8 ports?

  -device nec-usb-xhci,p2=8,p3=8

Also, any opinions on if we should expose p2 vs p3 or just a single 'ports' knob? I don't know what the usecase for configuring only one or the other is...
Comment 2 Gerd Hoffmann 2015-10-14 01:48:22 EDT
p2 is the number of usb2 ports, p3 is the number of usb4 ports.  Ports do overlap.  So for example p2=8,p2=4 gives you a xhci controller where ports 1-4 can do both usb2 and usb3, whereas ports 5-8 are usb2 only.

That is mostly useful for debugging/testing purposes, for example forcing devices into usb2 mode on xhci to see whenever this works correctly.

I'd suggest to expose this as a single ports= property in libvirt.
Comment 3 Cole Robinson 2016-04-27 14:30:38 EDT
Patches posted upstream: http://www.redhat.com/archives/libvir-list/2016-April/msg01829.html
Comment 4 Cole Robinson 2016-05-03 09:03:51 EDT
Upstream now:

commit 600977e293ee97fc53a7ef17fb89cb310560e7ab
Author: Cole Robinson <crobinso@redhat.com>
Date:   Sat Apr 23 19:52:56 2016 -0400

    qemu: support configuring usb3 controller port count
    
    This adds a ports= attribute to usb controller XML, like
    
      <controller type='usb' model='nec-xhci' ports='8'/>
    
    This maps to:
    
      qemu -device nec-usb-xhci,p2=8,p3=8
    
    Meaning, 8 ports that support both usb2 and usb3 devices. Gerd
    suggested to just expose them as one knob.

Note You need to log in before you can comment on or make changes to this bug.