K3520-Z mode not switched automatically
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
network-manager (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Ubuntu 12.04.2 LTS
Although I have logged this as a network-manager problem, it could well turn out to be an issue with usb-modeswitch (usb-modeswitch 1.2.3+repack0-
Expected behaviour (and what happened in 10.04):
* The presence of mobile broadband dongle K3520-Z should be detected.
* The appropriate steps should be taken to switch it from usb-storage mode.
* Mobile broadband should be enabled.
What actually happens:
* The dongle remains in usb-storage mode.
* Mobile broadband does not appear as an option on the network drop-down menu.
The following commands can be used to work around the problem:
sudo modprobe --verbose option
sudo echo "19d2 0055" >/sys/bus/
sudo usb_modeswitch --default-vendor 0x19d2 --default-product 0x2000 --message-content "55534243123456
After these commands mobile broadband appears as a disabled option in the network drop-down menu. Once mobile broadband is manually enabled, all is well.
The remainder of this bug report might or might not contain useful information.
When I tried researching this problem, I encountered threads in various forums that seemed to be reporting the same failure but for different dongles. This bug might therefore not be limited to the K3520-Z, but I do know that it doesn't apply to a K3770 as I also have one of those (I suppose I could swap the SIM from the K3520-Z to the K3770 to work around the problem, but I'd rather not risk damaging the SIM in the process).
When I first encountered this problem after upgrading from 10.04.01 to 12.04.2, I was puzzled by the fact that mobile broadband had worked perfectly after the upgrade completed but then failed on a later startup. I was further confused when from time to time it worked on subsequent startups. I have, however, now realised what was going on and have tested my understanding appropriately. Following a shutdown and startup mobile broadband fails because the dongle has been powered down and hence has reverted to usb-storage mode, but following a restart mobile broadband works (providing it was working prior to the restart) because the dongle has remained powered throughout and hence has not reverted to usb-storage mode.
This problem manifests itself in the same way on a netbook (I'll provide more details of the hardware if they are considered useful). This is what might well be expected, but I mention it because on 10.04.1 I had an entirely different experience. The K3520-Z used to switch mode automatically on both systems, but I had to switch the K3770 manually on the netbook (this is why I was able to come up with the above workaround after upgrading to 12.04.02 - I had done all the hard work discovering the workaround 18 months ago when I bought the K3770 while on holiday in Spain and now just needed to find the correct usb_modeswitch options for the K3520-Z). No, you haven't misread that. The dongle that switched mode automatically on both systems in 10.04.01 now fails to switch automatically on both in 12.04.02, while the one that switched automatically on only one of the two systems in 10.04.01 now switches automatically on both in 12.04.02.
If it's on any interest, the following is the output from the above commands:
Looking for target devices ...
No devices in target mode or class found
Looking for default devices ...
found matching product ID
adding device
Found device in default mode, class or configuration (1)
Accessing device 002 on bus 007 ...
Getting the current device configuration ...
OK, got current device configuration (1)
Using first interface: 0x00
Using endpoints 0x09 (out) and 0x89 (in)
Inquiring device details; driver will be detached ...
Looking for active driver ...
OK, driver found ("usb-storage")
OK, driver "usb-storage" detached
SCSI inquiry data (for identification)
-------
Vendor String: ZTE Corp
Model String: USB Storage
Revision String: 2.31
-------
USB description data (for identification)
-------
Manufacturer: Qualcomm, Incorporated
Product: USB ZTE Storage
Serial No.: P671M8VDF_MS
-------
Setting up communication with interface 0
Using endpoint 0x09 for message sending ...
Trying to send message 1 to endpoint 0x09 ...
OK, message successfully sent
Reading the response to message 1 (CSW) ...
OK, response successfully read (13 bytes).
Trying to send message 2 to endpoint 0x09 ...
OK, message successfully sent
Reading the response to message 2 (CSW) ...
OK, response successfully read (0 bytes).
Trying to send message 3 to endpoint 0x09 ...
OK, message successfully sent
Reading the response to message 3 (CSW) ...
OK, response successfully read (0 bytes).
Resetting response endpoint 0x89
Could not reset endpoint (probably harmless): -71
Resetting message endpoint 0x09
Could not reset endpoint (probably harmless): -71
Device is gone, skipping any further commands
Checking for mode switch (max. 20 times, once per second) ...
Searching for target devices ...
Searching for target devices ...
Searching for target devices ...
found matching product ID
adding device
Found target device, now opening
Error: could not get description string "serial number"
Found correct target device
Mode switch succeeded. Bye.
ok:19d2:0055
ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: network-manager 0.9.4.0-0ubuntu4.2
ProcVersionSign
Uname: Linux 3.2.0-40-generic i686
ApportVersion: 2.0.1-0ubuntu17.2
Architecture: i386
CRDA: Error: command ['iw', 'reg', 'get'] failed with exit code 1: nl80211 not found.
Date: Wed May 1 08:51:46 2013
IfupdownConfig:
auto lo
iface lo inet loopback
IpRoute:
default via 10.64.64.64 dev ppp0 proto static
10.64.64.64 dev ppp0 proto kernel scope link src 10.162.121.221
169.254.0.0/16 dev ppp0 scope link metric 1000
IwConfig:
ppp0 no wireless extensions.
lo no wireless extensions.
eth0 no wireless extensions.
MarkForUpload: True
NetworkManager.
[main]
NetworkingEnab
WirelessEnable
WWANEnabled=true
ProcEnviron:
TERM=xterm
LC_COLLATE=C
PATH=(custom, no user)
LANG=en_GB.UTF-8
SHELL=/bin/bash
RfKill:
SourcePackage: network-manager
UpgradeStatus: Upgraded to precise on 2013-04-30 (1 days ago)
nmcli-con:
NAME UUID TYPE TIMESTAMP TIMESTAMP-REAL AUTOCONNECT READONLY DBUS-PATH
Wired connection 1 f026e4a8-
Vodafone UK 88242320-
nmcli-dev:
DEVICE TYPE STATE DBUS-PATH
ttyUSB0 gsm connected /org/freedeskto
eth0 802-3-ethernet unavailable /org/freedeskto
nmcli-nm:
RUNNING VERSION STATE NET-ENABLED WIFI-HARDWARE WIFI WWAN-HARDWARE WWAN
running 0.9.4.0 connected enabled enabled enabled enabled enabled
Having done some further investigation, I believe this is a udev issue, not a network manager issue.
Having issued the command debug
udevadm control --log-priority=
I then inserted first the K3770 and then the K3520-Z. I've subsequently been looking at the very copious debug output from udev in syslog. For both dongles udev is successfully finding a rule and invoking usb_modeswitch but although the mode switch is successful for the K3770, it is unsuccessful for the K3520-Z. The way in which isb_modeswitch is being invoked by udev differs substantially for the two dongles. This surprises me given that the manual method for switching them is fairly similar.
I shall spend some more time trying to make greater sense of the udev debug output to see if I can identify the cause of the difference in the invocation of usb_modeswitch. Meanwhile if anyone would like me to upload the extracts from syslog for the K-3770 and the K3520-Z, let me know.