linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sudeep Holla <sudeep.holla@arm.com>
To: linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org
Cc: Sudeep Holla <sudeep.holla@arm.com>,
	Ulf Hansson <ulf.hansson@linaro.org>,
	Adrian Hunter <adrian.hunter@intel.com>,
	linux-mmc@vger.kernel.org
Subject: [PATCH 05/19] mmc: core/host: enable support for the standard "wakeup-source" property
Date: Wed, 21 Oct 2015 11:10:02 +0100	[thread overview]
Message-ID: <1445422216-29375-6-git-send-email-sudeep.holla@arm.com> (raw)
In-Reply-To: <1445422216-29375-1-git-send-email-sudeep.holla@arm.com>

Though the mmc core driver should/will continue to support the legacy
"enable-sdio-wakeup" property to enable SDIO as the wakeup source, we
need to add support for the new standard property "wakeup-source".

This patch adds support for "wakeup-source" property in addition to the
existing "enable-sdio-wakeup" property.

Cc: Ulf Hansson <ulf.hansson@linaro.org>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: linux-mmc@vger.kernel.org
Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
---
 drivers/mmc/core/host.c        | 3 ++-
 drivers/mmc/host/sdhci-pltfm.c | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/mmc/core/host.c b/drivers/mmc/core/host.c
index 5466f25f0281..85222bb56c73 100644
--- a/drivers/mmc/core/host.c
+++ b/drivers/mmc/core/host.c
@@ -513,7 +513,8 @@ int mmc_of_parse(struct mmc_host *host)
 		host->caps2 |= MMC_CAP2_FULL_PWR_CYCLE;
 	if (of_property_read_bool(np, "keep-power-in-suspend"))
 		host->pm_caps |= MMC_PM_KEEP_POWER;
-	if (of_property_read_bool(np, "enable-sdio-wakeup"))
+	if (of_property_read_bool(np, "wakeup-source") ||
+	    of_property_read_bool(np, "enable-sdio-wakeup")) /* legacy */
 		host->pm_caps |= MMC_PM_WAKE_SDIO_IRQ;
 	if (of_property_read_bool(np, "mmc-ddr-1_8v"))
 		host->caps |= MMC_CAP_1_8V_DDR;
diff --git a/drivers/mmc/host/sdhci-pltfm.c b/drivers/mmc/host/sdhci-pltfm.c
index a207f5aaf62f..f00374bdafc9 100644
--- a/drivers/mmc/host/sdhci-pltfm.c
+++ b/drivers/mmc/host/sdhci-pltfm.c
@@ -108,7 +108,8 @@ void sdhci_get_of_property(struct platform_device *pdev)
 	if (of_find_property(np, "keep-power-in-suspend", NULL))
 		host->mmc->pm_caps |= MMC_PM_KEEP_POWER;
 
-	if (of_find_property(np, "enable-sdio-wakeup", NULL))
+	if (of_property_read_bool(np, "wakeup-source") ||
+	    of_property_read_bool(np, "enable-sdio-wakeup")) /* legacy */
 		host->mmc->pm_caps |= MMC_PM_WAKE_SDIO_IRQ;
 }
 #else
-- 
1.9.1


  parent reply	other threads:[~2015-10-21 10:15 UTC|newest]

