Skip to content

Commit

Permalink
uqmi: set CID during 'query-data-status' operation
Browse files Browse the repository at this point in the history
Modems used in ZTE mobile broadband routers require to query the data
session status using the same CID as one used to establish the session,
otherwise they will report the session as "disconnected" despite
reporting correct PDH in previous step. Without this change, IPv6
connection on these modems doesn't establish properly. In IPv4 this bug
is present as well, but for some reason querying of IPv4 status works
using temporary CID, this however seems noncompliant with QMI
specifications, so fix it as well.

Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
  • Loading branch information
Leo-PL authored and dangowrt committed Mar 12, 2022
1 parent 34fd5e3 commit c8a8811
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh
Expand Up @@ -285,7 +285,7 @@ proto_qmi_setup() {
fi

# Check data connection state
connstat=$(uqmi -s -d "$device" --get-data-status)
connstat=$(uqmi -s -d "$device" --set-client-id wds,"$cid_4" --get-data-status)
[ "$connstat" == '"connected"' ] || {
echo "No data link!"
uqmi -s -d "$device" --set-client-id wds,"$cid_4" --release-client-id wds > /dev/null 2>&1
Expand Down Expand Up @@ -322,7 +322,7 @@ proto_qmi_setup() {
fi

# Check data connection state
connstat=$(uqmi -s -d "$device" --get-data-status)
connstat=$(uqmi -s -d "$device" --set-client-id wds,"$cid_6" --get-data-status)
[ "$connstat" == '"connected"' ] || {
echo "No data link!"
uqmi -s -d "$device" --set-client-id wds,"$cid_6" --release-client-id wds > /dev/null 2>&1
Expand Down

0 comments on commit c8a8811

Please sign in to comment.