Skip to content

Commit

Permalink
Convert call sites to the proper method for testing time stamping modes.
Browse files Browse the repository at this point in the history
Signed-off-by: Richard Cochran <richardcochran@gmail.com>
Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
  • Loading branch information
richardcochran committed Mar 4, 2020
1 parent 720c9fa commit 21141a4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion clock.c
Original file line number Diff line number Diff line change
Expand Up @@ -957,7 +957,7 @@ struct clock *clock_create(enum clock_type type, struct config *config,
interface_ensure_tslabel(iface);
interface_get_tsinfo(iface);
if (interface_tsinfo_valid(iface) &&
((iface->ts_info.so_timestamping & required_modes) != required_modes)) {
!interface_tsmodes_supported(iface, required_modes)) {
pr_err("interface '%s' does not support requested timestamping mode",
interface_name(iface));
return NULL;
Expand Down
2 changes: 1 addition & 1 deletion port.c
Original file line number Diff line number Diff line change
Expand Up @@ -2514,7 +2514,7 @@ void port_link_status(void *ctx, int linkup, int ts_index)
if (interface_tsinfo_valid(p->iface) &&
interface_phc_index(p->iface) >= 0) {
required_modes = clock_required_modes(p->clock);
if ((p->iface->ts_info.so_timestamping & required_modes) != required_modes) {
if (!interface_tsmodes_supported(p->iface, required_modes)) {
pr_err("interface '%s' does not support requested "
"timestamping mode, set link status down by force.",
interface_label(p->iface));
Expand Down

0 comments on commit 21141a4

Please sign in to comment.