Bug 702264

Summary: Virtio-serial-port does not work after hot-unplug another virtio-serial-port
Product: Red Hat Enterprise Linux 6 Reporter: Mike Cao <bcao>
Component: qemu-kvmAssignee: Virtualization Maintenance <virt-maint>
Status: CLOSED DUPLICATE QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1CC: amit.shah, juzhang, michen, mkenneth, virt-maint
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-05-05 08:40:38 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:

Description Mike Cao 2011-05-05 08:18:23 UTC
Description of problem:


Version-Release number of selected component (if applicable):
[root@localhost Desktop]# uname -r
2.6.32-131.0.10.el6.x86_64
# rpm -q qemu-kvm
qemu-kvm-0.12.1.2-2.160.el6.x86_64

How reproducible:
100%

Steps to Reproduce:
1. start VM with -chardev
eg: <CLI> -monitor stdio \
-chardev socket,id=s11,path=/tmp/tt11,server,nowait \
-chardev socket,id=s12,path=/tmp/tt12,server,nowait \
-chardev socket,id=s13,path=/tmp/tt13,server,nowait \

2.Hot add virtio-serial-bus
(qemu) device_add virtio-serial-pci,id=virtio-serial0,max_ports=16,bus=pci.0,addr=0x8

3.hot add 1st virtioserialport
(qemu)device_add virtserialport,chardev=s11,name=org.linux-kvm.port.11,bus=virtio-serial0.0,id=port11

4.in the guest send data to /dev/vport0p1 
in the guest #echo c > /dev/virtio-ports/org.linux-kvm.port.11
on the host  #nc -U /tmp/tt11
(after step 4 ,socket could receive data)

5.hot add another virtioserialport
(qemu)device_add virtserialport,chardev=s12,name=org.linux-kvm.port.12,bus=virtio-serial0.0,id=port12

6.in the guest send data to /dev/vport0p2
in the guest #echo c > /dev/virtio-ports/org.linux-kvm.port.12
on the host  #nc -U /tmp/tt12
(after step 6 ,socket could receive data)

7.Hot unplug the 2nd virtio serial port
(qemu)device_del port12
(after step7 ,/dev/vport0p2 removed)

8.send data via /dev/vport0p1 in the guest


Actual Results:
After step8,guest could not transfer data via /dev/vport0p1

Expected Results:
After step8,guest still can send data via /dev/vport0p1

Comment 1 Amit Shah 2011-05-05 08:40:38 UTC

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