Skip to content

Commit

Permalink
Revert "add deviation for ETH channal rate class non-supported. Arist…
Browse files Browse the repository at this point in the history
…a device does not support this yet"

This reverts commit b1af1fc.
  • Loading branch information
jianchen-g committed Dec 17, 2024
1 parent 4514b65 commit 0439ee9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 25 deletions.
28 changes: 8 additions & 20 deletions internal/cfgplugins/interface.go
Original file line number Diff line number Diff line change
Expand Up @@ -162,26 +162,14 @@ func ConfigETHChannel(t *testing.T, dut *ondatra.DUTDevice, interfaceName, trans
},
}
}
var channel *oc.TerminalDevice_Channel
if deviations.ChannelRateClassParametersUnsupported(dut) {
channel = &oc.TerminalDevice_Channel{
Description: ygot.String("ETH Logical Channel"),
Index: ygot.Uint32(ethIndex),
LogicalChannelType: oc.TransportTypes_LOGICAL_ELEMENT_PROTOCOL_TYPE_PROT_ETHERNET,
TribProtocol: oc.TransportTypes_TRIBUTARY_PROTOCOL_TYPE_PROT_400GE,
Ingress: ingress,
Assignment: assignment,
}
} else {
channel = &oc.TerminalDevice_Channel{
Description: ygot.String("ETH Logical Channel"),
Index: ygot.Uint32(ethIndex),
LogicalChannelType: oc.TransportTypes_LOGICAL_ELEMENT_PROTOCOL_TYPE_PROT_ETHERNET,
TribProtocol: oc.TransportTypes_TRIBUTARY_PROTOCOL_TYPE_PROT_400GE,
RateClass: oc.TransportTypes_TRIBUTARY_RATE_CLASS_TYPE_TRIB_RATE_400G,
Ingress: ingress,
Assignment: assignment,
}
channel = &oc.TerminalDevice_Channel{
Description: ygot.String("ETH Logical Channel"),
Index: ygot.Uint32(ethIndex),
LogicalChannelType: oc.TransportTypes_LOGICAL_ELEMENT_PROTOCOL_TYPE_PROT_ETHERNET,
TribProtocol: oc.TransportTypes_TRIBUTARY_PROTOCOL_TYPE_PROT_400GE,
RateClass: oc.TransportTypes_TRIBUTARY_RATE_CLASS_TYPE_TRIB_RATE_400G,
Ingress: ingress,
Assignment: assignment,
}
gnmi.Replace(t, dut, gnmi.OC().TerminalDevice().Channel(ethIndex).Config(), channel)
}
5 changes: 0 additions & 5 deletions internal/deviations/deviations.go
Original file line number Diff line number Diff line change
Expand Up @@ -1243,8 +1243,3 @@ func EnableTableConnections(dut *ondatra.DUTDevice) bool {
func NoZeroSuppression(dut *ondatra.DUTDevice) bool {
return lookupDUTDeviations(dut).GetNoZeroSuppression()
}

// ChannelRateClassParametersUnsupported returns true if channel rate class parameters are unsupported
func ChannelRateClassParametersUnsupported(dut *ondatra.DUTDevice) bool {
return lookupDUTDeviations(dut).GetChannelAssignmentRateClassParametersUnsupported()
}

0 comments on commit 0439ee9

Please sign in to comment.