1. 11 Mar, 2016 3 commits
  2. 10 Mar, 2016 14 commits
  3. 09 Mar, 2016 6 commits
    • Beniamino Galvani's avatar
      551c5de1
    • Beniamino Galvani's avatar
    • Thomas Haller's avatar
      systemd: update code from upstream · bccb4e35
      Thomas Haller authored
      This is a direct dump from systemd git on 2016-03-07, git commit
      280d397ab313b647fbd824d1cb58eb8323c74501.
      
      ======
      
      SYSTEMD_DIR=../systemd
      COMMIT=280d397ab313b647fbd824d1cb58eb8323c74501
      
      (
        cd "$SYSTEMD_DIR"
        git checkout "$COMMIT"
        git reset --hard
        git clean -fdx
      )
      
      git ls-files :/src/systemd/src/ | xargs -d '\n' rm -f
      
      nm_copy_sd() {
          mkdir -p "./src/systemd/$(dirname "$1")"
          cp "$SYSTEMD_DIR/$1" "./src/systemd/$1"
      }
      
      nm_copy_sd "src/basic/alloc-util.c"
      nm_copy_sd "src/basic/alloc-util.h"
      nm_copy_sd "src/basic/async.h"
      nm_copy_sd "src/basic/escape.c"
      nm_copy_sd "src/basic/escape.h"
      nm_copy_sd "src/basic/ether-addr-util.c"
      nm_copy_sd "src/basic/ether-addr-util.h"
      nm_copy_sd "src/basic/fileio.c"
      nm_copy_sd "src/basic/fileio.h"
      nm_copy_sd "src/basic/fd-util.c"
      nm_copy_sd "src/basic/fd-util.h"
      nm_copy_sd "src/basic/fs-util.c"
      nm_copy_sd "src/basic/fs-util.h"
      nm_copy_sd "src/basic/hash-funcs.c"
      nm_copy_sd "src/basic/hash-funcs.h"
      nm_copy_sd "src/basic/hashmap.c"
      nm_copy_sd "src/basic/hashmap.h"
      nm_copy_sd "src/basic/hexdecoct.c"
      nm_copy_sd "src/basic/hexdecoct.h"
      nm_copy_sd "src/basic/hostname-util.c"
      nm_copy_sd "src/basic/hostname-util.h"
      nm_copy_sd "src/basic/in-addr-util.c"
      nm_copy_sd "src/basic/in-addr-util.h"
      nm_copy_sd "src/basic/io-util.c"
      nm_copy_sd "src/basic/io-util.h"
      nm_copy_sd "src/basic/list.h"
      nm_copy_sd "src/basic/log.h"
      nm_copy_sd "src/basic/macro.h"
      nm_copy_sd "src/basic/mempool.h"
      nm_copy_sd "src/basic/mempool.c"
      nm_copy_sd "src/basic/parse-util.c"
      nm_copy_sd "src/basic/parse-util.h"
      nm_copy_sd "src/basic/path-util.c"
      nm_copy_sd "src/basic/path-util.h"
      nm_copy_sd "src/basic/prioq.h"
      nm_copy_sd "src/basic/prioq.c"
      nm_copy_sd "src/basic/random-util.c"
      nm_copy_sd "src/basic/random-util.h"
      nm_copy_sd "src/basic/refcnt.h"
      nm_copy_sd "src/basic/set.h"
      nm_copy_sd "src/basic/siphash24.c"
      nm_copy_sd "src/basic/siphash24.h"
      nm_copy_sd "src/basic/socket-util.c"
      nm_copy_sd "src/basic/socket-util.h"
      nm_copy_sd "src/basic/sparse-endian.h"
      nm_copy_sd "src/basic/stdio-util.h"
      nm_copy_sd "src/basic/string-table.c"
      nm_copy_sd "src/basic/string-table.h"
      nm_copy_sd "src/basic/string-util.c"
      nm_copy_sd "src/basic/string-util.h"
      nm_copy_sd "src/basic/strv.c"
      nm_copy_sd "src/basic/strv.h"
      nm_copy_sd "src/basic/time-util.c"
      nm_copy_sd "src/basic/time-util.h"
      nm_copy_sd "src/basic/umask-util.h"
      nm_copy_sd "src/basic/unaligned.h"
      nm_copy_sd "src/basic/utf8.c"
      nm_copy_sd "src/basic/utf8.h"
      nm_copy_sd "src/basic/util.c"
      nm_copy_sd "src/basic/util.h"
      nm_copy_sd "src/libsystemd-network/arp-util.c"
      nm_copy_sd "src/libsystemd-network/arp-util.h"
      nm_copy_sd "src/libsystemd-network/dhcp6-internal.h"
      nm_copy_sd "src/libsystemd-network/dhcp6-lease-internal.h"
      nm_copy_sd "src/libsystemd-network/dhcp6-network.c"
      nm_copy_sd "src/libsystemd-network/dhcp6-option.c"
      nm_copy_sd "src/libsystemd-network/dhcp6-protocol.h"
      nm_copy_sd "src/libsystemd-network/dhcp-identifier.c"
      nm_copy_sd "src/libsystemd-network/dhcp-identifier.h"
      nm_copy_sd "src/libsystemd-network/dhcp-internal.h"
      nm_copy_sd "src/libsystemd-network/dhcp-lease-internal.h"
      nm_copy_sd "src/libsystemd-network/dhcp-network.c"
      nm_copy_sd "src/libsystemd-network/dhcp-option.c"
      nm_copy_sd "src/libsystemd-network/dhcp-packet.c"
      nm_copy_sd "src/libsystemd-network/dhcp-protocol.h"
      nm_copy_sd "src/libsystemd-network/lldp.h"
      nm_copy_sd "src/libsystemd-network/lldp-internal.h"
      nm_copy_sd "src/libsystemd-network/lldp-neighbor.c"
      nm_copy_sd "src/libsystemd-network/lldp-neighbor.h"
      nm_copy_sd "src/libsystemd-network/lldp-network.c"
      nm_copy_sd "src/libsystemd-network/lldp-network.h"
      nm_copy_sd "src/libsystemd-network/network-internal.c"
      nm_copy_sd "src/libsystemd-network/network-internal.h"
      nm_copy_sd "src/libsystemd-network/sd-dhcp6-client.c"
      nm_copy_sd "src/libsystemd-network/sd-dhcp6-lease.c"
      nm_copy_sd "src/libsystemd-network/sd-dhcp-client.c"
      nm_copy_sd "src/libsystemd-network/sd-dhcp-lease.c"
      nm_copy_sd "src/libsystemd-network/sd-ipv4ll.c"
      nm_copy_sd "src/libsystemd-network/sd-ipv4acd.c"
      nm_copy_sd "src/libsystemd-network/sd-lldp.c"
      nm_copy_sd "src/libsystemd/sd-event/sd-event.c"
      nm_copy_sd "src/libsystemd/sd-id128/sd-id128.c"
      nm_copy_sd "src/shared/dns-domain.c"
      nm_copy_sd "src/shared/dns-domain.h"
      nm_copy_sd "src/systemd/_sd-common.h"
      nm_copy_sd "src/systemd/sd-dhcp6-client.h"
      nm_copy_sd "src/systemd/sd-dhcp6-lease.h"
      nm_copy_sd "src/systemd/sd-dhcp-client.h"
      nm_copy_sd "src/systemd/sd-dhcp-lease.h"
      nm_copy_sd "src/systemd/sd-event.h"
      nm_copy_sd "src/systemd/sd-ndisc.h"
      nm_copy_sd "src/systemd/sd-id128.h"
      nm_copy_sd "src/systemd/sd-ipv4acd.h"
      nm_copy_sd "src/systemd/sd-ipv4ll.h"
      nm_copy_sd "src/systemd/sd-lldp.h"
      bccb4e35
    • Thomas Haller's avatar
      build: compile with -Wno-duplicate-decl-specifier · f7941ceb
      Thomas Haller authored
      Duplicated const specifiers are allowed by C99 and can easily
      happen in macros. Also, systemd's interal code will use them.
      
      Disable this warning, it doesn't seem useful.
      f7941ceb
    • Beniamino Galvani's avatar
      man: update version number and dates in manual pages · c885fd55
      Beniamino Galvani authored
      Bump NM version number to 1.2 and add the project name to non-XML
      pages. Also, update the dates to the date of the last non-trivial
      change and update their format to YYYY-MM-DD, as specified by 'man
      man-pages'.
      c885fd55
    • Beniamino Galvani's avatar
      manager: fix assumption of child connections with autoconnect=no · e80fc056
      Beniamino Galvani authored
      During startup, when a link is detected (enp0s25 in the example below)
      we try to create also virtual devices (ipip1) on it through
      system_create_virtual_device(), however this realizes only devices for
      connections which can autoactivate.
      
      To support the assumption of child devices with autoconnect=no, we
      should take in consideration in retry_connections_for_parent_device()
      only connections for which the link does not exist, and let existing
      links be handled by platform_link_added(), which also realizes them.
      
      Reproducer:
       $ nmcli c add type ip-tunnel ifname ipip1 con-name ipip1+ autoconnect no \
                     mode ipip remote 172.25.16.1 dev enp0s25 ip4 1.2.3.4/31
       $ nmcli c up ipip1+
       $ systemctl restart NetworkManager
      
      Result:
       * before: ipip1+ is not assumed, ipip1 is not present in 'nmcli d' output
       * after:  ipip1+ is assumed, ipip1 detected
      e80fc056
  4. 08 Mar, 2016 8 commits
  5. 07 Mar, 2016 6 commits
    • Beniamino Galvani's avatar
      device: don't assert the presence of old vpn configurations · 639f2d4b
      Beniamino Galvani authored
      When a VPN connection is active and the parent device becomes
      unmanaged (due to device removal or system entering sleep), all
      configurations are removed from the interface and the device is taken
      down. After that, the VPN is disconnected and tries to remove the old
      VPN configuration from device, causing the following assertion to
      fail:
      
        _replace_vpn_config_in_list: assertion '!old' failed
      
      Remove the assertion as @old can be missing for valid reasons.
      639f2d4b
    • Thomas Haller's avatar
    • Thomas Haller's avatar
      platform: add network namespace support to platform · c7b38625
      Thomas Haller authored
      Add a new NMPNetns class. This allows creation, deletion and
      switching of network namespaces. The API only offers push/pop
      operations to switch the namespace. This way the API enforces
      the user to always restore the previous namespace.
      
      A NMPlatform instance not only uses the netlink socket, but also
      sysfs, udev, ethtool, mii. Still, a NMPlatform instance lives
      entirely inside one namespace and is not spanning multiple namespaces.
      To properly support network namespaces, the platform instance must
      switch the namespace as necessary, transparent to the caller.
      Udev is only supported in the main namespace.
      
      For now, network namespaces are not actually used and are disabled
      via the NM_PLATFORM_NETNS_SUPPORT argument.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=762408
      c7b38625
    • Thomas Haller's avatar
      platform: don't create udev client if udev isn't used · 1a1c5fb7
      Thomas Haller authored
      Inside container, where we don't use udev we don't receive
      any events from udev client. Thus the client only returns
      devices when iterating it initially, but no events for newly
      added devices that appear later.
      
      Thus, inside containers we don't want to create a udev client
      at all.
      1a1c5fb7
    • Thomas Haller's avatar
      core: move simple utils function from "nm-platform-utils.h" · 6165df78
      Thomas Haller authored
      Most functions defined in "nm-platform-utils.h" perform a lookup
      of link properties, for example via ethtool or sysfs. Those functions
      depend on the system configuration, such as the current network namespace.
      
      Move the simple helper functions away to "nm-core-internal.h", so that
      all remaining functions from "nm-platform-utils.h" are really related to
      somthing that interacts with the system/kernel.
      6165df78
    • Thomas Haller's avatar
      platform: add and use nm_utils_ifname_cpy() helper · 0e90f1ba
      Thomas Haller authored
      Coverity complains rightly about "strncpy (dst, ifname, IFNAMSIZ)"
      because it might leave @dst non-NULL-terminated, in case @ifname
      is too long (which already would be a bug in the first place).
      
      Replace the strcpy() uses by a new helper nm_utils_ifname_cpy()
      that asserts against valid arguments.
      0e90f1ba
  6. 06 Mar, 2016 2 commits
  7. 05 Mar, 2016 1 commit