Skip to content

pintrcl: restore old state when pinctrl_select_state fails

Richard Genoud lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 15 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4pinctrl: fix typo in headerdrivers/pinctrl/core.h+1 -11 reply
2/4pinctrl: create pinctrl_free_setting functiondrivers/pinctrl/core.c+19 -131 reply
3/4pinctrl: disable and free setting in select_state in case of errordrivers/pinctrl/core.c+25 -37 replies
4/4pinctrl: re-enable old state in case of error in pinctrl_select_statedrivers/pinctrl/core.c+19 -16 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/4] pintrcl: restore old state when pinctrl_select_state fails

If there's an error when applying a new state (for example, if a pin is already muxed), old state is not restored. This patch set corrects this behaviour.
The first patch is just a small typo fix.
The second doesn't introduce any functionnal change, but prepares for the third patch.
The third patch undoes what have been done to enable the new state.
The last patch re-applies the old state.

Richard Genoud (4):
pinctrl: fix typo in header
pinctrl: create pinctrl_free_setting function
pinctrl: disable and free setting in select_state in case of error
pinctrl: re-enable old state in case of error in pinctrl_select_state

 drivers/pinctrl/core.c |   78 ++++++++++++++++++++++++++++++++++++++----------
 drivers/pinctrl/core.h |    2 +-
 2 files changed, 63 insertions(+), 17 deletions(-)
Signature · 1 line
1.7.2.5