Commit 69b0e112 authored by Sriram Yagnaraman's avatar Sriram Yagnaraman Committed by Arnaldo Carvalho de Melo

perf script: Add new parameter in kfree_skb tracepoint to the python scripts using it

Include reason parameter that was added in commit c504e5c2
("net: skb: introduce kfree_skb_reason()")

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sriram Yagnaraman <sriram.yagnaraman@est.tech>
Link: https://lore.kernel.org/r/20230426104149.14089-1-sriram.yagnaraman@est.techSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent 0e20f431
......@@ -68,9 +68,9 @@ def trace_end():
get_kallsyms_table()
print_drop_table()
# called from perf, when it finds a correspoinding event
# called from perf, when it finds a corresponding event
def skb__kfree_skb(name, context, cpu, sec, nsec, pid, comm, callchain,
skbaddr, location, protocol):
skbaddr, location, protocol, reason):
slocation = str(location)
try:
drop_log[slocation] = drop_log[slocation] + 1
......
......@@ -288,9 +288,9 @@ def net__net_dev_xmit(name, context, cpu, sec, nsec, pid, comm, callchain,
all_event_list.append(event_info)
def skb__kfree_skb(name, context, cpu, sec, nsec, pid, comm, callchain,
skbaddr, protocol, location):
skbaddr, location, protocol, reason):
event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
skbaddr, protocol, location)
skbaddr, location, protocol, reason)
all_event_list.append(event_info)
def skb__consume_skb(name, context, cpu, sec, nsec, pid, comm, callchain, skbaddr):
......@@ -430,7 +430,7 @@ def handle_net_dev_xmit(event_info):
def handle_kfree_skb(event_info):
(name, context, cpu, time, pid, comm,
skbaddr, protocol, location) = event_info
skbaddr, location, protocol, reason) = event_info
for i in range(len(tx_queue_list)):
skb = tx_queue_list[i]
if skb['skbaddr'] == skbaddr:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment