qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* USB-audio sound issues with qemu-system-ppc in Linux and Windows.
@ 2019-10-25 13:28 Howard Spoelstra
  2019-10-26  7:40 ` Howard Spoelstra
  0 siblings, 1 reply; 5+ messages in thread
From: Howard Spoelstra @ 2019-10-25 13:28 UTC (permalink / raw)
  To: qemu-devel qemu-devel

[-- Attachment #1: Type: text/plain, Size: 5587 bytes --]

 Hi,

I'm  experiencing several issues related to sound using usb-audio when
running qemu-system-ppc in Linux and Windows. Guests tried are Mac OS 9.2
and Mac OS X 10.0, 10.1, 10.2 and 10.3.
(10.4 and 10.5 never have the usb-audio device available for audio
playback, even though the device is recognised in the OS X system profiler.)
It is hit and miss whether the audio device is actually available upon boot
in 9.2 and the other versions of OS X.

Qemu version tried is current master (Oct 25th), Windows version is
cross-compiled from Fedora 30. I do not think there is any regression going
on here, these are just issues that have been present for a long time.

General issue: when audio is played, it almost always sounds crackling.

For reasons of size, I uploaded 3 logs obtained in Linux running Mac OS X
10.3 with -trace "usb*" to:
https://surfdrive.surf.nl/files/index.php/s/YfVVxEE3cHXkFPf/download
1. Log_no_audio_available.txt
2. Log_audio_available_2_sounds_played.txt
3. Log_audio_available_multi_sounds_played_untill_hangup.txt

General issue in Linux (fedora 30)(which seems related to bug
https://bugs.launchpad.net/qemu/+bug/1623998):
[hsp@fedora30 qemu-master]$ ./startqemu.sh
pulseaudio: set_sink_input_volume() failed
pulseaudio: Reason: Invalid argument
pulseaudio: set_sink_input_mute() failed
pulseaudio: Reason: Invalid argument

General issue in Windows 10: I always get to a point where this is logged:
dsound: Could not lock playback buffer
dsound: Reason: An invalid parameter was passed to the returning function
dsound: Failed to lock buffer

Linux specific.
Qemu invocation for Mac OS 9.2:
./qemu-system-ppc -L pc-bios -boot c -M mac99 -m 512 \
-drive file=~/Mac-disks/9.2.img,format=raw,media=disk \
-serial stdio -sdl -device usb-audio -trace "*aud*"

This immediately starts logging:
7380@1571817102.833929:audio_timer_start interval 10 ms
7380@1571817125.207880:audio_timer_delayed interval 16 ms
7380@1571817129.046816:audio_timer_delayed interval 16 ms

Any movement of a window on the Linux desktop results in additional
audio_timer_delayed logging.
The audio_timer_delayed never stops.
In Mac OS 9.2, the desktop icons disappear after some seconds of running,
so the system cannot be stopped normally.
Running the GTK GUI, only this is logged (no additional logging when moving
windows).
14130@1571988483.402017:audio_timer_start interval 10 ms
But the icons on the desktop also disappear.

When running Mac OS X 10.X and clicking some system sounds, I see:
12134@1571818709.446031:audio_timer_start interval 10 ms
12134@1571818710.195023:audio_timer_stop
12134@1571818714.951030:audio_timer_start interval 10 ms
12134@1571818715.432959:audio_timer_stop
12134@1571818717.171045:audio_timer_start interval 10 ms
12134@1571818717.714323:audio_timer_stop
12134@1571818718.072381:audio_timer_start interval 10 ms
12134@1571818719.114544:audio_timer_stop

After randomly clicking some system sounds more, the timer starts delaying
and no longer stops:
12134@1571818893.564793:audio_timer_stop
12134@1571818895.698040:audio_timer_start interval 10 ms
12134@1571818899.961673:audio_timer_delayed interval 15 ms
12134@1571818900.472716:audio_timer_delayed interval 15 ms
12134@1571818902.759007:audio_timer_delayed interval 15 ms
12134@1571818905.803400:audio_timer_delayed interval 15 ms
But the systems stays responsive, so can be shut down.

Windows specific.
Invocation:
qemu-system-ppc.exe -L pc-bios -boot c -M mac99 -m 512 ^
-drive file=C:\Mac-disks\9.2.img,format=raw,media=disk ^
-serial stdio -sdl -device usb-audio -trace "*aud*"

This immediately starts logging the audio_timer_start interval and never
stops.
Icons disappear from the desktop after some seconds.

When running Mac OS X 10.X, playing just two system sounds results in:
2380@1571822566.040790:audio_timer_start interval 10 ms
2380@1571822566.108279:audio_timer_delayed interval 22 ms
2380@1571822566.128820:audio_timer_delayed interval 20 ms
2380@1571822566.150509:audio_timer_delayed interval 22 ms
2380@1571822566.172112:audio_timer_delayed interval 21 ms
......
2380@1571822566.561345:audio_timer_delayed interval 21 ms
2380@1571822566.583846:audio_timer_delayed interval 22 ms
2380@1571822566.600482:audio_timer_delayed interval 15 ms
2380@1571822566.610111:audio_timer_stop
2380@1571822572.226433:audio_timer_start interval 10 ms
2380@1571822572.250866:audio_timer_delayed interval 24 ms
2380@1571822572.269819:audio_timer_delayed interval 18 ms
......
2380@1571822572.452403:audio_timer_delayed interval 20 ms
2380@1571822572.474190:audio_timer_delayed interval 21 ms
2380@1571822572.509474:audio_timer_delayed interval 35 ms
dsound: Could not lock playback buffer
dsound: Reason: An invalid parameter was passed to the returning function
dsound: Failed to lock buffer
2380@1571822572.560505:audio_timer_delayed interval 51 ms
2380@1571822572.581102:audio_timer_delayed interval 19 ms
2380@1571822572.600912:audio_timer_delayed interval 19 ms

There is no saying when audio_timer_delayed will start displaying
constantly.
Only when one set of:
2260@1571823472.652244:audio_timer_start interval 10 ms
2260@1571823473.198349:audio_timer_stop
Is following directly after each other, sound is played somewhat correctly.
After randomly clicking several system sounds, the audio_timer_delayed
message never stops.

Thanks for looking into this.
If there is any additional information needed, or disk images of Mac OS 9.2
or OS X 10.3 are required, please let me know.

Best,
Howard

ps: thanks to Zoltan for pointing out I sent the original message into an
earlier thread ;-)

[-- Attachment #2: Type: text/html, Size: 6217 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread
* [PULL v2 00/73] tcg plugins and testing updates
@ 2019-10-25  6:36 Alex Bennée
  2019-10-25  6:36 ` [PULL v2 46/73] target/alpha: fetch code with translator_ld Alex Bennée
  0 siblings, 1 reply; 5+ messages in thread
