All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Eric Miao <eric.y.miao@gmail.com>,
	Haojian Zhuang <haojian.zhuang@gmail.com>,
	Kukjin Kim <kgene.kim@samsung.com>,
	Stephen Warren <swarren@wwwdotorg.org>,
	Linus Walleij <linus.walleij@linaro.org>
Cc: linux-samsung-soc@vger.kernel.org, linux-tegra@vger.kernel.org,
	linux-omap@vger.kernel.org, linaro-kernel@lists.linaro.org,
	Mark Brown <broonie@linaro.org>
Subject: [PATCH 04/11] spi/omap2: Covert to core runtime PM
Date: Sun, 28 Jul 2013 15:43:19 +0100	[thread overview]
Message-ID: <1375022606-7576-4-git-send-email-broonie@kernel.org> (raw)
In-Reply-To: <1375022606-7576-1-git-send-email-broonie@kernel.org>

From: Mark Brown <broonie@linaro.org>

Signed-off-by: Mark Brown <broonie@linaro.org>
---
 drivers/spi/spi-omap2-mcspi.c | 20 +-------------------
 1 file changed, 1 insertion(+), 19 deletions(-)

diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi/spi-omap2-mcspi.c
index 5994039..973c1cb 100644
--- a/drivers/spi/spi-omap2-mcspi.c
+++ b/drivers/spi/spi-omap2-mcspi.c
@@ -335,23 +335,6 @@ static void omap2_mcspi_restore_ctx(struct omap2_mcspi *mcspi)
 		__raw_writel(cs->chconf0, cs->base + OMAP2_MCSPI_CHCONF0);
 }
 
-static int omap2_prepare_transfer(struct spi_master *master)
-{
-	struct omap2_mcspi *mcspi = spi_master_get_devdata(master);
-
-	pm_runtime_get_sync(mcspi->dev);
-	return 0;
-}
-
-static int omap2_unprepare_transfer(struct spi_master *master)
-{
-	struct omap2_mcspi *mcspi = spi_master_get_devdata(master);
-
-	pm_runtime_mark_last_busy(mcspi->dev);
-	pm_runtime_put_autosuspend(mcspi->dev);
-	return 0;
-}
-
 static int mcspi_wait_for_reg_bit(void __iomem *reg, unsigned long bit)
 {
 	unsigned long timeout;
@@ -1318,8 +1301,7 @@ static int omap2_mcspi_probe(struct platform_device *pdev)
 	master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH;
 	master->bits_per_word_mask = SPI_BPW_RANGE_MASK(4, 32);
 	master->setup = omap2_mcspi_setup;
-	master->prepare_transfer_hardware = omap2_prepare_transfer;
-	master->unprepare_transfer_hardware = omap2_unprepare_transfer;
+	master->auto_runtime_pm = true;
 	master->transfer_one_message = omap2_mcspi_transfer_one_message;
 	master->cleanup = omap2_mcspi_cleanup;
 	master->dev.of_node = node;
-- 
1.8.3.2


  parent reply	other threads:[~2013-07-28 14:43 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-28 14:43 [PATCH 01/11] spi: Provide core support for runtime PM during transfers Mark Brown
2013-07-28 14:43 ` [PATCH 02/11] spi/bcm63xx: Convert to core runtime PM Mark Brown
2013-07-28 14:43 ` [PATCH 03/11] spi/coldfire-qspi: " Mark Brown
2013-07-28 14:43 ` Mark Brown [this message]
2013-07-28 21:20   ` [PATCH 04/11] spi/omap2: Covert " Felipe Balbi
2013-07-28 14:43 ` [PATCH 05/11] spi/pl022: Convert " Mark Brown
     [not found]   ` <1375022606-7576-5-git-send-email-broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2013-07-28 20:52     ` Linus Walleij
2013-07-29  6:04       ` Mark Brown
2013-07-28 14:43 ` [PATCH 06/11] spi/pxa2xx: " Mark Brown
2013-07-28 14:43 ` [PATCH 07/11] spi/hspi: " Mark Brown
     [not found] ` <1375022606-7576-1-git-send-email-broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2013-07-28 14:43   ` [PATCH 08/11] spi/s3c64xx: Use core for " Mark Brown
2013-07-28 14:43   ` [PATCH 10/11] spi/tegra20-sflash: Use core " Mark Brown
2013-07-28 20:51   ` [PATCH 01/11] spi: Provide core support for runtime PM during transfers Linus Walleij
2013-07-29  5:56     ` Mark Brown
2013-07-28 14:43 ` [PATCH 09/11] spi/tegra114: Use core runtime PM Mark Brown
2013-07-28 14:43 ` [PATCH 11/11] spi/tegra20-slink: " Mark Brown
2013-07-29 16:56 ` [PATCH 01/11] spi: Provide core support for runtime PM during transfers Stephen Warren

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=1375022606-7576-4-git-send-email-broonie@kernel.org \
    --to=broonie@kernel.org \
    --cc=broonie@linaro.org \
    --cc=eric.y.miao@gmail.com \
    --cc=haojian.zhuang@gmail.com \
    --cc=kgene.kim@samsung.com \
    --cc=linaro-kernel@lists.linaro.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=swarren@wwwdotorg.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.