summary refs log tree commit diff
path: root/src/core/ndisc
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/ndisc')
-rw-r--r--src/core/ndisc/nm-lndp-ndisc.c24
-rw-r--r--src/core/ndisc/nm-ndisc.c8
-rw-r--r--src/core/ndisc/nm-ndisc.h14
-rw-r--r--src/core/ndisc/tests/test-ndisc-linux.c2
4 files changed, 24 insertions, 24 deletions
diff --git a/src/core/ndisc/nm-lndp-ndisc.c b/src/core/ndisc/nm-lndp-ndisc.c
index f773478f..f11178f8 100644
--- a/src/core/ndisc/nm-lndp-ndisc.c
+++ b/src/core/ndisc/nm-lndp-ndisc.c
@@ -13,12 +13,12 @@
 #include <stdarg.h>
 #include <ndp.h>
 
-#include "nm-glib-aux/nm-str-buf.h"
-#include "systemd/nm-sd-utils-shared.h"
+#include "libnm-glib-aux/nm-str-buf.h"
+#include "libnm-systemd-shared/nm-sd-utils-shared.h"
 #include "nm-ndisc-private.h"
 #include "NetworkManagerUtils.h"
-#include "platform/nm-platform.h"
-#include "nm-platform/nmp-netns.h"
+#include "libnm-platform/nm-platform.h"
+#include "libnm-platform/nmp-netns.h"
 
 #define _NMLOG_PREFIX_NAME "ndisc-lndp"
 
@@ -85,14 +85,14 @@ send_rs(NMNDisc *ndisc, GError **error)
 static NMIcmpv6RouterPref
 _route_preference_coerce(enum ndp_route_preference pref)
 {
-#define _ASSERT_ENUM(v1, v2)                                      \
-    G_STMT_START                                                  \
-    {                                                             \
-        G_STATIC_ASSERT((NMIcmpv6RouterPref)(v1) == (v2));        \
-        G_STATIC_ASSERT((enum ndp_route_preference)(v2) == (v1)); \
-        G_STATIC_ASSERT((gint64)(v1) == (v2));                    \
-        G_STATIC_ASSERT((gint64)(v2) == (v1));                    \
-    }                                                             \
+#define _ASSERT_ENUM(v1, v2)                                       \
+    G_STMT_START                                                   \
+    {                                                              \
+        G_STATIC_ASSERT((NMIcmpv6RouterPref) (v1) == (v2));        \
+        G_STATIC_ASSERT((enum ndp_route_preference) (v2) == (v1)); \
+        G_STATIC_ASSERT((gint64) (v1) == (v2));                    \
+        G_STATIC_ASSERT((gint64) (v2) == (v1));                    \
+    }                                                              \
     G_STMT_END
 
     switch (pref) {
diff --git a/src/core/ndisc/nm-ndisc.c b/src/core/ndisc/nm-ndisc.c
index a5c1b935..cf1b58ec 100644
--- a/src/core/ndisc/nm-ndisc.c
+++ b/src/core/ndisc/nm-ndisc.c
@@ -14,8 +14,8 @@
 
 #include "nm-ndisc-private.h"
 #include "nm-utils.h"
-#include "platform/nm-platform.h"
-#include "nm-platform/nmp-netns.h"
+#include "libnm-platform/nm-platform.h"
+#include "libnm-platform/nmp-netns.h"
 #include "nm-l3-config-data.h"
 
 #define _NMLOG_PREFIX_NAME "ndisc"
@@ -806,7 +806,7 @@ solicit_retransmit_time_jitter(gint32 solicit_retransmit_time_msec)
     ten_percent = NM_MAX(1, solicit_retransmit_time_msec / 10);
 
     return solicit_retransmit_time_msec - ten_percent
-           + ((gint32)(g_random_int() % (2u * ((guint32) ten_percent))));
+           + ((gint32) (g_random_int() % (2u * ((guint32) ten_percent))));
 }
 
 static gboolean
@@ -882,7 +882,7 @@ solicit_timer_start(NMNDisc *ndisc)
      * a suitable delay in 2021. Wait only up to 250 msec instead. */
 
     delay_msec =
-        g_random_int() % ((guint32)(NM_NDISC_RFC4861_MAX_RTR_SOLICITATION_DELAY * 1000 / 4));
+        g_random_int() % ((guint32) (NM_NDISC_RFC4861_MAX_RTR_SOLICITATION_DELAY * 1000 / 4));
 
     _LOGD("solicit: schedule sending first solicitation (of %d) in %.3f seconds",
           priv->router_solicitations,
diff --git a/src/core/ndisc/nm-ndisc.h b/src/core/ndisc/nm-ndisc.h
index 93aee4db..15f95d20 100644
--- a/src/core/ndisc/nm-ndisc.h
+++ b/src/core/ndisc/nm-ndisc.h
@@ -13,8 +13,8 @@
 #include "nm-setting-ip6-config.h"
 #include "NetworkManagerUtils.h"
 
-#include "platform/nm-platform.h"
-#include "platform/nmp-object.h"
+#include "libnm-platform/nm-platform.h"
+#include "libnm-platform/nmp-object.h"
 
 #define NM_RA_TIMEOUT_DEFAULT  ((guint32) 0)
 #define NM_RA_TIMEOUT_INFINITY ((guint32) G_MAXINT32)
@@ -99,7 +99,7 @@ _nm_ndisc_lifetime_from_expiry(gint64 now_msec, gint64 expiry_msec, gboolean cei
         diff += 999;
     }
 
-    return NM_MIN(diff / 1000, (gint64)(G_MAXUINT32 - 1));
+    return NM_MIN(diff / 1000, (gint64) (G_MAXUINT32 - 1));
 }
 
 /*****************************************************************************/
@@ -159,10 +159,10 @@ typedef enum {
 #define NM_NDISC_RFC4861_MAX_RTR_SOLICITATION_DELAY 1 /* seconds */
 
 #define NM_NDISC_MAX_ADDRESSES_DEFAULT          16
-#define NM_NDISC_ROUTER_SOLICITATIONS_DEFAULT   3 /* RFC4861, MAX_RTR_SOLICITATIONS */
-#define NM_NDISC_ROUTER_ADVERTISEMENTS_DEFAULT  3 /* RFC4861, MAX_INITIAL_RTR_ADVERTISEMENTS */
-#define NM_NDISC_ROUTER_ADVERT_DELAY            3 /* RFC4861, MIN_DELAY_BETWEEN_RAS */
-#define NM_NDISC_ROUTER_ADVERT_INITIAL_INTERVAL 16 /* RFC4861, MAX_INITIAL_RTR_ADVERT_INTERVAL */
+#define NM_NDISC_ROUTER_SOLICITATIONS_DEFAULT   3   /* RFC4861, MAX_RTR_SOLICITATIONS */
+#define NM_NDISC_ROUTER_ADVERTISEMENTS_DEFAULT  3   /* RFC4861, MAX_INITIAL_RTR_ADVERTISEMENTS */
+#define NM_NDISC_ROUTER_ADVERT_DELAY            3   /* RFC4861, MIN_DELAY_BETWEEN_RAS */
+#define NM_NDISC_ROUTER_ADVERT_INITIAL_INTERVAL 16  /* RFC4861, MAX_INITIAL_RTR_ADVERT_INTERVAL */
 #define NM_NDISC_ROUTER_ADVERT_DELAY_MS         500 /* RFC4861, MAX_RA_DELAY_TIME */
 #define NM_NDISC_ROUTER_ADVERT_MAX_INTERVAL     600 /* RFC4861, MaxRtrAdvInterval default */
 #define NM_NDISC_ROUTER_LIFETIME                900 /* 1.5 * NM_NDISC_ROUTER_ADVERT_MAX_INTERVAL */
diff --git a/src/core/ndisc/tests/test-ndisc-linux.c b/src/core/ndisc/tests/test-ndisc-linux.c
index 9a5df60b..c84ee142 100644
--- a/src/core/ndisc/tests/test-ndisc-linux.c
+++ b/src/core/ndisc/tests/test-ndisc-linux.c
@@ -10,7 +10,7 @@
 #include "ndisc/nm-ndisc.h"
 #include "ndisc/nm-lndp-ndisc.h"
 
-#include "platform/nm-linux-platform.h"
+#include "libnm-platform/nm-linux-platform.h"
 
 #include "nm-test-utils-core.h"