Commit Graph

5790 Commits

Author SHA1 Message Date
Aleksander Morgado
55408e8b94 device: port probe may be in the ignored list 2016-03-27 21:53:03 +02:00
Aleksander Morgado
f156ec06fb context: use G_OPTION_ARG_FILENAME when a file path is expected 2016-03-27 21:39:11 +02:00
Aleksander Morgado
0f9377686d context: fix --help output
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
2016-03-27 21:35:55 +02:00
Aleksander Morgado
6ba37aa041 base-modem: remove unused 'mm_base_modem_get_port()' method 2016-03-27 18:52:39 +02:00
Aleksander Morgado
1583452554 base-modem: remove unused 'mm_base_modem_owns_port()' method 2016-03-27 18:52:35 +02:00
Aleksander Morgado
547b9b9d87 base-modem: remove unused 'mm_base_modem_release_port()' method 2016-03-27 18:51:45 +02:00
Tomas Jura
ad03445bf7 serial: do not restore termios on port close 2016-03-26 16:54:17 +01:00
Aleksander Morgado
d6cee7782b release: bump version to 1.5.991 (1.6-rc2) 2016-03-25 11:15:14 +01:00
Brian Norris
34961f20a6 libmm-glib: fix enum conversion warning/error
mm-modem-oma.c:400:51: error: implicit conversion from enumeration type 'MMOmaSessionType' to different enumeration type 'MMOmaFeature'
      [-Werror,-Wenum-conversion]
    g_return_val_if_fail (MM_IS_MODEM_OMA (self), MM_OMA_SESSION_TYPE_UNKNOWN);
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/glib-2.0/glib/gmessages.h:382:11: note: expanded from macro 'g_return_val_if_fail'
         return (val);                                                  \
         ~~~~~~  ^~~

This should be MMOmaFeature, not MMOmaSessionType. The end result is the same,
as both are 0.
2016-03-25 11:14:00 +01:00
Aleksander Morgado
2c1230ba7b po: sleep monitor source file was renamed
Reported by: Michael Biebl <biebl@debian.org>
2016-03-23 22:50:34 +01:00
Lubomir Rintel
8fee9a99f0 port-probe: unlink the task from probe before completing it
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: 1939c5ace5
2016-03-22 22:26:16 +01:00
Aleksander Morgado
a0e8505156 build: rename sleep monitor source file, only one implementation available 2016-03-21 23:48:46 +01:00
poma
6197a06931 UPower signaling obsolescence
"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>
2016-03-21 23:44:51 +01:00
Lubomir Rintel
342ea24e34 cinterion: drop unused constants
GCC 6 doesn't like this. Unused since f2024b7.
2016-03-21 15:05:52 +01:00
Lubomir Rintel
2a5909af17 wmc: fix a typo in the test
GCC 6 notices an unused constant and errors out.
2016-03-21 15:02:41 +01:00
Aleksander Morgado
6512fde74d build: fix missing MMCLI_LIBS variable 2016-03-21 11:14:25 +01:00
Aleksander Morgado
021e57a283 build: run configure script from builddir rather than srcdir
Based on an equivalent patch from Philip Withnall <philip@tecnocode.co.uk>
for libmbim; see:

    https://bugs.freedesktop.org/show_bug.cgi?id=94639
2016-03-21 10:45:25 +01:00
Aleksander Morgado
07f899a9d3 release: bump version to 1.5.900 (1.6-rc1)
Also bump soname of libmm-glib, as the interface has grown since the last tag.
2016-03-18 12:56:08 +01:00
Aleksander Morgado
0c2f98d2a7 NEWS: update for 1.6.0 2016-03-18 12:49:39 +01:00
Aleksander Morgado
c6dda5e502 build: require libmbim 1.12 and libqmi 1.14
Preparing for the new ModemManager stable release, we now require the latest
stable series of both libmbim and libqmi.
2016-03-18 11:36:52 +01:00
Aleksander Morgado
d7a643b16a libmm-glib,modem-voice: fix unknown methods in documentation
html/MMCallProperties.html:141: warning: no link for: 'mm-modem-voice-create' -> (<code class="function">mm_modem_voice_create()</code>).
    html/MMCallProperties.html:141: warning: no link for: 'mm-modem-voice-create-sync' -> (<code class="function">mm_modem_voice_create_sync()</code>).
    html/MMModemVoice.html:379: warning: no link for: 'mm-modem-voice-delete-finish' -> (<code class="function">mm_modem_voice_delete_finish()</code>).
    html/MMModemVoice.html:380: warning: no link for: 'mm-modem-voice-delete-sync' -> (<code class="function">mm_modem_voice_delete_sync()</code>).
2016-03-16 18:26:33 +01:00
Aleksander Morgado
4055488fd0 libmm-glib,modem-location: fix unknown method in documentation
html/MMModemLocation.html:516: warning: no link for: 'mm-modem-dup-supl-server' -> (<code class="function">mm_modem_dup_supl_server()</code>).
2016-03-16 18:13:18 +01:00
Dan Williams
1ae6a7be8a build: work around automake-1.15 & intltool complaining about translations in build dir
make distcheck runs a build in dist directory subtirs and then runs intltool -m
which in turn complains about translations in a built file:

  The following files contain translations and are currently not in use. Please
  consider adding these to the POTFILES.in file, located in the po/ directory.

    sub/data/org.freedesktop.ModemManager.policy.in

The issue is reported to intltool upstream already:
https://bugs.launchpad.net/intltool/+bug/1117944
2016-03-15 16:17:42 -05:00
Aleksander Morgado
93bf189fa2 build,libmm-glib: built headers shouldn't be included in dist 2016-03-15 19:15:25 +01:00
Aleksander Morgado
eeb9e2bdcc build: end all multiline list variables with $(NULL)
So that appending a new item in the list only inserts one new line (i.e. the
last $(NULL) is the last item always).
2016-03-15 19:15:25 +01:00
Aleksander Morgado
f9c63bfa05 build,plugins: update build rules
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 plugins build rules are also updated so that whenever a plugin has some
testable 'helpers', these are compiled into a noinst library and then the new
library included by both the plugin and the tester program. This avoids multiple
recompilations of the same sources for different objects.
2016-03-15 19:15:25 +01:00
Aleksander Morgado
3b8361eb06 build,core: update build rules
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
2016-03-15 19:15:25 +01:00
Aleksander Morgado
3bac0a17f5 build,libmm-glib: fix gdbus-codegen rules
The rule with multiple targets means that for each of the target the command
specified is run; not that a single run of the command generates all the targets
specified.

So, generate the .c file with the command, and make the .h and the .xml files
a side-effect of the .c generation.
2016-03-15 19:15:25 +01:00
Dan Williams
0a9cbf65ea modem-helpers: fix handling split PDP context ID reporting in CGDCONT=? response
Cinterion PHS8-US devices send split PDP context ID like "(1-17,101-112)" and
that caused the modem-helpers to choke.
2016-03-15 10:34:28 -05:00
Aleksander Morgado
8ac075d768 build: ignore thuraya helpers test 2016-03-13 18:01:16 +01:00
Aleksander Morgado
e00fd54a20 build: bump required gettext version to 0.19.3
Otherwise:
    configure.ac:86: warning: The 'AM_PROG_MKDIR_P' macro is deprecated, and its use is discouraged.
    configure.ac:86: You should use the Autoconf-provided 'AC_PROG_MKDIR_P' macro instead,
    configure.ac:86: and use '$(MKDIR_P)' instead of '$(mkdir_p)'in your Makefile.am files.
2016-03-13 17:39:20 +01:00
Dan Williams
a9b69d210d huawei: use AT^DHCP response if available for NDISDUP-capable devices
For non-QMI/non-MBIM Huawei devices that use HiSense chipsets,
the recommended way to create the connection is to use NDISDUP
and either DHCP on the net interface, or the ^DHCP command.
There are some reports of devices that connect successfully, but
don't respond to DHCP requests on the interface.  Try to get
IP addressing info from the device via ^DHCP and fall back to
telling clients to use actual DHCP if that fails.

https://bugzilla.redhat.com/show_bug.cgi?id=1254886
2016-03-13 13:25:19 +01:00
Aleksander Morgado
91d343520f huawei: ignore ^LTERSRP unsolicited message
Based on a previous patch from Dan Williams <dcbw@redhat.com>
2016-03-13 13:21:05 +01:00
Aleksander Morgado
1939c5ace5 port-probe: simplify task completion
We no longer need to complete in idle, because the limitation imposed by the
serial port methods no longer exists.
2016-03-11 15:03:07 +01:00
Aleksander Morgado
d9596587e2 port-serial: allow completions not in idle
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.
2016-03-11 15:03:03 +01:00
Carlo Lobrano
1322201a43 telit: implemented set current bands 2016-03-10 16:10:18 +01:00
Aleksander Morgado
93056fe3f2 plugin-manager: allow early cancel of port tasks when they haven't been run yet 2016-03-09 23:59:46 +01:00
Aleksander Morgado
c605b0bc46 port-probe: allow cancellation 2016-03-09 23:59:46 +01:00
Aleksander Morgado
d3bf07e7a8 plugin: allow cancellation of the port probe operation 2016-03-09 23:59:46 +01:00
Aleksander Morgado
fd4fdbf21b plugin-manager: refactor device/port support checks and allow cancellations 2016-03-09 23:59:46 +01:00
Aleksander Morgado
be9b5e0141 plugin-manager: improve logging when loading plugins 2016-03-09 23:59:46 +01:00
Carlo Lobrano
be317e8b80 broadband-modem: fix +CPMS empty parameter support
* 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
2016-03-09 14:43:08 +01:00
Aleksander Morgado
7c2d5b1aa3 helpers: fix check for pid when creating device identifier
https://bugs.freedesktop.org/show_bug.cgi?id=94364
2016-03-02 17:09:33 +01:00
Daniele Palmas
c8a26e472e telit: add current modes setting
This patch adds current modes setting in Telit plugin
2016-02-24 11:22:14 +01:00
Michael Farrell
6e7ff47109 proxmark3 is not a modem, blacklist it.
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
2016-02-20 16:30:01 +01:00
Aleksander Morgado
7652486433 build: ignore telit unit test 2016-02-20 16:26:19 +01:00
Carlo Lobrano
beeabdea2f telit: add load_current_bands interface 2016-02-15 14:22:48 +01:00
Michael Biebl
c533e56e1e tests: white space / indentation fixes
Fixes problems with GCC 6

Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=811583
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=94149
2016-02-15 14:16:25 +01:00
Aleksander Morgado
a08708c10d huawei: avoid trying to disable parent voice unsolicited events
Which actually segfaults, as MMBroadbandModem doesn't implement the
disable_unsolicited_events() method in the voice interface.
2016-02-15 13:38:54 +01:00
Aleksander Morgado
5d8b26eeeb huawei: ignore ^ECCLIST unsolicited messages
These messages list the emergency numbers reported by the network, we don't use
them yet.

E.g.:

  ^ECCLIST: 112,911\r\n
2016-02-15 13:25:42 +01:00