]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
fix up x86-speculation-include-unprivileged-ebpf-status-in-spectre-v2-mitigation...
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 10 Mar 2022 12:25:32 +0000 (13:25 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 10 Mar 2022 12:25:32 +0000 (13:25 +0100)
for 5.4 and 4.19

queue-4.19/x86-speculation-include-unprivileged-ebpf-status-in-spectre-v2-mitigation-reporting.patch
queue-5.4/x86-speculation-include-unprivileged-ebpf-status-in-spectre-v2-mitigation-reporting.patch

index a8818ab2ec62354f31cc9f50553f0175d79a39eb..bca0d2f1cdf4172dd803c36ff4477f95e3eca3ad 100644 (file)
@@ -111,9 +111,9 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  #else /* !CONFIG_BPF_SYSCALL */
  static inline struct bpf_prog *bpf_prog_get(u32 ufd)
  {
-@@ -801,6 +806,12 @@ static inline int bpf_fd_reuseport_array
+@@ -644,6 +649,12 @@ static inline struct bpf_prog *bpf_prog_
  {
-       return -EOPNOTSUPP;
+       return ERR_PTR(-EOPNOTSUPP);
  }
 +
 +static inline bool unprivileged_ebpf_enabled(void)
@@ -122,8 +122,8 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 +}
 +
  #endif /* CONFIG_BPF_SYSCALL */
- #endif /* defined(CONFIG_INET) && defined(CONFIG_BPF_SYSCALL) */
  
+ static inline struct bpf_prog *bpf_prog_get_type(u32 ufd,
 --- a/kernel/sysctl.c
 +++ b/kernel/sysctl.c
 @@ -251,6 +251,11 @@ static int sysrq_sysctl_handler(struct c
index a2eb56ecb09249ff7a3ec0bc80cc67df35c23d2e..b7585e63af102852681c4617e2552d5996019365 100644 (file)
@@ -112,9 +112,9 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  #else /* !CONFIG_BPF_SYSCALL */
  static inline struct bpf_prog *bpf_prog_get(u32 ufd)
  {
-@@ -1034,6 +1040,12 @@ static inline int bpf_fd_reuseport_array
+@@ -881,6 +887,12 @@ static inline int bpf_prog_test_run_flow
  {
-       return -EOPNOTSUPP;
+       return -ENOTSUPP;
  }
 +
 +static inline bool unprivileged_ebpf_enabled(void)
@@ -123,8 +123,8 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 +}
 +
  #endif /* CONFIG_BPF_SYSCALL */
- #endif /* defined(CONFIG_INET) && defined(CONFIG_BPF_SYSCALL) */
  
+ static inline struct bpf_prog *bpf_prog_get_type(u32 ufd,
 --- a/kernel/sysctl.c
 +++ b/kernel/sysctl.c
 @@ -251,6 +251,11 @@ static int sysrq_sysctl_handler(struct c