From: Alex Bennée @ 2019-10-25  6:36 UTC (permalink / raw)
  To: peter.maydell; +Cc: Alex Bennée, qemu-devel

The following changes since commit 81c1f71eeb874c4cbbb9c5c4d1a1dc0ba7391dff:

  Merge remote-tracking branch 'remotes/ehabkost/tags/machine-next-pull-request' into staging (2019-10-24 10:43:20 +0100)

are available in the Git repository at:

  https://github.com/stsquad/qemu.git tags/pull-testing-and-plugins-241019-2

for you to fetch changes up to 18900c2d7901680457b51b3ad3f684ef9cba8b64:

  travis.yml: enable linux-gcc-debug-tcg cache (2019-10-24 22:31:29 +0100)

----------------------------------------------------------------
Core TCG plugin support and testing updates

  - TCG plugin support
  - netbsd VM autoinstall
  - various Travis dependency updates
  - enable tcg debug for check-tcg
  - additional Xcode build for Cirrus
  - dependency tweak for gitlab

----------------------------------------------------------------
Alex Bennée (30):
      travis.yml: reduce scope of the --enable-debug build
      travis.yml: bump Xcode 10 to latest dot release
      cirrus.yml: add latest Xcode build target
      travis.yml: cache the clang sanitizer build
      travis.yml: --enable-debug-tcg to check-tcg
      tests/docker: set HOST_ARCH if we don't have ARCH
      tests/docker: update Travis image to a more current version
      trace: add mmu_index to mem_info
      docs/devel: add plugins.rst design document
      plugin: add implementation of the api
      plugins: implement helpers for resolving hwaddr
      cputlb: ensure _cmmu helper functions follow the naming standard
      configure: add --enable-plugins
      plugin: expand the plugin_init function to include an info block
      plugin: add qemu_plugin_insn_disas helper
      plugin: add qemu_plugin_outs helper
      tests/tcg/Makefile.target: fix path to config-host.mak
      tests/tcg: set QEMU_OPTS for all cris runs
      tests/tcg: move "virtual" tests to EXTRA_TESTS
      tests/tcg: drop test-i386-fprem from TESTS when not SLOW
      tests/tcg: enable plugin testing
      tests/plugin: add a hotblocks plugin
      tests/plugin: add instruction execution breakdown
      tests/plugin: add hotpages to analyse memory access patterns
      accel/stubs: reduce headers from tcg-stub
      include/exec: wrap cpu_ldst.h in CONFIG_TCG
      .travis.yml: add --enable-plugins tests
      scripts/checkpatch.pl: don't complain about (foo, /* empty */)
      MAINTAINERS: add me for the TCG plugins code
      travis.yml: enable linux-gcc-debug-tcg cache

