Skip to content

pinctrl: sunxi: Support generic pinconf functions

Chen-Yu Tsai linux-arm-kernel linux-gpio lkml 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest3 patches 5 repliesIn review
  2. v23 patches 6 repliesSuperseded
  3. v13 patches 5 repliesSuperseded

Changes in v3 from the cover letter

- Added Maxime's ack.

- Moved the removal of the cached config value from patch 3 to patch 2 at Maxime's request.

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3pinctrl: sunxi: Fix PIN_CONFIG_BIAS_PULL_{DOWN,UP} argumentdrivers/pinctrl/sunxi/pinctrl-sunxi.c+5 -11 reply
2/3pinctrl: sunxi: Add support for fetching pinconf settings from hardwaredrivers/pinctrl/sunxi/pinctrl-sunxi.c drivers/pinctrl/sunxi/pinctrl-sunxi.h+81 -63 replies
3/3pinctrl: sunxi: Make sunxi_pconf_group_set use sunxi_pconf_reg helperdrivers/pinctrl/sunxi/pinctrl-sunxi.c+32 -321 reply

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchMaxime Ripard
1/3A-b
2/3A-b
3/3A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/3] pinctrl: sunxi: Support generic pinconf functions

Hi everyone,

This series fixes up generic pinconf support for the sunxi pinctrl driver library. The driver was doing some bits wrong, like a) storing the pinconf config value in its struct, and not actually reading the hardware to get the current config, and b) not using the right arguments for the bias parameters.

Patch 1 fixes the pin bias parameter arguments.

Patch 2 makes the driver read out pinconf settings from the hardware, and returns the correct value for unsupported features and disable features. With this in place it also declares itself as generic pinconf compatible, which enables us to read the config through the debugfs pinconf interface.

Patch 3 makes the sunxi_pconf_group_set callback use the helper function introduced in patch 1.

Changes since v2:

- Added Maxime's ack.

- Moved the removal of the cached config value from patch 3 to patch 2 at Maxime's request.

Changes since v1:

- Rebased onto the updated sunxi pinctrl driver with support for the generic pinconf bindings

- Use separate value for what is written to the register in the pinconf set function, as Maxime requested.

Regards
ChenYu

Chen-Yu Tsai (3):
pinctrl: sunxi: Fix PIN_CONFIG_BIAS_PULL_{DOWN,UP} argument
pinctrl: sunxi: Add support for fetching pinconf settings from
hardware
pinctrl: sunxi: Make sunxi_pconf_group_set use sunxi_pconf_reg helper

 drivers/pinctrl/sunxi/pinctrl-sunxi.c | 156 +++++++++++++++++++++++++---------
 drivers/pinctrl/sunxi/pinctrl-sunxi.h |   1 -
 2 files changed, 118 insertions(+), 39 deletions(-)
Signature · 1 line
2.10.2