Skip to content

Commit 6822437

Browse files
plbossartbroonie
authored andcommitted
ASoC: Intel: byt/cht: add .pm_ops
Add required .pm_ops to support suspend/resume on baytrail/cherrytrail machines. This .pm_ops is conditionally-added to avoid impacting the legacy driver where power management is handled differently. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Tested-by: Enric Balletbo i Serra <enric.balletbo@collabora.com> Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20200526203640.25980-5-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 512e767 commit 6822437

9 files changed

Lines changed: 27 additions & 0 deletions

File tree

‎sound/soc/intel/boards/bytcht_cx2072x.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -261,6 +261,9 @@ static int snd_byt_cht_cx2072x_probe(struct platform_device *pdev)
261261
static struct platform_driver snd_byt_cht_cx2072x_driver = {
262262
.driver = {
263263
.name = "bytcht_cx2072x",
264+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
265+
.pm = &snd_soc_pm_ops,
266+
#endif
264267
},
265268
.probe = snd_byt_cht_cx2072x_probe,
266269
};

‎sound/soc/intel/boards/bytcht_da7213.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,9 @@ static int bytcht_da7213_probe(struct platform_device *pdev)
272272
static struct platform_driver bytcht_da7213_driver = {
273273
.driver = {
274274
.name = "bytcht_da7213",
275+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
276+
.pm = &snd_soc_pm_ops,
277+
#endif
275278
},
276279
.probe = bytcht_da7213_probe,
277280
};

‎sound/soc/intel/boards/bytcht_es8316.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -605,6 +605,9 @@ static int snd_byt_cht_es8316_mc_remove(struct platform_device *pdev)
605605
static struct platform_driver snd_byt_cht_es8316_mc_driver = {
606606
.driver = {
607607
.name = "bytcht_es8316",
608+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
609+
.pm = &snd_soc_pm_ops,
610+
#endif
608611
},
609612
.probe = snd_byt_cht_es8316_mc_probe,
610613
.remove = snd_byt_cht_es8316_mc_remove,

‎sound/soc/intel/boards/bytcr_rt5640.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1319,6 +1319,9 @@ static int snd_byt_rt5640_mc_probe(struct platform_device *pdev)
13191319
static struct platform_driver snd_byt_rt5640_mc_driver = {
13201320
.driver = {
13211321
.name = "bytcr_rt5640",
1322+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
1323+
.pm = &snd_soc_pm_ops,
1324+
#endif
13221325
},
13231326
.probe = snd_byt_rt5640_mc_probe,
13241327
};

‎sound/soc/intel/boards/bytcr_rt5651.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1097,6 +1097,9 @@ static int snd_byt_rt5651_mc_probe(struct platform_device *pdev)
10971097
static struct platform_driver snd_byt_rt5651_mc_driver = {
10981098
.driver = {
10991099
.name = "bytcr_rt5651",
1100+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
1101+
.pm = &snd_soc_pm_ops,
1102+
#endif
11001103
},
11011104
.probe = snd_byt_rt5651_mc_probe,
11021105
};

‎sound/soc/intel/boards/cht_bsw_max98090_ti.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -616,6 +616,9 @@ static int snd_cht_mc_remove(struct platform_device *pdev)
616616
static struct platform_driver snd_cht_mc_driver = {
617617
.driver = {
618618
.name = "cht-bsw-max98090",
619+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
620+
.pm = &snd_soc_pm_ops,
621+
#endif
619622
},
620623
.probe = snd_cht_mc_probe,
621624
.remove = snd_cht_mc_remove,

‎sound/soc/intel/boards/cht_bsw_nau8824.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -282,6 +282,9 @@ static int snd_cht_mc_probe(struct platform_device *pdev)
282282
static struct platform_driver snd_cht_mc_driver = {
283283
.driver = {
284284
.name = "cht-bsw-nau8824",
285+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
286+
.pm = &snd_soc_pm_ops,
287+
#endif
285288
},
286289
.probe = snd_cht_mc_probe,
287290
};

‎sound/soc/intel/boards/cht_bsw_rt5645.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -680,6 +680,9 @@ static int snd_cht_mc_probe(struct platform_device *pdev)
680680
static struct platform_driver snd_cht_mc_driver = {
681681
.driver = {
682682
.name = "cht-bsw-rt5645",
683+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
684+
.pm = &snd_soc_pm_ops,
685+
#endif
683686
},
684687
.probe = snd_cht_mc_probe,
685688
};

‎sound/soc/intel/boards/cht_bsw_rt5672.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -459,6 +459,9 @@ static int snd_cht_mc_probe(struct platform_device *pdev)
459459
static struct platform_driver snd_cht_mc_driver = {
460460
.driver = {
461461
.name = "cht-bsw-rt5672",
462+
#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
463+
.pm = &snd_soc_pm_ops,
464+
#endif
462465
},
463466
.probe = snd_cht_mc_probe,
464467
};

0 commit comments

Comments
 (0)