qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v8] audio/jack: add JACK client audiodev


From: Geoffrey McRae
Subject: Re: [PATCH v8] audio/jack: add JACK client audiodev
Date: Tue, 12 May 2020 00:58:00 +1000
User-agent: Roundcube Webmail/1.3.8



On 2020-05-12 00:53, Stefan Hajnoczi wrote:
On Wed, Apr 29, 2020 at 03:53:58PM +1000, Geoffrey McRae wrote:
This commit adds a new audiodev backend to allow QEMU to use JACK as
both an audio sink and source.

Signed-off-by: Geoffrey McRae <address@hidden>
---
 audio/Makefile.objs    |   5 +
 audio/audio.c          |   1 +
 audio/audio_template.h |   2 +
audio/jackaudio.c | 677 +++++++++++++++++++++++++++++++++++++++++
 configure              |  17 ++
 qapi/audio.json        |  56 +++-
 6 files changed, 756 insertions(+), 2 deletions(-)
 create mode 100644 audio/jackaudio.c

Cool! Out of interest, which emulated audio device do you use and have
you had issues with buffer sizes/latency?

I now use the ICH9 device, however, I had buffer size issues with usbaudio.


I haven't reviewed in depth but in general this looks good.

+typedef struct QJackBuffer {
+    int          channels;
+    int          frames;
+    _Atomic(int) used;

stdatomic.h isn't used directly in QEMU. Can you use "qemu/atomic.h"
instead?

Sure.


+static inline int qjack_buffer_used(QJackBuffer *buffer)
+{
+    assert(buffer->data);
+    return atomic_load_explicit(&buffer->used, memory_order_relaxed);
+}

Is this function used?

Nope, left behind from a prior implementation, I will remove it.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]