aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/bpf
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2021-10-07 15:24:06 -0700
committerJakub Kicinski <kuba@kernel.org>2021-10-07 15:24:06 -0700
commit9fe1155233c8290ca6e206053e531ef87f9026ea (patch)
treeef0d45b2562e01beb8ce4cb4cd016155b4e32a65 /kernel/bpf
parentethernet: ti: cpts: Use devm_kcalloc() instead of devm_kzalloc() (diff)
parentMerge tag 'nfsd-5.15-3' of git://git.kernel.org/pub/scm/linux/kernel/git/cel/linux (diff)
downloadlinux-dev-9fe1155233c8290ca6e206053e531ef87f9026ea.tar.xz
linux-dev-9fe1155233c8290ca6e206053e531ef87f9026ea.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
No conflicts. Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'kernel/bpf')
-rw-r--r--kernel/bpf/stackmap.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/bpf/stackmap.c b/kernel/bpf/stackmap.c
index 09a3fd97d329..6e75bbee39f0 100644
--- a/kernel/bpf/stackmap.c
+++ b/kernel/bpf/stackmap.c
@@ -63,7 +63,8 @@ static inline int stack_map_data_size(struct bpf_map *map)
static int prealloc_elems_and_freelist(struct bpf_stack_map *smap)
{
- u32 elem_size = sizeof(struct stack_map_bucket) + smap->map.value_size;
+ u64 elem_size = sizeof(struct stack_map_bucket) +
+ (u64)smap->map.value_size;
int err;
smap->elems = bpf_map_area_alloc(elem_size * smap->map.max_entries,