diff options
| author | Laxminath Kasam <lkasam@codeaurora.org> | 2016-12-14 20:00:35 +0530 |
|---|---|---|
| committer | Laxminath Kasam <lkasam@codeaurora.org> | 2016-12-17 11:38:24 +0530 |
| commit | 69898f67286504e23e5433afe9f1a6c473a89c6b (patch) | |
| tree | 6a069d9a1c6f7926e72b647b65f70c8d17ced118 /drivers/mfd | |
| parent | 7296f6d92b1c4e92aa90990621434f02bbe1d5ed (diff) | |
ASoC: msm: migrate to cdc pinctrl functions
For audio pinctrl settings in internal codec,
use cdc pinctrl functions to activate and
suspend gpios.
Change-Id: Ib0de01379a02636d35b49770aa82ea53de7c2768
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
Diffstat (limited to 'drivers/mfd')
| -rw-r--r-- | drivers/mfd/msm-cdc-pinctrl.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/drivers/mfd/msm-cdc-pinctrl.c b/drivers/mfd/msm-cdc-pinctrl.c index 3ffd20245877..9622256a280d 100644 --- a/drivers/mfd/msm-cdc-pinctrl.c +++ b/drivers/mfd/msm-cdc-pinctrl.c @@ -180,13 +180,15 @@ static int msm_cdc_pinctrl_probe(struct platform_device *pdev) ret = PTR_ERR(gpio_data->pinctrl_sleep); goto err_lookup_state; } - - /* Set pinctrl state to aud_sleep by default */ - ret = pinctrl_select_state(gpio_data->pinctrl, - gpio_data->pinctrl_sleep); - if (ret) - dev_err(&pdev->dev, "%s: set cdc gpio sleep state fail: %d\n", - __func__, ret); + /* skip setting to sleep state for LPI_TLMM GPIOs */ + if (!of_property_read_bool(pdev->dev.of_node, "qcom,lpi-gpios")) { + /* Set pinctrl state to aud_sleep by default */ + ret = pinctrl_select_state(gpio_data->pinctrl, + gpio_data->pinctrl_sleep); + if (ret) + dev_err(&pdev->dev, "%s: set cdc gpio sleep state fail: %d\n", + __func__, ret); + } gpio_data->gpio = of_get_named_gpio(pdev->dev.of_node, "qcom,cdc-rst-n-gpio", 0); |
