[PATCH 3/6] mmc: TMIO: Use devm_ioremap()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



	Use devm_ioremap for tmio / sh_mobile.

Reviewed-by: Violeta Menendez <violeta.menendez@xxxxxxxxxxxxxxx>
Signed-off-by: Ian Molton <ian.molton@xxxxxxxxxxxxxxx>
---
 drivers/mmc/host/tmio_mmc_pio.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c
index 7db9310..50e8c01 100644
--- a/drivers/mmc/host/tmio_mmc_pio.c
+++ b/drivers/mmc/host/tmio_mmc_pio.c
@@ -1021,7 +1021,7 @@ int tmio_mmc_host_probe(struct tmio_mmc_host *host)
 	if (ret < 0)
 		goto host_free;
 
-	host->ctl = ioremap(res_ctl->start, resource_size(res_ctl));
+	host->ctl = devm_ioremap(dev, res_ctl->start, resource_size(res_ctl));
 	if (!host->ctl) {
 		ret = -ENOMEM;
 		goto host_free;
@@ -1119,7 +1119,6 @@ int tmio_mmc_host_probe(struct tmio_mmc_host *host)
 
 pm_disable:
 	pm_runtime_disable(dev);
-	iounmap(host->ctl);
 host_free:
 	mmc_free_host(mmc);
 
@@ -1145,7 +1144,6 @@ void tmio_mmc_host_remove(struct tmio_mmc_host *host)
 	pm_runtime_put_sync(&pdev->dev);
 	pm_runtime_disable(&pdev->dev);
 
-	iounmap(host->ctl);
 	mmc_free_host(mmc);
 }
 EXPORT_SYMBOL(tmio_mmc_host_remove);
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux