[PATCH 45/60] Fix double reconnection problem using the same mdlid

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: José Antonio Santos-Cadenas <santoscadenas@xxxxxxxxx>

---
 mcap/mcap.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/mcap/mcap.c b/mcap/mcap.c
index a2cfa8c..18220bc 100644
--- a/mcap/mcap.c
+++ b/mcap/mcap.c
@@ -1076,6 +1076,12 @@ static void process_md_reconnect_mdl_req(struct mcap_mcl *mcl, uint8_t *cmd,
 		send4B_cmd(mcl, MCAP_MD_RECONNECT_MDL_RSP,
 						MCAP_INVALID_MDL, mdl_id);
 		return;
+	} else if (mdl->state == MDL_WAITING || mdl->state == MDL_DELETING ) {
+		/* Creation request arrives for a MDL that is being managed
+		* at current moment */
+		send4B_cmd(mcl, MCAP_MD_RECONNECT_MDL_RSP, MCAP_MDL_BUSY,
+									mdl_id);
+		return;
 	}
 
 	/* Callback to upper layer */
-- 
1.6.3.3

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux