Hi all,

I still have troubles using USB CD or DVD drives in QEMU. They get detected and work very often on Linux Guests, but Windows XP Guests seem not to be able to detect the drive completely.

Now my question to all:
Do you have a USB CD or DVD drive already attached to a Windows XP QEMU guest?
If yes, please let me know your host hardware configuration and your QEMU options - I really need this feature for my further work.

I tested now 1 plain USB DVD/RW drive, 1 plain older USB CD/RW drive and a "combo" DVD Drive with Cardreader.

Results - both on a AMD (Debian 6.0, kernel 2.6.32.5) and two Intel host systems (vanilla kernel 2.6.32.12, Core2Duo / i7 and another disk with Debian 6.0 as well!):
Windows XP detects all drives with several host resets.
For the "plain" drives they are listed in the device manager but not get a drive letter assigned - no further errors visible. => but those drives work fine on a native XP system and are fine as well on native Linux.

The "combo" drive gets fully detected on the AMD system with the Windows XP Guest - transfer rates in the guest are ok (~ 50 secs for 90 MB from CD), but this drive causes USB resets on the Intel systems and no real success when trying to transfer data (Double click on the drive letter causes a Windows Explorer hang / get unresponsive - there is no autostart.inf on my test CD). With the Debian 6.0 and the Intel Systems I get the drive letter as well for the combo drive - but the disc access is not possible - it resets the USB device over and over on the host system and causes kernel oops (see the textfile from dmesg attached)!

I can provide further traces, logfiles etc. for digging deeper, but I need to know what you need exactly for proceeding and will try to provide them.

Thanks a lot in advance.

Best regards,

