summaryrefslogtreecommitdiffstats
path: root/include/linux/if_macvlan.h
diff options
context:
space:
mode:
authorJason Wang <jasowang@redhat.com>2013-06-05 23:54:39 +0000
committerDavid S. Miller <davem@davemloft.net>2013-06-07 23:49:09 -0700
commit815f236d622721b54f3963ba59dad98b02cdeabf (patch)
tree1d250c5ea79bb8f5352fb1c0a978352cc9b3a3e1 /include/linux/if_macvlan.h
parent376b1aabe1f53aad80615d05ddb8c43670be6a5c (diff)
downloadblackbird-op-linux-815f236d622721b54f3963ba59dad98b02cdeabf.tar.gz
blackbird-op-linux-815f236d622721b54f3963ba59dad98b02cdeabf.zip
macvtap: add TUNSETQUEUE ioctl
This patch adds TUNSETQUEUE ioctl to let userspace can temporarily disable or enable a queue of macvtap. This is used to be compatible at API layer of tuntap to simplify the userspace to manage the queues. This is done through introducing a linked list to track all taps while using vlan->taps array to only track active taps. Signed-off-by: Jason Wang <jasowang@redhat.com> Acked-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/if_macvlan.h')
-rw-r--r--include/linux/if_macvlan.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/if_macvlan.h b/include/linux/if_macvlan.h
index 62d8bda67874..19121331a5ed 100644
--- a/include/linux/if_macvlan.h
+++ b/include/linux/if_macvlan.h
@@ -69,8 +69,12 @@ struct macvlan_dev {
u16 flags;
int (*receive)(struct sk_buff *skb);
int (*forward)(struct net_device *dev, struct sk_buff *skb);
+ /* This array tracks active taps. */
struct macvtap_queue *taps[MAX_MACVTAP_QUEUES];
+ /* This list tracks all taps (both enabled and disabled) */
+ struct list_head queue_list;
int numvtaps;
+ int numqueues;
int minor;
};
OpenPOWER on IntegriCloud