]> git.ipfire.org Git - thirdparty/linux.git/commit
ALSA: virtio: Add missing 384 kHz PCM rate mapping
authorCássio Gabriel <cassiogabrielcontato@gmail.com>
Fri, 15 May 2026 13:32:25 +0000 (10:32 -0300)
committerTakashi Iwai <tiwai@suse.de>
Sat, 16 May 2026 13:42:30 +0000 (15:42 +0200)
commit83fbbcb7935ec6d2c8ba3bc133e8a0ead2ab0b2d
tree0e387ffce714d64d03c34c682a871263de80fd1b
parentb65020d5398f499c09498c9786dba6d67ae57664
ALSA: virtio: Add missing 384 kHz PCM rate mapping

The VirtIO sound UAPI defines VIRTIO_SND_PCM_RATE_384000, and ALSA
has SNDRV_PCM_RATE_384000. However, virtio-snd's rate conversion
tables stop at 192 kHz.

A device advertising only 384 kHz is rejected as having no supported
PCM frame rates. A device advertising 384 kHz together with lower rates
does not expose 384 kHz through the ALSA hardware constraints. The
selected ALSA rate also needs a reverse mapping for SET_PARAMS.

Add the missing 384 kHz entries to both conversion tables.

Fixes: 29b96bf50ba9 ("ALSA: virtio: build PCM devices and substream hardware descriptors")
Fixes: da76e9f3e43a ("ALSA: virtio: PCM substream operators")
Cc: stable@vger.kernel.org
Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com>
Link: https://patch.msgid.link/20260515-alsa-virtio-384k-rate-v1-1-35ecb5df835c@gmail.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/virtio/virtio_pcm.c
sound/virtio/virtio_pcm_ops.c