Bug 839957 - usb-storage: SYNCHRONIZE_CACHE is broken
usb-storage: SYNCHRONIZE_CACHE is broken
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm (Show other bugs)
6.3
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Gerd Hoffmann
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-13 05:49 EDT by Gerd Hoffmann
Modified: 2013-02-21 02:38 EST (History)
9 users (show)

See Also:
Fixed In Version: qemu-kvm-0.12.1.2-2.306.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-02-21 02:38:07 EST
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)
the fedora 17 guest kernel log. (33.01 KB, text/plain)
2012-07-16 04:55 EDT, Sibiao Luo
no flags Details

  None (edit)
Description Gerd Hoffmann 2012-07-13 05:49:23 EDT
Description of problem:
Fedora 17 guest produces a constant stream of "reset high-speed USB device number" when accessing usb-storage devices due to a bug in SYNCHRONIZE_CACHE handling.

Version-Release number of selected component (if applicable):
qemu-kvm-0.12.1.2-2.295.el6
Comment 1 Gerd Hoffmann 2012-07-13 06:42:54 EDT
http://patchwork.ozlabs.org/patch/170838/
Comment 2 Sibiao Luo 2012-07-16 04:52:20 EDT
Hi all,
   
   I reproduce this issue on the kernel-2.6.32-284.el6.x86_64 and qemu-kvm-0.12.1.2-2.295.el6.x86_64 host with the Fedora_17_x86_64 guest.

Version-Release number of selected component (if applicable):
host info:
# uname -r && rpm -q qemu-kvm
2.6.32-284.el6.x86_64
qemu-kvm-0.12.1.2-2.295.el6.x86_64
guest info:
Fedora_17_x86_64

Steps to Reproduce:
1.install fedora 17 guest on rhel 6.3 host.
2.create a usb-storage.
# qemu-img create -f qcow2 usb-storage.qcow2 20G
3.boot the guest adding a usb-storage device.
eg: # /usr/libexec/qemu-kvm -M rhel6.3.0 -cpu host -enable-kvm -m 2048 -smp 2 -usb -name sluo -uuid `uuidgen` -drive file=Fedora_17_x86_64.qcow2,format=qcow2,if=none,id=drive-virtio-disk0,cache=none,werror=stop,rerror=stop -device virtio-blk-pci,bus=pci.0,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 -netdev tap,id=hostnet0,script=/etc/qemu-ifup -device virtio-net-pci,netdev=hostnet0,id=virtio-net-pci0,mac=08:2E:5F:0A:0D:B3 -spice disable-ticketing,port=5931 -vga qxl -global qxl-vga.vram_size=67108864 -device usb-ehci,id=ehci -drive file=/home/usb-storage.qcow2,if=none,id=storage0,media=disk,cache=none,format=qcow2 -device usb-storage,drive=storage0,id=usb-storage0,bus=ehci.0 -monitor stdio
4.write something to it (create filesystem for example).
# fdisk -l --> find the usb-storage disk in guest.
# mkfs.ext4 /dev/sda
5.check the guests kernel log.
# dmesg

Test results:
After the step 5, we can see a constant stream of "reset high-speed USB device number" in Fedora 17 guest's kernel log. I will attach the kernel log later.
# dmesg
[    0.000000] Initializing cgroup subsys cpuset
[    0.000000] Initializing cgroup subsys cpu
...
[   57.556246] SELinux: initialized (dev fusectl, type fusectl), uses genfs_contexts
[   57.595447] SELinux: initialized (dev fuse, type fuse), uses genfs_contexts
[  554.995113] usb 1-1: reset high-speed USB device number 2 using ehci_hcd
[  555.241106] usb 1-1: reset high-speed USB device number 2 using ehci_hcd 

   BTW, I also tried the rhel6.3 guest, it do not have this issue.

Best wish.
sluo
Comment 3 Sibiao Luo 2012-07-16 04:55:11 EDT
Created attachment 598397 [details]
the fedora 17 guest kernel log.
Comment 4 Gerd Hoffmann 2012-08-10 08:21:53 EDT
patch posted.
Comment 7 Sibiao Luo 2012-10-09 05:09:19 EDT
I Verify this issue on the kernel-2.6.32-315.el6.x86_64 and
qemu-kvm-0.12.1.2-2.320.el6.x86_64 host with the the same steps as comment #2.

Host info:
# uname -r && rpm -q qemu-kvm
2.6.32-315.el6.x86_64
qemu-kvm-0.12.1.2-2.320.el6.x86_64
Guest info:
Fedora_17_x86_64

Steps:
as same as comment #2

Test results:
After the step 5, 
we *cannot* see any stream of "reset high-speed USB device number" in Fedora 17 guest's kernel log, so this issue disappear.

Base on above and comment #2, this issue has been fixed correctly.
Comment 9 errata-xmlrpc 2013-02-21 02:38:07 EST
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-2013-0527.html

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