Automatic Activation, Hotplug and UDEV, Configuration
RussianNeuroMancer
Posts: 10
Joined: 30 Oct 2018, 04:11

Re: HP lt4220 (Snapdragon X12 LTE)

Post by RussianNeuroMancer » 27 Sep 2020, 00:36

Canonical dropped dispatcher-c-rewrite from their usbmodeswitch package: https://launchpad.net/ubuntu/+source/us ... 0-2ubuntu1

So I moved on to Ubuntu 20.10 (and usbmodeswitch 2.6.1) to see if current usbmodeswitch will able to configure modem automatically. After all usbmodeswitch-data is updated now and include config for this modem.

Unfortunately, for some reason usbmodeswitch fail, and I have no idea why. Please take a look at this usb_modeswitch_2-3 log:

Code: Select all

USB_ModeSwitch log from Sun Sep 27 06:27:13 +02 2020
Raw parameters: --switch-mode 2-3
Use global config file: /etc/usb_modeswitch.conf

Use global config file: /etc/usb_modeswitch.conf
Use top device dir /sys/bus/usb/devices/2-3
Check class of first interface ...
 No access to first interface. Exit
edit: Another attempt looks more promising:

Code: Select all

USB_ModeSwitch log from Sun Sep 27 06:42:18 +02 2020
Raw parameters: --switch-mode 2-3
Use global config file: /etc/usb_modeswitch.conf

Use global config file: /etc/usb_modeswitch.conf
Use top device dir /sys/bus/usb/devices/2-3
Check class of first interface ...
 Interface class is 02.

----------------
USB values from sysfs:
  manufacturer	Qualcomm
  product	Snapdragon(TM) X12 LTE-A
  serial	0123456789ABCDEF
----------------
Found packed config collection /usr/share/usb_modeswitch/configPack.tar.gz
ConfigList: pack/03f0:0857 pack/
SCSI attributes not needed, move on
Check config: pack/03f0:0857
! matched. Read config data
Extract config 03f0:0857 from collection /usr/share/usb_modeswitch/configPack.tar.gz
Device may have an MBIM configuration, check driver ...
 driver for MBIM devices is available
Find MBIM configuration number ...
Command line:
usb_modeswitch -W -D  -b 2 -g 3 -v 03f0 -p 0857 -f $flags(config)
Then log does not change, probably because usb_modeswitch crash:

Code: Select all

Sep 27 06:42:18 hp1013 systemd[1]: usb_modeswitch@2-3.service: Main process exited, code=killed, status=15/TERM
Sep 27 06:42:18 hp1013 systemd[1]: usb_modeswitch@2-3.service: Failed with result 'signal'.
Sep 27 06:42:18 hp1013 systemd[1]: usb_modeswitch@2-3.service: Main process exited, code=killed, status=15/TERM
Sep 27 06:42:18 hp1013 systemd[1]: usb_modeswitch@2-3.service: Failed with result 'signal'.
Sep 27 06:42:18 hp1013 systemd[1]: usb_modeswitch@2-3.service: Main process exited, code=killed, status=15/TERM
Sep 27 06:42:18 hp1013 systemd[1]: usb_modeswitch@2-3.service: Failed with result 'signal'.
Sep 27 06:42:19 hp1013 usb_modeswitch: switch device 03f0:0857 on 002/003
Sep 27 06:42:19 hp1013 systemd[1]: usb_modeswitch@2-3.service: Main process exited, code=killed, status=15/TERM
Sep 27 06:42:19 hp1013 systemd[1]: usb_modeswitch@2-3.service: Failed with result 'signal'.
Sep 27 06:42:19 hp1013 systemd[1]: usb_modeswitch@2-3.service: Main process exited, code=killed, status=15/TERM
Sep 27 06:42:19 hp1013 systemd[1]: usb_modeswitch@2-3.service: Failed with result 'signal'.
Sep 27 06:42:19 hp1013 systemd[1]: usb_modeswitch@2-3.service: Start request repeated too quickly.
Sep 27 06:42:19 hp1013 systemd[1]: usb_modeswitch@2-3.service: Failed with result 'signal'.
So either way it doesn't work :(

Just to be sure I checked "echo 3 > /sys/bus/usb/devices/usb2/2-3/bConfigurationValue" and it allow to get modem working.

RussianNeuroMancer
Posts: 10
Joined: 30 Oct 2018, 04:11

Re: HP lt4220 (Snapdragon X12 LTE)

Post by RussianNeuroMancer » 28 Sep 2020, 02:46

Turns out first log caused by regression in Linux 5.9 (I installed it to get fix for other issue). So it's not an usb-modeswitch bug.
I will try to bisect it and will post result here, because this regression is directly related to usb-modeswitch and prevent it from working correctly.

As for second log and crash - I have no idea, but it's doesn't happen on Linux 5.8 so I not sure if it's important.


Josh
Site Admin
Posts: 6569
Joined: 03 Nov 2007, 00:30

Re: HP lt4220 (Snapdragon X12 LTE)

Post by Josh » 04 Nov 2020, 09:26

I have responded to the kernel bugzilla report. I'll see if I can pinpoint the reason why I introduced the "change" event in the udev rule.

Zerginator
Posts: 1
Joined: 23 Jan 2021, 12:35

Re: HP lt4220 (Snapdragon X12 LTE)

Post by Zerginator » 23 Jan 2021, 12:39

I had the same/similar issue with my HP lt4132 since Kernel 5.9

The fix discussed on the Bugzilla Page on the Kernel change (https://bugzilla.kernel.org/show_bug.cgi?id=209469) worked fine for me:

Changing

Code: Select all

ACTION!="add|change"
to this:

Code: Select all

ACTION=="add"
in /lib/udev/rules.d/40-usb_modeswitch.rules
resulted in the modem working again.

I would not really expect this to be changed back in the kernel anytime soon, as it reads like it was done to fix other issues.

The maybe a fix needs to be done on USB_Modeswitch side.

Josh
Site Admin
Posts: 6569
Joined: 03 Nov 2007, 00:30

Re: HP lt4220 (Snapdragon X12 LTE)

Post by Josh » 17 Apr 2021, 14:43

I have posted the report that triggered the change with "change" (haha).

https://bugzilla.kernel.org/show_bug.cgi?id=209469#c16

I'll have to check how a switch back to "add" only will affect reboot behaviour.

Post Reply