Page MenuHomeFreeBSD

sound: Remove useless newspd check in sysctl_dev_pcm_vchanrate()
ClosedPublic

Authored by christos on Sep 28 2024, 3:16 PM.
Tags
None
Referenced Files
F144448053: D46834.id145090.diff
Sun, Feb 8, 12:11 PM
F144314210: D46834.id143867.diff
Sat, Feb 7, 7:27 PM
Unknown Object (File)
Fri, Jan 30, 9:12 PM
Unknown Object (File)
Dec 22 2025, 3:37 PM
Unknown Object (File)
Dec 7 2025, 5:21 AM
Unknown Object (File)
Nov 26 2025, 1:16 AM
Unknown Object (File)
Nov 18 2025, 10:16 AM
Unknown Object (File)
Nov 4 2025, 4:53 PM
Subscribers

Details

Summary

feeder_rate_min functions as the lower boundary.

Sponsored by: The FreeBSD Foundation
MFC after: 2 days

Diff Detail

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

Event Timeline

sys/dev/sound/pcm/vchan.c
511

We could just as well use RANGE() to fit the speed into the acceptable range, instead of returning an error.

dev_submerge.ch added inline comments.
sys/dev/sound/pcm/vchan.c
511

I'd prefer the EINVAL return here. The values close to feeder_rate_min and feeder_rate_max are unrealistic and never used in practice, going out of bounds here is almost certainly a user error.

This revision is now accepted and ready to land.Sep 29 2024, 3:08 PM