mctpd: accept set endpoint ID as endpoint#96
Merged
jk-ozlabs merged 2 commits intoCodeConstruct:mainfrom Aug 11, 2025
Merged
Conversation
521f10c to
e6c85c3
Compare
jk-ozlabs
reviewed
Jul 31, 2025
Member
jk-ozlabs
left a comment
There was a problem hiding this comment.
mostly looks good! just a few comments / queries inline.
Preparing the values and letting the caller OR multiple fields together should be preferred over assigning to their arguments. Signed-off-by: Khang D Nguyen <khangng@os.amperecomputing.com>
e6c85c3 to
45707fa
Compare
Currently, mctpd handles Set EID message as a bus owner, which means it assumes it has at least one local EID and rejects all Set Endpoint ID requests. This commit handles the case where mctpd runs on an endpoint and it has no EID set yet. Signed-off-by: Khang D Nguyen <khangng@os.amperecomputing.com>
45707fa to
8b906b4
Compare
Contributor
Author
|
Sorry for the update, just missing one more |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change takes a little long for me to push out, mainly because I am not sure how the specification interacts with our MCTP in-kernel infrastructure, where a single EID address can be assigned on multiple interfaces.
I think I mostly know how this maps to the spec now. The spec suggests:
This PR address the endpoint case, where it will accept the EID from every interfaces it is connected to.
Also, this PR also fixes the response for Bus Owner. Instead of rejecting with
0b01 EID assignment rejected, this PR rejects withMCTP_CTRL_CC_ERROR_UNSUPPORTED_CMD. Rejecting EID assignment is reserved for the case where a bridge is rejecting subsequent EID assignments from other bus owners it is connected to.