From 16e92eb577381633bd6f2a092696c0e4fe689821 Mon Sep 17 00:00:00 2001 From: Wei Liu Date: Tue, 5 Apr 2016 19:59:53 +0100 Subject: [PATCH] libxl: colo: move netlink related stuff to libxl_colo_proxy.c They are only used there, no need to expose them to other parts of libxl. This is necessary to make libxl build on FreeBSD again because FreeBSD doesn't have netlink. Signed-off-by: Wei Liu Acked-by: Ian Jackson --- tools/libxl/libxl_colo.h | 12 ------------ tools/libxl/libxl_colo_proxy.c | 13 +++++++++++++ 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/tools/libxl/libxl_colo.h b/tools/libxl/libxl_colo.h index 4f6a612f53..f0e438eccb 100644 --- a/tools/libxl/libxl_colo.h +++ b/tools/libxl/libxl_colo.h @@ -17,10 +17,6 @@ #define LIBXL_COLO_H #include "libxl_internal.h" -#include - -/* Consistent with the new COLO netlink channel in kernel side */ -#define NETLINK_COLO 28 /* Maximum time(5s) to wait for colo proxy checkpoit */ #define COLO_PROXY_CHECKPOINT_TIMEOUT 5000000 @@ -53,14 +49,6 @@ enum { LIBXL_COLO_RESUMED, }; -enum colo_netlink_op { - COLO_QUERY_CHECKPOINT = (NLMSG_MIN_TYPE + 1), - COLO_CHECKPOINT, - COLO_FAILOVER, - COLO_PROXY_INIT, - COLO_PROXY_RESET, /* UNUSED, will be used for continuous FT */ -}; - struct libxl__colo_device_nic { int devid; const char *vif; diff --git a/tools/libxl/libxl_colo_proxy.c b/tools/libxl/libxl_colo_proxy.c index 991bd0d458..034e76c55c 100644 --- a/tools/libxl/libxl_colo_proxy.c +++ b/tools/libxl/libxl_colo_proxy.c @@ -17,6 +17,19 @@ #include "libxl_internal.h" +#include + +/* Consistent with the new COLO netlink channel in kernel side */ +#define NETLINK_COLO 28 + +enum colo_netlink_op { + COLO_QUERY_CHECKPOINT = (NLMSG_MIN_TYPE + 1), + COLO_CHECKPOINT, + COLO_FAILOVER, + COLO_PROXY_INIT, + COLO_PROXY_RESET, /* UNUSED, will be used for continuous FT */ +}; + /* ========= colo-proxy: helper functions ========== */ static int colo_proxy_send(libxl__colo_proxy_state *cps, uint8_t *buff, -- 2.30.2