Page MenuHomeFreeBSD

sound: Retire volch
ClosedPublic

Authored by christos on Fri, Apr 25, 5:26 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Apr 29, 8:48 PM
Unknown Object (File)
Mon, Apr 28, 10:39 AM
Unknown Object (File)
Mon, Apr 28, 9:59 AM
Unknown Object (File)
Mon, Apr 28, 6:34 AM
Unknown Object (File)
Mon, Apr 28, 1:55 AM
Unknown Object (File)
Sun, Apr 27, 10:06 PM
Unknown Object (File)
Sat, Apr 26, 4:53 PM
Subscribers

Details

Summary

volch is a variable used internally in dsp_ioctl_channel() which
corresponds to either priv->rdch or priv->wrch. As a result, priv->volch
is also a pointer to one of those two channels, but is also not used
anywhere outside dsp_ioctl_channel(). Since the operation of figuring
out which channel we want to operate on inside dsp_ioctl_channel() is
cheap enough, retire volch to avoid unnecessary complexity and
confusion.

While here, rename "volch" to just "ch".

Sponsored by: The FreeBSD Foundation
MFC after: 1 week

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 63744
Build 60628: arc lint + arc unit

Event Timeline

sys/dev/sound/pcm/dsp.c
578

Delete this comment too? It's not adding anything anymore.

700

Can't you just pass NULL here?

christos marked 2 inline comments as done.

Address Mark's comments.

This revision is now accepted and ready to land.Sun, Apr 27, 1:47 PM
This revision was automatically updated to reflect the committed changes.