some sierra modem tty's get killed by CFUN=1

Bug #459052 reported by Alexander Sack
58
This bug affects 9 people
Affects Status Importance Assigned to Milestone
ModemManager
Fix Released
Undecided
Unassigned
modemmanager (Ubuntu)
Fix Released
High
Unassigned

Bug Description

Binary package hint: modemmanager

spin from bug 452427 ... for sierra the tty seems to go away if CFUN=1 is send. might be that its just a few modems, but until we understand that we should not send CFUN=1 ....

Revision history for this message
Alexander Sack (asac) wrote :
Changed in modemmanager (Ubuntu):
importance: Undecided → High
milestone: none → karmic-updates
status: New → In Progress
assignee: nobody → Alexander Sack (asac)
Revision history for this message
Alexander Sack (asac) wrote : Re: [Bug 459052] Re: some sierra modem tty's get killed by CFUN=1

On Fri, Oct 23, 2009 at 01:01:51PM -0000, Alexander Sack wrote:
>
> ** Attachment added: "patch: do not use CFUN=1 command for sierras"
> http://launchpadlibrarian.net/34248245/lp452427_sierra_cfun.patch
>

The problem seems to be that some sierra modems need this CFUN=1 as
they are regularly powered down on startup ... while other sierra
modems crash on CFUN=1 (like you do ) ... can you please attach the
output of lsusb and also minicom against your tty and check what an
AT+ATI gives you?

 - Alexander

Revision history for this message
vak (khamenya) wrote :

Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 007 Device 002: ID 1199:6832 Sierra Wireless, Inc. MC8780 Device
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 002: ID 0c24:000f Taiyo Yuden Bluetooth Driver (V2.0+EDR)
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 002: ID 08ff:2580 AuthenTec, Inc. AES2501 Fingerprint Sensor
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 003: ID 046d:09b2 Logitech, Inc. Fujitsu Webcam
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Revision history for this message
vak (khamenya) wrote :

AT+ATI
ERROR
ATI
Manufacturer: Sierra Wireless, Inc.
Model: MC8780
Revision: D1_0_3_0AP C:/WS/FW/D1_0_3_0AP/MSM7200/SRC 2007/07/04 17:01:22
IMEI: 354219010093324
IMEI SV: 1
FSN: D331667132210
3GPP Release 5
+GCAP: +CGSM,+FCLASS,+DS

OK

Revision history for this message
Gerd Bavendiek (gerd-bavendiek) wrote :

This is what I get:

Manufacturer: Sierra Wireless, Inc.
Model: MC8780
Revision: F1_0_0_10AP C:/WS/FW/F1_0_0_10AP/MSM7200R3/SRC/AMSS 2007/11/08
10:51:5
IMEI: 99999999999999999999
IMEI SV: 7
FSN: D331208289510
3GPP Release 6
+GCAP: +CGSM,+DS,+ES

FW slightly newer than vak's, but also from 2007.

Alexander Sack schrieb:
> On Fri, Oct 23, 2009 at 01:01:51PM -0000, Alexander Sack wrote:
>> ** Attachment added: "patch: do not use CFUN=1 command for sierras"
>> http://launchpadlibrarian.net/34248245/lp452427_sierra_cfun.patch
>>
>
> The problem seems to be that some sierra modems need this CFUN=1 as
> they are regularly powered down on startup ... while other sierra
> modems crash on CFUN=1 (like you do ) ... can you please attach the
> output of lsusb and also minicom against your tty and check what an
> AT+ATI gives you?
>
> - Alexander
>

--
------------------------------------------------------------------------
Gerd Bavendiek Linux Users check out:
<email address hidden> http://linos.wordpress.com
------------------------------------------------------------------------

Revision history for this message
Shahar Or (mightyiam) wrote :

Dear ones,

For me the patch woks exactly right on karmic.

Will it work the same way for Jaunty?

Bus 005 Device 004: ID 1199:6852 Sierra Wireless, Inc. AirCard 880E Device

AT+ATI
ERROR
ATI
Manufacturer: Sierra Wireless, Inc.
Model: AC880E
Revision: F1_0_0_11AP C:/WS/FW/F1_0_0_11AP/MSM7200R3/SRC/AMSS 2007/11/21 20:17:7
IMEI: 356812010771184
IMEI SV: 7
FSN: D460798165810
3GPP Release 6
+GCAP: +CGSM,+DS,+ES

Revision history for this message
Alexander Sack (asac) wrote :

On Thu, Nov 12, 2009 at 09:26:21PM -0000, Shahar Or wrote:
> Dear ones,
>
> For me the patch woks exactly right on karmic.
>
> Will it work the same way for Jaunty?

what do you mean? afaik we dont send CFUN in jaunty ...

 - Alexander

Revision history for this message
Gerd Bavendiek (gerd-bavendiek) wrote :

On 13.11.2009 13:16, Alexander Sack wrote:
> On Thu, Nov 12, 2009 at 09:26:21PM -0000, Shahar Or wrote:
>
>> Dear ones,
>>
>> For me the patch woks exactly right on karmic.
>>
>> Will it work the same way for Jaunty?
>>
> what do you mean? afaik we dont send CFUN in jaunty ...
>
> - Alexander
>
>
But you did in Intrepid, didn't you ?

