Skip to content

Commit

Permalink
ptp: increase maximum adjustment of virtual clocks.
Browse files Browse the repository at this point in the history
Increase the maximum frequency offset of virtual clocks to 50% to enable
faster slewing corrections.

This value cannot be represented as scaled ppm when long has 32 bits,
but that is already the case for other drivers, even those that provide
the adjfine() function, i.e. 32-bit applications are expected to check
for the limit.

Signed-off-by: Miroslav Lichvar <[email protected]>
Acked-by: Richard Cochran <[email protected]>
Cc: Yangbo Lu <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
mlichvar authored and davem330 committed Feb 3, 2022
1 parent bfcbb76 commit f77222d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/ptp/ptp_vclock.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,7 @@ static long ptp_vclock_refresh(struct ptp_clock_info *ptp)
static const struct ptp_clock_info ptp_vclock_info = {
.owner = THIS_MODULE,
.name = "ptp virtual clock",
/* The maximum ppb value that long scaled_ppm can support */
.max_adj = 32767999,
.max_adj = 500000000,
.adjfine = ptp_vclock_adjfine,
.adjtime = ptp_vclock_adjtime,
.gettime64 = ptp_vclock_gettime,
Expand Down

0 comments on commit f77222d

Please sign in to comment.