summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* libnm: fix range of MTU property to uint32 for ip-tunnelth/infiniband-max-mtuThomas Haller2019-04-051-2/+2
| | | | | This should make no difference, because commonly guint32 is a typedef for guint/unsigned and has the same range.
* device: limit maximum MTU for connection default of "infiniband.mtu"Thomas Haller2019-04-053-6/+9
| | | | | | Connection defaults should correspond in range to the per-profile values. "infiniband.mtu" is required to be not larger than 65520, so we also need to honor that when parsing the connection default.
* libnm/infiniband: lift restriction of MTU to 2044 for IPoIB in "datagram" modeThomas Haller2019-04-054-34/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Traditionally, the MTU in "datagram" transport mode was restricted to 2044. That is no longer the case, relax that. In fact, choose a very large maximum and don't differenciate between "connected" mode (they now both use now 65520). This is only the limitation of the connection profile. Whether setting such large MTUs actually works must be determined when activating the profile. Initscripts "ifup-ib" from rdma-core package originally had a limit of 2044. This was raised to 4092 in rh#1186498. It is suggested to raise it further in bug rh#1647541. In general, kernel often does not allow setting large MTUs. And even if it allows it, it may not work because it also requires the entire network to be configured accordingly. But that means, it is generally not helpful to limit the MTU in the connection profile too strictly. Just allow large MTUs, we need to see at activation time whether the configuration works. Related: https://bugzilla.redhat.com/show_bug.cgi?id=1186498 Related: https://bugzilla.redhat.com/show_bug.cgi?id=1593334 (rdma-core: raise limit from 2044 to 4092 in ifup-ib) Related: https://bugzilla.redhat.com/show_bug.cgi?id=1647541 (rdma-core: raise limit beyond 4092 in ifup-ib) Related: https://bugzilla.redhat.com/show_bug.cgi?id=1532638#c4 (rdma-core: MTU related discussion) Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1534869 (NetworkManager bug about this topic, but with lots of unrelated discussion. See in particular #c16) Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1653494
* all: merge branch 'th/strstrip'Thomas Haller2019-04-045-143/+219
|\ | | | | | | https://github.com/NetworkManager/NetworkManager/pull/329
| * cli: use nm_strstrip_avoid_copy_a() to avoid heap allocationThomas Haller2019-04-041-7/+7
| |
| * shared: cleanup _nm_utils_ascii_str_to_bool()Thomas Haller2019-04-041-18/+14
| | | | | | | | | | | | | | | | Previously, this would re-implement what nm_strstrip_avoid_copy() was doing. Use nm_strstrip_avoid_copy_a() instead, which avoids the code duplication and the heap allocation in common cases.
| * shared: add nm_strstrip_avoid_copy_a() helperThomas Haller2019-04-042-0/+80
| |
| * shared: move nm_memdup(), nm_strndup_a(), and nm_strdup_int() to ↵Thomas Haller2019-04-042-112/+112
| | | | | | | | | | | | | | | | | | | | | | | | | | | | "nm-macros-internal.h" The main difference between "shared/nm-utils/nm-macros-internal.h" and "shared/nm-utils/nm-shared-utils.h" is that the former is header-only while the latter has a source file as well. Apart from that, both headers are included everywhere. The next commit will add nm_strstrip_avoid_copy_a() to "nm-macros-internal.h" header, which will use nm_strndup_a(). Hence, also nm_strndup_a() should be in "nm-macros-internal.h".
| * shared/trivial: rename variables in nm_strndup_a() and ↵Thomas Haller2019-04-042-18/+18
|/ | | | | | | | | nm_str_skip_leading_spaces() macros "_str" is a very tempting name for a temporary variable. Rename the variable in nm_strndup_a() macro, so that other macros can call these (more general) macros (and still use the name "_str").
* sriov: merge branch 'bg/sriov-drivers-autoprobe-rh1695093'Beniamino Galvani2019-04-044-12/+78
|\ | | | | | | | | https://github.com/NetworkManager/NetworkManager/pull/331 https://bugzilla.redhat.com/show_bug.cgi?id=1695093
| * platform: assume 'sriov_drivers_autoprobe' is 1 when sysfs file is missingBeniamino Galvani2019-04-041-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'sriov_drivers_autoprobe' was added in kernel 4.12. With previous kernel versions NM is currently unable to set any SR-IOV parameter because it tries to read 'sriov_drivers_autoprobe' which doesn't exist, assumes that current value is -1 and tries to change it, failing. When the file doesn't exist, drivers are automatically probed so we can assume the value is 1. In this way NM is able to activate a connection with sriov.autoprobe-drivers=1 (the default) even on older kernel versions. Fixes: 1e41495d9a1b ('platform: sriov: write new values when we can't read old ones') https://bugzilla.redhat.com/show_bug.cgi?id=1695093
| * platform: set errno to ENOENT for nm_platform_sysctl_get()Thomas Haller2019-04-044-12/+70
|/
* libnm-core: fix build warningBeniamino Galvani2019-04-041-1/+1
| | | | | | libnm-core/nm-keyfile.c:679:32: error: 'key_type' may be used uninitialized in this function [-Werror=maybe-uninitialized] build_list[build_list_len++] = (BuildListData) { ^
* acd: merge branch 'th/gitlab-ci-fixes'Thomas Haller2019-04-0410-27/+72
|\ | | | | | | https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/103
| * acd/tests: assert that nm_acd_manager_announce_addresses() did not failThomas Haller2019-04-041-1/+3
| |
| * acd/tests: use nm_auto cleanup attributes for mainloop and NMAcdManagerThomas Haller2019-04-041-11/+7
| |
| * acd: return error code from nm_acd_manager_start_probe()Thomas Haller2019-04-044-15/+49
| | | | | | | | | | | | | | ... and nm_acd_manager_announce_addresses(). The test will need more information to know why it may fail. Return a NetworkManager error code, instead of a boolean.
| * core: add nm_auto_free_acdmgr cleanup macroThomas Haller2019-04-041-0/+3
| |
| * shared: add nm_auto_unref_gmainloop cleanup macroThomas Haller2019-04-041-0/+3
| |
| * contrib/rpm: disable NDEBUG for meson buildsThomas Haller2019-04-041-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For better or worse, our release builds commonly do not disable assertions. That means, - NDEBUG is not set, and assert() is in effect - G_DISABLE_ASSERT is not set, and g_assert() is in effect - G_DISABLE_CHECKS is not set, and g_return*() is in effect. On the other hand, NM_MORE_ASSERTS is not enabled by default and nm_assert() is stripped away. That is the actual purpose of nm_assert(): it is commonly disabled on release builds, while all other assertions are enabled. Note that it is fully supported to build NetworkManager with all kind of assertions disabled. However, such a configuration is not much tested and I would not recommend it for that reason. %meson expands to $ /usr/bin/meson --buildtype=plain --prefix=/usr --libdir=/usr/lib64 --libexecdir=/usr/libexec --bindir=/usr/bin --sbindir=/usr/sbin --includedir=/usr/include --datadir=/usr/share --mandir=/usr/share/man --infodir=/usr/share/info --localedir=/usr/share/locale --sysconfdir=/etc --localstatedir=/var --sharedstatedir=/var/lib --wrap-mode=nodownload --auto-features=enabled -Db_ndebug=true . x86_64-redhat-linux-gnu $OTHER_ARGS thus passing -DNDEBUG to the meson build. Override that.
| * shared: workaround -Wunused-but-set-variable warning with assertionsThomas Haller2019-04-043-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Usually, we don't want to build with NDEBUG (because disabling regular assertions is an untested configuration). Still, when we do, we get compiler warnings. Non-debug builds break with a compiler warning: $ ccache cc -Ishared/a4d2686@@n-acd@sta -Ishared -I../shared -I../shared/c-siphash/src -I../shared/c-list/src -I../shared/c-rbtree/src -fdiagnostics-color=always -DNDEBUG -pipe -D_FILE_OFFSET_BITS=64 -Werror -std=gnu11 -fdata-sections -ffunction-sections -O2 -g -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fPIC -D_GNU_SOURCE -DSO_ATTACH_BPF=50 -std=c11 -Wno-pointer-arith -Wno-vla -MD -MQ 'shared/a4d2686@@n-acd@sta/n-acd_src_n-acd-probe.c.o' -MF 'shared/a4d2686@@n-acd@sta/n-acd_src_n-acd-probe.c.o.d' -o 'shared/a4d2686@@n-acd@sta/n-acd_src_n-acd-probe.c.o' -c ../shared/n-acd/src/n-acd-probe.c ../shared/n-acd/src/n-acd-probe.c: In function 'n_acd_probe_unlink': ../shared/n-acd/src/n-acd-probe.c:209:13: error: variable 'r' set but not used [-Werror=unused-but-set-variable] int r; ^ $ cache cc -Ishared/a4d2686@@c-rbtree@sta -Ishared -I../shared -fdiagnostics-color=always -DNDEBUG -pipe -D_FILE_OFFSET_BITS=64 -Werror -std=gnu11 -fdata-sections -ffunction-sections -O2 -g -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fPIC -std=c11 -MD -MQ 'shared/a4d2686@@c-rbtree@sta/c-rbtree_src_c-rbtree.c.o' -MF 'shared/a4d2686@@c-rbtree@sta/c-rbtree_src_c-rbtree.c.o.d' -o 'shared/a4d2686@@c-rbtree@sta/c-rbtree_src_c-rbtree.c.o' -c ../shared/c-rbtree/src/c-rbtree.c ../shared/c-rbtree/src/c-rbtree.c: In function 'c_rbtree_move': ../shared/c-rbtree/src/c-rbtree.c:456:18: error: variable 't' set but not used [-Werror=unused-but-set-variable] CRBTree *t; ^ https://github.com/nettools/n-acd/pull/6 https://github.com/c-util/c-rbtree/pull/3
| * gitlab-ci: print information about test environment in testsThomas Haller2019-04-041-0/+2
|/ | | | It's just interesting to see in the logs.
* systemd: merge branch systemd into masterThomas Haller2019-04-0462-904/+926
|\
| * systemd: update code from upstream (2019-04-04)Thomas Haller2019-04-0460-978/+1031
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a direct dump from systemd git. ====== SYSTEMD_DIR=../systemd COMMIT=6e79d2b5a414f49c05392cf5f52072c5f081442e ( cd "$SYSTEMD_DIR" git checkout "$COMMIT" git reset --hard git clean -fdx ) git ls-files -z :/src/systemd/src/ \ :/shared/systemd/src/ \ :/shared/nm-utils/unaligned.h | \ xargs -0 rm -f nm_copy_sd_shared() { mkdir -p "./shared/systemd/$(dirname "$1")" cp "$SYSTEMD_DIR/$1" "./shared/systemd/$1" } nm_copy_sd_core() { mkdir -p "./src/systemd/$(dirname "$1")" cp "$SYSTEMD_DIR/$1" "./src/systemd/$1" } nm_copy_sd_nmutils() { mkdir -p "./shared/nm-utils/" cp "$SYSTEMD_DIR/$1" "./shared/nm-utils/${1##*/}" } nm_copy_sd_core "src/libsystemd-network/arp-util.c" nm_copy_sd_core "src/libsystemd-network/arp-util.h" nm_copy_sd_core "src/libsystemd-network/dhcp-identifier.c" nm_copy_sd_core "src/libsystemd-network/dhcp-identifier.h" nm_copy_sd_core "src/libsystemd-network/dhcp-internal.h" nm_copy_sd_core "src/libsystemd-network/dhcp-lease-internal.h" nm_copy_sd_core "src/libsystemd-network/dhcp-network.c" nm_copy_sd_core "src/libsystemd-network/dhcp-option.c" nm_copy_sd_core "src/libsystemd-network/dhcp-packet.c" nm_copy_sd_core "src/libsystemd-network/dhcp-protocol.h" nm_copy_sd_core "src/libsystemd-network/dhcp6-internal.h" nm_copy_sd_core "src/libsystemd-network/dhcp6-lease-internal.h" nm_copy_sd_core "src/libsystemd-network/dhcp6-network.c" nm_copy_sd_core "src/libsystemd-network/dhcp6-option.c" nm_copy_sd_core "src/libsystemd-network/dhcp6-protocol.h" nm_copy_sd_core "src/libsystemd-network/lldp-internal.h" nm_copy_sd_core "src/libsystemd-network/lldp-neighbor.c" nm_copy_sd_core "src/libsystemd-network/lldp-neighbor.h" nm_copy_sd_core "src/libsystemd-network/lldp-network.c" nm_copy_sd_core "src/libsystemd-network/lldp-network.h" nm_copy_sd_core "src/libsystemd-network/network-internal.c" nm_copy_sd_core "src/libsystemd-network/network-internal.h" nm_copy_sd_core "src/libsystemd-network/sd-dhcp-client.c" nm_copy_sd_core "src/libsystemd-network/sd-dhcp-lease.c" nm_copy_sd_core "src/libsystemd-network/sd-dhcp6-client.c" nm_copy_sd_core "src/libsystemd-network/sd-dhcp6-lease.c" nm_copy_sd_core "src/libsystemd-network/sd-ipv4acd.c" nm_copy_sd_core "src/libsystemd-network/sd-ipv4ll.c" nm_copy_sd_core "src/libsystemd-network/sd-lldp.c" nm_copy_sd_core "src/libsystemd/sd-event/event-source.h" nm_copy_sd_core "src/libsystemd/sd-event/event-util.c" nm_copy_sd_core "src/libsystemd/sd-event/event-util.h" nm_copy_sd_core "src/libsystemd/sd-event/sd-event.c" nm_copy_sd_core "src/libsystemd/sd-id128/id128-util.c" nm_copy_sd_core "src/libsystemd/sd-id128/id128-util.h" nm_copy_sd_core "src/libsystemd/sd-id128/sd-id128.c" nm_copy_sd_core "src/shared/dns-domain.c" nm_copy_sd_core "src/shared/dns-domain.h" nm_copy_sd_core "src/systemd/_sd-common.h" nm_copy_sd_core "src/systemd/sd-dhcp-client.h" nm_copy_sd_core "src/systemd/sd-dhcp-lease.h" nm_copy_sd_core "src/systemd/sd-dhcp6-client.h" nm_copy_sd_core "src/systemd/sd-dhcp6-lease.h" nm_copy_sd_core "src/systemd/sd-event.h" nm_copy_sd_core "src/systemd/sd-id128.h" nm_copy_sd_core "src/systemd/sd-ipv4acd.h" nm_copy_sd_core "src/systemd/sd-ipv4ll.h" nm_copy_sd_core "src/systemd/sd-lldp.h" nm_copy_sd_core "src/systemd/sd-ndisc.h" nm_copy_sd_nmutils "src/basic/unaligned.h" nm_copy_sd_shared "src/basic/alloc-util.c" nm_copy_sd_shared "src/basic/alloc-util.h" nm_copy_sd_shared "src/basic/async.h" nm_copy_sd_shared "src/basic/env-file.c" nm_copy_sd_shared "src/basic/env-file.h" nm_copy_sd_shared "src/basic/env-util.c" nm_copy_sd_shared "src/basic/env-util.h" nm_copy_sd_shared "src/basic/errno-util.h" nm_copy_sd_shared "src/basic/escape.c" nm_copy_sd_shared "src/basic/escape.h" nm_copy_sd_shared "src/basic/ether-addr-util.c" nm_copy_sd_shared "src/basic/ether-addr-util.h" nm_copy_sd_shared "src/basic/extract-word.c" nm_copy_sd_shared "src/basic/extract-word.h" nm_copy_sd_shared "src/basic/fd-util.c" nm_copy_sd_shared "src/basic/fd-util.h" nm_copy_sd_shared "src/basic/fileio.c" nm_copy_sd_shared "src/basic/fileio.h" nm_copy_sd_shared "src/basic/fs-util.c" nm_copy_sd_shared "src/basic/fs-util.h" nm_copy_sd_shared "src/basic/hash-funcs.c" nm_copy_sd_shared "src/basic/hash-funcs.h" nm_copy_sd_shared "src/basic/hashmap.c" nm_copy_sd_shared "src/basic/hashmap.h" nm_copy_sd_shared "src/basic/hexdecoct.c" nm_copy_sd_shared "src/basic/hexdecoct.h" nm_copy_sd_shared "src/basic/hostname-util.c" nm_copy_sd_shared "src/basic/hostname-util.h" nm_copy_sd_shared "src/basic/in-addr-util.c" nm_copy_sd_shared "src/basic/in-addr-util.h" nm_copy_sd_shared "src/basic/io-util.c" nm_copy_sd_shared "src/basic/io-util.h" nm_copy_sd_shared "src/basic/list.h" nm_copy_sd_shared "src/basic/log.h" nm_copy_sd_shared "src/basic/macro.h" nm_copy_sd_shared "src/basic/memory-util.c" nm_copy_sd_shared "src/basic/memory-util.h" nm_copy_sd_shared "src/basic/mempool.c" nm_copy_sd_shared "src/basic/mempool.h" nm_copy_sd_shared "src/basic/missing_fcntl.h" nm_copy_sd_shared "src/basic/missing_socket.h" nm_copy_sd_shared "src/basic/missing_stat.h" nm_copy_sd_shared "src/basic/missing_type.h" nm_copy_sd_shared "src/basic/parse-util.c" nm_copy_sd_shared "src/basic/parse-util.h" nm_copy_sd_shared "src/basic/path-util.c" nm_copy_sd_shared "src/basic/path-util.h" nm_copy_sd_shared "src/basic/prioq.c" nm_copy_sd_shared "src/basic/prioq.h" nm_copy_sd_shared "src/basic/process-util.c" nm_copy_sd_shared "src/basic/process-util.h" nm_copy_sd_shared "src/basic/random-util.c" nm_copy_sd_shared "src/basic/random-util.h" nm_copy_sd_shared "src/basic/set.h" nm_copy_sd_shared "src/basic/signal-util.h" nm_copy_sd_shared "src/basic/siphash24.h" nm_copy_sd_shared "src/basic/socket-util.c" nm_copy_sd_shared "src/basic/socket-util.h" nm_copy_sd_shared "src/basic/sort-util.h" nm_copy_sd_shared "src/basic/sparse-endian.h" nm_copy_sd_shared "src/basic/stat-util.c" nm_copy_sd_shared "src/basic/stat-util.h" nm_copy_sd_shared "src/basic/stdio-util.h" nm_copy_sd_shared "src/basic/string-table.c" nm_copy_sd_shared "src/basic/string-table.h" nm_copy_sd_shared "src/basic/string-util.c" nm_copy_sd_shared "src/basic/string-util.h" nm_copy_sd_shared "src/basic/strv.c" nm_copy_sd_shared "src/basic/strv.h" nm_copy_sd_shared "src/basic/time-util.c" nm_copy_sd_shared "src/basic/time-util.h" nm_copy_sd_shared "src/basic/tmpfile-util.c" nm_copy_sd_shared "src/basic/tmpfile-util.h" nm_copy_sd_shared "src/basic/umask-util.h" nm_copy_sd_shared "src/basic/utf8.c" nm_copy_sd_shared "src/basic/utf8.h" nm_copy_sd_shared "src/basic/util.c" nm_copy_sd_shared "src/basic/util.h"
* | cli,wwan: merge partial branch 'lr/gsm-default-apn'Thomas Haller2019-04-032-14/+0
|\ \ | | | | | | | | | | | | | | | | | | Cherry-pick two patches from "lr/gsm-default-apn" and merge them to master early. Related: https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/98
| * | wwan/modem-broadband: no point in insisting on pre-existing GSM settingLubomir Rintel2019-04-031-13/+0
| | | | | | | | | | | | We can just create a default one upon connection completion.
| * | clients: do not require gsm.apnLubomir Rintel2019-04-031-1/+0
|/ / | | | | | | The server doesn't require it either.
* | libnm-core: Remove duplicated wordRafael Fontenelle2019-04-031-4/+4
| | | | | | | | https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/97
* | connectivity/trivial: add code commentThomas Haller2019-04-031-4/+13
| |
* | Coerce connectivity "LIMITED" to "NONE" when device is disconnectedAntonio Larrosa2019-04-031-1/+2
| | | | | | | | | | | | | | | | | | | | If the device is disconnected it can't have any connectivity, so we can set it to NONE instead of LIMITED. https://gitlab.freedesktop.org/NetworkManager/NetworkManager/issues/138 Related: https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/99 https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/100
* | release: bump version to 1.17.2 (development)1.17.2-devLubomir Rintel2019-04-032-2/+2
| |
* | merge: branch lr/agent-hintsLubomir Rintel2019-04-031-16/+29
|\ \ | | | | | | | | | https://github.com/NetworkManager/NetworkManager/pull/328
| * | secret-agent-simple: pass hints to the auth dialogLubomir Rintel2019-04-031-0/+9
| | |
| * | secret-agent-simple: get rid of an extra variableLubomir Rintel2019-04-031-3/+1
| | |
| * | secret-agent-simple: replace a char array with a GPtrArrayLubomir Rintel2019-04-031-13/+19
|/ / | | | | | | This will make it easier to dynamically add more options.
* | Revert "all: goodbye libnm-glib"Lubomir Rintel2019-04-03214-11/+74760
| | | | | | | | | | | | We need this for a little little longer :( This reverts commit 1de8383ad9fdfc8f552117e5d109bdfa7005634b.
* | shared: better implement compat version of explicit_bzero()Thomas Haller2019-04-021-6/+13
| | | | | | | | | | | | | | | | | | | | | | If we don't have explicit_bzero(), try a bit harder and use a volatile pointer. This is also what libsecret's egg_secure_clear() does [1]. However, for us this is less important, because commonly we expect glibc to provide a useable explicit_bzero(). [1] https://gitlab.gnome.org/GNOME/libsecret/blob/b5442654d483e959ac9ecd3a3fb9eebc8d9d8399/egg/egg-secure-memory.c#L1352
* | Update connectivity value on device removalAntonio Larrosa2019-04-021-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a device is removed (like when the user unplugs a usb network device) the device object is removed, so it doesn't emit a notify signal for a change in its connectivity and so, device_connectivity_changed is not called. This means that nobody updates the global connectivity value which is potentially wrong if the device was the one providing network connectivity. Since device_connectivity_changed's first two parameters aren't actually used and are there just for the signal to be able to be connected, I moved the code from device_connectivity_changed to a new update_connectivity_value function that just takes a NMManager parameter and also call it from remove_device. [thaller@redhat.com: fix coding style regarding whitespace] https://gitlab.freedesktop.org/NetworkManager/NetworkManager/issues/141 https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/101
* | po: update Italian (it) translationMilo Casagrande2019-04-021-3677/+3681
| | | | | | | | | | | | | | * Fixed translation errors. * Completed untranslated strings. https://gitlab.freedesktop.org/NetworkManager/NetworkManager/merge_requests/102
* | ifupdown: fix connection iteratorYupeng Chang2019-04-021-1/+1
| | | | | | | | | | | | | | Fixes: 6aa66426a416 ('settings/ifupdown: merge eni_ifaces and connections hashes in plugin') https://gitlab.freedesktop.org/NetworkManager/NetworkManager/issues/145 https://bugzilla.redhat.com/show_bug.cgi?id=1694912
* | clients: only ask secrets for settings that require themBeniamino Galvani2019-04-026-0/+30
| | | | | | | | | | | | | | | | | | | | | | | | When nmcli needs secrets for a connection it asks them for every known setting. nmtui is a bit smarter and asks them only for settings that actually exist in the connection. Make a step further and let clients ask secrets only for setting that exist *and* have any secret property. This decreases the number of D-Bus calls when editing or showing a connection with secrets. https://bugzilla.redhat.com/show_bug.cgi?id=1506536 https://github.com/NetworkManager/NetworkManager/pull/327
* | cli: fix a crash on "nmcli d wifi hotspot"Lubomir Rintel2019-04-021-0/+1
| | | | | | | | | | | | | | | | | | | | Call the correct _finish() function for nm_client_add_and_activate_connection_async(). add_and_activate_cb() somewhat confusingly alternates between two different ones depending on whether info->create is set. Fixes: 35932375272a ('cli: reuse connections in nmcli dev wifi con') https://github.com/NetworkManager/NetworkManager/pull/326
* | libnm-core: fix memory leak in setting testBeniamino Galvani2019-03-311-0/+1
| | | | | | | | Fixes: 7fb23b0a62a0 ('libnm: add NMIPRoutingRule API')
* | build: fix searching dlopen in configureBeniamino Galvani2019-03-311-2/+3
| | | | | | | | | | | | | | | | | | The 4th argument of AC_SEARCH_LIBS is a list of additional libraries, not the name of the variable to hold the result which is always ac_cv_search_$function. Also, we should ignore the result when it is "none required". Fixes: 1f2eeb85d80d ('build: rename $(LIBDL) to $(DL_LIBS) and modify detection')
* | libnm-core: make compiler happyfg/tmpFrancesco Giudici2019-03-291-1/+1
| | | | | | | | | | ../libnm-core/nm-utils.c:6784:30: error: unused variable 'var_unref' [-Werror,-Wunused-variable] gs_unref_variant GVariant *var_unref = vlan_var;
* | libnm-core: drop unused variableFrancesco Giudici2019-03-281-1/+0
| |
* | ovs: don't traverse interface through disconnected when the ovsdb entry is ↵Lubomir Rintel2019-03-281-8/+1
| | | | | | | | | | | | | | | | | | | | removed Go straight to unmanaged. That's what all the other devices do when their backing resources vanish. If the device reached disconnected state, an autoconnect check would try to connect it back, in vain. https://github.com/NetworkManager/NetworkManager/pull/324
* | ovs-interface: dissociate the link on disconnectionLubomir Rintel2019-03-281-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Open vSwitch is the special kid on the block -- it likes to be in charge of the link lifetime and so we shouldn't be. This means that we shouldn't be attempting to remove the link: we'd just (gracefully) fail anyways. More importantly, this also means that we shouldn't care if we see the link go away. Once the device reaches DISCONNECTED state, its configuration is cleaned up and we may already be activating another connection. We shouldn't alter the device state when OpenVSwitch decides to drop the old link. https://bugzilla.redhat.com/show_bug.cgi?id=1543557 https://github.com/NetworkManager/NetworkManager/pull/324
* | settings: keep the added connection alive for a bit longerLubomir Rintel2019-03-281-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes a crash on failed AddAndActivate: $ ip link set eth0 down $ nmcli d conn eth0 Error: Failed to add/activate new connection: Connection 'eth0' is not available on device eth0 because device has no carrier <NetworkManager crashes> #3 0x000055555558b6c5 in _nm_g_return_if_fail_warning #4 0x00005555557008c7 in nm_settings_has_connection #5 0x0000555555700e5f in pk_add_cb #6 0x0000555555726e30 in pk_call_cb #7 0x0000555555726e30 in pk_call_cb #8 0x0000555555726e30 in pk_call_cb #9 0x00005555555aaea8 in _call_id_invoke_callback #10 0x00005555555ab2e8 in _call_on_idle https://github.com/NetworkManager/NetworkManager/pull/325
* | libnm,core: merge branch 'th/routing-rule-pt2'Thomas Haller2019-03-2730-813/+4996
|\ \ | | | | | | | | | https://github.com/NetworkManager/NetworkManager/pull/321