about summary refs log tree commit diff
path: root/src/core/devices/wwan/nm-modem.c
diff options
context:
space:
mode:
authorSebastien Bacher <seb128@ubuntu.com>2021-07-05 20:35:03 +0200
committerSebastien Bacher <seb128@ubuntu.com>2021-07-05 20:35:03 +0200
commit35779c6675728fa6f0fd0a21cefb904408509c23 (patch)
tree553e7239e0ba182b4f9b29b1e7a9d66a595d08bc /src/core/devices/wwan/nm-modem.c
parentd92aa7f298fe84d4cf686c5ad64b73438e00d377 (diff)
New upstream version 1.32.2
Diffstat (limited to 'src/core/devices/wwan/nm-modem.c')
-rw-r--r--src/core/devices/wwan/nm-modem.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/core/devices/wwan/nm-modem.c b/src/core/devices/wwan/nm-modem.c
index 0d334fa4..15baa677 100644
--- a/src/core/devices/wwan/nm-modem.c
+++ b/src/core/devices/wwan/nm-modem.c
@@ -10,10 +10,11 @@
 
 #include <fcntl.h>
 #include <termios.h>
+#include <linux/if.h>
 #include <linux/rtnetlink.h>
 
-#include "nm-core-internal.h"
-#include "platform/nm-platform.h"
+#include "libnm-core-intern/nm-core-internal.h"
+#include "libnm-platform/nm-platform.h"
 #include "nm-setting-connection.h"
 #include "NetworkManagerUtils.h"
 #include "devices/nm-device-private.h"
@@ -799,8 +800,10 @@ nm_modem_ip4_pre_commit(NMModem *modem, NMDevice *device, NMIP4Config *config)
 
         g_assert(address);
         if (address->plen == 32)
-            nm_platform_link_set_noarp(nm_device_get_platform(device),
-                                       nm_device_get_ip_ifindex(device));
+            nm_platform_link_change_flags(nm_device_get_platform(device),
+                                          nm_device_get_ip_ifindex(device),
+                                          IFF_NOARP,
+                                          TRUE);
     }
 }
 
@@ -1199,7 +1202,7 @@ deactivate_cleanup(NMModem *self, NMDevice *device, gboolean stop_ppp_manager)
 
                 nm_platform_ip_route_flush(platform, AF_UNSPEC, ifindex);
                 nm_platform_ip_address_flush(platform, AF_UNSPEC, ifindex);
-                nm_platform_link_set_down(platform, ifindex);
+                nm_platform_link_change_flags(platform, ifindex, IFF_UP, FALSE);
             }
         }
     }