pinctrl: show pin name when request pins
authorDong Aisheng <dong.aisheng@linaro.org>
Tue, 17 Apr 2012 07:00:45 +0000 (15:00 +0800)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 18 Apr 2012 11:53:13 +0000 (13:53 +0200)
Pin name is more useful to users.

Acked-by: Stephen Warren <swarren@wwwdotorg.org>
Signed-off-by: Dong Aisheng <dong.aisheng@linaro.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/pinmux.c

index c494c37bf167d2e6f8ffea19b5ae9d1037790166..fa0357bd88ff638ed28f36ce8c84c9d167a80f6e 100644 (file)
@@ -88,8 +88,6 @@ static int pin_request(struct pinctrl_dev *pctldev,
        const struct pinmux_ops *ops = pctldev->desc->pmxops;
        int status = -EINVAL;
 
-       dev_dbg(pctldev->dev, "request pin %d for %s\n", pin, owner);
-
        desc = pin_desc_get(pctldev, pin);
        if (desc == NULL) {
                dev_err(pctldev->dev,
@@ -97,6 +95,9 @@ static int pin_request(struct pinctrl_dev *pctldev,
                goto out;
        }
 
+       dev_dbg(pctldev->dev, "request pin %d (%s) for %s\n",
+               pin, desc->name, owner);
+
        if (gpio_range) {
                /* There's no need to support multiple GPIO requests */
                if (desc->gpio_owner) {