uqmi: wait before creating PDP connection uqmi-optimization-known-good
authorDavid Bauer <mail@david-bauer.net>
Sun, 8 Oct 2023 23:59:22 +0000 (01:59 +0200)
committerDavid Bauer <mail@david-bauer.net>
Mon, 9 Oct 2023 02:52:38 +0000 (04:52 +0200)
The modem needs a short moment before it can establish a PDP session
after it attached to the network.

Wait 5 seconds before attempting to create a PDP session. Otherwise,
this process is very racy and might take multiple attempts after a
connection is initially lost.

Signed-off-by: David Bauer <mail@david-bauer.net>
package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh

index 025cfde9bf5f4b761392d07f07b4cc17822d1c24..3e538a73eea17b0ccdd27f9b58dfc60c67da28f2 100755 (executable)
@@ -278,6 +278,8 @@ proto_qmi_setup() {
 
        [ -n "$modes" ] && uqmi -s -d "$device" --set-network-modes "$modes" > /dev/null 2>&1
 
+       sleep 5
+
        echo "Starting network $interface"
 
        pdptype="$(echo "$pdptype" | awk '{print tolower($0)}')"