Problems with modemmanager and Sierra EM7345 on resume

Aleksander Morgado aleksander at aleksander.es
Mon Feb 23 03:31:32 PST 2015


On Mon, Feb 23, 2015 at 10:40 AM, Alfredo Palhares
<masterkorp at masterkorp.net> wrote:
> I have this problem too.
>

I don't think it's the same issue; just same symptom.

> Currently on a thinkpad x240 with the Ericsson N5321 gw and I use
> modemmanger on a set of bash scripts (netctl) and the increment on the
> modem number always makes it non working.
>

After a suspend/resume cycle, the modem may be fully powered off/on,
and that means that ModemManager will see kernel events where the
device disappears and re-appears. From the ModemManager point of view,
the newly appeared modem is a totally different modem, and hence the
newly exported object in DBus gets a new number. This is not an error
or a problem that it's going to get fixed...

> I guess if there is not solution for this I will need to make a parser
> for mmcli -L output and parse the modem number.

That is one thing you could do, yes.

Or otherwise avoid using mmcli at all in that way, and set up your own
script to listen for e.g. newly added modems via DBus. This is an
example doing that in Python:
http://cgit.freedesktop.org/ModemManager/ModemManager/tree/examples/modem-watcher-python

Or even in Javascript, if you're into that:
http://cgit.freedesktop.org/ModemManager/ModemManager/tree/examples/modem-watcher-javascript

If you do want to somehow detect that a specific modem was exported in
DBus with some other path after a suspend/resume, you can look at the
"EquipmentIdentifier" property, which should be the same regardless of
the modem reboots:
http://www.freedesktop.org/software/ModemManager/api/latest/gdbus-org.freedesktop.ModemManager1.Modem.html#gdbus-property-org-freedesktop-ModemManager1-Modem.EquipmentIdentifier

Cheers!

-- 
Aleksander
https://aleksander.es


More information about the ModemManager-devel mailing list