* [PATCH] mmc: sdhci-pxav3: fix device wakeup initialization
@ 2015-06-02 10:38 Jisheng Zhang
2015-06-04 8:34 ` Ulf Hansson
0 siblings, 1 reply; 2+ messages in thread
From: Jisheng Zhang @ 2015-06-02 10:38 UTC (permalink / raw)
To: linux-arm-kernel
MMC_PM_KEEP_POWER doesn't imply MMC_PM_WAKE_SDIO_IRQ, we should only
enable device wake up when MMC_PM_WAKE_SDIO_IRQ is set. And "pm_flags"
is the requested pm features, we should not set it in the host driver.
At the same time, device wakeup is disabled by default, so there's no
need to disable device wakeup explicitly.
This patch fixes the warning as following:
[ 64.616651] ------------[ cut here ]------------
[ 64.616665] WARNING: CPU: 0 PID: 79 at linux/kernel/irq/manage.c:603 irq_set_irq_wake+0xf0/0x11c()
[ 64.616667] Unbalanced IRQ 87 wake disable
Signed-off-by: Jisheng Zhang <jszhang@marvell.com>
---
drivers/mmc/host/sdhci-pxav3.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/drivers/mmc/host/sdhci-pxav3.c b/drivers/mmc/host/sdhci-pxav3.c
index 01cb2d3..9cd5fc6 100644
--- a/drivers/mmc/host/sdhci-pxav3.c
+++ b/drivers/mmc/host/sdhci-pxav3.c
@@ -457,12 +457,8 @@ static int sdhci_pxav3_probe(struct platform_device *pdev)
platform_set_drvdata(pdev, host);
- if (host->mmc->pm_caps & MMC_PM_KEEP_POWER) {
+ if (host->mmc->pm_caps & MMC_PM_WAKE_SDIO_IRQ)
device_init_wakeup(&pdev->dev, 1);
- host->mmc->pm_flags |= MMC_PM_WAKE_SDIO_IRQ;
- } else {
- device_init_wakeup(&pdev->dev, 0);
- }
pm_runtime_put_autosuspend(&pdev->dev);
--
2.1.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH] mmc: sdhci-pxav3: fix device wakeup initialization
2015-06-02 10:38 [PATCH] mmc: sdhci-pxav3: fix device wakeup initialization Jisheng Zhang
@ 2015-06-04 8:34 ` Ulf Hansson
0 siblings, 0 replies; 2+ messages in thread
From: Ulf Hansson @ 2015-06-04 8:34 UTC (permalink / raw)
To: linux-arm-kernel
On 2 June 2015 at 12:38, Jisheng Zhang <jszhang@marvell.com> wrote:
> MMC_PM_KEEP_POWER doesn't imply MMC_PM_WAKE_SDIO_IRQ, we should only
> enable device wake up when MMC_PM_WAKE_SDIO_IRQ is set. And "pm_flags"
> is the requested pm features, we should not set it in the host driver.
>
> At the same time, device wakeup is disabled by default, so there's no
> need to disable device wakeup explicitly.
>
> This patch fixes the warning as following:
>
> [ 64.616651] ------------[ cut here ]------------
> [ 64.616665] WARNING: CPU: 0 PID: 79 at linux/kernel/irq/manage.c:603 irq_set_irq_wake+0xf0/0x11c()
> [ 64.616667] Unbalanced IRQ 87 wake disable
>
> Signed-off-by: Jisheng Zhang <jszhang@marvell.com>
Thanks, applied.
Kind regards
Uffe
> ---
> drivers/mmc/host/sdhci-pxav3.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/drivers/mmc/host/sdhci-pxav3.c b/drivers/mmc/host/sdhci-pxav3.c
> index 01cb2d3..9cd5fc6 100644
> --- a/drivers/mmc/host/sdhci-pxav3.c
> +++ b/drivers/mmc/host/sdhci-pxav3.c
> @@ -457,12 +457,8 @@ static int sdhci_pxav3_probe(struct platform_device *pdev)
>
> platform_set_drvdata(pdev, host);
>
> - if (host->mmc->pm_caps & MMC_PM_KEEP_POWER) {
> + if (host->mmc->pm_caps & MMC_PM_WAKE_SDIO_IRQ)
> device_init_wakeup(&pdev->dev, 1);
> - host->mmc->pm_flags |= MMC_PM_WAKE_SDIO_IRQ;
> - } else {
> - device_init_wakeup(&pdev->dev, 0);
> - }
>
> pm_runtime_put_autosuspend(&pdev->dev);
>
> --
> 2.1.4
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-06-04 8:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-02 10:38 [PATCH] mmc: sdhci-pxav3: fix device wakeup initialization Jisheng Zhang
2015-06-04 8:34 ` Ulf Hansson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).