Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 35e03a88 authored by Liam Girdwood's avatar Liam Girdwood Committed by Mark Brown
Browse files

ASoC: Intel: fix build with runtime PM disabled.



Fix the following errors:

All error/warnings:

>> sound/soc/intel/sst-haswell-pcm.c:1168:13: error: 'hsw_pcm_prepare' undeclared here (not in a function)
     .prepare = hsw_pcm_prepare,
                ^
>> sound/soc/intel/sst-haswell-pcm.c:1169:14: error: 'hsw_pcm_complete' undeclared here (not in a function)
     .complete = hsw_pcm_complete,
                 ^
Reported-by: default avatarkbuild test robot <fengguang.wu@intel.com>
Signed-off-by: default avatarLiam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent b891f62f
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -1711,7 +1711,7 @@ void sst_hsw_runtime_module_free(struct sst_module_runtime *runtime)
	sst_module_runtime_free(runtime);
	sst_module_runtime_free(runtime);
}
}


#ifdef CONFIG_PM_RUNTIME
#ifdef CONFIG_PM
static int sst_hsw_dx_state_dump(struct sst_hsw *hsw)
static int sst_hsw_dx_state_dump(struct sst_hsw *hsw)
{
{
	struct sst_dsp *sst = hsw->dsp;
	struct sst_dsp *sst = hsw->dsp;
+6 −8
Original line number Original line Diff line number Diff line
@@ -1058,6 +1058,12 @@ static int hsw_pcm_runtime_resume(struct device *dev)
	return ret;
	return ret;
}
}


#else
#define hsw_pcm_runtime_idle		NULL
#define hsw_pcm_runtime_suspend		NULL
#define hsw_pcm_runtime_resume		NULL
#endif

static void hsw_pcm_complete(struct device *dev)
static void hsw_pcm_complete(struct device *dev)
{
{
	struct hsw_priv_data *pdata = dev_get_drvdata(dev);
	struct hsw_priv_data *pdata = dev_get_drvdata(dev);
@@ -1153,14 +1159,6 @@ static int hsw_pcm_prepare(struct device *dev)
	return 0;
	return 0;
}
}


#else
#define hsw_pcm_runtime_idle		NULL
#define hsw_pcm_runtime_suspend		NULL
#define hsw_pcm_runtime_resume		NULL
#define hsw_pcm_runtime_complete	NULL
#define hsw_pcm_runtime_prepare		NULL
#endif

static const struct dev_pm_ops hsw_pcm_pm = {
static const struct dev_pm_ops hsw_pcm_pm = {
	.runtime_idle = hsw_pcm_runtime_idle,
	.runtime_idle = hsw_pcm_runtime_idle,
	.runtime_suspend = hsw_pcm_runtime_suspend,
	.runtime_suspend = hsw_pcm_runtime_suspend,