summaryrefslogtreecommitdiffstats
path: root/zebra
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@nvidia.com>2021-10-06 14:49:58 +0200
committerDonald Sharp <sharpd@nvidia.com>2022-04-20 15:43:47 +0200
commit1d80c20919dff2a0abbb0087b3cca957587406d5 (patch)
tree453bbf569ee849bfc86419be682658ba3f5391ef /zebra
parentzebra: Add netlink_request_intf_addr tracepoint (diff)
downloadfrr-1d80c20919dff2a0abbb0087b3cca957587406d5.tar.xz
frr-1d80c20919dff2a0abbb0087b3cca957587406d5.zip
zebra: Add netlink_nexthop_change tracepoint
Add a tracepoint for the netlink_nexthop_change function. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'zebra')
-rw-r--r--zebra/rt_netlink.c3
-rw-r--r--zebra/zebra_trace.h14
2 files changed, 17 insertions, 0 deletions
diff --git a/zebra/rt_netlink.c b/zebra/rt_netlink.c
index f91b2f889..686815da3 100644
--- a/zebra/rt_netlink.c
+++ b/zebra/rt_netlink.c
@@ -79,6 +79,7 @@
#include "zebra/zebra_vxlan.h"
#include "zebra/zebra_errors.h"
#include "zebra/zebra_evpn_mh.h"
+#include "zebra/zebra_trace.h"
#ifndef AF_MPLS
#define AF_MPLS 28
@@ -2906,6 +2907,8 @@ int netlink_nexthop_change(struct nlmsghdr *h, ns_id_t ns_id, int startup)
uint8_t grp_count = 0;
struct rtattr *tb[NHA_MAX + 1] = {};
+ frrtrace(3, frr_zebra, netlink_nexthop_change, h, ns_id, startup);
+
nhm = NLMSG_DATA(h);
if (ns_id)
diff --git a/zebra/zebra_trace.h b/zebra/zebra_trace.h
index 3175c1a12..d5c8287f0 100644
--- a/zebra/zebra_trace.h
+++ b/zebra/zebra_trace.h
@@ -67,6 +67,20 @@ TRACEPOINT_EVENT(
)
)
+TRACEPOINT_EVENT(
+ frr_zebra,
+ netlink_nexthop_change,
+ TP_ARGS(
+ struct nlmsghdr *, h,
+ ns_id_t, ns_id,
+ int, startup),
+ TP_FIELDS(
+ ctf_integer_hex(intptr_t, h, h)
+ ctf_integer(uint32_t, ns_id, ns_id)
+ ctf_integer(uint32_t, startup, startup)
+ )
+ )
+
#include <lttng/tracepoint-event.h>
#endif /* HAVE_LTTNG */