ANDROID: bpf: Workaround for bpf permissions check regression

From an email thread on how to try to fix up the current Android boot
issues...

Change-Id: If4a4ef96acc09708727451fb79233b3cc1f18482
Signed-off-by: John Stultz <john.stultz@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
John Stultz
2020-06-18 19:03:44 +00:00
committed by Greg Kroah-Hartman
parent 95a06095ff
commit 96331e0dc4

View File

@@ -2134,7 +2134,7 @@ static int bpf_prog_load(union bpf_attr *attr, union bpf_attr __user *uattr)
!bpf_capable())
return -EPERM;
if (is_net_admin_prog_type(type) && !capable(CAP_NET_ADMIN))
if (is_net_admin_prog_type(type) && !capable(CAP_SYS_ADMIN))
return -EPERM;
if (is_perfmon_prog_type(type) && !perfmon_capable())
return -EPERM;