| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
v4: modems/providers may not return DNS servers and not all modems
support DHCP, so lack of DNS servers should not indicate a bearer
IP method of "DHCP". IP config daemon/scripts already have to handle
missing DNS anyway.
v6: IPv6 requires SLAAC or DHCPv6 as part of the specification, so for
now we assume modems will support it. Provide all the info the modem
sent, but if there is any missing information use an IP method of
"DHCP" to indicate that info should be obtained via SLAAC/DHCPv6. Only
use an IP method of "STATIC" when all basic properties are given by
the modem.
|
|
|
|
|
| |
Hook up to the WDS Packet Service Status indication, listen for
disconnection events, and disconnect the bearer when we get one.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When we were completing tasks in idle, the logic was like this:
* Schedule task completion in idle
* self->priv->task = NULL
* (idle) Task completion callback called
This meant that the self->priv->task was always set to NULL before the
completion callback was called, which is what we wanted as a new task may be
scheduled in the callback itself.
Now, without completing in idle, we were wrongly doing:
* Task completion callback called
* self->priv->task = NULL
This commit fixes the logic by making sure self->priv->task = NULL before any
task completion.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
The options that require an argument should explicitly specify so.
Before:
--log-level=INFO Log level: one of [ERR, WARN, INFO, DEBUG]
--log-file Path to log file
After:
--log-level=[LEVEL] Log level: one of ERR, WARN, INFO, DEBUG
--log-file=[PATH] Path to log file
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
| |
The task completion may try to enqueue a next probe task and in
mm_port_probe_run() it asserts there's no task linked.
https://bugs.freedesktop.org/show_bug.cgi?id=94664
Fixes: 1939c5ace50240127276efacec5c7f166483bb79
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
"Newer upower versions no longer emit that signal since this handled by systemd."
by Michael Biebl <mbiebl@gmail.org>
https://lists.freedesktop.org/archives/devkit-devel/2014-March/001575.html
See also "Plans for UPower 1.0"
by Richard Hughes <hughsient@gmail.com>
https://lists.freedesktop.org/archives/devkit-devel/2013-January/001339.html
Signed-off-by: poma <pomidorabelisima@gmail.com>
|
|
|
|
|
| |
So that appending a new item in the list only inserts one new line (i.e. the
last $(NULL) is the last item always).
|
|
|
|
|
|
|
|
|
| |
We try to combine in common envvars the compiler and linker flags shared by the
different components, and where possible, also re-using the implicit AM_CFLAGS
and AM_LDFLAGS variables that automake provides, and which apply to all objects
being built in the same Makefile.am.
The internal libmodem-helpers.la library is also renamed to libhelpers.la
|
|
|
|
|
| |
Cinterion PHS8-US devices send split PDP context ID like "(1-17,101-112)" and
that caused the modem-helpers to choke.
|
|
|
|
|
| |
We no longer need to complete in idle, because the limitation imposed by the
serial port methods no longer exists.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Port serial command completions may be performed in several different places:
* When a cached response is set during command sending.
* When errors happen during command sending.
* When we process a response (i.e. common_input_available())
* When we process a timeout (i.e. port_serial_timed_out())
* When cancelled (i.e. port_serial_response_wait_cancelled())
We're currently safe with the previous logic only because the users of the
serial port explicitly complete operations in idle, which means that whenever
we're processing in a internal callback (e.g. during response or timeout
processing) the serial port object is valid for as long as the callback runs.
But, if we ever end up using the serial port with a not-in-idle completion,
it may happen that if the command is completed within a internal signal callback
the serial port object may get fully closed and unref-ed before exiting the
callback.
We could force a valid port reference to exist as long as the internal signal
is scheduled, but then we may lose the ability to automatically close the port
during a full unref(), as the internal signals are set as long as the port is
open.
So, to cope with this possibility of not-in-idle completion, we instead force
references to be valid whenever we see that a command completion may happen,
which is basically whenever port_serial_got_response() is called; but we only
do that if we're going to use the port object after that, otherwise, we ignore
the problem.
In addition to the problems with the references, we also update the
common_input_available() method so that the source isn't kept if the last
response buffer processing ended up closing the port.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add new async virtual method init_current_storages to
MMIfaceModemMessaging
* Add logic of init_current_storages to MMBroadbandModem
* Add step "INIT_CURRENT_STORAGES" in MMIfaceModemMessaging
initialization in order to load and store current SMS
storages for mem1 and mem2.
* Add usage of current sms storage value for mem1 in place
of an empty string parameter when the command AT+CPMS
is used.
https://bugs.freedesktop.org/show_bug.cgi?id=93135
|
|
|
|
| |
https://bugs.freedesktop.org/show_bug.cgi?id=94364
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
ModemManager locks the proxmark3 when it is connected. As it is not a modem,
ModemManager shouldn't be talking to it.
At present, the recommended action in the proxmark3 documentation is to
purge ModemManager to fix this issue.
Note that this vendor uses an unregistered USB device ID, so it is
instead matched by the manufacturer string.
References:
- http://store.ryscc.com/blogs/news/45802433
- http://www.proxmark.org/forum/viewtopic.php?id=1759
|
|
|
|
|
| |
We should really consider errors if we expect that the regex string may not
compile; but in this case the pattern is fixed, so should never happen.
|
|
|
|
|
|
| |
Also added test cases.
Signed-off-by: Thomas Sailer <t.sailer@alumni.ethz.ch>
|
|
|
|
|
|
|
|
| |
GSM 07.07 CREG=2 unsolicited pattern.
Added testcase for Thuraya XT.
Signed-off-by: Thomas Sailer <t.sailer@alumni.ethz.ch>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A Huawei E173 (with FW 11.126.15.00.445) seems to stop responding on the
primary port (ttyUSB2) when the CGACT is resent on the data port (ttyUSB0).
The CGACT-on-data-port was originally added as a fallback attempt to get
single-port modems to disconnect when all other methods failed.
For single-port modems, the primary port is also the data port so this
patch will have no effect.
For multi-port modems, this patch will retry the CGACT on the primary
port which has a higher chance of success because we already know
the primary port is talking to us, while the data port may still
be stuck in PPP mode.
|
|
|
|
|
|
| |
Add testcase for Thuraya XT.
Signed-off-by: Thomas Sailer <t.sailer@alumni.ethz.ch>
|
|
|
|
|
|
|
| |
The MMBroadbandModemQmi will not create a MMSimQmi until the unlock status has
been checked, and therefore this means that when the SIM object is being created
we already know whether the modem supports DMS UIM commands or not, so avoid
further fallbacks in the SIM object.
|
|
|
|
|
|
|
|
|
|
|
| |
Newer modems like the MC7455 don't implement the "DMS UIM" commands in the
DMS service, and therefore these modems need to use the UIM service directly.
We include a new flag to detect whether any of the DMS UIM commands is flagged
as invalid, and if so, we'll fallback to the UIM specific implementations for
all.
libqmi version bump to 1.13.7, which includes the new required methods.
|
|
|
|
|
| |
Newer modems like the MC7455 don't implement the "DMS UIM" commands in the
DMS service, and therefore these modems need to use the UIM service directly.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
When the card application is flagged as needing PIN or PUK, then the card can be
considered as being ready.
|
|
|
|
|
| |
The newer modules like the MC7455 which support multiple SIM cards won't
implement the legacy "DMS UIM" commands.
|
|
|
|
|
| |
When using raw-ip we'll default to request static IP setup for now, so that we
don't rely on the DHCP client supporting raw-ip interfaces.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The port opening logic is changed completely.
Before this change, the logic would only try 802.3 setting via CTL when the
QmiDevice was being open.
With this new change, instead, we'll use WDA and the new libqmi APIs to query
the link layer protocol expected by both the device and the kernel. If the LLP
matches in both, we assume we're done; if they differ we'll try to update the
LLP expected by the kernel to the one setup in WDA. This change will allow us
to run with the modem using raw-ip if that is what WDA reports by default.
Also bumped the libqmi version to 1.13.6, which has support for the new required
APIs.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Response parsing was being done in different places for AT and QCDM subclasses;
in the case of AT it was being done early, before returning the byte array in
the mm_serial_port_command_finish() response. In the case of QCDM, it was being
done after mm_serial_port_command_finish(), and that was forcing every caller to
cleanup the response buffer once the response was processed.
With the new logic in this patch, the response is always parsed (i.e. looked for
a valid response or an error detected) before mm_serial_port_command_finish()
returns, and actually this method now returns a totally different GByteArray,
not the internal response buffer GByteArray, so there's no longer any need for
the caller to explicitly clean it up. The one doing the cleanup is the parser
method itself in every case.
This change also allows us to return serial port responses in idle, but that's
not changed for now as there's no immediate need.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When valid responses were returned to the caller of the serial command, the
caller itself was responsible for removing from the GByteArray the data that
it was successfully processed (all the data in AT, just 1 message in QCDM). But,
the same logic was missing for the case of errors; we were not explicitly
removing the response and therefore in some cases we would see it propagated
into the next command response. It was common to see this issue when the echo
removal was disabled in the serial port, as in Option/HSO modems:
<debug> (ttyHS3): --> 'AT+CNUM<CR>'
<debug> (ttyHS3): <-- '<CR><LF>+CME ERROR: 14<CR><LF>'
<debug> Got failure code 14: SIM busy
<debug> (ttyHS3) device open count is 1 (close)
<warn> couldn't load list of Own Numbers: 'Failed to parse NV MDN command result: -17'
<debug> (ttyHS3) device open count is 2 (open)
<debug> (ttyHS3): --> 'AT_OPSYS?<CR>'
<debug> (ttyHS3): <-- '<CR><LF>_OPSYS: 1,2<CR><LF><CR><LF>OK<CR><LF>'
<warn> couldn't load current allowed/preferred modes: 'Couldn't parse OPSYS response: '+CME ERROR: 14
_OPSYS: 1,2''
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We were trying to load the generic modes supported reported by either *CNTI=2 or
AT+WS46=?, so that then we could filter out the MBM-specific modes unsupported.
But, this may not be ideal, as both these two commands may fail:
[mm-broadband-modem.c:1612] modem_load_supported_modes(): loading supported modes...
[mm-port-serial.c:1237] mm_port_serial_open(): (ttyACM1) device open count is 3 (open)
[mm-port-serial.c:1294] _close_internal(): (ttyACM1) device open count is 2 (close)
[mm-port-serial-at.c:440] debug_log(): (ttyACM1): --> 'AT*CNTI=2<CR>'
[mm-port-serial-at.c:440] debug_log(): (ttyACM1): <-- '<CR><LF>ERROR<CR><LF>'
[mm-serial-parsers.c:364] mm_serial_parser_v1_parse(): Got failure code 100: Unknown error
[mm-broadband-modem.c:1546] supported_modes_cnti_ready(): Generic query of supported 3GPP networks with *CNTI failed: 'Unknown error'
[mm-port-serial.c:1237] mm_port_serial_open(): (ttyACM1) device open count is 3 (open)
[mm-port-serial.c:1294] _close_internal(): (ttyACM1) device open count is 2 (close)
[mm-port-serial-at.c:440] debug_log(): (ttyACM1): --> 'AT+WS46=?<CR>'
[mm-port-serial-at.c:440] debug_log(): (ttyACM1): <-- '<CR><LF>ERROR<CR><LF>'
[mm-serial-parsers.c:364] mm_serial_parser_v1_parse(): Got failure code 100: Unknown error
[mm-broadband-modem.c:1494] supported_modes_ws46_test_ready(): Generic query of supported 3GPP networks with WS46=? failed: 'Unknown error'
[mm-iface-modem.c:3974] load_supported_modes_ready(): couldn't load Supported Modes: 'Couldn't retrieve supported modes'
Instead, we'll ask the modem for the list of modes supported, and return that
directly.
|