On 11/01/2017 12:16 PM, Orson Zhai wrote:
[...]
We have ran some bpf test within kselftest for 4.14.0-rc5-next-20171018 at
some hardware resource limited devices. Say Hikey Board (arm64 core) with
2GB memory.
The test processes was killed by OOM which made the test failed.
We investigate the reason and find bpf test will require a large mount of
memory to run.
Like some code in selftests/bpf/test_maps.c
static void test_hashmap_walk(int task, void *data)
{
int fd, i, max_entries = 100000;
^^^^^^^^^^^^
......
}
The test will pass smoothly when we set max_entries to a smaller number.
Feel free to send a patch to set this to something lower, maybe 10k
or such, if that will work for your setup.
Thanks,
Daniel