Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add L3XC support #1602

Merged
merged 9 commits into from
Jan 20, 2020
Merged
Show file tree
Hide file tree
Changes from 6 commits
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
2 changes: 1 addition & 1 deletion plugins/kvscheduler/internal/graph/node_read.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ func (node *nodeR) GetLabel() string {
return node.label
}

// GetKey returns the value associated with the node.
// GetValue returns the value associated with the node.
func (node *nodeR) GetValue() proto.Message {
return node.value
}
Expand Down
2 changes: 1 addition & 1 deletion plugins/netalloc/netalloc_api.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const (
// GWRefAllowed is used when it doesn't matter if reference points to interface
// address or GW address.
GWRefAllowed GwValidityCheck = iota
// GWRefAllowed is used when an IP address reference should point to GW address.
// GWRefRequired is used when an IP address reference should point to GW address.
GWRefRequired
// GwRefUnexpected is used when an IP address reference should not point to GW address.
GwRefUnexpected
Expand Down
6 changes: 3 additions & 3 deletions plugins/vpp/abfplugin/abfidx/abfidx.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,18 @@ package abfidx
import (
"github.com/ligato/cn-infra/idxmap"
"github.com/ligato/cn-infra/logging"
abf "go.ligato.io/vpp-agent/v3/proto/ligato/vpp/abf"

"go.ligato.io/vpp-agent/v3/pkg/idxvpp"
abf "go.ligato.io/vpp-agent/v3/proto/ligato/vpp/abf"
)

// ABFMetadataIndex provides read-only access to mapping between ABF indexes (generated in the ABF plugin)
// and ABF names.
type ABFMetadataIndex interface {
// LookupIdx looks up previously stored item identified by index in the mapping.
// LookupByName looks up previously stored item identified by name in the mapping.
LookupByName(name string) (metadata *ABFMetadata, exists bool)

// LookupName looks up previously stored item identified by name in the mapping.
// LookupByIndex looks up previously stored item identified by index in the mapping.
LookupByIndex(idx uint32) (name string, metadata *ABFMetadata, exists bool)
}

Expand Down
2 changes: 1 addition & 1 deletion plugins/vpp/abfplugin/abfplugin.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

//go:generate descriptor-adapter --descriptor-name ABF --value-type *vpp_abf.ABF --meta-type *abfidx.ABFMetadata --import "abfidx" --import "go.ligato.io/vpp-agent/v3/proto/ligato/vpp/abf" --output-dir "descriptor"
//go:generate descriptor-adapter --descriptor-name ABF --value-type *vpp_abf.ABF --meta-type *abfidx.ABFMetadata --import "go.ligato.io/vpp-agent/v3/plugins/vpp/abfplugin/abfidx" --import "go.ligato.io/vpp-agent/v3/proto/ligato/vpp/abf" --output-dir "descriptor"

package abfplugin

Expand Down
15 changes: 15 additions & 0 deletions plugins/vpp/binapi/vpp1908/l3xc.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
diff --git a/plugins/vpp/binapi/vpp1908/l3xc/l3xc.ba.go b/plugins/vpp/binapi/vpp1908/l3xc/l3xc.ba.go
index 3bdb5510a..191e53c00 100644
--- a/plugins/vpp/binapi/vpp1908/l3xc/l3xc.ba.go
+++ b/plugins/vpp/binapi/vpp1908/l3xc/l3xc.ba.go
@@ -458,8 +458,8 @@ type FibPath struct {
Flags FibPathFlagsf
Proto FibPathNhProto
Nh FibPathNh
- NLabels uint8
- LabelStack []FibMplsLabel `struc:"[16]FibMplsLabel"`
+ NLabels uint8 `struc:"sizeof=LabelStack"` // MANUALLY FIXED, see https://jira.fd.io/browse/VPP-1261
+ LabelStack []FibMplsLabel
}

func (*FibPath) GetTypeName() string {
Loading