Lines Matching +full:static +full:- +full:enable
1 // SPDX-License-Identifier: GPL-2.0
3 // mt8192-afe-gpio.c -- Mediatek 8192 afe gpio ctrl
11 #include "mt8192-afe-common.h"
12 #include "mt8192-afe-gpio.h"
14 static struct pinctrl *aud_pinctrl;
60 static struct audio_gpio_attr aud_gpios[MT8192_AFE_GPIO_GPIO_NUM] = {
101 static DEFINE_MUTEX(gpio_request_mutex);
103 static int mt8192_afe_gpio_select(struct device *dev, in mt8192_afe_gpio_select()
111 return -EINVAL; in mt8192_afe_gpio_select()
117 return -EIO; in mt8192_afe_gpio_select()
164 static int mt8192_afe_gpio_adda_dl(struct device *dev, bool enable) in mt8192_afe_gpio_adda_dl() argument
166 if (enable) { in mt8192_afe_gpio_adda_dl()
175 static int mt8192_afe_gpio_adda_ul(struct device *dev, bool enable) in mt8192_afe_gpio_adda_ul() argument
177 if (enable) { in mt8192_afe_gpio_adda_ul()
186 static int mt8192_afe_gpio_adda_ch34_dl(struct device *dev, bool enable) in mt8192_afe_gpio_adda_ch34_dl() argument
188 if (enable) { in mt8192_afe_gpio_adda_ch34_dl()
197 static int mt8192_afe_gpio_adda_ch34_ul(struct device *dev, bool enable) in mt8192_afe_gpio_adda_ch34_ul() argument
199 if (enable) { in mt8192_afe_gpio_adda_ch34_ul()
208 int mt8192_afe_gpio_request(struct device *dev, bool enable, in mt8192_afe_gpio_request() argument
215 mt8192_afe_gpio_adda_ul(dev, enable); in mt8192_afe_gpio_request()
217 mt8192_afe_gpio_adda_dl(dev, enable); in mt8192_afe_gpio_request()
221 mt8192_afe_gpio_adda_ch34_ul(dev, enable); in mt8192_afe_gpio_request()
223 mt8192_afe_gpio_adda_ch34_dl(dev, enable); in mt8192_afe_gpio_request()
226 if (enable) in mt8192_afe_gpio_request()
232 if (enable) in mt8192_afe_gpio_request()
238 if (enable) in mt8192_afe_gpio_request()
244 if (enable) in mt8192_afe_gpio_request()
250 if (enable) in mt8192_afe_gpio_request()
256 if (enable) in mt8192_afe_gpio_request()
262 if (enable) in mt8192_afe_gpio_request()
268 if (enable) in mt8192_afe_gpio_request()
274 if (enable) in mt8192_afe_gpio_request()
280 if (enable) in mt8192_afe_gpio_request()
286 if (enable) { in mt8192_afe_gpio_request()
301 return -EINVAL; in mt8192_afe_gpio_request()