6 #include "virnetdevtap.h"
9 #define VIR_FROM_THIS VIR_FROM_BHYVE
11 void virMacAddrGenerate(const unsigned char prefix
[VIR_MAC_PREFIX_BUFLEN
],
14 addr
->addr
[0] = prefix
[0];
15 addr
->addr
[1] = prefix
[1];
16 addr
->addr
[2] = prefix
[2];
22 int virNetDevTapCreateInBridgePort(const char *brname ATTRIBUTE_UNUSED
,
24 const virMacAddr
*macaddr ATTRIBUTE_UNUSED
,
25 const unsigned char *vmuuid ATTRIBUTE_UNUSED
,
26 const char *tunpath ATTRIBUTE_UNUSED
,
27 int *tapfd ATTRIBUTE_UNUSED
,
28 size_t tapfdSize ATTRIBUTE_UNUSED
,
29 virNetDevVPortProfilePtr virtPortProfile ATTRIBUTE_UNUSED
,
30 virNetDevVlanPtr virtVlan ATTRIBUTE_UNUSED
,
31 virNetDevCoalescePtr coalesce ATTRIBUTE_UNUSED
,
32 unsigned int mtu ATTRIBUTE_UNUSED
,
33 unsigned int *actualMTU ATTRIBUTE_UNUSED
,
34 unsigned int fakeflags ATTRIBUTE_UNUSED
)
37 if (VIR_STRDUP(*ifname
, "vnet0") < 0)
42 char *virNetDevTapGetRealDeviceName(char *name ATTRIBUTE_UNUSED
)
46 if (VIR_STRDUP(fakename
, "faketapdev") < 0)
51 int virNetDevSetOnline(const char *ifname ATTRIBUTE_UNUSED
,
52 bool online ATTRIBUTE_UNUSED
)
57 int bind(int sockfd ATTRIBUTE_UNUSED
,
58 const struct sockaddr
*addr ATTRIBUTE_UNUSED
,
59 socklen_t addrlen ATTRIBUTE_UNUSED
)