diff --git a/src/devices/wwan/nm-device-modem.c b/src/devices/wwan/nm-device-modem.c index 8e5b70bde..a2f2e7a6f 100644 --- a/src/devices/wwan/nm-device-modem.c +++ b/src/devices/wwan/nm-device-modem.c @@ -384,6 +384,15 @@ modem_state_cb (NMModem *modem, */ nm_modem_set_mm_enabled (priv->modem, priv->rf_enabled); + if (dev_state == NM_DEVICE_STATE_NEED_AUTH) { + /* The modem was unlocked externally to NetworkManager, + deactivate so the default connection can be + automatically activated again */ + nm_device_state_changed (device, + NM_DEVICE_STATE_DEACTIVATING, + NM_DEVICE_STATE_REASON_MODEM_AVAILABLE); + } + /* Now allow connections without a PIN to be available */ nm_device_recheck_available_connections (device); }