uqmi: fix PIN_STATUS_FAILED error with MC7455 WCDMA/LTE modem
[openwrt/staging/pepe2k.git] / package / network / utils / uqmi / files / lib / netifd / proto / qmi.sh
index 9b2f69f009f467e204dcab6f6c8557398057179f..1da98db5ac7b35d39143b8393bff8b1bdcf06d59 100755 (executable)
@@ -83,7 +83,7 @@ proto_qmi_setup() {
                fi
        done
 
-       if uqmi -s -d "$device" --get-pin-status | grep '"Not supported"' > /dev/null; then
+       if uqmi -s -d "$device" --get-pin-status | grep '"Not supported"\|"Invalid QMI command"' > /dev/null; then
                [ -n "$pincode" ] && {
                        uqmi -s -d "$device" --verify-pin1 "$pincode" > /dev/null || uqmi -s -d "$device" --uim-verify-pin1 "$pincode" > /dev/null || {
                                echo "Unable to verify PIN"