File tree 1 file changed +3
-4
lines changed
tools/testing/selftests/bpf/prog_tests 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change 3
3
4
4
#include <linux/err.h>
5
5
#include <netinet/tcp.h>
6
+ #include <sys/param.h>
6
7
#include <test_progs.h>
7
8
#include "network_helpers.h"
8
9
#include "bpf_dctcp.skel.h"
9
10
#include "bpf_cubic.skel.h"
10
11
#include "bpf_tcp_nogpl.skel.h"
11
12
#include "bpf_dctcp_release.skel.h"
12
13
13
- #define min (a , b ) ((a) < (b) ? (a) : (b))
14
-
15
14
#ifndef ENOTSUPP
16
15
#define ENOTSUPP 524
17
16
#endif
@@ -53,7 +52,7 @@ static void *server(void *arg)
53
52
54
53
while (bytes < total_bytes && !READ_ONCE (stop )) {
55
54
nr_sent = send (fd , & batch ,
56
- min (total_bytes - bytes , sizeof (batch )), 0 );
55
+ MIN (total_bytes - bytes , sizeof (batch )), 0 );
57
56
if (nr_sent == -1 && errno == EINTR )
58
57
continue ;
59
58
if (nr_sent == -1 ) {
@@ -146,7 +145,7 @@ static void do_test(const char *tcp_ca, const struct bpf_map *sk_stg_map)
146
145
/* recv total_bytes */
147
146
while (bytes < total_bytes && !READ_ONCE (stop )) {
148
147
nr_recv = recv (fd , & batch ,
149
- min (total_bytes - bytes , sizeof (batch )), 0 );
148
+ MIN (total_bytes - bytes , sizeof (batch )), 0 );
150
149
if (nr_recv == -1 && errno == EINTR )
151
150
continue ;
152
151
if (nr_recv == -1 )
You can’t perform that action at this time.
0 commit comments