Update CNI to 1.2.0

Signed-off-by: Aditi <sharmaad@vmware.com>
This commit is contained in:
Aditi
2023-01-23 12:11:18 +00:00
parent 3695f29c3c
commit 7ec75b1207
158 changed files with 6539 additions and 3060 deletions

View File

@@ -11,6 +11,24 @@ type Scope uint8
type NextHopFlag int
const (
RT_FILTER_PROTOCOL uint64 = 1 << (1 + iota)
RT_FILTER_SCOPE
RT_FILTER_TYPE
RT_FILTER_TOS
RT_FILTER_IIF
RT_FILTER_OIF
RT_FILTER_DST
RT_FILTER_SRC
RT_FILTER_GW
RT_FILTER_TABLE
RT_FILTER_HOPLIMIT
RT_FILTER_PRIORITY
RT_FILTER_MARK
RT_FILTER_MASK
RT_FILTER_REALM
)
type Destination interface {
Family() int
Decode([]byte) error
@@ -41,6 +59,7 @@ type Route struct {
MultiPath []*NexthopInfo
Protocol RouteProtocol
Priority int
Family int
Table int
Type int
Tos int
@@ -49,6 +68,7 @@ type Route struct {
NewDst Destination
Encap Encap
Via Destination
Realm int
MTU int
Window int
Rtt int
@@ -94,6 +114,7 @@ func (r Route) String() string {
}
elems = append(elems, fmt.Sprintf("Flags: %s", r.ListFlags()))
elems = append(elems, fmt.Sprintf("Table: %d", r.Table))
elems = append(elems, fmt.Sprintf("Realm: %d", r.Realm))
return fmt.Sprintf("{%s}", strings.Join(elems, " "))
}
@@ -107,6 +128,7 @@ func (r Route) Equal(x Route) bool {
nexthopInfoSlice(r.MultiPath).Equal(x.MultiPath) &&
r.Protocol == x.Protocol &&
r.Priority == x.Priority &&
r.Realm == x.Realm &&
r.Table == x.Table &&
r.Type == x.Type &&
r.Tos == x.Tos &&