-
Notifications
You must be signed in to change notification settings - Fork 604
API/UCP/UCT: Add per-endpoint traffic class #11805
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -788,6 +788,23 @@ typedef struct ucp_ep_params { | |
| */ | ||
| ucs_sock_addr_t local_sockaddr; | ||
|
|
||
| /** | ||
| * Traffic class for this endpoint, as a full 8-bit Type of Service value: | ||
| * a 6-bit Differentiated Services Code Point (DSCP) followed by 2 ECN | ||
| * bits. On InfiniBand it is used as the GRH Traffic Class; on RoCEv2 its | ||
| * upper 6 bits are used as the DSCP field of the IP header. It overrides | ||
| * the transport's default traffic class for this endpoint only, using the | ||
| * same format. | ||
| * | ||
| * Currently implemented by the RC transport over mlx5 devices with DEVX | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The new field and mask bit have no consumer in this PR — no transport reads There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Misleading "Currently implemented by the RC transport over mlx5 devices with DEVX enabled..." wording. No code reads |
||
| * enabled, including the GGA and GDAKI transports which are based on it. | ||
| * Transports which do not support it, such as DC, ignore this value and | ||
| * keep using their default traffic class. | ||
| * | ||
| * This setting is optional. To enable it, the corresponding @ref | ||
| * UCP_EP_PARAM_FIELD_TRAFFIC_CLASS bit in the field mask must be set. | ||
| */ | ||
| uint8_t traffic_class; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This API change is tricky. We are trying to expose transport specific (TL) concept into UCP and we end up calling out explicitly RC/IB/ROCE. Would it make sense to define HIGH/LOW/etc. level and underneath implement relevant mapping ?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @shamisp You're right, and I checked with Feroz Zahid on the QoS side — he says the same thing: DSCP is not what an application should be setting. So I'll rework the UCP side. Proposed direction:
One design question before I code it: should UCP resolve the level into a traffic class — with the transport publishing its mapping through the iface attributes — or should the level be passed down to UCT and resolved there? The first keeps the UCT API exactly as you approved it; the second puts the mapping where the fabric config already lives. Also @shasson5 what do you think ?
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You have two options in general:
If we anticipate protocols orchestrating various priorities, I think (1) is correct path. If protocols are not expected to operate on QoS level, then (2) better choice.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. in our case protocols are not expected to deal with QoS (no special lanes/transport/protocols selection), so option 2 is the correct approach.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think also option 2 it's the correct approach
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Move it to Ep creation instead of EP connect ? probably. Can single EP support multiple QoS levels ? This is a scalability question. Creating extra UCT EP and management those is not free.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @ybenvidia do you have a requirement/design document that describes the specific use case/scenario that we need to support? |
||
| } ucp_ep_params_t; | ||
|
|
||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -374,7 +374,10 @@ typedef enum { | |
| UCT_EP_CONNECT_TO_EP_PARAM_FIELD_DEVICE_ADDR_LENGTH = UCS_BIT(0), | ||
|
|
||
| /** Endpoint address length */ | ||
| UCT_EP_CONNECT_TO_EP_PARAM_FIELD_EP_ADDR_LENGTH = UCS_BIT(1) | ||
| UCT_EP_CONNECT_TO_EP_PARAM_FIELD_EP_ADDR_LENGTH = UCS_BIT(1), | ||
|
|
||
| /** Traffic class */ | ||
| UCT_EP_CONNECT_TO_EP_PARAM_FIELD_TRAFFIC_CLASS = UCS_BIT(2) | ||
| } uct_ep_connect_to_ep_param_field_t; | ||
|
|
||
|
|
||
|
|
@@ -729,6 +732,25 @@ typedef struct uct_ep_connect_to_ep_params { | |
| * default minimal length according to the address buffer contents. | ||
| */ | ||
| size_t ep_addr_length; | ||
|
|
||
| /** | ||
| * Traffic class for this endpoint, as a full 8-bit Type of Service value: | ||
| * a 6-bit Differentiated Services Code Point (DSCP) followed by 2 ECN | ||
| * bits. On InfiniBand it is used as the GRH Traffic Class; on RoCEv2 its | ||
| * upper 6 bits are used as the DSCP field of the IP header. It overrides | ||
| * the interface's default traffic class for this endpoint only, using the | ||
| * same format. | ||
| * | ||
| * Currently implemented by the RC transport over mlx5 devices with DEVX | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The new field and mask bit have no consumer in this PR — no transport reads There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Misleading "Currently implemented by the RC transport over mlx5 devices with DEVX enabled..." wording. No code reads |
||
| * enabled, including the GGA and GDAKI transports which are based on it. | ||
| * Transports which do not support it, such as DC, ignore this value and | ||
| * keep using their default traffic class. | ||
| * | ||
| * This setting is optional. To enable it, the corresponding @ref | ||
| * UCT_EP_CONNECT_TO_EP_PARAM_FIELD_TRAFFIC_CLASS bit in the field mask | ||
| * must be set. | ||
| */ | ||
| uint8_t traffic_class; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. On UCT this makes much more sense but for UCP as I mentioned earlier it is not a good abstraction. |
||
| } uct_ep_connect_to_ep_params_t; | ||
|
|
||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.