mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-04-29 12:14:48 +00:00
qemu: Add MACVTAP support
The networking device structure now supports MACVTAP. Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
This commit is contained in:
parent
6d7dfa04bf
commit
3908185ccd
5
qemu.go
5
qemu.go
@ -319,6 +319,9 @@ type NetDeviceType string
|
|||||||
const (
|
const (
|
||||||
// TAP is a TAP networking device type.
|
// TAP is a TAP networking device type.
|
||||||
TAP NetDeviceType = "tap"
|
TAP NetDeviceType = "tap"
|
||||||
|
|
||||||
|
// MACVTAP is a MAC virtual TAP networking device type.
|
||||||
|
MACVTAP = "macvtap"
|
||||||
)
|
)
|
||||||
|
|
||||||
// NetDevice represents a guest networking device
|
// NetDevice represents a guest networking device
|
||||||
@ -361,6 +364,8 @@ func (netdev NetDevice) Valid() bool {
|
|||||||
switch netdev.Type {
|
switch netdev.Type {
|
||||||
case TAP:
|
case TAP:
|
||||||
return true
|
return true
|
||||||
|
case MACVTAP:
|
||||||
|
return true
|
||||||
default:
|
default:
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user