]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
drop some unneeded libbpf patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 18 Oct 2022 11:29:30 +0000 (13:29 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 18 Oct 2022 11:29:30 +0000 (13:29 +0200)
queue-6.0/libbpf-do-not-require-executable-permission-for-shar.patch
queue-6.0/libbpf-fix-crash-if-sec-freplace-programs-don-t-have.patch
queue-6.0/libbpf-fix-potential-null-dereference-when-parsing-e.patch [deleted file]
queue-6.0/libbpf-skip-empty-sections-in-bpf_object__init_globa.patch [deleted file]
queue-6.0/series

index 858e9c6080878df0284d02ff0a8a107fe2570bc5..dad594aa090ba0d1f6432a804ee4c94c582fa7e0 100644 (file)
@@ -19,14 +19,12 @@ Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
 Link: https://lore.kernel.org/bpf/20220806102021.3867130-1-hengqi.chen@gmail.com
 Signed-off-by: Sasha Levin <sashal@kernel.org>
 ---
- tools/lib/bpf/libbpf.c | 8 +++++---
+ tools/lib/bpf/libbpf.c |    8 +++++---
  1 file changed, 5 insertions(+), 3 deletions(-)
 
-diff --git a/tools/lib/bpf/libbpf.c b/tools/lib/bpf/libbpf.c
-index c0af210f1acd..6b40c8672ff9 100644
 --- a/tools/lib/bpf/libbpf.c
 +++ b/tools/lib/bpf/libbpf.c
-@@ -10671,15 +10671,17 @@ static const char *arch_specific_lib_paths(void)
+@@ -10667,15 +10667,17 @@ static const char *arch_specific_lib_pat
  static int resolve_full_path(const char *file, char *result, size_t result_sz)
  {
        const char *search_paths[3] = {};
@@ -45,7 +43,7 @@ index c0af210f1acd..6b40c8672ff9 100644
        }
  
        for (i = 0; i < ARRAY_SIZE(search_paths); i++) {
-@@ -10698,8 +10700,8 @@ static int resolve_full_path(const char *file, char *result, size_t result_sz)
+@@ -10694,8 +10696,8 @@ static int resolve_full_path(const char
                        if (!seg_len)
                                continue;
                        snprintf(result, result_sz, "%.*s/%s", seg_len, s, file);
@@ -56,6 +54,3 @@ index c0af210f1acd..6b40c8672ff9 100644
                                continue;
                        pr_debug("resolved '%s' to '%s'\n", file, result);
                        return 0;
--- 
-2.35.1
-
index 86ec5aab315087fbde279a06c51fdd08de2936db..70f780bc1b7a6e928dc1d43cebde0fe4d0504321 100644 (file)
@@ -23,14 +23,12 @@ Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
 Link: https://lore.kernel.org/bpf/20220909193053.577111-3-andrii@kernel.org
 Signed-off-by: Sasha Levin <sashal@kernel.org>
 ---
- tools/lib/bpf/libbpf.c | 13 +++++++++----
+ tools/lib/bpf/libbpf.c |   13 +++++++++----
  1 file changed, 9 insertions(+), 4 deletions(-)
 
-diff --git a/tools/lib/bpf/libbpf.c b/tools/lib/bpf/libbpf.c
-index 159f60a245c0..c0af210f1acd 100644
 --- a/tools/lib/bpf/libbpf.c
 +++ b/tools/lib/bpf/libbpf.c
-@@ -9060,11 +9060,15 @@ static int libbpf_find_attach_btf_id(struct bpf_program *prog, const char *attac
+@@ -9056,11 +9056,15 @@ static int libbpf_find_attach_btf_id(str
        int err = 0;
  
        /* BPF program's BTF ID */
@@ -49,7 +47,7 @@ index 159f60a245c0..c0af210f1acd 100644
                        return err;
                }
                *btf_obj_fd = 0;
-@@ -9081,7 +9085,8 @@ static int libbpf_find_attach_btf_id(struct bpf_program *prog, const char *attac
+@@ -9077,7 +9081,8 @@ static int libbpf_find_attach_btf_id(str
                err = find_kernel_btf_id(prog->obj, attach_name, attach_type, btf_obj_fd, btf_type_id);
        }
        if (err) {
@@ -59,6 +57,3 @@ index 159f60a245c0..c0af210f1acd 100644
                return err;
        }
        return 0;
--- 
-2.35.1
-
diff --git a/queue-6.0/libbpf-fix-potential-null-dereference-when-parsing-e.patch b/queue-6.0/libbpf-fix-potential-null-dereference-when-parsing-e.patch
deleted file mode 100644 (file)
index b4fbbbc..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-From 840907e2c3ddba191cce6d1dd2ba876e60d44cdf Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
-Date: Mon, 15 Aug 2022 17:19:26 -0700
-Subject: libbpf: Fix potential NULL dereference when parsing ELF
-
-From: Andrii Nakryiko <andrii@kernel.org>
-
-[ Upstream commit d4e6d684f3bea46a2fc195765c77a3b26bcb080e ]
-
-Fix if condition filtering empty ELF sections to prevent NULL
-dereference.
-
-Fixes: 47ea7417b074 ("libbpf: Skip empty sections in bpf_object__init_global_data_maps")
-Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
-Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
-Acked-by: Hao Luo <haoluo@google.com>
-Link: https://lore.kernel.org/bpf/20220816001929.369487-2-andrii@kernel.org
-Signed-off-by: Sasha Levin <sashal@kernel.org>
----
- tools/lib/bpf/libbpf.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/tools/lib/bpf/libbpf.c b/tools/lib/bpf/libbpf.c
-index 77e3797cf75a..159f60a245c0 100644
---- a/tools/lib/bpf/libbpf.c
-+++ b/tools/lib/bpf/libbpf.c
-@@ -1643,7 +1643,7 @@ static int bpf_object__init_global_data_maps(struct bpf_object *obj)
-               sec_desc = &obj->efile.secs[sec_idx];
-               /* Skip recognized sections with size 0. */
--              if (sec_desc->data && sec_desc->data->d_size == 0)
-+              if (!sec_desc->data || sec_desc->data->d_size == 0)
-                       continue;
-               switch (sec_desc->sec_type) {
--- 
-2.35.1
-
diff --git a/queue-6.0/libbpf-skip-empty-sections-in-bpf_object__init_globa.patch b/queue-6.0/libbpf-skip-empty-sections-in-bpf_object__init_globa.patch
deleted file mode 100644 (file)
index e3e2a13..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-From 53cf72d08dd3e8e7e86b880f4355459ce35bcfe7 Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
-Date: Sun, 31 Jul 2022 17:26:49 -0600
-Subject: libbpf: Skip empty sections in bpf_object__init_global_data_maps
-
-From: James Hilliard <james.hilliard1@gmail.com>
-
-[ Upstream commit 47ea7417b0744324424405fc1207e266053237a9 ]
-
-The GNU assembler generates an empty .bss section. This is a well
-established behavior in GAS that happens in all supported targets.
-
-The LLVM assembler doesn't generate an empty .bss section.
-
-bpftool chokes on the empty .bss section.
-
-Additionally in bpf_object__elf_collect the sec_desc->data is not
-initialized when a section is not recognized. In this case, this
-happens with .comment.
-
-So we must check that sec_desc->data is initialized before checking
-if the size is 0.
-
-Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
-Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
-Acked-by: Jiri Olsa <jolsa@kernel.org>
-Link: https://lore.kernel.org/bpf/20220731232649.4668-1-james.hilliard1@gmail.com
-Stable-dep-of: 3045f42a6432 ("libbpf: Initialize err in probe_map_create")
-Signed-off-by: Sasha Levin <sashal@kernel.org>
----
- tools/lib/bpf/libbpf.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/tools/lib/bpf/libbpf.c b/tools/lib/bpf/libbpf.c
-index 50d41815f431..77e3797cf75a 100644
---- a/tools/lib/bpf/libbpf.c
-+++ b/tools/lib/bpf/libbpf.c
-@@ -1642,6 +1642,10 @@ static int bpf_object__init_global_data_maps(struct bpf_object *obj)
-       for (sec_idx = 1; sec_idx < obj->efile.sec_cnt; sec_idx++) {
-               sec_desc = &obj->efile.secs[sec_idx];
-+              /* Skip recognized sections with size 0. */
-+              if (sec_desc->data && sec_desc->data->d_size == 0)
-+                      continue;
-+
-               switch (sec_desc->sec_type) {
-               case SEC_DATA:
-                       sec_name = elf_sec_name(obj, elf_sec_by_idx(obj, sec_idx));
--- 
-2.35.1
-
index d4b2ef35c345d99db5196b47730a63442e179e24..5ac7ba55d2b0d2611a64ea3549dee1fd9757c5ba 100644 (file)
@@ -225,7 +225,6 @@ nfsd-protect-against-send-buffer-overflow-in-nfsv2-r.patch
 nfsd-fix-handling-of-oversized-nfsv4-compound-reques.patch
 x86-paravirt-add-extra-clobbers-with-zero_call_used_.patch
 m68k-process-bootinfo-records-before-saving-them.patch
-libbpf-skip-empty-sections-in-bpf_object__init_globa.patch
 libbpf-initialize-err-in-probe_map_create.patch
 wifi-rtw88-8822c-extend-supported-probe-request-size.patch
 wifi-rtlwifi-8192de-correct-checking-of-iqk-reload.patch
@@ -235,7 +234,6 @@ bpf-cleanup-check_refcount_ok.patch
 bpf-fix-ref_obj_id-for-dynptr-data-slices-in-verifie.patch
 spi-s3c64xx-correct-dma_chan-pointer-initialization.patch
 leds-lm3601x-don-t-use-mutex-after-it-was-destroyed.patch
-libbpf-fix-potential-null-dereference-when-parsing-e.patch
 tsnep-fix-tsnep_info_tx_time-register-define.patch
 net-prestera-cache-port-state-for-non-phylink-ports-.patch
 bpf-fix-reference-state-management-for-synchronous-c.patch