Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 91c7709d authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ASoC: wcd: correct handling of GND_MIC_SWAP"

parents 22aa3d45 5be9ddd0
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -974,7 +974,6 @@ static void wcd_correct_swch_plug(struct work_struct *work)
		if ((!(result2 & 0x01)) && (!is_pa_on)) {
			/* Check for cross connection*/
			if (wcd_check_cross_conn(mbhc)) {
				plug_type = MBHC_PLUG_TYPE_GND_MIC_SWAP;
				pt_gnd_mic_swap_cnt++;
				if (pt_gnd_mic_swap_cnt <
						GND_MIC_SWAP_THRESHOLD) {
@@ -987,6 +986,7 @@ static void wcd_correct_swch_plug(struct work_struct *work)
					 */
					pr_debug("%s: switch didnt work\n",
						  __func__);
					plug_type = MBHC_PLUG_TYPE_GND_MIC_SWAP;
					goto report;
				} else if (mbhc->mbhc_cfg->swap_gnd_mic) {
					pr_debug("%s: US_EU gpio present, flip switch\n",
@@ -995,6 +995,7 @@ static void wcd_correct_swch_plug(struct work_struct *work)
					 * if switch is toggled, check again,
					 * otherwise report unsupported plug
					 */
					plug_type = MBHC_PLUG_TYPE_GND_MIC_SWAP;
					if (mbhc->mbhc_cfg->swap_gnd_mic(codec))
						continue;
				}