]> git.baikalelectronics.ru Git - kernel.git/commit
pinctrl: stm32: use valid pin identifier in stm32_pinctrl_resume()
authorFabien Dessenne <fabien.dessenne@foss.st.com>
Fri, 8 Oct 2021 12:25:17 +0000 (14:25 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 27 Oct 2021 07:54:30 +0000 (09:54 +0200)
commita53488294381d12394d4e78e6060aebf71983323
treec4d6676c78b76b051e0ecfeb361fad3054077c21
parent19cd20b2089e86d5f3122c9fda62e74c34d08848
pinctrl: stm32: use valid pin identifier in stm32_pinctrl_resume()

commit c370bb474016ab9edfdabd7c08a88dd13a71ddbd upstream.

When resuming from low power, the driver attempts to restore the
configuration of some pins. This is done by a call to:
  stm32_pinctrl_restore_gpio_regs(struct stm32_pinctrl *pctl, u32 pin)
where 'pin' must be a valid pin value (i.e. matching some 'groups->pin').
Fix the current implementation which uses some wrong 'pin' value.

Fixes: ea7a013e78a8 ("pinctrl: stm32: add suspend/resume management")
Signed-off-by: Fabien Dessenne <fabien.dessenne@foss.st.com>
Link: https://lore.kernel.org/r/20211008122517.617633-1-fabien.dessenne@foss.st.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/pinctrl/stm32/pinctrl-stm32.c