* [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs.
@ 2026-09-24 5:53 Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 1/3] soundwire: intel_auxdevice: add rt766/rt767 codec to wake_capable_list Shuming Fan via B4 Relay
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: Shuming Fan via B4 Relay @ 2026-09-24 5:53 UTC (permalink / raw)
To: broonie, lgirdwood
Cc: Shuming Fan, derek.fang, lars, oder_chiou, linux-sound, flove,
jack.yu
This series adds the required codec information and codec-specific DAPM routes,
enables wake capability on Intel platforms, and avoids re-initializing blind writes.
The series includes:
Add RT766 and RT767 to the SoundWire wake-capable codec list.
Add RT766 and RT767 codec information to sdw_utils.
Add support for codec versions 3 and 4.
Add the RT766 speaker and headset DAPM routes.
Avoid re-initializing blind writes.
With these changes, the generic SoundWire machine driver can recognize the RT766/RT767
codecs and set up the corresponding ASoC DAI links and codec routes.
Signed-off-by: Shuming Fan <shumingf@realtek.com>
---
Changes in v2:
- use b4 command to send this series and add a cover letter
---
Shuming Fan (3):
soundwire: intel_auxdevice: add rt766/rt767 codec to wake_capable_list
ASoC: sdw_utils: Add rt766/rt767 support
ASoC: rt766: avoid re-initialize the blind write
drivers/soundwire/intel_auxdevice.c | 2 +
sound/soc/codecs/rt766-sdca.c | 2 +-
sound/soc/sdw_utils/soc_sdw_rt_mf_sdca.c | 6 +
sound/soc/sdw_utils/soc_sdw_rt_sdca_jack_common.c | 8 +
sound/soc/sdw_utils/soc_sdw_utils.c | 172 ++++++++++++++++++++++
5 files changed, 189 insertions(+), 1 deletion(-)
---
base-commit: 782424a17d77ae6de07b490618b523066c528f59
change-id: 20260924-rt766-e20c3019ad0f
Best regards,
--
Shuming Fan <shumingf@realtek.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v2 1/3] soundwire: intel_auxdevice: add rt766/rt767 codec to wake_capable_list
2026-09-24 5:53 [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs Shuming Fan via B4 Relay
@ 2026-09-24 5:53 ` Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 2/3] ASoC: sdw_utils: Add rt766/rt767 support Shuming Fan via B4 Relay
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Shuming Fan via B4 Relay @ 2026-09-24 5:53 UTC (permalink / raw)
To: broonie, lgirdwood
Cc: Shuming Fan, derek.fang, lars, oder_chiou, linux-sound, flove,
jack.yu
From: Shuming Fan <shumingf@realtek.com>
rt766/rt767 have wake capability. Add it to the wake_capable_list.
Signed-off-by: Shuming Fan <shumingf@realtek.com>
---
drivers/soundwire/intel_auxdevice.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/soundwire/intel_auxdevice.c b/drivers/soundwire/intel_auxdevice.c
index a8407560bf4f..bcf94ea38cab 100644
--- a/drivers/soundwire/intel_auxdevice.c
+++ b/drivers/soundwire/intel_auxdevice.c
@@ -73,6 +73,8 @@ static struct wake_capable_part wake_capable_list[] = {
{0x025d, 0x717},
{0x025d, 0x721},
{0x025d, 0x722},
+ {0x025d, 0x766},
+ {0x025d, 0x767},
{0x04b3, 0x9356},
};
--
2.55.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH v2 2/3] ASoC: sdw_utils: Add rt766/rt767 support
2026-09-24 5:53 [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 1/3] soundwire: intel_auxdevice: add rt766/rt767 codec to wake_capable_list Shuming Fan via B4 Relay
@ 2026-09-24 5:53 ` Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 3/3] ASoC: rt766: avoid re-initialize the blind write Shuming Fan via B4 Relay
2026-09-24 18:46 ` (subset) [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs Mark Brown
3 siblings, 0 replies; 5+ messages in thread
From: Shuming Fan via B4 Relay @ 2026-09-24 5:53 UTC (permalink / raw)
To: broonie, lgirdwood
Cc: Shuming Fan, derek.fang, lars, oder_chiou, linux-sound, flove,
jack.yu
From: Shuming Fan <shumingf@realtek.com>
This patch adds the codec_info and route-related settings.
Signed-off-by: Shuming Fan <shumingf@realtek.com>
---
sound/soc/sdw_utils/soc_sdw_rt_mf_sdca.c | 6 +
sound/soc/sdw_utils/soc_sdw_rt_sdca_jack_common.c | 8 +
sound/soc/sdw_utils/soc_sdw_utils.c | 172 ++++++++++++++++++++++
3 files changed, 186 insertions(+)
diff --git a/sound/soc/sdw_utils/soc_sdw_rt_mf_sdca.c b/sound/soc/sdw_utils/soc_sdw_rt_mf_sdca.c
index 5bf3627a97a0..6e5fa93b5fc2 100644
--- a/sound/soc/sdw_utils/soc_sdw_rt_mf_sdca.c
+++ b/sound/soc/sdw_utils/soc_sdw_rt_mf_sdca.c
@@ -33,6 +33,11 @@ static const struct snd_soc_dapm_route rt722_spk_map[] = {
{ "Speaker", NULL, "rt722 SPK" },
};
+static const struct snd_soc_dapm_route rt766_spk_map[] = {
+ { "Speaker", NULL, "rt766 SPOL" },
+ { "Speaker", NULL, "rt766 SPOR" },
+};
+
/* Structure to map codec names to respective route arrays and sizes */
struct codec_route_map {
const char *codec_name;
@@ -45,6 +50,7 @@ static const struct codec_route_map codec_routes[] = {
{ "rt712", rt712_spk_map, ARRAY_SIZE(rt712_spk_map) },
{ "rt721", rt721_spk_map, ARRAY_SIZE(rt721_spk_map) },
{ "rt722", rt722_spk_map, ARRAY_SIZE(rt722_spk_map) },
+ { "rt766", rt766_spk_map, ARRAY_SIZE(rt766_spk_map) },
};
static const struct codec_route_map *get_codec_route_map(const char *codec_name)
diff --git a/sound/soc/sdw_utils/soc_sdw_rt_sdca_jack_common.c b/sound/soc/sdw_utils/soc_sdw_rt_sdca_jack_common.c
index 2547b5b3fdd7..b4e427d55130 100644
--- a/sound/soc/sdw_utils/soc_sdw_rt_sdca_jack_common.c
+++ b/sound/soc/sdw_utils/soc_sdw_rt_sdca_jack_common.c
@@ -70,6 +70,11 @@ static const struct snd_soc_dapm_route rt722_sdca_map[] = {
{ "rt722 MIC2", NULL, "Headset Mic" },
};
+static const struct snd_soc_dapm_route rt766_sdca_map[] = {
+ { "Headphone", NULL, "rt766 HP" },
+ { "rt766 MIC2", NULL, "Headset Mic" },
+};
+
static struct snd_soc_jack_pin rt_sdca_jack_pins[] = {
{
.pin = "Headphone",
@@ -133,6 +138,9 @@ int asoc_sdw_rt_sdca_jack_rtd_init(struct snd_soc_pcm_runtime *rtd, struct snd_s
} else if (strstr(component->name_prefix, "rt722")) {
ret = snd_soc_dapm_add_routes(dapm, rt722_sdca_map,
ARRAY_SIZE(rt722_sdca_map));
+ } else if (strstr(component->name_prefix, "rt766")) {
+ ret = snd_soc_dapm_add_routes(dapm, rt766_sdca_map,
+ ARRAY_SIZE(rt766_sdca_map));
} else {
dev_err(card->dev, "%s is not supported\n", component->name_prefix);
return -EINVAL;
diff --git a/sound/soc/sdw_utils/soc_sdw_utils.c b/sound/soc/sdw_utils/soc_sdw_utils.c
index f0f0822d8ed6..14aee10b40ba 100644
--- a/sound/soc/sdw_utils/soc_sdw_utils.c
+++ b/sound/soc/sdw_utils/soc_sdw_utils.c
@@ -779,6 +779,178 @@ struct asoc_sdw_codec_info codec_info_list[] = {
},
.dai_num = 3,
},
+ {
+ .vendor_id = 0x025d,
+ .part_id = 0x767,
+ .name_prefix = "rt766",
+ .version_id = 3,
+ .dais = {
+ {
+ .direction = {true, true},
+ .dai_name = "rt766-sdca-aif1",
+ .dai_type = SOC_SDW_DAI_TYPE_JACK,
+ .dailink = {SOC_SDW_JACK_OUT_DAI_ID, SOC_SDW_JACK_IN_DAI_ID},
+ .init = asoc_sdw_rt_sdca_jack_init,
+ .exit = asoc_sdw_rt_sdca_jack_exit,
+ .rtd_init = asoc_sdw_rt_sdca_jack_rtd_init,
+ .controls = generic_jack_controls,
+ .num_controls = ARRAY_SIZE(generic_jack_controls),
+ .widgets = generic_jack_widgets,
+ .num_widgets = ARRAY_SIZE(generic_jack_widgets),
+ },
+ {
+ .direction = {true, false},
+ .dai_name = "rt766-sdca-aif2",
+ .component_name = "rt766",
+ .dai_type = SOC_SDW_DAI_TYPE_AMP,
+ .dailink = {SOC_SDW_AMP_OUT_DAI_ID, SOC_SDW_UNUSED_DAI_ID},
+ .init = asoc_sdw_rt_amp_init,
+ .exit = asoc_sdw_rt_amp_exit,
+ .rtd_init = asoc_sdw_rt_mf_sdca_spk_rtd_init,
+ .controls = generic_spk_controls,
+ .num_controls = ARRAY_SIZE(generic_spk_controls),
+ .widgets = generic_spk_widgets,
+ .num_widgets = ARRAY_SIZE(generic_spk_widgets),
+ },
+ {
+ .direction = {false, true},
+ .dai_name = "rt766-sdca-aif3",
+ .dai_type = SOC_SDW_DAI_TYPE_MIC,
+ .dailink = {SOC_SDW_UNUSED_DAI_ID, SOC_SDW_DMIC_DAI_ID},
+ .rtd_init = asoc_sdw_rt_dmic_rtd_init,
+ },
+ },
+ .dai_num = 3,
+ },
+ {
+ .vendor_id = 0x025d,
+ .part_id = 0x767,
+ .name_prefix = "rt766",
+ .version_id = 4,
+ .dais = {
+ {
+ .direction = {true, true},
+ .dai_name = "rt766-sdca-aif1",
+ .dai_type = SOC_SDW_DAI_TYPE_JACK,
+ .dailink = {SOC_SDW_JACK_OUT_DAI_ID, SOC_SDW_JACK_IN_DAI_ID},
+ .init = asoc_sdw_rt_sdca_jack_init,
+ .exit = asoc_sdw_rt_sdca_jack_exit,
+ .rtd_init = asoc_sdw_rt_sdca_jack_rtd_init,
+ .controls = generic_jack_controls,
+ .num_controls = ARRAY_SIZE(generic_jack_controls),
+ .widgets = generic_jack_widgets,
+ .num_widgets = ARRAY_SIZE(generic_jack_widgets),
+ },
+ {
+ .direction = {true, false},
+ .dai_name = "rt766-sdca-aif2",
+ .component_name = "rt766",
+ .dai_type = SOC_SDW_DAI_TYPE_AMP,
+ .dailink = {SOC_SDW_AMP_OUT_DAI_ID, SOC_SDW_UNUSED_DAI_ID},
+ .init = asoc_sdw_rt_amp_init,
+ .exit = asoc_sdw_rt_amp_exit,
+ .rtd_init = asoc_sdw_rt_mf_sdca_spk_rtd_init,
+ .controls = generic_spk_controls,
+ .num_controls = ARRAY_SIZE(generic_spk_controls),
+ .widgets = generic_spk_widgets,
+ .num_widgets = ARRAY_SIZE(generic_spk_widgets),
+ },
+ {
+ .direction = {false, true},
+ .dai_name = "rt766-sdca-aif3",
+ .dai_type = SOC_SDW_DAI_TYPE_MIC,
+ .dailink = {SOC_SDW_UNUSED_DAI_ID, SOC_SDW_DMIC_DAI_ID},
+ .rtd_init = asoc_sdw_rt_dmic_rtd_init,
+ },
+ },
+ .dai_num = 3,
+ },
+ {
+ .vendor_id = 0x025d,
+ .part_id = 0x766,
+ .name_prefix = "rt766",
+ .version_id = 3,
+ .dais = {
+ {
+ .direction = {true, true},
+ .dai_name = "rt766-sdca-aif1",
+ .dai_type = SOC_SDW_DAI_TYPE_JACK,
+ .dailink = {SOC_SDW_JACK_OUT_DAI_ID, SOC_SDW_JACK_IN_DAI_ID},
+ .init = asoc_sdw_rt_sdca_jack_init,
+ .exit = asoc_sdw_rt_sdca_jack_exit,
+ .rtd_init = asoc_sdw_rt_sdca_jack_rtd_init,
+ .controls = generic_jack_controls,
+ .num_controls = ARRAY_SIZE(generic_jack_controls),
+ .widgets = generic_jack_widgets,
+ .num_widgets = ARRAY_SIZE(generic_jack_widgets),
+ },
+ {
+ .direction = {true, false},
+ .dai_name = "rt766-sdca-aif2",
+ .component_name = "rt766",
+ .dai_type = SOC_SDW_DAI_TYPE_AMP,
+ .dailink = {SOC_SDW_AMP_OUT_DAI_ID, SOC_SDW_UNUSED_DAI_ID},
+ .init = asoc_sdw_rt_amp_init,
+ .exit = asoc_sdw_rt_amp_exit,
+ .rtd_init = asoc_sdw_rt_mf_sdca_spk_rtd_init,
+ .controls = generic_spk_controls,
+ .num_controls = ARRAY_SIZE(generic_spk_controls),
+ .widgets = generic_spk_widgets,
+ .num_widgets = ARRAY_SIZE(generic_spk_widgets),
+ },
+ {
+ .direction = {false, true},
+ .dai_name = "rt766-sdca-aif3",
+ .dai_type = SOC_SDW_DAI_TYPE_MIC,
+ .dailink = {SOC_SDW_UNUSED_DAI_ID, SOC_SDW_DMIC_DAI_ID},
+ .rtd_init = asoc_sdw_rt_dmic_rtd_init,
+ },
+ },
+ .dai_num = 3,
+ },
+ {
+ .vendor_id = 0x025d,
+ .part_id = 0x766,
+ .name_prefix = "rt766",
+ .version_id = 4,
+ .dais = {
+ {
+ .direction = {true, true},
+ .dai_name = "rt766-sdca-aif1",
+ .dai_type = SOC_SDW_DAI_TYPE_JACK,
+ .dailink = {SOC_SDW_JACK_OUT_DAI_ID, SOC_SDW_JACK_IN_DAI_ID},
+ .init = asoc_sdw_rt_sdca_jack_init,
+ .exit = asoc_sdw_rt_sdca_jack_exit,
+ .rtd_init = asoc_sdw_rt_sdca_jack_rtd_init,
+ .controls = generic_jack_controls,
+ .num_controls = ARRAY_SIZE(generic_jack_controls),
+ .widgets = generic_jack_widgets,
+ .num_widgets = ARRAY_SIZE(generic_jack_widgets),
+ },
+ {
+ .direction = {true, false},
+ .dai_name = "rt766-sdca-aif2",
+ .component_name = "rt766",
+ .dai_type = SOC_SDW_DAI_TYPE_AMP,
+ .dailink = {SOC_SDW_AMP_OUT_DAI_ID, SOC_SDW_UNUSED_DAI_ID},
+ .init = asoc_sdw_rt_amp_init,
+ .exit = asoc_sdw_rt_amp_exit,
+ .rtd_init = asoc_sdw_rt_mf_sdca_spk_rtd_init,
+ .controls = generic_spk_controls,
+ .num_controls = ARRAY_SIZE(generic_spk_controls),
+ .widgets = generic_spk_widgets,
+ .num_widgets = ARRAY_SIZE(generic_spk_widgets),
+ },
+ {
+ .direction = {false, true},
+ .dai_name = "rt766-sdca-aif3",
+ .dai_type = SOC_SDW_DAI_TYPE_MIC,
+ .dailink = {SOC_SDW_UNUSED_DAI_ID, SOC_SDW_DMIC_DAI_ID},
+ .rtd_init = asoc_sdw_rt_dmic_rtd_init,
+ },
+ },
+ .dai_num = 3,
+ },
{
.vendor_id = 0x019f,
.part_id = 0x8373,
--
2.55.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH v2 3/3] ASoC: rt766: avoid re-initialize the blind write
2026-09-24 5:53 [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 1/3] soundwire: intel_auxdevice: add rt766/rt767 codec to wake_capable_list Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 2/3] ASoC: sdw_utils: Add rt766/rt767 support Shuming Fan via B4 Relay
@ 2026-09-24 5:53 ` Shuming Fan via B4 Relay
2026-09-24 18:46 ` (subset) [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs Mark Brown
3 siblings, 0 replies; 5+ messages in thread
From: Shuming Fan via B4 Relay @ 2026-09-24 5:53 UTC (permalink / raw)
To: broonie, lgirdwood
Cc: Shuming Fan, derek.fang, lars, oder_chiou, linux-sound, flove,
jack.yu
From: Shuming Fan <shumingf@realtek.com>
We only need to check the function_status to determine
whether the system has undergone a cold or warm reboot.
Signed-off-by: Shuming Fan <shumingf@realtek.com>
---
sound/soc/codecs/rt766-sdca.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/rt766-sdca.c b/sound/soc/codecs/rt766-sdca.c
index 5a1c1e10e6d7..28b4118e05c9 100644
--- a/sound/soc/codecs/rt766-sdca.c
+++ b/sound/soc/codecs/rt766-sdca.c
@@ -1297,7 +1297,7 @@ static int rt766_func_initialize(struct rt766_sdca_priv *rt766, struct sdca_func
regmap_read(rt766->regmap, func_status_reg, &func_status);
dev_dbg(dev, "%s, %s func_status=0x%x\n", __func__, func_data->desc->name, func_status);
- if ((func_status & SDCA_CTL_ENTITY_0_FUNCTION_NEEDS_INITIALIZATION) || (!rt766->first_hw_init)) {
+ if ((func_status & SDCA_CTL_ENTITY_0_FUNCTION_NEEDS_INITIALIZATION)) {
ret = sdca_regmap_write_init(dev, rt766->regmap, func_data);
if (ret) {
dev_err(dev, "%s initialization table update failed\n", func_data->desc->name);
--
2.55.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: (subset) [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs.
2026-09-24 5:53 [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs Shuming Fan via B4 Relay
` (2 preceding siblings ...)
2026-09-24 5:53 ` [PATCH v2 3/3] ASoC: rt766: avoid re-initialize the blind write Shuming Fan via B4 Relay
@ 2026-09-24 18:46 ` Mark Brown
3 siblings, 0 replies; 5+ messages in thread
From: Mark Brown @ 2026-09-24 18:46 UTC (permalink / raw)
To: lgirdwood, Shuming Fan
Cc: derek.fang, lars, oder_chiou, linux-sound, flove, jack.yu
On Thu, 24 Sep 2026 13:53:01 +0800, Shuming Fan wrote:
> Add ASoC machine driver support for the RT766 and RT767 codecs.
>
> This series adds the required codec information and codec-specific DAPM routes,
> enables wake capability on Intel platforms, and avoids re-initializing blind writes.
>
> The series includes:
>
> [...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-7.4
Thanks!
[2/3] ASoC: sdw_utils: Add rt766/rt767 support
https://git.kernel.org/broonie/sound/c/8eb2b0c88286
[3/3] ASoC: rt766: avoid re-initialize the blind write
https://git.kernel.org/broonie/sound/c/be190d999369
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2026-09-25 10:14 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-24 5:53 [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 1/3] soundwire: intel_auxdevice: add rt766/rt767 codec to wake_capable_list Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 2/3] ASoC: sdw_utils: Add rt766/rt767 support Shuming Fan via B4 Relay
2026-09-24 5:53 ` [PATCH v2 3/3] ASoC: rt766: avoid re-initialize the blind write Shuming Fan via B4 Relay
2026-09-24 18:46 ` (subset) [PATCH v2 0/3] Add ASoC machine driver support for the RT766 and RT767 codecs Mark Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox