Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1531480

Summary: ccid controller can not be attached to usb hub
Product: Red Hat Enterprise Linux 7 Reporter: yalzhang <yalzhang>
Component: libvirtAssignee: Libvirt Maintainers <libvirt-maint>
Status: CLOSED DUPLICATE QA Contact: Jing Qi <jinqi>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.5CC: jinqi, jiyan, jtomko, rbalakri, xuzhang
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-01-05 10:10:21 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description yalzhang@redhat.com 2018-01-05 09:47:01 UTC
Description of problem:
ccid controller can not be attached to usb hub

Version-Release number of selected component (if applicable):
libvirt-3.9.0-7.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1.  prepare guest xml with 1 usb3 controller, and 3 devices connected to the controller. 
 # virsh dumpxml pc
<controller type='usb' index='0' model='nec-xhci'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
    </controller>
...
<input type='tablet' bus='usb'>
      <address type='usb' bus='0' port='1'/>
    </input>
 <redirdev bus='usb' type='spicevmc'>
      <address type='usb' bus='0' port='2'/>
    </redirdev>
    <redirdev bus='usb' type='spicevmc'>
      <address type='usb' bus='0' port='3'/>
    </redirdev>


2.  edit the xml to add 1 ccid controller and 1 usb disk
# virsh edit pc
...
   <disk type='file' device='disk'>
      <driver name='qemu' type='raw'/>
      <source file='/var/lib/libvirt/images/pc-2.qcow2'/>
      <target dev='sdx' bus='usb'/>
    </disk>
<controller type='ccid'/>
...
As usb3 only support 4 ports, a hub will be added, and the usb disk and ccid controller will attached to the hub
# virsh dumpxml pc 
...
  <disk type='file' device='disk'>
      <driver name='qemu' type='raw'/>
      <source file='/var/lib/libvirt/images/pc-2.qcow2'/>
      <target dev='sdx' bus='usb'/>
      <address type='usb' bus='0' port='4.1'/>
    </disk>
    <controller type='ccid' index='0'>
      <address type='usb' bus='0' port='4.2'/>
    </controller>
...
  <hub type='usb'>
      <address type='usb' bus='0' port='4'/>
    </hub>

3. guest can not start 
# virsh start pc
error: Failed to start domain pc
error: internal error: process exited while connecting to monitor: 2018-01-05T08:10:12.703102Z qemu-kvm: -device usb-ccid,id=ccid0,bus=usb.0,port=4.2: usb port 4.2 (bus usb.0) not found (in use?)


Actual results:
ccid controller can not be attached to usb hub
 
Expected results:
guest can start successfully, or there is error message about ccid controller can not attached to usb hub

Additional info:
If there is 2 usb disk with  adress like <address type='usb' bus='0' port='4.1'/>, <address type='usb' bus='0' port='4.2'/>, the guest can start successfully.

Comment 2 Ján Tomko 2018-01-05 10:10:21 UTC

*** This bug has been marked as a duplicate of bug 1375402 ***