diff options
author | Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> | 2013-11-28 19:20:03 +0400 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2013-12-03 13:38:39 +0400 |
commit | 5d27619498ab468e8c7e67844c640ad0915e8d85 (patch) | |
tree | 014bdb13f0f3657fbb59c9f985d173a7c8bed3a0 /drivers/pinctrl/sh-pfc/pfc-r8a7740.c | |
parent | a9e51fe5e610dce8110ec383f50b96eeadd568e0 (diff) | |
download | linux-5d27619498ab468e8c7e67844c640ad0915e8d85.tar.xz |
sh-pfc: r8a7740: Fix pin bias setup
When computing the pin configuration register offset the bias setup code
erroneously compares the pin number range with the loop index instead of
the pin number. Fix it.
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/sh-pfc/pfc-r8a7740.c')
-rw-r--r-- | drivers/pinctrl/sh-pfc/pfc-r8a7740.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pinctrl/sh-pfc/pfc-r8a7740.c b/drivers/pinctrl/sh-pfc/pfc-r8a7740.c index 009174d07767..bc5eb453a45c 100644 --- a/drivers/pinctrl/sh-pfc/pfc-r8a7740.c +++ b/drivers/pinctrl/sh-pfc/pfc-r8a7740.c @@ -3720,7 +3720,7 @@ static void __iomem *r8a7740_pinmux_portcr(struct sh_pfc *pfc, unsigned int pin) const struct r8a7740_portcr_group *group = &r8a7740_portcr_offsets[i]; - if (i <= group->end_pin) + if (pin <= group->end_pin) return pfc->window->virt + group->offset + pin; } |