Erik
[ 1125.780250] usb-storage: waiting for device to settle before scanning
[ 1126.016797] usb 2-1.4: reset high speed USB device using ehci_hcd and 
address 3
[ 1126.290122] usb 2-1.4: usbfs: interface 0 claimed by usb-storage while 
'qemu-system-x86' sets config #1
[ 1142.166799] usb 2-1.4: reset high speed USB device using ehci_hcd and 
address 3
[ 1142.302141] scsi18 : SCSI emulation for USB Mass Storage devices
[ 1142.302247] usb-storage: device found at 3
[ 1142.302250] usb-storage: waiting for device to settle before scanning
[ 1147.298496] usb-storage: device scan complete
[ 1147.299574] scsi 18:0:0:0: CD-ROM            HL-DT-ST DVD-RW GWA-4040N 1.01 
PQ: 0 ANSI: 0
[ 1147.300437] scsi 18:0:0:1: Direct-Access     GENERIC  IDE CARD READER  9350 
PQ: 0 ANSI: 0 CCS
[ 1147.304182] sd 18:0:0:1: [sdc] Attached SCSI removable disk
[ 1147.768301] sr0: scsi3-mmc drive: 40x/24x writer cd/rw xa/form2 cdda tray
[ 1147.768306] Uniform CD-ROM driver Revision: 3.20
[ 1147.768428] sr 18:0:0:0: Attached scsi CD-ROM sr0
[ 1147.807633] sd 0:0:0:0: Attached scsi generic sg0 type 0
[ 1147.807874] sd 4:0:0:0: Attached scsi generic sg1 type 0
[ 1147.807961] sr 18:0:0:0: Attached scsi generic sg2 type 5
[ 1147.808630] sd 18:0:0:1: Attached scsi generic sg3 type 0
[ 1178.054300] usb 2-1.4: reset high speed USB device using ehci_hcd and 
address 3
[ 1178.282291] usb 2-1.4: reset high speed USB device using ehci_hcd and 
address 3
[ 1179.082176] usb 2-1.4: reset high speed USB device using ehci_hcd and 
address 3
[ 1179.217424] usb 2-1.4: usbfs: interface 0 claimed by usb-storage while 
'qemu-system-x86' sets config #1
[ 1179.262642] scsi 18:0:0:0: Device offlined - not ready after error recovery
[ 1179.262690] BUG: unable to handle kernel NULL pointer dereference at 00000304
[ 1179.270111] IP: [<f7fffb56>] scsi_prep_state_check+0x1/0x77 [scsi_mod]
[ 1179.277440] *pde = 00000000
[ 1179.284685] Oops: 0000 [#1] SMP
[ 1179.291864] last sysfs file: /sys/devices/pci0000:00/0000:00:1d.0/class
[ 1179.299088] Modules linked in: sg sr_mod cdrom usb_storage kvm_intel kvm sco 
bridge stp acpi_cpufreq ppdev lp cpufreq_userspace rfcomm cpufreq_powersave 
bnep cpufreq_conservative l2cap crc16 cpufreq_stats bluetooth rfkill 
binfmt_misc fuse loop i915 drm_kms_helper drm i2c_algo_bit parport_pc i2c_i801 
parport i2c_core pcspkr psmouse serio_raw ac evdev button processor video 
output ext3 jbd mbcache sd_mod crc_t10dif ahci fan libata scsi_mod thermal 
ehci_hcd thermal_sys e1000e usbcore nls_base [last unloaded: scsi_wait_scan]
[ 1179.322456]
[ 1179.330138] Pid: 10915, comm: blkid Not tainted (2.6.32-5-686 #1)
[ 1179.337876] EIP: 0060:[<f7fffb56>] EFLAGS: 00010046 CPU: 0
[ 1179.345576] EIP is at scsi_prep_state_check+0x1/0x77 [scsi_mod]
[ 1179.353237] EAX: 00000000 EBX: f5c44d48 ECX: 00000001 EDX: f5c44d48
[ 1179.360906] ESI: f4e58000 EDI: 00000000 EBP: 00000000 ESP: f4e77b0c
[ 1179.368515]  DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068
[ 1179.376104] Process blkid (pid: 10915, ti=f4e76000 task=f6623b80 
task.ti=f4e76000)
[ 1179.383724] Stack:
[ 1179.391259]  f5c44d48 f8000a3b f5c44d48 f4e58000 f4e58000 00000000 f8000b1a 
f5c44d48
[ 1179.391432] <0> 00000000 c11291eb f5c44d48 f4e58000 00000000 f5c44d48 
00000000 f80000c4
[ 1179.399130] <0> f4e58000 c144f4e0 c103b6c4 00000092 f4e58000 f4e58000 
f4e58000 f5c44d48
[ 1179.414336] Call Trace:
[ 1179.421904]  [<f8000a3b>] ? scsi_setup_blk_pc_cmnd+0xd/0xd0 [scsi_mod]
[ 1179.429514]  [<f8000b1a>] ? scsi_prep_fn+0x1c/0x29 [scsi_mod]
[ 1179.437072]  [<c11291eb>] ? blk_peek_request+0xa8/0x150
[ 1179.444593]  [<f80000c4>] ? scsi_request_fn+0x26/0x46f [scsi_mod]
[ 1179.452089]  [<c103b6c4>] ? del_timer+0x55/0x5c
[ 1179.459536]  [<c1129b68>] ? __generic_unplug_device+0x23/0x25
[ 1179.466971]  [<c112c3b8>] ? blk_execute_rq_nowait+0x59/0x77
[ 1179.474358]  [<c112c45a>] ? blk_execute_rq+0x84/0xb2
[ 1179.481681]  [<c112c33c>] ? blk_end_sync_rq+0x0/0x23
[ 1179.488946]  [<c112963e>] ? get_request+0x1b0/0x25b
[ 1179.496164]  [<c1129b84>] ? get_request_wait+0x1a/0x146
[ 1179.503328]  [<f800120f>] ? scsi_execute+0xce/0x126 [scsi_mod]
[ 1179.510469]  [<f80012c1>] ? scsi_execute_req+0x5a/0x81 [scsi_mod]
[ 1179.517576]  [<f7ffc7e8>] ? ioctl_internal_command+0x4a/0x125 [scsi_mod]
[ 1179.524674]  [<f7ffc910>] ? scsi_set_medium_removal+0x4d/0x83 [scsi_mod]
[ 1179.531729]  [<fb40edef>] ? cdrom_open+0x2dc/0x891 [cdrom]
[ 1179.538748]  [<c108b44d>] ? zone_watermark_ok+0x16/0x99
[ 1179.545730]  [<c101f92c>] ? kmap_atomic_prot+0xc7/0xea
[ 1179.552659]  [<c101f7dd>] ? kunmap_atomic+0x51/0x6d
[ 1179.559539]  [<c101f7e9>] ? kunmap_atomic+0x5d/0x6d
[ 1179.566330]  [<c108c2d3>] ? get_page_from_freelist+0x33a/0x3c7
[ 1179.573113]  [<c108c621>] ? __alloc_pages_nodemask+0xf3/0x4d9
[ 1179.579874]  [<c108b44d>] ? zone_watermark_ok+0x16/0x99
[ 1179.586574]  [<c101f92c>] ? kmap_atomic_prot+0xc7/0xea
[ 1179.593225]  [<c101f7dd>] ? kunmap_atomic+0x51/0x6d
[ 1179.599825]  [<c101f7e9>] ? kunmap_atomic+0x5d/0x6d
[ 1179.606350]  [<c108c2d3>] ? get_page_from_freelist+0x33a/0x3c7
[ 1179.612856]  [<c108b44d>] ? zone_watermark_ok+0x16/0x99
[ 1179.619314]  [<c101f92c>] ? kmap_atomic_prot+0xc7/0xea
[ 1179.625717]  [<c1136884>] ? kobject_get+0xf/0x13
[ 1179.632089]  [<c112e126>] ? get_disk+0x6f/0x87
[ 1179.638398]  [<c11b51cf>] ? kobj_lookup+0x132/0x161
[ 1179.644673]  [<c10c1431>] ? __d_lookup+0x9e/0xd3
[ 1179.650889]  [<c1136884>] ? kobject_get+0xf/0x13
[ 1179.657054]  [<fb4203ca>] ? sr_block_open+0x66/0x7a [sr_mod]
[ 1179.663201]  [<c10d2c96>] ? __blkdev_get+0xb0/0x2c7
[ 1179.669324]  [<c10d2f14>] ? blkdev_open+0x60/0x8b
[ 1179.675844]  [<c10b2213>] ? __dentry_open+0x156/0x246
[ 1179.682312]  [<c10b2394>] ? nameidata_to_filp+0x29/0x3c
[ 1179.688743]  [<c10d2eb4>] ? blkdev_open+0x0/0x8b
[ 1179.695116]  [<c10bc42c>] ? do_filp_open+0x43f/0x802
[ 1179.701454]  [<c109c082>] ? handle_mm_fault+0x48f/0x959
[ 1179.707752]  [<c10c414d>] ? alloc_fd+0x52/0xb7
[ 1179.713985]  [<c10b1fcb>] ? do_sys_open+0x4c/0xdf
[ 1179.720171]  [<c10b20a2>] ? sys_open+0x1e/0x23
[ 1179.726298]  [<c10030fb>] ? sysenter_do_call+0x12/0x28
[ 1179.732377] Code: b4 1e 01 f8 00 0f 85 da fe ff ff e9 bc fe ff ff 83 3d b8 
1e 01 f8 00 0f 85 26 ff ff ff e9 08 ff ff ff 83 c4 1c 5b 5e 5f 5d c3 53 <8b> 88 
04 03 00 00 83 f9 02 74 67 83 e9 04 83 f9 04 77 53 ff 24
[ 1179.745767] EIP: [<f7fffb56>] scsi_prep_state_check+0x1/0x77 [scsi_mod] 
SS:ESP 0068:f4e77b0c
[ 1179.752351] CR2: 0000000000000304
[ 1179.758839] ---[ end trace aece1fe64e2fa0d8 ]---
[ 1180.478049] usb 2-1.4: reset high speed USB device using ehci_hcd and 
address 3
[ 1180.617258] scsi19 : SCSI emulation for USB Mass Storage devices
[ 1180.623650] usb-storage: device found at 3
[ 1180.630637] usb-storage: waiting for device to settle before scanning
[ 1180.858047] usb 2-1.4: reset high speed USB device using ehci_hcd and 
address 3
[ 1181.141945] usb 2-1.4: usbfs: interface 0 claimed by usb-storage while 
'qemu-system-x86' sets config #1
[ 1181.869923] usb 2-1.4: reset high speed USB device using ehci_hcd and 
address 3
[ 1182.009124] scsi20 : SCSI emulation for USB Mass Storage devices
[ 1182.015195] usb-storage: device found at 3

Reply via email to