Eduardo Habkost (2):
      tests/vm: Let subclasses disable IPv6
      tests/vm/netbsd: Disable IPv6

Emilio G. Cota (32):
      trace: expand mem_info:size_shift to 4 bits
      cpu: introduce cpu_in_exclusive_context()
      translate-all: use cpu_in_exclusive_work_context() in tb_flush
      plugin: add user-facing API
      plugin: add core code
      queue: add QTAILQ_REMOVE_SEVERAL
      cputlb: document get_page_addr_code
      cputlb: introduce get_page_addr_code_hostp
      tcg: add tcg_gen_st_ptr
      plugin-gen: add module for TCG-related code
      atomic_template: add inline trace/plugin helpers
      tcg: let plugins instrument virtual memory accesses
      translate-all: notify plugin code of tb_flush
      *-user: notify plugin of exit
      *-user: plugin syscalls
      cpu: hook plugin vcpu events
      plugin-gen: add plugin_insn_append
      translator: add translator_ld{ub,sw,uw,l,q}
      target/arm: fetch code with translator_ld
      target/ppc: fetch code with translator_ld
      target/sh4: fetch code with translator_ld
      target/i386: fetch code with translator_ld
      target/hppa: fetch code with translator_ld
      target/m68k: fetch code with translator_ld
      target/alpha: fetch code with translator_ld
      target/riscv: fetch code with translator_ld
      target/sparc: fetch code with translator_ld
      target/xtensa: fetch code with translator_ld
      target/openrisc: fetch code with translator_ld
      translator: inject instrumentation from plugins
      plugin: add API symbols to qemu-plugins.symbols
      tests/plugin: add sample plugins

Gerd Hoffmann (1):
      tests/vm: netbsd autoinstall, using serial console

Lluís Vilanova (2):
      vl: support -plugin option
      linux-user: support -plugin option

Philippe Mathieu-Daudé (1):
      travis.yml: Test the release tarball

