diff options
author | Lubomir Rintel <lkundrak@v3.sk> | 2018-08-15 18:27:06 +0200 |
---|---|---|
committer | Lubomir Rintel <lkundrak@v3.sk> | 2018-08-15 18:29:53 +0200 |
commit | dad52e623a54cedc711fe057d6ec76980d62285a (patch) | |
tree | 7308a5b2a5ce3479a3470c5f9a3a3d1c8f9368ce | |
parent | e96851673bf23098f004b26f390a6a2dbcdddebc (diff) | |
download | NetworkManager-lr/no-inet6-log.tar.gz |
platform: if AF_INET6 is not available, don't warnlr/no-inet6-log
These should be logged on DEBUG level:
<warn> platform-linux: do-change-link[2]: failure changing link: failure 97 (Address family not supported by protocol)
<warn> device (wlo1): failed to enable userspace IPv6LL address handling (unspecified)
https://gitlab.freedesktop.org/NetworkManager/NetworkManager/issues/10
-rw-r--r-- | src/devices/nm-device.c | 3 | ||||
-rw-r--r-- | src/platform/nm-linux-platform.c | 3 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c index 0427039b8b..81cd57bd2e 100644 --- a/src/devices/nm-device.c +++ b/src/devices/nm-device.c @@ -9345,7 +9345,8 @@ set_nm_ipv6ll (NMDevice *self, gboolean enable) _LOGD (LOGD_IP6, "will %s userland IPv6LL", detail); plerr = nm_platform_link_set_user_ipv6ll_enabled (nm_device_get_platform (self), ifindex, enable); if (plerr != NM_PLATFORM_ERROR_SUCCESS) { - _NMLOG (plerr == NM_PLATFORM_ERROR_NOT_FOUND ? LOGL_DEBUG : LOGL_WARN, + _NMLOG (( plerr == NM_PLATFORM_ERROR_NOT_FOUND + || plerr == NM_PLATFORM_ERROR_OPNOTSUPP) ? LOGL_DEBUG : LOGL_WARN, LOGD_IP6, "failed to %s userspace IPv6LL address handling (%s)", detail, diff --git a/src/platform/nm-linux-platform.c b/src/platform/nm-linux-platform.c index fd0210bb0d..a960f41ef1 100644 --- a/src/platform/nm-linux-platform.c +++ b/src/platform/nm-linux-platform.c @@ -5195,6 +5195,9 @@ retry: } else if (NM_IN_SET (-((int) seq_result), ENODEV)) { log_level = LOGL_DEBUG; result = NM_PLATFORM_ERROR_NOT_FOUND; + } else if (-((int) seq_result) == EAFNOSUPPORT) { + log_level = LOGL_DEBUG; + result = NM_PLATFORM_ERROR_OPNOTSUPP; } else { log_level = LOGL_WARN; result = NM_PLATFORM_ERROR_UNSPECIFIED; |