Author Message

<  Setup Discussion  ~  Ubuntu 17.04 freezes when usb_modeswitch runs

PostPosted: Tue Jul 25, 2017 10:48 am Reply with quote
Posts: 2 Joined: Tue Jul 25, 2017 10:41 am
This link describes issue I see:-

https://ubuntuforums.org/showthread.php ... 18c2c94962

So plug in usb, everything stops, unplug and it immediately recovers. Ubuntu 17.04.

I will try an older usb_modeswitch version to see if that fixes issue, currently have latest:-

* usb_modeswitch: handle USB devices with multiple modes
* Version 2.5.0 (C) Josua Dietze 2017
* Based on libusb1/libusbx



here is my log file, if helpful.


dave@crowthorne:~$ more /var/log/usb_modeswitch_2-7.1

USB_ModeSwitch log from Tue Jul 25 09:43:55 BST 2017

Use global config file: /etc/usb_modeswitch.conf
Raw parameters: --switch-mode 2-7.1:1.0
Use top device dir /sys/bus/usb/devices/2-7.1
Check class of first interface ...
Interface 0 class is 08.

----------------
USB values from sysfs:
manufacturer HUAWEI
product HUAWEI Mobile
serial FFFFFFFFFFFFFFFF
----------------
bNumConfigurations is 1 - don't check for active configuration
Found packed config collection /usr/share/usb_modeswitch/configPack.tar.gz
ConfigList: /etc/usb_modeswitch.d/12d1:1f01 /usr/share/usb_modeswitch/12d1:1f01 /usr/share/usb_modeswitch/12d1:#linux pack/12d1:1f01 pack/12d1:#linux
SCSI attributes not needed, move on
Check config: /etc/usb_modeswitch.d/12d1:1f01
! matched. Read config data
Use config file from override folder /etc/usb_modeswitch.d
Logger is /usr/bin/logger
Command line:
usb_modeswitch -W -D -u -1 -b 2 -g 22 -v 12d1 -p 1f01 -f $flags(config)

Verbose debug output of usb_modeswitch and libusb follows
(Note that some USB errors are to be expected in the process)
--------------------------------

Read long config from command line

* usb_modeswitch: handle USB devices with multiple modes
* Version 2.5.0 (C) Josua Dietze 2017
* Based on libusb1/libusbx

! PLEASE REPORT NEW CONFIGURATIONS !

DefaultVendor= 0x12d1
DefaultProduct= 0x1f01
TargetVendor= 0x12d1
TargetProduct= 0x1442
MessageContent="55534243123456780000000000000011060000000000000000000000000000"
System integration mode enabled

Use given bus/device number: 002/022 ...
Look for default devices ...
bus/device number matched
found USB ID 12d1:1f01
vendor ID matched
product ID matched
Found devices in default mode (1)
Get the current device configuration ...
Use interface number 0
with class 8
Use endpoints 0x01 (out) and 0x81 (in)

USB description data (for identification)
-------------------------
Manufacturer: HUAWEI
Product: HUAWEI Mobile
Serial No.: FFFFFFFFFFFFFFFF
-------------------------
Looking for active driver ...
OK, driver detached
Set up interface 0
Use endpoint 0x01 for message sending ...
Trying to send message 1 to endpoint 0x01 ...
OK, message successfully sent
Read the response to message 1 (CSW) ...
Response successfully read (13 bytes), status 1
Reset response endpoint 0x81
Reset message endpoint 0x01
ok:busdev
--------------------------------
(end of usb_modeswitch output)

Check success of mode switch for max. 20 seconds ...
Read attributes ...
All attributes matched
Mode switching was successful, found 12d1:1442 (HUAWEI: HUAWEI Mobile)
Serial USB driver bound to interface 0
will try to guess and symlink modem port on next connect
Check for AVOID_RESET_QUIRK kernel attribute
AVOID_RESET_QUIRK activated

All done, exit


Offline
PostPosted: Tue Jul 25, 2017 12:38 pm Reply with quote
Posts: 1166 Joined: Wed Jul 11, 2012 3:14 pm Location: Koh Samui, TH
abadger wrote:


That is a five year old thread about a problem in Ubuntu 12.04.
I can't see that it has anything to do with your problem even if the symptom is the same.

abadger wrote:
Mode switching was successful, found 12d1:1442 (HUAWEI: HUAWEI Mobile)
Serial USB driver bound to interface 0
will try to guess and symlink modem port on next connect
Check for AVOID_RESET_QUIRK kernel attribute
AVOID_RESET_QUIRK activated

All done, exit


Nothing wrong, usb_modeswitch has done its job and left the scene.
Whatever happens afterwards that makes "everything stop" is not usb_modeswitch responsibility.


Offline
PostPosted: Tue Jul 25, 2017 9:42 pm Reply with quote
Posts: 2 Joined: Tue Jul 25, 2017 10:41 am
[48317.004323] usb 2-1: USB disconnect, device number 26
[48317.340073] usb 2-1: new high-speed USB device number 27 using xhci_hcd
[48317.481109] usb 2-1: New USB device found, idVendor=12d1, idProduct=1442
[48317.481112] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[48317.481115] usb 2-1: Product: HUAWEI Mobile
[48317.481116] usb 2-1: Manufacturer: HUAWEI
[48317.500237] option 2-1:1.0: GSM modem (1-port) converter detected
[48317.500522] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB0
[48317.500749] option 2-1:1.1: GSM modem (1-port) converter detected
[48317.500967] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB1
[48343.545740] usb 2-1: USB disconnect, device number 27
[48343.546246] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
[48343.546300] option 2-1:1.0: device disconnected
[48343.546737] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
[48343.546784] option 2-1:1.1: device disconnected


