Skip to content

Commit

Permalink
phc: record step on live clocks only. (Fixes #17)
Browse files Browse the repository at this point in the history
  • Loading branch information
abower-amd committed Dec 23, 2024
1 parent 8d64147 commit 8da2e59
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/sfptpd_clock.c
Original file line number Diff line number Diff line change
Expand Up @@ -1095,7 +1095,8 @@ static void clock_record_step(void)
clock_lock();
for (clock = sfptpd_clock_list_head; clock != NULL; clock = clock->next) {
assert(clock->magic == SFPTPD_CLOCK_MAGIC);
if (clock->type != SFPTPD_CLOCK_TYPE_SYSTEM)
if (clock->type != SFPTPD_CLOCK_TYPE_SYSTEM &&
clock->u.nic.phc != NULL)
sfptpd_phc_record_step(clock->u.nic.phc);
}
clock_unlock();
Expand Down

0 comments on commit 8da2e59

Please sign in to comment.