Don't use gpio_free() for output gpios

This change will not request for gpio_free if the gpio_request
is not called for a particular gpio.

Change-Id: I39bedb3495d59334ea61953eaeb8ccf59d6633f8
Signed-off-by: Balakrishna Godavarthi <bgodavar@codeaurora.org>
This commit is contained in:
Balakrishna Godavarthi 2021-03-19 10:54:49 +05:30
commit 90477e8efd

View file

@ -565,11 +565,7 @@ static int bluetooth_power(int on)
gpio_fail:
if (bt_power_pdata->bt_gpio_sys_rst > 0)
gpio_free(bt_power_pdata->bt_gpio_sys_rst);
if (bt_power_pdata->wl_gpio_sys_rst > 0)
gpio_free(bt_power_pdata->wl_gpio_sys_rst);
if (bt_power_pdata->bt_gpio_sw_ctrl > 0)
gpio_free(bt_power_pdata->bt_gpio_sw_ctrl);
if (bt_power_pdata->bt_gpio_debug > 0)
if (bt_power_pdata->bt_gpio_debug > 0)
gpio_free(bt_power_pdata->bt_gpio_debug);
if (bt_power_pdata->bt_chip_clk)
bt_clk_disable(bt_power_pdata->bt_chip_clk);