mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 15:23:53 -06:00
tap: support enabling or disabling a queue
This patch introduce a new bit - enabled in TAPState which tracks whether a specific queue/fd is enabled. The tap/fd is enabled during initialization and could be enabled/disabled by tap_enalbe() and tap_disable() which calls platform specific helpers to do the real work. Polling of a tap fd can only done when the tap was enabled. Signed-off-by: Jason Wang <jasowang@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
94fdc6d030
commit
16dbaf905b
3 changed files with 52 additions and 3 deletions
|
@ -35,6 +35,8 @@ int tap_has_vnet_hdr_len(NetClientState *nc, int len);
|
|||
void tap_using_vnet_hdr(NetClientState *nc, bool using_vnet_hdr);
|
||||
void tap_set_offload(NetClientState *nc, int csum, int tso4, int tso6, int ecn, int ufo);
|
||||
void tap_set_vnet_hdr_len(NetClientState *nc, int len);
|
||||
int tap_enable(NetClientState *nc);
|
||||
int tap_disable(NetClientState *nc);
|
||||
|
||||
int tap_get_fd(NetClientState *nc);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue