Skip to content

Commit 723b690

Browse files
tiwaibroonie
authored andcommitted
ASoC: sunxi: Convert to RUNTIME_PM_OPS()
Use the newer RUNTIME_PM_OPS() instead of SET_RUNTIME_PM_OPS() together with pm_ptr(). This optimizes slightly when CONFIG_PM is disabled, too. Signed-off-by: Takashi Iwai <[email protected]> Reviewed-by: Charles Keepax <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent 7369a2d commit 723b690

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

sound/soc/sunxi/sun4i-spdif.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -727,15 +727,15 @@ static void sun4i_spdif_remove(struct platform_device *pdev)
727727
}
728728

729729
static const struct dev_pm_ops sun4i_spdif_pm = {
730-
SET_RUNTIME_PM_OPS(sun4i_spdif_runtime_suspend,
731-
sun4i_spdif_runtime_resume, NULL)
730+
RUNTIME_PM_OPS(sun4i_spdif_runtime_suspend,
731+
sun4i_spdif_runtime_resume, NULL)
732732
};
733733

734734
static struct platform_driver sun4i_spdif_driver = {
735735
.driver = {
736736
.name = "sun4i-spdif",
737737
.of_match_table = sun4i_spdif_of_match,
738-
.pm = &sun4i_spdif_pm,
738+
.pm = pm_ptr(&sun4i_spdif_pm),
739739
},
740740
.probe = sun4i_spdif_probe,
741741
.remove = sun4i_spdif_remove,

sound/soc/sunxi/sun50i-dmic.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -415,15 +415,15 @@ static void sun50i_dmic_remove(struct platform_device *pdev)
415415
}
416416

417417
static const struct dev_pm_ops sun50i_dmic_pm = {
418-
SET_RUNTIME_PM_OPS(sun50i_dmic_runtime_suspend,
419-
sun50i_dmic_runtime_resume, NULL)
418+
RUNTIME_PM_OPS(sun50i_dmic_runtime_suspend,
419+
sun50i_dmic_runtime_resume, NULL)
420420
};
421421

422422
static struct platform_driver sun50i_dmic_driver = {
423423
.driver = {
424424
.name = "sun50i-dmic",
425425
.of_match_table = sun50i_dmic_of_match,
426-
.pm = &sun50i_dmic_pm,
426+
.pm = pm_ptr(&sun50i_dmic_pm),
427427
},
428428
.probe = sun50i_dmic_probe,
429429
.remove = sun50i_dmic_remove,

sound/soc/sunxi/sun8i-codec.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1702,15 +1702,15 @@ static const struct of_device_id sun8i_codec_of_match[] = {
17021702
MODULE_DEVICE_TABLE(of, sun8i_codec_of_match);
17031703

17041704
static const struct dev_pm_ops sun8i_codec_pm_ops = {
1705-
SET_RUNTIME_PM_OPS(sun8i_codec_runtime_suspend,
1706-
sun8i_codec_runtime_resume, NULL)
1705+
RUNTIME_PM_OPS(sun8i_codec_runtime_suspend,
1706+
sun8i_codec_runtime_resume, NULL)
17071707
};
17081708

17091709
static struct platform_driver sun8i_codec_driver = {
17101710
.driver = {
17111711
.name = "sun8i-codec",
17121712
.of_match_table = sun8i_codec_of_match,
1713-
.pm = &sun8i_codec_pm_ops,
1713+
.pm = pm_ptr(&sun8i_codec_pm_ops),
17141714
},
17151715
.probe = sun8i_codec_probe,
17161716
.remove = sun8i_codec_remove,

0 commit comments

Comments
 (0)