aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2010-02-18 00:46:50 -0500
committerDavid S. Miller <davem@davemloft.net>2010-02-18 17:08:38 -0500
commit501c774cb13c3ef8fb7fc5f08fa19473f7d9a0db (patch)
tree65db25ce76a5c038d69c304d9b6456e4f68e9f47 /include/linux
parent02df55d28c6001a3cdb7a997a34a0b01f01d015e (diff)
net/macvtap: add vhost support
This adds support for passing a macvtap file descriptor into vhost-net, much like we already do for tun/tap. Most of the new code is taken from the respective patch in the tun driver and may get consolidated in the future. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Sridhar Samudrala <sri@us.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/if_macvlan.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/linux/if_macvlan.h b/include/linux/if_macvlan.h
index f9cb9ba1475d..b78a712247da 100644
--- a/include/linux/if_macvlan.h
+++ b/include/linux/if_macvlan.h
@@ -7,6 +7,19 @@
7#include <linux/netlink.h> 7#include <linux/netlink.h>
8#include <net/netlink.h> 8#include <net/netlink.h>
9 9
10#if defined(CONFIG_MACVTAP) || defined(CONFIG_MACVTAP_MODULE)
11struct socket *macvtap_get_socket(struct file *);
12#else
13#include <linux/err.h>
14#include <linux/errno.h>
15struct file;
16struct socket;
17static inline struct socket *macvtap_get_socket(struct file *f)
18{
19 return ERR_PTR(-EINVAL);
20}
21#endif /* CONFIG_MACVTAP */
22
10struct macvlan_port; 23struct macvlan_port;
11struct macvtap_queue; 24struct macvtap_queue;
12 25