summaryrefslogtreecommitdiff
path: root/kernel/sysctl.c
diff options
context:
space:
mode:
authorBui Quang Minh <minhquangbui99@gmail.com>2021-01-27 06:36:53 +0000
committerMichael Bestas <mkbestas@lineageos.org>2022-04-19 00:51:52 +0300
commit2790324974734efc1a307922d738582ef006d201 (patch)
treef9b1f16c0c662ebf5ea6a16d689e285cca16afae /kernel/sysctl.c
parente6c4b4b97e4cfed0e2cecd06655c1e641bc42fda (diff)
bpf: Check for integer overflow when using roundup_pow_of_two()
[ Upstream commit 6183f4d3a0a2ad230511987c6c362ca43ec0055f ] On 32-bit architecture, roundup_pow_of_two() can return 0 when the argument has upper most bit set due to resulting 1UL << 32. Add a check for this case. Fixes: d5a3b1f69186 ("bpf: introduce BPF_MAP_TYPE_STACK_TRACE") Signed-off-by: Bui Quang Minh <minhquangbui99@gmail.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Link: https://lore.kernel.org/bpf/20210127063653.3576-1-minhquangbui99@gmail.com Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'kernel/sysctl.c')
0 files changed, 0 insertions, 0 deletions