aboutsummaryrefslogtreecommitdiffstats
path: root/include/dt-bindings/pinctrl
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@openbsd.org>2021-05-20 19:13:06 +0200
committerLinus Walleij <linus.walleij@linaro.org>2021-05-25 17:46:08 +0200
commit710071479cf8c6127791427561a6ba4ee916c07f (patch)
tree787e02a93576690e5222cb0be4d4a1edcdf7092e /include/dt-bindings/pinctrl
parentpinctrl: at91: Constify struct at91_pinctrl_mux_ops (diff)
downloadlinux-dev-710071479cf8c6127791427561a6ba4ee916c07f.tar.xz
linux-dev-710071479cf8c6127791427561a6ba4ee916c07f.zip
dt-bindings: pinctrl: Add DT bindings for apple, pinctrl
The Apple GPIO controller is a simple combined pin and GPIO conroller present on Apple ARM SoC platforms, including various iPhone and iPad devices and the "Apple Silicon" Macs. Signed-off-by: Mark Kettenis <kettenis@openbsd.org> Link: https://lore.kernel.org/r/20210520171310.772-2-mark.kettenis@xs4all.nl Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'include/dt-bindings/pinctrl')
-rw-r--r--include/dt-bindings/pinctrl/apple.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/dt-bindings/pinctrl/apple.h b/include/dt-bindings/pinctrl/apple.h
new file mode 100644
index 000000000000..ea0a6f466592
--- /dev/null
+++ b/include/dt-bindings/pinctrl/apple.h
@@ -0,0 +1,13 @@
+/* SPDX-License-Identifier: GPL-2.0+ OR MIT */
+/*
+ * This header provides constants for Apple pinctrl bindings.
+ */
+
+#ifndef _DT_BINDINGS_PINCTRL_APPLE_H
+#define _DT_BINDINGS_PINCTRL_APPLE_H
+
+#define APPLE_PINMUX(pin, func) ((pin) | ((func) << 16))
+#define APPLE_PIN(pinmux) ((pinmux) & 0xffff)
+#define APPLE_FUNC(pinmux) ((pinmux) >> 16)
+
+#endif /* _DT_BINDINGS_PINCTRL_APPLE_H */