diff --git a/kernel/Documentation/bpf/troubleshooting.rst b/kernel/Documentation/bpf/troubleshooting.rst index 5ceb857..0c41a7a 100644 --- a/kernel/Documentation/bpf/troubleshooting.rst +++ b/kernel/Documentation/bpf/troubleshooting.rst @@ -8,11 +8,9 @@ programs. With a primary focus on programs under kernels samples/bpf. Memory ulimits ============== -The eBPF maps uses locked memory, which is default very low. -Your program likely need to increase resource limit ``RLIMIT_MEMLOCK`` -see system call `setrlimit(2)`_. +The eBPF maps uses locked memory. A typical Ubuntu system will set RLIMIT to 64k `uname -l`. -The ``bpf_create_map`` call will return errno EPERM (Operation not +The ``bpf_create_map`` call will set the RLIMIT_MEMLOCK to RLIM_INFINITY and will return errno EPERM (Operation not permitted) when the RLIMIT_MEMLOCK memory size limit is exceeded. .. _setrlimit(2): http://man7.org/linux/man-pages/man2/setrlimit.2.html