diff options
author | Roman Gushchin <guro@fb.com> | 2020-12-01 13:58:53 -0800 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2020-12-02 18:32:47 -0800 |
commit | abbdd0813f347f9d1eea376409a68295318b2ef5 (patch) | |
tree | 3194198276361593cb99960ab8c23939d919907d /net | |
parent | db54330d3e137c23bea26784cecf5ae17e72e4c6 (diff) |
bpf: Eliminate rlimit-based memory accounting for bpf ringbuffer
Do not use rlimit-based memory accounting for bpf ringbuffer.
It has been replaced with the memcg-based memory accounting.
bpf_ringbuf_alloc() can't return anything except ERR_PTR(-ENOMEM)
and a valid pointer, so to simplify the code make it return NULL
in the first case. This allows to drop a couple of lines in
ringbuf_map_alloc() and also makes it look similar to other memory
allocating function like kmalloc().
Signed-off-by: Roman Gushchin <guro@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Song Liu <songliubraving@fb.com>
Acked-by: Andrii Nakryiko <andriin@fb.com>
Link: https://lore.kernel.org/bpf/20201201215900.3569844-28-guro@fb.com
Diffstat (limited to 'net')
0 files changed, 0 insertions, 0 deletions