+#define ARISTA_TIMESTAMP_64_TAI 0x0010
+#define ARISTA_TIMESTAMP_64_UTC 0x0110
+#define ARISTA_TIMESTAMP_48_TAI 0x0020
+#define ARISTA_TIMESTAMP_48_UTC 0x0120
+
+static const struct tok ts_version_name[] = {
+ { ARISTA_TIMESTAMP_64_TAI, "TAI(64-bit)" },
+ { ARISTA_TIMESTAMP_64_UTC, "UTC(64-bit)" },
+ { ARISTA_TIMESTAMP_48_TAI, "TAI(48-bit)" },
+ { ARISTA_TIMESTAMP_48_UTC, "UTC(48-bit)" },
+ { 0, NULL }
+};
+
+static inline void
+arista_print_date_hms_time(netdissect_options *ndo, uint32_t seconds,
+ uint32_t nanoseconds)
+{
+ time_t ts;
+ struct tm *tm;
+ char buf[BUFSIZE];
+
+ ts = seconds + (nanoseconds / 1000000000);
+ if (NULL == (tm = gmtime(&ts)))
+ ND_PRINT(": gmtime() error");
+ else if (0 == strftime(buf, sizeof(buf), "%Y-%m-%d %H:%M:%S", tm))
+ ND_PRINT(": strftime() error");
+ else
+ ND_PRINT(": %s, %09u ns, ", buf, nanoseconds);
+}