diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2012-02-09 19:34:12 -0500 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2012-02-10 15:33:10 -0500 |
commit | 77a5988355f993840928d195f790a939200a4ff0 (patch) | |
tree | b2590450fb4c5e956ddfc119e6bb610ce53aa8a9 /drivers/pinctrl | |
parent | befe5bdfbb698b3bc57c58d0bd7ca3391c9275ed (diff) |
pinctrl: changes hog mechanism to be self-referential
Instead of a specific boolean field to indicate if a map entry shall
be hogged, treat self-reference as an indication of desired hogging.
This drops one field off the map struct and has a nice Douglas R.
Hofstadter-feel to it.
Acked-by: Dong Aisheng <dong.aisheng@linaro.org>
Acked-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl')
-rw-r--r-- | drivers/pinctrl/core.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index ec32c545f07f..c5f76ad5a8c5 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c | |||
@@ -793,11 +793,9 @@ int pinctrl_hog_maps(struct pinctrl_dev *pctldev) | |||
793 | for (i = 0; i < pinctrl_maps_num; i++) { | 793 | for (i = 0; i < pinctrl_maps_num; i++) { |
794 | struct pinctrl_map const *map = &pinctrl_maps[i]; | 794 | struct pinctrl_map const *map = &pinctrl_maps[i]; |
795 | 795 | ||
796 | if (!map->hog_on_boot) | ||
797 | continue; | ||
798 | |||
799 | if (map->ctrl_dev_name && | 796 | if (map->ctrl_dev_name && |
800 | !strcmp(map->ctrl_dev_name, devname)) { | 797 | !strcmp(map->ctrl_dev_name, devname) && |
798 | !strcmp(map->dev_name, devname)) { | ||
801 | /* OK time to hog! */ | 799 | /* OK time to hog! */ |
802 | ret = pinctrl_hog_map(pctldev, map); | 800 | ret = pinctrl_hog_map(pctldev, map); |
803 | if (ret) | 801 | if (ret) |