Add following alarm related trace points.
- rte_eal_trace_alarm_set()
- rte_eal_trace_alarm_cancel()
Signed-off-by: Jerin Jacob <jerinj@marvell.com>
Acked-by: David Marchand <david.marchand@redhat.com>
RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_str);
RTE_TRACE_POINT_DEFINE(rte_eal_trace_generic_func);
+RTE_TRACE_POINT_DEFINE(rte_eal_trace_alarm_set);
+RTE_TRACE_POINT_DEFINE(rte_eal_trace_alarm_cancel);
+
RTE_INIT(eal_trace_init)
{
RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_void,
lib.eal.generic.string);
RTE_TRACE_POINT_REGISTER(rte_eal_trace_generic_func,
lib.eal.generic.func);
+
+ RTE_TRACE_POINT_REGISTER(rte_eal_trace_alarm_set,
+ lib.eal.alarm.set);
+ RTE_TRACE_POINT_REGISTER(rte_eal_trace_alarm_cancel,
+ lib.eal.alarm.cancel);
}
#include <rte_errno.h>
#include <rte_interrupts.h>
#include <rte_spinlock.h>
+#include <rte_eal_trace.h>
#include "eal_private.h"
#include "eal_alarm_private.h"
rte_spinlock_unlock(&alarm_list_lk);
+ rte_eal_trace_alarm_set(us, cb_fn, cb_arg, ret);
return ret;
}
rte_spinlock_unlock(&alarm_list_lk);
+ rte_eal_trace_alarm_cancel(cb_fn, cb_arg, count);
return count;
}
extern "C" {
#endif
+#include <rte_alarm.h>
#include <rte_trace_point.h>
/* Generic */
#define RTE_EAL_TRACE_GENERIC_FUNC rte_eal_trace_generic_func(__func__)
+/* Alarm */
+RTE_TRACE_POINT(
+ rte_eal_trace_alarm_set,
+ RTE_TRACE_POINT_ARGS(uint64_t us, rte_eal_alarm_callback cb_fn,
+ void *cb_arg, int rc),
+ rte_trace_point_emit_u64(us);
+ rte_trace_point_emit_ptr(cb_fn);
+ rte_trace_point_emit_ptr(cb_arg);
+ rte_trace_point_emit_int(rc);
+)
+
+RTE_TRACE_POINT(
+ rte_eal_trace_alarm_cancel,
+ RTE_TRACE_POINT_ARGS(rte_eal_alarm_callback cb_fn, void *cb_arg,
+ int count),
+ rte_trace_point_emit_ptr(cb_fn);
+ rte_trace_point_emit_ptr(cb_arg);
+ rte_trace_point_emit_int(count);
+)
+
#ifdef __cplusplus
}
#endif
#include <rte_lcore.h>
#include <rte_errno.h>
#include <rte_spinlock.h>
+#include <rte_eal_trace.h>
+
#include <eal_private.h>
#ifndef TFD_NONBLOCK
}
rte_spinlock_unlock(&alarm_list_lk);
+ rte_eal_trace_alarm_set(us, cb_fn, cb_arg, ret);
return ret;
}
else if (err)
rte_errno = err;
+ rte_eal_trace_alarm_cancel(cb_fn, cb_arg, count);
return count;
}
rte_thread_is_intr;
# added in 20.05
+ __rte_eal_trace_alarm_cancel;
+ __rte_eal_trace_alarm_set;
__rte_eal_trace_generic_double;
__rte_eal_trace_generic_float;
__rte_eal_trace_generic_func;