Bug 770512
Summary: | Virtio serial chardev will be still in use even failed to hot plug a serial port on it | |||
---|---|---|---|---|
Product: | Red Hat Enterprise Linux 6 | Reporter: | Qunfang Zhang <qzhang> | |
Component: | qemu-kvm | Assignee: | Amit Shah <amit.shah> | |
Status: | CLOSED ERRATA | QA Contact: | Virtualization Bugs <virt-bugs> | |
Severity: | medium | Docs Contact: | ||
Priority: | medium | |||
Version: | 6.3 | CC: | acathrow, amit.shah, bsarathy, juzhang, michen, mkenneth, tburke, virt-maint, wdai | |
Target Milestone: | rc | |||
Target Release: | --- | |||
Hardware: | Unspecified | |||
OS: | Unspecified | |||
Whiteboard: | ||||
Fixed In Version: | qemu-kvm-0.12.1.2-2.226.el6 | Doc Type: | Bug Fix | |
Doc Text: |
No documentation necessary
|
Story Points: | --- | |
Clone Of: | ||||
: | 923599 (view as bug list) | Environment: | ||
Last Closed: | 2012-06-20 11:38:17 UTC | Type: | --- | |
Regression: | --- | Mount Type: | --- | |
Documentation: | --- | CRM: | ||
Verified Versions: | Category: | --- | ||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | ||
Cloudforms Team: | --- | Target Upstream Version: | ||
Embargoed: | ||||
Bug Depends On: | ||||
Bug Blocks: | 676568, 923599, 969799, 973038 |
Description
Qunfang Zhang
2011-12-27 07:31:30 UTC
After step 4 in the bug description, qemu monitor shows: (qemu) device_add virtserialport,bus=virtio-serial0.0,nr=2,chardev=channel1,name=org.linux-kvm.port.1,id=port1 Property 'virtserialport.chardev' can't take value 'channel1', it's in use This is going to need the chardev hot-plug/unplug patches (Bug 676568). Instead of closing as a dup, I'll let this bug remain open so that we test this scenario when that bug is closed. This is a bug in the chardev - qdev connection code. A typical use case for dynamic chardev - qdev connection is full hot plug/unplug of chardevs (bug 676568). But other use cases exist. For instance, you can unplug the qdev and reuse the same chardev for another qdev. But currently a qdev initialization can fail in a way that leaves the chardev unusable for another qdev. That's this bug. It needs fixing regardless of chardev hot plug/unplug. Thus, I'm reverting the dependency between this one and bug 676568: this one blocks bug 676568. While testing, please also test the case in Bug 700512. It should continue to remain fixed. The fix in bug 700512 will be reverted for a generic fix, which will fix both these bugs. Reproduced this issue with steps and environment as follows: # uname -r ;rpm -q qemu-kvm 2.6.32-220.el6.x86_64 qemu-kvm-0.12.1.2-2.209.el6_2.1.x86_64 1. Boot a guest with virtio serial bus and chardev but no serial port 2. Hot plug a virtio serial port on the first chardev "channel0" 3. Hot plug another serial port on the second chardev "channel1" but with a wrong "nr" value to let it failed to plug. (qemu) device_add virtserialport,bus=virtio-serial0.0,nr=1,chardev=channel1,name=org.linux-kvm.port.1,id=port1 virtio-serial-bus: A port already exists at id 1 Device 'virtserialport' could not be initialized 4. Hot plug the serial port again with correct "nr" value. after step 4,qemu monitor shows: (qemu) device_add virtserialport,bus=virtio-serial0.0,nr=2,chardev=channel1,name=org.linux-kvm.port.1,id=port1 Property 'virtserialport.chardev' can't take value 'channel1', it's in use (qemu)info qtree shows there's only 1 virtio serial port "port0" and chardev "channel0" Verified this issue with steps and environment as follows: # uname -r ;rpm -q qemu-kvm 2.6.32-220.el6.x86_64 qemu-kvm-0.12.1.2-2.226.el6.x86_64 redo above step1 ~ step4. after step4, qemu monitor does not report an error. (qemu) info qtree .... bus: virtio-serial0.0 type virtio-serial-bus dev: virtserialport, id "port1" dev-prop: chardev = channel1 bus-prop: nr = 2 bus-prop: name = "org.linux-kvm.port.1" dev-prop-int: id: 2 dev-prop-int: guest_connected: 0 dev-prop-int: host_connected: 0 dev-prop-int: throttled: 0 dev: virtserialport, id "port0" dev-prop: chardev = channel0 bus-prop: nr = 1 bus-prop: name = "org.linux-kvm.port.0" dev-prop-int: id: 1 dev-prop-int: guest_connected: 0 dev-prop-int: host_connected: 0 dev-prop-int: throttled: 0 .... (qemu) info tree shows both <port0,channel0> and <port1,channel1>. So,this bug had been fixed. Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: No documentation necessary Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHBA-2012-0746.html |