This is from a log, taken in Intrepid:

NetworkManager: <info> (ttyUSB0): powering up...
NetworkManager: <debug> [1227279075.172044] nm_serial_debug(): Sending:
'AT+CFUN=1
'
NetworkManager: <debug> [1227279075.182881] nm_serial_debug(): Got: '

OK

For me personally this was the last Ubuntu, I could use my builtin
Sierra UMTS. In Jaunty pppd was killed immediately after start. In
Karmic Beta it worked for a short time, right now it doesn't.

So I'm really lost.

Unfortunately I'm not able to work around this (I tried wvdial /
gnome-ppp without success).

My only chance is to reboot, select Intrepid and I'm fine. But of course
this is _really_ annoying to put it politely.

Gerd

Revision history for this message
Christof Länzlinger (laenzlinger) wrote :

Dear all

I am also affected by this Bug (Swisscom, Sierra Wireless Aircard 880).

The patch http://launchpadlibrarian.net/34248245/lp452427_sierra_cfun.patch
solves the problem for me.

Thanks a lot!

--
$ lsusb
Bus 009 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 008 Device 002: ID 1199:6850 Sierra Wireless, Inc. AirCard 880 Device
Bus 008 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 002: ID 17ef:1003 Lenovo
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 002: ID 0a5c:2110 Broadcom Corp. Bluetooth Controller
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
--
AT
OK
ATI
Manufacturer: Sierra Wireless, Inc.
Model: AC880
Revision: F1_0_0_8AP C:/WS/FW/F1_0_0_8AP/MSM7200R3/SRC/AMSS 2007/10/10 16:44:13
IMEI: 354217010502518
IMEI SV: 6
FSN: D400848085511
3GPP Release 6
+GCAP: +CGSM,+FCLASS,+DS

OK
--

Martin Pitt (pitti)
Changed in modemmanager (Ubuntu):
milestone: karmic-updates → none
assignee: Alexander Sack (asac) → nobody
Revision history for this message
Aleksander Morgado (aleksander-m) wrote :

Ah, interesting. Wavecom modems (now part of Sierra Wireless as well) do a full OS restart when AT+CFUN=1 is sent to them (including the USB stack, so connections get closed) , so it is possibly something very similar.

With the patch for the Sierra modems here, what happens to those Sierra modems which really do need the power up command?

Revision history for this message
Aleksander Morgado (aleksander-m) wrote :

The result of the discussion upstream is that the power-up command should only be sent to Sierra Wireless modems if not already in full functionality mode. Basically: if AT+CFUN? already replies AT+CFUN: 1, then skip the power-up command.

Implemented this already in the 'power-up-check-needed' branch in the following git repo:
 git://gitorious.org/lanedo/modemmanager.git

Already tested it with Wavecom modems, which are also affected by the issue.

Tests with Sierra Wireless models are highly appreciated.

Revision history for this message
Aleksander Morgado (aleksander-m) wrote :
Changed in modemmanager (Ubuntu):
status: In Progress → Fix Committed
Changed in modemmanager:
status: New → Fix Committed
Changed in modemmanager (Ubuntu):
status: Fix Committed → Confirmed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package modemmanager - 0.5-0ubuntu1

