summaryrefslogtreecommitdiffstats
path: root/include/trace
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2016-09-23 12:39:22 +0100
committerDavid Howells <dhowells@redhat.com>2016-09-23 15:49:19 +0100
commitbe832aecc5ba811728e15a10f675f4a2187f25dd (patch)
tree42ef2d2bf2804c0f18a4ede8169bbede793c87ed /include/trace
parentfc7ab6d29a3af0b7f6df7c095509378c8caf85b5 (diff)
downloadop-kernel-dev-be832aecc5ba811728e15a10f675f4a2187f25dd.zip
op-kernel-dev-be832aecc5ba811728e15a10f675f4a2187f25dd.tar.gz
rxrpc: Add data Tx tracepoint and adjust Tx ACK tracepoint
Add a tracepoint to log transmission of DATA packets (including loss injection). Adjust the ACK transmission tracepoint to include the packet serial number and to line this up with the DATA transmission display. Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'include/trace')
-rw-r--r--include/trace/events/rxrpc.h50
1 files changed, 42 insertions, 8 deletions
diff --git a/include/trace/events/rxrpc.h b/include/trace/events/rxrpc.h
index 5732289..6001bf9 100644
--- a/include/trace/events/rxrpc.h
+++ b/include/trace/events/rxrpc.h
@@ -256,33 +256,67 @@ TRACE_EVENT(rxrpc_rx_ack,
__entry->n_acks)
);
+TRACE_EVENT(rxrpc_tx_data,
+ TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t seq,
+ rxrpc_serial_t serial, u8 flags, bool lose),
+
+ TP_ARGS(call, seq, serial, flags, lose),
+
+ TP_STRUCT__entry(
+ __field(struct rxrpc_call *, call )
+ __field(rxrpc_seq_t, seq )
+ __field(rxrpc_serial_t, serial )
+ __field(u8, flags )
+ __field(bool, lose )
+ ),
+
+ TP_fast_assign(
+ __entry->call = call;
+ __entry->seq = seq;
+ __entry->serial = serial;
+ __entry->flags = flags;
+ __entry->lose = lose;
+ ),
+
+ TP_printk("c=%p DATA %08x q=%08x fl=%02x%s",
+ __entry->call,
+ __entry->serial,
+ __entry->seq,
+ __entry->flags,
+ __entry->lose ? " *LOSE*" : "")
+ );
+
TRACE_EVENT(rxrpc_tx_ack,
- TP_PROTO(struct rxrpc_call *call, rxrpc_seq_t first,
- rxrpc_serial_t serial, u8 reason, u8 n_acks),
+ TP_PROTO(struct rxrpc_call *call, rxrpc_serial_t serial,
+ rxrpc_seq_t ack_first, rxrpc_serial_t ack_serial,
+ u8 reason, u8 n_acks),
- TP_ARGS(call, first, serial, reason, n_acks),
+ TP_ARGS(call, serial, ack_first, ack_serial, reason, n_acks),
TP_STRUCT__entry(
__field(struct rxrpc_call *, call )
- __field(rxrpc_seq_t, first )
__field(rxrpc_serial_t, serial )
+ __field(rxrpc_seq_t, ack_first )
+ __field(rxrpc_serial_t, ack_serial )
__field(u8, reason )
__field(u8, n_acks )
),
TP_fast_assign(
__entry->call = call;
- __entry->first = first;
__entry->serial = serial;
+ __entry->ack_first = ack_first;
+ __entry->ack_serial = ack_serial;
__entry->reason = reason;
__entry->n_acks = n_acks;
),
- TP_printk("c=%p %s f=%08x r=%08x n=%u",
+ TP_printk(" c=%p ACK %08x %s f=%08x r=%08x n=%u",
__entry->call,
- rxrpc_acks(__entry->reason),
- __entry->first,
__entry->serial,
+ rxrpc_acks(__entry->reason),
+ __entry->ack_first,
+ __entry->ack_serial,
__entry->n_acks)
);
OpenPOWER on IntegriCloud