From c4b311a7d074f3211add8cd8ff8febcd6e85a009 Mon Sep 17 00:00:00 2001 From: Saravana Kannan Date: Thu, 14 Nov 2019 17:39:06 -0800 Subject: [PATCH] ANDROID: GKI: of: property: Add device links support for pinctrl-[0-3] pinctrl-[0..n] property is used to point to pin controllers. However, there are other pinctrl-* properties that don't point to suppliers. To keep the parsing simple, for now, add support only for pinctrl-[0..3] properties as there's only one or two devices in the tree that have more than pinctrl-3. Bug: 144864161 Signed-off-by: Saravana Kannan Signed-off-by: Will McVicker (cherry picked from commit 3579c811e2ef195ab0a1c452a3d8966af40bf731) Change-Id: Ia063ffecc7429c77a9c9ff7c31c431167225a62f --- drivers/of/property.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/of/property.c b/drivers/of/property.c index e707fcc63a9d..3909b95e95d6 100644 --- a/drivers/of/property.c +++ b/drivers/of/property.c @@ -1219,6 +1219,10 @@ DEFINE_SIMPLE_PROP(mboxes, "mboxes", "#mbox-cells") DEFINE_SIMPLE_PROP(io_channels, "io-channel", "#io-channel-cells") DEFINE_SIMPLE_PROP(interrupt_parent, "interrupt-parent", NULL) DEFINE_SIMPLE_PROP(dmas, "dmas", "#dma-cells") +DEFINE_SIMPLE_PROP(pinctrl0, "pinctrl-0", NULL) +DEFINE_SIMPLE_PROP(pinctrl1, "pinctrl-1", NULL) +DEFINE_SIMPLE_PROP(pinctrl2, "pinctrl-2", NULL) +DEFINE_SIMPLE_PROP(pinctrl3, "pinctrl-3", NULL) DEFINE_SUFFIX_PROP(regulators, "-supply", NULL) DEFINE_SUFFIX_PROP(gpio, "-gpio", "#gpio-cells") DEFINE_SUFFIX_PROP(gpios, "-gpios", "#gpio-cells") @@ -1243,6 +1247,10 @@ static const struct supplier_bindings of_supplier_bindings[] = { { .parse_prop = parse_io_channels, }, { .parse_prop = parse_interrupt_parent, }, { .parse_prop = parse_dmas, }, + { .parse_prop = parse_pinctrl0, }, + { .parse_prop = parse_pinctrl1, }, + { .parse_prop = parse_pinctrl2, }, + { .parse_prop = parse_pinctrl3, }, { .parse_prop = parse_regulators, }, { .parse_prop = parse_gpio, }, { .parse_prop = parse_gpios, },