Skip to content

Commit

Permalink
- virtualization-controller: remove Macvtap support.
Browse files Browse the repository at this point in the history
Signed-off-by: Ivan Mikheykin <[email protected]>
  • Loading branch information
diafour committed Sep 19, 2024
1 parent c0f7cec commit f3dd568
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ type KVVMOptions struct {
OsType virtv2.OsType

// These options are for local development mode
ForceBridgeNetworkBinding bool
DisableHypervSyNIC bool
DisableHypervSyNIC bool
}

type KVVM struct {
Expand Down Expand Up @@ -494,11 +493,7 @@ func (b *KVVM) SetNetworkInterface(name string) {
Name: name,
Model: devPreset.InterfaceModel,
}
if b.opts.ForceBridgeNetworkBinding {
iface.InterfaceBindingMethod.Bridge = &virtv1.InterfaceBridge{}
} else {
iface.InterfaceBindingMethod.Macvtap = &virtv1.InterfaceMacvtap{}
}
iface.InterfaceBindingMethod.Bridge = &virtv1.InterfaceBridge{}
b.Resource.Spec.Template.Spec.Domain.Devices.Interfaces = util.SetArrayElem(
b.Resource.Spec.Template.Spec.Domain.Devices.Interfaces, iface,
func(v1, v2 virtv1.Interface) bool {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -323,10 +323,9 @@ func (h *SyncKvvmHandler) makeKVVMFromVMSpec(ctx context.Context, s state.Virtua
kvvmName := common.NamespacedName(current)

kvvmOpts := kvbuilder.KVVMOptions{
EnableParavirtualization: current.Spec.EnableParavirtualization,
OsType: current.Spec.OsType,
ForceBridgeNetworkBinding: os.Getenv("FORCE_BRIDGE_NETWORK_BINDING") == "1",
DisableHypervSyNIC: os.Getenv("DISABLE_HYPERV_SYNIC") == "1",
EnableParavirtualization: current.Spec.EnableParavirtualization,
OsType: current.Spec.OsType,
DisableHypervSyNIC: os.Getenv("DISABLE_HYPERV_SYNIC") == "1",
}

kvvm, err := s.KVVM(ctx)
Expand Down

0 comments on commit f3dd568

Please sign in to comment.