qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Geoffrey McRae <geoff@hostfission.com>
To: Stefan Hajnoczi <stefanha@gmail.com>
Cc: qemu-devel@nongnu.org, Gerd Hoffmann <kraxel@redhat.com>
Subject: Re: [PATCH v8] audio/jack: add JACK client audiodev
Date: Tue, 12 May 2020 00:58:00 +1000	[thread overview]
Message-ID: <6b06451cd2a862bc29b65aa0df304b4c@hostfission.com> (raw)
In-Reply-To: <20200511145347.GD182627@stefanha-x1.localdomain>



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 <geoff@hostfission.com>
>> ---
>>  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	other threads:[~2020-05-11 14:59 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-29  5:53 [PATCH v8] audio/jack: add JACK client audiodev Geoffrey McRae
2020-05-11 14:53 ` Stefan Hajnoczi
2020-05-11 14:58   ` Geoffrey McRae [this message]
2020-05-11 20:31 ` Eric Blake

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6b06451cd2a862bc29b65aa0df304b4c@hostfission.com \
    --to=geoff@hostfission.com \
    --cc=kraxel@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).