Message ID | 1397139569-3906-1-git-send-email-ulf.hansson@linaro.org |
---|---|
State | Accepted |
Headers | show |
On 10 April 2014 16:19, Ulf Hansson <ulf.hansson@linaro.org> wrote: > devm_ioremap() returns NULL on error, not an error. > > Cc: Alessandro Rubini <rubini@unipv.it> > Cc: Linus Walleij <linus.walleij@linaro.org> > Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Linus, Wolfram - ping. Kind regards Ulf Hansson -- To unsubscribe from this list: send the line "unsubscribe linux-i2c" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Tue, May 6, 2014 at 11:32 AM, Ulf Hansson <ulf.hansson@linaro.org> wrote: > On 10 April 2014 16:19, Ulf Hansson <ulf.hansson@linaro.org> wrote: >> devm_ioremap() returns NULL on error, not an error. >> >> Cc: Alessandro Rubini <rubini@unipv.it> >> Cc: Linus Walleij <linus.walleij@linaro.org> >> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> > > Linus, Wolfram - ping. Acked-by: Linus Walleij <linus.walleij@linaro.org> Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-i2c" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Thu, Apr 10, 2014 at 04:19:29PM +0200, Ulf Hansson wrote: > devm_ioremap() returns NULL on error, not an error. > > Cc: Alessandro Rubini <rubini@unipv.it> > Cc: Linus Walleij <linus.walleij@linaro.org> > Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> Applied to for-current, thanks!
diff --git a/drivers/i2c/busses/i2c-nomadik.c b/drivers/i2c/busses/i2c-nomadik.c index 28cbe1b..32c85e9 100644 --- a/drivers/i2c/busses/i2c-nomadik.c +++ b/drivers/i2c/busses/i2c-nomadik.c @@ -999,7 +999,7 @@ static int nmk_i2c_probe(struct amba_device *adev, const struct amba_id *id) dev->virtbase = devm_ioremap(&adev->dev, adev->res.start, resource_size(&adev->res)); - if (IS_ERR(dev->virtbase)) { + if (!dev->virtbase) { ret = -ENOMEM; goto err_no_mem; }
devm_ioremap() returns NULL on error, not an error. Cc: Alessandro Rubini <rubini@unipv.it> Cc: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> --- drivers/i2c/busses/i2c-nomadik.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)