From 08a4bad48feec75a6c60736034d28d5e573f9606 Mon Sep 17 00:00:00 2001 From: Satish Kodishala Date: Fri, 11 Dec 2020 13:53:00 +0530 Subject: [PATCH] Ignore -106 error while opening channel Ignore -106 error when channel opened again without closing. CRs-Fixed: 2836671 Change-Id: Ib27179031e6bbdc20511132efd6c4578d1d0a911 Signed-off-by: Satish Kodishala --- drivers/bluetooth/btfm_slim_codec.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/drivers/bluetooth/btfm_slim_codec.c b/drivers/bluetooth/btfm_slim_codec.c index 4f4cbe738e50..deafd9b8edb4 100644 --- a/drivers/bluetooth/btfm_slim_codec.c +++ b/drivers/bluetooth/btfm_slim_codec.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0-only /* - * Copyright (c) 2016-2019, The Linux Foundation. All rights reserved. + * Copyright (c) 2016-2020, The Linux Foundation. All rights reserved. */ #include @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include @@ -209,6 +210,11 @@ static int btfm_slim_dai_prepare(struct snd_pcm_substream *substream, /* save the enable channel status */ if (ret == 0) bt_soc_enable_status = 1; + + if (ret == -EISCONN) { + BTFMSLIM_ERR("channel opened without closing, returning success"); + ret = 0; + } return ret; }