sh_eth: fix EESIPR values for SH77{34|63}
[linux/fpc-iii.git] / sound / firewire / amdtp-stream-trace.h
blob9c04faf206b287e5f949120f5fa2860a5690964b
1 /*
2 * amdtp-stream-trace.h - tracepoint definitions to dump a part of packet data
4 * Copyright (c) 2016 Takashi Sakamoto
5 * Licensed under the terms of the GNU General Public License, version 2.
6 */
8 #undef TRACE_SYSTEM
9 #define TRACE_SYSTEM snd_firewire_lib
11 #if !defined(_AMDTP_STREAM_TRACE_H) || defined(TRACE_HEADER_MULTI_READ)
12 #define _AMDTP_STREAM_TRACE_H
14 #include <linux/tracepoint.h>
16 TRACE_EVENT(in_packet,
17 TP_PROTO(const struct amdtp_stream *s, u32 cycles, u32 cip_header[2], unsigned int payload_quadlets, unsigned int index),
18 TP_ARGS(s, cycles, cip_header, payload_quadlets, index),
19 TP_STRUCT__entry(
20 __field(unsigned int, second)
21 __field(unsigned int, cycle)
22 __field(int, channel)
23 __field(int, src)
24 __field(int, dest)
25 __field(u32, cip_header0)
26 __field(u32, cip_header1)
27 __field(unsigned int, payload_quadlets)
28 __field(unsigned int, packet_index)
29 __field(unsigned int, irq)
30 __field(unsigned int, index)
32 TP_fast_assign(
33 __entry->second = cycles / CYCLES_PER_SECOND;
34 __entry->cycle = cycles % CYCLES_PER_SECOND;
35 __entry->channel = s->context->channel;
36 __entry->src = fw_parent_device(s->unit)->node_id;
37 __entry->dest = fw_parent_device(s->unit)->card->node_id;
38 __entry->cip_header0 = cip_header[0];
39 __entry->cip_header1 = cip_header[1];
40 __entry->payload_quadlets = payload_quadlets;
41 __entry->packet_index = s->packet_index;
42 __entry->irq = !!in_interrupt();
43 __entry->index = index;
45 TP_printk(
46 "%02u %04u %04x %04x %02d %08x %08x %03u %02u %01u %02u",
47 __entry->second,
48 __entry->cycle,
49 __entry->src,
50 __entry->dest,
51 __entry->channel,
52 __entry->cip_header0,
53 __entry->cip_header1,
54 __entry->payload_quadlets,
55 __entry->packet_index,
56 __entry->irq,
57 __entry->index)
60 TRACE_EVENT(out_packet,
61 TP_PROTO(const struct amdtp_stream *s, u32 cycles, __be32 *cip_header, unsigned int payload_length, unsigned int index),
62 TP_ARGS(s, cycles, cip_header, payload_length, index),
63 TP_STRUCT__entry(
64 __field(unsigned int, second)
65 __field(unsigned int, cycle)
66 __field(int, channel)
67 __field(int, src)
68 __field(int, dest)
69 __field(u32, cip_header0)
70 __field(u32, cip_header1)
71 __field(unsigned int, payload_quadlets)
72 __field(unsigned int, packet_index)
73 __field(unsigned int, irq)
74 __field(unsigned int, index)
76 TP_fast_assign(
77 __entry->second = cycles / CYCLES_PER_SECOND;
78 __entry->cycle = cycles % CYCLES_PER_SECOND;
79 __entry->channel = s->context->channel;
80 __entry->src = fw_parent_device(s->unit)->card->node_id;
81 __entry->dest = fw_parent_device(s->unit)->node_id;
82 __entry->cip_header0 = be32_to_cpu(cip_header[0]);
83 __entry->cip_header1 = be32_to_cpu(cip_header[1]);
84 __entry->payload_quadlets = payload_length / 4;
85 __entry->packet_index = s->packet_index;
86 __entry->irq = !!in_interrupt();
87 __entry->index = index;
89 TP_printk(
90 "%02u %04u %04x %04x %02d %08x %08x %03u %02u %01u %02u",
91 __entry->second,
92 __entry->cycle,
93 __entry->src,
94 __entry->dest,
95 __entry->channel,
96 __entry->cip_header0,
97 __entry->cip_header1,
98 __entry->payload_quadlets,
99 __entry->packet_index,
100 __entry->irq,
101 __entry->index)
104 #endif
106 #undef TRACE_INCLUDE_PATH
107 #define TRACE_INCLUDE_PATH .
108 #undef TRACE_INCLUDE_FILE
109 #define TRACE_INCLUDE_FILE amdtp-stream-trace
110 #include <trace/define_trace.h>