Thomas Huth (5):
      travis.yml: Add libvdeplug-dev to compile-test net/vde.c
      travis.yml: Use libsdl2 instead of libsdl1.2, and install libsdl2-image
      travis.yml: Use newer version of libgnutls and libpng
      travis.yml: Fix the ccache lines
      gitlab-ci.yml: Use libvdeplug-dev to compile-test the VDE network backend

 .cirrus.yml                               |  11 +
 .gitlab-ci.yml                            |   2 +-
 .shippable.yml                            |   2 -
 .travis.yml                               |  69 ++-
 MAINTAINERS                               |   6 +
 Makefile                                  |  16 +-
 Makefile.target                           |   2 +
 accel/stubs/tcg-stub.c                    |   1 -
 accel/tcg/Makefile.objs                   |   1 +
 accel/tcg/atomic_common.inc.c             |  54 ++
 accel/tcg/atomic_template.h               |  94 +--
 accel/tcg/cpu-exec.c                      |   8 +-
 accel/tcg/cputlb.c                        |  84 ++-
 accel/tcg/plugin-gen.c                    | 932 ++++++++++++++++++++++++++++++
 accel/tcg/plugin-helpers.h                |   5 +
 accel/tcg/translate-all.c                 |  15 +-
 accel/tcg/translator.c                    |  20 +
 accel/tcg/user-exec.c                     |   3 +
 bsd-user/syscall.c                        |  24 +-
 configure                                 |  89 +++
 cpus-common.c                             |   4 +
 cpus.c                                    |  10 +
 disas.c                                   | 110 ++++
 docs/devel/index.rst                      |   1 +
 docs/devel/plugins.rst                    | 112 ++++
 exec.c                                    |   2 +
 hw/core/cpu.c                             |   2 +
 include/disas/disas.h                     |   2 +
 include/exec/cpu-defs.h                   |   1 +
 include/exec/cpu_ldst.h                   |  11 +
 include/exec/cpu_ldst_template.h          |  41 +-
 include/exec/cpu_ldst_useronly_template.h |  32 +-
 include/exec/exec-all.h                   |  64 +-
 include/exec/helper-gen.h                 |   1 +
 include/exec/helper-proto.h               |   1 +
 include/exec/helper-tcg.h                 |   1 +
 include/exec/plugin-gen.h                 |  71 +++
 include/exec/translator.h                 |  62 +-
 include/hw/core/cpu.h                     |  19 +
 include/qemu/log.h                        |   1 +
 include/qemu/plugin-memory.h              |  40 ++
 include/qemu/plugin.h                     | 255 ++++++++
 include/qemu/qemu-plugin.h                | 393 +++++++++++++
 include/qemu/queue.h                      |  10 +
 include/user/syscall-trace.h              |  40 ++
 linux-user/exit.c                         |   1 +
 linux-user/main.c                         |  18 +
 linux-user/syscall.c                      |   7 +-
 plugins/.gitignore                        |   2 +
 plugins/Makefile.objs                     |  21 +
 plugins/api.c                             | 341 +++++++++++
 plugins/core.c                            | 502 ++++++++++++++++
 plugins/loader.c                          | 377 ++++++++++++
 plugins/plugin.h                          |  97 ++++
 plugins/qemu-plugins.symbols              |  40 ++
 qemu-options.hx                           |  17 +
 scripts/checkpatch.pl                     |   2 +-
 scripts/tracetool/transform.py            |   1 +
 target/alpha/translate.c                  |   2 +-
 target/arm/arm_ldst.h                     |  15 +-
 target/cris/translate_v10.inc.c           |   3 +-
 target/hppa/translate.c                   |   2 +-
 target/i386/translate.c                   |  10 +-
 target/m68k/translate.c                   |   2 +-
 target/openrisc/translate.c               |   2 +-
 target/ppc/translate.c                    |   8 +-
 target/riscv/translate.c                  |   2 +-
 target/sh4/translate.c                    |   4 +-
 target/sparc/translate.c                  |   2 +-
 target/xtensa/translate.c                 |   4 +-
 tcg/tcg-op.c                              |  40 +-
 tcg/tcg-op.h                              |  16 +
 tcg/tcg-opc.h                             |   3 +
 tcg/tcg.c                                 |  22 +
 tcg/tcg.h                                 |  41 +-
 tests/Makefile.include                    |  11 +-
 tests/docker/Makefile.include             |   6 +-
 tests/docker/dockerfiles/travis.docker    |   6 +-
 tests/plugin/Makefile                     |  31 +
 tests/plugin/bb.c                         |  64 ++
 tests/plugin/empty.c                      |  30 +
 tests/plugin/hotblocks.c                  | 143 +++++
 tests/plugin/hotpages.c                   | 191 ++++++
 tests/plugin/howvec.c                     | 352 +++++++++++
 tests/plugin/insn.c                       |  61 ++
 tests/plugin/mem.c                        |  97 ++++
 tests/tcg/Makefile.target                 |  43 +-
 tests/tcg/aarch64/Makefile.softmmu-target |   2 +-
 tests/tcg/aarch64/Makefile.target         |   6 +
 tests/tcg/arm/Makefile.softmmu-target     |   1 +
 tests/tcg/arm/Makefile.target             |   6 +
 tests/tcg/cris/Makefile.target            |   2 +-
 tests/tcg/i386/Makefile.target            |  11 +-
 tests/vm/basevm.py                        |  15 +-
 tests/vm/netbsd                           | 195 ++++++-
 trace-events                              |   8 +-
 trace/mem-internal.h                      |  39 +-
 trace/mem.h                               |   7 +-
 util/log.c                                |   3 +
 vl.c                                      |  11 +
 100 files changed, 5462 insertions(+), 207 deletions(-)
 create mode 100644 accel/tcg/atomic_common.inc.c
 create mode 100644 accel/tcg/plugin-gen.c
 create mode 100644 accel/tcg/plugin-helpers.h
 create mode 100644 docs/devel/plugins.rst
 create mode 100644 include/exec/plugin-gen.h
 create mode 100644 include/qemu/plugin-memory.h
 create mode 100644 include/qemu/plugin.h
 create mode 100644 include/qemu/qemu-plugin.h
 create mode 100644 include/user/syscall-trace.h
 create mode 100644 plugins/.gitignore
 create mode 100644 plugins/Makefile.objs
 create mode 100644 plugins/api.c
 create mode 100644 plugins/core.c
 create mode 100644 plugins/loader.c
 create mode 100644 plugins/plugin.h
 create mode 100644 plugins/qemu-plugins.symbols
 create mode 100644 tests/plugin/Makefile
 create mode 100644 tests/plugin/bb.c
 create mode 100644 tests/plugin/empty.c
 create mode 100644 tests/plugin/hotblocks.c
 create mode 100644 tests/plugin/hotpages.c
 create mode 100644 tests/plugin/howvec.c
 create mode 100644 tests/plugin/insn.c
 create mode 100644 tests/plugin/mem.c

--
2.20.1



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-10-26  9:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-25 13:28 USB-audio sound issues with qemu-system-ppc in Linux and Windows Howard Spoelstra
2019-10-26  7:40 ` Howard Spoelstra
2019-10-26  9:38   ` BALATON Zoltan
2019-10-26  9:45     ` BALATON Zoltan
  -- strict thread matches above, loose matches on Subject: below --
2019-10-25  6:36 [PULL v2 00/73] tcg plugins and testing updates Alex Bennée
2019-10-25  6:36 ` [PULL v2 46/73] target/alpha: fetch code with translator_ld Alex Bennée
2019-10-25  7:40   ` USB-audio sound issues with qemu-system-ppc in Linux and Windows Howard Spoelstra

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).