From: HyeongJun An <sammiee5311@gmail.com>
To: Mark Brown <broonie@kernel.org>
Cc: Liam Girdwood <lgirdwood@gmail.com>,
linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org,
HyeongJun An <sammiee5311@gmail.com>,
David Rhodes <david.rhodes@cirrus.com>,
Richard Fitzgerald <rf@opensource.cirrus.com>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
patches@opensource.cirrus.com
Subject: [PATCH 2/6] ASoC: cs42l52: Fix the NG Type Switch bit
Date: Thu, 8 Oct 2026 22:09:48 +0900 [thread overview]
Message-ID: <20261008130953.2446692-3-sammiee5311@gmail.com> (raw)
In-Reply-To: <20261008130953.2446692-1-sammiee5311@gmail.com>
The NG Type Switch enum selects between "Apply Specific" and "Apply
All", which is the NGALL bit. The datasheet puts NGALL at bit 7 of the
Noise Gate Control register. The enum uses bit 6, which is NG, the
noise gate enable owned by the NG Enable Switch. cs42l52.h names it
CS42L52_NG_ENABLE_SHIFT. cs42l56 has the same Noise Gate register and
puts its NG All Switch at bit 7.
So changing the noise gate type turns the noise gate on or off, and
NGALL cannot be set.
Use bit 7.
Fixes: dfe0f98b8d2e ("ASoC: Add support for CS42L52 Codec")
Link: https://statics.cirrus.com/pubs/proDatasheet/CS42L52_F2.pdf
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: HyeongJun An <sammiee5311@gmail.com>
---
sound/soc/codecs/cs42l52.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/cs42l52.c b/sound/soc/codecs/cs42l52.c
index 5f033556099a..1d3334886402 100644
--- a/sound/soc/codecs/cs42l52.c
+++ b/sound/soc/codecs/cs42l52.c
@@ -290,7 +290,7 @@ static const char * const cs42l52_ng_type_text[] = {
};
static SOC_ENUM_SINGLE_DECL(ng_type_enum,
- CS42L52_NOISE_GATE_CTL, 6,
+ CS42L52_NOISE_GATE_CTL, 7,
cs42l52_ng_type_text);
static const char * const left_swap_text[] = {
--
2.43.0
next prev parent reply other threads:[~2026-10-08 13:10 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-08 13:09 [PATCH 0/6] ASoC: Fix controls that write another control's bits HyeongJun An
2026-10-08 13:09 ` [PATCH 1/6] ASoC: cs42l56: Put the Limiter Cushion control on the limiter register HyeongJun An
2026-10-08 13:09 ` HyeongJun An [this message]
2026-10-08 13:09 ` [PATCH 3/6] ASoC: pcm3168a: Fix the DAC zero flag polarity bit HyeongJun An
2026-10-09 10:51 ` Cezary Rojewski
2026-10-08 13:09 ` [PATCH 4/6] ASoC: max98371: Fix the Speaker DHT Min Volume bits HyeongJun An
2026-10-08 13:09 ` [PATCH 5/6] ASoC: wm8978: Fix the 128x oversampling switch bits HyeongJun An
2026-10-08 13:09 ` [PATCH 6/6] ASoC: nau8822: " HyeongJun An
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261008130953.2446692-3-sammiee5311@gmail.com \
--to=sammiee5311@gmail.com \
--cc=broonie@kernel.org \
--cc=david.rhodes@cirrus.com \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=patches@opensource.cirrus.com \
--cc=perex@perex.cz \
--cc=rf@opensource.cirrus.com \
--cc=tiwai@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®