linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] pinctrl: sunxi: Support generic pinconf functions
@ 2016-11-11  2:44 Chen-Yu Tsai
  2016-11-11  2:44 ` [PATCH v2 1/3] pinctrl: sunxi: Fix PIN_CONFIG_BIAS_PULL_{DOWN,UP} argument Chen-Yu Tsai
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Chen-Yu Tsai @ 2016-11-11  2:44 UTC (permalink / raw)
  To: Linus Walleij, Maxime Ripard
  Cc: Chen-Yu Tsai, linux-gpio, linux-arm-kernel, linux-kernel, linux-sunxi

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 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(-)

-- 
2.10.2

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2016-11-15  9:17 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-11  2:44 [PATCH v2 0/3] pinctrl: sunxi: Support generic pinconf functions Chen-Yu Tsai
2016-11-11  2:44 ` [PATCH v2 1/3] pinctrl: sunxi: Fix PIN_CONFIG_BIAS_PULL_{DOWN,UP} argument Chen-Yu Tsai
2016-11-11  8:34   ` Maxime Ripard
2016-11-15  9:16   ` Linus Walleij
2016-11-11  2:44 ` [PATCH v2 2/3] pinctrl: sunxi: Add support for fetching pinconf settings from hardware Chen-Yu Tsai
2016-11-11  8:36   ` Maxime Ripard
2016-11-11  8:39     ` Chen-Yu Tsai
2016-11-11  2:44 ` [PATCH v2 3/3] pinctrl: sunxi: Make sunxi_pconf_group_set use sunxi_pconf_reg helper Chen-Yu Tsai
2016-11-11  8:38   ` Maxime Ripard
2016-11-11  8:45     ` Chen-Yu Tsai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).