Message ID | 20210628115614.94579-2-ontje.luensdorf@dlr.de |
---|---|
State | Changes Requested |
Delegated to: | Petr Štetiar |
Headers | show |
Series | Workaround for rut955 modem initialization | expand |
Hi Ontje, On 28.06.2021 13:56, Ontje.Luensdorf@dlr.de wrote: > From: Ontje Lünsdorf <ontje.luensdorf@dlr.de> > > The rut955 fails to activate its modem upon every second reboot otherwise. This will issue reset every time the qmi connection is (re-)initialized, making the whole (re-)connection process much longer. Does the modem really need to be reset every time the connection is brought up or just once, after the bootup? IIRC, RUT9xx series has a dedicated GPIO for modem power enable/disable. How about using that instead?
Hello Ontje, On Mon, Jun 28, 2021 at 3:00 PM <Ontje.Luensdorf@dlr.de> wrote: > The rut955 fails to activate its modem upon every second reboot otherwise. What does it mean "fails to activate modem"? Could you be more specific? A bit more detailed issue description will be helpful if someone faces a similar case, even possibly with another modem model. Whether the modem does not respond at all or it is unable to establish a new data connection? Did you try to purge the modem clients list and then reestablish the connection? > Co-authored-by: hans-hermann.redenius@dlr.de > Co-authored-by: jonas.stuehrenberg@dlr.de BTW, you missed the Signed-of-by :) > --- > package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh | 4 ++++ > 1 file changed, 4 insertions(+) > > 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 c0134f4..60695ec 100755 > --- a/package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh > +++ b/package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh > @@ -81,6 +81,10 @@ proto_qmi_setup() { > > echo "Waiting for SIM initialization" > local uninitialized_timeout=0 > + > + # Reset modem, workaround for a buggy modem after an reboot > + uqmi -s -d "$device" --set-device-operating-mode reset > + As already mentioned by Piotr, resetting the modem on each connection establishing attempt is overkill. Did you consider using a hotplug script to reset the modem after the initial detection? With a hotplug script you even will be able to reset only a specific buggy modem model and reduce side-effects. -- Sergey
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 c0134f4..60695ec 100755 --- a/package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh +++ b/package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh @@ -81,6 +81,10 @@ proto_qmi_setup() { echo "Waiting for SIM initialization" local uninitialized_timeout=0 + + # Reset modem, workaround for a buggy modem after an reboot + uqmi -s -d "$device" --set-device-operating-mode reset + while uqmi -s -d "$device" --get-pin-status | grep '"UIM uninitialized"' > /dev/null; do [ -e "$device" ] || return 1 if [ "$uninitialized_timeout" -lt "$timeout" -o "$timeout" = "0" ]; then
From: Ontje Lünsdorf <ontje.luensdorf@dlr.de> The rut955 fails to activate its modem upon every second reboot otherwise. Co-authored-by: hans-hermann.redenius@dlr.de Co-authored-by: jonas.stuehrenberg@dlr.de --- package/network/utils/uqmi/files/lib/netifd/proto/qmi.sh | 4 ++++ 1 file changed, 4 insertions(+)