summaryrefslogtreecommitdiff
path: root/drivers/pinctrl/pinctrl-uclass.c
diff options
context:
space:
mode:
authorPatrick Delaunay <patrick.delaunay@st.com>2019-08-02 14:48:00 +0200
committerSimon Glass <sjg@chromium.org>2019-10-15 08:40:02 -0600
commitc20851b3d850dd859f202d2395e8dde0fc81c1ce (patch)
treeb00e94a54de5a26abdbc0bb13c9f3ce1441dec32 /drivers/pinctrl/pinctrl-uclass.c
parentd1d5ffd554a88562a88801273a2f8d134827605a (diff)
dm: pinctrl: introduce PINCONF_RECURSIVE option
In the Linux pinctrl binding, the pin configuration nodes don't need to be direct children of the pin controller device (may be grandchildren for example). This behavior is managed with the pinconfig u-class which recursively bind all the sub-node of the pin controller. But for some binding (when pin configuration is only children of pin controller) that is not necessary. U-Boot can save memory and reduce the number of pinconf instance when this feature is deactivated (for arch stm32mp for example for SPL). This patch allows to control this feature with a new option CONFIG_PINCONF_RECURSIVE when it is possible for each individual pin controller device. Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com> Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/pinctrl/pinctrl-uclass.c')
-rw-r--r--drivers/pinctrl/pinctrl-uclass.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/pinctrl/pinctrl-uclass.c b/drivers/pinctrl/pinctrl-uclass.c
index 5b1cd29d86..bf799a701c 100644
--- a/drivers/pinctrl/pinctrl-uclass.c
+++ b/drivers/pinctrl/pinctrl-uclass.c
@@ -151,7 +151,9 @@ static int pinconfig_post_bind(struct udevice *dev)
UCLASS_DRIVER(pinconfig) = {
.id = UCLASS_PINCONFIG,
+#if CONFIG_IS_ENABLED(PINCONFIG_RECURSIVE)
.post_bind = pinconfig_post_bind,
+#endif
.name = "pinconfig",
};