diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2014-09-03 07:02:56 -0400 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2014-09-04 04:05:07 -0400 |
commit | 03e9f0cac5da6af85758276cb4624caf5911f2b9 (patch) | |
tree | ce79c1a080347a615b82f2805296f3e3091c01c1 /drivers/pinctrl/pinmux.c | |
parent | 327455817a92522e669d2d11367e42af5956a8ed (diff) |
pinctrl: clean up after enable refactoring
commit 2243a87d90b42eb38bc281957df3e57c712b5e56
"pinctrl: avoid duplicated calling enable_pinmux_setting for a pin"
removed the .disable callback from the struct pinmux_ops,
making the .enable() callback the only remaining callback.
However .enable() is a bad name as it seems to imply that a
muxing can also be disabled. Rename the callback to .set_mux()
and also take this opportunity to clean out any remaining
mentions of .disable() from the documentation.
Acked-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
Acked-by: Fan Wu <fwu@marvell.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/pinmux.c')
-rw-r--r-- | drivers/pinctrl/pinmux.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/pinctrl/pinmux.c b/drivers/pinctrl/pinmux.c index c055daf9a80f..b874458dcb88 100644 --- a/drivers/pinctrl/pinmux.c +++ b/drivers/pinctrl/pinmux.c | |||
@@ -41,7 +41,7 @@ int pinmux_check_ops(struct pinctrl_dev *pctldev) | |||
41 | !ops->get_functions_count || | 41 | !ops->get_functions_count || |
42 | !ops->get_function_name || | 42 | !ops->get_function_name || |
43 | !ops->get_function_groups || | 43 | !ops->get_function_groups || |
44 | !ops->enable) { | 44 | !ops->set_mux) { |
45 | dev_err(pctldev->dev, "pinmux ops lacks necessary functions\n"); | 45 | dev_err(pctldev->dev, "pinmux ops lacks necessary functions\n"); |
46 | return -EINVAL; | 46 | return -EINVAL; |
47 | } | 47 | } |
@@ -445,15 +445,15 @@ int pinmux_enable_setting(struct pinctrl_setting const *setting) | |||
445 | desc->mux_setting = &(setting->data.mux); | 445 | desc->mux_setting = &(setting->data.mux); |
446 | } | 446 | } |
447 | 447 | ||
448 | ret = ops->enable(pctldev, setting->data.mux.func, | 448 | ret = ops->set_mux(pctldev, setting->data.mux.func, |
449 | setting->data.mux.group); | 449 | setting->data.mux.group); |
450 | 450 | ||
451 | if (ret) | 451 | if (ret) |
452 | goto err_enable; | 452 | goto err_set_mux; |
453 | 453 | ||
454 | return 0; | 454 | return 0; |
455 | 455 | ||
456 | err_enable: | 456 | err_set_mux: |
457 | for (i = 0; i < num_pins; i++) { | 457 | for (i = 0; i < num_pins; i++) { |
458 | desc = pin_desc_get(pctldev, pins[i]); | 458 | desc = pin_desc_get(pctldev, pins[i]); |
459 | if (desc) | 459 | if (desc) |