aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/soc/omap/omap-dmic.c9
-rw-r--r--sound/soc/omap/omap-mcpdm.c8
2 files changed, 6 insertions, 11 deletions
diff --git a/sound/soc/omap/omap-dmic.c b/sound/soc/omap/omap-dmic.c
index 77e9e7e68edc..8ebaf117d81f 100644
--- a/sound/soc/omap/omap-dmic.c
+++ b/sound/soc/omap/omap-dmic.c
@@ -493,12 +493,9 @@ static int asoc_dmic_probe(struct platform_device *pdev)
493 goto err_put_clk; 493 goto err_put_clk;
494 } 494 }
495 495
496 dmic->io_base = devm_request_and_ioremap(&pdev->dev, res); 496 dmic->io_base = devm_ioremap_resource(&pdev->dev, res);
497 if (!dmic->io_base) { 497 if (IS_ERR(dmic->io_base))
498 dev_err(&pdev->dev, "cannot remap\n"); 498 return PTR_ERR(dmic->io_base);
499 ret = -ENOMEM;
500 goto err_put_clk;
501 }
502 499
503 ret = snd_soc_register_dai(&pdev->dev, &omap_dmic_dai); 500 ret = snd_soc_register_dai(&pdev->dev, &omap_dmic_dai);
504 if (ret) 501 if (ret)
diff --git a/sound/soc/omap/omap-mcpdm.c b/sound/soc/omap/omap-mcpdm.c
index 079f277cdba4..ddfcc1834ff0 100644
--- a/sound/soc/omap/omap-mcpdm.c
+++ b/sound/soc/omap/omap-mcpdm.c
@@ -464,11 +464,9 @@ static int asoc_mcpdm_probe(struct platform_device *pdev)
464 if (res == NULL) 464 if (res == NULL)
465 return -ENOMEM; 465 return -ENOMEM;
466 466
467 mcpdm->io_base = devm_request_and_ioremap(&pdev->dev, res); 467 mcpdm->io_base = devm_ioremap_resource(&pdev->dev, res);
468 if (!mcpdm->io_base) { 468 if (IS_ERR(mcpdm->io_base))
469 dev_err(&pdev->dev, "cannot remap\n"); 469 return PTR_ERR(mcpdm->io_base);
470 return -ENOMEM;
471 }
472 470
473 mcpdm->irq = platform_get_irq(pdev, 0); 471 mcpdm->irq = platform_get_irq(pdev, 0);
474 if (mcpdm->irq < 0) 472 if (mcpdm->irq < 0)