root@crowthorne:/home/dave/Downloads/usb-modeswitch-2.5.0# lsusb

Bus 001 Device 002: ID 8087:8001 Intel Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 002 Device 005: ID 05e3:0723 Genesys Logic, Inc. GL827L SD/MMC/MS Flash Card Reader
Bus 002 Device 007: ID 04f2:0833 Chicony Electronics Co., Ltd
Bus 002 Device 006: ID 2222:3100 MacAlly
Bus 002 Device 004: ID 05e3:0608 Genesys Logic, Inc. Hub
Bus 002 Device 015: ID 041e:0414 Creative Technology, Ltd
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

root@crowthorne:/home/dave/Downloads/usb-modeswitch-2.5.0# lsusb

Bus 001 Device 002: ID 8087:8001 Intel Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 002 Device 005: ID 05e3:0723 Genesys Logic, Inc. GL827L SD/MMC/MS Flash Card Reader
Bus 002 Device 007: ID 04f2:0833 Chicony Electronics Co., Ltd
Bus 002 Device 006: ID 2222:3100 MacAlly
Bus 002 Device 004: ID 05e3:0608 Genesys Logic, Inc. Hub
Bus 002 Device 015: ID 041e:0414 Creative Technology, Ltd
Bus 002 Device 028: ID 12d1:1f01 Huawei Technologies Co., Ltd. E353/E3131 (Mass storage mode)
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
root@crowthorne:/home/dave/Downloads/usb-modeswitch-2.5.0# dmesg <*** Machine is hung, remove usb and see this dmesg message
[ 0.000000] microcode: microcode updated early to revision 0x25, date = 2017-01-27
[ 0.000000] Linux version 4.10.0-041000-generic (kernel@gloin) (gcc version 6.2.0 20161005 (Ubuntu 6.2.0-5ubuntu12) ) #201702191831 SMP Sun Feb 19 23:33:19 UTC 2017
[ 0.000000] Command line: BOOT_IMAGE=/boot/vmlinuz-4.10.0-041000-generic root=UUID=73aba746-cce8-4a0f-a0aa-c6d4622c2533 ro quiet splash vt.handoff=7
[ 0.000000] KERNEL supported cpus:
[ 0.000000] Intel GenuineIntel
[ 0.000000] AMD AuthenticAMD
...
...
[48343.546300] option 2-1:1.0: device disconnected
[48343.546737] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
[48343.546784] option 2-1:1.1: device disconnected
[48385.329519] usb 2-1: new high-speed USB device number 28 using xhci_hcd
[48385.470925] usb 2-1: New USB device found, idVendor=12d1, idProduct=1f01
[48385.470929] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[48385.470932] usb 2-1: Product: HUAWEI Mobile
[48385.470935] usb 2-1: Manufacturer: HUAWEI
[48385.470937] usb 2-1: SerialNumber: FFFFFFFFFFFFFFFF
[48385.513531] usb-storage 2-1:1.0: USB Mass Storage device detected
[48385.514088] scsi host3: usb-storage 2-1:1.0
[48386.138747] usb 2-1: USB disconnect, device number 28
[48386.473437] usb 2-1: new high-speed USB device number 29 using xhci_hcd
[48386.614725] usb 2-1: New USB device found, idVendor=12d1, idProduct=1442
[48386.614732] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[48386.614736] usb 2-1: Product: HUAWEI Mobile
[48386.614739] usb 2-1: Manufacturer: HUAWEI
[48386.634054] option 2-1:1.0: GSM modem (1-port) converter detected
[48386.634160] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB0
[48386.634247] option 2-1:1.1: GSM modem (1-port) converter detected
[48386.634324] usb 2-1: GSM modem (1-port) converter now attached to ttyUSB1
[48397.165780] usb 2-1: USB disconnect, device number 29
[48397.166287] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
[48397.166328] option 2-1:1.0: device disconnected
[48397.166762] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
[48397.166811] option 2-1:1.1: device disconnected
root@crowthorne:/home/dave/Downloads/usb-modeswitch-2.5.0#


Offline
PostPosted: Tue Jul 25, 2017 11:08 pm Reply with quote
Site Admin Posts: 6420 Joined: Sat Nov 03, 2007 12:30 am
Not sure what your point is with these logs. The dmesg output shows that usb_modeswitch is doing its work.
Can you be more specific?


Offline
PostPosted: Wed Jul 26, 2017 7:26 am Reply with quote
Posts: 1166 Joined: Wed Jul 11, 2012 3:14 pm Location: Koh Samui, TH
Remove your custom configured switch message, the usb id is supported in usb_modeswitch and usb_modeswitch has the correct switching method for it.


Offline

Display posts from previous:  Sort by:

All times are UTC+02:00
Page 1 of 1
5 posts
Users browsing this forum: No registered users and 1 guest
Search for:
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum
cron