Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions cns/types/infiniband/status.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package infiniband

type Status int

const (
Available Status = 0
ProgrammingPending Status = 1
ProgrammingFailed Status = 2
ProgrammingComplete Status = 3
ReleasePending Status = 4
)
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
package v1alpha1

import (
"net"

"github.com/Azure/azure-container-networking/cns/types/infiniband"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)

Expand Down Expand Up @@ -45,6 +48,9 @@ type MultitenantPodNetworkConfigSpec struct {
PodNetwork string `json:"podNetwork"`
// name of the requesting cx pod
PodName string `json:"podName,omitempty"`
// list of IB MACs to use for a pod
// +kubebuilder:validation:Optional
IBMACs []net.HardwareAddr `json:"IBMACs,omitempty"`
}

type InterfaceInfo struct {
Expand All @@ -66,6 +72,9 @@ type InterfaceInfo struct {
// AccelnetEnabled determines if the CNI will provision the NIC with accelerated networking enabled
// +kubebuilder:validation:Optional
AccelnetEnabled bool `json:"accelnetEnabled,omitempty"`
// IBStatus is the programming status of the infiniband device
// +kubebuilder:validation:Optional
IBStatus infiniband.Status `json:"ibStatus,omitempty"`
}

// MultitenantPodNetworkConfigStatus defines the observed state of PodNetworkConfig
Expand Down
14 changes: 13 additions & 1 deletion crd/multitenancy/api/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,13 @@ spec:
description: MultitenantPodNetworkConfigSpec defines the desired state
of PodNetworkConfig
properties:
IBMACs:
description: list of IB MACs to use for a pod
items:
description: A HardwareAddr represents a physical hardware address.
format: byte
type: string
type: array
podName:
description: name of the requesting cx pod
type: string
Expand Down Expand Up @@ -98,6 +105,10 @@ spec:
gatewayIP:
description: GatewayIP is the gateway ip of the injected subnet
type: string
ibStatus:
description: IBStatus is the programming status of the infiniband
device
type: integer
macAddress:
description: MacAddress is the MAC Address of the VM's NIC which
this network container was created for
Expand Down
Loading