blob: 0ebcb1a3700b8e4572d6c01c3b0c6becb8b2882e (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
|
semantic: 0.445
mistranslation: 0.350
architecture: 0.346
performance: 0.313
device: 0.266
PID: 0.249
peripherals: 0.232
user-level: 0.231
kernel: 0.219
socket: 0.216
arm: 0.211
permissions: 0.210
hypervisor: 0.203
graphic: 0.201
debug: 0.173
files: 0.165
ppc: 0.151
boot: 0.145
register: 0.144
network: 0.138
virtual: 0.136
i386: 0.128
VMM: 0.127
TCG: 0.110
risc-v: 0.109
vnc: 0.106
x86: 0.097
assembly: 0.092
KVM: 0.065
Unable to use USB as hda in Windows
I built qemu 1.6.0 from source in MinGW (and all dependents not available with mingw-get)
The command line:
qemu-system-i386.exe -m 1024 -hda \\.\PhysicalDrive1 -L pc-bios
or
qemu-system-x86_64.exe -m 1024 -hda \\.\PhysicalDrive1 -L pc-bios
(or the *w.exe equivalents)
reports in stderr.txt:
qemu-system-i386.exe: -hda \\.\PhysicalDrive1: Block protocol 'host_device' doesn't support the option 'filename'
qemu-system-i386.exe: -hda \\.\PhysicalDrive1: could not open disk image \\.\PhysicalDrive1: Invalid argument
I have also found this bug in 1.5 but not in 1.4
Some Help:
The code in Qemu is a bit beyond me at 1am, but I was able to determine the root cause seems to be that block.c is becoming confused about referring to a file but not having a file name. I have been able to work around this by changing line 860 of block.c from: "if (qdict_size(options) != 0) {" to "if (qdict_size(options) != 0 && !is_windows_drive(filename)) {"
But I don't think this is a good solution (it is assuming that nothing else could be wrong), and I can't be sure that I'm not masking some real issue.
FWIW; Build is on XP, but execution is on Win7.
Thanks.
I can confirm the same bug. I am not building from source, but rather using the unofficial Windows binaries linked to by Qemu.
http://wiki.qemu.org/Links
I'm running as Administrator on Win8.1 x86_64
qemu-system-i386.exe -L . -hda \\.\PhysicalDrive3
qemu-system-i386.exe: -hda \\.\PhysicalDrive3: Block protocol 'host_device' doesn't support the option 'filename'
qemu-system-i386.exe: -hda \\.\PhysicalDrive3: could not open disk image \\.\PhysicalDrive3: Invalid argument
I see this error in the 1.51, 1.53, and 1.60 builds from a couple different sources
PhysicalDrive3 is a USB device that's visible in the Windows Disk Management Snap-In. I see the activity light on the drive blink when running this command.
I've found some older Qemu binaries from various random sources https://code.google.com/p/kqemu-portable-win/ and they seem to be able to access physical devices without issue, though they also seem to have other problems of their own...
I think this has been fixed by commit 68dc0364, which was included in
qemu 1.7.0 and also backported to 1.6.1. Can you please try upgrading and
confirm whether it fixes the problem?
I found some newer Windows binaries at http://qemu.weilnetz.de/ and can confirm I do not see the issue any more.
|