@@ -12,4 +12,8 @@ config PINCTRL_UNIPHIER_PH1_PRO4
bool "UniPhier PH1-Pro4 SoC pinctrl driver"
select PINCTRL_UNIPHIER_CORE
+config PINCTRL_UNIPHIER_PH1_SLD8
+ bool "UniPhier PH1-sLD8 SoC pinctrl driver"
+ select PINCTRL_UNIPHIER_CORE
+
endif
@@ -2,3 +2,4 @@ obj-$(CONFIG_PINCTRL_UNIPHIER_CORE) += pinctrl-uniphier-core.o
obj-$(CONFIG_PINCTRL_UNIPHIER_PH1_LD4) += pinctrl-ph1-ld4.o
obj-$(CONFIG_PINCTRL_UNIPHIER_PH1_PRO4) += pinctrl-ph1-pro4.o
+obj-$(CONFIG_PINCTRL_UNIPHIER_PH1_SLD8) += pinctrl-ph1-sld8.o
new file mode 100644
@@ -0,0 +1,65 @@
+/*
+ * Copyright (C) 2015 Masahiro Yamada <yamada.masahiro@socionext.com>
+ *
+ * SPDX-License-Identifier: GPL-2.0+
+ */
+
+#include <dm/device.h>
+#include <dm/pinctrl.h>
+
+#include "pinctrl-uniphier.h"
+
+static const struct uniphier_mux i2c0_mux[] = {{102, 0}, {103, 0}};
+static const struct uniphier_mux i2c1_mux[] = {{104, 0}, {105, 0}};
+static const struct uniphier_mux i2c2_mux[] = {{108, 2}, {109, 2}};
+static const struct uniphier_mux i2c3_mux[] = {{108, 3}, {109, 3}};
+static const struct uniphier_mux uart0_mux[] = {{70, 3}, {71, 3}};
+static const struct uniphier_mux uart1_mux[] = {{114, 0}, {115, 0}};
+static const struct uniphier_mux uart2_mux[] = {{112, 1}, {113, 1}};
+static const struct uniphier_mux uart3_mux[] = {{110, 1}, {111, 1}};
+static const struct uniphier_mux usb0_mux[] = {{41, 0}, {42, 0}};
+static const struct uniphier_mux usb1_mux[] = {{43, 0}, {44, 0}};
+static const struct uniphier_mux usb2_mux[] = {{114, 1}, {115, 1}};
+
+static const struct uniphier_pinmux_data ph1_sld8_pinmux_data[] = {
+ UNIPHIER_PINMUX_DATA(i2c0, i2c0),
+ UNIPHIER_PINMUX_DATA(i2c1, i2c1),
+ UNIPHIER_PINMUX_DATA(i2c2, i2c2),
+ UNIPHIER_PINMUX_DATA(i2c3, i2c3),
+ UNIPHIER_PINMUX_DATA(uart0, uart0),
+ UNIPHIER_PINMUX_DATA(uart1, uart1),
+ UNIPHIER_PINMUX_DATA(uart2, uart2),
+ UNIPHIER_PINMUX_DATA(uart3, uart3),
+ UNIPHIER_PINMUX_DATA(usb0, usb0),
+ UNIPHIER_PINMUX_DATA(usb1, usb1),
+ UNIPHIER_PINMUX_DATA(usb2, usb2),
+};
+
+static struct uniphier_pinctrl_socdata ph1_sld8_pinctrl_socdata = {
+ .pinmux_data = ph1_sld8_pinmux_data,
+ .num_pinmux_data = ARRAY_SIZE(ph1_sld8_pinmux_data),
+ .mux_bits = 8,
+ .reg_stride = 4,
+ .load_pinctrl = false,
+};
+
+static int ph1_sld8_pinctrl_probe(struct udevice *dev)
+{
+ return uniphier_pinctrl_probe(dev, &ph1_sld8_pinctrl_socdata);
+}
+
+static const struct udevice_id ph1_sld8_pinctrl_match[] = {
+ { .compatible = "socionext,ph1-sld8-pinctrl" },
+ { /* sentinel */ }
+};
+
+U_BOOT_DRIVER(ph1_sld8_pinctrl) = {
+ .name = "ph1-sld8-pinctrl",
+ .id = UCLASS_PINCTRL,
+ .of_match = of_match_ptr(ph1_sld8_pinctrl_match),
+ .probe = ph1_sld8_pinctrl_probe,
+ .remove = uniphier_pinctrl_remove,
+ .priv_auto_alloc_size = sizeof(struct uniphier_pinctrl_priv),
+ .ops = &uniphier_pinctrl_ops,
+ .flags = DM_FLAG_PRE_RELOC,
+};
Add pinmux support for UniPhier PH1-sLD8 SoC. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> --- drivers/pinctrl/uniphier/Kconfig | 4 ++ drivers/pinctrl/uniphier/Makefile | 1 + drivers/pinctrl/uniphier/pinctrl-ph1-sld8.c | 65 +++++++++++++++++++++++++++++ 3 files changed, 70 insertions(+) create mode 100644 drivers/pinctrl/uniphier/pinctrl-ph1-sld8.c