/* AF_RXRPC tracepoints
*
* Copyright (C) 2016 Red Hat, Inc. All Rights Reserved.
* Written by David Howells (dhowells@redhat.com)
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public Licence
* as published by the Free Software Foundation; either version
* 2 of the Licence, or (at your option) any later version.
*/
#undef TRACE_SYSTEM
#define TRACE_SYSTEM rxrpc
#if !defined(_TRACE_RXRPC_H) || defined(TRACE_HEADER_MULTI_READ)
#define _TRACE_RXRPC_H
#include <linux/tracepoint.h>
/*
* Define enums for tracing information.
*
* These should all be kept sorted, making it easier to match the string
* mapping tables further on.
*/
#ifndef __RXRPC_DECLARE_TRACE_ENUMS_ONCE_ONLY
#define __RXRPC_DECLARE_TRACE_ENUMS_ONCE_ONLY
enum rxrpc_skb_trace {
rxrpc_skb_rx_cleaned,
rxrpc_skb_rx_freed,
rxrpc_skb_rx_got,
rxrpc_skb_rx_lost,
rxrpc_skb_rx_purged,
rxrpc_skb_rx_received,
rxrpc_skb_rx_rotated,
rxrpc_skb_rx_seen,
rxrpc_skb_tx_cleaned,
rxrpc_skb_tx_freed,
rxrpc_skb_tx_got,
rxrpc_skb_tx_new,
rxrpc_skb_tx_rotated,
rxrpc_skb_tx_seen,
};
enum rxrpc_conn_trace {
rxrpc_conn_got,
rxrpc_conn_new_client,
rxrpc_conn_new_service,
rxrpc_conn_put_client,
rxrpc_conn_put_service,
rxrpc_conn_queued,
rxrpc_conn_seen,
};
enum rxrpc_client_trace {
rxrpc_client_activate_chans,
rxrpc_client_alloc,
rxrpc_client_chan_activate,
rxrpc_client_chan_disconnect,
rxrpc_client_chan_pass,
rxrpc_client_chan_unstarted,
rxrpc_client_cleanup,
rxrpc_client_count,
rxrpc_client_discard,
rxrpc_client_duplicate,
rxrpc_client_exposed,
rxrpc_client_replace,
rxrpc_client_to_active,
rxrpc_client_to_culled,
rxrpc_client_to_idle,
rxrpc_client_to_inactive,
rxrpc_client_to_upgrade,
rxrpc_client_to_waiting,
rxrpc_client_uncount,
};
enum rxrpc_call_trace {
rxrpc_call_connected,
rxrpc_call_error,
rxrpc_call_got,
rxrpc_call_got_kernel,
rxrpc_call_got_userid,
rxrpc_call_new_client,
rxrpc_call_new_service,
rxrpc_call_put,
rxrpc_call_put_kernel,
rxrpc_call_put_noqueue,
rxrpc_call_put_userid,
rxrpc_call_queued,
rxrpc_call_queued_ref,
rxrpc_call_release,
rxrpc_call_seen,
};
enum rxrpc_transmit_trace {
rxrpc_transmit_await_reply,
rxrpc_transmit_end,
rxrpc_transmit_queue,
rxrpc_transmit_queue_last,
rxrpc_transmit_rotate,
rxrpc_transmit_rotate_last,
rxrpc_transmit_wait,
};
enum rxrpc_receive_trace {
rxrpc_receive_end,
rxrpc_receive_front,
rxrpc_receive_incoming,
rxrpc_receive_queue,
rxrpc_receive_queue_last,
rxrpc_receive_rotate,
};
enum rxrpc_recvmsg_trace {
rxrpc_recvmsg_cont,
rxrpc_recvmsg_data_return,
rxrpc_recvmsg_dequeue,
rxrpc_recvmsg_enter,
rxrpc_recvmsg_full,
rxrpc_recvmsg_hole,
rxrpc_recvmsg_next,
rxrpc_recvmsg_requeue,
rxrpc_recvmsg_return,
rxrpc_recvmsg_terminal,
rxrpc_recvmsg_to_be_accepted,
rxrpc_recvmsg_wait,
};
enum rxrpc_rtt_tx_trace {
rxrpc_rtt_tx_data,
rxrpc_rtt_tx_ping,
};
enum rxrpc_rtt_rx_trace {
rxrpc_rtt_rx_ping_response,
rxrpc_rtt_rx_requested_ack,
};
enum rxrpc_timer_trace {
rxrpc_timer_begin,
rxrpc_timer_expired,
rxrpc_timer_init_for_reply,
rxrpc_timer_init_for_send_reply,
rxrpc_timer_set_for_ack,
rxrpc_timer_set_for_ping,
rxrpc_timer_set_for_resend,
rxrpc_timer_set_for_send,
};
enum rxrpc_propose_ack_trace {
rxrpc_propose_ack_client_tx_end,
rxrpc_propose_ack_input_data,
rxrpc_propose_ack_ping_for_lost_ack,
rxrpc_propose_ack_ping_for_lost_reply,
rxrpc_propose_ack_ping_for_params,
rxrpc_propose_ack_processing_op,
rxrpc_propose_ack_respond_to_ack,
rxrpc_propose_ack_respond_to_ping,
rxrpc_propose_ack_retry_tx,
rxrpc_propose_ack_rotate_rx,
rxrpc_propose_ack_terminal_ack,
};
enum rxrpc_propose_ack_outcome {
rxrpc_propose_ack_subsume,
rxrpc_propose_ack_update,
rxrpc_propose_ack_use,
};
enum rxrpc_congest_change {
rxrpc_cong_begin_retransmission,
rxrpc_cong_cleared_nacks,
rxrpc_cong_new_low_nack,
rxrpc_cong_no_change,
rxrpc_cong_progress,
rxrpc_cong_retransmit_again,
rxrpc_cong_rtt_window_end,
rxrpc_cong_saw_nack,
};
#endif /* end __RXRPC_DECLARE_TRACE_ENUMS_ONCE_ONLY */
/*
* Declare tracing information enums and their string mappings for display.
*/
#define rxrpc_skb_traces \
EM(rxrpc_skb_rx_cleaned, "Rx CLN") \
EM(rxrpc_skb_rx_freed, "Rx FRE") \
EM(rxrpc_skb_rx_got, "Rx GOT") \
EM(rxrpc_skb_rx_lost, "Rx *L*") \
EM(rxrpc_skb_rx_purged, "Rx PUR") \
EM(rxrpc_skb_rx_received, "Rx RCV") \
EM(rxrpc_skb_rx_rotated, "Rx ROT") \
EM(rxrpc_skb_rx_seen, "Rx SEE") \
EM(rxrpc_skb_tx_cleaned, "Tx CLN") \
EM(rxrpc_skb_tx_freed, "Tx FRE") \
EM(rxrpc_skb_tx_got, "Tx GOT") \
EM(rxrpc_skb_tx_new, "Tx NEW") \
EM(rxrpc_skb_tx_rotated, "Tx ROT") \
E_(rxrpc_skb_tx_seen, "Tx SEE")
#define rxrpc_conn_traces \
EM(rxrp