Skip to content

Feature: PTP Peer-to-Peer (P2P) Path Delay Support - #2324

Open
gurprem-singh wants to merge 1 commit into
opencomputeproject:masterfrom
gurprem-singh:p2p-delay-headers
Open

Feature: PTP Peer-to-Peer (P2P) Path Delay Support#2324
gurprem-singh wants to merge 1 commit into
opencomputeproject:masterfrom
gurprem-singh:p2p-delay-headers

Conversation

@gurprem-singh

Copy link
Copy Markdown

Adds the headers and design specification for the PTP Pdelay configuration object, expanding SAI capabilities to configure localized hardware measurement profiles for link propagation delays.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@gurprem-singh
gurprem-singh force-pushed the p2p-delay-headers branch 2 times, most recently from c9b91ab to 3ff98d8 Compare July 27, 2026 16:16

@kcudnik kcudnik left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

address comments

Comment thread meta/saiserialize.c Outdated
_Out_ char *buffer,
_In_ const sai_ptp_l2_header_t header)
{
return 0;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

missing serialization method

Comment thread meta/saiserialize.c Outdated
_In_ const char *buffer,
_Out_ sai_ptp_l2_header_t header)
{
return 0;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

missing serialization method

Comment thread meta/saiserialize.c Outdated
return (int)(buf - buffer);
}

int sai_serialize_ptp_clock_id(

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

if you are adding serialize and dserialize, then add also unittest for that

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

custom serializer removed. applies to other comments as well.

Comment thread meta/saiserialize.c Outdated
id[n] = (uint8_t)arr[n];
}

return 8;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

it should return "read" variable, number of consumed characters, take a look at sai_deserialize_mac and sai_deserialize_object_id

Comment thread meta/saisanitycheck.c Outdated
CHECK_STRUCT_SIZE(sai_acl_field_data_data_t, 16);
CHECK_STRUCT_SIZE(sai_acl_field_data_mask_t, 16);
CHECK_STRUCT_SIZE(sai_attribute_value_t, 40);
CHECK_STRUCT_SIZE(sai_attribute_value_t, 64);

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

this is breaking (not backward compatible) change as attribute value size is changing

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

fixed to use sai_u8_list_t instead

@gurprem-singh
gurprem-singh force-pushed the p2p-delay-headers branch 3 times, most recently from 2c81938 to 06a3bb1 Compare August 3, 2026 23:10
Adds the headers and design specification for the PTP Pdelay configuration object, expanding SAI capabilities to configure localized hardware measurement profiles for link propagation delays.

This incorporates the v3 struct simplifications, utilizing standard sai_u8_list_t mappings to preserve SAI ABI compatibility.

Signed-off-by: gurprem <gurprem@google.com>
@gurprem-singh

Copy link
Copy Markdown
Author

Thanks for review @kcudnik. Latest patch is updated so both attributes now use the standard sai_u8_list_t instead. This keeps the union at 40 bytes, and since it's a natively-supported type, it no longer needs any custom serialize/deserialize methods or their unit tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants