Commit Graph
84 Commits
Author SHA1 Message Date
Aleksander Morgado 306566ad7e quectel: implement shared quectel logic in MBIM modem 2024-03-13 03:57:57 +00:00
Aleksander Morgado 87fb47b9ab quectel: minor code reordering 2024-03-13 03:57:57 +00:00
Aleksander Morgado 8c208f7bcf xmm: ignore +XBIPI URCs 2024-03-13 03:52:35 +00:00
Aleksander Morgado 4b0b9dde02 fibocom: setup common shared setup ports in all modems
Make sure all Fibocom modem implementations use the shared port setup
logic that adds the SIM READY URC ignore rule.
2024-03-13 03:52:35 +00:00
Aleksander Morgado 8512ff4442 fibocom: setup shared fibocom management on AT-only modem
The generic MMBroadbandModemFibocom object uses the shared Fibocom
settings to load the update settings. This logic does not use the
Private info right now, but there is no reason why it wouldn't do it
in the future. Also, for consistency, it makes sense to ensure the
shared interface setup is the same in all implementations, we should
not have only some allowing to initialize the Private info.
2024-03-13 03:52:35 +00:00
Kamesh Relangi 2dac0a9e4f build: fix dependencies in huawei plugin helpers
Compilation errors due to generated files is observed when
compiling in multi threaded environment, as the generated files
getting generated after they have been referred.

Fix: Added dependency in meson so that it will ensure that the
header is generated.

Ref fail log:
../mobile-broadband/ModemManager/src/plugins/huawei/mm-modem-helpers-huawei.c:29:10:
fatal error: mm-huawei-enums-types.h: No such file or directory
   29 | #include "mm-huawei-enums-types.h"
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.

Signed-off-by: Kamesh Relangi <quic_krelangi@quicinc.com>
2024-03-12 12:06:42 +00:00
Aleksander Morgado 07f1f58642 modem-helpers: rework AT string quote operation and add unit tests
Rework the AT string quote operation to build the output with the
GString helper, instead of manually calculating how many bytes we'll
need in the output. It just makes it clearer.
2024-03-12 10:15:59 +00:00
Aleksander Morgado b99757a1f4 fibocom: don't be strict on required drivers
Requiring an explicit set of drivers should only be done when we have
different plugins supporting different types of devices of the same
manufacturer based on the drivers in use (e.g. as in the Sierra case).

When the plugin includes a list of required drivers, the plugin filter
will only assume the plugin can be used if at least one of the
available ports is exposed with one of the drivers in the list.

Because of this, if we start probing some ports before all the
expected ports are reported, we may end up not selecting a given
plugin just because the driver match should have been done in a
not-yet-notified port.

E.g. on system boot:
 * ttyACM0 is notified.
 * min probing time elapses so ttyACM0 probing starts
 * Fibocom plugin is not selected for ttyACM0 as no matched
   driver ("cdc_acm") is given in the the list of drivers of the
   plugin.
 * cdc-wdm0 and wwan0 drivers are notified.
 * MM creates generic MBIM modem with the Fibocom plugin, but without
   XMM features support, because the ttyACM0 port probing was not done
   by the Fibocom plugin.

And if we reset the modem after that:
 * ttyACM0 is notified.
 * cdc-wdm0 and wwan0 drivers are notified.
 * min probing time elapses so probing starts for all ports
 * Fibocom plugin is selected for all port probings as "cdc_mbim" is
   listed in the list of drivers of the plugin.
 * MM creates XMM-capable MBIM modem with the Fibocom plugin.
2024-03-11 12:36:15 +00:00
Lukas Voegl f8295bd641 cinterion: keep dual-sim order
mm_parse_uint_list() sorts available SIMs and possibly changes the order of the active / non-active SIM.
A custom parser is added, which keeps the order of all SIMs.

Signed-off-by: Lukas Voegl <lvoegl@tdt.de>
2024-03-04 09:11:36 +00:00
Aleksander Morgado b3708636b1 mtk: fix reported nw error in FM350 < 29.22.13
The network error needs to be scaled down.
2024-02-15 21:08:57 +00:00
Aleksander Morgado b313a603aa mtk: remove IP packet filters during connection in FM350 < 29.23.06
Old firmware versions of the FM350 had some internal IP packet filters
installed, which prevented proper IPv6 connectivity in certain cases.

This workaround ensures that the IP packet filters get removed
whenever a data connection is up. Because we don't know when exactly
the filters get installed, we do this removal periodically along with
the bearer stats query.
2024-02-15 21:06:59 +00:00
Aleksander Morgado 2f306e8e7c mtk: multiplex support only available in FM350 >= 29.23.06
Old versions of the FM350 firmware were able to support multiplex with
multiple PDNs more or less consistently, except on very specific cases
like Verizon.

