diff options
Diffstat (limited to 'tools/testing/selftests/bpf/test_maps.c')
| -rw-r--r-- | tools/testing/selftests/bpf/test_maps.c | 6 | 
1 files changed, 1 insertions, 5 deletions
diff --git a/tools/testing/selftests/bpf/test_maps.c b/tools/testing/selftests/bpf/test_maps.c index 02eae1e864c2..c6766b2cff85 100644 --- a/tools/testing/selftests/bpf/test_maps.c +++ b/tools/testing/selftests/bpf/test_maps.c @@ -756,11 +756,7 @@ static void test_sockmap(unsigned int tasks, void *data)  	/* Test update without programs */  	for (i = 0; i < 6; i++) {  		err = bpf_map_update_elem(fd, &i, &sfd[i], BPF_ANY); -		if (i < 2 && !err) { -			printf("Allowed update sockmap '%i:%i' not in ESTABLISHED\n", -			       i, sfd[i]); -			goto out_sockmap; -		} else if (i >= 2 && err) { +		if (err) {  			printf("Failed noprog update sockmap '%i:%i'\n",  			       i, sfd[i]);  			goto out_sockmap;  |