soundwire: intel: remove DAI startup/shutdown
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Thu, 15 Dec 2022 08:54:36 +0000 (16:54 +0800)
committerVinod Koul <vkoul@kernel.org>
Mon, 9 Jan 2023 16:03:49 +0000 (21:33 +0530)
commit5c2f4c9cfc79028079f0691899a93843827a00b7
treed454af8f8bf295185c2d1060593d88ac0a3e9237
parent1b929c02afd37871d5afb9d498426f83432e71c2
soundwire: intel: remove DAI startup/shutdown

The only thing these DAI startup/shutdown callbacks do is play with
pm_runtime reference counts.

This is not wrong, but it's not necessary at all. At the ASoC core level,
only the component matters for pm_runtime. The ASoC core already calls
pm_runtime_get_sync() in snd_soc_pcm_component_pm_runtime_get(),
before the DAI startup callback is invoked.

None of the SoundWire codec drivers rely on pm_runtime helpers in
their DAI startup/shutdown either. This adds to the evidence that only
the component, or more precisely the device specified when registering
a component, should deal with pm_runtime transitions.

Beyond the code cleanup, this move prepares for the addition of link
power management in the auxiliary device startup/resume/suspend
callbacks. The DAI callbacks can by-design assume that the device is
already pm_runtime active.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Rander Wang <rander.wang@intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Link: https://lore.kernel.org/r/20221215085436.2001568-1-yung-chuan.liao@linux.intel.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/soundwire/intel.c