tracex2_user.c (3eb66e91a25497065c5322b1268cbc3953642227) tracex2_user.c (5c3cf87d477a461274452cb46f7654c5b6ae6294)
1// SPDX-License-Identifier: GPL-2.0
2#include <stdio.h>
3#include <unistd.h>
4#include <stdlib.h>
5#include <signal.h>
6#include <linux/bpf.h>
7#include <string.h>
8#include <sys/resource.h>

--- 117 unchanged lines hidden (view full) ---

126 perror("setrlimit(RLIMIT_MEMLOCK)");
127 return 1;
128 }
129
130 signal(SIGINT, int_exit);
131 signal(SIGTERM, int_exit);
132
133 /* start 'ping' in the background to have some kfree_skb events */
1// SPDX-License-Identifier: GPL-2.0
2#include <stdio.h>
3#include <unistd.h>
4#include <stdlib.h>
5#include <signal.h>
6#include <linux/bpf.h>
7#include <string.h>
8#include <sys/resource.h>

--- 117 unchanged lines hidden (view full) ---

126 perror("setrlimit(RLIMIT_MEMLOCK)");
127 return 1;
128 }
129
130 signal(SIGINT, int_exit);
131 signal(SIGTERM, int_exit);
132
133 /* start 'ping' in the background to have some kfree_skb events */
134 f = popen("ping -c5 localhost", "r");
134 f = popen("ping -4 -c5 localhost", "r");
135 (void) f;
136
137 /* start 'dd' in the background to have plenty of 'write' syscalls */
138 f = popen("dd if=/dev/zero of=/dev/null count=5000000", "r");
139 (void) f;
140
141 if (load_bpf_file(filename)) {
142 printf("%s", bpf_log_buf);

--- 18 unchanged lines hidden ---
135 (void) f;
136
137 /* start 'dd' in the background to have plenty of 'write' syscalls */
138 f = popen("dd if=/dev/zero of=/dev/null count=5000000", "r");
139 (void) f;
140
141 if (load_bpf_file(filename)) {
142 printf("%s", bpf_log_buf);

--- 18 unchanged lines hidden ---