aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/spi/spi-ep93xx.c7
-rw-r--r--drivers/spi/spi-mxs.c6
-rw-r--r--drivers/spi/spi-omap2-mcspi.c7
-rw-r--r--drivers/spi/spi-s3c64xx.c7
-rw-r--r--drivers/spi/spi-sirf.c7
-rw-r--r--drivers/spi/spi-tegra20-sflash.c8
-rw-r--r--drivers/spi/spi-tegra20-slink.c8
7 files changed, 21 insertions, 29 deletions
diff --git a/drivers/spi/spi-ep93xx.c b/drivers/spi/spi-ep93xx.c
index acb1e1935c5a..2e31f32d06f1 100644
--- a/drivers/spi/spi-ep93xx.c
+++ b/drivers/spi/spi-ep93xx.c
@@ -1085,10 +1085,9 @@ static int ep93xx_spi_probe(struct platform_device *pdev)
1085 1085
1086 espi->sspdr_phys = res->start + SSPDR; 1086 espi->sspdr_phys = res->start + SSPDR;
1087 1087
1088 espi->regs_base = devm_request_and_ioremap(&pdev->dev, res); 1088 espi->regs_base = devm_ioremap_resource(&pdev->dev, res);
1089 if (!espi->regs_base) { 1089 if (IS_ERR(espi->regs_base)) {
1090 dev_err(&pdev->dev, "failed to map resources\n"); 1090 error = PTR_ERR(espi->regs_base);
1091 error = -ENODEV;
1092 goto fail_put_clock; 1091 goto fail_put_clock;
1093 } 1092 }
1094 1093
diff --git a/drivers/spi/spi-mxs.c b/drivers/spi/spi-mxs.c
index a3ede249d05d..b735988641e0 100644
--- a/drivers/spi/spi-mxs.c
+++ b/drivers/spi/spi-mxs.c
@@ -538,9 +538,9 @@ static int mxs_spi_probe(struct platform_device *pdev)
538 if (!iores || irq_err < 0 || irq_dma < 0) 538 if (!iores || irq_err < 0 || irq_dma < 0)
539 return -EINVAL; 539 return -EINVAL;
540 540
541 base = devm_request_and_ioremap(&pdev->dev, iores); 541 base = devm_ioremap_resource(&pdev->dev, iores);
542 if (!base) 542 if (IS_ERR(base))
543 return -EADDRNOTAVAIL; 543 return PTR_ERR(base);
544 544
545 pinctrl = devm_pinctrl_get_select_default(&pdev->dev); 545 pinctrl = devm_pinctrl_get_select_default(&pdev->dev);
546 if (IS_ERR(pinctrl)) 546 if (IS_ERR(pinctrl))
diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi/spi-omap2-mcspi.c
index b610f522ca44..71a9482f0acc 100644
--- a/drivers/spi/spi-omap2-mcspi.c
+++ b/drivers/spi/spi-omap2-mcspi.c
@@ -1204,10 +1204,9 @@ static int omap2_mcspi_probe(struct platform_device *pdev)
1204 r->end += regs_offset; 1204 r->end += regs_offset;
1205 mcspi->phys = r->start; 1205 mcspi->phys = r->start;
1206 1206
1207 mcspi->base = devm_request_and_ioremap(&pdev->dev, r); 1207 mcspi->base = devm_ioremap_resource(&pdev->dev, r);
1208 if (!mcspi->base) { 1208 if (IS_ERR(mcspi->base)) {
1209 dev_dbg(&pdev->dev, "can't ioremap MCSPI\n"); 1209 status = PTR_ERR(mcspi->base);
1210 status = -ENOMEM;
1211 goto free_master; 1210 goto free_master;
1212 } 1211 }
1213 1212
diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c
index ad93231a8038..3d4a7c48d74d 100644
--- a/drivers/spi/spi-s3c64xx.c
+++ b/drivers/spi/spi-s3c64xx.c
@@ -1276,10 +1276,9 @@ static int __init s3c64xx_spi_probe(struct platform_device *pdev)
1276 /* the spi->mode bits understood by this driver: */ 1276 /* the spi->mode bits understood by this driver: */
1277 master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH; 1277 master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH;
1278 1278
1279 sdd->regs = devm_request_and_ioremap(&pdev->dev, mem_res); 1279 sdd->regs = devm_ioremap_resource(&pdev->dev, mem_res);
1280 if (sdd->regs == NULL) { 1280 if (IS_ERR(sdd->regs)) {
1281 dev_err(&pdev->dev, "Unable to remap IO\n"); 1281 ret = PTR_ERR(sdd->regs);
1282 ret = -ENXIO;
1283 goto err1; 1282 goto err1;
1284 } 1283 }
1285 1284
diff --git a/drivers/spi/spi-sirf.c b/drivers/spi/spi-sirf.c
index e0f43a512e84..78c8842b9501 100644
--- a/drivers/spi/spi-sirf.c
+++ b/drivers/spi/spi-sirf.c
@@ -535,10 +535,9 @@ static int spi_sirfsoc_probe(struct platform_device *pdev)
535 } 535 }
536 } 536 }
537 537
538 sspi->base = devm_request_and_ioremap(&pdev->dev, mem_res); 538 sspi->base = devm_ioremap_resource(&pdev->dev, mem_res);
539 if (!sspi->base) { 539 if (IS_ERR(sspi->base)) {
540 dev_err(&pdev->dev, "IO remap failed!\n"); 540 ret = PTR_ERR(sspi->base);
541 ret = -ENOMEM;
542 goto free_master; 541 goto free_master;
543 } 542 }
544 543
diff --git a/drivers/spi/spi-tegra20-sflash.c b/drivers/spi/spi-tegra20-sflash.c
index 448a8cc71df3..69c9d23bd472 100644
--- a/drivers/spi/spi-tegra20-sflash.c
+++ b/drivers/spi/spi-tegra20-sflash.c
@@ -508,11 +508,9 @@ static int tegra_sflash_probe(struct platform_device *pdev)
508 ret = -ENODEV; 508 ret = -ENODEV;
509 goto exit_free_master; 509 goto exit_free_master;
510 } 510 }
511 tsd->base = devm_request_and_ioremap(&pdev->dev, r); 511 tsd->base = devm_ioremap_resource(&pdev->dev, r);
512 if (!tsd->base) { 512 if (IS_ERR(tsd->base)) {
513 dev_err(&pdev->dev, 513 ret = PTR_ERR(tsd->base);
514 "Cannot request memregion/iomap dma address\n");
515 ret = -EADDRNOTAVAIL;
516 goto exit_free_master; 514 goto exit_free_master;
517 } 515 }
518 516
diff --git a/drivers/spi/spi-tegra20-slink.c b/drivers/spi/spi-tegra20-slink.c
index 651167f2e0af..96bd6c25a0fc 100644
--- a/drivers/spi/spi-tegra20-slink.c
+++ b/drivers/spi/spi-tegra20-slink.c
@@ -1172,11 +1172,9 @@ static int tegra_slink_probe(struct platform_device *pdev)
1172 goto exit_free_master; 1172 goto exit_free_master;
1173 } 1173 }
1174 tspi->phys = r->start; 1174 tspi->phys = r->start;
1175 tspi->base = devm_request_and_ioremap(&pdev->dev, r); 1175 tspi->base = devm_ioremap_resource(&pdev->dev, r);
1176 if (!tspi->base) { 1176 if (IS_ERR(tspi->base)) {
1177 dev_err(&pdev->dev, 1177 ret = PTR_ERR(tspi->base);
1178 "Cannot request memregion/iomap dma address\n");
1179 ret = -EADDRNOTAVAIL;
1180 goto exit_free_master; 1178 goto exit_free_master;
1181 } 1179 }
1182 1180