summaryrefslogtreecommitdiffstats
path: root/src/vnet/devices/virtio/virtio.c
diff options
context:
space:
mode:
authorTom Jones <thj@freebsd.org>2024-01-30 09:06:47 +0000
committerDamjan Marion <dmarion@0xa5.net>2024-02-18 15:58:01 +0000
commit61b4efc4dae3f60265ed2b6d8bdcad84b1c4e1cb (patch)
tree5b5313097aff8fb3680701c83b81063ef8e91259 /src/vnet/devices/virtio/virtio.c
parent6ce1e930e87938d9350da5ed7652cf64fbc82e6d (diff)
vnet: Provide platform specific if_tap headers
Type: improvement Change-Id: Ia5cec0afc7f929491e495bb337493e64f752d75f Signed-off-by: Tom Jones <thj@freebsd.org>
Diffstat (limited to 'src/vnet/devices/virtio/virtio.c')
-rw-r--r--src/vnet/devices/virtio/virtio.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vnet/devices/virtio/virtio.c b/src/vnet/devices/virtio/virtio.c
index 2d393656b39..d2302fa1dc4 100644
--- a/src/vnet/devices/virtio/virtio.c
+++ b/src/vnet/devices/virtio/virtio.c
@@ -19,7 +19,11 @@
#include <sys/stat.h>
#include <fcntl.h>
#include <net/if.h>
+#ifdef __linux__
#include <linux/if_tun.h>
+#elif __FreeBSD__
+#include <net/if_tun.h>
+#endif /* __linux__ */
#include <sys/ioctl.h>
#include <sys/eventfd.h>