diff options
author | 2022-11-16 15:23:51 +0800 | |
---|---|---|
committer | 2022-11-17 15:49:59 -0800 | |
commit | 05c1558bfcb63b95a9f530767c04c7db091560f2 (patch) | |
tree | fa2ca7e67b027b642c4ed7cfb7872ab9b9106a29 /drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c | |
parent | libbpf: Handle size overflow for user ringbuf mmap (diff) | |
download | wireguard-linux-05c1558bfcb63b95a9f530767c04c7db091560f2.tar.xz wireguard-linux-05c1558bfcb63b95a9f530767c04c7db091560f2.zip |
libbpf: Check the validity of size in user_ring_buffer__reserve()
The top two bits of size are used as busy and discard flags, so reject
the reservation that has any of these special bits in the size. With the
addition of validity check, these is also no need to check whether or
not total_size is overflowed.
Signed-off-by: Hou Tao <houtao1@huawei.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20221116072351.1168938-5-houtao@huaweicloud.com
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_gem.c')
0 files changed, 0 insertions, 0 deletions