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 798838 - Some problems of USB hostplug/passthrough with product and vendor.
Summary: Some problems of USB hostplug/passthrough with product and vendor.
Keywords:
Status: CLOSED DUPLICATE of bug 808459
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt
Version: 6.3
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: rc
: ---
Assignee: Laine Stump
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-03-01 03:31 UTC by yuping zhang
Modified: 2012-04-30 15:03 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-04-30 14:44:17 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description yuping zhang 2012-03-01 03:31:31 UTC
Description of problem:
Hostplug USB to a guest,then shutdown guest -> start guest,fail to hostplug USB to guest.
Shutdown guest,passthrough USB to guest,then start guest -> shutdown guest,after that,fail to start guest again.

Version-Release number of selected component (if applicable):
libvirt-0.9.10-3.el6.x86_64
virt-manager-0.9.0-10.el6.x86_64

How reproducible:
always

Steps to Reproduce:

# virsh nodedev-dumpxml usb_2_1
<device>
  <name>usb_2_1</name>
  <parent>usb_usb2</parent>
  <driver>
    <name>usb</name>
  </driver>
  <capability type='usb_device'>
    <bus>2</bus>
    <device>8</device>
    <product id='0x1625'>DT 101 II</product>
    <vendor id='0x0951'>Kingston</vendor>
  </capability>
</device>

Hotplug:
1.Start a guest.
2.Prepare a USB xml with product + vendor.
#cat hostdev-usb-product.xml 
<hostdev mode='subsystem' type='usb' managed='yes'>
      <source>
              <product id='0x1625'/>
              <vendor id='0x0951'/>
       </source>
</hostdev>

3.#virsh attach-device rhel6.2-new hostdev-usb-product.xml
Device attached successfully
4.Shutdown guest,then start it.

5.Attach the USB device to gust again
# virsh attach-device rhel6.2-new hostdev-usb-product.xml 
error: Failed to attach device from hostdev-usb-product.xml
error: Requested operation is not valid: USB device 002:010 is in use by domain ;�m

Passthrough:
1.Shutdown a guest.
2.Add the USB xml(product+vendor) to guest.
#virsh edit rhel6.2-new
...
<hostdev mode='subsystem' type='usb' managed='yes'>
      <source>
              <product id='0x1625'/>
              <vendor id='0x0951'/>
       </source>
</hostdev>
...
3.Start the guest.Wait for the guest boot successfully,then shutdown it.
4.Start the guest again.
# virsh start rhel6.2-new
error: Failed to start domain rhel6.2-new
error: Requested operation is not valid: USB device 002:010 is in use by domain 

Actual results:
As above

Expected results:
1.The usb can be hotplugged and the guest can be started successfully.
2.Restart libvirtd,the usb can works well.

Additional info:
The USB works well when hotplug/passthrough with bus and device.

Comment 2 dyuan 2012-04-28 07:10:26 UTC
It should be regression caused by patch of bug 743671.

Comment 5 Michal Privoznik 2012-04-30 08:00:05 UTC
dyuan,

You're right. The first round of patch that tried to fix bug 743671 turned out to be incomplete. Therefore I've posted the second round. However, the have missed upstream freeze phase, so they will be picked up by next release (0.9.12);

So I think we can close this one as a dup of bug 743671.
Laine?

Comment 6 Laine Stump 2012-04-30 14:42:45 UTC
Yes, this bug is fixed by the patches listed in https://bugzilla.redhat.com/show_bug.cgi?id=743671#c9 . They had been delayed because the full impact of *not* having them wasn't realized. So, completely fixing that bug will cause this bug to go away.


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