All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oleksandr <olekstysh@gmail.com>
To: "SHARMA, JYOTIRMOY" <JYOTIRMOY.SHARMA@amd.com>,
	"christopher.w.clark@gmail.com" <christopher.w.clark@gmail.com>
Cc: "dpsmith@apertussolutions.com" <dpsmith@apertussolutions.com>,
	"Stabellini, Stefano" <stefano.stabellini@amd.com>,
	"xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>,
	"xen-users@lists.xenproject.org" <xen-users@lists.xenproject.org>
Subject: Re: Enable audio virtualization in Xen
Date: Fri, 12 Aug 2022 15:15:42 +0300	[thread overview]
Message-ID: <df068c2b-2b09-fb0f-aa85-77bb1191b25a@gmail.com> (raw)
In-Reply-To: <DM6PR12MB429763D0795CAB57F9F7206A9F679@DM6PR12MB4297.namprd12.prod.outlook.com>


On 12.08.22 12:27, SHARMA, JYOTIRMOY wrote:
>
> [AMD Official Use Only - General]
>
>
> Hello Christopher,
>
Hello Jyotirmoy, Christopher


Just spotted that libxenbe and snd_be were mentioned ...


> Thank you so much for your reply. I will execute your steps and first 
> try to enable pulse audio as you have mentioned.
>
> Later I will try to enable ALSA which is my final requirement.
>
> Meanwhile, I was reading up on virtio-snd and found some patches in 
> the internet. However, those patches are not
>
> present in the qemu source code 
> (https://gitlab.com/qemu-project/qemu.git). Do you know
>
>  1. If virtio-snd front end driver is another option to enable audio
>     in HVM guest with Qemu/ALSA as backend in dom0?
>  2. If yes, how is it different from xen front end drivers?
>
> Also, regarding enabling Xen PV audio front end device drivers, you 
> have mentioned that I need to enable backend using libxenbe and 
> snd_be. Does it mean, in this case, Qemu is not involved in the audio 
> backend? Any pointers to understand this overall architecture (Xen PV 
> audio front end driver/snd_be/qemu/ALSA) will be extremely helpful.
>

    ... I am not familiar with sound internals, but have an overall 
understanding about Xen PV audio.


1. The backend (snd_be) is Xen PV backend, not a virtio. It is a 
standalone user-space application, so Qemu is not involved here if we 
are speaking about snd_be+libxenbe. The backend can work on top of Pulse 
or Alsa and supports playback and record.
    https://github.com/xen-troops/snd_be/commits/master
    Some details you can find at:
    https://github.com/xen-troops/snd_be/blob/master/README.md

2. The library (libxenbe) contains various Xen specific stuff, such as 
event channel, xenstore, grant table, etc needed for Xen PV backend to 
work, so it should be linked by snd_be.
    https://github.com/xen-troops/libxenbe/commits/master
    Both snd_be and libxenbe are written on C++, both are part of Yocto 
build, but I guess they can be built standalone.


3. The frontend is in upstream Linux and supported, the protocol is also 
there, toolstack also supports PV audio configuration (no extra patches 
are needed):
    https://elixir.bootlin.com/linux/v5.19.1/source/sound/xen
https://elixir.bootlin.com/linux/v5.19.1/source/include/xen/interface/io/sndif.h

    Also the guest should be built with CONFIG_SND_XEN_FRONTEND=y


> Regards,
>
> Jyotirmoy
>
-- 
Regards,

Oleksandr Tyshchenko



  reply	other threads:[~2022-08-12 12:16 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-12  9:27 Enable audio virtualization in Xen SHARMA, JYOTIRMOY
2022-08-12 12:15 ` Oleksandr [this message]
  -- strict thread matches above, loose matches on Subject: below --
2022-09-06 10:51 SHARMA, JYOTIRMOY
2022-09-05 18:27 SHARMA, JYOTIRMOY
2022-09-01  8:58 SHARMA, JYOTIRMOY
2022-09-02  8:21 ` Oleksandr Tyshchenko
2022-09-01  7:28 SHARMA, JYOTIRMOY
2022-07-25 11:08 SHARMA, JYOTIRMOY
2022-07-25 21:14 ` Christopher Clark
2022-07-26 10:57   ` SHARMA, JYOTIRMOY
2022-07-28 19:05     ` SHARMA, JYOTIRMOY
2022-07-28 20:37       ` Christopher Clark
2022-07-29 21:48         ` Christopher Clark

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=df068c2b-2b09-fb0f-aa85-77bb1191b25a@gmail.com \
    --to=olekstysh@gmail.com \
    --cc=JYOTIRMOY.SHARMA@amd.com \
    --cc=christopher.w.clark@gmail.com \
    --cc=dpsmith@apertussolutions.com \
    --cc=stefano.stabellini@amd.com \
    --cc=xen-devel@lists.xenproject.org \
    --cc=xen-users@lists.xenproject.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.