aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mmc/host/mvsdio.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mmc/host/mvsdio.c')
-rw-r--r--drivers/mmc/host/mvsdio.c35
1 files changed, 3 insertions, 32 deletions
diff --git a/drivers/mmc/host/mvsdio.c b/drivers/mmc/host/mvsdio.c
index deecee08c288..45aa2206741d 100644
--- a/drivers/mmc/host/mvsdio.c
+++ b/drivers/mmc/host/mvsdio.c
@@ -775,9 +775,9 @@ static int mvsd_probe(struct platform_device *pdev)
775 775
776 spin_lock_init(&host->lock); 776 spin_lock_init(&host->lock);
777 777
778 host->base = devm_request_and_ioremap(&pdev->dev, r); 778 host->base = devm_ioremap_resource(&pdev->dev, r);
779 if (!host->base) { 779 if (IS_ERR(host->base)) {
780 ret = -ENOMEM; 780 ret = PTR_ERR(host->base);
781 goto out; 781 goto out;
782 } 782 }
783 783
@@ -838,33 +838,6 @@ static int mvsd_remove(struct platform_device *pdev)
838 return 0; 838 return 0;
839} 839}
840 840
841#ifdef CONFIG_PM
842static int mvsd_suspend(struct platform_device *dev, pm_message_t state)
843{
844 struct mmc_host *mmc = platform_get_drvdata(dev);
845 int ret = 0;
846
847 if (mmc)
848 ret = mmc_suspend_host(mmc);
849
850 return ret;
851}
852
853static int mvsd_resume(struct platform_device *dev)
854{
855 struct mmc_host *mmc = platform_get_drvdata(dev);
856 int ret = 0;
857
858 if (mmc)
859 ret = mmc_resume_host(mmc);
860
861 return ret;
862}
863#else
864#define mvsd_suspend NULL
865#define mvsd_resume NULL
866#endif
867
868static const struct of_device_id mvsdio_dt_ids[] = { 841static const struct of_device_id mvsdio_dt_ids[] = {
869 { .compatible = "marvell,orion-sdio" }, 842 { .compatible = "marvell,orion-sdio" },
870 { /* sentinel */ } 843 { /* sentinel */ }
@@ -874,8 +847,6 @@ MODULE_DEVICE_TABLE(of, mvsdio_dt_ids);
874static struct platform_driver mvsd_driver = { 847static struct platform_driver mvsd_driver = {
875 .probe = mvsd_probe, 848 .probe = mvsd_probe,
876 .remove = mvsd_remove, 849 .remove = mvsd_remove,
877 .suspend = mvsd_suspend,
878 .resume = mvsd_resume,
879 .driver = { 850 .driver = {
880 .name = DRIVER_NAME, 851 .name = DRIVER_NAME,
881 .of_match_table = mvsdio_dt_ids, 852 .of_match_table = mvsdio_dt_ids,