summaryrefslogtreecommitdiffstats
path: root/include/linux/filter.h
diff options
context:
space:
mode:
authorMartynas Pumputis2019-01-31 10:19:33 +0100
committerDaniel Borkmann2019-01-31 23:13:22 +0100
commit1bb54c4071f585ebef56ce8fdfe6026fa2cbcddd (patch)
tree7250dc1999a2829c27b5e721446c49cad6b759f3 /include/linux/filter.h
parentMerge branch 'typedef-func_proto' (diff)
downloadkernel-qcow2-linux-1bb54c4071f585ebef56ce8fdfe6026fa2cbcddd.tar.gz
kernel-qcow2-linux-1bb54c4071f585ebef56ce8fdfe6026fa2cbcddd.tar.xz
kernel-qcow2-linux-1bb54c4071f585ebef56ce8fdfe6026fa2cbcddd.zip
bpf, selftests: fix handling of sparse CPU allocations
Previously, bpf_num_possible_cpus() had a bug when calculating a number of possible CPUs in the case of sparse CPU allocations, as it was considering only the first range or element of /sys/devices/system/cpu/possible. E.g. in the case of "0,2-3" (CPU 1 is not available), the function returned 1 instead of 3. This patch fixes the function by making it parse all CPU ranges and elements. Signed-off-by: Martynas Pumputis <m@lambda.lt> Acked-by: Yonghong Song <yhs@fb.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Diffstat (limited to 'include/linux/filter.h')
0 files changed, 0 insertions, 0 deletions