summaryrefslogtreecommitdiff
path: root/drivers/pinctrl/pinconf.c
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2016-05-24 14:26:26 +0900
committerLinus Walleij <linus.walleij@linaro.org>2016-05-31 10:19:56 +0200
commitcf9d994dcf00c09c73eb686e239ab6449a248719 (patch)
tree45c00681c4a16285e0a3e194717060e9a69d1e03 /drivers/pinctrl/pinconf.c
parent4fac724fd76623c65ad00b412f5c7d0a816b98ff (diff)
pinctrl: do not care about blank pin name
If a pin name is not specified in struct pinctrl_pin_desc, pinctrl_register_one_pin() dynamically assigns its name. So, desc->name is always a valid pointer here. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/pinconf.c')
-rw-r--r--drivers/pinctrl/pinconf.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/pinctrl/pinconf.c b/drivers/pinctrl/pinconf.c
index 4dd7722f9935..3f1b6f03abc9 100644
--- a/drivers/pinctrl/pinconf.c
+++ b/drivers/pinctrl/pinconf.c
@@ -258,8 +258,7 @@ void pinconf_show_setting(struct seq_file *s,
case PIN_MAP_TYPE_CONFIGS_PIN:
desc = pin_desc_get(setting->pctldev,
setting->data.configs.group_or_pin);
- seq_printf(s, "pin %s (%d)",
- desc->name ? desc->name : "unnamed",
+ seq_printf(s, "pin %s (%d)", desc->name,
setting->data.configs.group_or_pin);
break;
case PIN_MAP_TYPE_CONFIGS_GROUP:
@@ -311,8 +310,7 @@ static int pinconf_pins_show(struct seq_file *s, void *what)
if (desc == NULL)
continue;
- seq_printf(s, "pin %d (%s):", pin,
- desc->name ? desc->name : "unnamed");
+ seq_printf(s, "pin %d (%s):", pin, desc->name);
pinconf_dump_pin(pctldev, s, pin);