[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201019194206.1050591-1-kafai@fb.com>
Date: Mon, 19 Oct 2020 12:42:06 -0700
From: Martin KaFai Lau <kafai@...com>
To: <bpf@...r.kernel.org>
CC: Alexei Starovoitov <ast@...nel.org>,
Daniel Borkmann <daniel@...earbox.net>,
Hao Luo <haoluo@...gle.com>, <kernel-team@...com>,
<netdev@...r.kernel.org>, Yonghong Song <yhs@...com>
Subject: [PATCH bpf 0/3] bpf: Enforce NULL check on new _OR_NULL return types
This set enforces NULL check on the new helper return types,
RET_PTR_TO_BTF_ID_OR_NULL and RET_PTR_TO_MEM_OR_BTF_ID_OR_NULL.
Martin KaFai Lau (3):
bpf: Enforce id generation for all may-be-null register type
bpf: selftest: Ensure the return value of bpf_skc_to helpers must be
checked
bpf: selftest: Ensure the return value of the bpf_per_cpu_ptr() must
be checked
kernel/bpf/verifier.c | 11 ++--
.../selftests/bpf/prog_tests/ksyms_btf.c | 57 +++++++++++++------
.../bpf/progs/test_ksyms_btf_null_check.c | 31 ++++++++++
tools/testing/selftests/bpf/verifier/sock.c | 25 ++++++++
4 files changed, 100 insertions(+), 24 deletions(-)
create mode 100644 tools/testing/selftests/bpf/progs/test_ksyms_btf_null_check.c
--
2.24.1
Powered by blists - more mailing lists