b.liu | e958203 | 2025-04-17 19:18:16 +0800 | [diff] [blame^] | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
| 2 | |
| 3 | #undef TRACE_SYSTEM |
| 4 | #define TRACE_SYSTEM net |
| 5 | #define TRACE_INCLUDE_PATH trace/hooks |
| 6 | |
| 7 | #if !defined(_TRACE_HOOK_NET_VH_H) || defined(TRACE_HEADER_MULTI_READ) |
| 8 | #define _TRACE_HOOK_NET_VH_H |
| 9 | #include <linux/tracepoint.h> |
| 10 | #include <trace/hooks/vendor_hooks.h> |
| 11 | |
| 12 | struct packet_type; |
| 13 | struct list_head; |
| 14 | struct sk_buff; |
| 15 | struct nf_conn; |
| 16 | struct sock; |
| 17 | DECLARE_HOOK(android_vh_ptype_head, |
| 18 | TP_PROTO(const struct packet_type *pt, struct list_head *vendor_pt), |
| 19 | TP_ARGS(pt, vendor_pt)); |
| 20 | DECLARE_HOOK(android_vh_kfree_skb, |
| 21 | TP_PROTO(struct sk_buff *skb), TP_ARGS(skb)); |
| 22 | DECLARE_RESTRICTED_HOOK(android_rvh_nf_conn_alloc, |
| 23 | TP_PROTO(struct nf_conn *nf_conn), TP_ARGS(nf_conn), 1); |
| 24 | DECLARE_RESTRICTED_HOOK(android_rvh_nf_conn_free, |
| 25 | TP_PROTO(struct nf_conn *nf_conn), TP_ARGS(nf_conn), 1); |
| 26 | DECLARE_RESTRICTED_HOOK(android_rvh_sk_alloc, |
| 27 | TP_PROTO(struct sock *sock), TP_ARGS(sock), 1); |
| 28 | DECLARE_RESTRICTED_HOOK(android_rvh_sk_free, |
| 29 | TP_PROTO(struct sock *sock), TP_ARGS(sock), 1); |
| 30 | |
| 31 | /* macro versions of hooks are no longer required */ |
| 32 | |
| 33 | #endif /* _TRACE_HOOK_NET_VH_H */ |
| 34 | /* This part must be outside protection */ |
| 35 | #include <trace/define_trace.h> |