-
Notifications
You must be signed in to change notification settings - Fork 20
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
Added configurable minor version number. #546
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #546 +/- ##
==========================================
+ Coverage 62.20% 62.46% +0.26%
==========================================
Files 63 63
Lines 8225 8288 +63
==========================================
+ Hits 5116 5177 +61
- Misses 3109 3111 +2 ☔ View full report in Codecov by Sentry. |
// Notes: | ||
// Fields specific for delay mechanism are kept as part of [DelayMechanism]. | ||
// Version is always 2.1, so not stored (versionNumber, minorVersionNumber) | ||
// Major version is always 2.1, so not stored (versionNumber) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// Major version is always 2.1, so not stored (versionNumber) | |
// Major version is always 2, so not stored (versionNumber) |
@@ -64,6 +64,8 @@ pub struct PortConfig { | |||
pub delay_mechanism: DelayType, | |||
#[serde(default = "default_delay_interval")] | |||
pub delay_interval: i8, | |||
#[serde(default = "default_minor_ptp_version")] | |||
pub minor_ptp_version: u8, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess this technically right now allows you to specify version 2.255, which feels like something we really shouldn't allow. Maybe use an enum MinorVersion { Zero, One }
with a From<MinorVersion> for u8
, TryFrom<u8> for MinorVersion
and equivalent serde implementations?
No description provided.