ASoC: SOF: Do nothing when DSP PM callbacks are not set
authorDaniel Baluta <daniel.baluta@nxp.com>
Fri, 15 May 2020 13:59:51 +0000 (16:59 +0300)
committerMark Brown <broonie@kernel.org>
Mon, 18 May 2020 12:24:53 +0000 (13:24 +0100)
commitc26fde3b15ed41f5f452f1da727795f787833287
treeae1cd132cc3f8b5bb170755eab907310e22931ac
parentd731c1a0f935dbebf4a851e072f8c7309eb2b8c5
ASoC: SOF: Do nothing when DSP PM callbacks are not set

This provides a better separation between runtime and PM sleep
callbacks.

Only do nothing if given runtime flag is set and calback is not set.

With the current implementation, if PM sleep callback is set but runtime
callback is not set then at runtime resume we reload the firmware even
if we do not support runtime resume callback.

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Link: https://lore.kernel.org/r/20200515135958.17511-2-kai.vehmanen@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/sof/pm.c