| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
(cherry picked from commit 3911ea5a0f6b26e12a3586c75d72bb2c5820e3c1)
|
|
|
|
| |
(cherry picked from commit 70b8ec1a88477eea3a2f569a83fc270ccaff9504)
|
|
|
|
| |
(cherry picked from commit 81019ca5b519d505da90f119b0037d9cc9916fe4)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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''
(cherry picked from commit ede17bd41c044af1d59b347f8859a9894272d27e)
|
|
|
|
| |
(cherry picked from commit 0512a820cda8e0934ce11339726e66c6dea85d3f)
|
|
|
|
| |
(cherry picked from commit 98c58ca64b7fa80ebe7cf96bcee77c7e9ef02f99)
|
|
|
|
| |
(cherry picked from commit 0a31a466cbeb42c613a80def224c94bba14431c3)
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
mmcli is GPLv2+; that's what --version has always said and that's what the
README in ModemManager sources specifies:
License.
The ModemManager and mmcli binaries are both GPLv2+.
The libmm-glib library is LGPLv2+.
|
| |
|
|
|
|
| |
https://bugs.freedesktop.org/show_bug.cgi?id=90408
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The CPMS test parser was expecting 3 groups (parenthesis enclosed lists) of
memory IDs, e.g.:
+CPMS: ("SM","ME"),("SM","ME"),("SM","ME")
But some modems like the Huawei MU609 may just report single elements, not
groups, e.g.:
+CPMS: "SM","SM","SM"
This patch avoids using g_strsplit() to split the groups, as that is unaware
of the possible replies without groups. Instead, a new helper method is
implemented which does the group/item split itself, considering also the
possibility of a reply with mixed groups and non-groups, like e.g.:
+CPMS: ("SM","ME"),"SM","SM"
Additionally, we also now support the case where the groups are empty, e.g.:
+CPMS: (),(),()
https://bugs.freedesktop.org/show_bug.cgi?id=92243
|
|
|
|
| |
(cherry picked from commit 3129516736bb6eb49458ece7df86f57fce51200e)
|
|
|
|
| |
For now, use 2 digits for MNC if < 100 and 3 digits otherwise.
|
| |
|
|
|
|
|
|
|
|
| |
Auth settings will be added in a QMI message only if at least one of these is
requested:
* An explicit auth preference is requested.
* User string is given and isn't empty.
* Password string is given and isn't empty.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When changing from idle to registered we'll load registration info before really
reporting that we're registered (so that clients can get the new registration
info directly). During this time, we should also allow LAC/CID updates triggered
in the location interface.
E.g. when receiving this QMI message, we're not processing LAC/CID because when
they get reported, the registration state was not yet 'registered':
[/dev/cdc-wdm0] Received message (translated)...
>>>>>> QMUX:
>>>>>> length = 67
>>>>>> flags = 0x80
>>>>>> service = "nas"
>>>>>> client = 1
>>>>>> QMI:
>>>>>> flags = "indication"
>>>>>> transaction = 0
>>>>>> tlv_length = 55
>>>>>> message = "Serving System" (0x0024)
>>>>>> TLV:
>>>>>> type = "MNC PCS Digit Include Status" (0x29)
>>>>>> length = 5
>>>>>> value = D6:00:01:00:00
>>>>>> translated = [ mcc = '214' mnc = '1' includes_pcs_digit = 'no' ]
>>>>>> TLV:
>>>>>> type = "LTE TAC" (0x25)
>>>>>> length = 2
>>>>>> value = 08:01
>>>>>> translated = 264
>>>>>> TLV:
>>>>>> type = "Detailed Service Status" (0x22)
>>>>>> length = 5
>>>>>> value = 02:03:00:01:00
>>>>>> translated = [ status = 'available' capability = 'cs-ps' hdr_status = 'none' hdr_hybrid = 'yes' forbidden = 'no' ]
>>>>>> TLV:
>>>>>> type = "CID 3GPP" (0x1e)
>>>>>> length = 4
>>>>>> value = 01:A1:4D:04
>>>>>> translated = 72196353
>>>>>> TLV:
>>>>>> type = "LAC 3GPP" (0x1d)
>>>>>> length = 2
>>>>>> value = FE:FF
>>>>>> translated = 65534
>>>>>> TLV:
>>>>>> type = "Current PLMN" (0x12)
>>>>>> length = 5
>>>>>> value = D6:00:01:00:00
>>>>>> translated = [ mcc = '214' mnc = '1' description = '' ]
>>>>>> TLV:
>>>>>> type = "Data Service Capability" (0x11)
>>>>>> length = 2
>>>>>> value = 01:0B
>>>>>> translated = { [0] = 'lte '}
>>>>>> TLV:
>>>>>> type = "Serving System" (0x01)
>>>>>> length = 6
>>>>>> value = 01:01:01:02:01:08
>>>>>> translated = [ registration_state = 'registered' cs_attach_state = 'attached' ps_attach_state = 'attached' selected_network = '3gpp' radio_interfaces = '{ [0] = 'lte '}' ]
<debug> [1444895382.427216] Processing 3GPP info...
<info> [1444895382.433423] Modem /org/freedesktop/ModemManager1/Modem/3: 3GPP Registration state changed (idle -> registering)
[ Here we tried to update LAC/CID ]
<debug> [1444895382.439668] Modem /org/freedesktop/ModemManager1/Modem/3: 3GPP location updated (MCC: '214', MNC: '1', Location area code: '0', Cell ID: '0')
<info> [1444895382.446788] Modem /org/freedesktop/ModemManager1/Modem/3: 3GPP Registration state changed (registering -> home)
<info> [1444895382.452383] Modem /org/freedesktop/ModemManager1/Modem/3: state changed (enabled -> registered)
|
|
|
|
|
|
|
|
|
|
|
| |
Given that the Location interface requires 3GPP info reported by the 3GPP
interface, we should only trigger registration checks once the Location
interface has been already enabled and ready to be used. If we don't do this,
we'll end up e.g. getting initial MCCMNC values but never reaching the Location
interface properly.
So, fix this by triggering all registration checks (CDMA and 3GPP) only after
having enabled all interfaces.
|
|
|
|
|
|
|
|
|
| |
LAC/CID may only be given in the serving system indications when the values
change, and therefore we shouldn't reset the values to 0 whenever they're not
reported.
This seems to happen in newer devices; older devices like the MC7710 did always
report the values in the indications.
|
|
|
|
|
|
|
| |
In MM 0.6 days it used to be obfuscated, but that was pointless. Now
it's just the ICCID.
(cherry picked from commit 267b13c231003bddb51afdc91ea85637b7e678bb)
|
| |
|
| |
|
| |
|
|
|
|
| |
remove them
|
| |
|
|
|
|
| |
Same as we do in IPv6. Note that NM won't use it if DHCP is requested.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Breakpoint 2, g_log (log_domain=log_domain@entry=0x7ffff6ad744e "GLib", log_level=log_level@entry=G_LOG_LEVEL_CRITICAL, format=format@entry=0x7ffff6ae0c1d "%s: assertion '%s' failed") at gmessages.c:1075
1075 {
(gdb) bt
#0 0x00007ffff6a71b20 in g_log (log_domain=log_domain@entry=0x7ffff6ad744e "GLib", log_level=log_level@entry=G_LOG_LEVEL_CRITICAL, format=format@entry=0x7ffff6ae0c1d "%s: assertion '%s' failed")
at gmessages.c:1075
#1 0x00007ffff6a71be9 in g_return_if_fail_warning (log_domain=log_domain@entry=0x7ffff6ad744e "GLib", pretty_function=pretty_function@entry=0x7ffff6b316a0 <__FUNCTION__.5266> "g_variant_new_string", expression=expression@entry=0x7ffff6b2f1e8 "g_utf8_validate (string, -1, NULL)") at gmessages.c:1088
#2 0x00007ffff6a9e925 in g_variant_new_string (string=0x7cf850 "260\366\377\177") at gvariant.c:1230
#3 0x00007ffff7068cfe in g_dbus_gvalue_to_gvariant (gvalue=gvalue@entry=0x7fffffffdec0, type=0x7ffff7b9df91) at gdbusutils.c:604
#4 0x00007ffff7b8f1eb in _mm_gdbus_modem3gpp_skeleton_handle_get_property (connection=<optimized out>, sender=sender@entry=0x0, object_path=object_path@entry=0x7bd340 "/org/freedesktop/ModemManager1/Modem/1", interface_name=interface_name@entry=0x7ffff7b97320 "org.freedesktop.ModemManager1.Modem.Modem3gpp", property_name=property_name@entry=0x7ffff7baa0a4 "OperatorCode", error=error@entry=0x0, user_data=0x799ab0)
at mm-gdbus-modem.c:19680
#5 0x00007ffff7b8f894 in mm_gdbus_modem3gpp_skeleton_dbus_interface_get_properties (_skeleton=<optimized out>) at mm-gdbus-modem.c:19759
#6 0x00007ffff708e791 in g_dbus_interface_skeleton_get_properties (interface_=0x799ab0 [MmGdbusModem3gppSkeleton]) at gdbusinterfaceskeleton.c:371
#7 0x00007ffff70937a2 in manager_method_call (connection=<optimized out>, sender=sender@entry=0x7fffe0005200 ":1.270", object_path=object_path@entry=0x7fffe0002fd0 "/org/freedesktop/ModemManager1", interface_name=interface_name@entry=0x7fffe0002dd0 "org.freedesktop.DBus.ObjectManager", method_name=method_name@entry=0x7fffe00059e0 "GetManagedObjects", parameters=parameters@entry=0x7c1e70, invocation=0x7fffe0003260 [GDBusMethodInvocation], user_data=0x713cd0) at gdbusobjectmanagerserver.c:845
#8 0x00007ffff7076aac in call_in_idle_cb (user_data=0x7fffe0003260) at gdbusconnection.c:4884
#9 0x00007ffff6a6a7fb in g_main_context_dispatch (context=0x713a00) at gmain.c:3111
#10 0x00007ffff6a6a7fb in g_main_context_dispatch (context=context@entry=0x713a00) at gmain.c:3710
#11 0x00007ffff6a6ab98 in g_main_context_iterate (context=0x713a00, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at gmain.c:3781
#12 0x00007ffff6a6aec2 in g_main_loop_run (loop=0x71bf50) at gmain.c:3975
#13 0x0000000000430e57 in main (argc=<optimized out>, argv=<optimized out>) at main.c:150
|
|
|
|
| |
Instead, we'll return NULL and an error set.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The MC7304, which is a 3GPP only device, reports a ESN with value 0 in "DMS Get IDs":
ModemManager[10121]: [/dev/cdc-wdm0] Received message (translated)...
>>>>>> QMUX:
>>>>>> length = 45
>>>>>> flags = 0x80
>>>>>> service = "dms"
>>>>>> client = 2
>>>>>> QMI:
>>>>>> flags = "response"
>>>>>> transaction = 6
>>>>>> tlv_length = 33
>>>>>> message = "Get IDs" (0x0025)
>>>>>> TLV:
>>>>>> type = "Result" (0x02)
>>>>>> length = 4
>>>>>> value = 00:00:00:00
>>>>>> translated = SUCCESS
>>>>>> TLV:
>>>>>> type = 0x13
>>>>>> length = 1
>>>>>> value = 42
>>>>>> TLV:
>>>>>> type = "Esn" (0x10)
>>>>>> length = 1
>>>>>> value = 30
>>>>>> translated = 0
>>>>>> TLV:
>>>>>> type = "Imei" (0x11)
>>>>>> length = 15
>>>>>> value = <hidden>
>>>>>> translated = <hidden>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Variability in the response style from certain modems causes the parsing
of the +CGMR response to fail. For example, the Telit HE910 inserts an
empty string ("") in the second field of the response, causing the
sscanf implementation to fail.
This patch converts the parsing of the CGMR response to a regex that
allows for more flexibility and robustness, and adds unit tests around
the parsing call.
Signed-off-by: Nick Stevens <Nick.Stevens@digi.com>
|
| |
|
| |
|
|
|
|
| |
as a warning
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously the enable unsolicited messages command (+CNMI) was only
being sent on the primary. This patch adds support for sending the
enable on the secondary as well. If the secondary doesn't exist, or if
setting the enable causes an error, a warning is logged but no error is
propagated up.
This change is needed for proper SMS operation on the Telit HE910, which
requires that +CNMI be sent to both primary and secondary. Since a
failure to send the +CNMI command on the secondary is a non-fatal error,
it is unlikely that this will cause issues with other modems.
Signed-off-by: Nick Stevens <Nick.Stevens@digi.com>
|
|
|
|
|
|
|
|
| |
https://bugs.freedesktop.org/show_bug.cgi?id=85008
As reported by Sven Arvidsson <sa@whiz.se>.
(cherry picked from commit 5fb8e87abd82d4eb463fdb601ca33ead153f5fc2)
|
|
|
|
|
|
|
|
| |
https://bugs.freedesktop.org/show_bug.cgi?id=85008
As reported by Dan Williams <dcbw@redhat.com>.
(cherry picked from commit f60b0551429bbb767d0154f9c1335146641d340a)
|
|
|
|
|
|
|
|
|
| |
The udev rules file is updated according to the list of devices
supporting gps features provided by the udev rules file from the
mbm-gpsd project.
https://bugs.freedesktop.org/show_bug.cgi?id=85008
(cherry picked from commit 534eea345dd8dda96a88559b621ab1a55028cee8)
|
|
|
|
|
|
|
| |
Changing udev rules for HE910/UE910/UL865 in order to use dynamic port
identification through #PORTCFG (tag ID_MM_TELIT_PORTS_TAGGED)
(cherry picked from commit 12318970a7df2e0dd83b8284762e4cf7294fe0d3)
|
|
|
|
|
|
|
|
| |
Adding dynamic port identification for Telit modems that support AT#PORTCFG
command. Port configurations for HE910/UE910/UL865 taken from document
"HE910/UE910/UL865 Families Ports Arrangements User Guide"
(cherry picked from commit ad6d15b535e80392ee04581f5d638cb73367170c)
|
|
|
|
|
|
|
| |
Add a default implementation that queries the real-time clock using the
AT+CCLK? command. Also set AT+CTZU=1 in case a modem requires it.
(cherry picked from commit 3ad64c8f5aed43697bf289fce277bde48f208051)
|
|
|
|
|
|
|
| |
If all other registration states are UNKNOWN, use a registration state
of DENIED as the global modem state.
(cherry picked from commit 9186e2aa39668c0d071f52d47d6a1aea087bc8a7)
|