Skip to content

Commit

Permalink
skip unsupported FEC counters on montblanc mgmt ports
Browse files Browse the repository at this point in the history
Summary: Some fboss hw tests are failing due to unsupported counters on montblanc, skip these counters for now, will follow-up with broadcom why they are not supported.

Reviewed By: srikrishnagopu

Differential Revision: D61562423

fbshipit-source-id: 8db320d063457ffc69668c9c193d84122e5b3d9a
  • Loading branch information
daiwei1983 authored and facebook-github-bot committed Aug 21, 2024
1 parent d5ffdda commit c94f807
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions fboss/agent/hw/sai/switch/SaiPortManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1566,11 +1566,25 @@ SaiQueueHandle* SaiPortManager::getQueueHandle(PortID swId, uint8_t queueId)
}

bool SaiPortManager::fecStatsSupported(PortID portId) const {
if (platform_->getAsic()->getAsicType() ==
cfg::AsicType::ASIC_TYPE_TOMAHAWK5 &&
getPortType(portId) == cfg::PortType::MANAGEMENT_PORT) {
// TODO(daiweix): follow up why not supported on TH5 mgmt port, e.g.
// SAI_PORT_STAT_IF_IN_FEC_CORRECTABLE_FRAMES
return false;
}
return platform_->getAsic()->isSupported(HwAsic::Feature::SAI_FEC_COUNTERS) &&
utility::isReedSolomonFec(getFECMode(portId));
}

bool SaiPortManager::fecCorrectedBitsSupported(PortID portId) const {
if (platform_->getAsic()->getAsicType() ==
cfg::AsicType::ASIC_TYPE_TOMAHAWK5 &&
getPortType(portId) == cfg::PortType::MANAGEMENT_PORT) {
// TODO(daiweix): follow up why not supported on TH5 mgmt port, e.g.
// SAI_PORT_STAT_IF_IN_FEC_CORRECTED_BITS
return false;
}
if (platform_->getAsic()->isSupported(
HwAsic::Feature::SAI_FEC_CORRECTED_BITS) &&
utility::isReedSolomonFec(getFECMode(portId))) {
Expand Down

0 comments on commit c94f807

Please sign in to comment.