From: Dhruva Gole <d-gole@ti.com>
To: Ulf Hansson <ulf.hansson@linaro.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
Adrian Hunter <adrian.hunter@intel.com>
Cc: Tony Lindgren <tony@atomide.com>, Len Brown <len.brown@intel.com>,
Pavel Machek <pavel@ucw.cz>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Viresh Kumar <viresh.kumar@linaro.org>, <theo.lebrun@bootlin.com>,
Dhruva Gole <d-gole@ti.com>, <linux-pm@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <linux-mmc@vger.kernel.org>
Subject: [PATCH 3/3] mmc: sdhci-pci: Use device_set_wakeup_enable for en/disable wakeups
Date: Mon, 18 Mar 2024 11:20:54 +0530 [thread overview]
Message-ID: <20240318055054.1564696-4-d-gole@ti.com> (raw)
In-Reply-To: <20240318055054.1564696-1-d-gole@ti.com>
There exists device_set_wakeup_enable for wrapping device_wakeup_enable
and device_wakeup_disable. Use that instead to avoid confusion in
returning from a void vs int function.
Signed-off-by: Dhruva Gole <d-gole@ti.com>
---
I do not have the hardware to test out this driver, hence requesting
someone to review/ test it if atall you suspect that this change can
break existing functionality.
drivers/mmc/host/sdhci-pci-core.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mmc/host/sdhci-pci-core.c b/drivers/mmc/host/sdhci-pci-core.c
index 025b31aa712c..db614389a5fc 100644
--- a/drivers/mmc/host/sdhci-pci-core.c
+++ b/drivers/mmc/host/sdhci-pci-core.c
@@ -61,9 +61,9 @@ static int sdhci_pci_init_wakeup(struct sdhci_pci_chip *chip)
}
if ((pm_flags & MMC_PM_KEEP_POWER) && (pm_flags & MMC_PM_WAKE_SDIO_IRQ))
- return device_wakeup_enable(&chip->pdev->dev);
+ return device_set_wakeup_enable(&chip->pdev->dev, true);
else if (!cap_cd_wake)
- return device_wakeup_disable(&chip->pdev->dev);
+ return device_set_wakeup_enable(&chip->pdev->dev, false);
return 0;
}
--
2.34.1
next prev parent reply other threads:[~2024-03-18 6:06 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-18 5:50 [PATCH 0/3] PM: wakeup: make device_wakeup_disable return void Dhruva Gole
2024-03-18 5:50 ` [PATCH 1/3] " Dhruva Gole
2024-03-18 13:47 ` Rafael J. Wysocki
2024-03-18 15:19 ` Dhruva Gole
2024-03-18 5:50 ` [PATCH 2/3] PM: wakeup: Remove unnecessary else from device_init_wakeup Dhruva Gole
2024-03-18 13:52 ` Rafael J. Wysocki
2024-03-18 15:18 ` Dhruva Gole
2024-03-18 5:50 ` Dhruva Gole [this message]
2024-03-18 13:50 ` [PATCH 3/3] mmc: sdhci-pci: Use device_set_wakeup_enable for en/disable wakeups Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240318055054.1564696-4-d-gole@ti.com \
--to=d-gole@ti.com \
--cc=adrian.hunter@intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=len.brown@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=pavel@ucw.cz \
--cc=rafael@kernel.org \
--cc=theo.lebrun@bootlin.com \
--cc=tony@atomide.com \
--cc=ulf.hansson@linaro.org \
--cc=viresh.kumar@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox