aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/include/asm/assembler.h
diff options
context:
space:
mode:
authorMartin KaFai Lau <[email protected]>2020-03-14 01:02:09 +0000
committerDaniel Borkmann <[email protected]>2020-03-17 19:40:19 +0000
commit8e7ae2518f5265f0ef09d561748098fde5a87ccd (patch)
tree4ca18ed93fa3e56a4c81ff6715d0a8b9d8b7afb9 /arch/arm/include/asm/assembler.h
parentnet: ip_gre: Accept IFLA_INFO_DATA-less configuration (diff)
downloadkernel-8e7ae2518f5265f0ef09d561748098fde5a87ccd.tar.gz
kernel-8e7ae2518f5265f0ef09d561748098fde5a87ccd.zip
bpf: Sanitize the bpf_struct_ops tcp-cc name
The bpf_struct_ops tcp-cc name should be sanitized in order to avoid problematic chars (e.g. whitespaces). This patch reuses the bpf_obj_name_cpy() for accepting the same set of characters in order to keep a consistent bpf programming experience. A "size" param is added. Also, the strlen is returned on success so that the caller (like the bpf_tcp_ca here) can error out on empty name. The existing callers of the bpf_obj_name_cpy() only need to change the testing statement to "if (err < 0)". For all these existing callers, the err will be overwritten later, so no extra change is needed for the new strlen return value. v3: - reverse xmas tree style v2: - Save the orig_src to avoid "end - size" (Andrii) Fixes: 0baf26b0fcd7 ("bpf: tcp: Support tcp_congestion_ops in bpf") Signed-off-by: Martin KaFai Lau <[email protected]> Signed-off-by: Daniel Borkmann <[email protected]> Acked-by: Andrii Nakryiko <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'arch/arm/include/asm/assembler.h')
0 files changed, 0 insertions, 0 deletions