From 600d648a0db310de25d554fcebcdb46e682ae274 Mon Sep 17 00:00:00 2001
From: Nickolay Ledovskikh <nledovskikh@gmail.com>
Date: Fri, 16 Dec 2016 15:41:06 +0300
Subject: [PATCH] uqmi: Prevent 'POLICY MISMATH' error.

Add uqmi 'sync' command call to release stalled cid when preparing to
setup new connection. As a result it prevents 'POLICY MISMATCH' errors.

Signed-off-by: Nickolay Ledovskikh <nledovskikh@gmail.com>
---
 package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh b/package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh
index cab9cb9121..1f260ae3c2 100755
--- a/package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh
+++ b/package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh
@@ -78,6 +78,7 @@ proto_qmi_setup() {
 
 	uqmi -s -d "$device" --set-data-format 802.3
 	uqmi -s -d "$device" --wda-set-data-format 802.3
+	uqmi -s -d "$device" --sync
 
 	echo "Waiting for network registration"
 	while uqmi -s -d "$device" --get-serving-system | grep '"searching"' > /dev/null; do
-- 
2.30.2