---------------
modemmanager (0.5-0ubuntu1) oneiric; urgency=low

  * New upstream release 0.5.
    - gsm: send init command twice to make the N900 happy (LP: #765516)
    - fix sierra modems' sleep mode command (LP: #459052, #738005)
  * debian/patches/lp700316_usb_blacklist.patch: add extra devices to blacklist
    of USB devices known to usually be serial dongles or other things MM should
    not touch. (LP: #700316)
  * debian/control, debian/rules: add a -dbg package for modemmanager, and
    override dh_strip accordingly. (LP: #415394)
  * debian/rules: fix .la/.a file removal to not fail if there is nothing to
    remove.
  * debian/modemmanager.install: install files to the modemmanager package
    explicitly now that it's not the only binary package.
 -- Mathieu Trudel-Lapierre <email address hidden> Fri, 05 Aug 2011 12:46:32 -0400

Changed in modemmanager (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Gerd Bavendiek (gerd-bavendiek) wrote :

Sorry, I doubt that it is fixed in Oneiric.

Trying to switch from Natty to Oneiric (latest patches) I tested it
yesterday. My Sierra did not work. I produced some debug output. Please
have a look:

modem-manager[2279]: <debug> [1323109715.342834]
[mm-at-serial-port.c:298] debug_log(): (ttyUSB2): --> 'AT+CFUN=1<CR>'
modem-manager[2279]: <debug> [1323109715.391579]
[mm-at-serial-port.c:298] debug_log(): (ttyUSB2): <-- '<CR><LF>OK<CR><LF>'
modem-manager[2279]: <debug> [1323109717.443409] [mm-serial-port.c:636]
data_available(): (ttyUSB2) unexpected port hangup!
modem-manager[2279]: <debug> [1323109717.443482] [mm-serial-port.c:844]
mm_serial_port_close(): (ttyUSB2) device open count is 0 (close)
modem-manager[2279]: <info> [1323109717.443518] [mm-serial-port.c:859]
mm_serial_port_close(): (ttyUSB2) closing serial port...
modem-manager[2279]: <info> [1323109717.443580] [mm-serial-port.c:880]
mm_serial_port_close(): (ttyUSB2) serial port closed

IMHO this is the old problem, which Aleksander fixed in July. Oneiric
modem-manager still kills the modem via sending CFUN=1.

Am 05.08.2011 19:00, schrieb Launchpad Bug Tracker:
> This bug was fixed in the package modemmanager - 0.5-0ubuntu1
>
> ---------------
> modemmanager (0.5-0ubuntu1) oneiric; urgency=low
>
> * New upstream release 0.5.
> - gsm: send init command twice to make the N900 happy (LP: #765516)
> - fix sierra modems' sleep mode command (LP: #459052, #738005)
> * debian/patches/lp700316_usb_blacklist.patch: add extra devices to blacklist
> of USB devices known to usually be serial dongles or other things MM should
> not touch. (LP: #700316)
> * debian/control, debian/rules: add a -dbg package for modemmanager, and
> override dh_strip accordingly. (LP: #415394)
> * debian/rules: fix .la/.a file removal to not fail if there is nothing to
> remove.
> * debian/modemmanager.install: install files to the modemmanager package
> explicitly now that it's not the only binary package.
> -- Mathieu Trudel-Lapierre<email address hidden> Fri, 05 Aug 2011 12:46:32 -0400
>
> ** Changed in: modemmanager (Ubuntu)
> Status: Confirmed => Fix Released
>

--
------------------------------------------------------------------------
Gerd Bavendiek Linux Users check out:
<email address hidden> http://linos.wordpress.com
------------------------------------------------------------------------

Revision history for this message
Mathieu Trudel-Lapierre (cyphermox) wrote :

Could you please confirm you indeed have modemmanager 0.5-0ubuntu1? Also, it might be good to look into whether your device needs a firmware update, or whether it really is supported by the changes implemented. There are so many devices, they're all different.

Having the full debug log from the point where that modem was connected will also help, since there may be some extra information about why CFUN=1 doesn't work.

Revision history for this message
Gerd Bavendiek (gerd-bavendiek) wrote :
  • mm.log Edit (41.4 KiB, text/x-log; name="mm.log")

Hi Mathieu,

thanks for responding.

Am 06.12.2011 16:25, schrieb Mathieu Trudel-Lapierre:
> Could you please confirm you indeed have modemmanager 0.5-0ubuntu1?
lulu:/home/ba> dpkg -l | grep modem
ii modemmanager
0.5-1ubuntu1 D-Bus service for managing modems

> Also, it might be good to look into whether your device needs a firmware
> update, or whether it really is supported by the changes implemented.
> There are so many devices, they're all different.

This is a dual boot laptop. In Natty (with patched modemmanager)
everything is well. In Oneiric CFUN=1 is being sent, WHICH MUST NOT
HAPPEN with the type of Sierra I've got.

This was the point in Aleksander's patch.

> Having the full debug log from the point where that modem was connected
> will also help, since there may be some extra information about why
> CFUN=1 doesn't work.
>
mm.log is attached.

Thanks

Gerd

--
------------------------------------------------------------------------
Gerd Bavendiek Linux Users check out:
<email address hidden> http://linos.wordpress.com
------------------------------------------------------------------------

Revision history for this message
Aleksander Morgado (aleksander-m) wrote :

MM 0.5 does *not* have that patch, it's currently only in git master. I can backport it to the 0.5 branch one of these days.

Revision history for this message
Aleksander Morgado (aleksander-m) wrote :

(unless there is a patch in Ubuntu packaging, which I didn't check)

Relevant commits are: 6e9d980e8c29974f9b641a1f6bc3be5212500901 and 56db81890120e63f251b899b0eac66dc8941d411

Revision history for this message
Aleksander Morgado (aleksander-m) wrote :

I just cherry-picked the fixes for the MM_05 branch, they should be available in the next MM 0.5 release.

Revision history for this message
Gerd Bavendiek (gerd-bavendiek) wrote :

Thanks Aleksander.

When do you think will this be available ?

Does it make sense for me to build it on my own, just to be able to
swicth to Oneiric ?

Are the changes available somewhere ?

Kind regards

Gerd

Am 09.12.2011 11:35, schrieb Aleksander Morgado:
> I just cherry-picked the fixes for the MM_05 branch, they should be
> available in the next MM 0.5 release.
>

--
------------------------------------------------------------------------
Gerd Bavendiek Linux Users check out:
<email address hidden> http://linos.wordpress.com
------------------------------------------------------------------------

Revision history for this message
Aleksander Morgado (aleksander-m) wrote :

You can always build the MM_05 branch from the upstream repo... don't know when the next planned stable release is expected.

Changed in modemmanager:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.