Import from old repository commit 61ef2b42a9c4ba8e1600f15bb0236765edc2ad45.
[cascardo/ovs.git] / datapath / dp_dev.h
1 #ifndef DP_DEV_H
2 #define DP_DEV_H 1
3
4 struct dp_dev {
5         struct datapath *dp;
6         int port_no;
7
8         struct net_device *dev;
9         struct net_device_stats stats;
10         struct sk_buff_head xmit_queue;
11         struct work_struct xmit_work;
12
13         struct list_head list;
14 };
15
16 static inline struct dp_dev *dp_dev_priv(struct net_device *netdev)
17 {
18         return netdev_priv(netdev);
19 }
20
21 struct net_device *dp_dev_create(struct datapath *, const char *, int port_no);
22 void dp_dev_destroy(struct net_device *);
23 int dp_dev_recv(struct net_device *, struct sk_buff *);
24 int is_dp_dev(struct net_device *);
25 struct datapath *dp_dev_get_dp(struct net_device *);
26
27 #endif /* dp_dev.h */