Internships/ProjectIdeas/VirtioSound: Difference between revisions
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
=== | === Implement virtio-sound emulation === | ||
'''Summary:''' Implement device emulation for the new virtio-sound device. | '''Summary:''' Implement device emulation for the new virtio-sound device. |
Revision as of 15:36, 31 January 2023
Implement virtio-sound emulation
Summary: Implement device emulation for the new virtio-sound device.
The VIRTIO specification defines a sound device and Linux has a guest driver for it, but QEMU does not emulate the virtio-sound device yet.
The goal is to implement virtio-sound in QEMU with mono and stereo playback and capture. There is unfinished code for virtio-sound playback support that you can use as a starting point. It will be necessary to clean up the code and add capture support.
As stretch goals you can implement additional functionality covered by the specification, including support for multi-channel devices (e.g. surround sound playback), channel maps, etc.
To familiarize yourself with the project idea (see links below):
- Review the VIRTIO sound device specification.
- Review the audio/audio.h QEMU audio subsystem API.
- Review the unfinished patches.
This project will expose you to device emulation, VIRTIO, and you'll learn how audio devices work at the hardware interface level.
Links:
- Device specification: https://docs.oasis-open.org/virtio/virtio/v1.2/csd01/virtio-v1.2-csd01.html#x1-52900014
- Linux guest driver: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/sound/virtio
- QEMU audio subsystem: https://git.qemu.org/?p=qemu.git;a=tree;f=audio
- QEMU audio devices: https://git.qemu.org/?p=qemu.git;a=tree;f=hw/audio
Details:
- Skill level: intermediate/advanced
- Language: C
- Mentor: Stefan Hajnoczi <stefanha@redhat.com>
- Suggested by: Gerd Hoffmann <kraxel@redhat.com>