• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /*
3  * Copyright (c) 2023 Huawei Device Co., Ltd.
4  */
5 
6 #ifndef LITE_HCK_INET_H
7 #define LITE_HCK_INET_H
8 
9 #include <linux/netdevice.h>
10 #include <linux/hck/lite_vendor_hooks.h>
11 
12 #ifndef CONFIG_HCK
13 #undef CALL_HCK_LITE_HOOK
14 #define CALL_HCK_LITE_HOOK(name, args...)
15 #undef REGISTER_HCK_LITE_HOOK
16 #define REGISTER_HCK_LITE_HOOK(name, probe)
17 #undef REGISTER_HCK_LITE_DATA_HOOK
18 #define REGISTER_HCK_LITE_DATA_HOOK(name, probe, data)
19 #else
20 
21 DECLARE_HCK_LITE_HOOK(nip_ninet_ehashfn_lhck,
22 		TP_PROTO(const struct sock *sk, u32 *ret),
23 		TP_ARGS(sk, ret));
24 
25 DECLARE_HCK_LITE_HOOK(nip_ninet_gifconf_lhck,
26 		TP_PROTO(struct net_device *dev, char __user *buf, int len, int size, int *ret),
27 		TP_ARGS(dev, buf, len, size, ret));
28 
29 #endif /* CONFIG_HCK */
30 
31 #endif /* LITE_HCK_INET_H */
32