The newest firmware versions support multiplex on any carrier, so we
can enable back the feature depending on the firmware version number.
2024-02-15 21:01:53 +00:00
Aleksander Morgado 1373ca7e51 mtk: expect async SLAAC only in FM350 >= 29.23.06
Async SLAAC implementation in the FM350 is only available since
29.23.06, so only wait for the IP configuration indications reporting
the SLAAC result in newer versions.
2024-02-15 21:01:52 +00:00
Aleksander Morgado 1befca4573 cinterion: disable periodic signal checks in MBIM modems 2024-02-15 13:01:00 +00:00
Aleksander Morgado 91828ecc65 quectel: disable periodic signal checks in MBIM modems 2024-02-15 13:01:00 +00:00
Aleksander Morgado 3c35212f7c telit: disable periodic signal checks in MBIM modems 2024-02-15 13:01:00 +00:00
RICCIARDI-Adrien ef126455b8 plugins: mtk: Added MT6229 USB modem support.
This modem is used for instance on the CAT B100 phone.

Signed-off-by: RICCIARDI-Adrien <adrien.ricciardi@hotmail.fr>
2024-02-12 22:34:01 +00:00
Madhav 1655d0e014 bearer-mbim: When an IP type is unspecified in the profile, default to IPv4v6 (dual-stack)
To address limitations in reading IP_TYPE information (in some cases) for profile requests,
default to IPv4v6 (dual-stack) for profile requests and IPv4 only for user requests (to ensure backward compatibility)
if nothing specific is requested. This ensures network compatibility across IPv4 and IPv6 networks,
preventing potential connectivity issues in IPv6 environments.
2024-01-25 21:52:31 +00:00
Lukas Voegl 6f21b1d8fb cinterion: swap local and dynamic PDP context command
Signed-off-by: Lukas Voegl <lvoegl@tdt.de>
2024-01-25 15:17:48 +00:00
Lukas Voegl c4eac36484 cinterion: default to none authentication with no user and password
Signed-off-by: Lukas Voegl <lvoegl@tdt.de>
2024-01-25 15:17:48 +00:00
Lukas Voegl 030ec7c5bb cinterion: change secondary port to ppp on PLS8
Signed-off-by: Lukas Voegl <lvoegl@tdt.de>
2024-01-25 15:02:59 +00:00
Lukas Voegl 4078d54ad5 cinterion: switch primary and secondary port for PLS8
Signed-off-by: Lukas Voegl <lvoegl@tdt.de>
2024-01-19 13:41:57 +00:00
Nagi Marupaka 97ac3e8448 fibocom: re-enable the modem after an attempt to set initial EPS bearer irrespective of success or failure of the operation 2023-12-13 10:10:20 +00:00
Petr Krasnoshchekov 59b82a2f97 simtech: add port type hints for A7600E-H, A7602E-H 2023-12-01 12:50:51 +00:00
Petr Krasnoshchekov d40d156081 simtech: ignore +CPIN: READY URC on startup
A7600E-H sends +CPIN: URC on startup.
The URC can be treated by ModemManager as a response to other command, what leads to errors during ModemManager initialization
2023-12-01 12:50:50 +00:00
Petr Krasnoshchekov a7ff7281af simtech: ignore PB DONE, SMS DONE, +NITZ: URCs 2023-12-01 12:49:45 +00:00
Petr Krasnoshchekov c871b1a514 simtech: implement reset for A7600E-H/A7602E-H 2023-12-01 12:49:45 +00:00
Aleksander Morgado 11a1720daf mtk: add FM350 specific MBIM implementation
Including logic to set low power mode during an EPS initial bearer
settings update.
2023-11-06 15:11:38 +00:00
Aleksander Morgado ddb2888d32 mtk: add MTK specific MBIM implementation
Basically to flag that we don't support QMI explicitly, so that it's
not even attempted.
2023-11-06 15:11:38 +00:00
Aleksander Morgado c814f3590a mtk: flag FM350 as not supporting multiplexing
There is no released firmware version with proper support for
multiplexing yet.
2023-11-06 15:11:38 +00:00
Aleksander Morgado 6457c644b5 mtk-legacy: rename label in udev rules 2023-11-06 13:02:22 +00:00
Aleksander Morgado c3597636ec build: fix single-plugin build for mtk 2023-10-31 14:11:20 +00:00
Aleksander Morgado 48d9708e14 mtk: remove support for the udev rules tester
There are no udev rules in the new mtk plugin for now.
2023-10-30 10:06:37 +00:00
Aleksander Morgado a4a5c972e8 mtk-legacy: rename port type hints rules file
These rules apply to modems managed by the mtk-legacy plugin.
2023-10-30 10:05:17 +00:00
ming-pei.hsu eb776be926 mtk: add mtk plugin which support mbim interface
Add MTK plugin for mtk_t7xx platform which support MBIM interface.
2023-10-30 10:03:53 +00:00
Aleksander Morgado 74904b3cb1 quectel: coding style fixes 2023-10-18 21:29:06 +00:00
mank.wang 1b6e4c4349 quectel: avoid incorrect module version report after the upgrade
After LVFS upgrade, the module needs to be restarted. ModemManager
queries the module information, sometimes the module is not ready, and
the information queried by "mmcli -m any --firmware-status" is
incomplete,

