diff options
author | Thierry Reding <thierry.reding@avionic-design.de> | 2013-01-21 11:09:14 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-01-22 20:41:57 +0100 |
commit | 9e0c1fb29a7c257a31c321c2437617b6b4d66168 (patch) | |
tree | ee0b93ff33eb3156339a1e72411c8bbad0c8c415 /drivers/pinctrl/pinctrl-nomadik.c | |
parent | misc: Convert to devm_ioremap_resource() (diff) | |
download | linux-9e0c1fb29a7c257a31c321c2437617b6b4d66168.tar.xz linux-9e0c1fb29a7c257a31c321c2437617b6b4d66168.zip |
pinctrl: Convert to devm_ioremap_resource()
Convert all uses of devm_request_and_ioremap() to the newly introduced
devm_ioremap_resource() which provides more consistent error handling.
devm_ioremap_resource() provides its own error messages so all explicit
error messages can be removed from the failure code paths.
Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Cc: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/pinctrl/pinctrl-nomadik.c')
-rw-r--r-- | drivers/pinctrl/pinctrl-nomadik.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/pinctrl/pinctrl-nomadik.c b/drivers/pinctrl/pinctrl-nomadik.c index 1bb16ffb4e41..96e7cfbbce6d 100644 --- a/drivers/pinctrl/pinctrl-nomadik.c +++ b/drivers/pinctrl/pinctrl-nomadik.c @@ -1367,9 +1367,9 @@ static int nmk_gpio_probe(struct platform_device *dev) goto out; } - base = devm_request_and_ioremap(&dev->dev, res); - if (!base) { - ret = -ENOMEM; + base = devm_ioremap_resource(&dev->dev, res); + if (IS_ERR(base)) { + ret = PTR_ERR(base); goto out; } |