blob: 8ff03f4308cab7a7312c8ac8ab3ea1b9734cfaa7 (
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
|
x86: 0.961
device: 0.932
ppc: 0.894
peripherals: 0.875
semantic: 0.834
network: 0.803
architecture: 0.791
socket: 0.784
PID: 0.767
files: 0.764
vnc: 0.763
register: 0.750
boot: 0.743
kernel: 0.724
mistranslation: 0.707
permissions: 0.706
debug: 0.680
graphic: 0.675
i386: 0.674
arm: 0.628
performance: 0.587
risc-v: 0.585
VMM: 0.555
TCG: 0.481
hypervisor: 0.479
user-level: 0.475
virtual: 0.444
assembly: 0.151
KVM: 0.141
Direct Sound Audio does not stop
The Bug:
DirectSound Audio does not stop because dsound_ctl_out does not end up calling IDirectSoundBuffer_Stop. This is due to a bug in dsound_get_status_out where the status flags returned from IDirectSoundBuffer_GetStatus are compared with DSERR_BUFFERLOST (an error code) rather than DSBSTATUS_BUFFERLOST (a status flag). The status is actually (DSBSTATUS_LOOPING | DSBSTATUS_PLAYING) and one of those flags happens to be set in the DSERR_BUFFERLOST value. As a result, dsound_get_status_out returns -1 and dsound_ctl_out exits before calling IDirectSoundBuffer_Stop.
The Fix:
A simple replacement of DSERR_BUFFERLOST with DSBSTATUS_BUFFERLOST in dsound_get_status_out.
Should be: "if (*statusp & DSBSTATUS_BUFFERLOST) {"
Version Information:
I was able to produce this bug in Qemu 2.9.0 and with the latest source pulled from git://git.qemu-project.org/qemu.git (commit 8dfaf23ae1). I was able to verify my suggested fix with the latest source.
Guest OS:
Discovered running Minoca OS v0.4 (www.github.com/minoca/os). Images at https://www.minocacorp.com/download/nightlies/latest-x86. The Qemu test images I tried (http://wiki.qemu.org/Testing/System_Images) didn't have an easy sound setup (was looking for 'aplay' or similar).
Qemu Command Line:
./qemu-system-x86_64.exe -m 512 -hda pc.img -smp 4 -usbdevice keyboard -device intel-hda -device hda-duplex
Fixed here:
https://git.qemu.org/?p=qemu.git;a=commitdiff;h=4ba664cb0aab
|