| 1 |
#include "common.h" |
| 2 |
#include "linked.h" |
| 3 |
|
| 4 |
|
| 5 |
__section(".maps") struct h32_btf map_l1_w; |
| 6 |
|
| 7 |
|
| 8 |
__weak __section(".maps") struct h32_btf map_l1_s; |
| 9 |
|
| 10 |
|
| 11 |
__weak __section(".maps") struct h32_btf map_ww; |
| 12 |
|
| 13 |
|
| 14 |
__section(".maps") struct h32_btf map_l2; |
| 15 |
|
| 16 |
|
| 17 |
__weak __section("maps") struct bpf_map_def map_legacy_l1_s = h32_legacy(__LINE__); |
| 18 |
|
| 19 |
|
| 20 |
__section("maps") struct bpf_map_def map_legacy_l2_s = h32_legacy(1); |
| 21 |
|
| 22 |
|
| 23 |
extern int l1(void); |
| 24 |
__section("socket") int entry_l1() { |
| 25 |
return l1(); |
| 26 |
} |
| 27 |
|
| 28 |
|
| 29 |
__weak __noinline int l2() { |
| 30 |
return 0; |
| 31 |
} |
| 32 |
|
| 33 |
|
| 34 |
__noinline int l1_w() { |
| 35 |
return 0; |
| 36 |
} |
| 37 |
__section("socket") int entry_l1_w() { |
| 38 |
return l1_w(); |
| 39 |
} |
| 40 |
|
| 41 |
|
| 42 |
__weak __noinline int l1_s() { |
| 43 |
return __LINE__; |
| 44 |
} |
| 45 |
__weak __section("socket") int entry_l1_s() { |
| 46 |
return l1_s(); |
| 47 |
} |
| 48 |
|
| 49 |
|
| 50 |
__weak __noinline int ww() { |
| 51 |
return __LINE__; |
| 52 |
} |
| 53 |
__weak __section("socket") int entry_ww() { |
| 54 |
return ww(); |
| 55 |
} |