It is now modified to re query once per second when obtaining
incomplete versions, up to a maximum of 16 times.

Signed-off-by: mank.wang <mank.wang@quectel.com>
2023-10-18 21:29:06 +00:00
Puliang Lu 9db7b18f4d fibocom: Added support for firmware objects
Added load_update_settings, load_update_settings_finish
Add support for fastboot flash
2023-10-18 21:01:35 +00:00
Aleksander Morgado 16b8b6a08f ublox: remove ID_MM_PROCESS tags
The ID_MM_PROCESS tag should be set by the user when using the
allowlist filter, we must not ship any device flagged by default with
that tag.

Moreover, the two ENV actions in a single rule is something not
currently supported by the builtin udev rule parser that is used in
systems without udev (e.g. openwrt).

Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/779
2023-10-17 21:45:35 +00:00
Robert Marko 8182a10d5d quectel: add support for RM520N
RM520N in USB mode exposes the following:
ttyUSB0 (if #0): QCDM/DIAG port
ttyUSB1 (if #1): GPS data port
ttyUSB2 (if #2): AT primary port
ttyUSB3 (if #3): AT secondary port

So, lets mark them so ModemManager can properly manage them.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
2023-10-12 13:16:36 +02:00
Rukun Mao b7433b4c14 iface-modem: new logic to detect SIM swap with explicit IMSI/ICCID query
This improves SIM hot swap check process, and it can help avoid unnecessary
modem reprobe during suspend-resume without SIM inserted.

The changes in this CL implemented the new logic ONLY for MBIM, and the
new logic has not been implemented for QMI and AT yet. Thus, we keep the
legacy `mm_iface_modem_check_for_sim_swap()' till the new logic for QMI
and AT has been implemented.
2023-10-11 14:01:33 +00:00
ming-pei.hsu 4fdda13c4e mtk: rename for old mtk plugin
Use mtk-legacy to instead mtk plugin.
2023-10-11 13:27:31 +00:00
Lukas Voegl fe0e6059ba cinterion: implement setting primary slot
Signed-off-by: Lukas Voegl <lvoegl@tdt.de>
2023-10-05 11:36:08 +00:00
Lukas Voegl 1341c65b5c cinterion: implement loading multiple SIMs
Signed-off-by: Lukas Voegl <lvoegl@tdt.de>
2023-10-05 11:36:08 +00:00
Lukas Voegl 8cd1c1bdb9 api,modem: new 'Physdev' property
Signed-off-by: Lukas Voegl <lvoegl@tdt.de>
2023-09-18 10:53:12 +02:00
QuectelDuke 1fc061b6a5 quectel: Add RM520 with firehose support
Signed-off-by: QuectelDuke <duke.xin@quectel.com>
2023-09-15 09:49:50 +00:00
QuectelDuke bae7242af6 quectel: Add new EM160 product with firehose support
Signed-off-by: QuectelDuke <duke.xin@quectel.com>
2023-09-14 07:51:12 +00:00
QuectelDuke 0a87294725 quectel: add Sahara udev tag to EM061K-GL modems
Signed-off-by: QuectelDuke <duke.xin@quectel.com>
2023-09-08 08:35:48 +00:00
QuectelDuke 8fc9b77750 quectel: add support for EM060K-GL usb modules
Signed-off-by: QuectelDuke <duke.xin@quectel.com>
2023-08-14 12:03:02 +00:00
Aleksander Morgado 50caac4bdd fibocom: disable multiplexing support in NL668
The NL668 doesn't seem to support multiplexing, as it fails to
transfer data even in the one multiplexed PDN case.
2023-08-05 22:08:01 +00:00