Loading sound/soc/codecs/wcd-mbhc-v2.c +15 −1 Original line number Diff line number Diff line /* Copyright (c) 2015, The Linux Foundation. All rights reserved. /* Copyright (c) 2015-2016, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -1304,6 +1304,15 @@ exit: micbias2 = mbhc->mbhc_cb->micbias_enable_status(mbhc, MIC_BIAS_2); } if (mbhc->mbhc_cfg->detect_extn_cable && ((plug_type == MBHC_PLUG_TYPE_HEADPHONE) || (plug_type == MBHC_PLUG_TYPE_HEADSET)) && !mbhc->hs_detect_work_stop) { WCD_MBHC_RSC_LOCK(mbhc); wcd_mbhc_hs_elec_irq(mbhc, WCD_MBHC_ELEC_HS_REM, true); WCD_MBHC_RSC_UNLOCK(mbhc); } if (mbhc->mbhc_cb->set_cap_mode) mbhc->mbhc_cb->set_cap_mode(codec, micbias1, micbias2); Loading Loading @@ -1662,6 +1671,10 @@ static irqreturn_t wcd_mbhc_hs_rem_irq(int irq, void *data) } } while (!time_after(jiffies, timeout)); if (wcd_swch_level_remove(mbhc)) { pr_debug("%s: Switch level is low ", __func__); goto exit; } pr_debug("%s: headset %s actually removed\n", __func__, removed ? "" : "not "); Loading Loading @@ -1696,6 +1709,7 @@ static irqreturn_t wcd_mbhc_hs_rem_irq(int irq, void *data) } } } exit: WCD_MBHC_RSC_UNLOCK(mbhc); pr_debug("%s: leave\n", __func__); return IRQ_HANDLED; Loading Loading
sound/soc/codecs/wcd-mbhc-v2.c +15 −1 Original line number Diff line number Diff line /* Copyright (c) 2015, The Linux Foundation. All rights reserved. /* Copyright (c) 2015-2016, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -1304,6 +1304,15 @@ exit: micbias2 = mbhc->mbhc_cb->micbias_enable_status(mbhc, MIC_BIAS_2); } if (mbhc->mbhc_cfg->detect_extn_cable && ((plug_type == MBHC_PLUG_TYPE_HEADPHONE) || (plug_type == MBHC_PLUG_TYPE_HEADSET)) && !mbhc->hs_detect_work_stop) { WCD_MBHC_RSC_LOCK(mbhc); wcd_mbhc_hs_elec_irq(mbhc, WCD_MBHC_ELEC_HS_REM, true); WCD_MBHC_RSC_UNLOCK(mbhc); } if (mbhc->mbhc_cb->set_cap_mode) mbhc->mbhc_cb->set_cap_mode(codec, micbias1, micbias2); Loading Loading @@ -1662,6 +1671,10 @@ static irqreturn_t wcd_mbhc_hs_rem_irq(int irq, void *data) } } while (!time_after(jiffies, timeout)); if (wcd_swch_level_remove(mbhc)) { pr_debug("%s: Switch level is low ", __func__); goto exit; } pr_debug("%s: headset %s actually removed\n", __func__, removed ? "" : "not "); Loading Loading @@ -1696,6 +1709,7 @@ static irqreturn_t wcd_mbhc_hs_rem_irq(int irq, void *data) } } } exit: WCD_MBHC_RSC_UNLOCK(mbhc); pr_debug("%s: leave\n", __func__); return IRQ_HANDLED; Loading