diff options
Diffstat (limited to 'drivers/i2c/busses/i2c-sirf.c')
-rw-r--r-- | drivers/i2c/busses/i2c-sirf.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/i2c/busses/i2c-sirf.c b/drivers/i2c/busses/i2c-sirf.c index e03381aee34..5a7ad240bd2 100644 --- a/drivers/i2c/busses/i2c-sirf.c +++ b/drivers/i2c/busses/i2c-sirf.c @@ -309,10 +309,9 @@ static int i2c_sirfsoc_probe(struct platform_device *pdev) goto out; } - siic->base = devm_request_and_ioremap(&pdev->dev, mem_res); - if (siic->base == NULL) { - dev_err(&pdev->dev, "IO remap failed!\n"); - err = -ENOMEM; + siic->base = devm_ioremap_resource(&pdev->dev, mem_res); + if (IS_ERR(siic->base)) { + err = PTR_ERR(siic->base); goto out; } |