1    	/*
2    	 * vim:noexpandtab:shiftwidth=8:tabstop=8:
3    	 *
4    	 * Copyright 2018 Red Hat, Inc. and/or its affiliates.
5    	 * All rights reserved.
6    	 *
7    	 * Redistribution and use in source and binary forms, with or without
8    	 * modification, are permitted provided that the following conditions are met:
9    	 * - Redistributions of source code must retain the above copyright notice,
10   	 *   this list of conditions and the following disclaimer.
11   	 * - Redistributions in binary form must reproduce the above copyright notice,
12   	 *   this list of conditions and the following disclaimer in the documentation
13   	 *   and/or other materials provided with the distribution.
14   	 * - Neither the name of Sun Microsystems, Inc. nor the names of its
15   	 *   contributors may be used to endorse or promote products derived
16   	 *   from this software without specific prior written permission.
17   	 *
18   	 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
19   	 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20   	 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21   	 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
22   	 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
23   	 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
24   	 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
25   	 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
26   	 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27   	 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
28   	 * POSSIBILITY OF SUCH DAMAGE.
29   	 */
30   	
31   	#include "config.h"
32   	#include <stdint.h>
33   	
34   	#undef TRACEPOINT_PROVIDER
35   	#define TRACEPOINT_PROVIDER xprt
36   	
37   	#if !defined(GANESHA_LTTNG_XPRT_TP_H) || defined(TRACEPOINT_HEADER_MULTI_READ)
38   	#define GANESHA_LTTNG_XPRT_TP_H
39   	
40   	#include <lttng/tracepoint.h>
41   	
42   	TRACEPOINT_EVENT(
43   		xprt,
44   		ref,
45   		TP_ARGS(const char *, function,
46   			unsigned int, line,
47   			void *, xprt,
48   			uint32_t, count),
49   		TP_FIELDS(
50   			ctf_string(fnc, function)
51   			ctf_integer(unsigned int, line, line)
52   			ctf_integer_hex(void *, xprt, xprt)
53   			ctf_integer(uint32_t, count, count)
54   		)
55   	)
56   	
57   	TRACEPOINT_LOGLEVEL(
58   		xprt,
59   		ref,
60   		TRACE_INFO)
61   	
(1) Event unsigned_compare: This less-than-zero comparison of an unsigned value is never true. "4294967295U < 0U".
62   	TRACEPOINT_EVENT(
63   		xprt,
64   		unref,
65   		TP_ARGS(const char *, function,
66   			unsigned int, line,
67   			void *, xprt,
68   			uint32_t, count),
69   		TP_FIELDS(
70   			ctf_string(fnc, function)
71   			ctf_integer(unsigned int, line, line)
72   			ctf_integer_hex(void *, xprt, xprt)
73   			ctf_integer(uint32_t, count, count)
74   		)
75   	)
76   	
77   	TRACEPOINT_LOGLEVEL(
78   		xprt,
79   		unref,
80   		TRACE_INFO)
81   	
82   	#endif /* GANESHA_LTTNG_XPRT_TP_H */
83   	
84   	#undef TRACEPOINT_INCLUDE
85   	#define TRACEPOINT_INCLUDE "lttng/xprt.h"
86   	
87   	#include <lttng/tracepoint-event.h>
88