]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: Change kvfree to kfree in generic_map_lookup_batch()
authorDenis Efremov <efremov@linux.com>
Mon, 1 Jun 2020 16:28:14 +0000 (19:28 +0300)
committerAlexei Starovoitov <ast@kernel.org>
Mon, 1 Jun 2020 21:48:33 +0000 (14:48 -0700)
commitd6ddc0b3b95e17dd59aed8459789be9852e92202
tree0a444c6c75337492ed4b11c448e283af7856f026
parent7327a24e48558c0e3dff87c1a61b620c217ddfdc
bpf: Change kvfree to kfree in generic_map_lookup_batch()

buf_prevkey in generic_map_lookup_batch() is allocated with
kmalloc(). It's safe to free it with kfree().

Fixes: 694a8e604cdc ("bpf: Add generic support for lookup batch op")
Signed-off-by: Denis Efremov <efremov@linux.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Song Liu <songliubraving@fb.com>
Link: https://lore.kernel.org/bpf/20200601162814.17426-1-efremov@linux.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
kernel/bpf/syscall.c