Page MenuHomeFreeBSD

sound: Be more verbose with virtual channel descriptions
ClosedPublic

Authored by christos on Apr 18 2024, 5:31 PM.
Tags
None
Referenced Files
Unknown Object (File)
Oct 1 2024, 2:05 PM
Unknown Object (File)
Oct 1 2024, 9:15 AM
Unknown Object (File)
Sep 30 2024, 2:42 AM
Unknown Object (File)
Sep 19 2024, 8:45 PM
Unknown Object (File)
Sep 19 2024, 5:09 AM
Unknown Object (File)
Sep 18 2024, 12:25 PM
Unknown Object (File)
Sep 18 2024, 5:38 AM
Unknown Object (File)
Sep 18 2024, 3:14 AM
Subscribers

Details

Summary

Non-virtual channel description denote "play" or "record", so do the
same for virtual ones as well.

Sponsored by: The FreeBSD Foundation
MFC after: 1 week

Test Plan

Before:

root@freebsd:/mnt/src # cat /dev/sndstat | grep pcm0:
pcm0: <Focusrite Scarlett Solo USB> on uaudio0 (1p:1v/1r:1v) default
        [pcm0:play:dsp0.p0]: spd 48000, fmt 0x00200010/0x00201000, flags 0x00002100, 0x00000006
        pcm0:play:dsp0.p0[pcm0:virtual:dsp0.vp0]: spd 8000, fmt 0x00100008, flags 0x10000000, 0x00000000
        [pcm0:record:dsp0.r0]: spd 48000, fmt 0x00200010/0x00201000, flags 0x00002100, 0x00000007
        pcm0:record:dsp0.r0[pcm0:virtual:dsp0.vr0]: spd 8000, fmt 0x00100008, flags 0x10000000, 0x00000000

After:

root@freebsd:/mnt/src # cat /dev/sndstat | grep pcm0:
pcm0: <Focusrite Scarlett Solo USB> on uaudio0 (1p:1v/1r:1v) default
        [pcm0:play:dsp0.p0]: spd 48000, fmt 0x00200010/0x00201000, flags 0x00002100, 0x00000006
        pcm0:play:dsp0.p0[pcm0:virtual_play:dsp0.vp0]: spd 8000, fmt 0x00100008, flags 0x10000000, 0x00000000
        [pcm0:record:dsp0.r0]: spd 48000, fmt 0x00200010/0x00201000, flags 0x00002100, 0x00000007
        pcm0:record:dsp0.r0[pcm0:virtual_record:dsp0.vr0]: spd 8000, fmt 0x00100008, flags 0x10000000, 0x00000000

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

I don't object but we already have :record: or :play: (elsewhere) in the description, is there any case where this won't be the case?

I don't object but we already have :record: or :play: (elsewhere) in the description, is there any case where this won't be the case?

There are many places where we print the channel name (search for ch->name or c->name) and in this case the strings will only contain :virtual:.

This revision is now accepted and ready to land.Apr 18 2024, 8:07 PM