aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2012-09-06broadband-modem-qmi: if WMS service is available Messaging is supportedAleksander Morgado
2012-09-06sms: set state back to UNKNOWN when all SMS parts were deletedAleksander Morgado
2012-09-06sms: transition from Unknown|Stored to Sent when the SMS is sentAleksander Morgado
2012-09-06sms: use property accessors from parent MmGdbusSms when it simplifies thingsAleksander Morgado
2012-09-06sms: transition from Unknown to Stored in user-created SMS objectsAleksander Morgado
2012-09-06sms: user-created SMS objects will have either 'text' or 'data'Aleksander Morgado
2012-09-06libmm-common,sms-properties: handle the 'data' property for SMSAleksander Morgado
2012-09-06sms-part: beware of NULL input dataAleksander Morgado
2012-09-06sms: allow getting list of partsAleksander Morgado
2012-09-06sms: SMS objects need to be create by `create_modem()' in the Messaging ifaceAleksander Morgado
So that plugins can subclass the generic SMS object.
2012-09-06iface-modem-messaging: plug memleakAleksander Morgado
2012-09-06sms: fix setting full text in objectAleksander Morgado
2012-09-06sms-list: add helper debug logsAleksander Morgado
2012-09-06sms-part: add helper debug logsAleksander Morgado
2012-09-06sms-part: new `mm_sms_part_new_from_binary_pdu()' methodAleksander Morgado
2012-09-06bearer: set signal handlers only after setting 'config' and 'modem' propertiesAleksander Morgado
Modem plugins may set the 'modem' property before the 'config' property when creating a bearer. set_signal_handlers() should thus be called after both properties are set such that modem_{3gpp,cdma}_registration_state_changed checks roaming allowance correctly when launching a connection. Based on a draft patch by: Ben Chan <benchan@chromium.org>
2012-09-06icera: properly specify MM_BROADBAND_BEARER_ICERA_DEFAULT_IP_METHOD propertyBen Chan
2012-09-06sms: use g_variant_new_from_data instead of g_variant_new_fixed_arrayBen Chan
ModemManager configure script currenty requires glib 2.30.2 or later, bud g_variant_new_fixed_array requires at least glib 2.32. To maintain the compatibility with glib 2.30, this patch modifies the code to use g_variant_new_from_data instead of g_variant_new_fixed_array.
2012-09-06zte: extend allowed modes for LTE/4G devices for +ZSNT commandMarius B. Kotsbak
Updates: AT+ZSNT=6 means LTE only AT+ZSNT to specify 2G and 3G doesn't support 2G or 3G preference in LTE modems Tested with a ZTE MF 820D.
2012-09-05build: new `--without-qmi' configure optionAleksander Morgado
For those who don't care about the QMI support through libqmi-glib, or if you're stuck with glib 2.30 (libqmi-glib requires 2.32), this configure switch allows disabling the QMI support completely. The logic to detect cdc-wdm ports is still in place, but the QMI probing is never launched at them. Also, all QMI-related objects won't be compiled.
2012-09-04iface-modem-simple: never remove connected bearersAleksander Morgado
Modems have a maximum of bearers allowed to be connected at a time, number which is given by the number of available ports that may be used for data connections. When Simple.Connect() tries to launch a connection, it will try to find first an existing bearer with the required parameters (e.g. APN, IP type). If such bearer is found, it will just use it. If no such bearer is found, it will try to create one. When trying to create one, if there is no more room for bearers in the modem, we will remove the first disconnected bearer that we find, if any, before trying to create the new one. This logic now makes sure that no connected bearer gets removed in order to create a new one, and also that only one existing gets removed if possible (not every bearer as we did previously). Further logic to connect multiple bearers at a time cannot be done using the Simple interface.
2012-09-04plugin: defer task if supports check tells us to retryAleksander Morgado
Huawei modems will probe interface 0 always first; if we try to probe another interface meanwhile the supports check will give us a MM_CORE_ERROR_RETRY error, indicating that we need to defer the probing of the port.
2012-09-03sierra: add support for new !SELRAT values in newer Sierra LTE modemsMarius B. Kotsbak
AT!SELRAT=? !SELRAT: Index, Name 00, Automatic 01, UMTS 3G Only 02, GSM 2G Only 03, Automatic 04, Automatic 05, GSM and UMTS Only 06, LTE Only 07, GSM, UMTS, LTE
2012-09-03iface-modem: don't try to use the bearer list if there is noneAleksander Morgado
When the modem gets unplugged, or system gone into suspend, we start losing the modem ports one by one. When the last is lost, we trigger the disposal of the modem (we call g_object_run_dispose() and then we call the main-reference unref()). So, if we end up losing all ports while the connection sequence was being run, we would end up in this situation, where we try to disconnect the bearers (the bearer and modem objects are still valid, as we have references around, but the list of bearers won't be available any more in the modem object as it was cleared in the modem dispose(). Thread 0 *CRASHED* ( SIGSEGV @ 0x00000000 ) 0x7f5cdbd5cda0 [ModemManager] - mm-bearer-list.c:163] mm_bearer_list_foreach 0x7f5cdbd6a4bd [ModemManager] - mm-iface-modem.c:110] bearer_status_changed 0x7f5cdbad0903 [libgobject-2.0.so.0.3000.2] - gclosure.c:774] g_closure_invoke 0x7f5cdbae1dbb [libgobject-2.0.so.0.3000.2] - gsignal.c:3272] signal_emit_unlocked_R 0x7f5cdbaeac82 [libgobject-2.0.so.0.3000.2] - gsignal.c:3003] g_signal_emit_valist 0x7f5cdbaeae5e [libgobject-2.0.so.0.3000.2] - gsignal.c:3060] g_signal_emit 0x7f5cdbad3876 [libgobject-2.0.so.0.3000.2] - gobject.c:925] g_object_dispatch_properties_changed 0x7f5cdbad5ceb [libgobject-2.0.so.0.3000.2] - gobjectnotifyqueue.c:132] g_object_notify_by_pspec 0x7f5cdbd56b08 [ModemManager] - mm-bearer.c:112] bearer_update_status 0x7f5cdbd56ffd [ModemManager] - mm-bearer.c:393] disconnect_ready 0x7f5cdbbcc676 [libgio-2.0.so.0.3000.2] - gsimpleasyncresult.c:749] g_simple_async_result_complete 0x7f5cdbbcc788 [libgio-2.0.so.0.3000.2] - gsimpleasyncresult.c:761] complete_in_idle_cb 0x7f5cdb7cff44 [libglib-2.0.so.0.3000.2] - gmain.c:2441] g_main_context_dispatch 0x7f5cdb7d0597 [libglib-2.0.so.0.3000.2] - gmain.c:3089] g_main_context_iterate 0x7f5cdb7d0b51 [libglib-2.0.so.0.3000.2] - gmain.c:3297] g_main_loop_run 0x7f5cdbd4e331 [ModemManager] - main.c:150] main 0x7f5cdb1ea41c [libc-2.15.so] - libc-start.c:234] __libc_start_main 0x7f5cdbd4de48 [ModemManager] + 0x00019e48] Reported by Ben Chan <benchan@google.com>
2012-09-02broadband-modem: avoid segfault when initialization sequence is abortedAleksander Morgado
The ports context is only set if the initialization sequence succeeds; so don't try to clear the ports context if it wasn't set.
2012-09-02sierra: use generic current capabilities loadingAleksander Morgado
The generic current capabilities loading already has the required extra AT+WS46=? query to see if LTE capabilities are available.
2012-09-02broadband-modem: run an extra AT+WS46=? when querying current capabilitiesAleksander Morgado
Some modems (e.g. Sierra Wireless MC7710 or ZTE MF820D) won't report LTE capabilities even if they have them. So just run AT+WS46=? as well to see if the current supported modes list includes any LTE-specific mode. This is not a big deal, as the AT+WS46=? command is a test command with a cache-able result, so the next time we need the command result (when loading supported modes) the value will be loaded from the cache.
2012-09-02modem-helpers: recognize "4G" as LTE access technologyMarius B. Kotsbak
Some modems (e.g. ZTE MF 820D) report LTE access technology as "4G": +ZPAS: "4G","PS_ONLY"
2012-08-31broadband-modem-qmi: fix handling of current and overall modem capabilitiesDan Williams
Current capabilities is the set of *active* radios that can be used right now. Modem capabilities are the set of all radios the modem could use, if some action were performed to enable them if they are not enabled already (firmware reload, changing allowed mode, etc). For QMI devices, the DMS Get Capabilities command represents all radios, and thus "modem capabilities". But to read *current* capabilities, ie active radios, we need to query the NAS System Selection Preference and grab the "mode preference" TLV. Unfortunately that is only available with NAS >= 1.1, which means older Gobi devices (1K and 2K) don't support it. So for older devices, we try to get the Technology Preference (which takes into account user-requested limitations) and then mask that with the DMS Get Capabilities result for a best-effort current capabilities. For example, the Pantech UML290VW reports DMS Get Capabilities of "cdma, evdo, gsm, umts, lte", but a more limited SSP mode preference according to what modes are actually enabled. Gobi 1K devices don't support SSP, and the DMS Get Capabilities reports cdma/evdo or gsm/umts depending on the currently loaded firmware. Previous to this patch, ModemManager reported all modes as available on the UML290, ignoring what modes were actually enabled.
2012-08-31broadband-modem-qmi: use System Selection Preference when availableAleksander Morgado
Get/Set Technology Preference was introduced in NAS 1.0, so should be always available (even if we thought it was introduced in NAS 1.7, that's not true). But the newer System Selection Preference behaves better as it allows more features like 'preferred' modes; so use it when available (NAS >= 1.1).
2012-08-31icera: fix parsing of IP config optionsDan Williams
Some of the IP address items will be 0.0.0.0 depending on what the other items are, like when the duplicate gateway is set on newer devices, the first gateway address may be 0.0.0.0. Since that's not a valid IP address, just don't set that member of the config. Second, the intent with the duplicate gateway is only to use that when the first gateway was not given (ie, was 0.0.0.0) so fix the check for that.
2012-08-31broadband-modem-qmi: fix compilation when using `--with-newest-qmi-comands'Aleksander Morgado
2012-08-31sierra: fix finding LTE capabilitiesAleksander Morgado
2012-08-31sierra: allow users to help debug APP1 PPP capabilityDan Williams
Most Sierra PPP-based devices are supposed to allow PPP on the APP1 port, which has a dumb AT parser, leaving the main port (with the intelligent AT parser) free for status and signal strength. But out of all the devices I've tested it with (8775, 8781, AC881, and C885), only the C885 actually works. The rest (including three different firmware versions for the 8775) either crash or disconnect shortly after PPP starts. To help figure out which devices actually support this, when running MM in debug mode, users can set the MM_SIERRA_APP1_PPP_OK environment variable and assume the APP1 port allows PPP. This is only for debugging purposes.
2012-08-31huawei: additional unsolicited messages to ignoreAleksander Morgado
2012-08-31sierra: skip echo removal in the secondary portAleksander Morgado
This is the port to git master of the following commit: commit d1be19d231a395339b1f452d1a30b73ea77ad528 Author: Dan Williams <dcbw@redhat.com> Date: Tue Aug 28 21:58:43 2012 -0500 sierra: fix CSQ handling on APP1 port The APP1 port doesn't always prefix its replies with <CR><LF> which runs afoul of the built-in echo removal. Since Sierra modems are on the whole well-behaved WRT echo removal, just disable it on the secondary ports. Only changes behavior for PPP-based devices since they are the only ones that use the APP1 ports.
2012-08-31port-probe: speed up QCDM probing a bitAleksander Morgado
This is the port to git master of the following commit: commit 01201860de5565a78823913423c6b2a762e3731f Author: Dan Williams <dcbw@redhat.com> Date: Tue Aug 28 21:12:14 2012 -0500 core: speed up QCDM probing a bit The point of sending two "version info" commands was to ensure that the terminating 0x7E of the first one was processed as a QCDM frame boundary and that any random data in the buffer (like AT commands from probing) got cleared out. The second command would always get processed as a valid QCDM command if the device supported QCDM, since there was no garbage before it. Instead of that dance, just prepend the version info message with an extra 0x7E to ensure a clean QCDM frame which the device hopefully responds to immediately. Second, actually process that response instead of throwing it away. Should save about 3 seconds when probing QCDM ports.
2012-08-31sierra: use DHCP for the USB 305 (AT&T Lightning)Aleksander Morgado
This is the port to git master of the following commit: commit 44f70121f75d59dbf31a4a9a1a4e87293e509e7a Author: Dan Williams <dcbw@redhat.com> Date: Tue Aug 28 20:18:40 2012 -0500 sierra: use DHCP for the USB 305 (AT&T Lightning) For some reason, my AT&T Lightning just doesn't work with static IP (AT%IPDPADDR) any more. No traffic passes even though everything is set up the way it was before. No idea what happened. Using latest firmware 2.0.0.11. But what's interesting is on Windows the generic Sierra Watcher app uses DHCP. But on Linux, when using AT%IPDPACT, DHCP doesn't work. That's odd. But it turns out the modem supports the "standard" Sierra proprietary AT!SCACT commands, and that *does* make DHCP work. Crazy no? So since the Windows app uses DHCP, it's likely that the non-DHCP case (AT%IPDPACT/AT%IPDPADDR) either isn't well tested or isn't well supported. With that in mind, let's just use DHCP for this device in Linux too.
2012-08-31icera: handle additional IPv4 configuration optionsAleksander Morgado
This is the port to git master of the following commit: commit c8153b1ecdec1995258b114c90b575af1e721d3d Author: Dan Williams <dcbw@redhat.com> Date: Tue Aug 28 12:16:26 2012 -0500 icera: handle additional IPv4 configuration options Newer devices like the ZTE/Vodafone K3805-z have an enhanced %IPDPADDR command that includes a netmask and gateway, and these are necessary to configure the device since it uses /24 instead of a /32. Since the device is nice enough to tell us that, we should probably use that information. Unfortunately the MM API doens't expose the netmask and gateway yet, so we'll have to add a GetIP4ConfigEx() method or something like that, but this commit sets us up to do that.
2012-08-31modem-helpers: new helper to convert from netmask string to CIDRAleksander Morgado
2012-08-31zte: handle Icera-based devics that use DHCPAleksander Morgado
This is the port to git master of the following commit: commit d2654a287c309346cc46b535dd974b0a5fc06fd4 Author: Dan Williams <dcbw@redhat.com> Date: Tue Aug 28 12:15:30 2012 -0500 zte: handle Icera-based devics that use DHCP Since we can't autodetect that the devices use DHCP, we'll need to tag them with udev rules for the time being.
2012-08-31sierra: use an additional AT+WS46=? to detect LTE capabilitiesAleksander Morgado
Some Sierra modems (e.g. MC7710) will report LTE-specific supported modes in the AT+WS46=? reply, but not +CLTE capability in the AT+GCAP reply: AT+GCAP +GCAP: +CGSM OK AT+WS46=? +WS46: (12,22,25,28,29) OK
2012-08-31broadband-modem: if the generic CNMI request fails, try a ↵Aleksander Morgado
Qualcomm-compatible one This is the port to git master of the following commit: commit 1d9164ec90788d1be134482ff88c501e3c5d623c Author: Dan Williams <dcbw@redhat.com> Date: Mon Aug 27 18:20:33 2012 -0500 gsm: if the generic CNMI request fails, try a Qualcomm-compatible one Many devices based on Qualcomm chipsets don't support a <ds> value of '1', despite saying they do in the AT+CNMI=? response. But they do accept '2'. Since we're not doing much with delivery status reports yet, if we get a CME 303 (not supported) error when setting the message indication parameters via CNMI, fall back to the Qualcomm-compatible CNMI parameters. If we don't do this, we don't get SMS indications on these devices, because the original CNMI failed. Tested on Huawei E1550, Huawei E160G, ZTE MF622, and Novatel XU870.
2012-08-31sms: fix handling of 'data' property for multipart messagesAleksander Morgado
This is the port to git master of the following commit: commit 1c29ce5999d11dee2898e7bf41c00995a00c71d0 Author: Dan Williams <dcbw@redhat.com> Date: Mon Aug 27 17:36:49 2012 -0500 sms: fix handling of 'data' property for multipart messages Text was getting concatenated when reconstructing the full message, but the data wasn't. That meant that non-text multipart messages, like the binary APN/MMS settings messages that operators often send, were broken.
2012-08-31api,introspection: new `Data' property in the SMS interfaceAleksander Morgado
We need to expose the raw data for the case where we get SMS messages with binary content (e.g. settings SMS).
2012-08-31mbm: add Ericsson H5321gw (often found in Thinkpad X230)Dan Williams
2012-08-31sim: better handling of IMSI responseAleksander Morgado
This is a port to git master of the following commit: commit 0b051f9c7033143c56f59267794d1cadf4bd3416 Author: Dan Williams <dcbw@redhat.com> Date: Mon Aug 27 10:24:50 2012 -0500 gsm: better handling of IMSI response Moto EZX devices prefix the response with "+CIMI:" while most devices do not.
2012-08-31novatel: fix checking ERI for roaming/home decisionAleksander Morgado
This is a port to git master of the following commit: commit c21e29c50b5661308fb3b223c05f6942c06dc15d Author: Dan Williams <dcbw@redhat.com> Date: Fri Aug 24 13:31:04 2012 -0500 novatel: fix checking ERI for roaming/home decision More fallout from b22b2d99db57e4cec8e6c3074dd20acd6845cb62 which changed the return type of the qcdm_result_get_*() functions.
2012-08-31icera: retry configuring PDP context if it fails.Aleksander Morgado
This is the port to git master of the following commit: commit fb3187847b9c62d5205962c3c707ac1f44eaddcc Author: Eric Shienbrood <ers@chromium.org> Date: Thu Aug 11 16:58:34 2011 -0400 icera: retry configuring PDP context if it fails. If a connect operation is attempted immediately after a disconnect, it sometimes fails with CME error 583 - "a profile (CID) is currently active". Apparently, even though the preceding operation (%IPDPACT) to deactivate the PDP context returned an OK response, the context is not really completely available until a fraction of a second later. This causes the %IPDPCFG operation that is part of the subsequent connect attempt to fail with error 583. This change retries the %IPDPCFG after a one second delay. BUG=chrome-os-partner:4936 TEST=This can be tested from the UI, but I found it easier to produce the timing needed to trigger the bug by running mm-disconnect and mm-connect from a shell. Start out with the modem in the connected state. In the shell, run sudo /usr/local/lib/flimflam/test/mm-disconnect; sudo /usr/local/lib/flimflam/test/mm-connect --number='*99#' --apn=wap.cingular modem-manager should emit the log line "Invalid error code: 583". Prior to this change, the connect operation would fail. Now it should succeed. Change-Id: I6ae0e6a9f5405b54b0b465fe91d9542529f365c2 Reviewed-on: http://gerrit.chromium.org/gerrit/5781 Tested-by: Eric Shienbrood <ers@chromium.org> Reviewed-by: Nathan J. Williams <njw@chromium.org>
2012-08-31test: add utility to force a modem disconnectDan Williams