From: "Steven Rostedt (Google)" <rostedt@xxxxxxxxxxx> Add TRACECMD_TIME_SYNC_ROLE_CLIENT and SERVER to distringuish from guest/host to client/server. Signed-off-by: Steven Rostedt (Google) <rostedt@xxxxxxxxxxx> --- lib/trace-cmd/include/private/trace-cmd-private.h | 2 ++ lib/trace-cmd/trace-timesync-ptp.c | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/trace-cmd/include/private/trace-cmd-private.h b/lib/trace-cmd/include/private/trace-cmd-private.h index f68d17bb8e1d..6e7b346cda07 100644 --- a/lib/trace-cmd/include/private/trace-cmd-private.h +++ b/lib/trace-cmd/include/private/trace-cmd-private.h @@ -480,6 +480,8 @@ enum{ enum tracecmd_time_sync_role { TRACECMD_TIME_SYNC_ROLE_HOST = (1 << 0), TRACECMD_TIME_SYNC_ROLE_GUEST = (1 << 1), + TRACECMD_TIME_SYNC_ROLE_CLIENT = (1 << 2), + TRACECMD_TIME_SYNC_ROLE_SERVER = (1 << 3), }; /* Timestamp synchronization flags */ diff --git a/lib/trace-cmd/trace-timesync-ptp.c b/lib/trace-cmd/trace-timesync-ptp.c index 653d176e2e79..20e6e6f1ab59 100644 --- a/lib/trace-cmd/trace-timesync-ptp.c +++ b/lib/trace-cmd/trace-timesync-ptp.c @@ -702,7 +702,9 @@ int ptp_clock_sync_register(void) { return tracecmd_tsync_proto_register(PTP_NAME, PTP_ACCURACY, TRACECMD_TIME_SYNC_ROLE_GUEST | - TRACECMD_TIME_SYNC_ROLE_HOST, + TRACECMD_TIME_SYNC_ROLE_HOST | + TRACECMD_TIME_SYNC_ROLE_CLIENT | + TRACECMD_TIME_SYNC_ROLE_SERVER, 0, TRACECMD_TSYNC_FLAG_INTERPOLATE, ptp_clock_sync_init, ptp_clock_sync_free, -- 2.35.1