Skip to content

Commit b2e2f0e

Browse files
YueHaibingAlexei Starovoitov
authored andcommitted
bpf: Make array_map_mmap static
Fix sparse warning: kernel/bpf/arraymap.c:481:5: warning: symbol 'array_map_mmap' was not declared. Should it be static? Reported-by: Hulk Robot <[email protected]> Signed-off-by: YueHaibing <[email protected]> Signed-off-by: Alexei Starovoitov <[email protected]> Acked-by: Andrii Nakryiko <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
1 parent 24f6505 commit b2e2f0e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

kernel/bpf/arraymap.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ static int array_map_check_btf(const struct bpf_map *map,
478478
return 0;
479479
}
480480

481-
int array_map_mmap(struct bpf_map *map, struct vm_area_struct *vma)
481+
static int array_map_mmap(struct bpf_map *map, struct vm_area_struct *vma)
482482
{
483483
struct bpf_array *array = container_of(map, struct bpf_array, map);
484484
pgoff_t pgoff = PAGE_ALIGN(sizeof(*array)) >> PAGE_SHIFT;

0 commit comments

Comments
 (0)