]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
ASoC: Intel: byt/cht: add .pm_ops
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Tue, 26 May 2020 20:36:36 +0000 (15:36 -0500)
committerMark Brown <broonie@kernel.org>
Wed, 27 May 2020 13:06:56 +0000 (14:06 +0100)
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>
sound/soc/intel/boards/bytcht_cx2072x.c
sound/soc/intel/boards/bytcht_da7213.c
sound/soc/intel/boards/bytcht_es8316.c
sound/soc/intel/boards/bytcr_rt5640.c
sound/soc/intel/boards/bytcr_rt5651.c
sound/soc/intel/boards/cht_bsw_max98090_ti.c
sound/soc/intel/boards/cht_bsw_nau8824.c
sound/soc/intel/boards/cht_bsw_rt5645.c
sound/soc/intel/boards/cht_bsw_rt5672.c

index c7f81a93d7c8a27d655cabc8798b1e89e64dbb3f..fad937610494431b2ab788b22ba4a26138aa9de9 100644 (file)
@@ -261,6 +261,9 @@ static int snd_byt_cht_cx2072x_probe(struct platform_device *pdev)
 static struct platform_driver snd_byt_cht_cx2072x_driver = {
        .driver = {
                .name = "bytcht_cx2072x",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = snd_byt_cht_cx2072x_probe,
 };
index 5e96e7d02733c147483e617c5a01cd6eb205afbe..f3791ff2bad1c1374cf74bfb5b80ebcd4ceb0466 100644 (file)
@@ -272,6 +272,9 @@ static int bytcht_da7213_probe(struct platform_device *pdev)
 static struct platform_driver bytcht_da7213_driver = {
        .driver = {
                .name = "bytcht_da7213",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = bytcht_da7213_probe,
 };
index ddcd070100ef46aafce32c475ce6c3fc8e43bfa5..9e5fc9430628ccefc53ea6bb6f1482b39c32c043 100644 (file)
@@ -605,6 +605,9 @@ static int snd_byt_cht_es8316_mc_remove(struct platform_device *pdev)
 static struct platform_driver snd_byt_cht_es8316_mc_driver = {
        .driver = {
                .name = "bytcht_es8316",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = snd_byt_cht_es8316_mc_probe,
        .remove = snd_byt_cht_es8316_mc_remove,
index d7e42bd9b308c961d59db2334de50a488e4d1b0f..30f70bbdf89c729dee0cda88fb65a035b9c2207b 100644 (file)
@@ -1319,6 +1319,9 @@ static int snd_byt_rt5640_mc_probe(struct platform_device *pdev)
 static struct platform_driver snd_byt_rt5640_mc_driver = {
        .driver = {
                .name = "bytcr_rt5640",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = snd_byt_rt5640_mc_probe,
 };
index 0468fc35445f43173a80f4acfce84fe76aeae498..520e916e329cdd81521c2db87a79e178899693de 100644 (file)
@@ -1097,6 +1097,9 @@ static int snd_byt_rt5651_mc_probe(struct platform_device *pdev)
 static struct platform_driver snd_byt_rt5651_mc_driver = {
        .driver = {
                .name = "bytcr_rt5651",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = snd_byt_rt5651_mc_probe,
 };
index 135701738a4449a4feb46eba18fc30b1e86be090..767ac2ae03e225a4afd425acb7fb6f2a3eff4c92 100644 (file)
@@ -616,6 +616,9 @@ static int snd_cht_mc_remove(struct platform_device *pdev)
 static struct platform_driver snd_cht_mc_driver = {
        .driver = {
                .name = "cht-bsw-max98090",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = snd_cht_mc_probe,
        .remove = snd_cht_mc_remove,
index 67b46de2f088da135dffcb11ed7fdac259db84aa..2f7c94d335c1cea1107f897190a6f59b17994d65 100644 (file)
@@ -282,6 +282,9 @@ static int snd_cht_mc_probe(struct platform_device *pdev)
 static struct platform_driver snd_cht_mc_driver = {
        .driver = {
                .name = "cht-bsw-nau8824",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = snd_cht_mc_probe,
 };
index e64eca56e42604c2c4fafcbe0a96910fe5246933..22de138ffa3379ca3d7af44bc6aee4cac5ade3de 100644 (file)
@@ -680,6 +680,9 @@ static int snd_cht_mc_probe(struct platform_device *pdev)
 static struct platform_driver snd_cht_mc_driver = {
        .driver = {
                .name = "cht-bsw-rt5645",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = snd_cht_mc_probe,
 };
index 097023a3ec14a2fdc5dcfddf6134799c8d29eed1..7a43c70a1378a2e62a22102377b1dc1d4f19387f 100644 (file)
@@ -459,6 +459,9 @@ static int snd_cht_mc_probe(struct platform_device *pdev)
 static struct platform_driver snd_cht_mc_driver = {
        .driver = {
                .name = "cht-bsw-rt5672",
+#if IS_ENABLED(CONFIG_SND_SOC_SOF_BAYTRAIL)
+               .pm = &snd_soc_pm_ops,
+#endif
        },
        .probe = snd_cht_mc_probe,
 };