All of lore.kernel.org
 help / color / mirror / Atom feed
From: phucduc.bui@gmail.com
To: Mark Brown <broonie@kernel.org>,
	Thierry Reding <thierry.reding@kernel.org>,
	Jonathan Hunter <jonathanh@nvidia.com>
Cc: Liam Girdwood <lgirdwood@gmail.com>,
	Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
	Sheetal <sheetal@nvidia.com>,
	Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>,
	Takashi Sakamoto <o-takashi@sakamocchi.jp>,
	Kees Cook <kees+treewide@kernel.org>,
	u.kleine-koenig@baylibre.com, Danilo Krummrich <dakr@kernel.org>,
	Rosen Penev <rosenp@gmail.com>,
	Piyush Patle <piyushpatle228@gmail.com>,
	Chen Ni <nichen@iscas.ac.cn>,
	HyeongJun An <sammiee5311@gmail.com>,
	Anupama Kunkulagunta <akunkulagunt@nvidia.com>,
	Peter Ujfalusi <peter.ujfalusi@linux.intel.com>,
	Bjorn Helgaas <bhelgaas@google.com>,
	linux-tegra@vger.kernel.org, linux-sound@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	bui duc phuc <phucduc.bui@gmail.com>
Subject: [PATCH 02/11] ASoC: tegra: tegra186_dspk: Use devm_pm_runtime_enable()
Date: Fri,  4 Dec 2026 18:22:11 +0700	[thread overview]
Message-ID: <20261204112220.63695-3-phucduc.bui@gmail.com> (raw)
In-Reply-To: <20261204112220.63695-1-phucduc.bui@gmail.com>

From: bui duc phuc <phucduc.bui@gmail.com>

Replace pm_runtime_enable() with devm_pm_runtime_enable()
and remove the redundant remove callback.

Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
 sound/soc/tegra/tegra186_dspk.c | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/sound/soc/tegra/tegra186_dspk.c b/sound/soc/tegra/tegra186_dspk.c
index 8896f4f937f6..98c6afdf8a66 100644
--- a/sound/soc/tegra/tegra186_dspk.c
+++ b/sound/soc/tegra/tegra186_dspk.c
@@ -510,6 +510,10 @@ static int tegra186_dspk_platform_probe(struct platform_device *pdev)
 
 	regcache_cache_only(dspk->regmap, true);
 
+	err = devm_pm_runtime_enable(dev);
+	if (err)
+		return err;
+
 	err = devm_snd_soc_register_component(dev, &tegra186_dspk_cmpnt,
 					      tegra186_dspk_dais,
 					      ARRAY_SIZE(tegra186_dspk_dais));
@@ -517,16 +521,9 @@ static int tegra186_dspk_platform_probe(struct platform_device *pdev)
 		return dev_err_probe(dev, err,
 				     "can't register DSPK component\n");
 
-	pm_runtime_enable(dev);
-
 	return 0;
 }
 
-static void tegra186_dspk_platform_remove(struct platform_device *pdev)
-{
-	pm_runtime_disable(&pdev->dev);
-}
-
 static const struct dev_pm_ops tegra186_dspk_pm_ops = {
 	RUNTIME_PM_OPS(tegra186_dspk_runtime_suspend,
 		       tegra186_dspk_runtime_resume, NULL)
@@ -540,7 +537,6 @@ static struct platform_driver tegra186_dspk_driver = {
 		.pm = pm_ptr(&tegra186_dspk_pm_ops),
 	},
 	.probe = tegra186_dspk_platform_probe,
-	.remove = tegra186_dspk_platform_remove,
 };
 module_platform_driver(tegra186_dspk_driver);
 
-- 
2.43.0


  parent reply	other threads:[~2026-12-04 11:23 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-04 11:22 [PATCH 00/11] ASoC: tegra: Use devm_pm_runtime_enable() phucduc.bui
2026-12-04 11:22 ` [PATCH 01/11] ASoC: tegra: asrc: " phucduc.bui
2026-12-04 12:28   ` Thierry Reding
2026-12-05  9:17     ` Bui Duc Phuc
2026-12-04 11:22 ` phucduc.bui [this message]
2026-12-04 11:22 ` [PATCH 03/11] ASoC: tegra: tegra210_adx: " phucduc.bui
2026-12-04 11:22 ` [PATCH 04/11] ASoC: tegra: tegra210_ahub: " phucduc.bui
2026-12-04 11:22 ` [PATCH 05/11] ASoC: tegra: tegra210_amx: " phucduc.bui
2026-12-04 11:22 ` [PATCH 06/11] ASoC: tegra: tegra210_dmic: " phucduc.bui
2026-12-04 11:22 ` [PATCH 07/11] ASoC: tegra: tegra210_i2s: " phucduc.bui
2026-12-04 11:22 ` [PATCH 08/11] ASoC: tegra: tegra210_mixer: " phucduc.bui
2026-12-04 11:22 ` [PATCH 09/11] ASoC: tegra: tegra210_mvc: " phucduc.bui
2026-12-04 11:22 ` [PATCH 10/11] ASoC: tegra: tegra210_ope: " phucduc.bui
2026-12-04 11:22 ` [PATCH 11/11] ASoC: tegra: tegra210_sfc: " phucduc.bui
2026-12-04 12:29 ` [PATCH 00/11] ASoC: tegra: " Thierry Reding

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=20261204112220.63695-3-phucduc.bui@gmail.com \
    --to=phucduc.bui@gmail.com \
    --cc=akunkulagunt@nvidia.com \
    --cc=bhelgaas@google.com \
    --cc=broonie@kernel.org \
    --cc=dakr@kernel.org \
    --cc=jonathanh@nvidia.com \
    --cc=kees+treewide@kernel.org \
    --cc=kuninori.morimoto.gx@renesas.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=nichen@iscas.ac.cn \
    --cc=o-takashi@sakamocchi.jp \
    --cc=perex@perex.cz \
    --cc=peter.ujfalusi@linux.intel.com \
    --cc=piyushpatle228@gmail.com \
    --cc=rosenp@gmail.com \
    --cc=sammiee5311@gmail.com \
    --cc=sheetal@nvidia.com \
    --cc=thierry.reding@kernel.org \
    --cc=tiwai@suse.com \
    --cc=u.kleine-koenig@baylibre.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.