forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-12-19 9370bb92b2d16684ee45cf24e879c93c509162da
kernel/drivers/pinctrl/pinmux.h
....@@ -1,3 +1,4 @@
1
+/* SPDX-License-Identifier: GPL-2.0-only */
12 /*
23 * Internal interface between the core pin control system and the
34 * pinmux portions
....@@ -7,14 +8,14 @@
78 * Based on bits of regulator core, gpio core and clk core
89 *
910 * Author: Linus Walleij <linus.walleij@linaro.org>
10
- *
11
- * License terms: GNU General Public License (GPL) version 2
1211 */
1312 #ifdef CONFIG_PINMUX
1413
1514 int pinmux_check_ops(struct pinctrl_dev *pctldev);
1615
1716 int pinmux_validate_map(const struct pinctrl_map *map, int i);
17
+
18
+bool pinmux_can_be_used_for_gpio(struct pinctrl_dev *pctldev, unsigned pin);
1819
1920 int pinmux_request_gpio(struct pinctrl_dev *pctldev,
2021 struct pinctrl_gpio_range *range,
....@@ -43,6 +44,12 @@
4344 return 0;
4445 }
4546
47
+static inline bool pinmux_can_be_used_for_gpio(struct pinctrl_dev *pctldev,
48
+ unsigned pin)
49
+{
50
+ return true;
51
+}
52
+
4653 static inline int pinmux_request_gpio(struct pinctrl_dev *pctldev,
4754 struct pinctrl_gpio_range *range,
4855 unsigned pin, unsigned gpio)