aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristos Margiolis <christos@FreeBSD.org>2026-06-24 13:47:05 +0000
committerChristos Margiolis <christos@FreeBSD.org>2026-06-24 13:47:05 +0000
commitede0236d3b34a89bae7795f0f45696d4d94ce138 (patch)
tree6db8de181078caf004c86e03b6cfe449a91491fc
parent4c932a4d45fb3130ffa80176f5ff9dcacabd49f1 (diff)
sound: Retire unused SD_F_EQ_PC
This flag is neither set anywhere, nor is there a way to set it from userland, so it is effectively useless, and currently the effect is that EQ can only be enabled for primary playback channels. Retire the flag and keep this behavior, and think later whether we want to allow virtual channels to get their own EQ feeder as well. Sponsored by: The FreeBSD Foundation MFC after: 1 week
-rw-r--r--sys/dev/sound/pcm/feeder_chain.c6
-rw-r--r--sys/dev/sound/pcm/sound.h4
2 files changed, 4 insertions, 6 deletions
diff --git a/sys/dev/sound/pcm/feeder_chain.c b/sys/dev/sound/pcm/feeder_chain.c
index 1dbdf2fcc0e4..dc0788ffb53c 100644
--- a/sys/dev/sound/pcm/feeder_chain.c
+++ b/sys/dev/sound/pcm/feeder_chain.c
@@ -725,10 +725,8 @@ feeder_chain(struct pcm_channel *c)
/* Soft EQ only applicable for PLAY. */
if (cdesc.dummy == 0 &&
- c->direction == PCMDIR_PLAY && (d->flags & SD_F_EQ_ENABLED) &&
- (((d->flags & SD_F_EQ_PC) &&
- !(c->flags & CHN_F_HAS_VCHAN)) ||
- (!(d->flags & SD_F_EQ_PC) && !(c->flags & CHN_F_VIRTUAL))))
+ c->direction == PCMDIR_PLAY &&
+ (d->flags & SD_F_EQ_ENABLED) && !(c->flags & CHN_F_VIRTUAL))
cdesc.use_eq = 1;
if (FEEDFORMAT_NE_REQUIRED(&cdesc)) {
diff --git a/sys/dev/sound/pcm/sound.h b/sys/dev/sound/pcm/sound.h
index 60beee69d1a5..bfb0e259d510 100644
--- a/sys/dev/sound/pcm/sound.h
+++ b/sys/dev/sound/pcm/sound.h
@@ -108,7 +108,7 @@ struct snd_mixer;
/* unused 0x00000100 */
#define SD_F_EQ_ENABLED 0x00000200 /* EQ enabled */
/* unused 0x00000400 */
-#define SD_F_EQ_PC 0x00000800 /* EQ per-channel */
+/* unused 0x00000800 */
#define SD_F_PVCHANS 0x00001000 /* Playback vchans enabled */
#define SD_F_RVCHANS 0x00002000 /* Recording vchans enabled */
@@ -124,7 +124,7 @@ struct snd_mixer;
/* "\011 */ \
"\012EQ_ENABLED" \
/* "\013 */ \
- "\014EQ_PC" \
+ /* "\014 */ \
"\015PVCHANS" \
"\016RVCHANS"