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

[syncd] Add workaround for snoop SAI_PORT_ATTR_SPEED #1132

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

kcudnik
Copy link
Collaborator

@kcudnik kcudnik commented Sep 20, 2022

This is workaround. Skip port speed because of broadcom bug, after warm reboot SAI returns different speed then before warm reboot, which causes to generate SET operation on comparison logic and this SET operation fails. There is no SET operation for speed generated by orchagent, since all values are snooped here.

This is workaround.  Skip port speed because of broadcom bug, after warm
reboot SAI returns different speed then before warm reboot, which causes
to generate SET operation on comparison logic and this SET operation
fails.  There is no SET operation for speed generated by orchagent,
since all values are snooped here.
@@ -3044,6 +3044,24 @@ void Syncd::snoopGetResponse(
continue;
}

if (meta->objecttype == SAI_OBJECT_TYPE_PORT &&
Copy link
Contributor

Choose a reason for hiding this comment

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

Should there be a check that this is part of the warmreboot to skip this or we can skip this completely for other boot causes (cold/fastreboot) and not causing issue for those boot cases?

Choose a reason for hiding this comment

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

I believe that the issue was that SAI_PORT_ATTR_SPEED was getting queried on a port with the port in auto negotiation enabled. I suggest that SONIC check the port's configured auto negotiation mode and query the right attribute accordingly i.e., SAI_PORT_ATTR_SPEED or SAI_PORT_ATTR_ADVERTISED_SPEED.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

at this point check is not that easy, there should be no issue with other modes then warmboot

Copy link
Contributor

Choose a reason for hiding this comment

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

@prsunny can you please review this change too? If this is a blanket ignore on SPEED GET for PORT ATTR:

  1. Do you think this should be better handled at portorch level? I mean that's where the call initiates from, so ignoring from the source might be better?
  2. Do you see any concerns on ignoring this GET call for all the flows, and not just warmboot?

Copy link
Contributor

Choose a reason for hiding this comment

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

as mentioned in PR, it a workaround anyways for bcm platform. So fine with placing it here.

Copy link
Contributor

Choose a reason for hiding this comment

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

discussed offline with Vaibhav and think this should preferably be done from orchagent side as suggested in above comments.

@kcudnik kcudnik mentioned this pull request Oct 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants