Age | Commit message (Collapse) | Author |
|
If we remove the current element being iterated in the GList, we can
no longer call g_list_next() on it. Ensure we keep a valid pointer to
the next element in the list before removing the current one.
|
|
Handling of gdbus interface changes for additional
properties(service cell type and bandwidth) in
broadband modem mbim.
Co-author: Shilpa Shivakumar
|
|
It was not possible to read IMEI of modem when SIM was not inserted or
initialization failed due to modem facility locks. To load IMEI, the
3gpp interface need to be initialized before going to FALLBACK_LIMITED.
|
|
info indication
|
|
It seems like users can put the "unsupported" value for
both DRX cycle and MICO mode, so we should reject that.
|
|
|
|
Some firmware versions return an empty string for the revision when
using the device caps MBIM request, so use AT commands as a fallback
in case this happens.
|
|
FN990 requires more time for the AT ports to become responsive,
so increase the initial delay up to 40 seconds.
|
|
|
|
|
|
This commit modifies the QMI DMS Operating Mode indication registration logic.
During the power sequence chance, if a QMI_PROTOCOL_ERROR_MISSING_ARGUMENT error
was returned in "DMS Set Event Report" operation for Operating Mode Reporting failed,
the whole sequence was aborted, leading the modem to be disabled.
<debug> [modem0] Power indication registration request is sent
...
<debug> [modem0] couldn't update power state: Couldn't register for power indications: QMI protocol error (17): 'MissingArgument'
<warn> [modem0] couldn't enable interface: 'Couldn't register for power indications: QMI protocol error (17): 'MissingArgument''
<debug> [modem0] running implicit disable after failed enable...
This commit modifies the logic to properly detect the failure and
continue the sequence without the indications.
Fixes #683
Signed-off-by: Louis-Alexis Eyraud <louis-alexis.eyraud@unabiz.com>
|
|
Makes my compiler unhappy:
[471/539] Compiling C object src/ModemManager.p/mm-bearer-qmi.c.o
../src/mm-bearer-qmi.c: In function ‘process_operator_reserved_pco’:
../src/mm-bearer-qmi.c:580:18: warning: logical ‘and’ of equal expressions [-Wlogical-op]
580 | if (!tmp_mcc && !tmp_mcc && !container_id && !array->len)
| ^~
Fixes: f4b8d14b8d2d ('bearer-qmi: explicitly ignore PCOs with undefined contents:')
|
|
supported
When using qmi uim service from mbim broadband modem, a fallback from using
qmi uim service to normal mbim operations is done every time a call to
qmi_set_primary_sim_slot fails. But this may fall for various reasons,
and a fallback only makes sense when the device does not support that call
Patch reworked by Aleksander Morgado <aleksandermj@chromium.org>
|
|
|
|
|
|
There is nothing to process in this kind of PCO fields:
<<<<<< TLV:
<<<<<< type = "Operator Reserved PCO" (0x2f)
<<<<<< length = 8
<<<<<< value = 00:00:00:00:00:00:00:00
<<<<<< translated = [ mcc = '0' mnc = '0' mnc_includes_pcs_digit = 'no' app_specific_info = '{}' container_id = '0' ]
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/690
|
|
ModemManager[562783]: <err> [1673538458.350130] mm_utils_bin2hexstr: assertion 'bin != NULL' failed
ModemManager[562783]: <dbg> [1673538458.350167] [modem0/bearer0] container ID: 0
ModemManager[562783]: <dbg> [1673538458.350201] [modem0/bearer0] app specific info: (null)
Treat it better by only trying to build the app specific info string
if there are contents in the array.
|
|
|
|
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/684
|
|
The device may emit a "WDS Profile Changed" indication triggered from
our own "WDS Modify Profile", "WDS Create Profile" or "WDS Delete
Profile" operations, so ensure those are fully ignored so that we
don't emit the "Updated" signal in the ProfileManager interface.
The logic keeps track of the amount of concurrent operations so that
the signal is ignored for as long as there is at least one operation
running.
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/687
|
|
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/686
|
|
Instead of creating libmm-plugin* and libmm-shared* libraries that are
dlopen()-ed on runtime, allow incorporating all plugins into the
daemon binary itself.
This makes the startup of the daemon much faster and also avoids
issues with builds that require linker namespace isolation.
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/674
|
|
|
|
We also remove the plugin headers completely as they are not really
required anywhere.
|
|
<wrn> [plugin-manager] could not load shared '/usr/lib/ModemManager/libmm-shared-xmm.so': Missing major version info
Thread 1 "ModemManager" received signal SIGSEGV, Segmentation fault.
0x000055555562b79d in load_external_shared (path=<optimized out>, self=0x5555557b5880) at ../src/mm-plugin-manager.c:1885
1885 if (module && !(*shared_name))
(gdb) p module
$1 = (GModule *) 0x5555557b9670
(gdb) p shared_name
$2 = (const gchar **) 0x0
|
|
|
|
|
|
|
|
We are going to allow including the plugin sources built within the
ModemManager daemon binary; moving the sources within the daemon
sources directory makes it easier.
|
|
|
|
The 'link_ports' and 'ports' tables are created during object init(),
but they are fully removed and cleared during dispose(). Given that
the MMDevice executes an explicit g_object_run_dispose(), there may be
cases where a long-running operation that isn't cancelled ends up
being completed by the time the object disposal has already run at
least once.
That would end up crashing the process if we attempt to e.g. iterate
over one of the ports hash tables:
0x00007c3594eb3b93 (libglib-2.0.so.0 - ghash.c: 1180) g_hash_table_iter_next
0x00005b60d86f2563 (ModemManager - mm-base-modem.c: 1133) mm_base_modem_get_port_infos
0x00005b60d870228e (ModemManager - mm-iface-modem.c: 4013) fcc_unlock
0x00007c35950126a8 (libgio-2.0.so.0 - gtask.c: 1230) g_task_return_now
0x00007c35950116fa (libgio-2.0.so.0 - gtask.c: 1300) g_task_return
0x00007c3595011d12 (libgio-2.0.so.0 - gtask.c: 1930) g_task_return_new_error
0x00005b60d87518f2 (ModemManager - mm-broadband-modem-mbim.c: 1970) radio_state_set_up_ready
0x00007c35950126a8 (libgio-2.0.so.0 - gtask.c: 1230) g_task_return_now
0x00007c35950116fa (libgio-2.0.so.0 - gtask.c: 1300) g_task_return
0x00007c35950c486c (libmbim-glib.so.4 - mbim-device.c: 253) transaction_task_complete_and_free
0x00007c35950c714b (libmbim-glib.so.4 - mbim-device.c: 335) transaction_timed_out
0x00007c3594ec1232 (libglib-2.0.so.0 - gmain.c: 4971) g_timeout_dispatch
0x00007c3594ec43fc (libglib-2.0.so.0 - gmain.c: 3417) g_main_context_dispatch
0x00007c3594ec4704 (libglib-2.0.so.0 - gmain.c: 4211) g_main_context_iterate
0x00007c3594ec4978 (libglib-2.0.so.0 - gmain.c: 4411) g_main_loop_run
0x00005b60d86d7c56 (ModemManager - main.c: 217) main
0x00007c3594c526c5 (libc.so.6 + 0x000286c5) __libc_init_first
0x00007c3594c52781 (libc.so.6 + 0x00028781) __libc_start_main
0x00005b60d86d7970 (ModemManager + 0x00061970) _start
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/677
Change-Id: I6695c284f86a196e60de7f714bc1671332d08848
|
|
Instead of having the modem object listen notifications in the
MbimDevice, the MMPortMbim will act as an intermediate emitter for the
same.
The primary benefit is that the lifecycle of the port object is
tightly coupled to the life of the modem object, so there is no chance
that the port object outlives the modem object.
And the port object will ensure its own device notification handler is
correctly cleared up on its dispose, so there should be no chance of
firing up a signal in the device for a listener that is already
freed.
|
|
Letting the MMBroadbandModemMbim listen for the notifications of the
MbimDevice was not a good idea, especially since no explicit reference
to the device object was hold in the modem object. This leads to race
conditions in which the MbimDevice outlives the MMBroadbandModemMbim and
the MMPortMbim, and when the "device-removed" signal is triggered, the
program crashes.
The MMPortMbim will now emit its own 'removed' signals when the
underlying MbimDevice emits "device-removed', ensuring that the signal
handler is properly cleared up during the MMPortMbim disposal.
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/518
|
|
Letting the MMBroadbandModemQmi listen for the notifications of the
QmiDevice was not a good idea, especially since no explicit reference
to the device object was hold in the modem object. This leads to race
conditions in which the QmiDevice outlives the MMBroadbandModemQmi and
the MMPortQmi, and when the "device-removed" signal is triggered, the
program crashes.
The MMPortQmi will now emit its own 'removed' signals when the
underlying QmiDevice emits "device-removed', ensuring that the signal
handler is properly cleared up during the MMPortQmi disposal.
|
|
This signal indicates that the port is no longer accessible. Unlike a
udev port removal event, this indication may happen even if the port
is still exposed by the system.
It is designed to detect protocol proxy crashes, and so when such
event is detected by the modem, a full reprobe of the device will be
done to start from scratch the protocol management operations.
|
|
If the modem is already registered when ModemManager probes the modem,
it will ignore the registration state since the modem is not enabled
yet. Always querying the registration state before starting the
registration procedure makes sure to catch such cases and not perform
unnecessary registration steps.
Signed-off-by: Sven Schwermer <sven.schwermer@disruptive-technologies.com>
|
|
This requires bumping libmbim to 1.29.2, which is the version
including the enum->flags change.
|
|
We can directly use this change instead of requiring the libmbim
version bump because the numeric values of the enum didn't change:
NEW_MESSAGE == 2 == (1<<1)
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/673
|
|
|
|
Use g_auto* helpers where needed, and switch to use the slice
allocator for the handler operation contexts.
|
|
|
|
Use g_auto* helpers where needed, and switch to use the slice
allocator for the handler operation contexts.
|
|
|
|
Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/671
|
|
Output of NAS Get Home Network depends on network state, and we may fail
to read SIM card info if device is not attached.
Load card operator name and identifier using UIM Read Transparent.
|
|
client missing
Using mm_shared_qmi_ensure_client() ensures that the client must exist
or otherwise the operation would fail. Instead, try to peek the
clients independently with mm_shared_qmi_peek_client() and only fail
if both exist.
The state machine logic already treats the clients as optional.
|
|
Update profile manager and notify clients if there is a change in modem
profiles list.
|
|
When processing the NAS Signal Info message, don't assume that a
previously processed TLV creates the MMSignal object for a given
access technology.
|
|
|
|
value needs to be divided by 10 as for LTE
|