summaryrefslogtreecommitdiff
path: root/sound/soc/mediatek
AgeCommit message (Collapse)Author
6 daysASoC: mediatek: mt8365-mt6357: remove useless assignmentKuninori Morimoto
static int mt8365_mt6357_dev_probe(...) { ... struct device *dev = card->dev; ... => card->dev = dev; ... } This is useless. Remove it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://patch.msgid.link/87wlupi0sg.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
6 daysASoC: mediatek: mt8196-nau8825: remove unnecessary declarationKuninori Morimoto
No need to declarate mt8196_nau8825_soc_card. Remove it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://patch.msgid.link/87y0f5i0sl.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
6 daysASoC: mediatek: common/mtk-dsp-sof-common: use for_each_card_prelinks()Kuninori Morimoto
We already have for_each_card_prelinks(). Let's use it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://patch.msgid.link/87zezli0sp.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
6 daysASoC: mediatek: mt8192-mt6359-rt1015-rt5682: use *dev in ↵Kuninori Morimoto
mt8192_mt6359_card_set_be_link() use *dev, instead of card->dev. No functional change, but is preparation for cleanup driver. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Link: https://patch.msgid.link/871pcxjfd9.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
10 daysASoC: mediatek: mt8189: Remove redundant else-if branch with identical bodywangdicheng
Fix a compiler warning about a condition with no effect: sound/mediatek/mt8189/mt8189-dai-adda.c:388:7-9: WARNING: possible condition with no effect (if == else) The MTKAIF_PROTOCOL_2 branch and the else branch both write the same value 0xB0 to AFE_AUD_PAD_TOP_CFG0, making the else-if condition meaningless. Remove the redundant branch. Signed-off-by: wangdicheng <wangdicheng@kylinos.cn> Link: https://patch.msgid.link/20260717091542.721877-2-wangdich9700@163.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-06ASoC: cs35l3x: drain threaded IRQs before runtime suspendMark Brown
Runyu Xiao <runyu.xiao@seu.edu.cn> says: Both cs35l33 and cs35l34 can enter runtime suspend while their threaded IRQ handlers are still reachable. The suspend path then switches the driver into regcache cache-only mode and powers the codec down, while the IRQ thread still expects live status-register access. This issue was found by our static analysis tool and manually audited on Linux v6.18.21. Directed QEMU no-device validation further showed that, after runtime_suspend() completed, the real threaded handlers could still be injected and would continue past volatile regmap read failures into their release/update paths. This series keeps the fix on the suspend actor and applies the same runtime-suspend/threaded-IRQ ordering repair boundary to both drivers: - track whether request_threaded_irq() actually succeeded - disable_irq() before cache_only/power-off in runtime suspend - enable_irq() only after regcache_sync() in runtime resume That drains any in-flight threaded handler and blocks new IRQ handling while the codec is suspended, without mixing in larger IRQ-thread defensive cleanups. Build-tested by compiling cs35l33.o and cs35l34.o. No cs35l33/cs35l34 hardware was available for end-to-end runtime testing. Link: https://patch.msgid.link/20260611161553.3378721-1-runyu.xiao@seu.edu.cn
2026-07-03ASoC: mediatek: mt8365-mt6357: tidyup mach_privKuninori Morimoto
It sets soc_card_data (1) in Card private data at (A), but the function (z) after that gets it as priv (2) at (B). These are different data (*). (z) static int mt8365_mt6357_gpio_probe(...) { (B) struct mt8365_mt6357_priv *priv = snd_soc_card_get_drvdata(card); ... ^^^^(2) ^^^^^^^^^^^ } static int mt8365_mt6357_dev_probe(*soc_card_data, ...) { ^^^^^^^^^^^^^(1) ... struct mt8365_mt6357_priv *mach_priv; ... ^^^^^^^^^(2) (*) soc_card_data->mach_priv = mach_priv; ^^^^^^^^^^^^^(1) ^^^^^^^^^(2) (A) snd_soc_card_set_drvdata(card, soc_card_data); ^^^^^^^^^^^ ^^^^^^^^^^^^^(1) (z) mt8365_mt6357_gpio_probe(card); ... } Depending on the defined order in the struct (s), they may be the same pointer, but mach_priv (2) is not top of soc_card_data (1), thus the function (z) is getting wrong pointer. Fix it. (1) (s) struct mtk_soc_card_data { const struct mtk_sof_priv *sof_priv; ... void *mach_priv; }; (2) Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87qzlteuae.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-07-03Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c ↵Uwe Kleine-König (The Capable Hub)
files) Replace the #include of <linux/mod_devicetable.h> by the more specific <linux/device-id/*.h> where applicable. For most cases the include can be dropped completely, only a few drivers need one or two headers added. Acked-by: Danilo Krummrich <dakr@kernel.org> Acked-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Link: https://patch.msgid.link/1a3f2007c5c5dcf555c09a4035ce3ae8ef1b6c49.1782808461.git.u.kleine-koenig@baylibre.com Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com>
2026-07-01ASoC: mediatek: mt8173-rt5650: tidyup error messageKuninori Morimoto
mt8173_rt5650_dev_probe() has strange error message => ret = device_property_read_u32(...); ^^^^^^^^^^^^^^^^^^^^^^^^ if (ret) => dev_err(... "%s snd_soc_register_card fail %d\n", ...); ^^^^^^^^^^^^^^^^^^^^^ It should be "device_property_read_u32() fail". Fix it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/875x2zcjxn.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-30ASoC: mediatek: mt2701: add COMPILE_TESTRosen Penev
Enable COMPILE_TEST for mt2701 to get extra build coverage as done with other mediatek platforms. Signed-off-by: Rosen Penev <rosenp@gmail.com> Link: https://patch.msgid.link/20260630013024.1500623-1-rosenp@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-12ASoC: mediatek: tidyup detailsMark Brown
Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> says: These are tidyup details of mediatek drivers. Basically there is no functional change. This is prepare for later Card capsuling. This makes code review easy when Card capsuling happen. Kuninori Morimoto (6): Link: https://patch.msgid.link/87ik7tesdw.wl-kuninori.morimoto.gx@renesas.com
2026-06-12ASoC: mediatek: mt8365_mt6357: use *dev in mt8365_mt6357_gpio_probe()Kuninori Morimoto
use *dev, instead of card->dev. No functional change, but is preparation for cleanup driver. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87a4t5escw.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-12ASoC: mediatek: mt8186-mt6366: use *dev in mt8186_mt6366_soc_card_probe()Kuninori Morimoto
use *dev, instead of card->dev. No functional change, but is preparation for cleanup driver. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87bjdlesd0.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-12ASoC: mediatek: mt8186-mt6366: tidyup mt8186_mt6366_card_set_be_link()Kuninori Morimoto
mt8186_mt6366_card_set_be_link() requests *card, but necessary is card->dev. Tidyup it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87cxy1esd4.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-12ASoC: mediatek: mtk-soundcard-driver: tidyup set_dailink_daifmt()Kuninori Morimoto
card is not used. Remove it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87ecihesd8.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-12ASoC: mediatek: mtk-soundcard-driver: tidyup set_card_codec_info()Kuninori Morimoto
set_card_codec_info() requests *card, but necessary is card->dev. Tidyup it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87fr2xesdc.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-12ASoC: mediatek: cleanup mtk_sof_dailink_parse_of() paramKuninori Morimoto
mtk_sof_dailink_parse_of() is using unnecessarily complicated parameters. Let's cleanup it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87h5ndesdg.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: Use guard() for mutex & spin locksMark Brown
bui duc phuc <phucduc.bui@gmail.com> says: This series converts mutex and spinlock handling in Mediatek ASoC drivers to use guard() helpers. Most patches are straightforward conversions to guard() helpers with no functional change intended. One exception is mt8192-afe-gpio, where the mutex release point moves from immediately before dev_warn() to scope exit. However, the affected path only emits a warning and immediately returns -EINVAL, without any further processing. Compile-tested only. Link: https://patch.msgid.link/20260610102021.83273-1-phucduc.bui@gmail.com
2026-06-11ASoC: mediatek: mt8195: mt8365-dai-i2s: Use guard() for spin locksbui duc phuc
Clean up the code using guard() for spin locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-11-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: mt8195: mt8365-dai-adda: Use guard() for spin locksbui duc phuc
Clean up the code using guard() for spin locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-10-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: mt8195: mt8365-afe-clk: Use guard() for mutex & spin locksbui duc phuc
Clean up the code using guard() for mutex & spin locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-9-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: mt8195: mt8195-dai-etdm: Use guard() for spin locksbui duc phuc
Clean up the code using guard() for spin locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-8-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: mt8195: mt8195-afe-clk: Use guard() for spin locksbui duc phuc
Clean up the code using guard() for spin locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-7-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: mt8192: mt8192-afe-gpio: Use guard() for mutex locksbui duc phuc
Convert the explicit mutex_lock()/mutex_unlock() pair to guard(mutex) to simplify the locking logic and automatically release the mutex on all exit paths. This changes the mutex release point from immediately before dev_warn() to automatic cleanup at scope exit. However, the affected path only emits a warning and immediately returns -EINVAL, without any further processing. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-6-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: mt8188: mt8188-afe-clk: Use guard() for spin locksbui duc phuc
Clean up the code using guard() for spin locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-5-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: mt8186: mt8186-afe-gpio: Use guard() for mutex locksbui duc phuc
Clean up the code using guard() for mutex locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-4-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: common: mtk-btcvsd: Use guard() for spin locksbui duc phuc
Clean up the code using guard() for spin locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-3-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-11ASoC: mediatek: common: mtk-afe-fe-dai: Use guard() for mutex locksbui duc phuc
Clean up the code using guard() for mutex locks. Merely code refactoring, and no behavior change. Signed-off-by: bui duc phuc <phucduc.bui@gmail.com> Link: https://patch.msgid.link/20260610102021.83273-2-phucduc.bui@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-10ASoC: remove .debugfs_prefix from ComponentMark Brown
Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> says: Basically, we are assuming to use snd_soc_register_component() (X) to register Component. It requests Component driver (A). And, current Component has .debugfs_prefix (B). Now we can set component->debugfs_prefix (B) via component_driver->debugfs_prefix (A) today. But some drivers are still trying to set it via (B). Thus, they need to use snd_soc_component_initialize() (1) / snd_soc_component_add() (2) instead of (X), because they need to access component->debugfs_prefix (B). These functions (= 1, 2) should be capsuled into soc-xxx.c, but can't because of above drivers. This patch-set removes component->debugfs_prefix (B). The functions (= 1, 2) are still not yet be capsuled. This is step1 for it, step2 will be posted after this. Link: https://patch.msgid.link/87ldcxk5wz.wl-kuninori.morimoto.gx@renesas.com
2026-06-10ASoC: mediatek: mt8173-afe-pcm: set debugfs_prefix via Component driverKuninori Morimoto
We can set component->debugfs_prefix via component_driver->debugfs_prefix. Use it. Now it no longer need to use snd_soc_component_initialize() / snd_soc_component_add(). use snd_soc_component_register() instead. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87ecipk5vo.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-08ASoC: mediatek: mt8365-afe-pcm: fix possible NULL-pointer dereferences in ↵Tuo Li
mt8365_afe_suspend() mt8365_afe_suspend() allocates the register backup buffer with devm_kcalloc(), but does not check for allocation failure before using the returned pointer. This may lead to a NULL pointer dereference when accessing afe->reg_back_up[i]. Add the missing NULL check and return -ENOMEM on allocation failure after disabling the main clock. Also propagate the return value of mt8365_afe_suspend() in mt8365_afe_dev_runtime_suspend() so that the suspended state is not updated when suspend fails. Signed-off-by: Tuo Li <islituo@gmail.com> Link: https://patch.msgid.link/20260528064107.470824-1-islituo@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-02ASoC: mediatek: mt8192 probe cleanupMark Brown
Cássio Gabriel <cassiogabrielcontato@gmail.com> says: Fix two MT8192 AFE probe cleanup issues that mirror the recently fixed MT8189 and MT8196 paths. The first patch registers a devm cleanup action for a successful reserved-memory assignment so later probe failures and driver unbind release it. The second patch checks the temporary runtime resume used while reinitializing the regmap cache and makes the regcache failure path drop the PM reference and clear pm_runtime_bypass_reg_ctl. Link: https://patch.msgid.link/20260527-asoc-mt8192-probe-cleanup-v1-0-1bb834d05b72@gmail.com
2026-06-02ASoC: mediatek: mt8192: Check runtime resume during probeCássio Gabriel
The MT8192 AFE probe enables runtime PM temporarily while reinitializing the regmap cache from hardware, but it uses pm_runtime_get_sync() without checking the return value. If runtime resume fails, probe keeps going without the device necessarily being accessible, and pm_runtime_get_sync() may leave the PM usage count incremented. The regmap_reinit_cache() failure path also returns before dropping the temporary PM reference and before clearing pm_runtime_bypass_reg_ctl. Use pm_runtime_resume_and_get() so resume failures do not leak a usage count, and clear the temporary bypass flag after dropping the probe PM reference on all regmap_reinit_cache() outcomes. Fixes: 125ab5d588b0 ("ASoC: mediatek: mt8192: add platform driver") Cc: stable@vger.kernel.org Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com> Link: https://patch.msgid.link/20260527-asoc-mt8192-probe-cleanup-v1-2-1bb834d05b72@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-02ASoC: mediatek: mt8192: Release reserved memory on cleanupCássio Gabriel
The MT8192 AFE probe calls of_reserved_mem_device_init() and falls back to preallocated buffers when no reserved memory region is available. When the reserved memory assignment succeeds, however, the driver never releases it. Register a devm cleanup action after a successful reserved-memory assignment so the assignment is released on probe failure and driver unbind. Fixes: ec4a10ca4a68 ("ASoC: mediatek: use reserved memory or enable buffer pre-allocation") Cc: stable@vger.kernel.org Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com> Link: https://patch.msgid.link/20260527-asoc-mt8192-probe-cleanup-v1-1-1bb834d05b72@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-02ASoC: mediatek: mt8183: Fix probe resource cleanupMark Brown
Cássio Gabriel <cassiogabrielcontato@gmail.com> says: The MT8183 AFE probe has two cleanup gaps that match issues recently fixed in newer MediaTek AFE drivers. First, reserved memory assigned with of_reserved_mem_device_init() is never released on driver removal or later probe failures. Second, the probe-time runtime PM resume used before reinitializing the regmap cache is unchecked, and a regmap_reinit_cache() failure skips the temporary PM put. Fix both issues with a devm reserved-memory release action and checked runtime PM resume handling. Link: https://patch.msgid.link/20260527-asoc-mt8183-probe-cleanup-v1-0-4f4f5593c8d1@gmail.com
2026-06-02ASoC: mediatek: mt8183: Check runtime resume during probeCássio Gabriel
The MT8183 AFE probe uses pm_runtime_get_sync() before reading hardware defaults into the regmap cache, but does not check whether runtime resume failed. If regmap_reinit_cache() then fails, the temporary runtime PM usage count is also not released. Use pm_runtime_resume_and_get() so resume failures abort probe without leaking a usage count, and release the temporary reference before handling the regmap cache result. Fixes: a94aec035a12 ("ASoC: mediatek: mt8183: add platform driver") Cc: stable@vger.kernel.org Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com> Link: https://patch.msgid.link/20260527-asoc-mt8183-probe-cleanup-v1-2-4f4f5593c8d1@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-02ASoC: mediatek: mt8183: Release reserved memory on cleanupCássio Gabriel
The MT8183 AFE probe can assign reserved memory with of_reserved_mem_device_init(), but the assignment is never released on driver removal or later probe failures. Register a devm cleanup action so the reserved memory assignment is released consistently, matching newer Mediatek AFE drivers. Fixes: ec4a10ca4a68 ("ASoC: mediatek: use reserved memory or enable buffer pre-allocation") Cc: stable@vger.kernel.org Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com> Link: https://patch.msgid.link/20260527-asoc-mt8183-probe-cleanup-v1-1-4f4f5593c8d1@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-06-01ASoC: mediatek: mt2701: fix snprintf boundsRosen Penev
For whatever reason, GCC is unable to figure out that i2s_num is a single digit number, with MT2701_BASE_CLK_NUM being the maximum value it represents. Add a min() call to help it out and fix W=1 errors regarding snprintf bounds. Signed-off-by: Rosen Penev <rosenp@gmail.com> Link: https://patch.msgid.link/20260522014515.719973-1-rosenp@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-28ASoC: soc-card: add snd_soc_card_set_topology_name()Kuninori Morimoto
Some drivers want to use topology name, but currently each drivers are setting it by own method. This patch adds new snd_soc_card_set_topology_name() and do it by same method. Almost all driver doesn't set topology name, let's remove fixed name array, and use devm_kasprintf() instead. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Reviewed-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Link: https://patch.msgid.link/878q942wce.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-27ASoC: mediatek: mt2701: allocate i2s_path with privRosen Penev
Use a flexible array member to combine allocations. Clean up surrounding code and allocate based on afe_priv and not platform_priv which is a void pointer. struct_size needs a properly typed pointer to work. Signed-off-by: Rosen Penev <rosenp@gmail.com> Link: https://patch.msgid.link/20260519010413.629214-1-rosenp@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-25ASoC: codecs: max98090: switch to standard set_jack callbackMark Brown
Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com> says: The MAX98090 codec driver currently exposes a custom max98090_mic_detect() helper for machine drivers to register a headset jack. This series converts the driver to use the standard component .set_jack callback and updates the mt8173-max98090 machine driver to use snd_soc_component_set_jack() instead of the codec-specific helper. Using the standard callback removes the need for a custom exported symbol and allows machine drivers to use the common ASoC jack registration interface. This also improves compatibility with machine drivers, such as Qualcomm platforms, that already rely on snd_soc_component_set_jack(). Link: https://patch.msgid.link/20260520155002.145306-1-srinivas.kandagatla@oss.qualcomm.com
2026-05-25ASoC: mt8173-max98090: use standard callback to set jackSrinivas Kandagatla
use snd_soc_component_set_jack() instead of custom callback to max98090 codec. This will help other drivers using the standard callback to exercise the standard path instead of custom callback. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com> Link: https://patch.msgid.link/20260520155002.145306-2-srinivas.kandagatla@oss.qualcomm.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-22ASoC: mediatek: mt8189: Fix probe resource cleanupCássio Gabriel
The MT8189 AFE probe assigns reserved memory with of_reserved_mem_device_init(), but only releases that assignment from .remove(). If probe fails after the reserved memory has been assigned, the assignment record is left behind. The probe path also uses pm_runtime_get_sync() without checking its return value. If runtime resume fails, pm_runtime_get_sync() leaves the usage count incremented and the driver continues initialization without the device being resumed. Use pm_runtime_resume_and_get() so resume errors abort probe without leaking a PM usage count. Finally, component registration failure currently jumps to a label that drops a runtime PM reference even though the temporary probe reference was already released. Return the component registration error directly, and do not drop an unmatched PM reference from .remove(). Fixes: 7eb153585598 ("ASoC: mediatek: mt8189: add platform driver") Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com> Link: https://patch.msgid.link/20260514-asoc-mt8189-probe-cleanup-v1-1-ded733363281@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-18ASoC: mediatek: mt8196: Fix probe resource cleanupCássio Gabriel
The MT8196 AFE probe assigns reserved memory with of_reserved_mem_device_init(), but never releases it. This leaks the reserved memory assignment on driver removal and on later probe failures. The same probe path also uses unchecked pm_runtime_get_sync() calls. A failure while resuming the device can leave the runtime PM usage count in an unexpected state. The regmap error path returns directly while the device is still runtime active, and the remove path drops a runtime PM reference even though successful probe has already released its temporary reference. Register a devm cleanup action for the reserved memory assignment, use pm_runtime_resume_and_get(), and only drop runtime PM references on paths where they are actually held. Fixes: 57513aabfe5b ("ASoC: mediatek: mt8196: add platform driver") Signed-off-by: Cássio Gabriel <cassiogabrielcontato@gmail.com> Link: https://patch.msgid.link/20260517-asoc-mt8196-probe-cleanup-v1-1-a5d26949d7fe@gmail.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-05ASoC: mediatek: Add support for MT8196 SoCMark Brown
Cyril Chao <Cyril.Chao@mediatek.com> says: This series of patches adds support for Mediatek AFE of MT8196 SoC.
2026-05-05ASoC: mediatek: mt8196: add machine driver with nau8825Darren Ye
Add support for mt8196 board with nau8825. Signed-off-by: Darren Ye <darren.ye@mediatek.com> Signed-off-by: Cyril Chao <Cyril.Chao@mediatek.com> Link: https://patch.msgid.link/20260430022417.32282-11-Cyril.Chao@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-05ASoC: mediatek: mt8196: add platform driverDarren Ye
Add mt8196 platform driver. Signed-off-by: Darren Ye <darren.ye@mediatek.com> Signed-off-by: Cyril Chao <Cyril.Chao@mediatek.com> Link: https://patch.msgid.link/20260430022417.32282-9-Cyril.Chao@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-05ASoC: mediatek: mt8196: support TDM in platform driverDarren Ye
Add mt8196 TDM DAI driver support. Signed-off-by: Darren Ye <darren.ye@mediatek.com> Signed-off-by: Cyril Chao <Cyril.Chao@mediatek.com> Link: https://patch.msgid.link/20260430022417.32282-7-Cyril.Chao@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-05ASoC: mediatek: mt8196: support I2S in platform driverDarren Ye
Add mt8196 I2S DAI driver support. Signed-off-by: Darren Ye <darren.ye@mediatek.com> Signed-off-by: Cyril Chao <Cyril.Chao@mediatek.com> Link: https://patch.msgid.link/20260430022417.32282-6-Cyril.Chao@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org>
2026-05-05ASoC: mediatek: mt8196: support ADDA in platform driverDarren Ye
Add mt8196 ADDA DAI driver support. Signed-off-by: Darren Ye <darren.ye@mediatek.com> Signed-off-by: Cyril Chao <Cyril.Chao@mediatek.com> Link: https://patch.msgid.link/20260430022417.32282-5-Cyril.Chao@mediatek.com Signed-off-by: Mark Brown <broonie@kernel.org>