Thread overview: 67+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-21 10:09 [PATCH 00/19] devicetree: standardize/consolidate on "wakeup-source" property Sudeep Holla
2015-10-21 10:09 ` [PATCH 01/19] Documentation: " Sudeep Holla
2015-10-21 22:02   ` Rob Herring
2015-10-21 10:09 ` [PATCH 02/19] Documentation: devicetree: fix reference to legacy wakeup properties Sudeep Holla
2015-10-21 22:04   ` Rob Herring
2015-10-28 18:23     ` Sudeep Holla
2015-10-30 18:29       ` Rob Herring
2015-10-21 10:10 ` [PATCH 03/19] rtc: opal: enable support for the stardard "wakeup-source" property Sudeep Holla
2015-10-27 22:53   ` Alexandre Belloni
2015-10-21 10:10 ` [PATCH 04/19] rtc: isl12057: enable support for the standard " Sudeep Holla
2015-10-27 22:53   ` Alexandre Belloni
2015-10-21 10:10 ` Sudeep Holla [this message]
2015-11-19 11:32   ` [PATCH 05/19] mmc: core/host: " Ulf Hansson
2015-10-21 10:10 ` [PATCH 06/19] input: tegra-kbc: " Sudeep Holla
2015-10-23  6:39   ` Dmitry Torokhov
2015-10-23 10:23     ` Sudeep Holla
2015-10-26  8:33       ` Dmitry Torokhov
2015-10-21 10:10 ` [PATCH 07/19] ARM: dts: rockchip: replace gpio-key,wakeup with wakeup-source property Sudeep Holla
2015-10-21 10:10 ` [PATCH 08/19] ARM: dts: spear: " Sudeep Holla
2015-10-21 10:10 ` [PATCH 09/19] ARM: dts: am335x: " Sudeep Holla
2015-12-15 16:33   ` Sudeep Holla
2015-12-17 17:58     ` Tony Lindgren
2015-10-21 10:10 ` [PATCH 10/19] ARM: dts: at91: " Sudeep Holla
2015-10-21 10:21   ` Nicolas Ferre
2015-10-21 10:25     ` Sudeep Holla
2015-10-21 11:01       ` Ulf Hansson
2015-10-21 11:13         ` Sudeep Holla
2015-10-21 12:41           ` Sudeep Holla
2015-10-21 15:27             ` Nicolas Ferre
2015-10-21 10:10 ` [PATCH 11/19] ARM: dts: imx: replace legacy *,wakeup property with wakeup-source Sudeep Holla
2015-11-23  5:37   ` Shawn Guo
2015-11-26 11:33     ` Sudeep Holla
2015-12-02  1:54       ` Shawn Guo
2015-12-02 10:05         ` Sudeep Holla
2015-10-21 10:10 ` [PATCH 12/19] ARM: dts: exynos: " Sudeep Holla
2015-12-15 16:35   ` Sudeep Holla
2015-12-15 23:32     ` Krzysztof Kozlowski
2015-12-16 10:32       ` Sudeep Holla
2015-12-16 23:38         ` Krzysztof Kozlowski
2015-12-16 23:49   ` Krzysztof Kozlowski
2016-01-28  8:11     ` Krzysztof Kozlowski
2016-01-28 15:59       ` [UPDATE] " Sudeep Holla
2016-01-29  0:11         ` Krzysztof Kozlowski
2015-10-21 10:10 ` [PATCH 13/19] ARM: dts: tegra: " Sudeep Holla
2015-12-15 16:35   ` Sudeep Holla
2015-12-23 11:24   ` Sudeep Holla
2015-10-21 10:10 ` [PATCH 14/19] ARM: dts: shmobile/r8a7xxx: replace gpio-key,wakeup with wakeup-source property Sudeep Holla
2015-10-21 10:18   ` Geert Uytterhoeven
2015-10-21 10:23     ` Sudeep Holla
2015-10-22  0:50       ` Simon Horman
2015-10-22  9:37         ` Sudeep Holla
2015-10-23  0:18           ` Simon Horman
2015-10-21 10:10 ` [PATCH 15/19] ARM: dts: omap: replace legacy *,wakeup property with wakeup-source Sudeep Holla
2015-12-15 16:37   ` Sudeep Holla
2015-12-17 17:58     ` Tony Lindgren
2015-10-21 10:10 ` [PATCH 16/19] ARM: dts: s5pv210: " Sudeep Holla
2015-12-15 16:37   ` Sudeep Holla
2015-12-16 23:52   ` Krzysztof Kozlowski
2015-10-21 10:10 ` [PATCH 17/19] ARM: dts: armada: replace isil,irq2-can-wakeup-machine with wakeup-source property Sudeep Holla
2015-12-15 16:39   ` Sudeep Holla
2015-12-15 16:56     ` Gregory CLEMENT
2015-10-21 10:10 ` [PATCH 18/19] ARM: dts: ste: replace legacy *,wakeup property with wakeup-source Sudeep Holla
2015-10-27 12:34   ` Linus Walleij
2015-10-27 12:46     ` Sudeep Holla
2015-11-05  9:26       ` Linus Walleij
2015-10-21 10:10 ` [PATCH 19/19] ARM: dts: zynq: replace gpio-key,wakeup with wakeup-source property Sudeep Holla
2015-10-29  8:56   ` Michal Simek

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=1445422216-29375-6-git-send-email-sudeep.holla@arm.com \
    --to=sudeep.holla@arm.com \
    --cc=adrian.hunter@intel.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=ulf.hansson@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;
as well as URLs for NNTP newsgroup(s).