lkml.org 
[lkml]   [2024]   [Jan]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 7/7] ASoC: mediatek: mt8195-afe-pcm: Drop .remove_new() callback
Date
As we're calling devm_pm_runtime_enable() in the probe function of this
driver we don't need to disable it on remove as that's devm managed:
drop the .remove_new() callback entirely.

While at it, also add the sentinel comment to the last of_device_id
entry.

Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
---
sound/soc/mediatek/mt8195/mt8195-afe-pcm.c | 12 ++----------
1 file changed, 2 insertions(+), 10 deletions(-)

diff --git a/sound/soc/mediatek/mt8195/mt8195-afe-pcm.c b/sound/soc/mediatek/mt8195/mt8195-afe-pcm.c
index 620d7ade1992..de848d872ce6 100644
--- a/sound/soc/mediatek/mt8195/mt8195-afe-pcm.c
+++ b/sound/soc/mediatek/mt8195/mt8195-afe-pcm.c
@@ -3193,16 +3193,9 @@ static int mt8195_afe_pcm_dev_probe(struct platform_device *pdev)
return ret;
}

-static void mt8195_afe_pcm_dev_remove(struct platform_device *pdev)
-{
- pm_runtime_disable(&pdev->dev);
- if (!pm_runtime_status_suspended(&pdev->dev))
- mt8195_afe_runtime_suspend(&pdev->dev);
-}
-
static const struct of_device_id mt8195_afe_pcm_dt_match[] = {
- {.compatible = "mediatek,mt8195-audio", },
- {},
+ { .compatible = "mediatek,mt8195-audio" },
+ { /* sentinel */ },
};
MODULE_DEVICE_TABLE(of, mt8195_afe_pcm_dt_match);

@@ -3218,7 +3211,6 @@ static struct platform_driver mt8195_afe_pcm_driver = {
.pm = &mt8195_afe_pm_ops,
},
.probe = mt8195_afe_pcm_dev_probe,
- .remove_new = mt8195_afe_pcm_dev_remove,
};

module_platform_driver(mt8195_afe_pcm_driver);
--
2.43.0

\
 
 \ /
  Last update: 2024-01-11 11:54    [W:0.033 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site