summaryrefslogtreecommitdiff
path: root/sound/pci/sis7019.c
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2024-03-22 02:14:13 +0300
committerJakub Kicinski <kuba@kernel.org>2024-03-22 02:15:08 +0300
commit537c2e91d3549e5d6020bb0576cf9b54a845255f (patch)
treec09e8a1b7d733cde19b0c72678c28fb2bc97ff6b /sound/pci/sis7019.c
parent237bb5f7f7f55ec5f773469a974c61a49c298625 (diff)
parentcba9ffdb9913dfe6be29f049ce920ce451ce7cc4 (diff)
downloadlinux-537c2e91d3549e5d6020bb0576cf9b54a845255f.tar.xz
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Cross-merge networking fixes after downstream PR. Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'sound/pci/sis7019.c')
-rw-r--r--sound/pci/sis7019.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/sound/pci/sis7019.c b/sound/pci/sis7019.c
index fabe393607f8..53206beb2cb5 100644
--- a/sound/pci/sis7019.c
+++ b/sound/pci/sis7019.c
@@ -90,11 +90,7 @@ struct voice {
* we're not doing power management, we still need to allocate a page
* for the silence buffer.
*/
-#ifdef CONFIG_PM_SLEEP
#define SIS_SUSPEND_PAGES 4
-#else
-#define SIS_SUSPEND_PAGES 1
-#endif
struct sis7019 {
unsigned long ioport;
@@ -1152,7 +1148,6 @@ static int sis_chip_init(struct sis7019 *sis)
return 0;
}
-#ifdef CONFIG_PM_SLEEP
static int sis_suspend(struct device *dev)
{
struct snd_card *card = dev_get_drvdata(dev);
@@ -1231,11 +1226,7 @@ error:
return -EIO;
}
-static SIMPLE_DEV_PM_OPS(sis_pm, sis_suspend, sis_resume);
-#define SIS_PM_OPS &sis_pm
-#else
-#define SIS_PM_OPS NULL
-#endif /* CONFIG_PM_SLEEP */
+static DEFINE_SIMPLE_DEV_PM_OPS(sis_pm, sis_suspend, sis_resume);
static int sis_alloc_suspend(struct sis7019 *sis)
{
@@ -1397,7 +1388,7 @@ static struct pci_driver sis7019_driver = {
.id_table = snd_sis7019_ids,
.probe = snd_sis7019_probe,
.driver = {
- .pm = SIS_PM_OPS,
+ .pm = &sis_pm,
},
};