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

Support SAI_PORT_ATTR_PORT_SERDES_ID on vs gearbox #1082

Merged
merged 1 commit into from
Oct 10, 2022
Merged
Changes from all 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
6 changes: 6 additions & 0 deletions vslib/SwitchBCM81724.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,11 @@ sai_status_t SwitchBCM81724::create_port_dependencies(

CHECK_STATUS(set(SAI_OBJECT_TYPE_PORT, port_id, &attr));

attr.id = SAI_PORT_ATTR_PORT_SERDES_ID;
attr.value.oid = SAI_NULL_OBJECT_ID;

CHECK_STATUS(set(SAI_OBJECT_TYPE_PORT, port_id, &attr));

return SAI_STATUS_SUCCESS;
}

Expand Down Expand Up @@ -273,6 +278,7 @@ sai_status_t SwitchBCM81724::refresh_read_only(
*/

case SAI_PORT_ATTR_OPER_STATUS:
case SAI_PORT_ATTR_PORT_SERDES_ID:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SAI_PORT_ATTR_PORT_SERDES_ID is readonly attribute, and normally it should be recalculated each time is queried but if it's null, then is ok to jus return here

Copy link
Contributor Author

@byu343 byu343 Aug 16, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kcudnik Do I need to fix something here? Other than here, it looks like all checks have been passed.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you are fine

return SAI_STATUS_SUCCESS;
}
}
Expand Down