Age | Commit message (Collapse) | Author |
|
And consolidate the connection status checks done during connection and
disconnection so that we re-use the same logic.
|
|
This is the same logic used in other implementations (e.g. QMI).
|
|
The suggestion to use specific PDP context CIDs was given by Cinterion
for the special case of the Verizon operator, which 'reserves' specific
CIDs for specific purposes.
We don't want to impose that at the Cinterion plugin level, so remove
the PDP context mapping we had.
Therefore, simplify the connection procedure by just overriding the
'dialing' step of the default 3GPP connection sequence, instead of
overriding the whole connection sequence.
Also, we don't need to override the step to gather IP config because
this is already handled by the generic plugin (for DHCP over a network
interface).
We port to GTask for both 3GPP dial and 3GPP disconnect at the same time.
|
|
|
|
Better check for ^SWWAN support during the first time a bearer is going
to be created.
The enabling phase isn't the correct one because this logic is only run
whenever a modem is detected but not hotplugged (i.e. this step is to
'reset' the modem to generic runtime settings).
|
|
|
|
We get as input the ^SWWAN index we're interested in, and we loop
through the list of ^SWWAN lines looking for the one we need.
This updated helper method allows working with multi-line ^SWWAN
responses, e.g. given when more than one PDP context is active.
|
|
The only member in the private network isn't even used.
|
|
Group together all connection related logic (e.g. context) and define
the context steps directly within the connection sequence processing.
Also, don't initially run a disconnection before the connection; if that
logic is ever needed we should likely have it in the generic modem, not
done per plugin.
And error out early if not asking for IPv4.
|
|
Group together all disconnection related logic (e.g. context) and define
the context steps directly within the disconnection sequence processing.
|
|
|
|
Define the relationship between PDP context, SWWAN index and USB
interface number in one single place.
|
|
The enum values are given in UPPER_CASE format, not in CamelCase.
|
|
We already get the data port given as input parameter in
disconnect_3gpp(), so there is no point in trying to find out which the
data port is.
|
|
|
|
|
|
Fixes: 3206e9566392e8a9678bbd49e0de9bb21ed75291
|
|
qss unsolicited handler should be assigned to primary port first,
while secondary port was peeked.
|
|
mm_device_create_modem needs a valid object_manager instance to create the new
modem, while the one provided before was cleared out by a call to
mm_device_remove_modem few lines before.
Since the newly created modem refers to the same HW device, we can use
the same object_manager also.
https://bugs.freedesktop.org/show_bug.cgi?id=99160
|
|
Moved blacklist code to 77-mm-usb-device-blacklist.rules as per code review
|
|
E.g. if the connection attempt fails, connect_context_complete_and_free() may
be called before the signals are connected to the QmiClients.
https://bugs.freedesktop.org/show_bug.cgi?id=99047
|
|
|
|
So that different concurrent runs of this same test don't clash with
each other:
TEST: test-service-generic... (pid=11124)
/MM/Service/Generic/enable-disable: Activating service name='org.freedesktop.ModemManager1'
Successfully activated service 'org.freedesktop.ModemManager1'
** (plugins/.libs/lt-test-service-generic>:11124): ERROR **: Cannot bind socket: Error binding to address: Address already in use
cleaning up pid 11144
FAIL
|
|
|
|
And avoid including the wip-* XMLs in the dist tarball.
|
|
Looks like gdbus-codegen ends up making paragraphs and that breaks the
XML parsing:
DOC Building HTML
../../../../libmm-glib/generated/mm-gdbus-doc-org.freedesktop.ModemManager1.xml:60: parser error : Opening and ending tag mismatch: variablelist line 59 and para
</para><para> <varlistentry><term><literal>action</literal></term>
^
../../../../libmm-glib/generated/mm-gdbus-doc-org.freedesktop.ModemManager1.xml:110: parser error : Opening and ending tag mismatch: para line 110 and variablelist
</para><para> </variablelist>
^
../xml/ModemManager-dbus-reference.xml:93: element include: XInclude error : could not load ../../../../libmm-glib/generated/mm-gdbus-doc-org.freedesktop.ModemManager1.xml, and no fallback was found
|
|
This is so that "make check" doesn't depend on having the rule files
installed in the default udev rules directory, which currently would
break the build:
TEST: test-service-generic... (pid=2601)
/MM/Service/Generic/enable-disable: Activating service name='org.freedesktop.ModemManager1'
Successfully activated service 'org.freedesktop.ModemManager1'
** (/home/aleksander/Development/foss/ModemManager/plugins/.libs/lt-test-service-generic:2601):
ERROR **: Error setting test profile: GDBus.Error:org.freedesktop.ModemManager1.Error.Core.Failed: Failed to find primary AT port
FAIL
GTester: last random seed: R02S3897abaae9df36f8d2eeb679406ab675
make[3]: *** [Makefile:3804: test-nonrecursive] Terminated
|
|
Added support for 4-digit format years (i.e. YYYY), and also made the
timezone information optional, as per +CSDF in 3GPP TS 27.007.
https://bugs.freedesktop.org/show_bug.cgi?id=95319
|
|
|
|
The original g_udev_device_get_property_as_int() uses strtol() without
an explicit base (i.e. 0) so that the base is autodetected from the
string whenever possible (e.g. if prefixes with '0x' it is treated as a
hexadecimal string).
But, for ID_USB_INTERFACE_NUM, we explicitly require reading the number
as an hex string, even if we don't have any '0x' prefix.
Reported-by: Matthew Stanger <stangerm2@gmail.com>
|
|
If a port has been flagged as ignored with the ID_MM_PORT_IGNORE udev property,
we shouldn't open and probe the ports in any way, just flag them as ignored. We
still report them in the list of modem ports, but just with "unknown" type and
therefore not using them for anything.
|
|
Since automake 1.11.2 it is recommended that packages
use AM_DISTCHECK_CONFIGURE_FLAGS instead of
DISTCHECK_CONFIGURE_FLAGS as the latter is intended
to be a user variable.
https://bugs.freedesktop.org/show_bug.cgi?id=95826
|
|
status checking
Telit LE922A does not like the legacy way for checking pin status, but
instead of returning QMI_PROTOCOL_ERROR_INVALID_QMI_COMMAND, it returns
QMI_PROTOCOL_ERROR_NOT_SUPPORTED, making the modem not to be fully
initialized.
This patch adds QMI_PROTOCOL_ERROR_NOT_SUPPORTED as another error for
which the new pin checking status way is tried.
|
|
This is the value which we actually suggest in the manpage for the mmcli
operation, so just use the same one.
Scanning for 3GPP networks may really take a long time, so a specific timeout must be given:
$ mmcli -m 0 --3gpp-scan --timeout=300
Found 4 networks:
21404 - Yoigo (umts, available)
21407 - Movistar (umts, current)
21401 - vodafone ES (umts, forbidden)
21403 - Orange (umts, forbidden)
https://bugs.freedesktop.org/show_bug.cgi?id=98235
|
|
What's left enabled:
* Access to /dev -- obviously
* CAP_SYS_ADMIN -- this is needed by TIOCSSERIAL only. Too bad this also
allows TIOCSTI, which allows for code injection unless something else
(SELinux) disallows access to ttys with shells.
Maybe kernel should use CAP_SYS_TTY_CONFIG for this.
* socket(AF_NETLINK) -- udev & kernel device changes
* socket(AF_UNIX) -- D-Bus
|
|
These CDC ACM class devices are docking stations for Sigma Sport bike
computers. As they are sensitive to single byte commands, ModemManager
probing mechanism actually caused training data on attached bike
computer to be zeroed.
https://bugs.freedesktop.org/show_bug.cgi?id=96430
|
|
In place of two slightly different regexes for 2g/3g and 2g/3g/4g modems
we now use only one regex with conditional patterns for both supported
and current Bands detection.
Adding also minor fix in test code
|
|
|
|
https://bugs.freedesktop.org/show_bug.cgi?id=98220
|
|
Otherwise the build log is very very dense...
../../src/mm-broadband-modem-qmi.c: In function 'modem_load_own_numbers':
../../src/mm-broadband-modem-qmi.c:1406:5: warning: 'g_simple_async_result_new' is deprecated (declared at /usr/include/glib-2.0/gio/gsimpleasyncresult.h:51): Use 'g_task_new' instead [-Wdeprecated-declarations]
result = g_simple_async_result_new (G_OBJECT (self),
^
../../src/mm-broadband-modem.c: In function 'signal_quality_qcdm_ready':
../../src/mm-broadband-modem-mbim.c: In function 'modem_3gpp_scan_networks_finish':
../../src/mm-broadband-modem.c:1986:9: warning: 'g_simple_async_result_take_error' is deprecated (declared at /usr/include/glib-2.0/gio/gsimpleasyncresult.h:116) [-Wdeprecated-declarations]
g_simple_async_result_take_error (ctx->result, error);
^
../../src/mm-broadband-modem-mbim.c:2824:5: warning: 'g_simple_async_result_propagate_error' is deprecated (declared at /usr/include/glib-2.0/gio/gsimpleasyncresult.h:119) [-Wdeprecated-declarations]
if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (res), error))
^
|
|
https://bugs.freedesktop.org/show_bug.cgi?id=98216
|
|
|
|
When the device is reset, it needs some time before the newly exposed TTYs are
able to reply to our AT commands. We increase the default timeout of the AT
probing commands in order to cope with that, or we'll end up with TTYs of
'unknown' type that aren't used for anything.
|
|
u-blox modems will append a string showing the MCC and MNC info to the access
point name listed in AT+CGDCONT? responses. We will try to detect when that
happens, and we just accept the match.
The logic doesn't just look for a string prefix; it also looks for the special
MCC + MNC suffix, which is much more restrictive, to try to avoid false
positives.
|
|
|
|
The implementation uses +UGCNTRD=? to query whether the per-PDP context
statistics are supported by the device, and if they are, +UGCNTRD is used to
query them.
We only process the statistics for the specific CID we're using.
|
|
The parser returns only the results for the CID being specified as input. This
is so that we can just query the statistics of the CID currently in use by the
bearer.
|
|
|
|
Reuse the logic and context used to update current modes, as we need the same
steps (check current power state, go into low power, config update, and recover
previous power state).
|
|
|