Skip to content

Commit

Permalink
bpf: selftests: Remove unused 'nospace_err' in tests for batched ops …
Browse files Browse the repository at this point in the history
…in array maps

This seems to be a reminiscent from the hashmap tests.

Signed-off-by: Pedro Tammela <[email protected]>
Signed-off-by: Andrii Nakryiko <[email protected]>
Acked-by: Yonghong Song <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]
  • Loading branch information
tammela authored and anakryiko committed Mar 16, 2021
1 parent d94436a commit 23f50b5
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions tools/testing/selftests/bpf/map_tests/array_map_batch_ops.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ void test_array_map_batch_ops(void)
int map_fd, *keys, *values, *visited;
__u32 count, total, total_success;
const __u32 max_entries = 10;
bool nospace_err;
__u64 batch = 0;
int err, step;
DECLARE_LIBBPF_OPTS(bpf_map_batch_opts, opts,
Expand Down Expand Up @@ -90,7 +89,6 @@ void test_array_map_batch_ops(void)
* elements each.
*/
count = step;
nospace_err = false;
while (true) {
err = bpf_map_lookup_batch(map_fd,
total ? &batch : NULL, &batch,
Expand All @@ -107,9 +105,6 @@ void test_array_map_batch_ops(void)

}

if (nospace_err == true)
continue;

CHECK(total != max_entries, "lookup with steps",
"total = %u, max_entries = %u\n", total, max_entries);

Expand Down

0 comments on commit 23f50b5

Please sign in to comment.