From 8cb2e198ac8d4b5b4a3cf0f825c5feca2039b162 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=91=E5=BE=AE?= <1067852565@qq.com> Date: Sun, 15 Sep 2024 15:16:58 +0000 Subject: [PATCH] up --- commit_info_output.txt | 55656 +++++++++++++++++++++++++++++++++++++++ data/commit_survey.csv | 15462 +++++++++++ 2 files changed, 71118 insertions(+) diff --git a/commit_info_output.txt b/commit_info_output.txt index da8b506..e41c892 100644 --- a/commit_info_output.txt +++ b/commit_info_output.txt @@ -27472,3 +27472,55659 @@ MPTCP tests. This patch moves it into prog_tests/mptcp.c -------------------- -------------------- Processing Commit ID: 95b88500b97ca8bafc0b9c8e79e9716c2ddc40c6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 95b88500b97ca8bafc0b9c8e79e9716c2ddc40c6 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1714518090 + Commit Message: + selftests/bpf: Add opts argument for __start_server + +This patch adds network_helper_opts parameter for __start_server() +instead of "int protocol" and "int timeout_ms". This not only reduces +the number of parameters + Parent Hashes: 06ebfd11678ad63cfd7021580e13d1582ee6c782 + Refs: but also makes it more flexible. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/127d2f0929980b41f757dcfebe1b667e6bfb43f1.1714014697.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a flexible opts argument for the __start_server function in selftests/bpf.', 'keywords': 'opts, __start_server, selftests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 3e9bc0472b910d4115e16e9c2d684c7757cb6c60 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3e9bc0472b910d4115e16e9c2d684c7757cb6c60 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1714499144 + Commit Message: + Merge branch 'bpf: Add BPF_PROG_TYPE_CGROUP_SKB attach type enforcement in BPF_LINK_CREATE' + +Stanislav Fomichev says: + +==================== +Syzkaller found a case where it's possible to attach cgroup_skb program +to the sockopt hooks. Apparently it's currently possible to do that + Parent Hashes: b867247555c4181bf84eb10b72b176862c29112d 095ddb501b39b7842e5da555915ad89e370b9888 + Refs: +but only when using BPF_LINK_CREATE API. The first patch in the series +has more info on why that happens. +==================== + +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds enforcement for BPF_PROG_TYPE_CGROUP_SKB attach type in BPF_LINK_CREATE API.', 'keywords': 'BPF_LINK_CREATE, attach type, cgroup_skb', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 095ddb501b39b7842e5da555915ad89e370b9888 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 095ddb501b39b7842e5da555915ad89e370b9888 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1714499017 + Commit Message: + selftests/bpf: Add sockopt case to verify prog_type + +Make sure only sockopt programs can be attached to the setsockopt +and getsockopt hooks. + +Signed-off-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240426231621.2716876-4-sdf@google.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: d70b2660e75b85bdaa9d75f9c4224c2f6f89cf23 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added sockopt test case to ensure only sockopt programs attach to setsockopt/getsockopt hooks.', 'keywords': 'sockopt,test case,prog_type', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: d70b2660e75b85bdaa9d75f9c4224c2f6f89cf23 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d70b2660e75b85bdaa9d75f9c4224c2f6f89cf23 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1714499017 + Commit Message: + selftests/bpf: Extend sockopt tests to use BPF_LINK_CREATE + +Run all existing test cases with the attachment created via +BPF_LINK_CREATE. Next commit will add extra test cases to verify +link_create attach_type enforcement. + +Signed-off-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240426231621.2716876-3-sdf@google.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 543576ec15b17c0c93301ac8297333c7b6e84ac7 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extend existing BPF sockopt tests to utilize BPF_LINK_CREATE for attachment.', 'keywords': 'selftests,bpf,BPF_LINK_CREATE', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 543576ec15b17c0c93301ac8297333c7b6e84ac7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 543576ec15b17c0c93301ac8297333c7b6e84ac7 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1714499017 + Commit Message: + bpf: Add BPF_PROG_TYPE_CGROUP_SKB attach type enforcement in BPF_LINK_CREATE + +bpf_prog_attach uses attach_type_to_prog_type to enforce proper +attach type for BPF_PROG_TYPE_CGROUP_SKB. link_create uses +bpf_prog_get and relies on bpf_prog_attach_check_attach_type +to properly verify prog_type <> attach_type association. + +Add missing attach_type enforcement for the link_create case. +Otherwise + Parent Hashes: b867247555c4181bf84eb10b72b176862c29112d + Refs: it's currently possible to attach cgroup_skb prog +types to other cgroup hooks. + +Fixes: af6eea57437a ("bpf: Implement bpf_link-based cgroup BPF program attachment") +Link: https://lore.kernel.org/bpf/0000000000004792a90615a1dde0@google.com/ +Reported-by: syzbot+838346b979830606c854@syzkaller.appspotmail.com +Signed-off-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240426231621.2716876-2-sdf@google.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit enforces attach type verification for cgroup_skb programs in BPF_LINK_CREATE.', 'keywords': 'attach type, cgroup_skb, link_create', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 06ebfd11678ad63cfd7021580e13d1582ee6c782 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 06ebfd11678ad63cfd7021580e13d1582ee6c782 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1714497807 + Commit Message: + Merge branch 'bpf-introduce-kprobe_multi-session-attach' + +Jiri Olsa says: + +==================== +bpf: Introduce kprobe_multi session attach + +hi + Parent Hashes: 05cbc217aafbc631a6c2fab4accf95850cb48358 a3a5113393ccfad2eb23ca091aa6e55b5bd67eb4 + Refs: +adding support to attach kprobe program through kprobe_multi link +in a session mode + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce support for attaching kprobe programs using kprobe_multi in session mode.', 'keywords': 'kprobe, session, attach', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: a3a5113393ccfad2eb23ca091aa6e55b5bd67eb4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a3a5113393ccfad2eb23ca091aa6e55b5bd67eb4 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1714497805 + Commit Message: + selftests/bpf: Add kprobe session cookie test + +Adding kprobe session test that verifies the cookie value +get properly propagated from entry to return program. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-8-jolsa@kernel.org + + Parent Hashes: 0983b1697aefbf69f465f907b934b89bbce467ea + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a kprobe selftest to verify cookie propagation from entry to return program.', 'keywords': 'kprobe,selftest,cookie', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 0983b1697aefbf69f465f907b934b89bbce467ea +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0983b1697aefbf69f465f907b934b89bbce467ea + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1714497781 + Commit Message: + selftests/bpf: Add kprobe session test + +Adding kprobe session test and testing that the entry program +return value controls execution of the return probe program. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-7-jolsa@kernel.org + + Parent Hashes: 7b94965429f2fa32a83e1275c6bf6ed0add08603 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Add test case for kprobe session to verify entry program's control over return probe execution.", 'keywords': 'kprobe,test,session', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 7b94965429f2fa32a83e1275c6bf6ed0add08603 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7b94965429f2fa32a83e1275c6bf6ed0add08603 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1714495553 + Commit Message: + libbpf: Add kprobe session attach type name to attach_type_name + +Adding kprobe session attach type name to attach_type_name + Parent Hashes: 2ca178f02b2f4e523e970894def16282e4adbc39 + Refs: +so libbpf_bpf_attach_type_str returns proper string name for +BPF_TRACE_KPROBE_SESSION attach type. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-6-jolsa@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add kprobe session attach type name to attach_type_name in libbpf.', 'keywords': 'libbpf,kprobe,attach type', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 2ca178f02b2f4e523e970894def16282e4adbc39 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2ca178f02b2f4e523e970894def16282e4adbc39 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1714495553 + Commit Message: + libbpf: Add support for kprobe session attach + +Adding support to attach program in kprobe session mode +with bpf_program__attach_kprobe_multi_opts function. + +Adding session bool to bpf_kprobe_multi_opts struct that allows +to load and attach the bpf program via kprobe session. +the attachment to create kprobe multi session. + +Also adding new program loader section that allows: + SEC("kprobe.session/bpf_fentry_test*") + +and loads/attaches kprobe program as kprobe session. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-5-jolsa@kernel.org + + Parent Hashes: 5c919acef85147886eb2abf86fb147f94680a8b0 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for kprobe session mode attachment to bpf programs with new loader section and options.', 'keywords': 'kprobe, session, attach', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 5c919acef85147886eb2abf86fb147f94680a8b0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5c919acef85147886eb2abf86fb147f94680a8b0 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1714495553 + Commit Message: + bpf: Add support for kprobe session cookie + +Adding support for cookie within the session of kprobe multi +entry and return program. + +The session cookie is u64 value and can be retrieved be new +kfunc bpf_session_cookie + Parent Hashes: adf46d88ae4b2557f7e2e02547a25fb866935711 + Refs: which returns pointer to the cookie +value. The bpf program can use the pointer to store (on entry) +and load (on return) the value. + +The cookie value is implemented via fprobe feature that allows +to share values between entry and return ftrace fprobe callbacks. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-4-jolsa@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds support for a session cookie in kprobe programs using fprobe to share values between entry and return callbacks.', 'keywords': 'kprobe, session cookie, fprobe', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: adf46d88ae4b2557f7e2e02547a25fb866935711 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: adf46d88ae4b2557f7e2e02547a25fb866935711 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1714495553 + Commit Message: + bpf: Add support for kprobe session context + +Adding struct bpf_session_run_ctx object to hold session related +data + Parent Hashes: 535a3692ba7245792e6f23654507865d4293c850 + Refs: which is atm is_return bool and data pointer coming in +following changes. + +Placing bpf_session_run_ctx layer in between bpf_run_ctx and +bpf_kprobe_multi_run_ctx so the session data can be retrieved +regardless of if it's kprobe_multi or uprobe_multi link + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds kprobe session context support by introducing struct bpf_session_run_ctx for session data management.', 'keywords': 'kprobe, session, context', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 535a3692ba7245792e6f23654507865d4293c850 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 535a3692ba7245792e6f23654507865d4293c850 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1714495553 + Commit Message: + bpf: Add support for kprobe session attach + +Adding support to attach bpf program for entry and return probe +of the same function. This is common use case which at the moment +requires to create two kprobe multi links. + +Adding new BPF_TRACE_KPROBE_SESSION attach type that instructs +kernel to attach single link program to both entry and exit probe. + +It's possible to control execution of the bpf program on return +probe simply by returning zero or non zero from the entry bpf +program execution to execute or not the bpf program on return +probe respectively. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-2-jolsa@kernel.org + + Parent Hashes: 05cbc217aafbc631a6c2fab4accf95850cb48358 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for attaching BPF programs to both entry and return kprobe sessions with a single link.', 'keywords': 'kprobe,BPF,attach', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 32a4ca1361d7a51e5003d4af4dfbf570f1b5fd00 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 32a4ca1361d7a51e5003d4af4dfbf570f1b5fd00 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1714490132 + Commit Message: + selftests: net: py: extract tool logic + +The main use of the ip() wrapper over cmd() is that it can parse JSON. +cmd("ip -j link show") will return stdout as a string + Parent Hashes: ff4b2bfa63bd07cca35f6e704dc5035650595950 + Refs: and test has +to call json.loads(). With ip("link show" + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor selftests to improve JSON parsing by extracting tool logic into the ip() wrapper.', 'keywords': 'selftests, JSON, wrapper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 05cbc217aafbc631a6c2fab4accf95850cb48358 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 05cbc217aafbc631a6c2fab4accf95850cb48358 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1714487338 + Commit Message: + selftests/bpf: Drop an unused local variable + +Some copy/paste leftover + Parent Hashes: a891711d0166133ec5120615fcf365d9745d82b2 + Refs: this is never used. + +Fixes: e3d9eac99afd ("selftests/bpf: wq: add bpf_wq_init() checks") +Signed-off-by: Benjamin Tissoires +Signed-off-by: Daniel Borkmann +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/bpf/20240430-bpf-next-v3-3-27afe7f3b17c@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes an unused local variable in selftests/bpf.', 'keywords': 'unused variable, selftests, cleanup', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: a891711d0166133ec5120615fcf365d9745d82b2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a891711d0166133ec5120615fcf365d9745d82b2 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1714487326 + Commit Message: + bpf: Do not walk twice the hash map on free + +If someone stores both a timer and a workqueue in a hash map + Parent Hashes: b98a5c68ccaa94e93b9e898091fe2cf21c1500e6 + Refs: on free + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize hash map free operation to prevent double walking in bpf subsystem.', 'keywords': 'hash map, bpf, optimize', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b98a5c68ccaa94e93b9e898091fe2cf21c1500e6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b98a5c68ccaa94e93b9e898091fe2cf21c1500e6 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1714487313 + Commit Message: + bpf: Do not walk twice the map on free + +If someone stores both a timer and a workqueue in a map + Parent Hashes: 1bba3b3d373dbafae891e7cb06b8c82c8d62aba1 + Refs: on free +we would walk it twice. + +Add a check in array_map_free_timers_wq and free the timers and +workqueues if they are present. + +Fixes: 246331e3f1ea ("bpf: allow struct bpf_wq to be embedded in arraymaps and hashmaps") +Signed-off-by: Benjamin Tissoires +Signed-off-by: Daniel Borkmann +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/bpf/20240430-bpf-next-v3-1-27afe7f3b17c@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Prevent twice traversal of map containing timers and workqueues during free operation in eBPF.', 'keywords': 'map,free,twice', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 1bba3b3d373dbafae891e7cb06b8c82c8d62aba1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1bba3b3d373dbafae891e7cb06b8c82c8d62aba1 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1714434513 + Commit Message: + selftests/bpf: validate nulled-out struct_ops program is handled properly + +Add a selftests validating that it's possible to have some struct_ops +callback set declaratively + Parent Hashes: f973fccd43d34b096077d5d21d051ef75b22a7ea + Refs: then disable it (by setting to NULL) +programmatically. Libbpf should detect that such program should +not be loaded. Otherwise + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added selftests to ensure struct_ops program handles nulled-out callbacks properly in libbpf.', 'keywords': 'selftests, struct_ops, libbpf', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f973fccd43d34b096077d5d21d051ef75b22a7ea +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f973fccd43d34b096077d5d21d051ef75b22a7ea + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1714434366 + Commit Message: + libbpf: handle nulled-out program in struct_ops correctly + +If struct_ops has one of program callbacks set declaratively and host +kernel is old and doesn't support this callback + Parent Hashes: cfd3bfe9507b4aa39f7e86772e60b50b799e490e + Refs: libbpf will allow to +load such struct_ops as long as that callback was explicitly nulled-out +(presumably through skeleton). This is all working correctly + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Ensure libbpf handles nulled-out program callbacks in struct_ops for compatibility with older kernels.', 'keywords': 'libbpf,struct_ops,nulled-out', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cfd3bfe9507b4aa39f7e86772e60b50b799e490e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cfd3bfe9507b4aa39f7e86772e60b50b799e490e + Author Name: Dmitrii Bundin + Author Email: dmitrii.bundin.a@gmail.com + Commit Date: 1714433287 + Commit Message: + bpf: Include linux/types.h for u32 + +Inclusion of the header linux/btf_ids.h relies on indirect inclusion of +the header linux/types.h. Including it directly on the top level helps +to avoid potential problems if linux/types.h hasn't been included +before. + +The main motivation to introduce this it is to avoid similar problems that +have shown up in the bpftool where GNU libc indirectly pulls +linux/types.h causing compile error of the form: + + error: unknown type name 'u32' + u32 cnt; + ^~~ + +The bpftool compile error was fixed in +62248b22d01e ("tools/resolve_btfids: fix build with musl libc"). + +Signed-off-by: Dmitrii Bundin +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240420042457.3198883-1-dmitrii.bundin.a@gmail.com + + Parent Hashes: 789d9a53d2f633317c64de3eba0940f31a8f0cd6 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Directly include linux/types.h to prevent build errors related to missing u32 type in bpftool.', 'keywords': 'linux types, bpftool, u32', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 25927d0a1bec5091d371693c9fdd9640478837de +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 25927d0a1bec5091d371693c9fdd9640478837de + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1714432635 + Commit Message: + selftests/bpf: Free strdup memory in veristat + +The strdup() function returns a pointer to a new string which is a +duplicate of the string "input". Memory for the new string is obtained +with malloc() + Parent Hashes: 237c522c1d5d19e8d3057a38ce690c753020c7d1 + Refs: and need to be freed with free(). + +This patch adds these missing "free(input)" in parse_stats() to avoid +memory leak in veristat.c. + +Signed-off-by: Geliang Tang +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/ded44f8865cd7f337f52fc5fb0a5fbed7d6bd641.1714374022.git.tanggeliang@kylinos.cn + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes a memory leak by freeing strdup memory in the selftests for veristat.', 'keywords': 'memory, leak, free', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 237c522c1d5d19e8d3057a38ce690c753020c7d1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 237c522c1d5d19e8d3057a38ce690c753020c7d1 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1714432635 + Commit Message: + selftests/bpf: Free strdup memory in test_sockmap + +The strdup() function returns a pointer to a new string which is a +duplicate of the string "ptr". Memory for the new string is obtained +with malloc() + Parent Hashes: 19468ed51488dae19254e8a67c75d583b05fa5e3 + Refs: and need to be freed with free(). + +This patch adds these missing "free(ptr)" in check_whitelist() and +check_blacklist() to avoid memory leaks in test_sockmap.c. + +Signed-off-by: Geliang Tang +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/b76f2f4c550aebe4ab8ea73d23c4cbe4f06ea996.1714374022.git.tanggeliang@kylinos.cn + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes memory leaks by adding missing free calls in test_sockmap.c for strdup allocations.', 'keywords': 'memory leak, strdup, test_sockmap', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 19468ed51488dae19254e8a67c75d583b05fa5e3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 19468ed51488dae19254e8a67c75d583b05fa5e3 + Author Name: Viktor Malik + Author Email: vmalik@redhat.com + Commit Date: 1714432451 + Commit Message: + selftests/bpf: Run cgroup1_hierarchy test in own mount namespace + +The cgroup1_hierarchy test uses setup_classid_environment to setup +cgroupv1 environment. The problem is that the environment is set in +/sys/fs/cgroup and therefore + Parent Hashes: a3034872cd90a6881ad4e10ca6d30e1215a99ada + Refs: if not run under an own mount namespace + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies the cgroup1_hierarchy test to run in its own mount namespace to avoid environment setup conflicts.', 'keywords': 'cgroup1_hierarchy,mount namespace,environment', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a3034872cd90a6881ad4e10ca6d30e1215a99ada +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a3034872cd90a6881ad4e10ca6d30e1215a99ada + Author Name: Andy Shevchenko + Author Email: andriy.shevchenko@linux.intel.com + Commit Date: 1714432394 + Commit Message: + bpf: Switch to krealloc_array() + +Let the krealloc_array() copy the original data and +check for a multiplication overflow. + +Signed-off-by: Andy Shevchenko +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240429120005.3539116-1-andriy.shevchenko@linux.intel.com + + Parent Hashes: cb01621b6d91567ac74c8b95e4db731febdbdec3 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Switches to using krealloc_array() for memory allocation with overflow check in eBPF.', 'keywords': 'krealloc_array,memory overflow', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cb01621b6d91567ac74c8b95e4db731febdbdec3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cb01621b6d91567ac74c8b95e4db731febdbdec3 + Author Name: Andy Shevchenko + Author Email: andriy.shevchenko@linux.intel.com + Commit Date: 1714432323 + Commit Message: + bpf: Use struct_size() + +Use struct_size() instead of hand writing it. +This is less verbose and more robust. + +Signed-off-by: Andy Shevchenko +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240429121323.3818497-1-andriy.shevchenko@linux.intel.com + + Parent Hashes: 397658ddc88ce3c21d2aa3bed8e15fc69dfec946 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor code to use struct_size() for improved code robustness and clarity.', 'keywords': 'struct_size, robust, refactor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 397658ddc88ce3c21d2aa3bed8e15fc69dfec946 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 397658ddc88ce3c21d2aa3bed8e15fc69dfec946 + Author Name: Tao Chen + Author Email: chen.dylane@gmail.com + Commit Date: 1714432203 + Commit Message: + samples/bpf: Add valid info for VMLINUX_BTF + +When I use the command 'make M=samples/bpf' to compile samples/bpf code +in ubuntu 22.04 + Parent Hashes: 0db63c0b86e981a1e97d2596d64ceceba1a5470e + Refs: the error info occured: +Cannot find a vmlinux for VMLINUX_BTF at any of " /home/ubuntu/code/linux/vmlinux" + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add valid information to VMLINUX_BTF in samples/bpf for compile error resolution.', 'keywords': 'samples,bpf,VMLINUX_BTF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 0db63c0b86e981a1e97d2596d64ceceba1a5470e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0db63c0b86e981a1e97d2596d64ceceba1a5470e + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1714425401 + Commit Message: + bpf: Fix verifier assumptions about socket->sk + +The verifier assumes that 'sk' field in 'struct socket' is valid +and non-NULL when 'socket' pointer itself is trusted and non-NULL. +That may not be the case when socket was just created and +passed to LSM socket_accept hook. +Fix this verifier assumption and adjust tests. + +Reported-by: Liam Wisehart +Acked-by: Kumar Kartikeya Dwivedi +Fixes: 6fcd486b3a0a ("bpf: Refactor RCU enforcement in the verifier.") +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/r/20240427002544.68803-1-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 89de2db19317fb89a6e9163f33c3a7b23ee75a18 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Fix verifier assumptions regarding non-NULL 'sk' field in sockets when accepted by LSM hooks.", 'keywords': 'verifier, socket, non-NULL', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['socket like programs', 'LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: 89de2db19317fb89a6e9163f33c3a7b23ee75a18 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 89de2db19317fb89a6e9163f33c3a7b23ee75a18 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1714421539 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-04-29 + +We've added 147 non-merge commits during the last 32 day(s) which contain +a total of 158 files changed + Parent Hashes: b3f1a08fcf0dd58d99b14b9f8fbd1929f188b746 07801a24e2f18624cd2400ce15f14569eb416c9a + Refs: 9400 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge update includes 147 non-merge commits with multiple file changes from bpf-next branch.', 'keywords': 'merge, commits, bpf-next', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 07801a24e2f18624cd2400ce15f14569eb416c9a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 07801a24e2f18624cd2400ce15f14569eb416c9a + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1714384482 + Commit Message: + bpf + Parent Hashes: 6e25bcf06af0341691f7058e17e04800f6a19e26 + Refs: docs: Clarify PC use in instruction-set.rst + +This patch elaborates on the use of PC by expanding the PC acronym + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit clarifies the use of the PC acronym in the bpf instruction set documentation.', 'keywords': 'PC,documentation,clarity', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 8524d71cebfa6ddcfbb89f0fe0e174c8d0477c6d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8524d71cebfa6ddcfbb89f0fe0e174c8d0477c6d + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1714180390 + Commit Message: + perf build: Pretend scandirat is missing with msan + +Memory sanitizer lacks an interceptor for scandirat + Parent Hashes: e101a05f79fd4ee3e89d2f3fb716493c33a33708 + Refs: reporting all +memory it allocates as uninitialized. Memory sanitizer has a scandir +interceptor so use the fallback function in this case. This allows +'perf test' to run under memory sanitizer. + +Additional notes from Ian on running in this mode: + +Note + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies the perf build to use a fallback function for scandirat with memory sanitizer.', 'keywords': 'perf, msan, scandirat', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b2ff42c6d3abc26ef0f395fe9ee8c64364fbaa22 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b2ff42c6d3abc26ef0f395fe9ee8c64364fbaa22 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1714178213 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-04-26 + +We've added 12 non-merge commits during the last 22 day(s) which contain +a total of 14 files changed + Parent Hashes: 6a30653b604aaad1bf0f2e74b068ceb8b6fc7aea a86538a2efb826b9a62c7b41e0499948b04aec7d + Refs: 168 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merged bpf-related changes from the 'for-netdev' tag into the main branch involving 12 non-merge commits.", 'keywords': 'bpf, netdev, merge', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: a86538a2efb826b9a62c7b41e0499948b04aec7d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a86538a2efb826b9a62c7b41e0499948b04aec7d + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1714149919 + Commit Message: + Merge branch 'bpf-prevent-userspace-memory-access' + +Puranjay Mohan says: + +==================== +bpf: prevent userspace memory access + +V5: https://lore.kernel.org/bpf/20240324185356.59111-1-puranjay12@gmail.com/ +Changes in V6: +- Disable the verifier's instrumentation in x86-64 and update the JIT to + take care of vsyscall page in addition to userspace addresses. +- Update bpf_testmod to test for vsyscall addresses. + +V4: https://lore.kernel.org/bpf/20240321124640.8870-1-puranjay12@gmail.com/ +Changes in V5: +- Use TASK_SIZE_MAX + PAGE_SIZE + Parent Hashes: 5bcf0dcbf9066348058b88a510c57f70f384c92c 7cd6750d9a560fa69bb640a7280479d6a67999ad + Refs: VSYSCALL_ADDR as userspace boundary in + x86-64 JIT. +- Added Acked-by: Ilya Leoshkevich + +V3: https://lore.kernel.org/bpf/20240321120842.78983-1-puranjay12@gmail.com/ +Changes in V4: +- Disable this feature on architectures that don't define + CONFIG_ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE. +- By doing the above + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit prevents userspace memory access in eBPF by updating the verifier and JIT on x86-64.', 'keywords': 'userspace memory access, verifier, JIT', 'commit_classification': "It's a security fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7cd6750d9a560fa69bb640a7280479d6a67999ad +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7cd6750d9a560fa69bb640a7280479d6a67999ad + Author Name: Puranjay Mohan + Author Email: puranjay@kernel.org + Commit Date: 1714149918 + Commit Message: + selftests/bpf: Test PROBE_MEM of VSYSCALL_ADDR on x86-64 + +The vsyscall is a legacy API for fast execution of system calls. It maps +a page at address VSYSCALL_ADDR into the userspace program. This address +is in the top 10MB of the address space: + +ffffffffff600000 - ffffffffff600fff | 4 kB | legacy vsyscall ABI + +The last commit fixes the x86-64 BPF JIT to skip accessing addresses in +this memory region. Add this address to bpf_testmod_return_ptr() so we +can make sure that it is fixed. + +After this change and without the previous commit + Parent Hashes: b599d7d26d6ad1fc9975218574bc2ca6d0293cfd + Refs: subprogs_extable +selftest will crash the kernel. + +Signed-off-by: Puranjay Mohan +Link: https://lore.kernel.org/r/20240424100210.11982-4-puranjay@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Test PROBE_MEM of VSYSCALL_ADDR in BPF selftests on x86-64 architecture.', 'keywords': 'PROBE_MEM, VSYSCALL_ADDR, x86-64', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's an experimental feature that doesn't fit into existing categories."]} +-------------------- +-------------------- +Processing Commit ID: b599d7d26d6ad1fc9975218574bc2ca6d0293cfd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b599d7d26d6ad1fc9975218574bc2ca6d0293cfd + Author Name: Puranjay Mohan + Author Email: puranjay@kernel.org + Commit Date: 1714149918 + Commit Message: + bpf + Parent Hashes: 66e13b615a0ce76b785d780ecc9776ba71983629 + Refs: x86: Fix PROBE_MEM runtime load check + +When a load is marked PROBE_MEM - e.g. due to PTR_UNTRUSTED access - the +address being loaded from is not necessarily valid. The BPF jit sets up +exception handlers for each such load which catch page faults and 0 out +the destination register. + +If the address for the load is outside kernel address space + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix PROBE_MEM runtime load check and exception handling in the BPF JIT compiler for untrusted pointer accesses.', 'keywords': 'PROBE_MEM,BPF JIT,exception', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 66e13b615a0ce76b785d780ecc9776ba71983629 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 66e13b615a0ce76b785d780ecc9776ba71983629 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1714149918 + Commit Message: + bpf: verifier: prevent userspace memory access + +With BPF_PROBE_MEM + Parent Hashes: 5bcf0dcbf9066348058b88a510c57f70f384c92c + Refs: BPF allows de-referencing an untrusted pointer. To +thwart invalid memory accesses + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves memory access safety in BPF by using BPF_PROBE_MEM to prevent userspace memory access issues.', 'keywords': 'verifier, memory, prevention', 'commit_classification': "It's a security fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6e25bcf06af0341691f7058e17e04800f6a19e26 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6e25bcf06af0341691f7058e17e04800f6a19e26 + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1714144204 + Commit Message: + bpf_helpers.h: Define bpf_tail_call_static when building with GCC + +The definition of bpf_tail_call_static in tools/lib/bpf/bpf_helpers.h +is guarded by a preprocessor check to assure that clang is recent +enough to support it. This patch updates the guard so the function is +compiled when using GCC 13 or later as well. + +Tested in bpf-next master. No regressions. + +Signed-off-by: Jose E. Marchesi +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240426145158.14409-1-jose.marchesi@oracle.com + + Parent Hashes: e51b907d40329d4b4517a155e0bc0bf593d6767d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support for bpf_tail_call_static function in GCC 13 or later.', 'keywords': 'bpf_tail_call_static,GCC,compile', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 15fd021bc4270273d8f4b7f58fdda8a16214a377 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 15fd021bc4270273d8f4b7f58fdda8a16214a377 + Author Name: Song Yoong Siang + Author Email: yoong.siang.song@intel.com + Commit Date: 1714137839 + Commit Message: + igc: Add Tx hardware timestamp request for AF_XDP zero-copy packet + +This patch adds support to per-packet Tx hardware timestamp request to +AF_XDP zero-copy packet via XDP Tx metadata framework. Please note that +user needs to enable Tx HW timestamp capability via igc_ioctl() with +SIOCSHWTSTAMP cmd before sending xsk Tx hardware timestamp request. + +Same as implementation in RX timestamp XDP hints kfunc metadata + Parent Hashes: dba86b7d8778102998a6a2989f6a2d935efc6d47 + Refs: Timer 0 +(adjustable clock) is used in xsk Tx hardware timestamp. i225/i226 have +four sets of timestamping registers. *skb and *xsk_tx_buffer pointers +are used to indicate whether the timestamping register is already occupied. + +Furthermore + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds Tx hardware timestamp support for AF_XDP zero-copy packets using XDP Tx metadata framework.', 'keywords': 'Tx hardware timestamp, AF_XDP, zero-copy', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: e51b907d40329d4b4517a155e0bc0bf593d6767d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e51b907d40329d4b4517a155e0bc0bf593d6767d + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1714097721 + Commit Message: + bpf + Parent Hashes: 876373985efb87844ca7cacd2d1d3ef4c9398c9c + Refs: docs: Add introduction for use in the ISA Internet Draft + +The proposed intro paragraph text is derived from the first paragraph +of the IETF BPF WG charter at https://datatracker.ietf.org/wg/bpf/about/ + +Signed-off-by: Dave Thaler +Acked-by: David Vernet +Link: https://lore.kernel.org/r/20240422190942.24658-1-dthaler1968@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add introduction text for BPF ISA in the related Internet Draft documentation.', 'keywords': 'BPF, ISA, documentation', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 876373985efb87844ca7cacd2d1d3ef4c9398c9c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 876373985efb87844ca7cacd2d1d3ef4c9398c9c + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1714079345 + Commit Message: + Merge branch 'bpf: add mrtt and srtt as ctx->args for BPF_SOCK_OPS_RTT_CB' + +Philo Lu says: + +==================== +These provides more information about tcp RTT estimation. The selftest for +BPF_SOCK_OPS_RTT_CB is extended for the added args. + +changelogs +-> v1: +- extend rtt selftest for added args (suggested by Stanislav) +==================== + +Signed-off-by: Martin KaFai Lau + + Parent Hashes: a311c3f9c342fc12e6c8a27e22c81955ab2a336c 7eb4f66b38069eec9c86c9d115f0bba1cf73ef2c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge branch to add mrtt and srtt as ctx->args for BPF_SOCK_OPS_RTT_CB with extended selftests.', 'keywords': 'mrtt, srtt, BPF_SOCK_OPS_RTT_CB', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 7eb4f66b38069eec9c86c9d115f0bba1cf73ef2c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7eb4f66b38069eec9c86c9d115f0bba1cf73ef2c + Author Name: Philo Lu + Author Email: lulie@linux.alibaba.com + Commit Date: 1714079345 + Commit Message: + selftests/bpf: extend BPF_SOCK_OPS_RTT_CB test for srtt and mrtt_us + +Because srtt and mrtt_us are added as args in bpf_sock_ops at +BPF_SOCK_OPS_RTT_CB + Parent Hashes: 48e2cd3e3dcfe04f212df4fb189fa04c2a87b980 + Refs: a simple check is added to make sure they are both +non-zero. + +$ ./test_progs -t tcp_rtt + #373 tcp_rtt:OK + Summary: 1/0 PASSED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extend BPF_SOCK_OPS_RTT_CB test to include checks for non-zero srtt and mrtt_us arguments.', 'keywords': 'BPF_SOCK_OPS_RTT_CB,srtt,mrtt_us', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 48e2cd3e3dcfe04f212df4fb189fa04c2a87b980 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 48e2cd3e3dcfe04f212df4fb189fa04c2a87b980 + Author Name: Philo Lu + Author Email: lulie@linux.alibaba.com + Commit Date: 1714079345 + Commit Message: + bpf: add mrtt and srtt as BPF_SOCK_OPS_RTT_CB args + +Two important arguments in RTT estimation + Parent Hashes: a311c3f9c342fc12e6c8a27e22c81955ab2a336c + Refs: mrtt and srtt + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new arguments mrtt and srtt to BPF_SOCK_OPS_RTT_CB for RTT estimation.', 'keywords': 'mrtt,srtt,RTT', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: a311c3f9c342fc12e6c8a27e22c81955ab2a336c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a311c3f9c342fc12e6c8a27e22c81955ab2a336c + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1714074163 + Commit Message: + Merge branch 'check-bpf_dummy_struct_ops-program-params-for-test-runs' + +Eduard Zingerman says: + +==================== +check bpf_dummy_struct_ops program params for test runs + +When doing BPF_PROG_TEST_RUN for bpf_dummy_struct_ops programs + Parent Hashes: 638a485c4996be1d38303cf25ea8d12dfd16011b 6a2d30d3c5bf9f088dcfd5f3746b04d84f2fab83 + Refs: +execution should be rejected when NULL is passed for non-nullable +params + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Ensure BPF_PROG_TEST_RUN rejects NULL non-nullable parameters for bpf_dummy_struct_ops programs.', 'keywords': 'BPF_PROG_TEST_RUN,NULL,params', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6a2d30d3c5bf9f088dcfd5f3746b04d84f2fab83 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6a2d30d3c5bf9f088dcfd5f3746b04d84f2fab83 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1714074163 + Commit Message: + selftests/bpf: dummy_st_ops should reject 0 for non-nullable params + +Check if BPF_PROG_TEST_RUN for bpf_dummy_struct_ops programs +rejects execution if NULL is passed for non-nullable parameter. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240424012821.595216-6-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 980ca8ceeae69ddf362870ea9183f389ae26324a + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Ensure bpf_dummy_struct_ops programs reject null parameters in BPF_PROG_TEST_RUN tests.', 'keywords': 'selftests,bpf,rejects', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 980ca8ceeae69ddf362870ea9183f389ae26324a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 980ca8ceeae69ddf362870ea9183f389ae26324a + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1714074163 + Commit Message: + bpf: check bpf_dummy_struct_ops program params for test runs + +When doing BPF_PROG_TEST_RUN for bpf_dummy_struct_ops programs + Parent Hashes: f612210d456a0b969a0adca91e68dbea0e0ea301 + Refs: +reject execution when NULL is passed for non-nullable params. +For programs with non-nullable params verifier assumes that +such params are never NULL and thus might optimize out NULL checks. + +Suggested-by: Kui-Feng Lee +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240424012821.595216-5-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reject BPF_PROG_TEST_RUN for bpf_dummy_struct_ops with nullable params to prevent incorrect verifier optimizations.', 'keywords': 'bpf_dummy_struct_ops, BPF_PROG_TEST_RUN, nullable', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f612210d456a0b969a0adca91e68dbea0e0ea301 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f612210d456a0b969a0adca91e68dbea0e0ea301 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1714074163 + Commit Message: + selftests/bpf: do not pass NULL for non-nullable params in dummy_st_ops + +dummy_st_ops.test_2 and dummy_st_ops.test_sleepable do not have their +'state' parameter marked as nullable. Update dummy_st_ops.c to avoid +passing NULL for such parameters + Parent Hashes: 3b3b84aacb4420226576c9732e7b539ca7b79633 + Refs: as the next patch would allow kernel +to enforce this restriction. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240424012821.595216-4-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Correct selftests/bpf by avoiding NULL parameters for non-nullable 'state' params in dummy_st_ops functions.", 'keywords': 'selftests,bpf,dummy_st_ops', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 3b3b84aacb4420226576c9732e7b539ca7b79633 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3b3b84aacb4420226576c9732e7b539ca7b79633 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1714074163 + Commit Message: + selftests/bpf: adjust dummy_st_ops_success to detect additional error + +As reported by Jose E. Marchesi in off-list discussion + Parent Hashes: 1479eaff1f16983d8fda7c5a08a586c21891087d + Refs: GCC and LLVM +generate slightly different code for dummy_st_ops_success/test_1(): + + SEC("struct_ops/test_1") + int BPF_PROG(test_1 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adjusts selftests in bpf to detect additional error cases highlighted by Jose E. Marchesi.', 'keywords': 'selftests,bpf,error', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 1479eaff1f16983d8fda7c5a08a586c21891087d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1479eaff1f16983d8fda7c5a08a586c21891087d + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1714074163 + Commit Message: + bpf: mark bpf_dummy_struct_ops.test_1 parameter as nullable + +Test case dummy_st_ops/dummy_init_ret_value passes NULL as the first +parameter of the test_1() function. Mark this parameter as nullable to +make verifier aware of such possibility. +Otherwise + Parent Hashes: 638a485c4996be1d38303cf25ea8d12dfd16011b + Refs: NULL check in the test_1() code: + + SEC("struct_ops/test_1") + int BPF_PROG(test_1 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit marks the bpf_dummy_struct_ops.test_1 parameter as nullable to improve verifier awareness.', 'keywords': 'nullable,test_1,verifier', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 638a485c4996be1d38303cf25ea8d12dfd16011b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 638a485c4996be1d38303cf25ea8d12dfd16011b + Author Name: Andrea Righi + Author Email: andrea.righi@canonical.com + Commit Date: 1714070764 + Commit Message: + selftests/bpf: Add ring_buffer__consume_n test. + +Add a testcase for the ring_buffer__consume_n() API. + +The test produces multiple samples in a ring buffer + Parent Hashes: 8ec3bf5c31d2a59c320ff59397f6ac362341d9d7 + Refs: using a +sys_getpid() fentry prog + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test case for ring_buffer__consume_n in selftests/bpf.', 'keywords': 'testcase, ring_buffer, API', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 8ec3bf5c31d2a59c320ff59397f6ac362341d9d7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8ec3bf5c31d2a59c320ff59397f6ac362341d9d7 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1714067320 + Commit Message: + bpf: Add bpf_guard_preempt() convenience macro + +Add bpf_guard_preempt() macro that uses newly introduced +bpf_preempt_disable/enable() kfuncs to guard a critical section. + +Signed-off-by: Alexei Starovoitov +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/r/20240424225529.16782-1-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 52578f7f53ff8fe3a8f6f3bc8b5956615c07a16e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce bpf_guard_preempt() macro for critical section protection using new bpf_preempt_disable/enable() kfuncs.', 'keywords': 'bpf, macro, preempt', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: caf93883f623ebd29989e3c35423f386ea4a41bb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: caf93883f623ebd29989e3c35423f386ea4a41bb + Author Name: David S. Miller + Author Email: davem@davemloft.net + Commit Date: 1714031532 + Commit Message: + Merge branch 'tcp-trace-next' + +Philo Lu says: + +==================== +tcp: update TCPCB_EVER_RETRANS after trace_tcp_retransmit_skb() + +Move TCPCB_EVER_RETRANS updating after the trace_tcp_retransmit_skb() +in __tcp_retransmit_skb() + Parent Hashes: d806871612712f1d08eb7ce81efd4ca81ca5bca1 2bf90a57f0e682872c5cfb66ffa45e432bb9c7ae + Refs: and then we are aware of whether the skb has +ever been retransmitted in this tracepoint. This can be used + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates TCPCB_EVER_RETRANS after trace_tcp_retransmit_skb in TCP retransmission handling.', 'keywords': 'TCP,tracepoint,retransmission', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 14b5fb2145caeb909a1cd57d9cd5e0c3cd005642 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 14b5fb2145caeb909a1cd57d9cd5e0c3cd005642 + Author Name: Philo Lu + Author Email: lulie@linux.alibaba.com + Commit Date: 1714031532 + Commit Message: + tcp: move tcp_skb_cb->sacked flags to enum + +Move the flag definitions for tcp_skb_cb->sacked into a new enum named +tcp_skb_cb_sacked_flags + Parent Hashes: d806871612712f1d08eb7ce81efd4ca81ca5bca1 + Refs: then we can get access to them in bpf via +vmlinux.h + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Move tcp_skb_cb->sacked flags to a new enum for better access via vmlinux.h in BPF.', 'keywords': 'tcp,flags,enum', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d806871612712f1d08eb7ce81efd4ca81ca5bca1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d806871612712f1d08eb7ce81efd4ca81ca5bca1 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1714014947 + Commit Message: + Merge branch 'selftests-net-extract-bpf-building-logic-from-the-makefile' + +Jakub Kicinski says: + +==================== +selftests: net: extract BPF building logic from the Makefile + +This has been sitting in my tree for a while. I will soon add YNL/libynl +support for networking selftests. This prompted a small cleanup of +the selftest makefile for net/. We don't want to be piling logic +for each library in there. YNL will get its own .mk file which can +be included. Do the same for the BPF building section + Parent Hashes: 2fa809b90617817fec2802c7cfaeb2c66fd04c2b 3f584c211d8cc049848620472aaec1bebd8ddaae + Refs: already. + +No funcional changes here + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit extracts BPF building logic from the network selftests Makefile for better organization.', 'keywords': 'selftests, BPF, Makefile', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6b88ce902f0bdcb3694a6ceddc8b3d0b40db3772 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6b88ce902f0bdcb3694a6ceddc8b3d0b40db3772 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1714014945 + Commit Message: + selftests: net: name bpf objects consistently and simplify Makefile + +The BPF sources moved with bpf_offload.py have a suffix of .bpf.c +which seems to be useful convention. Rename the 2 other BPF sources +we had. Use wildcard in the Makefile + Parent Hashes: 2fa809b90617817fec2802c7cfaeb2c66fd04c2b + Refs: since we can match all those +files easily now. + +Link: https://lore.kernel.org/r/20240423183542.3807234-2-kuba@kernel.org +Signed-off-by: Jakub Kicinski + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit renames BPF source files and simplifies the Makefile in the selftests for net.', 'keywords': 'rename, Makefile, selftests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8000e627dc98efc44658af6150fd81c62d936b1b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8000e627dc98efc44658af6150fd81c62d936b1b + Author Name: Vadim Fedorenko + Author Email: vadfed@meta.com + Commit Date: 1713999670 + Commit Message: + selftests: bpf: crypto: add benchmark for crypto functions + +Some simple benchmarks are added to understand the baseline of +performance. + +Signed-off-by: Vadim Fedorenko +Link: https://lore.kernel.org/r/20240422225024.2847039-5-vadfed@meta.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 91541ab192fc7f573e6c711ba9c2ae22a299c408 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added benchmark tests for eBPF crypto functions to assess baseline performance.', 'keywords': 'benchmark, crypto functions, performance', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 91541ab192fc7f573e6c711ba9c2ae22a299c408 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 91541ab192fc7f573e6c711ba9c2ae22a299c408 + Author Name: Vadim Fedorenko + Author Email: vadfed@meta.com + Commit Date: 1713999670 + Commit Message: + selftests: bpf: crypto skcipher algo selftests + +Add simple tc hook selftests to show the way to work with new crypto +BPF API. Some tricky dynptr initialization is used to provide empty iv +dynptr. Simple AES-ECB algo is used to demonstrate encryption and +decryption of fixed size buffers. + +Signed-off-by: Vadim Fedorenko +Link: https://lore.kernel.org/r/20240422225024.2847039-4-vadfed@meta.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: fda4f71282b21a8cf230b656781efb0a41371fd4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for tc hook using the new crypto BPF API with AES-ECB encryption demonstration.', 'keywords': 'selftests, crypto, AES', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: fda4f71282b21a8cf230b656781efb0a41371fd4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fda4f71282b21a8cf230b656781efb0a41371fd4 + Author Name: Vadim Fedorenko + Author Email: vadfed@meta.com + Commit Date: 1713999670 + Commit Message: + bpf: crypto: add skcipher to bpf crypto + +Implement skcipher crypto in BPF crypto framework. + +Signed-off-by: Vadim Fedorenko +Acked-by: Herbert Xu +Link: https://lore.kernel.org/r/20240422225024.2847039-3-vadfed@meta.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 3e1c6f35409f9e447bf37f64840f5b65576bfb78 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add skcipher cryptographic support to BPF crypto framework.', 'keywords': 'skcipher,crypto,BPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3e1c6f35409f9e447bf37f64840f5b65576bfb78 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3e1c6f35409f9e447bf37f64840f5b65576bfb78 + Author Name: Vadim Fedorenko + Author Email: vadfed@meta.com + Commit Date: 1713999670 + Commit Message: + bpf: make common crypto API for TC/XDP programs + +Add crypto API support to BPF to be able to decrypt or encrypt packets +in TC/XDP BPF programs. Special care should be taken for initialization +part of crypto algo because crypto alloc) doesn't work with preemtion +disabled + Parent Hashes: 95c07d58250ca3ed01855c20be568cf04e15382f + Refs: it can be run only in sleepable BPF program. Also async crypto +is not supported because of the very same issue - TC/XDP BPF programs +are not sleepable. + +Signed-off-by: Vadim Fedorenko +Link: https://lore.kernel.org/r/20240422225024.2847039-2-vadfed@meta.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce crypto API to enable packet encryption and decryption in TC/XDP BPF programs.', 'keywords': 'crypto,API,TC/XDP', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['xdp like programs', 'tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 95c07d58250ca3ed01855c20be568cf04e15382f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 95c07d58250ca3ed01855c20be568cf04e15382f + Author Name: Haiyue Wang + Author Email: haiyue.wang@intel.com + Commit Date: 1713999506 + Commit Message: + bpf: update the comment for BTF_FIELDS_MAX + +The commit d56b63cf0c0f ("bpf: add support for bpf_wq user type") +changes the fields support number to 11 + Parent Hashes: 82e38a505c9868e784ec31e743fd8a9fa5ca1084 + Refs: just sync the comment. + +Signed-off-by: Haiyue Wang +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240424054526.8031-1-haiyue.wang@intel.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update comment for BTF_FIELDS_MAX to reflect support for 11 fields.', 'keywords': 'BTF_FIELDS_MAX,comment,update', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 82e38a505c9868e784ec31e743fd8a9fa5ca1084 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 82e38a505c9868e784ec31e743fd8a9fa5ca1084 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1713992705 + Commit Message: + selftests/bpf: Fix wq test. + +The wq test was missing destroy(skel) part which was causing bpf progs to stay +loaded. That was causing test_progs to complain with +"Failed to unload bpf_testmod.ko from kernel: -11" message + Parent Hashes: 5305b378b351dc5fd55f5f1f37ef362ae0e11d7e + Refs: but adding +destroy() wasn't enough + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes wq test by adding missing destroy(skel) to unload BPF programs correctly.', 'keywords': 'wq test, destroy, unload', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e4c68bbaff1153e8730c16f566c78a25b2046372 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e4c68bbaff1153e8730c16f566c78a25b2046372 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713989549 + Commit Message: + selftests/bpf: Use make_sockaddr in test_sock_addr + +This patch uses public helper make_sockaddr() exported in network_helpers.h +instead of the local defined function mk_sockaddr() in test_sock_addr.c. +This can avoid duplicate code. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/1473e189d6ca1a3925de4c5354d191a14eca0f3f.1713868264.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + Parent Hashes: c6c40798428180516df80ce89da7bbfe1f6a828a + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactored test_sock_addr to use make_sockaddr from network_helpers.h, reducing code duplication.', 'keywords': 'selftests,bpf,make_sockaddr', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: c6c40798428180516df80ce89da7bbfe1f6a828a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c6c40798428180516df80ce89da7bbfe1f6a828a + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713989548 + Commit Message: + selftests/bpf: Use connect_to_addr in test_sock_addr + +This patch uses public network helper connect_to_addr() exported in +network_helpers.h instead of the local defined function connect_to_server() +in test_sock_addr.c. This can avoid duplicate code. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/f263797712d93fdfaf2943585c5dfae56714a00b.1713868264.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + Parent Hashes: e1cdb70d075e02b1f410b8446a8ff959fa15f0ee + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replace local function connect_to_server with public helper connect_to_addr in bpf selftests.', 'keywords': 'selftests,bpf,connect_to_addr', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: e1cdb70d075e02b1f410b8446a8ff959fa15f0ee +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e1cdb70d075e02b1f410b8446a8ff959fa15f0ee + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713989548 + Commit Message: + selftests/bpf: Use start_server_addr in test_sock_addr + +Include network_helpers.h in test_sock_addr.c + Parent Hashes: 285cffbaa8e6056c2595e07e3a320e55c71870ad + Refs: use the newly added public +helper start_server_addr() instead of the local defined function +start_server(). This can avoid duplicate code. + +In order to use functions defined in network_helpers.c in test_sock_addr.c + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor test_sock_addr to use the start_server_addr helper from network_helpers for cleaner code.', 'keywords': 'selftests,bpf,network_helpers', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 285cffbaa8e6056c2595e07e3a320e55c71870ad +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 285cffbaa8e6056c2595e07e3a320e55c71870ad + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713989548 + Commit Message: + selftests/bpf: Use log_err in open_netns/close_netns + +ASSERT helpers defined in test_progs.h shouldn't be used in public +functions like open_netns() and close_netns(). Since they depend on +test__fail() which defined in test_progs.c. Public functions may be +used not only in test_progs.c + Parent Hashes: 151f7442436658ee84076681d8f52e987fe147ea + Refs: but in other tests like test_sock_addr.c +in the next commit. + +This patch uses log_err() to replace ASSERT helpers in open_netns() +and close_netns() in network_helpers.c to decouple dependencies + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaced ASSERT helpers with log_err in open_netns and close_netns to reduce dependencies.', 'keywords': 'log_err, open_netns, dependencies', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 151f7442436658ee84076681d8f52e987fe147ea +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 151f7442436658ee84076681d8f52e987fe147ea + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713989548 + Commit Message: + selftests/bpf: Fix a fd leak in error paths in open_netns + +As Martin mentioned in review comment + Parent Hashes: 55d30cc90fd42587594345a025b34399585e6e19 + Refs: there is an existing bug that +orig_netns_fd will be leaked in the later "goto fail;" case after +open("/proc/self/ns/net") in open_netns() in network_helpers.c. This +patch adds "close(token->orig_netns_fd);" before "free(token);" to +fix it. + +Fixes: a30338840fa5 ("selftests/bpf: Move open_netns() and close_netns() into network_helpers.c") +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/a104040b47c3c34c67f3f125cdfdde244a870d3c.1713868264.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a file descriptor leak in open_netns() in the BPF selftests network_helpers.c file.', 'keywords': 'fd leak,selftests,BPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 55d30cc90fd42587594345a025b34399585e6e19 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 55d30cc90fd42587594345a025b34399585e6e19 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1713977285 + Commit Message: + Merge branch 'introduce-bpf_preempt_-disable-enable' + +Kumar Kartikeya Dwivedi says: + +==================== +Introduce bpf_preempt_{disable + Parent Hashes: dc92febf7b93da5049fe177804e6b1961fcc6bd7 3134396f1cba939783b87c63dae3a54708285a9a + Refs: enable} + +This set introduces two kfuncs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce new kfuncs for managing preemption in eBPF programs.', 'keywords': 'kfuncs,preemption,eBPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3134396f1cba939783b87c63dae3a54708285a9a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3134396f1cba939783b87c63dae3a54708285a9a + Author Name: Kumar Kartikeya Dwivedi + Author Email: memxor@gmail.com + Commit Date: 1713977269 + Commit Message: + selftests/bpf: Add tests for preempt kfuncs + +Add tests for nested cases + Parent Hashes: fc7566ad0a826cdc8886c5dbbb39ce72a0dc6333 + Refs: nested count preservation upon different +subprog calls that disable/enable preemption + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for nested preempt kfunc cases in BPF.', 'keywords': 'selftests, preempt, kfuncs', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fc7566ad0a826cdc8886c5dbbb39ce72a0dc6333 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fc7566ad0a826cdc8886c5dbbb39ce72a0dc6333 + Author Name: Kumar Kartikeya Dwivedi + Author Email: memxor@gmail.com + Commit Date: 1713977269 + Commit Message: + bpf: Introduce bpf_preempt_[disable + Parent Hashes: dc92febf7b93da5049fe177804e6b1961fcc6bd7 + Refs: enable] kfuncs + +Introduce two new BPF kfuncs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce two new BPF kfuncs for preempt disable support.', 'keywords': 'BPF kfuncs preempt', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dc92febf7b93da5049fe177804e6b1961fcc6bd7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dc92febf7b93da5049fe177804e6b1961fcc6bd7 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1713974810 + Commit Message: + bpf: Don't check for recursion in bpf_wq_work. + +__bpf_prog_enter_sleepable_recur does recursion check which is not applicable +to wq callback. The callback function is part of bpf program and bpf prog might +be running on the same cpu. So recursion check would incorrectly prevent +callback from running. The code can call __bpf_prog_enter_sleepable() + Parent Hashes: 6e10b6350a67d398c795ac0b93a7bb7103633fe4 + Refs: but +run_ctx would be fake + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove unnecessary recursion check in bpf_wq_work callback function.', 'keywords': 'recursion, bpf_wq_work, callback', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 1adb825af946fa6b2104c1713ad4999283e09fbc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1adb825af946fa6b2104c1713ad4999283e09fbc + Author Name: Joel Granados + Author Email: j.granados@samsung.com + Commit Date: 1713944634 + Commit Message: + bpf: Remove the now superfluous sentinel elements from ctl_table array + +This commit comes at the tail end of a greater effort to remove the +empty elements at the end of the ctl_table arrays (sentinels) which +will reduce the overall build time size of the kernel and run time +memory bloat by ~64 bytes per sentinel (further information Link : +https://lore.kernel.org/all/ZO5Yx5JFogGi%2FcBo@bombadil.infradead.org/) + +Remove sentinel element from bpf_syscall_table. + +Acked-by: Andrii Nakryiko +Signed-off-by: Joel Granados + + Parent Hashes: f15843f725a55d7232aa9b699be52c2c3da06982 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit removes superfluous sentinel elements from the ctl_table array to reduce kernel build size and memory usage.', 'keywords': 'sentinel, ctl_table, bpf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6e10b6350a67d398c795ac0b93a7bb7103633fe4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6e10b6350a67d398c795ac0b93a7bb7103633fe4 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1713926817 + Commit Message: + Merge branch 'introduce-bpf_wq' + +Benjamin Tissoires says: + +==================== +Introduce bpf_wq + +This is a followup of sleepable bpf_timer[0]. + +When discussing sleepable bpf_timer + Parent Hashes: a7de265cb2d849f8986a197499ad58dca0a4f209 8290dba51910d36721ced6ccf03049ed6b7ea2ce + Refs: it was thought that we should give +a try to bpf_wq + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces a new bpf_wq following the development of sleepable bpf_timer.', 'keywords': 'bpf_wq,sleepable,bpf_timer', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8290dba51910d36721ced6ccf03049ed6b7ea2ce +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8290dba51910d36721ced6ccf03049ed6b7ea2ce + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713926817 + Commit Message: + selftests/bpf: wq: add bpf_wq_start() checks + +Allows to test if allocation/free works + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-16-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 8e83da9732d91c60fdc651b2486c8e5935eb0ca2 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds bpf_wq_start() checks in selftests for allocation and free operations.', 'keywords': 'bpf_wq_start, selftests, allocation', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8e83da9732d91c60fdc651b2486c8e5935eb0ca2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8e83da9732d91c60fdc651b2486c8e5935eb0ca2 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713926817 + Commit Message: + bpf: add bpf_wq_start + +again + Parent Hashes: 01b7b1c5f3cc029bdd2652eba61e953ccd286c0e + Refs: copy/paste from bpf_timer_start(). + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-15-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a new function bpf_wq_start to the eBPF subsystem.', 'keywords': 'bpf, wq, start', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 01b7b1c5f3cc029bdd2652eba61e953ccd286c0e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 01b7b1c5f3cc029bdd2652eba61e953ccd286c0e + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713926817 + Commit Message: + selftests/bpf: add checks for bpf_wq_set_callback() + +We assign the callback and set everything up. +The actual tests of these callbacks will be done when bpf_wq_start() is +available. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-14-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 81f1d7a583fa1fa14f0c4e6140d34b5e3d08d227 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added selftests for bpf_wq_set_callback() function but await further tests with bpf_wq_start().', 'keywords': 'selftests, bpf_wq_set_callback, callback', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 81f1d7a583fa1fa14f0c4e6140d34b5e3d08d227 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 81f1d7a583fa1fa14f0c4e6140d34b5e3d08d227 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713926817 + Commit Message: + bpf: wq: add bpf_wq_set_callback_impl + +To support sleepable async callbacks + Parent Hashes: e3d9eac99afd94980475833479332fefd74c5c2b + Refs: we need to tell push_async_cb() +whether the cb is sleepable or not. + +The verifier now detects that we are in bpf_wq_set_callback_impl and +can allow a sleepable callback to happen. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-13-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add bpf_wq_set_callback_impl to support sleepable async callbacks in eBPF.', 'keywords': 'bpf, wq, sleepable', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e3d9eac99afd94980475833479332fefd74c5c2b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e3d9eac99afd94980475833479332fefd74c5c2b + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713926817 + Commit Message: + selftests/bpf: wq: add bpf_wq_init() checks + +Allows to test if allocation/free works + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-12-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: eb48f6cd41a0f7803770a76bbffb6bd5b1b2ae2f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for bpf_wq_init to verify allocation and free operations.', 'keywords': 'selftests,bpf_wq_init,allocation', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: eb48f6cd41a0f7803770a76bbffb6bd5b1b2ae2f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: eb48f6cd41a0f7803770a76bbffb6bd5b1b2ae2f + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713926817 + Commit Message: + bpf: wq: add bpf_wq_init + +We need to teach the verifier about the second argument which is declared +as void * but which is of type KF_ARG_PTR_TO_MAP. We could have dropped +this extra case if we declared the second argument as struct bpf_map * + Parent Hashes: b4abee7c1ae3d59440e7915da28c6d2cd394738a + Refs: +but that means users will have to do extra casting to have their program +compile. + +We also need to duplicate the timer code for the checking if the map +argument is matching the provided workqueue. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-11-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add bpf_wq_init with type check for the second argument to handle pointers to maps in eBPF verifier.', 'keywords': 'bpf_wq_init,pointer,map', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b4abee7c1ae3d59440e7915da28c6d2cd394738a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b4abee7c1ae3d59440e7915da28c6d2cd394738a + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713926813 + Commit Message: + selftests/bpf: add bpf_wq tests + +We simply try in all supported map types if we can store/load a bpf_wq. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-10-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 246331e3f1eac905170a923f0ec76725c2558232 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds tests for storing/loading bpf_wq in all supported eBPF map types.', 'keywords': 'bpf_wq,test,map', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 58a4c9b1e5a3e53c9148e80b90e1e43897ce77d1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 58a4c9b1e5a3e53c9148e80b90e1e43897ce77d1 + Author Name: Eric Dumazet + Author Email: edumazet@google.com + Commit Date: 1713924177 + Commit Message: + ipv4: check for NULL idev in ip_route_use_hint() + +syzbot was able to trigger a NULL deref in fib_validate_source() +in an old tree [1]. + +It appears the bug exists in latest trees. + +All calls to __in_dev_get_rcu() must be checked for a NULL result. + +[1] +general protection fault + Parent Hashes: 3584718cf2ec7e79b6814f2596dcf398c5fb2eca + Refs: probably for non-canonical address 0xdffffc0000000000: 0000 [#1] SMP KASAN +KASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007] +CPU: 2 PID: 3257 Comm: syz-executor.3 Not tainted 5.10.0-syzkaller #0 +Hardware name: QEMU Standard PC (Q35 + ICH9 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a NULL pointer dereference in ip_route_use_hint by ensuring __in_dev_get_rcu() results are checked for NULL.', 'keywords': 'NULL dereference, ipv4, ip_route_use_hint', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 246331e3f1eac905170a923f0ec76725c2558232 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 246331e3f1eac905170a923f0ec76725c2558232 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922285 + Commit Message: + bpf: allow struct bpf_wq to be embedded in arraymaps and hashmaps + +Currently bpf_wq_cancel_and_free() is just a placeholder as there is +no memory allocation for bpf_wq just yet. + +Again + Parent Hashes: d940c9b94d7e6d9cff288623e3e8bf5fdea98b79 + Refs: duplication of the bpf_timer approach + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-9-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Allow embedding of struct bpf_wq in arraymaps and hashmaps.', 'keywords': 'bpf_wq,arraymaps,hashmaps', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d940c9b94d7e6d9cff288623e3e8bf5fdea98b79 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d940c9b94d7e6d9cff288623e3e8bf5fdea98b79 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922285 + Commit Message: + bpf: add support for KF_ARG_PTR_TO_WORKQUEUE + +Introduce support for KF_ARG_PTR_TO_WORKQUEUE. The kfuncs will use bpf_wq +as argument and that will be recognized as workqueue argument by verifier. +bpf_wq_kern casting can happen inside kfunc + Parent Hashes: ad2c03e691be3268eefc75ff1d892db3f0e79f62 + Refs: but using bpf_wq in +argument makes life easier for users who work with non-kern type in BPF +progs. + +Duplicate process_timer_func into process_wq_func. +meta argument is only needed to ensure bpf_wq_init's workqueue and map +arguments are coming from the same map (map_uid logic is necessary for +correct inner-map handling) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds support for KF_ARG_PTR_TO_WORKQUEUE to recognize workqueue arguments within kfuncs for eBPF programs.', 'keywords': 'KF_ARG_PTR_TO_WORKQUEUE,bpf_wq,verifier', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ad2c03e691be3268eefc75ff1d892db3f0e79f62 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ad2c03e691be3268eefc75ff1d892db3f0e79f62 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922284 + Commit Message: + bpf: verifier: bail out if the argument is not a map + +When a kfunc is declared with a KF_ARG_PTR_TO_MAP + Parent Hashes: f1d0a2fbb0088675cceeab73d1f4b4308b289984 + Refs: we should have +reg->map_ptr set to a non NULL value + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a check to ensure reg->map_ptr is non-NULL when kfunc declares with KF_ARG_PTR_TO_MAP.', 'keywords': 'bpf,verifier,map', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f1d0a2fbb0088675cceeab73d1f4b4308b289984 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f1d0a2fbb0088675cceeab73d1f4b4308b289984 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922284 + Commit Message: + tools: sync include/uapi/linux/bpf.h + +cp include/uapi/linux/bpf.h tools/include/uapi/linux/bpf.h + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-6-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d56b63cf0c0f71e1b2e04dd8220b408f049e67ff + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Syncs bpf.h header files between include and tools directories.', 'keywords': 'sync,uapi,bpf.h', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: d56b63cf0c0f71e1b2e04dd8220b408f049e67ff +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d56b63cf0c0f71e1b2e04dd8220b408f049e67ff + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922284 + Commit Message: + bpf: add support for bpf_wq user type + +Mostly a copy/paste from the bpf_timer API + Parent Hashes: fc22d9495f0b32d75b5d25a17b300b7aad05c55d + Refs: without the initialization +and free + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support for a new bpf_wq user type in eBPF, similar to bpf_timer API.', 'keywords': 'bpf_wq,user,type', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fc22d9495f0b32d75b5d25a17b300b7aad05c55d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fc22d9495f0b32d75b5d25a17b300b7aad05c55d + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922284 + Commit Message: + bpf: replace bpf_timer_cancel_and_free with a generic helper + +Same reason than most bpf_timer* functions + Parent Hashes: 073f11b0264310b85754b6a0946afee753790c66 + Refs: we need almost the same for +workqueues. +So extract the generic part out of it so bpf_wq_cancel_and_free can reuse +it. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-4-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor bpf_timer_cancel_and_free to a generic helper for reuse in bpf_wq_cancel_and_free.', 'keywords': 'bpf timer helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 073f11b0264310b85754b6a0946afee753790c66 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 073f11b0264310b85754b6a0946afee753790c66 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922284 + Commit Message: + bpf: replace bpf_timer_set_callback with a generic helper + +In the same way we have a generic __bpf_async_init() + Parent Hashes: 56b4a177ae6322173360a93ea828ad18570a5a14 + Refs: we also need +to share code between timer and workqueue for the set_callback call. + +We just add an unused flags parameter + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit replaces bpf_timer_set_callback with a generic helper function for shared code between timer and workqueue.', 'keywords': 'bpf,generic,helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 56b4a177ae6322173360a93ea828ad18570a5a14 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 56b4a177ae6322173360a93ea828ad18570a5a14 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922284 + Commit Message: + bpf: replace bpf_timer_init with a generic helper + +No code change except for the new flags argument being stored in the +local data struct. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-2-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: be2749beff62e0d63cf97fe63cabc79a68443139 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit replaces bpf_timer_init with a generic helper function while adding a new flags argument.', 'keywords': 'bpf_timer_init,generic helper,flags argument', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: be2749beff62e0d63cf97fe63cabc79a68443139 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: be2749beff62e0d63cf97fe63cabc79a68443139 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1713922284 + Commit Message: + bpf: make timer data struct more generic + +To be able to add workqueues and reuse most of the timer code + Parent Hashes: a7de265cb2d849f8986a197499ad58dca0a4f209 + Refs: we need +to make bpf_hrtimer more generic. + +There is no code change except that the new struct gets a new u64 flags +attribute. We are still below 2 cache lines + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor the bpf_hrtimer to be more generic and reusable for workqueues.', 'keywords': 'bpf_hrtimer,generic,reusable', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b240fc56b8fd5d383bd00e59ddf67a4f66b86bb8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b240fc56b8fd5d383bd00e59ddf67a4f66b86bb8 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1713820892 + Commit Message: + Merge branch 'net-dsa-vsc73xx-convert-to-phylink-and-do-some-cleanup' + +Pawel Dembicki says: + +==================== +net: dsa: vsc73xx: convert to PHYLINK and do some cleanup + +This patch series is a result of splitting a larger patch series [0] + Parent Hashes: c51db4ac10d57c366f9a92121e3889bfc6c324cd 96944aafaaa64e6ead1d3d227a1493dd8196a827 + Refs: +where some parts needed to be refactored. + +The first patch switches from a poll loop to read_poll_timeout. + +The second patch is a simple conversion to phylink because adjust_link +won't work anymore. + +The third patch is preparation for future use. Using the +"phy_interface_mode_is_rgmii" macro allows for the proper recognition +of all RGMII modes. + +Patches 4-5 involve some cleanup: The fourth patch introduces +a definition with the maximum number of ports to avoid using +magic numbers. The next one fills in documentation. + +[0] https://patchwork.kernel.org/project/netdevbpf/list/?series=841034&state=%2A&archive=both +==================== + +Link: https://lore.kernel.org/r/20240417205048.3542839-1-paweldembicki@gmail.com +Signed-off-by: Jakub Kicinski + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit converts net-dsa-vsc73xx to PHYLINK and includes code cleanup and refactoring.', 'keywords': 'PHYLINK, cleanup, refactoring', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 584ed2f76ff5fe360d87a04d17b6520c7999e06b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 584ed2f76ff5fe360d87a04d17b6520c7999e06b + Author Name: Johannes Berg + Author Email: johannes.berg@intel.com + Commit Date: 1713817720 + Commit Message: + um: vector: fix bpfflash parameter evaluation + +With W=1 the build complains about a pointer compared to +zero + Parent Hashes: e3cce8d87d6407f83a5741c3c5d54bf1365c6ac6 + Refs: clearly the result should've been compared. + +Fixes: 9807019a62dc ("um: Loadable BPF "Firmware" for vector drivers") +Signed-off-by: Johannes Berg +Reviewed-by: Tiwei Bie +Signed-off-by: Richard Weinberger + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes pointer comparison issue in bpfflash parameter evaluation for vector drivers in UML.', 'keywords': 'bpfflash,vector,UML', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 5bcf0dcbf9066348058b88a510c57f70f384c92c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5bcf0dcbf9066348058b88a510c57f70f384c92c + Author Name: Toke Høiland-Jørgensen + Author Email: toke@redhat.com + Commit Date: 1713806681 + Commit Message: + xdp: use flags field to disambiguate broadcast redirect + +When redirecting a packet using XDP + Parent Hashes: c6f48506ba30c722dd9d89aa6a40eb1926277dff + Refs: the bpf_redirect_map() helper will set +up the redirect destination information in struct bpf_redirect_info (using +the __bpf_xdp_redirect_map() helper function) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit utilizes flags to clarify broadcast redirects in XDP packet redirection.', 'keywords': 'xdp, broadcast, redirect', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: a7de265cb2d849f8986a197499ad58dca0a4f209 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a7de265cb2d849f8986a197499ad58dca0a4f209 + Author Name: Rafael Passos + Author Email: rafael@rcpassos.me + Commit Date: 1713800888 + Commit Message: + bpf: Fix typos in comments + +Found the following typos in comments + Parent Hashes: e1a7545981e2086feaa40dcb7b0db8de0bdada19 + Refs: and fixed them: + +s/unpriviledged/unprivileged/ +s/reponsible/responsible/ +s/possiblities/possibilities/ +s/Divison/Division/ +s/precsion/precision/ +s/havea/have a/ +s/reponsible/responsible/ +s/responsibile/responsible/ +s/tigher/tighter/ +s/respecitve/respective/ + +Signed-off-by: Rafael Passos +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/6af7deb4-bb24-49e8-b3f1-8dd410597337@smtp-relay.sendinblue.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed multiple typos in comments in the bpf subsystem code.', 'keywords': 'typos, comments, bpf', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c6f48506ba30c722dd9d89aa6a40eb1926277dff +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c6f48506ba30c722dd9d89aa6a40eb1926277dff + Author Name: Puranjay Mohan + Author Email: puranjay@kernel.org + Commit Date: 1713799565 + Commit Message: + arm32 + Parent Hashes: 10541b374aa05c8118cc6a529a615882e53f261b + Refs: bpf: Reimplement sign-extension mov instruction + +The current implementation of the mov instruction with sign extension has the +following problems: + + 1. It clobbers the source register if it is not stacked because it + sign extends the source and then moves it to the destination. + 2. If the dst_reg is stacked + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit reimplements the ARM32 sign-extension mov instruction to address issues with source register clobbering and stacked destination registers.', 'keywords': 'ARM32, sign-extension, mov instruction', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e1a7545981e2086feaa40dcb7b0db8de0bdada19 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e1a7545981e2086feaa40dcb7b0db8de0bdada19 + Author Name: Rafael Passos + Author Email: rafael@rcpassos.me + Commit Date: 1713798725 + Commit Message: + bpf: Fix typo in function save_aux_ptr_type + +I found this typo in the save_aux_ptr_type function. +s/allow_trust_missmatch/allow_trust_mismatch/ +I did not find this anywhere else in the codebase. + +Signed-off-by: Rafael Passos +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/fbe1d636-8172-4698-9a5a-5a3444b55322@smtp-relay.sendinblue.com + + Parent Hashes: 735f5b8a7ccf383e50d76f7d1c25769eee474812 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Fixes a typo in the save_aux_ptr_type function's variable name.", 'keywords': 'typo, save_aux_ptr_type, fix', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 735f5b8a7ccf383e50d76f7d1c25769eee474812 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 735f5b8a7ccf383e50d76f7d1c25769eee474812 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1713719352 + Commit Message: + bpf + Parent Hashes: db50040d09cc511889b2c949a0c93d017e44f081 + Refs: docs: Fix formatting nit in instruction-set.rst + +Other places that had pseudocode were prefixed with :: +so as to appear in a literal block + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes formatting in the instruction-set documentation by using pseudocode blocks.', 'keywords': 'formatting, pseudocode, documentation', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: db50040d09cc511889b2c949a0c93d017e44f081 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: db50040d09cc511889b2c949a0c93d017e44f081 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1713719336 + Commit Message: + bpf + Parent Hashes: 2ea0aa535818622395fb55e01086ef2a490fc734 + Refs: docs: Clarify helper ID and pointer terms in instruction-set.rst + +Per IETF 119 meeting discussion and mailing list discussion at +https://mailarchive.ietf.org/arch/msg/bpf/2JwWQwFdOeMGv0VTbD0CKWwAOEA/ +the following changes are made. + +First + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Clarifies helper ID and pointer terms in bpf instruction-set documentation based on IETF and mailing list discussions.', 'keywords': 'documentation,helper ID,pointer', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 63a51820d29bdfcf52abed2db2d32b4f6843988e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 63a51820d29bdfcf52abed2db2d32b4f6843988e + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713572009 + Commit Message: + selftests/bpf: Use connect_to_addr in sk_assign + +This patch uses public helper connect_to_addr() exported in +network_helpers.h instead of the local defined function connect_to_server() +in prog_tests/sk_assign.c. This can avoid duplicate code. + +The code that sets SO_SNDTIMEO timeout as timeo_sec (3s) can be dropped + Parent Hashes: 805b4d90c0df79a88907623b2528954a0125313d + Refs: +since connect_to_addr() sets default timeout as 3s. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/98fdd384872bda10b2adb052e900a2212c9047b9.1713427236.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor sk_assign test by replacing connect_to_server with connect_to_addr to reduce code duplication.', 'keywords': 'connect_to_addr, sk_assign, refactor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 805b4d90c0df79a88907623b2528954a0125313d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 805b4d90c0df79a88907623b2528954a0125313d + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713572009 + Commit Message: + selftests/bpf: Use connect_to_addr in cls_redirect + +This patch uses public helper connect_to_addr() exported in +network_helpers.h instead of the local defined function connect_to_server() +in prog_tests/cls_redirect.c. This can avoid duplicate code. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/4a03ac92d2d392f8721f398fa449a83ac75577bc.1713427236.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + Parent Hashes: db9994d022ecd42006354609f6e4e3f57e5a4b03 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor cls_redirect test to use connect_to_addr helper to avoid code duplication.', 'keywords': 'selftests,bpf,refactor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: db9994d022ecd42006354609f6e4e3f57e5a4b03 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: db9994d022ecd42006354609f6e4e3f57e5a4b03 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713572008 + Commit Message: + selftests/bpf: Update arguments of connect_to_addr + +Move the third argument "int type" of connect_to_addr() to the first one +which is closer to how the socket syscall is doing it. And add a +network_helper_opts argument as the fourth one. Then change its usages in +sock_addr.c too. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/088ea8a95055f93409c5f57d12f0e58d43059ac4.1713427236.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + Parent Hashes: a2e4979536c440838794ee292955ce9ed55ad181 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reorder and update arguments of connect_to_addr in selftests/bpf to match socket syscall style.', 'keywords': 'connect_to_addr, arguments, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: a2e4979536c440838794ee292955ce9ed55ad181 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a2e4979536c440838794ee292955ce9ed55ad181 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713572008 + Commit Message: + selftests/bpf: Use start_server_addr in sk_assign + +Include network_helpers.h in prog_tests/sk_assign.c + Parent Hashes: 9851382fb3697efb2f4234d70596bd845b3af535 + Refs: use the newly +added public helper start_server_addr() instead of the local defined +function start_server(). This can avoid duplicate code. + +The code that sets SO_RCVTIMEO timeout as timeo_sec (3s) can be dropped + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactored sk_assign.c to use public helper start_server_addr and removed duplicate timeout setting.', 'keywords': 'refactor, sk_assign, network_helpers', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 9851382fb3697efb2f4234d70596bd845b3af535 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9851382fb3697efb2f4234d70596bd845b3af535 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713572008 + Commit Message: + selftests/bpf: Use start_server_addr in cls_redirect + +Include network_helpers.h in prog_tests/cls_redirect.c + Parent Hashes: 9c598a83b7eab7b05002911fd25b0be7b996ce6d + Refs: use the newly +added public helper start_server_addr() instead of the local defined +function start_server(). This can avoid duplicate code. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/13f336cb4c6680175d50bb963d9532e11528c758.1713427236.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor selftests to use start_server_addr in cls_redirect for code reuse.', 'keywords': 'start_server_addr,code reuse,selftests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 9c598a83b7eab7b05002911fd25b0be7b996ce6d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9c598a83b7eab7b05002911fd25b0be7b996ce6d + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1713572008 + Commit Message: + selftests/bpf: Add start_server_addr helper + +In order to pair up with connect_to_addr() + Parent Hashes: 462e5e2a5938d0241ad146d21dd0da1be8e7eaf0 + Refs: this patch adds a new helper +start_server_addr() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Added a new helper function 'start_server_addr' to bpf selftests for pairing with 'connect_to_addr'.", 'keywords': 'helper,selftests,bpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 50449ca66cc5a8cbc64749cf4b9f3d3fc5f4b457 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 50449ca66cc5a8cbc64749cf4b9f3d3fc5f4b457 + Author Name: Yaxiong Tian + Author Email: tianyaxiong@kylinos.cn + Commit Date: 1713540780 + Commit Message: + arm64: hibernate: Fix level3 translation fault in swsusp_save() + +On arm64 machines + Parent Hashes: 34e526cb7d46726b2ae5f83f2892d00ebb088509 + Refs: swsusp_save() faults if it attempts to access +MEMBLOCK_NOMAP memory ranges. This can be reproduced in QEMU using UEFI +when booting with rodata=off debug_pagealloc=off and CONFIG_KFENCE=n: + + Unable to handle kernel paging request at virtual address ffffff8000000000 + Mem abort info: + ESR = 0x0000000096000007 + EC = 0x25: DABT (current EL) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix the translation fault in swsusp_save() for arm64 during hibernation.', 'keywords': 'arm64, hibernate, translation', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 61ba075d9911d2a6db181fbb5602762a24d5d0a9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 61ba075d9911d2a6db181fbb5602762a24d5d0a9 + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@redhat.com + Commit Date: 1713489772 + Commit Message: + Revert "tools headers: Remove almost unused copy of uapi/stat.h + Parent Hashes: c15ed4442981ccf8e7e0d885f5cb500400dde9d7 + Refs: add few conditional defines" + +This reverts commit a672af9139a843eb7a48fd7846bb6df8f81b5f86. + +By now it is not used for building tools/perf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit reverts a previous removal of a uapi/stat.h copy for building perf tools.', 'keywords': 'revert, uapi/stat, tools', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: d9bd1d4264baddf7ab8baae86e91674d369f22de +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d9bd1d4264baddf7ab8baae86e91674d369f22de + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1713489771 + Commit Message: + perf test bpf-counters: Add test for BPF event modifier + +Refactor test to better enable sharing of logic + Parent Hashes: eb4d27cf9aef3e6c9bcaf8fa1a1cadc2433d847b + Refs: to give an idea of +progress and introduce test functions. Add test of measuring both +cycles and cycles:b simultaneously. + +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Athira Rajeev +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: Kan Liang +Cc: Mark Rutland +Cc: Namhyung Kim +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Song Liu +Cc: Thomas Richter +Link: https://lore.kernel.org/r/20240416170014.985191-2-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors perf test to add BPF event modifier and improve test logic sharing.', 'keywords': 'perf test, BPF event, refactor', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: eb4d27cf9aef3e6c9bcaf8fa1a1cadc2433d847b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: eb4d27cf9aef3e6c9bcaf8fa1a1cadc2433d847b + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1713489771 + Commit Message: + perf docs: Document bpf event modifier + +Document that 'b' is used as a modifier to make an event use a BPF +counter. + +Fixes: 01bd8efcec444468 ("perf stat: Introduce ':b' modifier") +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Athira Rajeev +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: Kan Liang +Cc: Mark Rutland +Cc: Namhyung Kim +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Song Liu +Cc: Thomas Richter +Link: https://lore.kernel.org/r/20240416170014.985191-1-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + Parent Hashes: 6b718ac6874c2233b8dec369a8a377d6c5b638e6 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Document the 'b' modifier used in perf events for BPF counters.", 'keywords': 'perf, BPF, event', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 462e5e2a5938d0241ad146d21dd0da1be8e7eaf0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 462e5e2a5938d0241ad146d21dd0da1be8e7eaf0 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1713456201 + Commit Message: + bpf: Fix JIT of is_mov_percpu_addr instruction. + +The codegen for is_mov_percpu_addr instruction works for rax/r8 registers +only. Fix it to generate proper x86 byte code for other registers. + +Fixes: 7bdbf7446305 ("bpf: add special internal-only MOV instruction to resolve per-CPU addrs") +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240417214406.15788-1-alexei.starovoitov@gmail.com + + Parent Hashes: e739e01d8df8bf26dbc9dcaeaee3c8c55e8ffa71 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix JIT to properly handle is_mov_percpu_addr instruction for x86 registers other than rax/r8.', 'keywords': 'JIT, x86, percpu', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6fc6d7f59376c7cda4d866159b29fe96d96afe83 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6fc6d7f59376c7cda4d866159b29fe96d96afe83 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1713403119 + Commit Message: + selftests: adopt BPF's approach to quieter builds + +selftest build is fairly noisy + Parent Hashes: 2bd99aef1b19e6da09eff692bc0a09d61d785782 + Refs: it's easy to miss warnings. +It's standard practice to add alternative messages in +the Makefile. I was grepping for existing solutions + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit reduces noise in selftest builds by adopting BPF's approach to quieter build outputs.", 'keywords': 'selftests, quieter builds, Makefile', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e739e01d8df8bf26dbc9dcaeaee3c8c55e8ffa71 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e739e01d8df8bf26dbc9dcaeaee3c8c55e8ffa71 + Author Name: Quentin Deslandes + Author Email: qde@naccy.de + Commit Date: 1713360242 + Commit Message: + libbpf: Fix dump of subsequent char arrays + +When dumping a character array + Parent Hashes: 9213e52970a5997c9eb176c7afcc6ec67b1b1e6f + Refs: libbpf will watch for a '\0' and set +is_array_terminated=true if found. This prevents libbpf from printing +the remaining characters of the array + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes libbpf to correctly handle termination of character arrays when dumping.', 'keywords': 'libbpf, character, arrays', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9213e52970a5997c9eb176c7afcc6ec67b1b1e6f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9213e52970a5997c9eb176c7afcc6ec67b1b1e6f + Author Name: Quentin Deslandes + Author Email: qde@naccy.de + Commit Date: 1713360224 + Commit Message: + libbpf: Fix misaligned array closing bracket + +In btf_dump_array_data() + Parent Hashes: ad2d22b617b7c0ca2cff4da6dc063183822484bb + Refs: libbpf will call btf_dump_dump_type_data() for +each element. For an array of characters + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Fixes misaligned array closing bracket in libbpf's btf_dump_array_data function.", 'keywords': 'libbpf, array, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: fc29e04ae1ad4c99422c0b8ae4b43cfe99c70429 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fc29e04ae1ad4c99422c0b8ae4b43cfe99c70429 + Author Name: Jesper Dangaard Brouer + Author Email: hawk@kernel.org + Commit Date: 1713305442 + Commit Message: + cgroup/rstat: add cgroup_rstat_lock helpers and tracepoints + +This commit enhances the ability to troubleshoot the global +cgroup_rstat_lock by introducing wrapper helper functions for the lock +along with associated tracepoints. + +Although global + Parent Hashes: 15b8b9ab5081d8dce9aa27a594ba4db2c29cefc0 + Refs: the cgroup_rstat_lock helper APIs and tracepoints take +arguments such as cgroup pointer and cpu_in_loop variable. This +adjustment is made because flushing occurs per cgroup despite the lock +being global. Hence + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds helper functions and tracepoints for better management and troubleshooting of cgroup_rstat_lock.', 'keywords': 'cgroup,rstat,tracepoints', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: ad2d22b617b7c0ca2cff4da6dc063183822484bb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ad2d22b617b7c0ca2cff4da6dc063183822484bb + Author Name: Quentin Monnet + Author Email: qmo@kernel.org + Commit Date: 1713283105 + Commit Message: + bpftool: Address minor issues in bash completion + +This commit contains a series of clean-ups and fixes for bpftool's bash +completion file: + +- Make sure all local variables are declared as such. +- Make sure variables are initialised before being read. +- Update ELF section ("maps" -> ".maps") for looking up map names in + object files. +- Fix call to _init_completion. +- Move definition for MAP_TYPE and PROG_TYPE higher up in the scope to + avoid defining them multiple times + Parent Hashes: 986e7663f98ec7441d9d948263ec0dda71e7479f + Refs: reuse MAP_TYPE where relevant. +- Simplify completion for "duration" keyword in "bpftool prog profile". +- Fix completion for "bpftool struct_ops register" and "bpftool link + (pin|detach)" where we would repeatedly suggest file names instead of + suggesting just one name. +- Fix completion for "bpftool iter pin ... map MAP" to account for the + "map" keyword. +- Add missing "detach" suggestion for "bpftool link". + +Signed-off-by: Quentin Monnet +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240413011427.14402-3-qmo@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes and refines bash completion in bpftool by addressing variable declarations, initialization, and improving command completion suggestions.', 'keywords': 'bash completion, bpftool, fixes', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 986e7663f98ec7441d9d948263ec0dda71e7479f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 986e7663f98ec7441d9d948263ec0dda71e7479f + Author Name: Quentin Monnet + Author Email: qmo@kernel.org + Commit Date: 1713283105 + Commit Message: + bpftool: Update documentation where progs/maps can be passed by name + +When using references to BPF programs + Parent Hashes: 1f586614f3ffa80fdf2116b2a1bebcdb5969cef8 + Refs: bpftool supports passing programs +by name on the command line. The manual pages for "bpftool prog" and +"bpftool map" (for prog_array updates) mention it + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update bpftool documentation to include support for passing programs and maps by name on the command line.', 'keywords': 'bpftool, documentation, command-line', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1f586614f3ffa80fdf2116b2a1bebcdb5969cef8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1f586614f3ffa80fdf2116b2a1bebcdb5969cef8 + Author Name: Harishankar Vishwanathan + Author Email: harishankar.vishwanathan@gmail.com + Commit Date: 1713282927 + Commit Message: + bpf: Harden and/or/xor value tracking in verifier + +This patch addresses a latent unsoundness issue in the +scalar(32)_min_max_and/or/xor functions. While it is not a bugfix + Parent Hashes: dac045fc9fa653e250f991ea8350b32cfec690d2 + Refs: +it ensures that the functions produce sound outputs for all inputs. + +The issue occurs in these functions when setting signed bounds. The +following example illustrates the issue for scalar_min_max_and() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit hardens the and/or/xor value tracking in the eBPF verifier to address potential unsoundness.', 'keywords': 'harden, verifier, tracking', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dac045fc9fa653e250f991ea8350b32cfec690d2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dac045fc9fa653e250f991ea8350b32cfec690d2 + Author Name: Chen Pei + Author Email: cp0613@linux.alibaba.com + Commit Date: 1713280938 + Commit Message: + bpf + Parent Hashes: fc5eb4a84e4c063e75a6a6e92308e9533c0f19b5 + Refs: tests: Fix typos in comments + +Currently + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix typographical errors in test comment documentation for clarity.', 'keywords': 'typos,test,comments', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 10541b374aa05c8118cc6a529a615882e53f261b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 10541b374aa05c8118cc6a529a615882e53f261b + Author Name: Xu Kuohai + Author Email: xukuohai@huawei.com + Commit Date: 1713280781 + Commit Message: + riscv + Parent Hashes: dc7d7447b56bcc9cf79a9c22e4edad200a298e4c + Refs: bpf: Fix incorrect runtime stats + +When __bpf_prog_enter() returns zero + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed incorrect runtime statistics when __bpf_prog_enter() returns zero for riscv architecture.', 'keywords': 'runtime, stats, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dc7d7447b56bcc9cf79a9c22e4edad200a298e4c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dc7d7447b56bcc9cf79a9c22e4edad200a298e4c + Author Name: Xu Kuohai + Author Email: xukuohai@huawei.com + Commit Date: 1713280770 + Commit Message: + bpf + Parent Hashes: 37eacb9f6e89fb399a79e952bc9c78eb3e16290e + Refs: arm64: Fix incorrect runtime stats + +When __bpf_prog_enter() returns zero + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix incorrect runtime statistics on ARM64 when __bpf_prog_enter() returns zero.', 'keywords': 'ARM64, fix, runtime', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fc5eb4a84e4c063e75a6a6e92308e9533c0f19b5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fc5eb4a84e4c063e75a6a6e92308e9533c0f19b5 + Author Name: Ard Biesheuvel + Author Email: ardb@kernel.org + Commit Date: 1713278113 + Commit Message: + btf: Avoid weak external references + +If the BTF code is enabled in the build configuration + Parent Hashes: 4d4992ff587604455e8843a0e76dce0b99175319 + Refs: the start/stop +BTF markers are guaranteed to exist. Only when CONFIG_DEBUG_INFO_BTF=n + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies BTF code to avoid weak external references when CONFIG_DEBUG_INFO_BTF is not set.', 'keywords': 'BTF, weak references, CONFIG_DEBUG_INFO_BTF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 854dd99b5ddc9d90e31e5f112462a5994dd31810 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 854dd99b5ddc9d90e31e5f112462a5994dd31810 + Author Name: Ingo Molnar + Author Email: mingo@kernel.org + Commit Date: 1713126926 + Commit Message: + perf/bpf: Mark perf_event_set_bpf_handler() and perf_event_free_bpf_handler() as inline too + +They can be unused with certain Kconfig variations: + + kernel/events/core.c:9622:13: warning: ‘perf_event_free_bpf_handler’ defined but not used [-Wunused-function] + kernel/events/core.c:9586:12: warning: ‘perf_event_set_bpf_handler’ defined but not used [-Wunused-function] + +Since they are both single-use + Parent Hashes: e224d1c1fb93f258030186b4878abe105c296ac1 + Refs: mark them inline. + +Signed-off-by: Ingo Molnar +Cc: linux-kernel@vger.kernel.org +Cc: Kyle Huey + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Marking perf_event_set_bpf_handler and perf_event_free_bpf_handler as inline to avoid unused function warnings.', 'keywords': 'inline, perf_event, unused', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 459fee7b508231cd4622b3bd94aaa85e8e16b888 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 459fee7b508231cd4622b3bd94aaa85e8e16b888 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1712955242 + Commit Message: + perf bench uprobe: Remove lib64 from libc.so.6 binary path + +bpf_program__attach_uprobe_opts will search LD_LIBRARY_PATH and so +specifying `/lib64` is unnecessary and causes failures for libc.so.6 +paths like `/lib/x86_64-linux-gnu/libc.so.6`. + +Fixes: 7b47623b8cae8149 ("perf bench uprobe trace_printk: Add entry attaching an BPF program that does a trace_printk") +Signed-off-by: Ian Rogers +Acked-by: Jiri Olsa +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Andrei Vagin +Cc: Ingo Molnar +Cc: Kan Liang +Cc: Kees Kook +Cc: Mark Rutland +Cc: Namhyung Kim +Cc: Peter Zijlstra +Link: https://lore.kernel.org/r/20240406040911.1603801-1-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + Parent Hashes: 2b8c43e7688fa61b842ea2b21d4159c67d6f2fd1 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed unnecessary /lib64 directory from libc.so.6 path to prevent failures in perf bench uprobe.', 'keywords': 'libc.so.6, LD_LIBRARY_PATH, uprobe', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 37eacb9f6e89fb399a79e952bc9c78eb3e16290e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 37eacb9f6e89fb399a79e952bc9c78eb3e16290e + Author Name: Anton Protopopov + Author Email: aspsk@isovalent.com + Commit Date: 1712939840 + Commit Message: + bpf: Fix a verifier verbose message + +Long ago a map file descriptor in a pseudo ldimm64 instruction could +only be present as an immediate value insn[0].imm + Parent Hashes: 6648e613226e18897231ab5e42ffc29e63fa3365 + Refs: and thus this value +was used in a verbose verifier message printed when the file descriptor +wasn't valid. Since addition of BPF_PSEUDO_MAP_IDX_VALUE/BPF_PSEUDO_MAP_IDX +the insn[0].imm field can also contain an index pointing to the file +descriptor in the attr.fd_array array. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a verbose message issue in the eBPF verifier for map descriptors.', 'keywords': 'fix, verifier, message', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4d4992ff587604455e8843a0e76dce0b99175319 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4d4992ff587604455e8843a0e76dce0b99175319 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1712939121 + Commit Message: + selftests/bpf: Add read_trace_pipe_iter function + +We have two printk tests reading trace_pipe in non blocking way + Parent Hashes: 23cc4fe44f1df5ccce088a7c9398f96794047c2a + Refs: +with the very same code. Moving that in new read_trace_pipe_iter +function. + +Current read_trace_pipe is used from samples/bpf and needs to +do blocking read and printf of the trace_pipe data + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor selftests/bpf to introduce a new non-blocking read_trace_pipe_iter function.', 'keywords': 'read_trace_pipe_iter, selftests, non-blocking', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 23cc4fe44f1df5ccce088a7c9398f96794047c2a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 23cc4fe44f1df5ccce088a7c9398f96794047c2a + Author Name: Thorsten Blum + Author Email: thorsten.blum@toblux.com + Commit Date: 1712938749 + Commit Message: + bpftool: Fix typo in error message + +s/at at/at a/ + +Signed-off-by: Thorsten Blum +Signed-off-by: Daniel Borkmann +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/bpf/20240411164258.533063-3-thorsten.blum@toblux.com + + Parent Hashes: c53e853c2d8145859f57c63662030f7aaa61cfdc + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a typo in the error message within bpftool utility.', 'keywords': 'bpftool, typo, error message', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 93d3fde7fd19c2e2cde7220e7986f9a75e9c5680 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 93d3fde7fd19c2e2cde7220e7986f9a75e9c5680 + Author Name: Ingo Molnar + Author Email: mingo@kernel.org + Commit Date: 1712915760 + Commit Message: + perf/bpf: Change the !CONFIG_BPF_SYSCALL stubs to static inlines + +Otherwise the compiler will be unhappy if they go unused + Parent Hashes: a265c9f6d52ac760e6e572bac73a11b60b998779 + Refs: +which they do on allnoconfigs. + +Signed-off-by: Ingo Molnar +Cc: Kyle Huey +Link: https://lore.kernel.org/r/ZhkE9F4dyfR2dH2D@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Change stubs to static inlines in perf/bpf to avoid compiler warnings with !CONFIG_BPF_SYSCALL.', 'keywords': 'perf,bpf,stubs', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: a265c9f6d52ac760e6e572bac73a11b60b998779 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a265c9f6d52ac760e6e572bac73a11b60b998779 + Author Name: Kyle Huey + Author Email: me@kylehuey.com + Commit Date: 1712915391 + Commit Message: + selftest/bpf: Test a perf BPF program that suppresses side effects + +The test sets a hardware breakpoint and uses a BPF program to suppress the +side effects of a perf event sample + Parent Hashes: c4fcc7d1f41532e878087c7c43f4cf247604d68b + Refs: including I/O availability signals + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest for perf BPF program to suppress side effects of perf event samples.', 'keywords': 'selftest, perf, side-effects', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: c4fcc7d1f41532e878087c7c43f4cf247604d68b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c4fcc7d1f41532e878087c7c43f4cf247604d68b + Author Name: Kyle Huey + Author Email: me@kylehuey.com + Commit Date: 1712915390 + Commit Message: + perf/bpf: Allow a BPF program to suppress all sample side effects + +Returning zero from a BPF program attached to a perf event already +suppresses any data output. Return early from __perf_event_overflow() in +this case so it will also suppress event_limit accounting + Parent Hashes: 76f6d58845829e5d6ef55532e67a323e7d30c26e + Refs: SIGTRAP +generation + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows BPF programs to suppress all sample side effects by returning zero from __perf_event_overflow.', 'keywords': 'BPF program, perf event, suppress', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'profile like programs']} +-------------------- +-------------------- +Processing Commit ID: 76f6d58845829e5d6ef55532e67a323e7d30c26e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 76f6d58845829e5d6ef55532e67a323e7d30c26e + Author Name: Kyle Huey + Author Email: me@kylehuey.com + Commit Date: 1712915390 + Commit Message: + perf/bpf: Remove unneeded uses_default_overflow_handler() + +Now that struct perf_event's orig_overflow_handler is gone + Parent Hashes: f11f10bfa1ca23b32020b2073aa13131a27978fe + Refs: there's no need +for the functions and macros to support looking past overflow_handler to +orig_overflow_handler. + +This patch is solely a refactoring and results in no behavior change. + +Signed-off-by: Kyle Huey +Signed-off-by: Ingo Molnar +Acked-by: Will Deacon +Acked-by: Song Liu +Acked-by: Jiri Olsa +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240412015019.7060-6-khuey@kylehuey.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove unneeded functions in perf/bpf after orig_overflow_handler removal.', 'keywords': 'refactoring, perf, overflow_handler', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: f11f10bfa1ca23b32020b2073aa13131a27978fe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f11f10bfa1ca23b32020b2073aa13131a27978fe + Author Name: Kyle Huey + Author Email: me@kylehuey.com + Commit Date: 1712915389 + Commit Message: + perf/bpf: Call BPF handler directly + Parent Hashes: 14e40a9578b70cc5323e55f61292a7e021f6037c + Refs: not through overflow machinery + +To ultimately allow BPF programs attached to perf events to completely +suppress all of the effects of a perf event overflow (rather than just the +sample output + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit allows BPF programs to suppress all effects of perf event overflow by calling the handler directly.', 'keywords': 'BPF, perf, overflow', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 14e40a9578b70cc5323e55f61292a7e021f6037c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 14e40a9578b70cc5323e55f61292a7e021f6037c + Author Name: Kyle Huey + Author Email: me@kylehuey.com + Commit Date: 1712915389 + Commit Message: + perf/bpf: Remove #ifdef CONFIG_BPF_SYSCALL from struct perf_event members + +This will allow __perf_event_overflow() (which is independent of +CONFIG_BPF_SYSCALL) to use struct perf_event's prog to decide whether to +call bpf_overflow_handler(). + +Suggested-by: Ingo Molnar +Signed-off-by: Kyle Huey +Signed-off-by: Ingo Molnar +Link: https://lore.kernel.org/r/20240412015019.7060-4-khuey@kylehuey.com + + Parent Hashes: 924d934393f98fa6a41d6ea27352faf79c2bbaf6 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove CONFIG_BPF_SYSCALL dependency from perf_event structure to enable independent functionality.', 'keywords': 'perf_event,BPF_SYSCALL,bpf_overflow_handler', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 924d934393f98fa6a41d6ea27352faf79c2bbaf6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 924d934393f98fa6a41d6ea27352faf79c2bbaf6 + Author Name: Kyle Huey + Author Email: me@kylehuey.com + Commit Date: 1712915388 + Commit Message: + perf/bpf: Create bpf_overflow_handler() stub for !CONFIG_BPF_SYSCALL + +This will allow __perf_event_overflow() (which is independent of +CONFIG_BPF_SYSCALL) to call bpf_overflow_handler(). + +Signed-off-by: Kyle Huey +Signed-off-by: Ingo Molnar +Link: https://lore.kernel.org/r/20240412015019.7060-3-khuey@kylehuey.com + + Parent Hashes: 4c03fe11b96bda60610aca77002e83f37b4a2242 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Create a bpf_overflow_handler stub for systems without CONFIG_BPF_SYSCALL.', 'keywords': 'bpf_overflow_handler, CONFIG_BPF_SYSCALL, perf_event_overflow', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 4c03fe11b96bda60610aca77002e83f37b4a2242 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4c03fe11b96bda60610aca77002e83f37b4a2242 + Author Name: Kyle Huey + Author Email: me@kylehuey.com + Commit Date: 1712915388 + Commit Message: + perf/bpf: Reorder bpf_overflow_handler() ahead of __perf_event_overflow() + +This will allow __perf_event_overflow() to call bpf_overflow_handler(). + +Signed-off-by: Kyle Huey +Signed-off-by: Ingo Molnar +Link: https://lore.kernel.org/r/20240412015019.7060-2-khuey@kylehuey.com + + Parent Hashes: acf68d98cae8a60dc4af2e9feaaa799bf0aa5c04 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reorders function definitions to allow __perf_event_overflow() to call bpf_overflow_handler().', 'keywords': 'bpf reordering overflow', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1e52af7f023c44859868306fac1a4b6b556cf47b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1e52af7f023c44859868306fac1a4b6b556cf47b + Author Name: Paul E. McKenney + Author Email: paulmck@kernel.org + Commit Date: 1712913805 + Commit Message: + bpf: Choose RCU Tasks based on TASKS_RCU rather than PREEMPTION + +The advent of CONFIG_PREEMPT_AUTO + Parent Hashes: 02b3c5fcdfe46f9c9dd5d3fc199612b13bf47c06 + Refs: AKA lazy preemption + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates eBPF RCU tasks selection to use TASKS_RCU instead of preemption settings.', 'keywords': 'RCU,TASKS_RCU,PREEMPTION', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c53e853c2d8145859f57c63662030f7aaa61cfdc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c53e853c2d8145859f57c63662030f7aaa61cfdc + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1712862407 + Commit Message: + Merge branch 'export send_recv_data' + +Geliang Tang says: + +==================== +v5: + - address Martin's comments for v4 (thanks). + - update patch 2 + Parent Hashes: d75142dbeb2bd1587b9cc19f841578f541275a64 dc34e44ea6a1c11cc517adc6df527b457acb9eaf + Refs: use 'return err' instead of 'return -1/0'. + - drop patch 3 in v4. + +v4: + - fix a bug in v3 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit merges branch updates to export send and receive data functions with bug fixes and code improvements.', 'keywords': 'merge, bugfix, export', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: dc34e44ea6a1c11cc517adc6df527b457acb9eaf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dc34e44ea6a1c11cc517adc6df527b457acb9eaf + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1712862402 + Commit Message: + selftests/bpf: Export send_recv_data helper + +This patch extracts the code to send and receive data into a new +helper named send_recv_data() in network_helpers.c and export it +in network_helpers.h. + +This helper will be used for MPTCP BPF selftests. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/5231103be91fadcce3674a589542c63b6a5eedd4.1712813933.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 68acca6e6f99b1f928a2c05b92bb1c272edb8ae7 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Export send_recv_data helper for MPTCP BPF selftests in network_helpers files.', 'keywords': 'send_recv_data,BPF,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 68acca6e6f99b1f928a2c05b92bb1c272edb8ae7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 68acca6e6f99b1f928a2c05b92bb1c272edb8ae7 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1712859476 + Commit Message: + selftests/bpf: Add struct send_recv_arg + +Avoid setting total_bytes and stop as global variables + Parent Hashes: d75142dbeb2bd1587b9cc19f841578f541275a64 + Refs: this patch adds +a new struct named send_recv_arg to pass arguments between threads. Put +these two variables together with fd into this struct and pass it to +server thread + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add struct send_recv_arg to pass arguments between threads in selftests/bpf.', 'keywords': 'selftests,bpf,struct', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f3408580bac8ce5cd76e7391e529c0a22e7c7eb2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f3408580bac8ce5cd76e7391e529c0a22e7c7eb2 + Author Name: Namhyung Kim + Author Email: namhyung@kernel.org + Commit Date: 1712856606 + Commit Message: + perf lock contention: Add a missing NULL check + +I got a report for a failure in BPF verifier on a recent kernel with +perf lock contention command. It checks task->sighand->siglock without +checking if sighand is NULL or not. Let's add one. + + ; if (&curr->sighand->siglock == (void *)lock) + 265: (79) r1 = *(u64 *)(r0 +2624) ; frame1: R0_w=trusted_ptr_task_struct(off=0 + Parent Hashes: 2b8dbf69ec60faf6c7db49e57d7f316409ccec92 + Refs: imm=0) + ; R1_w=rcu_ptr_or_null_sighand_struct(off=0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a NULL check in the perf lock contention command for a potential BPF verifier failure.', 'keywords': 'NULL check, BPF verifier, perf lock', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d75142dbeb2bd1587b9cc19f841578f541275a64 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d75142dbeb2bd1587b9cc19f841578f541275a64 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1712856565 + Commit Message: + selftests/bpf: Fix umount cgroup2 error in test_sockmap + +This patch fixes the following "umount cgroup2" error in test_sockmap.c: + + (cgroup_helpers.c:353: errno: Device or resource busy) umount cgroup2 + +Cgroup fd cg_fd should be closed before cleanup_cgroup_environment(). + +Fixes: 13a5f3ffd202 ("bpf: Selftests + Parent Hashes: ffa6b26b4d8a0520b78636ca9373ab842cb3b1a8 + Refs: sockmap test prog run without setting cgroup") +Signed-off-by: Geliang Tang +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/0399983bde729708773416b8488bac2cd5e022b8.1712639568.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit fixes an 'umount cgroup2' error in selftests related to BPF test_sockmap.", 'keywords': 'fix,selftests,cgroup2', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: b912cf042072e12e93faa874265b30cc0aa521b9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b912cf042072e12e93faa874265b30cc0aa521b9 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1712844121 + Commit Message: + HID: bpf: fix hid_bpf_input_report() when hid-core is not ready + +Reported by linux-next: +After merging the hid tree + Parent Hashes: 685dadafbde29dc3d6b7a13be284d684b06d4d4f + Refs: today's linux-next build (x86_64 allmodconfig) +failed like this: + +x86_64-linux-gnu-ld: vmlinux.o: in function `hid_bpf_input_report': +(.text+0x1c75181): undefined reference to `hid_input_report' + +Caused by commit 9be50ac30a83 ("HID: bpf: allow to inject HID event +from BPF") + +I just forgot to put the indirection in place. + +Link: https://lore.kernel.org/linux-kernel/20240411105131.7830f966@canb.auug.org.au/ +Fixes: 9be50ac30a83 ("HID: bpf: allow to inject HID event from BPF") +Link: https://lore.kernel.org/r/20240411-fix-hid-bpf-v1-1-4ae913031a8c@kernel.org +Signed-off-by: Benjamin Tissoires + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes HID BPF input report handling by adding necessary indirection when hid-core is not ready.', 'keywords': 'HID,BPF,fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: ffa6b26b4d8a0520b78636ca9373ab842cb3b1a8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ffa6b26b4d8a0520b78636ca9373ab842cb3b1a8 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1712804335 + Commit Message: + selftests/bpf: Enable tests for atomics with cpuv4 + +When looking at Alexei's patch ([1]) which added tests for atomics + Parent Hashes: ded8c00990b9f84e4daf4b3f4c881bace6cc990e + Refs: +I noticed that the tests will be skipped with cpuv4. For example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable selftests for atomic operations compatibility with cpuv4 in BPF.', 'keywords': 'selftests, atomics, cpuv4', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ded8c00990b9f84e4daf4b3f4c881bace6cc990e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ded8c00990b9f84e4daf4b3f4c881bace6cc990e + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712803946 + Commit Message: + Merge branch 'bpf-add-bpf_link-support-for-sk_msg-and-sk_skb-progs' + +Yonghong Song says: + +==================== +bpf: Add bpf_link support for sk_msg and sk_skb progs + +One of our internal services started to use sk_msg program and currently +it used existing prog attach/detach2 as demonstrated in selftests. +But attach/detach of all other bpf programs are based on bpf_link. +Consistent attach/detach APIs for all programs will make things easy to +undersand and less error prone. So this patch added bpf_link +support for BPF_PROG_TYPE_SK_MSG. Based on comments from +previous RFC patch + Parent Hashes: d0a2ba197bcbeaa795c5c961d927bcaf55964669 8ba218e625f0dfb3ef46fe0721dcdf565726ff76 + Refs: I added BPF_PROG_TYPE_SK_SKB support as well +as both program types have similar treatment w.r.t. bpf_link +handling. + +For the patch series + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added bpf_link support for sk_msg and sk_skb programs for consistent API usage.', 'keywords': 'bpf_link, sk_msg, sk_skb', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8ba218e625f0dfb3ef46fe0721dcdf565726ff76 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8ba218e625f0dfb3ef46fe0721dcdf565726ff76 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1712803945 + Commit Message: + selftests/bpf: Add some tests with new bpf_program__attach_sockmap() APIs + +Add a few more tests in sockmap_basic.c and sockmap_listen.c to +test bpf_link based APIs for SK_MSG and SK_SKB programs. +Link attach/detach/update are all tested. + +All tests are passed. + +Acked-by: Eduard Zingerman +Reviewed-by: John Fastabend +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043547.3738448-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: a15d58b2bc82abd8c4c994af158b0410424a18d3 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new tests for bpf_program__attach_sockmap() APIs in the selftests suite.', 'keywords': 'selftests, sockmap, APIs', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: a15d58b2bc82abd8c4c994af158b0410424a18d3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a15d58b2bc82abd8c4c994af158b0410424a18d3 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1712803945 + Commit Message: + selftests/bpf: Refactor out helper functions for a few tests + +These helper functions will be used later new tests as well. +There are no functionality change. + +Acked-by: Eduard Zingerman +Reviewed-by: John Fastabend +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043542.3738166-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 1f3e2091d25b2b140967480177fcaee2f0eebfb1 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor test cases by extracting helper functions for reuse in future tests without changing functionality.', 'keywords': 'selftests, refactor, helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 1f3e2091d25b2b140967480177fcaee2f0eebfb1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1f3e2091d25b2b140967480177fcaee2f0eebfb1 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1712803945 + Commit Message: + bpftool: Add link dump support for BPF_LINK_TYPE_SOCKMAP + +An example output looks like: + $ bpftool link + 1776: sk_skb prog 49730 + map_id 0 attach_type sk_skb_verdict + pids test_progs(8424) + 1777: sk_skb prog 49755 + map_id 0 attach_type sk_skb_stream_verdict + pids test_progs(8424) + 1778: sk_msg prog 49770 + map_id 8208 attach_type sk_msg_verdict + pids test_progs(8424) + +Reviewed-by: John Fastabend +Reviewed-by: Quentin Monnet +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043537.3737928-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 849989af61added13b2a9005608b1cf46f36f88b + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds support for link dumping of BPF_LINK_TYPE_SOCKMAP to bpftool.', 'keywords': 'bpftool, link dump, SOCKMAP', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 849989af61added13b2a9005608b1cf46f36f88b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 849989af61added13b2a9005608b1cf46f36f88b + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1712803945 + Commit Message: + libbpf: Add bpf_link support for BPF_PROG_TYPE_SOCKMAP + +Introduce a libbpf API function bpf_program__attach_sockmap() +which allow user to get a bpf_link for their corresponding programs. + +Acked-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Reviewed-by: John Fastabend +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043532.3737722-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 699c23f02c65cbfc3e638f14ce0d70c23a2e1f02 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces a new libbpf API function to attach BPF_PROG_TYPE_SOCKMAP using bpf_link.', 'keywords': 'bpf_link, sockmap, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 699c23f02c65cbfc3e638f14ce0d70c23a2e1f02 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 699c23f02c65cbfc3e638f14ce0d70c23a2e1f02 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1712803945 + Commit Message: + bpf: Add bpf_link support for sk_msg and sk_skb progs + +Add bpf_link support for sk_msg and sk_skb programs. We have an +internal request to support bpf_link for sk_msg programs so user +space can have a uniform handling with bpf_link based libbpf +APIs. Using bpf_link based libbpf API also has a benefit which +makes system robust by decoupling prog life cycle and +attachment life cycle. + +Reviewed-by: John Fastabend +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043527.3737160-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d0a2ba197bcbeaa795c5c961d927bcaf55964669 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add bpf_link support for sk_msg and sk_skb programs to enhance robustness and uniform handling with libbpf APIs.', 'keywords': 'bpf_link, sk_msg, sk_skb', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 414e576fb08f108b061cbc1fb964e51ff3467985 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 414e576fb08f108b061cbc1fb964e51ff3467985 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1712782994 + Commit Message: + Merge branch 'selftests-move-bpf-offload-test-from-bpf-to-net' + +Jakub Kicinski says: + +==================== +selftests: move bpf-offload test from bpf to net + +The test_offload.py test fits in networking and bpf equally +well. We started adding more Python tests in networking +and some of the code in test_offload.py can be reused + Parent Hashes: 2ecd487b670fcbb1ad4893fff1af4aafdecb6023 6ce2b689932ba8288ceef9a82c1caf029b0b23f9 + Refs: +so move it to networking. Looks like it bit rotted over +time and some fixes are needed. + +Admittedly more code could be extracted but I only had +the time for a minor cleanup :( +==================== + +Link: https://lore.kernel.org/r/20240409031549.3531084-1-kuba@kernel.org +Signed-off-by: Jakub Kicinski + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Move bpf-offload test from bpf to networking for better code reuse and minor cleanup.', 'keywords': 'bpf-offload, test, networking', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6ce2b689932ba8288ceef9a82c1caf029b0b23f9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6ce2b689932ba8288ceef9a82c1caf029b0b23f9 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1712782992 + Commit Message: + selftests: net: reuse common code in bpf_offload + +net/lib/py/nsim.py already contains the most useful parts +of the netdevsim wrapper classes. Reuse them. + +Acked-by: Stanislav Fomichev +Acked-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20240409031549.3531084-5-kuba@kernel.org +Signed-off-by: Jakub Kicinski + + Parent Hashes: b1c2ce11d42886d08cfa28e38ee07f2b606ced0b + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor bpf_offload self-tests to reuse existing code from netdevsim wrapper classes.', 'keywords': 'selftests, bpf_offload, netdevsim', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b1c2ce11d42886d08cfa28e38ee07f2b606ced0b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b1c2ce11d42886d08cfa28e38ee07f2b606ced0b + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1712782992 + Commit Message: + selftests: net: declare section names for bpf_offload + +Non-ancient ip (iproute2-5.15.0 + Parent Hashes: fc50c698c28bcf307dfb14ba9d0b3cacb091c1cb + Refs: libbpf 0.7.0) refuses to load +the sample with maps because we don't generate BTF: + + libbpf: BTF is required + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Declare section names for bpf_offload in selftests to ensure compatibility with newer iproute2 versions requiring BTF.', 'keywords': 'selftests, bpf_offload, BTF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fc50c698c28bcf307dfb14ba9d0b3cacb091c1cb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fc50c698c28bcf307dfb14ba9d0b3cacb091c1cb + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1712782992 + Commit Message: + selftests: net: bpf_offload: wait for maps + +Maps are removed asynchronously. Either there's a bigger delay +now or the test has always been flaky. Retry waiting in the loop. + +Acked-by: Stanislav Fomichev +Acked-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20240409031549.3531084-3-kuba@kernel.org +Signed-off-by: Jakub Kicinski + + Parent Hashes: e59f0e93e92e0ddfd17e3373d586218cf638571e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit modifies self-tests to add a wait loop for map removals due to asynchronous behavior.', 'keywords': 'selftests, maps, asynchronous', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e59f0e93e92e0ddfd17e3373d586218cf638571e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e59f0e93e92e0ddfd17e3373d586218cf638571e + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1712782992 + Commit Message: + selftests: move bpf-offload test from bpf to net + +We're building more python tests on the netdev side + Parent Hashes: 2ecd487b670fcbb1ad4893fff1af4aafdecb6023 + Refs: and some +of the classes from the venerable BPF offload tests can be reused. + +Acked-by: Stanislav Fomichev +Acked-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20240409031549.3531084-2-kuba@kernel.org +Signed-off-by: Jakub Kicinski + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit moves the bpf-offload test from bpf to net for improved reusability.', 'keywords': 'selftests,bpf-offload,net', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 685dadafbde29dc3d6b7a13be284d684b06d4d4f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 685dadafbde29dc3d6b7a13be284d684b06d4d4f + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1712759917 + Commit Message: + HID: bpf: allow to use bpf_timer_set_sleepable_cb() in tracing callbacks. + +Export the sleepable kfuncs we have on HID-BPF in tracing bpf programs + Parent Hashes: 2c0e8ced7d4bf746923fc424415844d695f07808 + Refs: +but with the condition of being used in a sleepable context. +This allows to use the bpf_timer when used in a sleepable context +through bpf_timer_set_sleepable_cb() and initiate work from a device event. + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-7-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable use of bpf_timer_set_sleepable_cb() in HID tracing bpf programs for sleepable contexts.', 'keywords': 'HID,BPF,sleepable', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 2c0e8ced7d4bf746923fc424415844d695f07808 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2c0e8ced7d4bf746923fc424415844d695f07808 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1712759917 + Commit Message: + selftests/hid: add tests for hid_bpf_input_report + +Usual way of testing + Parent Hashes: 9be50ac30a83896a753ab9f64e941763bb7900be + Refs: we call the function and ensures we receive +the event + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-6-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add self-tests for the hid_bpf_input_report function in HID driver.', 'keywords': 'selftests,hid_bpf_input_report,HID', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 9be50ac30a83896a753ab9f64e941763bb7900be +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9be50ac30a83896a753ab9f64e941763bb7900be + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1712759891 + Commit Message: + HID: bpf: allow to inject HID event from BPF + +It can be interesting to inject events from BPF as if the event were +to come from the device. +For example + Parent Hashes: db624e82c55f227b84ac9ebfa3de2f6f5fad666b + Refs: some multitouch devices do not all the time send a proximity +out event + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces the capability to inject HID events from eBPF, simulating device-originated events.', 'keywords': 'HID,BPF,event', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: db624e82c55f227b84ac9ebfa3de2f6f5fad666b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: db624e82c55f227b84ac9ebfa3de2f6f5fad666b + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1712759843 + Commit Message: + selftests/hid: Add test for hid_bpf_hw_output_report + +This time we need to ensure uhid receives it + Parent Hashes: c8a1495947ffcab18d9a85144ab4abc570720e65 + Refs: thus the new mutex and +condition. + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-4-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a selftest for HID to ensure uhid receives hid_bpf_hw_output_report correctly.', 'keywords': 'selftests,HID,uhid', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: c8a1495947ffcab18d9a85144ab4abc570720e65 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c8a1495947ffcab18d9a85144ab4abc570720e65 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1712759843 + Commit Message: + selftests/hid: add KASAN to the VM tests + +It's always a good idea to have KASAN in tests. + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-3-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires + + Parent Hashes: 5599f80196612efde96dbe6ef18f6ecc0cb4ba19 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds KASAN to the selftests for HID drivers in virtual machines.', 'keywords': 'KASAN,selftests,HID', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 5599f80196612efde96dbe6ef18f6ecc0cb4ba19 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5599f80196612efde96dbe6ef18f6ecc0cb4ba19 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1712759834 + Commit Message: + HID: bpf: export hid_hw_output_report as a BPF kfunc + +We currently only export hid_hw_raw_request() as a BPF kfunc. +However + Parent Hashes: 4171954f56fb6da8cc8ceebf54b78b874278a198 + Refs: some devices require an explicit write on the Output Report +instead of the use of the control channel. + +So also export hid_hw_output_report to BPF + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-2-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Export hid_hw_output_report as a BPF kfunc for HID support in eBPF.', 'keywords': 'HID,BPF,kfunc', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 4171954f56fb6da8cc8ceebf54b78b874278a198 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4171954f56fb6da8cc8ceebf54b78b874278a198 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1712759725 + Commit Message: + HID: bpf/dispatch: regroup kfuncs definitions + +No code change + Parent Hashes: 3e78a6c0d3e02e4cf881dc84c5127e9990f939d6 + Refs: just move down the hid_bpf_get_data() kfunc definition +so we have only one block of __bpf_kfunc_start/end_defs() + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-1-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit reorganizes HID BPF kfuncs definitions for cleaner code structure.', 'keywords': 'HID,bpf,kfuncs', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: d0a2ba197bcbeaa795c5c961d927bcaf55964669 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d0a2ba197bcbeaa795c5c961d927bcaf55964669 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712683466 + Commit Message: + selftests/bpf: Add tests for atomics in bpf_arena. + +Add selftests for atomic instructions in bpf_arena. + +Signed-off-by: Alexei Starovoitov +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240405231134.17274-2-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: d503a04f8bc0c75dc9db9452d8cc79d748afb752 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for atomic instructions used within bpf_arena.', 'keywords': 'selftests, atomics, bpf_arena', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d503a04f8bc0c75dc9db9452d8cc79d748afb752 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d503a04f8bc0c75dc9db9452d8cc79d748afb752 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712683466 + Commit Message: + bpf: Add support for certain atomics in bpf_arena to x86 JIT + +Support atomics in bpf_arena that can be JITed as a single x86 instruction. +Instructions that are JITed as loops are not supported at the moment + Parent Hashes: bb761fcb821738e8d3b720e1460d3783db74c68a + Refs: +since they require more complex extable and loop logic. + +JITs can choose to do smarter things with bpf_jit_supports_insn(). +Like arm64 may decide to support all bpf atomics instructions +when emit_lse_atomic is available and none in ll_sc mode. + +bpf_jit_supports_percpu_insn() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for atomics in bpf_arena to x86 JIT for single instruction execution.', 'keywords': 'atomics,JIT,bpf_arena', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b993115b44d769cb34b394d92658226df81a6c89 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b993115b44d769cb34b394d92658226df81a6c89 + Author Name: Paul E. McKenney + Author Email: paulmck@kernel.org + Commit Date: 1712668385 + Commit Message: + bpf: Select new NEED_TASKS_RCU Kconfig option + +Currently + Parent Hashes: 179f4ce102eb62b4b8efbd8371ee7d25c1082467 + Refs: if a Kconfig option depends on TASKS_RCU + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit selects the new Kconfig option NEED_TASKS_RCU for bpf.', 'keywords': 'Kconfig, NEED_TASKS_RCU, bpf', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: bb761fcb821738e8d3b720e1460d3783db74c68a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bb761fcb821738e8d3b720e1460d3783db74c68a + Author Name: Jason Xing + Author Email: kernelxing@tencent.com + Commit Date: 1712619078 + Commit Message: + selftests/bpf: eliminate warning of get_cgroup_id_from_path() + +The output goes like this if I make samples/bpf: +...warning: no previous prototype for ‘get_cgroup_id_from_path’... + +Make this function static could solve the warning problem since +no one outside of the file calls it. + +Signed-off-by: Jason Xing +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240406144613.4434-1-kerneljasonxing@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 50408d7abea68e2d1ae3a9328e1a468b7089b11c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit eliminates a prototype warning by making get_cgroup_id_from_path static in selftests/bpf.', 'keywords': 'selftests,bpf,warning', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 6648e613226e18897231ab5e42ffc29e63fa3365 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6648e613226e18897231ab5e42ffc29e63fa3365 + Author Name: Jason Xing + Author Email: kernelxing@tencent.com + Commit Date: 1712560702 + Commit Message: + bpf + Parent Hashes: 76cd338994778c552c51086fc056819b5cdda2e7 + Refs: skmsg: Fix NULL pointer dereference in sk_psock_skb_ingress_enqueue + +Fix NULL pointer data-races in sk_psock_skb_ingress_enqueue() which +syzbot reported [1]. + +[1] +BUG: KCSAN: data-race in sk_psock_drop / sk_psock_skb_ingress_enqueue + +write to 0xffff88814b3278b8 of 8 bytes by task 10724 on cpu 1: + sk_psock_stop_verdict net/core/skmsg.c:1257 [inline] + sk_psock_drop+0x13e/0x1f0 net/core/skmsg.c:843 + sk_psock_put include/linux/skmsg.h:459 [inline] + sock_map_close+0x1a7/0x260 net/core/sock_map.c:1648 + unix_release+0x4b/0x80 net/unix/af_unix.c:1048 + __sock_release net/socket.c:659 [inline] + sock_close+0x68/0x150 net/socket.c:1421 + __fput+0x2c1/0x660 fs/file_table.c:422 + __fput_sync+0x44/0x60 fs/file_table.c:507 + __do_sys_close fs/open.c:1556 [inline] + __se_sys_close+0x101/0x1b0 fs/open.c:1541 + __x64_sys_close+0x1f/0x30 fs/open.c:1541 + do_syscall_64+0xd3/0x1d0 + entry_SYSCALL_64_after_hwframe+0x6d/0x75 + +read to 0xffff88814b3278b8 of 8 bytes by task 10713 on cpu 0: + sk_psock_data_ready include/linux/skmsg.h:464 [inline] + sk_psock_skb_ingress_enqueue+0x32d/0x390 net/core/skmsg.c:555 + sk_psock_skb_ingress_self+0x185/0x1e0 net/core/skmsg.c:606 + sk_psock_verdict_apply net/core/skmsg.c:1008 [inline] + sk_psock_verdict_recv+0x3e4/0x4a0 net/core/skmsg.c:1202 + unix_read_skb net/unix/af_unix.c:2546 [inline] + unix_stream_read_skb+0x9e/0xf0 net/unix/af_unix.c:2682 + sk_psock_verdict_data_ready+0x77/0x220 net/core/skmsg.c:1223 + unix_stream_sendmsg+0x527/0x860 net/unix/af_unix.c:2339 + sock_sendmsg_nosec net/socket.c:730 [inline] + __sock_sendmsg+0x140/0x180 net/socket.c:745 + ____sys_sendmsg+0x312/0x410 net/socket.c:2584 + ___sys_sendmsg net/socket.c:2638 [inline] + __sys_sendmsg+0x1e9/0x280 net/socket.c:2667 + __do_sys_sendmsg net/socket.c:2676 [inline] + __se_sys_sendmsg net/socket.c:2674 [inline] + __x64_sys_sendmsg+0x46/0x50 net/socket.c:2674 + do_syscall_64+0xd3/0x1d0 + entry_SYSCALL_64_after_hwframe+0x6d/0x75 + +value changed: 0xffffffff83d7feb0 -> 0x0000000000000000 + +Reported by Kernel Concurrency Sanitizer on: +CPU: 0 PID: 10713 Comm: syz-executor.4 Tainted: G W 6.8.0-syzkaller-08951-gfe46a7dd189e #0 +Hardware name: Google Google Compute Engine/Google Compute Engine + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes data-race issues in sk_psock_skb_ingress_enqueue function to prevent NULL pointer dereference.', 'keywords': 'data-race,NULL pointer,sk_psock', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 50408d7abea68e2d1ae3a9328e1a468b7089b11c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 50408d7abea68e2d1ae3a9328e1a468b7089b11c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712423795 + Commit Message: + Merge branch 'libbpf-api-to-partially-consume-items-from-ringbuffer' + +Andrea Righi says: + +==================== +libbpf: API to partially consume items from ringbuffer + +Introduce ring__consume_n() and ring_buffer__consume_n() API to +partially consume items from one (or more) ringbuffer(s). + +This can be useful + Parent Hashes: d564ffde5c832c46513e0189647abfde9833e590 4d22ea94ea33550538b3b14429d52cb9f96ad2c3 + Refs: for example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce API to partially consume items from ringbuffer in libbpf.', 'keywords': 'libbpf, API, ringbuffer', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4d22ea94ea33550538b3b14429d52cb9f96ad2c3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4d22ea94ea33550538b3b14429d52cb9f96ad2c3 + Author Name: Andrea Righi + Author Email: andrea.righi@canonical.com + Commit Date: 1712419915 + Commit Message: + libbpf: Add ring__consume_n / ring_buffer__consume_n + +Introduce a new API to consume items from a ring buffer + Parent Hashes: 13e8125a22763557d719db996f70c71f77c9509c + Refs: limited to a +specified amount + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces a new API to consume multiple items from a ring buffer in libbpf.', 'keywords': 'libbpf,ring buffer,API', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 13e8125a22763557d719db996f70c71f77c9509c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 13e8125a22763557d719db996f70c71f77c9509c + Author Name: Andrea Righi + Author Email: andrea.righi@canonical.com + Commit Date: 1712419914 + Commit Message: + libbpf: ringbuf: Allow to consume up to a certain amount of items + +In some cases + Parent Hashes: 5bd2ed658231b0698211e94efb06393836a4539d + Refs: instead of always consuming all items from ring buffers +in a greedy way + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds an option to consume a specific number of items from libbpf ring buffers instead of all.', 'keywords': 'libbpf, ringbuf, consume', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5bd2ed658231b0698211e94efb06393836a4539d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5bd2ed658231b0698211e94efb06393836a4539d + Author Name: Andrea Righi + Author Email: andrea.righi@canonical.com + Commit Date: 1712419870 + Commit Message: + libbpf: Start v1.5 development cycle + +Bump libbpf.map to v1.5.0 to start a new libbpf version cycle. + +Signed-off-by: Andrea Righi +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240406092005.92399-2-andrea.righi@canonical.com + + Parent Hashes: d564ffde5c832c46513e0189647abfde9833e590 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Bump libbpf.map to v1.5.0 to initiate the new development cycle for libbpf.', 'keywords': 'libbpf development cycle', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 237f3cf13b20db183d3706d997eedc3c49eacd44 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 237f3cf13b20db183d3706d997eedc3c49eacd44 + Author Name: Eric Dumazet + Author Email: edumazet@google.com + Commit Date: 1712382442 + Commit Message: + xsk: validate user input for XDP_{UMEM|COMPLETION}_FILL_RING + +syzbot reported an illegal copy in xsk_setsockopt() [1] + +Make sure to validate setsockopt() @optlen parameter. + +[1] + + BUG: KASAN: slab-out-of-bounds in copy_from_sockptr_offset include/linux/sockptr.h:49 [inline] + BUG: KASAN: slab-out-of-bounds in copy_from_sockptr include/linux/sockptr.h:55 [inline] + BUG: KASAN: slab-out-of-bounds in xsk_setsockopt+0x909/0xa40 net/xdp/xsk.c:1420 +Read of size 4 at addr ffff888028c6cde3 by task syz-executor.0/7549 + +CPU: 0 PID: 7549 Comm: syz-executor.0 Not tainted 6.8.0-syzkaller-08951-gfe46a7dd189e #0 +Hardware name: Google Google Compute Engine/Google Compute Engine + Parent Hashes: 38a15d0a50e0a43778561a5861403851f0b0194c + Refs: BIOS Google 03/27/2024 +Call Trace: + + __dump_stack lib/dump_stack.c:88 [inline] + dump_stack_lvl+0x241/0x360 lib/dump_stack.c:114 + print_address_description mm/kasan/report.c:377 [inline] + print_report+0x169/0x550 mm/kasan/report.c:488 + kasan_report+0x143/0x180 mm/kasan/report.c:601 + copy_from_sockptr_offset include/linux/sockptr.h:49 [inline] + copy_from_sockptr include/linux/sockptr.h:55 [inline] + xsk_setsockopt+0x909/0xa40 net/xdp/xsk.c:1420 + do_sock_setsockopt+0x3af/0x720 net/socket.c:2311 + __sys_setsockopt+0x1ae/0x250 net/socket.c:2334 + __do_sys_setsockopt net/socket.c:2343 [inline] + __se_sys_setsockopt net/socket.c:2340 [inline] + __x64_sys_setsockopt+0xb5/0xd0 net/socket.c:2340 + do_syscall_64+0xfb/0x240 + entry_SYSCALL_64_after_hwframe+0x6d/0x75 +RIP: 0033:0x7fb40587de69 +Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48 +RSP: 002b:00007fb40665a0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000036 +RAX: ffffffffffffffda RBX: 00007fb4059abf80 RCX: 00007fb40587de69 +RDX: 0000000000000005 RSI: 000000000000011b RDI: 0000000000000006 +RBP: 00007fb4058ca47a R08: 0000000000000002 R09: 0000000000000000 +R10: 0000000020001980 R11: 0000000000000246 R12: 0000000000000000 +R13: 000000000000000b R14: 00007fb4059abf80 R15: 00007fff57ee4d08 + + +Allocated by task 7549: + kasan_save_stack mm/kasan/common.c:47 [inline] + kasan_save_track+0x3f/0x80 mm/kasan/common.c:68 + poison_kmalloc_redzone mm/kasan/common.c:370 [inline] + __kasan_kmalloc+0x98/0xb0 mm/kasan/common.c:387 + kasan_kmalloc include/linux/kasan.h:211 [inline] + __do_kmalloc_node mm/slub.c:3966 [inline] + __kmalloc+0x233/0x4a0 mm/slub.c:3979 + kmalloc include/linux/slab.h:632 [inline] + __cgroup_bpf_run_filter_setsockopt+0xd2f/0x1040 kernel/bpf/cgroup.c:1869 + do_sock_setsockopt+0x6b4/0x720 net/socket.c:2293 + __sys_setsockopt+0x1ae/0x250 net/socket.c:2334 + __do_sys_setsockopt net/socket.c:2343 [inline] + __se_sys_setsockopt net/socket.c:2340 [inline] + __x64_sys_setsockopt+0xb5/0xd0 net/socket.c:2340 + do_syscall_64+0xfb/0x240 + entry_SYSCALL_64_after_hwframe+0x6d/0x75 + +The buggy address belongs to the object at ffff888028c6cde0 + which belongs to the cache kmalloc-8 of size 8 +The buggy address is located 1 bytes to the right of + allocated 2-byte region [ffff888028c6cde0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes a bug by validating the optlen parameter in xsk_setsockopt to prevent slab-out-of-bounds errors.', 'keywords': 'validation, bugfix, xsk_setsockopt', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: d564ffde5c832c46513e0189647abfde9833e590 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d564ffde5c832c46513e0189647abfde9833e590 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712339944 + Commit Message: + Merge branch 'bpf-allow-invoking-kfuncs-from-bpf_prog_type_syscall-progs' + +David Vernet says: + +==================== +bpf: Allow invoking kfuncs from BPF_PROG_TYPE_SYSCALL progs + +Currently + Parent Hashes: 00d5d22a5b42c3ffdfd1b29526885bbcec2d2231 1bc724af00cc48ef03e3fa6d7a2f6731ac915c37 + Refs: a set of core BPF kfuncs (e.g. bpf_task_* + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enables invoking kfuncs from BPF_PROG_TYPE_SYSCALL programs.', 'keywords': 'kfuncs,BPF_PROG_TYPE_SYSCALL,invoke', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 1bc724af00cc48ef03e3fa6d7a2f6731ac915c37 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1bc724af00cc48ef03e3fa6d7a2f6731ac915c37 + Author Name: David Vernet + Author Email: void@manifault.com + Commit Date: 1712339890 + Commit Message: + selftests/bpf: Verify calling core kfuncs from BPF_PROG_TYPE_SYCALL + +Now that we can call some kfuncs from BPF_PROG_TYPE_SYSCALL progs + Parent Hashes: a8e03b6bbb2cc7cf387d1ce335e4ce4c3bdfef9b + Refs: let's +add some selftests that verify as much. As a bonus + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests to verify calling core kfuncs from BPF_PROG_TYPE_SYSCALL programs.', 'keywords': 'selftests,kfuncs,BPF_PROG_TYPE_SYSCALL', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a8e03b6bbb2cc7cf387d1ce335e4ce4c3bdfef9b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a8e03b6bbb2cc7cf387d1ce335e4ce4c3bdfef9b + Author Name: David Vernet + Author Email: void@manifault.com + Commit Date: 1712339769 + Commit Message: + bpf: Allow invoking kfuncs from BPF_PROG_TYPE_SYSCALL progs + +Currently + Parent Hashes: 00d5d22a5b42c3ffdfd1b29526885bbcec2d2231 + Refs: a set of core BPF kfuncs (e.g. bpf_task_* + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable kfunc invocation from BPF_PROG_TYPE_SYSCALL programs in eBPF.', 'keywords': 'kfuncs, BPF_PROG_TYPE_SYSCALL, eBPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 00d5d22a5b42c3ffdfd1b29526885bbcec2d2231 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 00d5d22a5b42c3ffdfd1b29526885bbcec2d2231 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1712338950 + Commit Message: + bpf + Parent Hashes: ba0cbe2bb4ab8aa266e48c6399bebf6e1217828a + Refs: docs: Editorial nits in instruction-set.rst + +This patch addresses a number of editorial nits including +spelling + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit addresses editorial nits and spelling corrections in the instruction-set documentation.', 'keywords': 'editorial, nits, spelling', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 76cd338994778c552c51086fc056819b5cdda2e7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 76cd338994778c552c51086fc056819b5cdda2e7 + Author Name: Björn Töpel + Author Email: bjorn@rivosinc.com + Commit Date: 1712338497 + Commit Message: + MAINTAINERS: bpf: Add Lehui and Puranjay as riscv64 reviewers + +Lehui and Puranjay have been active RISC-V 64-bit BPF JIT +contributors/reviewers for a long time! + +Let's make it more official by adding them as reviewers in +MAINTAINERS. + +Thank you for your hard work! + +Signed-off-by: Björn Töpel +Link: https://lore.kernel.org/r/20240405123352.2852393-1-bjorn@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: cfddb048040b598fa7df0e51ca361289fc7abf28 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds Lehui and Puranjay as official reviewers for the riscv64 BPF JIT in the MAINTAINERS file.', 'keywords': 'MAINTAINERS, riscv64, reviewers', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: ba0cbe2bb4ab8aa266e48c6399bebf6e1217828a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ba0cbe2bb4ab8aa266e48c6399bebf6e1217828a + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1712338398 + Commit Message: + selftests/bpf: Make sure libbpf doesn't enforce the signature of a func pointer. + +The verifier in the kernel ensures that the struct_ops operators behave +correctly by checking that they access parameters and context +appropriately. The verifier will approve a program as long as it correctly +accesses the context/parameters + Parent Hashes: 270954791c706b133a03b01e4b2d063dc870f704 + Refs: regardless of its function signature. In +contrast + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ensures libbpf does not enforce function pointer signatures in selftests.', 'keywords': 'libbpf,verifier,signature', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 270954791c706b133a03b01e4b2d063dc870f704 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 270954791c706b133a03b01e4b2d063dc870f704 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712338278 + Commit Message: + Merge branch 'bpf-allow-bpf_for_each_map_elem-helper-with-different-input-maps' + +Philo Lu says: + +==================== +bpf: allow bpf_for_each_map_elem() helper with different input maps + +Currently + Parent Hashes: 58babe27180c8d4cb54d831589cf801bd9268876 fecb1597cc11a23f32faa90d70a199533871686a + Refs: taking different maps within a single bpf_for_each_map_elem +call is not allowed. For example the following codes cannot pass the +verifier (with error "tail_call abusing map_ptr"): +``` +static void test_by_pid(int pid) +{ + if (pid <= 100) + bpf_for_each_map_elem(&map1 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows the use of bpf_for_each_map_elem() with different input maps in eBPF programs.', 'keywords': 'bpf, helper, maps', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fecb1597cc11a23f32faa90d70a199533871686a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fecb1597cc11a23f32faa90d70a199533871686a + Author Name: Philo Lu + Author Email: lulie@linux.alibaba.com + Commit Date: 1712338278 + Commit Message: + selftests/bpf: add test for bpf_for_each_map_elem() with different maps + +A test is added for bpf_for_each_map_elem() with either an arraymap or a +hashmap. +$ tools/testing/selftests/bpf/test_progs -t for_each + #93/1 for_each/hash_map:OK + #93/2 for_each/array_map:OK + #93/3 for_each/write_map_key:OK + #93/4 for_each/multi_maps:OK + #93 for_each:OK +Summary: 1/4 PASSED + Parent Hashes: 9d482da9e17a4ddd5563428f74302a36b2610306 + Refs: 0 SKIPPED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added selftests for bpf_for_each_map_elem() using arraymap and hashmap.', 'keywords': 'selftests,arraymap,hashmap', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9d482da9e17a4ddd5563428f74302a36b2610306 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9d482da9e17a4ddd5563428f74302a36b2610306 + Author Name: Philo Lu + Author Email: lulie@linux.alibaba.com + Commit Date: 1712338277 + Commit Message: + bpf: allow invoking bpf_for_each_map_elem with different maps + +Taking different maps within a single bpf_for_each_map_elem call is not +allowed before + Parent Hashes: 0a525621b7e5b49202b19d8f75382c6778fdd0c1 + Refs: because from the second map + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit allows invoking bpf_for_each_map_elem with different maps within a single use.', 'keywords': 'bpf,map,elements', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0a525621b7e5b49202b19d8f75382c6778fdd0c1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0a525621b7e5b49202b19d8f75382c6778fdd0c1 + Author Name: Philo Lu + Author Email: lulie@linux.alibaba.com + Commit Date: 1712338277 + Commit Message: + bpf: store both map ptr and state in bpf_insn_aux_data + +Currently + Parent Hashes: 58babe27180c8d4cb54d831589cf801bd9268876 + Refs: bpf_insn_aux_data->map_ptr_state is used to store either +map_ptr or its poison state (i.e. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies bpf_insn_aux_data to store both map pointer and state.', 'keywords': 'bpf, map_ptr, state', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 58babe27180c8d4cb54d831589cf801bd9268876 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 58babe27180c8d4cb54d831589cf801bd9268876 + Author Name: Arnd Bergmann + Author Email: arnd@arndb.de + Commit Date: 1712331555 + Commit Message: + bpf: fix perf_snapshot_branch_stack link failure + +The newly added code to handle bpf_get_branch_snapshot fails to link when +CONFIG_PERF_EVENTS is disabled: + +aarch64-linux-ld: kernel/bpf/verifier.o: in function `do_misc_fixups': +verifier.c:(.text+0x1090c): undefined reference to `__SCK__perf_snapshot_branch_stack' + +Add a build-time check for that Kconfig symbol around the code to +remove the link time dependency. + +Fixes: 314a53623cd4 ("bpf: inline bpf_get_branch_snapshot() helper") +Signed-off-by: Arnd Bergmann +Link: https://lore.kernel.org/r/20240405142637.577046-1-arnd@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 343ca8131c35ba132d200fd9752b60e65357924d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a linking error for bpf_get_branch_snapshot when CONFIG_PERF_EVENTS is disabled by adding a build-time check.', 'keywords': 'linking error, CONFIG_PERF_EVENTS, bpf_get_branch_snapshot', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cfddb048040b598fa7df0e51ca361289fc7abf28 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cfddb048040b598fa7df0e51ca361289fc7abf28 + Author Name: Puranjay Mohan + Author Email: puranjay@kernel.org + Commit Date: 1712324760 + Commit Message: + MAINTAINERS: Update email address for Puranjay Mohan + +I would like to use the kernel.org address for kernel development from +now on. + +Signed-off-by: Puranjay Mohan +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240405132337.71950-1-puranjay@kernel.org + + Parent Hashes: 229087f6f1dc2d0c38feba805770f28529980ec0 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update email address for Puranjay Mohan in the MAINTAINERS file.', 'keywords': 'MAINTAINERS update email', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 229087f6f1dc2d0c38feba805770f28529980ec0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 229087f6f1dc2d0c38feba805770f28529980ec0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712322767 + Commit Message: + bpf + Parent Hashes: c88b9b4cde17aec34fb9bfaf69f9f72a1c44f511 + Refs: kconfig: Fix DEBUG_INFO_BTF_MODULES Kconfig definition + +Turns out that due to CONFIG_DEBUG_INFO_BTF_MODULES not having an +explicitly specified "menu item name" in Kconfig + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed the Kconfig definition by specifying the menu item name for CONFIG_DEBUG_INFO_BTF_MODULES.', 'keywords': 'Kconfig, DEBUG_INFO_BTF_MODULES, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 343ca8131c35ba132d200fd9752b60e65357924d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 343ca8131c35ba132d200fd9752b60e65357924d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712280668 + Commit Message: + selftests/bpf: add fp-leaking precise subprog result tests + +Add selftests validating that BPF verifier handles precision marking +for SCALAR registers derived from r10 (fp) register correctly. + +Given `r0 = (s8)r10;` syntax is not supported by older Clang compilers + Parent Hashes: 1f2a74b41ea8b902687eb97c4e7e3f558801865b + Refs: +use the raw BPF instruction syntax to maximize compatibility. + +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240404214536.3551295-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests to ensure BPF verifier handles precision for SCALAR registers from r10 correctly.', 'keywords': 'selftests,BPF verifier,precision', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1f2a74b41ea8b902687eb97c4e7e3f558801865b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1f2a74b41ea8b902687eb97c4e7e3f558801865b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712280668 + Commit Message: + bpf: prevent r10 register from being marked as precise + +r10 is a special register that is not under BPF program's control and is +always effectively precise. The rest of precision logic assumes that +only r0-r9 SCALAR registers are marked as precise + Parent Hashes: f91717007217d975aa975ddabd91ae1a107b9bff + Refs: so prevent r10 from +being marked precise. + +This can happen due to signed cast instruction allowing to do something +like `r0 = (s8)r10;` + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Prevent r10 register from being incorrectly marked as precise in BPF programs.', 'keywords': 'r10, register, precise', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f91717007217d975aa975ddabd91ae1a107b9bff +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f91717007217d975aa975ddabd91ae1a107b9bff + Author Name: Anton Protopopov + Author Email: aspsk@isovalent.com + Commit Date: 1712271152 + Commit Message: + bpf: Pack struct bpf_fib_lookup + +The struct bpf_fib_lookup is supposed to be of size 64. A recent commit +59b418c7063d ("bpf: Add a check for struct bpf_fib_lookup size") added +a static assertion to check this property so that future changes to the +structure will not accidentally break this assumption. + +As it immediately turned out + Parent Hashes: 478a535ae54ad3831371904d93b5dfc403222e17 + Refs: on some 32-bit arm systems + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ensures that struct bpf_fib_lookup remains size 64 by packing it for compatibility with 32-bit systems.', 'keywords': 'struct bpf_fib_lookup, size 64, pack', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 478a535ae54ad3831371904d93b5dfc403222e17 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 478a535ae54ad3831371904d93b5dfc403222e17 + Author Name: Sahil Siddiq + Author Email: icegambit91@gmail.com + Commit Date: 1712270232 + Commit Message: + bpftool: Mount bpffs on provided dir instead of parent dir + +When pinning programs/objects under PATH (eg: during "bpftool prog +loadall") the bpffs is mounted on the parent dir of PATH in the +following situations: +- the given dir exists but it is not bpffs. +- the given dir doesn't exist and the parent dir is not bpffs. + +Mounting on the parent dir can also have the unintentional side- +effect of hiding other files located under the parent dir. + +If the given dir exists but is not bpffs + Parent Hashes: d82c045f9dfde6b9ea220d7f8310c98210dfc8cb + Refs: then the bpffs should +be mounted on the given dir and not its parent dir. + +Similarly + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Modified bpftool to mount bpffs on the provided directory instead of the parent directory when pinning programs.', 'keywords': 'bpftool, mount, bpffs', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['xdp like programs', 'socket like programs', 'cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: c88b9b4cde17aec34fb9bfaf69f9f72a1c44f511 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c88b9b4cde17aec34fb9bfaf69f9f72a1c44f511 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1712267350 + Commit Message: + Merge tag 'net-6.9-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + "Including fixes from netfilter + Parent Hashes: ec25bd8d981d910cdcc84914bf57e2cff9e7d63b 1cfa2f10f4e90a353c3ee2150866b4cf72579153 + Refs: bluetooth and bpf. + + Fairly usual collection of driver and core fixes. The large selftest + accompanying one of the fixes is also becoming a common occurrence. + + Current release - regressions: + + - ipv6: fix infinite recursion in fib6_dump_done() + + - net/rds: fix possible null-deref in newly added error path + + Current release - new code bugs: + + - net: do not consume a full cacheline for system_page_pool + + - bpf: fix bpf_arena-related file descriptor leaks in the verifier + + - drv: ice: fix freeing uninitialized pointers + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes including netfilter and driver core issues for ipv6, net, bpf, and ice.', 'keywords': 'networking, netfilter, bpf', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d82c045f9dfde6b9ea220d7f8310c98210dfc8cb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d82c045f9dfde6b9ea220d7f8310c98210dfc8cb + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712261281 + Commit Message: + Merge branch 'inline-bpf_get_branch_snapshot-bpf-helper' + +Andrii Nakryiko says: + +==================== +Inline bpf_get_branch_snapshot() BPF helper + +Implement inlining of bpf_get_branch_snapshot() BPF helper using generic BPF +assembly approach. This allows to reduce LBR record usage right before LBR +records are captured from inside BPF program. + +See v1 cover letter ([0]) for some visual examples. I dropped them from v2 +because there are multiple independent changes landing and being reviewed + Parent Hashes: 21ab0b6d0cfcb8aa98e33baa83f933f963514027 314a53623cd4e62e1b88126e5ed2bc87073d90ee + Refs: all +of which remove different parts of LBR record waste + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit merges inline implementation of bpf_get_branch_snapshot BPF helper to optimize LBR record usage in BPF programs.', 'keywords': 'inline, BPF helper, LBR', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 314a53623cd4e62e1b88126e5ed2bc87073d90ee +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 314a53623cd4e62e1b88126e5ed2bc87073d90ee + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712261281 + Commit Message: + bpf: inline bpf_get_branch_snapshot() helper + +Inline bpf_get_branch_snapshot() helper using architecture-agnostic +inline BPF code which calls directly into underlying callback of +perf_snapshot_branch_stack static call. This callback is set early +during kernel initialization and is never updated or reset + Parent Hashes: 5e6a3c1ee693da1793739bb378b224bcf33d7f14 + Refs: so it's ok +to fetch actual implementation using static_call_query() and call +directly into it. + +This change eliminates a full function call and saves one LBR entry +in PERF_SAMPLE_BRANCH_ANY LBR mode. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240404002640.1774210-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Inline bpf_get_branch_snapshot() helper to improve performance by reducing function calls and saving LBR entries.', 'keywords': 'inline helper performance', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', "It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 5e6a3c1ee693da1793739bb378b224bcf33d7f14 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5e6a3c1ee693da1793739bb378b224bcf33d7f14 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712261281 + Commit Message: + bpf: make bpf_get_branch_snapshot() architecture-agnostic + +perf_snapshot_branch_stack is set up in an architecture-agnostic way + Parent Hashes: 21ab0b6d0cfcb8aa98e33baa83f933f963514027 + Refs: so +there is no reason for BPF subsystem to keep track of which +architectures do support LBR or not. E.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors bpf_get_branch_snapshot to be architecture-agnostic, eliminating architecture-specific tracking for LBR support.', 'keywords': 'architecture-agnostic, bpf_get_branch_snapshot, LBR', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1cfa2f10f4e90a353c3ee2150866b4cf72579153 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1cfa2f10f4e90a353c3ee2150866b4cf72579153 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1712255859 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-04-04 + +We've added 7 non-merge commits during the last 5 day(s) which contain +a total of 9 files changed + Parent Hashes: 0c83842df40f86e529db6842231154772c20edcc ff91059932401894e6c86341915615c5eb0eca48 + Refs: 75 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "This commit merges the 'for-netdev' branch from the BPF repository into the mainline.", 'keywords': 'merge, netdev, bpf', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0c83842df40f86e529db6842231154772c20edcc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0c83842df40f86e529db6842231154772c20edcc + Author Name: Eric Dumazet + Author Email: edumazet@google.com + Commit Date: 1712248792 + Commit Message: + netfilter: validate user input for expected length + +I got multiple syzbot reports showing old bugs exposed +by BPF after commit 20f2505fb436 ("bpf: Try to avoid kzalloc +in cgroup/{s + Parent Hashes: d432f7bdc1cddd37e73dbe6b53b48785ab789e92 + Refs: g}etsockopt") + +setsockopt() @optlen argument should be taken into account +before copying data. + + BUG: KASAN: slab-out-of-bounds in copy_from_sockptr_offset include/linux/sockptr.h:49 [inline] + BUG: KASAN: slab-out-of-bounds in copy_from_sockptr include/linux/sockptr.h:55 [inline] + BUG: KASAN: slab-out-of-bounds in do_replace net/ipv4/netfilter/ip_tables.c:1111 [inline] + BUG: KASAN: slab-out-of-bounds in do_ipt_set_ctl+0x902/0x3dd0 net/ipv4/netfilter/ip_tables.c:1627 +Read of size 96 at addr ffff88802cd73da0 by task syz-executor.4/7238 + +CPU: 1 PID: 7238 Comm: syz-executor.4 Not tainted 6.9.0-rc2-next-20240403-syzkaller #0 +Hardware name: Google Google Compute Engine/Google Compute Engine + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds validation for user input length in the netfilter to prevent buffer overflows.', 'keywords': 'netfilter,validation,buffer overflow', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 21ab0b6d0cfcb8aa98e33baa83f933f963514027 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 21ab0b6d0cfcb8aa98e33baa83f933f963514027 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1712242122 + Commit Message: + bpf + Parent Hashes: 633a6e01d1a20b24a16899094c249a8cb2aad4b2 + Refs: riscv: Implement bpf_addr_space_cast instruction + +LLVM generates bpf_addr_space_cast instruction while translating +pointers between native (zero) address space and +__attribute__((address_space(N))). The addr_space=0 is reserved as +bpf_arena address space. + +rY = addr_space_cast(rX + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement bpf_addr_space_cast instruction for RISC-V in LLVM for handling address space translations.', 'keywords': 'bpf, addr_space_cast, RISC-V', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 633a6e01d1a20b24a16899094c249a8cb2aad4b2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 633a6e01d1a20b24a16899094c249a8cb2aad4b2 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1712242090 + Commit Message: + bpf + Parent Hashes: af682b767a41772499f8e54ca7d7e1deb3395f44 + Refs: riscv: Implement PROBE_MEM32 pseudo instructions + +Add support for [LDX | STX | ST] + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement PROBE_MEM32 pseudo instructions for riscv architecture in bpf.', 'keywords': 'riscv, PROBE_MEM32, pseudo', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: af682b767a41772499f8e54ca7d7e1deb3395f44 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: af682b767a41772499f8e54ca7d7e1deb3395f44 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712240006 + Commit Message: + bpf: Optimize emit_mov_imm64(). + +Turned out that bpf prog callback addresses + Parent Hashes: 1e9e0b85255e6eca6036b59d8a5fbca6501905ac + Refs: bpf prog addresses +used in bpf_trampoline + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize bpf_trampoline by improving emit_mov_imm64 function for bpf prog callback addresses.', 'keywords': 'Optimize, emit_mov_imm64, bpf_trampoline', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1e9e0b85255e6eca6036b59d8a5fbca6501905ac +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1e9e0b85255e6eca6036b59d8a5fbca6501905ac + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712205395 + Commit Message: + bpf: handle CONFIG_SMP=n configuration in x86 BPF JIT + +On non-SMP systems + Parent Hashes: 519e1de94b719f741e0de42b085b9a4551c5b15c + Refs: there is no "per-CPU" data + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix handling of per-CPU data in the x86 BPF JIT for non-SMP systems.', 'keywords': 'x86, BPF JIT, non-SMP', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4793cb599b1bdc3d356f0374c2c99ffe890ae876 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4793cb599b1bdc3d356f0374c2c99ffe890ae876 + Author Name: Tianchen Ding + Author Email: dtcccc@linux.alibaba.com + Commit Date: 1712173333 + Commit Message: + selftests: cgroup: skip test_cgcore_lesser_ns_open when cgroup2 mounted without nsdelegate + +The test case test_cgcore_lesser_ns_open only tasks effect when cgroup2 +is mounted with "nsdelegate" mount option. If it misses this option + Parent Hashes: 20d46283f5d679338ec2bbd734f46f900557fb97 + Refs: or +is remounted without "nsdelegate" + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Skip test_cgcore_lesser_ns_open if cgroup2 is mounted without nsdelegate.', 'keywords': 'skip,cgroup2,nsdelegate', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 519e1de94b719f741e0de42b085b9a4551c5b15c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 519e1de94b719f741e0de42b085b9a4551c5b15c + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712165413 + Commit Message: + Merge branch 'add-internal-only-bpf-per-cpu-instruction' + +Andrii Nakryiko says: + +==================== +Add internal-only BPF per-CPU instruction + +Add a new BPF instruction for resolving per-CPU memory addresses. + +New instruction is a special form of BPF_ALU64 | BPF_MOV | BPF_X + Parent Hashes: 2e114248e086fb376405ed3f89b220f8586a2541 0b56e637f705836b9aa51e2b1058c3c814c121a8 + Refs: with +insns->off set to BPF_ADDR_PERCPU (== -1). It resolves provided per-CPU offset +to an absolute address where per-CPU data resides for "this" CPU. + +This patch set implements support for it in x86-64 BPF JIT only. + +Using the new instruction + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added an internal-only BPF instruction for resolving per-CPU memory addresses in x86-64 BPF JIT.', 'keywords': 'BPF instruction, per-CPU address, x86-64 JIT', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0b56e637f705836b9aa51e2b1058c3c814c121a8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0b56e637f705836b9aa51e2b1058c3c814c121a8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712165396 + Commit Message: + bpf: inline bpf_map_lookup_elem() helper for PERCPU_HASH map + +Using new per-CPU BPF instruction + Parent Hashes: db69718b8efac802c7cc20d5a6c7dfc913f99c43 + Refs: partially inline +bpf_map_lookup_elem() helper for per-CPU hashmap BPF map. Just like for +normal HASH map + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Inline the bpf_map_lookup_elem() helper for per-CPU HASH maps using a new BPF instruction.', 'keywords': 'inline, per-CPU, BPF map', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: db69718b8efac802c7cc20d5a6c7dfc913f99c43 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: db69718b8efac802c7cc20d5a6c7dfc913f99c43 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712165396 + Commit Message: + bpf: inline bpf_map_lookup_elem() for PERCPU_ARRAY maps + +Using new per-CPU BPF instruction implement inlining for per-CPU ARRAY +map lookup helper + Parent Hashes: 1ae6921009e5d72787e07ccc04754514ccf6bc99 + Refs: if BPF JIT support is present. + +Signed-off-by: Andrii Nakryiko +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240402021307.1012571-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implemented inlining of bpf_map_lookup_elem() for PERCPU_ARRAY maps using new per-CPU BPF instruction.', 'keywords': 'inline,elements,PERCPU_ARRAY', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1ae6921009e5d72787e07ccc04754514ccf6bc99 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1ae6921009e5d72787e07ccc04754514ccf6bc99 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712165396 + Commit Message: + bpf: inline bpf_get_smp_processor_id() helper + +If BPF JIT supports per-CPU MOV instruction + Parent Hashes: 7bdbf7446305cb65c510c16d57cde82bc76b234a + Refs: inline bpf_get_smp_processor_id() +to eliminate unnecessary function calls. + +Signed-off-by: Andrii Nakryiko +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240402021307.1012571-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Inlined bpf_get_smp_processor_id() helper in BPF for efficiency if JIT supports per-CPU MOV instruction.', 'keywords': 'BPF, inline, efficiency', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7bdbf7446305cb65c510c16d57cde82bc76b234a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7bdbf7446305cb65c510c16d57cde82bc76b234a + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712165395 + Commit Message: + bpf: add special internal-only MOV instruction to resolve per-CPU addrs + +Add a new BPF instruction for resolving absolute addresses of per-CPU +data from their per-CPU offsets. This instruction is internal-only and +users are not allowed to use them directly. They will only be used for +internal inlining optimizations for now between BPF verifier and BPF JITs. + +We use a special BPF_MOV | BPF_ALU64 | BPF_X form with insn->off field +set to BPF_ADDR_PERCPU = -1. I used negative offset value to distinguish +them from positive ones used by user-exposed instructions. + +Such instruction performs a resolution of a per-CPU offset stored in +a register to a valid kernel address which can be dereferenced. It is +useful in any use case where absolute address of a per-CPU data has to +be resolved (e.g. + Parent Hashes: 2e114248e086fb376405ed3f89b220f8586a2541 + Refs: in inlining bpf_map_lookup_elem()). + +BPF disassembler is also taught to recognize them to support dumping +final BPF assembly code (non-JIT'ed version). + +Add arch-specific way for BPF JITs to mark support for this instructions. + +This patch also adds support for these instructions in x86-64 BPF JIT. + +Signed-off-by: Andrii Nakryiko +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240402021307.1012571-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a special internal-only MOV instruction for per-CPU address resolution in eBPF.', 'keywords': 'BPF instruction, per-CPU, MOV', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2e114248e086fb376405ed3f89b220f8586a2541 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2e114248e086fb376405ed3f89b220f8586a2541 + Author Name: Justin Stitt + Author Email: justinstitt@google.com + Commit Date: 1712156261 + Commit Message: + bpf: Replace deprecated strncpy with strscpy + +strncpy() is deprecated for use on NUL-terminated destination strings +[1] and as such we should prefer more robust and less ambiguous string +interfaces. + +bpf sym names get looked up and compared/cleaned with various string +apis. This suggests they need to be NUL-terminated (strncpy() suggests +this but does not guarantee it). + +| static int compare_symbol_name(const char *name + Parent Hashes: c53908b254fcf25b05bcdf6634adb36eaccac111 + Refs: char *namebuf) +| { +| cleanup_symbol_name(namebuf); +| return strcmp(name + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaced deprecated strncpy with strscpy for safer string handling in bpf symbol names.', 'keywords': 'deprecated, strncpy, strscpy', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 98f69a573c668a18cfda41b3976118e04521a196 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 98f69a573c668a18cfda41b3976118e04521a196 + Author Name: Namhyung Kim + Author Email: namhyung@kernel.org + Commit Date: 1712155737 + Commit Message: + perf annotate: Split out util/disasm.c + +The util/annotate.c code has both disassembly and sample annotation +related codes. Factor out the disasm part so that it can be handled +more easily. + +No functional changes intended. + +Committer notes: + +Add missing include env.h + Parent Hashes: 10adbf777622e22323abbf9f7861c26deb373199 + Refs: util.h + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors the code by splitting disassembly logic from util/annotate.c into util/disasm.c for better maintainability.', 'keywords': 'refactor, disassembly, annotate', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 09d2056efe0c02b7a589915c004c6e925735d081 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 09d2056efe0c02b7a589915c004c6e925735d081 + Author Name: Yang Jihong + Author Email: yangjihong@bytedance.com + Commit Date: 1712155736 + Commit Message: + perf evsel: Use evsel__name_is() helper + +Code cleanup + Parent Hashes: 6e4b398770d5023eb6383da9360a23bd537c155b + Refs: replace strcmp(evsel__name(evsel + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors code by replacing `strcmp` with the `evsel__name_is()` helper for improved code readability.', 'keywords': 'perf, evsel, helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The JIT compiler', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c53908b254fcf25b05bcdf6634adb36eaccac111 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c53908b254fcf25b05bcdf6634adb36eaccac111 + Author Name: Tushar Vyavahare + Author Email: tushar.vyavahare@intel.com + Commit Date: 1712153054 + Commit Message: + selftests/xsk: Add new test case for AF_XDP under max ring sizes + +Introduce a test case to evaluate AF_XDP's robustness by pushing hardware +and software ring sizes to their limits. This test ensures AF_XDP's +reliability amidst potential producer/consumer throttling due to maximum +ring utilization. The testing strategy includes: + +1. Configuring rings to their maximum allowable sizes. +2. Executing a series of tests across diverse batch sizes to assess + system's behavior under different configurations. + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-8-tushar.vyavahare@intel.com + + Parent Hashes: c4f960539fae6f04617d3909cc0dfdb88e7d197b + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "A new test case evaluates AF_XDP's robustness under maximum ring sizes in selftests.", 'keywords': 'AF_XDP, test case, ring sizes', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: c4f960539fae6f04617d3909cc0dfdb88e7d197b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c4f960539fae6f04617d3909cc0dfdb88e7d197b + Author Name: Tushar Vyavahare + Author Email: tushar.vyavahare@intel.com + Commit Date: 1712153045 + Commit Message: + selftests/xsk: Test AF_XDP functionality under minimal ring configurations + +Add a new test case that stresses AF_XDP and the driver by configuring +small hardware and software ring sizes. This verifies that AF_XDP continues +to function properly even with insufficient ring space that could lead +to frequent producer/consumer throttling. The test procedure involves: + +1. Set the minimum possible ring configuration(tx 64 and rx 128). +2. Run tests with various batch sizes(1 and 63) to validate the system's + behavior under different configurations. + +Update Makefile to include network_helpers.o in the build process for +xskxceiver. + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-7-tushar.vyavahare@intel.com + + Parent Hashes: 776021e07fd0d7592c767e60929b954e82676186 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds a test for AF_XDP functionality under minimal ring configurations by updating Makefile and testing with various batch sizes.', 'keywords': 'AF_XDP,minimal ring,test case', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 776021e07fd0d7592c767e60929b954e82676186 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 776021e07fd0d7592c767e60929b954e82676186 + Author Name: Tushar Vyavahare + Author Email: tushar.vyavahare@intel.com + Commit Date: 1712153037 + Commit Message: + selftests/xsk: Introduce set_ring_size function with a retry mechanism for handling AF_XDP socket closures + +Introduce a new function + Parent Hashes: bee3a7b07624223526c1fea465557068546d3b3c + Refs: set_ring_size() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce a set_ring_size function with retry mechanism for AF_XDP socket closures in selftests.', 'keywords': 'set_ring_size,retry mechanism,AF_XDP', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: bee3a7b07624223526c1fea465557068546d3b3c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bee3a7b07624223526c1fea465557068546d3b3c + Author Name: Tushar Vyavahare + Author Email: tushar.vyavahare@intel.com + Commit Date: 1712153033 + Commit Message: + selftests/bpf: Implement set_hw_ring_size function to configure interface ring size + +Introduce a new function called set_hw_ring_size that allows for the +dynamic configuration of the ring size within the interface. + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-5-tushar.vyavahare@intel.com + + Parent Hashes: 90a695c3d31e1c9f0adb8c4c80028ed4ea7ed5ab + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement set_hw_ring_size function to adjust interface ring size dynamically.', 'keywords': 'set_hw_ring_size, interface, ring size', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 90a695c3d31e1c9f0adb8c4c80028ed4ea7ed5ab +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 90a695c3d31e1c9f0adb8c4c80028ed4ea7ed5ab + Author Name: Tushar Vyavahare + Author Email: tushar.vyavahare@intel.com + Commit Date: 1712153017 + Commit Message: + selftests/bpf: Implement get_hw_ring_size function to retrieve current and max interface size + +Introduce a new function called get_hw_size that retrieves both the +current and maximum size of the interface and stores this information +in the 'ethtool_ringparam' structure. + +Remove ethtool_channels struct from xdp_hw_metadata.c due to redefinition +error. Remove unused linux/if.h include from flow_dissector BPF test to +address CI pipeline failure. + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-4-tushar.vyavahare@intel.com + + Parent Hashes: c3bd015090f24dcd2e839db1401e948ad95ce803 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implemented get_hw_ring_size function in BPF selftests to manage interface size configurations and resolved CI-related issues.', 'keywords': 'get_hw_ring_size, ethtool_ringparam, selftests', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs', 'tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: c3bd015090f24dcd2e839db1401e948ad95ce803 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c3bd015090f24dcd2e839db1401e948ad95ce803 + Author Name: Tushar Vyavahare + Author Email: tushar.vyavahare@intel.com + Commit Date: 1712152857 + Commit Message: + selftests/xsk: Make batch size variable + +Convert the constant BATCH_SIZE into a variable named batch_size to allow +dynamic modification at runtime. This is required for the forthcoming +changes to support testing different hardware ring sizes. + +While running these tests + Parent Hashes: 7effe3fdc049a34c56a68671100b5570e53e8f0a + Refs: a bug was identified when the batch size is +roughly the same as the NIC ring size. This has now been addressed by +Maciej's fix in commit 913eda2b08cc ("i40e: xsk: remove count_mask"). + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-3-tushar.vyavahare@intel.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit changes the BATCH_SIZE constant to a variable to support dynamic modification for testing different hardware ring sizes.', 'keywords': 'batch_size,dynamic,testing', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 7effe3fdc049a34c56a68671100b5570e53e8f0a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7effe3fdc049a34c56a68671100b5570e53e8f0a + Author Name: Tushar Vyavahare + Author Email: tushar.vyavahare@intel.com + Commit Date: 1712152814 + Commit Message: + tools: Add ethtool.h header to tooling infra + +This commit duplicates the ethtool.h file from the include/uapi/linux +directory in the kernel source to the tools/include/uapi/linux directory. + +This action ensures that the ethtool.h file used in the tools directory +is in sync with the kernel's version + Parent Hashes: 49b73fa623c47302befecba0c2c310739ed0a088 + Refs: maintaining consistency across the +codebase. + +There are some checkpatch warnings in this file that could be cleaned up + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Duplicate ethtool.h header to sync tools with kernel version.', 'keywords': 'ethtool,sync,header', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 49b73fa623c47302befecba0c2c310739ed0a088 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 49b73fa623c47302befecba0c2c310739ed0a088 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712112351 + Commit Message: + Merge branch 'bpf-arm64-add-support-for-bpf-arena' + +Puranjay Mohan says: + +==================== +bpf + Parent Hashes: c07b4bcd5163c2929d8bfc55140325fc15afb4eb 4dd31243e30843d5f63bccfb0369146e4de1a130 + Refs: arm64: Add support for BPF Arena + +Changes in V4 +V3: https://lore.kernel.org/bpf/20240323103057.26499-1-puranjay12@gmail.com/ +- Use more descriptive variable names. +- Use insn_is_cast_user() helper. + +Changes in V3 +V2: https://lore.kernel.org/bpf/20240321153102.103832-1-puranjay12@gmail.com/ +- Optimize bpf_addr_space_cast as suggested by Xu Kuohai + +Changes in V2 +V1: https://lore.kernel.org/bpf/20240314150003.123020-1-puranjay12@gmail.com/ +- Fix build warnings by using 5 in place of 32 as DONT_CLEAR marker. + R5 is not mapped to any BPF register so it can safely be used here. + +This series adds the support for PROBE_MEM32 and bpf_addr_space_cast +instructions to the ARM64 BPF JIT. These two instructions allow the +enablement of BPF Arena. + +All arena related selftests are passing. + + [root@ip-172-31-6-62 bpf]# ./test_progs -a "*arena*" + #3/1 arena_htab/arena_htab_llvm:OK + #3/2 arena_htab/arena_htab_asm:OK + #3 arena_htab:OK + #4/1 arena_list/arena_list_1:OK + #4/2 arena_list/arena_list_1000:OK + #4 arena_list:OK + #434/1 verifier_arena/basic_alloc1:OK + #434/2 verifier_arena/basic_alloc2:OK + #434/3 verifier_arena/basic_alloc3:OK + #434/4 verifier_arena/iter_maps1:OK + #434/5 verifier_arena/iter_maps2:OK + #434/6 verifier_arena/iter_maps3:OK + #434 verifier_arena:OK + Summary: 3/10 PASSED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit merges support for BPF Arena into the ARM64 BPF JIT with successful selftests.', 'keywords': 'BPF Arena, ARM64, JIT', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4dd31243e30843d5f63bccfb0369146e4de1a130 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4dd31243e30843d5f63bccfb0369146e4de1a130 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1712112350 + Commit Message: + bpf: Add arm64 JIT support for bpf_addr_space_cast instruction. + +LLVM generates bpf_addr_space_cast instruction while translating +pointers between native (zero) address space and +__attribute__((address_space(N))). The addr_space=0 is reserved as +bpf_arena address space. + +rY = addr_space_cast(rX + Parent Hashes: 339af577ec05c8fc0b96f23579614ae853d913ab + Refs: 0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add ARM64 JIT support for the bpf_addr_space_cast instruction.', 'keywords': 'ARM64,JIT,bpf_addr_space_cast', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 339af577ec05c8fc0b96f23579614ae853d913ab +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 339af577ec05c8fc0b96f23579614ae853d913ab + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1712112350 + Commit Message: + bpf: Add arm64 JIT support for PROBE_MEM32 pseudo instructions. + +Add support for [LDX | STX | ST] + Parent Hashes: c07b4bcd5163c2929d8bfc55140325fc15afb4eb + Refs: PROBE_MEM32 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support for arm64 JIT for PROBE_MEM32 pseudo instructions in eBPF.', 'keywords': 'arm64,JIT,PROBE_MEM32', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c07b4bcd5163c2929d8bfc55140325fc15afb4eb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c07b4bcd5163c2929d8bfc55140325fc15afb4eb + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1712077549 + Commit Message: + selftests/bpf: Add pid limit for mptcpify prog + +In order to prevent mptcpify prog from affecting the running results +of other BPF tests + Parent Hashes: 15ea39ad7e83af16480bbf20144fcc6edf4757f9 + Refs: a pid limit was added to restrict it from only +modifying its own program. + +Suggested-by: Martin KaFai Lau +Signed-off-by: Geliang Tang +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/8987e2938e15e8ec390b85b5dcbee704751359dc.1712054986.git.tanggeliang@kylinos.cn + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a pid limit to mptcpify program to prevent interference with other BPF tests.', 'keywords': 'pid limit, mptcpify, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 15ea39ad7e83af16480bbf20144fcc6edf4757f9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 15ea39ad7e83af16480bbf20144fcc6edf4757f9 + Author Name: Tobias Böhm + Author Email: tobias@aibor.de + Commit Date: 1712075314 + Commit Message: + libbpf: Use local bpf_helpers.h include + +Commit 20d59ee55172fdf6 ("libbpf: add bpf_core_cast() macro") added a +bpf_helpers include in bpf_core_read.h as a system include. Usually + Parent Hashes: ce09cbdd988887662546a1175bcfdfc6c8fdd150 + Refs: the +includes are local + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Change the inclusion of bpf_helpers.h to a local include in libbpf.', 'keywords': 'local, bpf_helpers, include', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ce09cbdd988887662546a1175bcfdfc6c8fdd150 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ce09cbdd988887662546a1175bcfdfc6c8fdd150 + Author Name: Jose Fernandez + Author Email: josef@netflix.com + Commit Date: 1712069475 + Commit Message: + bpf: Improve program stats run-time calculation + +This patch improves the run-time calculation for program stats by +capturing the duration as soon as possible after the program returns. + +Previously + Parent Hashes: c186ed12a8ec498532d13de43094bdec9ac6f121 + Refs: the duration included u64_stats_t operations. While the +instrumentation overhead is part of the total time spent when stats are +enabled + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve run-time calculation by capturing program stats duration earlier.', 'keywords': 'run-time,program,stats', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ff91059932401894e6c86341915615c5eb0eca48 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ff91059932401894e6c86341915615c5eb0eca48 + Author Name: Jakub Sitnicki + Author Email: jakub@cloudflare.com + Commit Date: 1712068265 + Commit Message: + bpf + Parent Hashes: 8c3fe029d79ada599fa558fdf3da0322fc38de36 + Refs: sockmap: Prevent lock inversion deadlock in map delete elem + +syzkaller started using corpuses where a BPF tracing program deletes +elements from a sockmap/sockhash map. Because BPF tracing programs can be +invoked from any interrupt context + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Prevent lock inversion deadlock in sockmap/sockhash map element deletion by BPF tracing programs.', 'keywords': 'lock inversion, deadlock, sockmap', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c186ed12a8ec498532d13de43094bdec9ac6f121 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c186ed12a8ec498532d13de43094bdec9ac6f121 + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1712068168 + Commit Message: + selftests/bpf: Skip test when perf_event_open returns EOPNOTSUPP + +When testing send_signal and stacktrace_build_id_nmi using the riscv sbi +pmu driver without the sscofpmf extension or the riscv legacy pmu driver + Parent Hashes: 2a24e2485722b0e12e17a2bd473bd15c9e420bdb + Refs: +then failures as follows are encountered: + + test_send_signal_common:FAIL:perf_event_open unexpected perf_event_open: actual -1 < expected 0 + #272/3 send_signal/send_signal_nmi:FAIL + + test_stacktrace_build_id_nmi:FAIL:perf_event_open err -1 errno 95 + #304 stacktrace_build_id_nmi:FAIL + +The reason is that the above pmu driver or hardware does not support +sampling events + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies test scripts to skip tests when perf_event_open returns EOPNOTSUPP due to unsupported sampling events in certain RISC-V configurations.', 'keywords': 'selftests,bpf,EOPNOTSUPP', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 2a24e2485722b0e12e17a2bd473bd15c9e420bdb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2a24e2485722b0e12e17a2bd473bd15c9e420bdb + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1712067649 + Commit Message: + bpftool: Use __typeof__() instead of typeof() in BPF skeleton + +When generated BPF skeleton header is included in C++ code base + Parent Hashes: 965c6167c93f3fac53e25807f83c07e87b3c085a + Refs: some +compiler setups will emit warning about using language extensions due to +typeof() usage + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaces typeof() with __typeof__() in BPF skeleton to avoid compiler warnings in C++ code.', 'keywords': 'bpftool, compiler, BPF', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 965c6167c93f3fac53e25807f83c07e87b3c085a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 965c6167c93f3fac53e25807f83c07e87b3c085a + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1712067240 + Commit Message: + selftests/bpf: Using llvm may_goto inline asm for cond_break macro + +Currently + Parent Hashes: 9dc182c58b5f5d4ac125ac85ad553f7142aa08d4 + Refs: cond_break macro uses bytes to encode the may_goto insn. +Patch [1] in llvm implemented may_goto insn in BPF backend. +Replace byte-level encoding with llvm inline asm for better usability. +Using llvm may_goto insn is controlled by macro __BPF_FEATURE_MAY_GOTO. + + [1] https://github.com/llvm/llvm-project/commit/0e0bfacff71859d1f9212205f8f873d47029d3fb + +Signed-off-by: Yonghong Song +Signed-off-by: Daniel Borkmann +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240402025446.3215182-1-yonghong.song@linux.dev + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates the cond_break macro to use llvm inline assembly for better usability.', 'keywords': 'llvm, inline asm, may_goto', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 9dc182c58b5f5d4ac125ac85ad553f7142aa08d4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9dc182c58b5f5d4ac125ac85ad553f7142aa08d4 + Author Name: Anton Protopopov + Author Email: aspsk@isovalent.com + Commit Date: 1712067120 + Commit Message: + bpf: Add a verbose message if map limit is reached + +When more than 64 maps are used by a program and its subprograms the +verifier returns -E2BIG. Add a verbose message which highlights the +source of the error and also print the actual limit. + +Signed-off-by: Anton Protopopov +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240402073347.195920-1-aspsk@isovalent.com + + Parent Hashes: ca4ddc26f8acaa9cb451fcb20f7ab0f02e4970cb + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds a verbose message for map limit exceeded errors in the bpf verifier.', 'keywords': 'verbose, verifier, maps', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ca4ddc26f8acaa9cb451fcb20f7ab0f02e4970cb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ca4ddc26f8acaa9cb451fcb20f7ab0f02e4970cb + Author Name: David Lechner + Author Email: dlechner@baylibre.com + Commit Date: 1712066674 + Commit Message: + bpf: Fix typo in uapi doc comments + +In a few places in the bpf uapi headers + Parent Hashes: a70f5d840a56a82c576385ca79ee55c1598f1bc3 + Refs: EOPNOTSUPP is missing a "P" in +the doc comments. This adds the missing "P". + +Signed-off-by: David Lechner +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240329152900.398260-2-dlechner@baylibre.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed a typo in the bpf uapi doc comments by adding a missing "P".', 'keywords': 'bpf, typo, doc comments', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: a70f5d840a56a82c576385ca79ee55c1598f1bc3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a70f5d840a56a82c576385ca79ee55c1598f1bc3 + Author Name: Rameez Rehman + Author Email: rameezrehman408@hotmail.com + Commit Date: 1712065823 + Commit Message: + bpftool: Clean-up typos + Parent Hashes: ea379b3ccc2e4dff9c3d616f0611b5312fe389ad + Refs: punctuation + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit cleans up typographical errors in the bpftool utility.', 'keywords': 'bpftool,cleanup,typos', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: ea379b3ccc2e4dff9c3d616f0611b5312fe389ad +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ea379b3ccc2e4dff9c3d616f0611b5312fe389ad + Author Name: Rameez Rehman + Author Email: rameezrehman408@hotmail.com + Commit Date: 1712065823 + Commit Message: + bpftool: Remove useless emphasis on command description in man pages + +As it turns out + Parent Hashes: f7b68543642136164ce7348945d3ada707c4e635 + Refs: the terms in definition lists in the rST file are +already rendered with bold-ish formatting when generating the man pages; +all double-star sequences we have in the commands for the command +description are unnecessary + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit removes unnecessary bold formatting from command descriptions in bpftool man pages.', 'keywords': 'bpftool,man pages,formatting', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: f7b68543642136164ce7348945d3ada707c4e635 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f7b68543642136164ce7348945d3ada707c4e635 + Author Name: Rameez Rehman + Author Email: rameezrehman408@hotmail.com + Commit Date: 1712065823 + Commit Message: + bpftool: Use simpler indentation in source rST for documentation + +The rST manual pages for bpftool would use a mix of tabs and spaces for +indentation. While this is the norm in C code + Parent Hashes: 623bdd58be3727318d374f0052f9dfff1e87b854 + Refs: this is rather unusual +for rST documents + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Simplified indentation in bpftool's rST documentation by standardizing to spaces.", 'keywords': 'bpftool, rST, indentation', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: fcf4692fa39e86a590c14a4af2de704e1d20a3b5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fcf4692fa39e86a590c14a4af2de704e1d20a3b5 + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1712029404 + Commit Message: + mptcp: prevent BPF accessing lowat from a subflow socket. + +Alexei reported the following splat: + + WARNING: CPU: 32 PID: 3276 at net/mptcp/subflow.c:1430 subflow_data_ready+0x147/0x1c0 + Modules linked in: dummy bpf_testmod(O) [last unloaded: bpf_test_no_cfi(O)] + CPU: 32 PID: 3276 Comm: test_progs Tainted: GO 6.8.0-12873-g2c43c33bfd23 + Call Trace: + + mptcp_set_rcvlowat+0x79/0x1d0 + sk_setsockopt+0x6c0/0x1540 + __bpf_setsockopt+0x6f/0x90 + bpf_sock_ops_setsockopt+0x3c/0x90 + bpf_prog_509ce5db2c7f9981_bpf_test_sockopt_int+0xb4/0x11b + bpf_prog_dce07e362d941d2b_bpf_test_socket_sockopt+0x12b/0x132 + bpf_prog_348c9b5faaf10092_skops_sockopt+0x954/0xe86 + __cgroup_bpf_run_filter_sock_ops+0xbc/0x250 + tcp_connect+0x879/0x1160 + tcp_v6_connect+0x50c/0x870 + mptcp_connect+0x129/0x280 + __inet_stream_connect+0xce/0x370 + inet_stream_connect+0x36/0x50 + bpf_trampoline_6442491565+0x49/0xef + inet_stream_connect+0x5/0x50 + __sys_connect+0x63/0x90 + __x64_sys_connect+0x14/0x20 + +The root cause of the issue is that bpf allows accessing mptcp-level +proto_ops from a tcp subflow scope. + +Fix the issue detecting the problematic call and preventing any action. + +Reported-by: Alexei Starovoitov +Closes: https://github.com/multipath-tcp/mptcp_net-next/issues/482 +Fixes: 5684ab1a0eff ("mptcp: give rcvlowat some love") +Signed-off-by: Paolo Abeni +Reviewed-by: Mat Martineau +Reviewed-by: Matthieu Baerts (NGI0) +Link: https://lore.kernel.org/r/d8cb7d8476d66cb0812a6e29cd1e626869d9d53e.1711738080.git.pabeni@redhat.com +Signed-off-by: Jakub Kicinski + + Parent Hashes: 31974122cfdeaf56abc18d8ab740d580d9833e90 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix to prevent BPF from accessing lowat from a subflow socket in MPTCP.', 'keywords': 'MPTCP,BPF,lowat', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 8c3fe029d79ada599fa558fdf3da0322fc38de36 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8c3fe029d79ada599fa558fdf3da0322fc38de36 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1712029077 + Commit Message: + Merge branch 'x86-bpf-fixes-for-the-bpf-jit-with-retbleed-stuff' + +Joan Bruguera Micó says: + +==================== +x86/bpf: Fixes for the BPF JIT with retbleed=stuff + +From: Joan Bruguera Micó + +Fixes two issues that cause kernels panic when using the BPF JIT with +the call depth tracking / stuffing mitigation for Skylake processors +(`retbleed=stuff`). Both issues can be triggered by running simple +BPF programs (e.g. running the test suite should trigger both). + +The first (resubmit) fixes a trivial issue related to calculating the +destination IP for call instructions with call depth tracking. + +The second is related to using the correct IP for relocations + Parent Hashes: 6dae957c8eef6eae5b386462767de97303235d5c 6a537453000a916392fcac1acb96c1d9d1e05b74 + Refs: related +to the recently introduced %rip-relative addressing for PER_CPU_VAR. + +Cc: Alexei Starovoitov +Cc: Daniel Borkmann +--- +v2: + Simplify calculation of "ip". + Add more details to the commit message. + +Joan Bruguera Micó (1): + x86/bpf: Fix IP for relocating call depth accounting +==================== + +Link: https://lore.kernel.org/r/20240401185821.224068-1-ubizjak@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes issues causing kernel crashes when using BPF JIT with retbleed mitigation on Skylake processors.', 'keywords': 'BPF JIT, retbleed, Skylake', 'commit_classification': "It's a bug fix.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6a537453000a916392fcac1acb96c1d9d1e05b74 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6a537453000a916392fcac1acb96c1d9d1e05b74 + Author Name: Joan Bruguera Micó + Author Email: joanbrugueram@gmail.com + Commit Date: 1712029076 + Commit Message: + x86/bpf: Fix IP for relocating call depth accounting + +The commit: + + 59bec00ace28 ("x86/percpu: Introduce %rip-relative addressing to PER_CPU_VAR()") + +made PER_CPU_VAR() to use rip-relative addressing + Parent Hashes: 9d98aa088386aee3db1b7b60b800c0fde0654a4a + Refs: hence +INCREMENT_CALL_DEPTH macro and skl_call_thunk_template got rip-relative +asm code inside of it. A follow up commit: + + 17bce3b2ae2d ("x86/callthunks: Handle %rip-relative relocations in call thunk template") + +changed x86_call_depth_emit_accounting() to use apply_relocation() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix IP alignment in x86 BPF by handling RIP-relative relocations in call depth accounting.', 'keywords': 'x86, BPF, relocation', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9d98aa088386aee3db1b7b60b800c0fde0654a4a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9d98aa088386aee3db1b7b60b800c0fde0654a4a + Author Name: Uros Bizjak + Author Email: ubizjak@gmail.com + Commit Date: 1712029076 + Commit Message: + x86/bpf: Fix IP after emitting call depth accounting + +Adjust the IP passed to `emit_patch` so it calculates the correct offset +for the CALL instruction if `x86_call_depth_emit_accounting` emits code. +Otherwise we will skip some instructions and most likely crash. + +Fixes: b2e9dfe54be4 ("x86/bpf: Emit call depth accounting if required") +Link: https://lore.kernel.org/lkml/20230105214922.250473-1-joanbrugueram@gmail.com/ +Co-developed-by: Joan Bruguera Micó +Signed-off-by: Joan Bruguera Micó +Signed-off-by: Uros Bizjak +Cc: Alexei Starovoitov +Cc: Daniel Borkmann +Link: https://lore.kernel.org/r/20240401185821.224068-2-ubizjak@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 6dae957c8eef6eae5b386462767de97303235d5c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes instruction pointer offset calculation for x86 BPF call depth accounting.', 'keywords': 'IP,call depth,x86', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: d29a8134c78232213fb88f20d7ae865ec364e367 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d29a8134c78232213fb88f20d7ae865ec364e367 + Author Name: Michal Schmidt + Author Email: mschmidt@redhat.com + Commit Date: 1711987089 + Commit Message: + ice: avoid the PTP hardware semaphore in gettimex64 path + +The PTP hardware semaphore (PFTSYN_SEM) is used to synchronize +operations that program the PTP timers. The operations involve issuing +commands to the sideband queue. The E810 does not have a hardware +sideband queue + Parent Hashes: 0e2bddf9e5f926ce32ed635012d0f8a0b54075d5 + Refs: so the admin queue is used. The admin queue is slow. +I have observed delays in hundreds of milliseconds waiting for +ice_sq_done. + +When phc2sys reads the time from the ice PTP clock and PFTSYN_SEM is +held by a task performing one of the slow operations + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve gettimex64 path by avoiding PTP hardware semaphore in ice driver to reduce delays.', 'keywords': 'PTP hardware, ice driver, semaphore', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 623bdd58be3727318d374f0052f9dfff1e87b854 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 623bdd58be3727318d374f0052f9dfff1e87b854 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711757910 + Commit Message: + selftests/bpf: make multi-uprobe tests work in RELEASE=1 mode + +When BPF selftests are built in RELEASE=1 mode with -O2 optimization +level + Parent Hashes: 59f2f841179aa6a0899cb9cf53659149a35749b7 + Refs: uprobe_multi binary + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve multi-uprobe tests compatibility with RELEASE=1 optimization mode.', 'keywords': 'selftests,uprobe,RELEASE', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 59f2f841179aa6a0899cb9cf53659149a35749b7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 59f2f841179aa6a0899cb9cf53659149a35749b7 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1711735841 + Commit Message: + bpf: Avoid kfree_rcu() under lock in bpf_lpm_trie. + +syzbot reported the following lock sequence: +cpu 2: + grabs timer_base lock + spins on bpf_lpm lock + +cpu 1: + grab rcu krcp lock + spins on timer_base lock + +cpu 0: + grab bpf_lpm lock + spins on rcu krcp lock + +bpf_lpm lock can be the same. +timer_base lock can also be the same due to timer migration. +but rcu krcp lock is always per-cpu + Parent Hashes: 201874fc064ef14c26ea87a890b3f58296750d2d + Refs: so it cannot be the same lock. +Hence it's a false positive. +To avoid lockdep complaining move kfree_rcu() after spin_unlock. + +Reported-by: syzbot+1fa663a2100308ab6eab@syzkaller.appspotmail.com +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240329171439.37813-1-alexei.starovoitov@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes a lock ordering issue by moving kfree_rcu() outside of the spinlock in bpf_lpm_trie.', 'keywords': 'bpf_lpm_trie, lock, kfree_rcu', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 6dae957c8eef6eae5b386462767de97303235d5c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6dae957c8eef6eae5b386462767de97303235d5c + Author Name: Anton Protopopov + Author Email: aspsk@isovalent.com + Commit Date: 1711729195 + Commit Message: + bpf: fix possible file descriptor leaks in verifier + +The resolve_pseudo_ldimm64() function might have leaked file +descriptors when BPF_MAP_TYPE_ARENA was used in a program (some +error paths missed a corresponding fdput). Add missing fdputs. + +v2: + remove unrelated changes from the fix + +Fixes: 6082b6c328b5 ("bpf: Recognize addr_space_cast instruction in the verifier.") +Signed-off-by: Anton Protopopov +Acked-by: Yonghong Song +Acked-by: Shung-Hsi Yu +Link: https://lore.kernel.org/r/20240329071106.67968-1-aspsk@isovalent.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 62248b22d01e96a4d669cde0d7005bd51ebf9e76 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes file descriptor leaks in verifier for BPF_MAP_TYPE_ARENA programs.', 'keywords': 'verifier, file descriptors, BPF_MAP_TYPE_ARENA', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 201874fc064ef14c26ea87a890b3f58296750d2d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 201874fc064ef14c26ea87a890b3f58296750d2d + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1711678335 + Commit Message: + Merge branch 'Use start_server and connect_fd_to_fd' + +Geliang Tang says: + +==================== +Simplify bpf_tcp_ca test by using connect_fd_to_fd and start_server +helpers. + +v4: + - Matt reminded me that I shouldn't send a square-to patch to BPF (thanks) + Parent Hashes: e8742081db7d01f980c6161ae1e8a1dbc1e30979 426670929fda4485a23094e03cea5d9b3ca918aa + Refs: + so I update them into two patches in v4. + +v3: + - split v2 as two patches as Daniel suggested. + - The patch "selftests/bpf: Use start_server in bpf_tcp_ca" is merged + by Daniel (thanks) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Simplify bpf_tcp_ca test using connect_fd_to_fd and start_server helpers.', 'keywords': 'simplify, bpf_tcp_ca, helpers', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 426670929fda4485a23094e03cea5d9b3ca918aa +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 426670929fda4485a23094e03cea5d9b3ca918aa + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1711678335 + Commit Message: + selftests/bpf: Drop settimeo in do_test + +settimeo is invoked in start_server() and in connect_fd_to_fd() already + Parent Hashes: e5e1a3aa56773d55dfb71c4d58176bc19ecfa739 + Refs: +no need to invoke settimeo(lfd + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove unnecessary settimeo invocation from selftests in BPF test suite.', 'keywords': 'settimeo,test,removal', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e5e1a3aa56773d55dfb71c4d58176bc19ecfa739 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e5e1a3aa56773d55dfb71c4d58176bc19ecfa739 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1711678334 + Commit Message: + selftests/bpf: Use connect_fd_to_fd in bpf_tcp_ca + +To simplify the code + Parent Hashes: e8742081db7d01f980c6161ae1e8a1dbc1e30979 + Refs: use BPF selftests helper connect_fd_to_fd() in +bpf_tcp_ca.c instead of open-coding it. This helper is defined in +network_helpers.c + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Simplifies bpf_tcp_ca selftest by using connect_fd_to_fd helper from network_helpers.', 'keywords': 'selftests, connect_fd_to_fd, simplify', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e8742081db7d01f980c6161ae1e8a1dbc1e30979 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e8742081db7d01f980c6161ae1e8a1dbc1e30979 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1711677659 + Commit Message: + bpf: Mark bpf prog stack with kmsan_unposion_memory in interpreter mode + +syzbot reported uninit memory usages during map_{lookup + Parent Hashes: e478cf26c556e4ab572ab0ab2306c986901dcd61 + Refs: delete}_elem. + +========== +BUG: KMSAN: uninit-value in __dev_map_lookup_elem kernel/bpf/devmap.c:441 [inline] +BUG: KMSAN: uninit-value in dev_map_lookup_elem+0xf3/0x170 kernel/bpf/devmap.c:796 +__dev_map_lookup_elem kernel/bpf/devmap.c:441 [inline] +dev_map_lookup_elem+0xf3/0x170 kernel/bpf/devmap.c:796 +____bpf_map_lookup_elem kernel/bpf/helpers.c:42 [inline] +bpf_map_lookup_elem+0x5c/0x80 kernel/bpf/helpers.c:38 +___bpf_prog_run+0x13fe/0xe0f0 kernel/bpf/core.c:1997 +__bpf_prog_run256+0xb5/0xe0 kernel/bpf/core.c:2237 +========== + +The reproducer should be in the interpreter mode. + +The C reproducer is trying to run the following bpf prog: + + 0: (18) r0 = 0x0 + 2: (18) r1 = map[id:49] + 4: (b7) r8 = 16777216 + 5: (7b) *(u64 *)(r10 -8) = r8 + 6: (bf) r2 = r10 + 7: (07) r2 += -229 + ^^^^^^^^^^ + + 8: (b7) r3 = 8 + 9: (b7) r4 = 0 + 10: (85) call dev_map_lookup_elem#1543472 + 11: (95) exit + +It is due to the "void *key" (r2) passed to the helper. bpf allows uninit +stack memory access for bpf prog with the right privileges. This patch +uses kmsan_unpoison_memory() to mark the stack as initialized. + +This should address different syzbot reports on the uninit "void *key" +argument during map_{lookup + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit marks BPF program stack with kmsan_unpoison_memory in interpreter mode to address uninitialized memory usage during map lookups.', 'keywords': 'kmsan_unpoison_memory, uninit-memory, interpreter', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1a80dbcb2dbaf6e4c216e62e30fa7d3daa8001ce +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1a80dbcb2dbaf6e4c216e62e30fa7d3daa8001ce + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711676865 + Commit Message: + bpf: support deferring bpf_link dealloc to after RCU grace period + +BPF link for some program types is passed as a "context" which can be +used by those BPF programs to look up additional information. E.g. + Parent Hashes: e9c856cabefb71d47b2eeb197f72c9c88e9b45b0 + Refs: for +multi-kprobes and multi-uprobes + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Support added for deferring bpf_link deallocation to post RCU grace period in eBPF.', 'keywords': 'bpf_link, RCU, deallocation', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: e9c856cabefb71d47b2eeb197f72c9c88e9b45b0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e9c856cabefb71d47b2eeb197f72c9c88e9b45b0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711676865 + Commit Message: + bpf: put uprobe link's path and task in release callback + +There is no need to delay putting either path or task to deallocation +step. It can be done right after bpf_uprobe_unregister. Between release +and dealloc + Parent Hashes: 037965402a010898d34f4e35327d22c0a95cd51f + Refs: there could be still some running BPF programs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Optimize allocation timing for uprobe link's path and task in BPF.", 'keywords': 'uprobe,release,deallocation', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: e478cf26c556e4ab572ab0ab2306c986901dcd61 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e478cf26c556e4ab572ab0ab2306c986901dcd61 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1711675901 + Commit Message: + Merge branch 'bpf-fix-a-couple-of-test-failures-with-lto-kernel' + +Yonghong Song says: + +==================== +bpf: Fix a couple of test failures with LTO kernel + +With a LTO kernel built with clang + Parent Hashes: 5da7fb04902b0f0fcd13bc5ef216e232fa971efa 6302bdeb91df9b4484b9d537c29f8b6117f3f73d + Refs: with one of earlier version of kernel + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix test failures in BPF with LTO kernel built using clang.', 'keywords': 'fix, LTO, test failures', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6302bdeb91df9b4484b9d537c29f8b6117f3f73d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6302bdeb91df9b4484b9d537c29f8b6117f3f73d + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711675901 + Commit Message: + selftests/bpf: Add a kprobe_multi subtest to use addrs instead of syms + +Get addrs directly from available_filter_functions_addrs and +send to the kernel during kprobe_multi_attach. This avoids +consultation of /proc/kallsyms. But available_filter_functions_addrs +is introduced in 6.5 + Parent Hashes: 9edaafadc2c50f2af99ee5b3bad6831e1b6ad54f + Refs: i.e. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a subtest for kprobe_multi using direct addresses instead of symbols in selftests/bpf.', 'keywords': 'kprobe_multi, addresses, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 9edaafadc2c50f2af99ee5b3bad6831e1b6ad54f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9edaafadc2c50f2af99ee5b3bad6831e1b6ad54f + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711675901 + Commit Message: + selftests/bpf: Fix kprobe_multi_bench_attach test failure with LTO kernel + +In my locally build clang LTO kernel (enabling CONFIG_LTO and +CONFIG_LTO_CLANG_THIN) + Parent Hashes: d1f02581059e42d8daf944aae2a296254cc7a5d5 + Refs: kprobe_multi_bench_attach/kernel subtest +failed like: + test_kprobe_multi_bench_attach:PASS:get_syms 0 nsec + test_kprobe_multi_bench_attach:PASS:kprobe_multi_empty__open_and_load 0 nsec + libbpf: prog 'test_kprobe_empty': failed to attach: No such process + test_kprobe_multi_bench_attach:FAIL:bpf_program__attach_kprobe_multi_opts unexpected error: -3 + #117/1 kprobe_multi_bench_attach/kernel:FAIL + +There are multiple symbols in /sys/kernel/debug/tracing/available_filter_functions +are renamed in /proc/kallsyms due to cross file inlining. One example is for + static function __access_remote_vm in mm/memory.c. +In a non-LTO kernel + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes test failure in kprobe_multi_bench_attach due to symbol renaming in LTO kernels.', 'keywords': 'kprobe_multi,LTO,fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: d1f02581059e42d8daf944aae2a296254cc7a5d5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d1f02581059e42d8daf944aae2a296254cc7a5d5 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711675901 + Commit Message: + selftests/bpf: Add {load + Parent Hashes: 9475dacb75e0b5efae086dc904f4d27c31f15157 + Refs: search}_kallsyms_custom_local() + +These two functions allow selftests to do loading/searching +kallsyms based on their specific compare functions. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041513.1199440-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'New functions added for loading and searching kallsyms for selftests in the BPF subsystem.', 'keywords': 'selftests, kallsyms, functions', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9475dacb75e0b5efae086dc904f4d27c31f15157 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9475dacb75e0b5efae086dc904f4d27c31f15157 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711675901 + Commit Message: + selftests/bpf: Refactor trace helper func load_kallsyms_local() + +Refactor trace helper function load_kallsyms_local() such that +it invokes a common function with a compare function as input. +The common function will be used later for other local functions. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041508.1199239-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d1320649346c36c5ba7b579533bf518960ef71e1 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor trace helper function to use a common function with a comparison input for future usage.', 'keywords': 'refactor, trace, helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: d1320649346c36c5ba7b579533bf518960ef71e1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d1320649346c36c5ba7b579533bf518960ef71e1 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711675901 + Commit Message: + selftests/bpf: Refactor some functions for kprobe_multi_test + +Refactor some functions in kprobe_multi_test.c to extract +some helper functions who will be used in later patches +to avoid code duplication. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041503.1198982-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: c56e59776f46d77984329488878a52baf4969457 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor functions in kprobe_multi_test.c to create reusable helpers for future patches, reducing code duplication.', 'keywords': 'refactor, kprobe, helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: c56e59776f46d77984329488878a52baf4969457 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c56e59776f46d77984329488878a52baf4969457 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711675901 + Commit Message: + libbpf: Handle .llvm. symbol properly + +With CONFIG_LTO_CLANG_THIN enabled + Parent Hashes: ad2b05286e94485070475e473963724fa657491c + Refs: with some of previous +version of kernel code base ([1]) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Handles the .llvm. symbol properly in libbpf with CONFIG_LTO_CLANG_THIN enabled.', 'keywords': 'libbpf symbol handling', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ad2b05286e94485070475e473963724fa657491c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ad2b05286e94485070475e473963724fa657491c + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711675901 + Commit Message: + libbpf: Mark libbpf_kallsyms_parse static function + +Currently libbpf_kallsyms_parse() function is declared as a global +function but actually it is not a API and there is no external +users in bpftool/bpf-selftests. So let us mark the function as +static. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041453.1197949-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: cdfd9cc3ba147ceea650afa6b7031e31a98d500e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit marks libbpf_kallsyms_parse function as static since it is not used externally.', 'keywords': 'libbpf,static,function', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cdfd9cc3ba147ceea650afa6b7031e31a98d500e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cdfd9cc3ba147ceea650afa6b7031e31a98d500e + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711675901 + Commit Message: + selftests/bpf: Replace CHECK with ASSERT macros for ksyms test + +Replace CHECK with ASSERT macros for ksyms tests. +This test failed earlier with clang lto kernel + Parent Hashes: 5da7fb04902b0f0fcd13bc5ef216e232fa971efa + Refs: but the +issue is gone with latest code base. But replacing +CHECK with ASSERT still improves code as ASSERT is +preferred in selftests. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041448.1197812-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaced CHECK with ASSERT macros in ksyms test for improved code quality in selftests.', 'keywords': 'ASSERT, ksyms, selftests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 5da7fb04902b0f0fcd13bc5ef216e232fa971efa +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5da7fb04902b0f0fcd13bc5ef216e232fa971efa + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1711675900 + Commit Message: + selftests/bpf: Test loading bpf-tcp-cc prog calling the kernel tcp-cc kfuncs + +This patch adds a test to ensure all static tcp-cc kfuncs is visible to +the struct_ops bpf programs. It is checked by successfully loading +the struct_ops programs calling these tcp-cc kfuncs. + +This patch needs to enable the CONFIG_TCP_CONG_DCTCP and +the CONFIG_TCP_CONG_BBR. + +Signed-off-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20240322191433.4133280-2-martin.lau@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 42e4ebd390be8e0090d64d58433b6cba45d919e9 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test for bpf-tcp-cc programs using kernel tcp-cc kfuncs.', 'keywords': 'bpf-tcp-cc,kfuncs,struct_ops', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 42e4ebd390be8e0090d64d58433b6cba45d919e9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 42e4ebd390be8e0090d64d58433b6cba45d919e9 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1711675900 + Commit Message: + bpf: Remove CONFIG_X86 and CONFIG_DYNAMIC_FTRACE guard from the tcp-cc kfuncs + +The commit 7aae231ac93b ("bpf: tcp: Limit calling some tcp cc functions to CONFIG_DYNAMIC_FTRACE") +added CONFIG_DYNAMIC_FTRACE guard because pahole was only generating +btf for ftrace-able functions. The ftrace filter had already been +removed from pahole + Parent Hashes: ee3bad033d01066348913f3220ea81987721ed53 + Refs: so the CONFIG_DYNAMIC_FTRACE guard can be +removed. + +The commit 569c484f9995 ("bpf: Limit static tcp-cc functions in the .BTF_ids list to x86") +has added CONFIG_X86 guard because it failed the powerpc arch which +prepended a "." to the local static function + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit removes configuration guards from tcp-cc kfuncs due to changes in ftrace requirements.', 'keywords': 'CONFIG_X86,CONFIG_DYNAMIC_FTRACE,kfuncs', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: ee3bad033d01066348913f3220ea81987721ed53 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ee3bad033d01066348913f3220ea81987721ed53 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1711675900 + Commit Message: + bpf: Mitigate latency spikes associated with freeing non-preallocated htab + +Following the recent upgrade of one of our BPF programs + Parent Hashes: a461a51e519aedee8aff518167451b250ce913b3 + Refs: we encountered +significant latency spikes affecting other applications running on the same +host. After thorough investigation + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Mitigate latency spikes when freeing non-preallocated htab in a BPF program.', 'keywords': 'latency, spikes, htab', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 985d0681b46be7db5ccc330d9a7f318b96ce0029 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 985d0681b46be7db5ccc330d9a7f318b96ce0029 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711675900 + Commit Message: + selftests/bpf: add batched tp/raw_tp/fmodret tests + +Utilize bpf_modify_return_test_tp() kfunc to have a fast way to trigger +tp/raw_tp/fmodret programs from another BPF program + Parent Hashes: 3124591f686115aca25d772c2ccb7b1e202c3197 + Refs: which gives us +comparable batched benchmarks to (batched) kprobe/fentry benchmarks. + +We don't switch kprobe/fentry batched benchmarks to this kfunc to make +bench tool usable on older kernels as well. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240326162151.3981687-7-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added batched tests for tp/raw_tp/fmodret programs using bpf_modify_return_test_tp() kfunc.', 'keywords': 'batched tests,kfunc,tp programs', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3124591f686115aca25d772c2ccb7b1e202c3197 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3124591f686115aca25d772c2ccb7b1e202c3197 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711675900 + Commit Message: + bpf: add bpf_modify_return_test_tp() kfunc triggering tracepoint + +Add a simple bpf_modify_return_test_tp() kfunc + Parent Hashes: b4ccf9158f5893dedb898687272fabfe80f58907 + Refs: available to all program +types + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added new kfunc bpf_modify_return_test_tp() for triggering tracepoints in eBPF.', 'keywords': 'bpf,kfunc,tracepoint', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: b4ccf9158f5893dedb898687272fabfe80f58907 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b4ccf9158f5893dedb898687272fabfe80f58907 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711675900 + Commit Message: + selftests/bpf: lazy-load trigger bench BPF programs + +Instead of front-loading all possible benchmarking BPF programs for +trigger benchmarks + Parent Hashes: 208c4391204d25d9178fbc87f216daffad00cd15 + Refs: explicitly specify which BPF programs are used by +specific benchmark and load only it. + +This allows to be more flexible in supporting older kernels + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implemented lazy-loading mechanism for BPF programs in selftests to support trigger benchmarks on older kernels.', 'keywords': 'selftests, lazy-load, benchmarks', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 208c4391204d25d9178fbc87f216daffad00cd15 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 208c4391204d25d9178fbc87f216daffad00cd15 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711675900 + Commit Message: + selftests/bpf: remove syscall-driven benchs + Parent Hashes: 7df4e597ea2cfd677e65730948153d5544986a10 + Refs: keep syscall-count only + +Remove "legacy" benchmarks triggered by syscalls in favor of newly added +in-kernel/batched benchmarks. Drop -batched suffix now as well. +Next patch will restore "feature parity" by adding back +tp/raw_tp/fmodret benchmarks based on in-kernel kfunc approach. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240326162151.3981687-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed syscall-driven benchmarks in favor of in-kernel batched benchmarks in selftests for BPF.', 'keywords': 'benchmarks, syscall, batched', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7df4e597ea2cfd677e65730948153d5544986a10 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7df4e597ea2cfd677e65730948153d5544986a10 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711675900 + Commit Message: + selftests/bpf: add batched + Parent Hashes: 1175f8dea349e5999d99727346db24f38306a793 + Refs: mostly in-kernel BPF triggering benchmarks + +Existing kprobe/fentry triggering benchmarks have 1-to-1 mapping between +one syscall execution and BPF program run. While we use a fast +get_pgid() syscall + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add batched benchmarks for selftests/bpf focusing on kprobe/fentry with faster syscall execution.', 'keywords': 'batched, benchmarks, kprobe', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 1175f8dea349e5999d99727346db24f38306a793 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1175f8dea349e5999d99727346db24f38306a793 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711675899 + Commit Message: + selftests/bpf: rename and clean up userspace-triggered benchmarks + +Rename uprobe-base to more precise usermode-count (it will match other +baseline-like benchmarks + Parent Hashes: 55fc888ded83ed542f3de3e51bae03936a998349 + Refs: kernel-count and syscall-count). Also use +BENCH_TRIG_USERMODE() macro to define all usermode-based triggering +benchmarks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Rename and clean up userspace-triggered benchmarks in selftests/bpf and use BENCH_TRIG_USERMODE macro.', 'keywords': 'selftests, benchmarks, rename', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 55fc888ded83ed542f3de3e51bae03936a998349 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 55fc888ded83ed542f3de3e51bae03936a998349 + Author Name: Haiyue Wang + Author Email: haiyue.wang@intel.com + Commit Date: 1711675896 + Commit Message: + bpf + Parent Hashes: 786bf0e7e2ec90b349a7bab6e97947982ab31f2c + Refs: arena: Use helper sizeof_field in struct accessors + +Use the well defined helper sizeof_field() to calculate the size of a +struct member + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Use the sizeof_field helper for calculating struct member size within the arena.', 'keywords': 'helper, struct, sizeof_field', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 786bf0e7e2ec90b349a7bab6e97947982ab31f2c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 786bf0e7e2ec90b349a7bab6e97947982ab31f2c + Author Name: Mykyta Yatsenko + Author Email: yatsenko@meta.com + Commit Date: 1711675853 + Commit Message: + bpf: improve error message for unsupported helper + +BPF verifier emits "unknown func" message when given BPF program type +does not support BPF helper. This message may be confusing for users + Parent Hashes: 59b418c7063d30e0a3e1f592d47df096db83185c + Refs: as +important context that helper is unknown only to current program type is +not provided. + +This patch changes message to "program of this type cannot use helper " +and aligns dependent code in libbpf and tests. Any suggestions on +improving/changing this message are welcome. + +Signed-off-by: Mykyta Yatsenko +Acked-by: Andrii Nakryiko +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/r/20240325152210.377548-1-yatsenko@meta.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improves error message clarity in BPF verifier when unsupported helpers are used by certain BPF program types.', 'keywords': 'error message, BPF verifier, helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 59b418c7063d30e0a3e1f592d47df096db83185c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 59b418c7063d30e0a3e1f592d47df096db83185c + Author Name: Anton Protopopov + Author Email: aspsk@isovalent.com + Commit Date: 1711675853 + Commit Message: + bpf: Add a check for struct bpf_fib_lookup size + +The struct bpf_fib_lookup should not grow outside of its 64 bytes. +Add a static assert to validate this. + +Suggested-by: David Ahern +Signed-off-by: Anton Protopopov +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240326101742.17421-4-aspsk@isovalent.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 6efec2cb06411a577125b5f531a852c08ead1209 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a static check to ensure struct bpf_fib_lookup size remains 64 bytes.', 'keywords': 'bpf_fib_lookup, static_assert, size_check', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6efec2cb06411a577125b5f531a852c08ead1209 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6efec2cb06411a577125b5f531a852c08ead1209 + Author Name: Anton Protopopov + Author Email: aspsk@isovalent.com + Commit Date: 1711675853 + Commit Message: + selftests/bpf: Add BPF_FIB_LOOKUP_MARK tests + +This patch extends the fib_lookup test suite by adding a few test +cases for each IP family to test the new BPF_FIB_LOOKUP_MARK flag +to the bpf_fib_lookup: + + * Test destination IP address selection with and without a mark + and/or the BPF_FIB_LOOKUP_MARK flag set + +Signed-off-by: Anton Protopopov +Signed-off-by: Daniel Borkmann +Acked-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240326101742.17421-3-aspsk@isovalent.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 5311591fbb349fe9f5c555dcba3b13a5831aa72d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extend the fib_lookup test suite with new test cases for BPF_FIB_LOOKUP_MARK flag.', 'keywords': 'fib_lookup, BPF_FIB_LOOKUP_MARK, tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 5311591fbb349fe9f5c555dcba3b13a5831aa72d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5311591fbb349fe9f5c555dcba3b13a5831aa72d + Author Name: Anton Protopopov + Author Email: aspsk@isovalent.com + Commit Date: 1711675852 + Commit Message: + bpf: Add support for passing mark with bpf_fib_lookup + +Extend the bpf_fib_lookup() helper by making it to utilize mark if +the BPF_FIB_LOOKUP_MARK flag is set. In order to pass the mark the +four bytes of struct bpf_fib_lookup are used + Parent Hashes: c602f4ca13a529b45692de4fdec96b4cdec866da + Refs: shared with the +output-only smac/dmac fields. + +Signed-off-by: Anton Protopopov +Signed-off-by: Daniel Borkmann +Reviewed-by: David Ahern +Acked-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240326101742.17421-2-aspsk@isovalent.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for passing mark with bpf_fib_lookup helper using BPF_FIB_LOOKUP_MARK flag.', 'keywords': 'bpf_fib_lookup, mark, helper', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 50108c352db70405b3d71d8099d0b3adc3b3352c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 50108c352db70405b3d71d8099d0b3adc3b3352c + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1711656577 + Commit Message: + Merge tag 'net-6.9-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + "Including fixes from bpf + Parent Hashes: 8d025e2092e29bfd13e56c78e22af25fac83c8ec 18685451fc4e546fc0e718580d32df3c0e5c8272 + Refs: WiFi and netfilter. + + Current release - regressions: + + - ipv6: fix address dump when IPv6 is disabled on an interface + + Current release - new code bugs: + + - bpf: temporarily disable atomic operations in BPF arena + + - nexthop: fix uninitialized variable in nla_put_nh_group_stats() + + Previous releases - regressions: + + - bpf: protect against int overflow for stack access size + + - hsr: fix the promiscuous mode in offload mode + + - wifi: don't always use FW dump trig + + - tls: adjust recv return with async crypto and failed copy to + userspace + + - tcp: properly terminate timers for kernel sockets + + - ice: fix memory corruption bug with suspend and rebuild + + - at803x: fix kernel panic with at8031_probe + + - qeth: handle deferred cc1 + + Previous releases - always broken: + + - bpf: fix bug in BPF_LDX_MEMSX + + - netfilter: reject table flag and netdev basechain updates + + - inet_defrag: prevent sk release while still in use + + - wifi: pick the version of SESSION_PROTECTION_NOTIF + + - wwan: t7xx: split 64bit accesses to fix alignment issues + + - mlxbf_gige: call request_irq() after NAPI initialized + + - hns3: fix kernel crash when devlink reload during pf + initialization" + +* tag 'net-6.9-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (81 commits) + inet: inet_defrag: prevent sk release while still in use + Octeontx2-af: fix pause frame configuration in GMP mode + net: lan743x: Add set RFE read fifo threshold for PCI1x1x chips + net: bcmasp: Remove phy_{suspend/resume} + net: bcmasp: Bring up unimac after PHY link up + net: phy: qcom: at803x: fix kernel panic with at8031_probe + netfilter: arptables: Select NETFILTER_FAMILY_ARP when building arp_tables.c + netfilter: nf_tables: skip netdev hook unregistration if table is dormant + netfilter: nf_tables: reject table flag and netdev basechain updates + netfilter: nf_tables: reject destroy command to remove basechain hooks + bpf: update BPF LSM designated reviewer list + bpf: Protect against int overflow for stack access size + bpf: Check bloom filter map value size + bpf: fix warning for crash_kexec + selftests: netdevsim: set test timeout to 10 minutes + net: wan: framer: Add missing static inline qualifiers + mlxbf_gige: call request_irq() after NAPI initialized + tls: get psock ref after taking rxlock to avoid leak + selftests: tls: add test with a partially invalid iov + tls: adjust recv return with async crypto and failed copy to userspace + ... + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes including BPF and various bug resolutions for the 6.9-rc2 release.', 'keywords': 'networking, BPF, fixes', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tc/netfilter like programs', 'LSM like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7e6f4b2af5b8cfe028386bc439c9bad1eddff9a6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7e6f4b2af5b8cfe028386bc439c9bad1eddff9a6 + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1711616880 + Commit Message: + Merge tag 'for-net' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Alexei Starovoitov says: + +==================== +pull-request: bpf 2024-03-27 + +The following pull-request contains BPF updates for your *net* tree. + +We've added 4 non-merge commits during the last 1 day(s) which contain +a total of 5 files changed + Parent Hashes: 56d2f48ed8f857f2765575a6a25b9655765edd41 4dd651076ef0e5f09940f763a1b4e8a209dab7ab + Refs: 26 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge BPF updates for net tree with 4 non-merge commits affecting 5 files.', 'keywords': 'BPF, net, updates', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4dd651076ef0e5f09940f763a1b4e8a209dab7ab +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4dd651076ef0e5f09940f763a1b4e8a209dab7ab + Author Name: Matt Bobrowski + Author Email: mattbobrowski@google.com + Commit Date: 1711563036 + Commit Message: + bpf: update BPF LSM designated reviewer list + +Adding myself in place of both Brendan and Florent as both have since +moved on from working on the BPF LSM and will no longer be devoting +their time to maintaining the BPF LSM. + +Signed-off-by: Matt Bobrowski +Acked-by: KP Singh +Link: https://lore.kernel.org/r/ZgMhWF_egdYF8t4D@google.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: a4e02d6b91c5e57f820032ec6ad794694c86f327 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added Matt Bobrowski to BPF LSM designated reviewer list replacing Brendan and Florent.', 'keywords': 'BPF, LSM, reviewer', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: ecc6a2101840177e57c925c102d2d29f260d37c8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ecc6a2101840177e57c925c102d2d29f260d37c8 + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1711558596 + Commit Message: + bpf: Protect against int overflow for stack access size + +This patch re-introduces protection against the size of access to stack +memory being negative; the access size can appear negative as a result +of overflowing its signed int representation. This should not actually +happen + Parent Hashes: a8d89feba7e54e691ca7c4efc2a6264fa83f3687 + Refs: as there are other protections along the way + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit reintroduces protection against int overflow for stack access size in the eBPF subsystem.', 'keywords': 'int overflow,stack access,protection', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a8d89feba7e54e691ca7c4efc2a6264fa83f3687 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a8d89feba7e54e691ca7c4efc2a6264fa83f3687 + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1711558577 + Commit Message: + bpf: Check bloom filter map value size + +This patch adds a missing check to bloom filter creating + Parent Hashes: 96b98a6552a90690d7bc18dd71b66312c9ded1fb + Refs: rejecting +values above KMALLOC_MAX_SIZE. This brings the bloom map in line with +many other map types. + +The lack of this protection can cause kernel crashes for value sizes +that overflow int's. Such a crash was caught by syzkaller. The next +patch adds more guard-rails at a lower level. + +Signed-off-by: Andrei Matei +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240327024245.318299-2-andreimatei1@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "This commit adds a check to prevent kernel crashes by ensuring bloom filter map values don't exceed KMALLOC_MAX_SIZE.", 'keywords': 'bloom filter, kernel crash, KMALLOC_MAX_SIZE', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 96b98a6552a90690d7bc18dd71b66312c9ded1fb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 96b98a6552a90690d7bc18dd71b66312c9ded1fb + Author Name: Hari Bathini + Author Email: hbathini@linux.ibm.com + Commit Date: 1711554744 + Commit Message: + bpf: fix warning for crash_kexec + +With [1] + Parent Hashes: afbf75e8da8ce8a0698212953d350697bb4355a6 + Refs: crash dump specific code is moved out of CONFIG_KEXEC_CORE +and placed under CONFIG_CRASH_DUMP + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix warning by moving crash dump specific code to CONFIG_CRASH_DUMP for proper configuration linkage.', 'keywords': 'fix, warning, crash', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 2a702c2e57908e7bb5c814afeac577a14815c2f2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2a702c2e57908e7bb5c814afeac577a14815c2f2 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1711551154 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-03-25 + +We've added 38 non-merge commits during the last 13 day(s) which contain +a total of 50 files changed + Parent Hashes: ee36b1e93b11b980e0156bd07cbb9866b7d3e29e 14bb1e8c8d4ad5d9d2febb7d19c70a3cf536e1e5 + Refs: 867 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge pull request for bpf-next with 38 non-merge commits and 50 files changed.', 'keywords': 'merge,pull request,bpf-next', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: ea6873118493019474abbf57d5a800da365734df +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ea6873118493019474abbf57d5a800da365734df + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1711487358 + Commit Message: + drivers/perf: riscv: Disable PERF_SAMPLE_BRANCH_* while not supported + +RISC-V perf driver does not yet support branch sampling. Although the +specification is in the works [0] + Parent Hashes: 4b0bf9a0127029054c2fa18ba5b3f3ddc45f54ed + Refs: it is best to disable such events +until support is available + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Disable unsupported branch sampling in RISC-V perf driver.', 'keywords': 'Disable, RISC-V, branch sampling', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 37ccdf7f11b12f987c5d9ff99e67104264016c8d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 37ccdf7f11b12f987c5d9ff99e67104264016c8d + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1711454118 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-03-25 + +The following pull-request contains BPF updates for your *net* tree. + +We've added 17 non-merge commits during the last 12 day(s) which contain +a total of 19 files changed + Parent Hashes: f1425529c33def8b46faae4400dd9e2bbaf16a05 443574b033876c85a35de4c65c14f7fe092222b2 + Refs: 184 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merges updates for BPF in linux net tree with 17 non-merge commits and 184 insertions.', 'keywords': 'BPF updates, net tree, merge', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 151c9c724d05d5b0dd8acd3e11cb69ef1f2dbada +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 151c9c724d05d5b0dd8acd3e11cb69ef1f2dbada + Author Name: Eric Dumazet + Author Email: edumazet@google.com + Commit Date: 1711421517 + Commit Message: + tcp: properly terminate timers for kernel sockets + +We had various syzbot reports about tcp timers firing after +the corresponding netns has been dismantled. + +Fortunately Josef Bacik could trigger the issue more often + Parent Hashes: b11c81731c810efe592e510bb0110e0db6877419 + Refs: +and could test a patch I wrote two years ago. + +When TCP sockets are closed + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix termination of TCP timers in kernel sockets after netns dismantling.', 'keywords': 'TCP, timers, netns', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', "It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 443574b033876c85a35de4c65c14f7fe092222b2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 443574b033876c85a35de4c65c14f7fe092222b2 + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1711391971 + Commit Message: + riscv + Parent Hashes: 122fdbd2a030a95128737fc77e47df15a8f170c3 + Refs: bpf: Fix kfunc parameters incompatibility between bpf and riscv abi + +We encountered a failing case when running selftest in no_alu32 mode: + +The failure case is `kfunc_call/kfunc_call_test4` and its source code is +like bellow: +``` +long bpf_kfunc_call_test4(signed char a + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix incompatibility of kfunc parameters between bpf and riscv ABI.', 'keywords': 'kfunc, incompatibility, riscv', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 14bb1e8c8d4ad5d9d2febb7d19c70a3cf536e1e5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 14bb1e8c8d4ad5d9d2febb7d19c70a3cf536e1e5 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711383954 + Commit Message: + selftests/bpf: Fix flaky test btf_map_in_map/lookup_update + +Recently + Parent Hashes: 770546ae9f4c1ae1ebcaf0874f0dd9631d77ec97 + Refs: I frequently hit the following test failure: + + [root@arch-fb-vm1 bpf]# ./test_progs -n 33/1 + test_lookup_update:PASS:skel_open 0 nsec + [...] + test_lookup_update:PASS:sync_rcu 0 nsec + test_lookup_update:FAIL:map1_leak inner_map1 leaked! + #33/1 btf_map_in_map/lookup_update:FAIL + #33 btf_map_in_map:FAIL + +In the test + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a flaky test in the bpf selftests related to btf_map_in_map and lookup_update.', 'keywords': 'flaky,test,fix', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 770546ae9f4c1ae1ebcaf0874f0dd9631d77ec97 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 770546ae9f4c1ae1ebcaf0874f0dd9631d77ec97 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1711383051 + Commit Message: + bpf: implement insn_is_cast_user() helper for JITs + +Implement a helper function to check if an instruction is +addr_space_cast from as(0) to as(1). Use this helper in the x86 JIT. + +Other JITs can use this helper when they add support for this instruction. + +Signed-off-by: Puranjay Mohan +Link: https://lore.kernel.org/r/20240324183226.29674-1-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: a8497506cd2c0fc90a64f6f5d2744a0ddb2c81eb + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a helper function insn_is_cast_user() for checking address space casts, integrated into x86 JIT.', 'keywords': 'helper,function,JIT', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a8497506cd2c0fc90a64f6f5d2744a0ddb2c81eb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a8497506cd2c0fc90a64f6f5d2744a0ddb2c81eb + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1711382748 + Commit Message: + bpf: Avoid get_kernel_nofault() to fetch kprobe entry IP + +get_kernel_nofault() (or + Parent Hashes: c29083f3f5069d811b3f3c7592a0dc45ec42960c + Refs: rather + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Avoid using get_kernel_nofault() to fetch kprobe entry IP for eBPF programs.', 'keywords': 'get_kernel_nofault,kprobe,eBPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: c29083f3f5069d811b3f3c7592a0dc45ec42960c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c29083f3f5069d811b3f3c7592a0dc45ec42960c + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1711381793 + Commit Message: + selftests/bpf: Use start_server in bpf_tcp_ca + +To simplify the code + Parent Hashes: 476a5e929119725fbfcf1307cc8517d9dd2a014d + Refs: use BPF selftests helper start_server() in +bpf_tcp_ca.c instead of open-coding it. This helper is defined in +network_helpers.c + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor bpf_tcp_ca.c to use start_server from network_helpers.c for simplicity.', 'keywords': 'selftests,bpf_tcp_ca,refactor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 476a5e929119725fbfcf1307cc8517d9dd2a014d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 476a5e929119725fbfcf1307cc8517d9dd2a014d + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711381016 + Commit Message: + bpf: Sync uapi bpf.h to tools directory + +There is a difference between kernel uapi bpf.h and tools +uapi bpf.h. There is no functionality difference + Parent Hashes: 61df575632d6b39213f47810c441bddbd87c3606 + Refs: but let +us sync properly to make it easy for later bpf.h update. + +Signed-off-by: Yonghong Song +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240325033842.1693553-1-yonghong.song@linux.dev + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit synchronizes the uapi bpf.h between the kernel and tools directory.', 'keywords': 'sync,uapi,tools', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 122fdbd2a030a95128737fc77e47df15a8f170c3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 122fdbd2a030a95128737fc77e47df15a8f170c3 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1711165449 + Commit Message: + bpf: verifier: reject addr_space_cast insn without arena + +The verifier allows using the addr_space_cast instruction in a program +that doesn't have an associated arena. This was caught in the form an +invalid memory access in do_misc_fixups() when while converting +addr_space_cast to a normal 32-bit mov + Parent Hashes: fa3550dca8f02ec312727653a94115ef3ab68445 + Refs: env->prog->aux->arena was +dereferenced to check for BPF_F_NO_USER_CONV flag. + +Reject programs that include the addr_space_cast instruction but don't +have an associated arena. + +root@rv-tester:~# ./reproducer + Unable to handle kernel access to user memory without uaccess routines at virtual address 0000000000000030 + Oops [#1] + [] do_misc_fixups+0x43c/0x1168 + [] bpf_check+0xda8/0x22b6 + [] bpf_prog_load+0x486/0x8dc + [] __sys_bpf+0xbd8/0x214e + [] __riscv_sys_bpf+0x22/0x2a + [] do_trap_ecall_u+0x102/0x17c + [] ret_from_exception+0x0/0x64 + +Fixes: 6082b6c328b5 ("bpf: Recognize addr_space_cast instruction in the verifier.") +Reported-by: xingwei lee +Reported-by: yue sun +Closes: https://lore.kernel.org/bpf/CABOYnLz09O1+2gGVJuCxd_24a-7UueXzV-Ff+Fr+h5EKFDiYCQ@mail.gmail.com/ +Signed-off-by: Puranjay Mohan +Link: https://lore.kernel.org/r/20240322153518.11555-1-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes a memory access issue by rejecting programs using addr_space_cast without an associated arena.', 'keywords': 'verifier, addr_space_cast, arena', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fa3550dca8f02ec312727653a94115ef3ab68445 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fa3550dca8f02ec312727653a94115ef3ab68445 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1711165059 + Commit Message: + selftests/bpf: verifier_arena: fix mmap address for arm64 + +The arena_list selftest uses (1ull << 32) in the mmap address +computation for arm64. Use the same in the verifier_arena selftest. + +This makes the selftest pass for arm64 on the CI[1]. + +[1] https://github.com/kernel-patches/bpf/pull/6622 + +Signed-off-by: Puranjay Mohan +Link: https://lore.kernel.org/r/20240322133552.70681-1-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: f7f5d1808b1b66935a24dd796dd1a0612ca9c147 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes mmap address computation for arm64 in the bpf selftest verifier_arena.', 'keywords': 'mmap,arm64,selftest', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f7f5d1808b1b66935a24dd796dd1a0612ca9c147 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f7f5d1808b1b66935a24dd796dd1a0612ca9c147 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1711164996 + Commit Message: + bpf: verifier: fix addr_space_cast from as(1) to as(0) + +The verifier currently converts addr_space_cast from as(1) to as(0) that +is: BPF_ALU64 | BPF_MOV | BPF_X with off=1 and imm=1 +to +BPF_ALU | BPF_MOV | BPF_X with imm=1 (32-bit mov) + +Because of this imm=1 + Parent Hashes: ddb2ffdc474a3000887dc776b971d04bde29decc + Refs: the JITs that have bpf_jit_needs_zext() == true + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes the address space cast issue in eBPF verifier from as(1) to as(0).', 'keywords': 'verifier, addr_space_cast, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 61df575632d6b39213f47810c441bddbd87c3606 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 61df575632d6b39213f47810c441bddbd87c3606 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1711143429 + Commit Message: + libbpf: Add new sec_def "sk_skb/verdict" + +The new sec_def specifies sk_skb program type with +BPF_SK_SKB_VERDICT attachment type. This way + Parent Hashes: af8d27bf15c8d68c60d830552055fcdba5b5f045 + Refs: libbpf +will set expected_attach_type properly for the program. + +Signed-off-by: Yonghong Song +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240319175412.2941149-1-yonghong.song@linux.dev + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a new sec_def specifying sk_skb program type with BPF_SK_SKB_VERDICT to set expected_attach_type in libbpf.', 'keywords': 'sec_def, sk_skb, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: af8d27bf15c8d68c60d830552055fcdba5b5f045 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: af8d27bf15c8d68c60d830552055fcdba5b5f045 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1711126877 + Commit Message: + selftests/bpf: Mark uprobe trigger functions with nocf_check attribute + +Some distros seem to enable the -fcf-protection=branch by default + Parent Hashes: 1684d6eb99e480ff653af60e20ff5e7e55e69ccd + Refs: +which breaks our setup on first instruction of uprobe trigger +functions and place there endbr64 instruction. + +Marking them with nocf_check attribute to skip that. + +Ignoring unknown attribute warning in gcc for bench objects + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Mark uprobe trigger functions with nocf_check attribute to avoid branch protection conflicts.', 'keywords': 'uprobe,nocf_check,protection', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 1684d6eb99e480ff653af60e20ff5e7e55e69ccd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1684d6eb99e480ff653af60e20ff5e7e55e69ccd + Author Name: Alan Maguire + Author Email: alan.maguire@oracle.com + Commit Date: 1711126817 + Commit Message: + selftests/bpf: Use syscall(SYS_gettid) instead of gettid() wrapper in bench + +With glibc 2.28 + Parent Hashes: 4c2a26fc80bcb851dc630590f2eec157991eccbf + Refs: selftests compilation fails for benchs/bench_trigger.c: + +benchs/bench_trigger.c: In function ‘inc_counter’: +benchs/bench_trigger.c:25:23: error: implicit declaration of function ‘gettid’; did you mean ‘getgid’? [-Werror=implicit-function-declaration] + 25 | tid = gettid(); + | ^~~~~~ + | getgid +cc1: all warnings being treated as errors + +It appears support for the gettid() wrapper is variable across glibc +versions + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replace gettid() with syscall(SYS_gettid) for compatibility in bench_trigger selftest.', 'keywords': 'gettid,system call,selftests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: b3ad832d8da583ff4237b04a1ba23cdbf8918907 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b3ad832d8da583ff4237b04a1ba23cdbf8918907 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1711064675 + Commit Message: + perf dso: Reorder members to save space in 'struct dso' + +Save 40 bytes and move from 8 to 7 cache lines. Make member dwfl +dependent on being a powerpc build. Squeeze bits of int/enum types +when appropriate. Remove holes/padding by reordering variables. + +Before: + + struct dso { + struct mutex lock; /* 0 40 */ + struct list_head node; /* 40 16 */ + struct rb_node rb_node __attribute__((__aligned__(8))); /* 56 24 */ + /* --- cacheline 1 boundary (64 bytes) was 16 bytes ago --- */ + struct rb_root * root; /* 80 8 */ + struct rb_root_cached symbols; /* 88 16 */ + struct symbol * * symbol_names; /* 104 8 */ + size_t symbol_names_len; /* 112 8 */ + struct rb_root_cached inlined_nodes; /* 120 16 */ + /* --- cacheline 2 boundary (128 bytes) was 8 bytes ago --- */ + struct rb_root_cached srclines; /* 136 16 */ + struct { + u64 addr; /* 152 8 */ + struct symbol * symbol; /* 160 8 */ + } last_find_result; /* 152 16 */ + void * a2l; /* 168 8 */ + char * symsrc_filename; /* 176 8 */ + unsigned int a2l_fails; /* 184 4 */ + enum dso_space_type kernel; /* 188 4 */ + /* --- cacheline 3 boundary (192 bytes) --- */ + _Bool is_kmod; /* 192 1 */ + + /* XXX 3 bytes hole + Parent Hashes: 2a5049b75d22c971e73501784f10548c1d69c407 + Refs: try to pack */ + + enum dso_swap_type needs_swap; /* 196 4 */ + enum dso_binary_type symtab_type; /* 200 4 */ + enum dso_binary_type binary_type; /* 204 4 */ + enum dso_load_errno load_errno; /* 208 4 */ + u8 adjust_symbols:1; /* 212: 0 1 */ + u8 has_build_id:1; /* 212: 1 1 */ + u8 header_build_id:1; /* 212: 2 1 */ + u8 has_srcline:1; /* 212: 3 1 */ + u8 hit:1; /* 212: 4 1 */ + u8 annotate_warned:1; /* 212: 5 1 */ + u8 auxtrace_warned:1; /* 212: 6 1 */ + u8 short_name_allocated:1; /* 212: 7 1 */ + u8 long_name_allocated:1; /* 213: 0 1 */ + u8 is_64_bit:1; /* 213: 1 1 */ + + /* XXX 6 bits hole + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Optimize 'struct dso' in perf tool by reordering members to reduce cache lines and save space.", 'keywords': 'optimize, reorder, struct', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: cba9ffdb9913dfe6be29f049ce920ce451ce7cc4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cba9ffdb9913dfe6be29f049ce920ce451ce7cc4 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1711057839 + Commit Message: + Merge tag 'net-6.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + "Including fixes from CAN + Parent Hashes: 1d35aae78ffe739bf46c2bf9dea7b51a4eebfbe0 f99c5f563c174a49ea1cbf4754539b05cfde40c4 + Refs: netfilter + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge network fixes from net-6.9-rc1 tag, includes CAN related corrections.', 'keywords': 'merge, networking, fixes', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 4c2a26fc80bcb851dc630590f2eec157991eccbf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4c2a26fc80bcb851dc630590f2eec157991eccbf + Author Name: Harishankar Vishwanathan + Author Email: harishankar.vishwanathan@gmail.com + Commit Date: 1711047386 + Commit Message: + bpf-next: Avoid goto in regs_refine_cond_op() + +In case of GE/GT/SGE/JST instructions + Parent Hashes: cc9b22dfa735800980e7362f02aff6f1c2280996 + Refs: regs_refine_cond_op() +reuses the logic that does analysis of LE/LT/SLE/SLT instructions. +This commit avoids the use of a goto to perform the reuse. + +Signed-off-by: Harishankar Vishwanathan +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240321002955.808604-1-harishankar.vishwanathan@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors the logic in regs_refine_cond_op to eliminate the use of a goto statement.', 'keywords': 'regs_refine_cond_op, refactor, goto', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ddb2ffdc474a3000887dc776b971d04bde29decc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ddb2ffdc474a3000887dc776b971d04bde29decc + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@kernel.org + Commit Date: 1711045637 + Commit Message: + libbpf: Define MFD_CLOEXEC if not available + +Since its going directly to the syscall to avoid not having +memfd_create() available in some systems + Parent Hashes: a51cd6bf8e10793103c5870ff9e4db295a843604 + Refs: do the same for its +MFD_CLOEXEC flags + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Defines MFD_CLOEXEC flag in libbpf for systems missing memfd_create support.', 'keywords': 'libbpf, MFD_CLOEXEC, memfd_create', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 88ce0106a1f603bf360cb397e8fe293f8298fabb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 88ce0106a1f603bf360cb397e8fe293f8298fabb + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1711040079 + Commit Message: + perf record: Delete session after stopping sideband thread + +The session has a header in it which contains a perf env with +bpf_progs. The bpf_progs are accessed by the sideband thread and so +the sideband thread must be stopped before the session is deleted + Parent Hashes: 67ee8e71daabb8632931b7559e5c8a4b69a427f8 + Refs: to +avoid a use after free. This error was detected by AddressSanitizer +in the following: + + ==2054673==ERROR: AddressSanitizer: heap-use-after-free on address 0x61d000161e00 at pc 0x55769289de54 bp 0x7f9df36d4ab0 sp 0x7f9df36d4aa8 + READ of size 8 at 0x61d000161e00 thread T1 + #0 0x55769289de53 in __perf_env__insert_bpf_prog_info util/env.c:42 + #1 0x55769289dbb1 in perf_env__insert_bpf_prog_info util/env.c:29 + #2 0x557692bbae29 in perf_env__add_bpf_info util/bpf-event.c:483 + #3 0x557692bbb01a in bpf_event__sb_cb util/bpf-event.c:512 + #4 0x5576928b75f4 in perf_evlist__poll_thread util/sideband_evlist.c:68 + #5 0x7f9df96a63eb in start_thread nptl/pthread_create.c:444 + #6 0x7f9df9726a4b in clone3 ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81 + + 0x61d000161e00 is located 384 bytes inside of 2136-byte region [0x61d000161c80 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a use-after-free error by ensuring the sideband thread stops before deleting the session in perf record.', 'keywords': 'use-after-free, sideband thread, perf record', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: a51cd6bf8e10793103c5870ff9e4db295a843604 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a51cd6bf8e10793103c5870ff9e4db295a843604 + Author Name: Artem Savkov + Author Email: asavkov@redhat.com + Commit Date: 1711018745 + Commit Message: + arm64: bpf: fix 32bit unconditional bswap + +In case when is64 == 1 in emit(A64_REV32(is64 + Parent Hashes: 114b5b3b4bde7358624437be2f12cde1b265224e + Refs: dst + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes an issue with 32-bit unconditional byte swap in ARM64 BPF code.', 'keywords': 'ARM64, BPF, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cc9b22dfa735800980e7362f02aff6f1c2280996 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cc9b22dfa735800980e7362f02aff6f1c2280996 + Author Name: Quentin Monnet + Author Email: qmo@kernel.org + Commit Date: 1711002829 + Commit Message: + bpftool: Clean up HOST_CFLAGS + Parent Hashes: 520fad2e3206b2476f201a283ecf096cfb671902 + Refs: HOST_LDFLAGS for bootstrap bpftool + +Bpftool's Makefile uses $(HOST_CFLAGS) to build the bootstrap version of +bpftool + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Clean up HOST_CFLAGS usage in bpftool's Makefile for bootstrap build.", 'keywords': 'bpftool, Makefile, HOST_CFLAGS', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 3201de46a2013293abe28caa46aa0387864d7cf7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3201de46a2013293abe28caa46aa0387864d7cf7 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1710993945 + Commit Message: + Merge branch 'report-rcu-qs-for-busy-network-kthreads' + +Yan Zhai says: + +==================== +Report RCU QS for busy network kthreads + +This changeset fixes a common problem for busy networking kthreads. +These threads + Parent Hashes: f7bf0ec1e73d43a347489e958b42841b111d63d6 00bf63122459e87193ee7f1bc6161c83a525569f + Refs: e.g. NAPI threads + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes RCU quiescent state reporting for busy network kernel threads.', 'keywords': 'RCU,kthreads,networking', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 00bf63122459e87193ee7f1bc6161c83a525569f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 00bf63122459e87193ee7f1bc6161c83a525569f + Author Name: Yan Zhai + Author Email: yan@cloudflare.com + Commit Date: 1710993943 + Commit Message: + bpf: report RCU QS in cpumap kthread + +When there are heavy load + Parent Hashes: d6dbbb11247c71203785a2c9da474c36f4b19eae + Refs: cpumap kernel threads can be busy polling +packets from redirect queues and block out RCU tasks from reaching +quiescent states. It is insufficient to just call cond_resched() in such +context. Periodically raise a consolidated RCU QS before cond_resched +fixes the problem. + +Fixes: 6710e1126934 ("bpf: introduce new bpf cpu map type BPF_MAP_TYPE_CPUMAP") +Reviewed-by: Jesper Dangaard Brouer +Signed-off-by: Yan Zhai +Acked-by: Paul E. McKenney +Acked-by: Jesper Dangaard Brouer +Link: https://lore.kernel.org/r/c17b9f1517e19d813da3ede5ed33ee18496bb5d8.1710877680.git.yan@cloudflare.com +Signed-off-by: Jakub Kicinski + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds periodic RCU quiescent state reporting in cpumap kthreads to prevent blocking RCU tasks.', 'keywords': 'RCU, cpumap, kthread', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d6dbbb11247c71203785a2c9da474c36f4b19eae +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d6dbbb11247c71203785a2c9da474c36f4b19eae + Author Name: Yan Zhai + Author Email: yan@cloudflare.com + Commit Date: 1710993942 + Commit Message: + net: report RCU QS on threaded NAPI repolling + +NAPI threads can keep polling packets under load. Currently it is only +calling cond_resched() before repolling + Parent Hashes: 1a77557d48cff187a169c2aec01c0dd78a5e7e50 + Refs: but it is not sufficient to +clear out the holdout of RCU tasks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve RCU task handling during threaded NAPI repolling to optimize network packet processing.', 'keywords': 'RCU, NAPI, repolling', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 520fad2e3206b2476f201a283ecf096cfb671902 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 520fad2e3206b2476f201a283ecf096cfb671902 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710916895 + Commit Message: + selftests/bpf: scale benchmark counting by using per-CPU counters + +When benchmarking with multiple threads (-pN + Parent Hashes: e9a826dd145bf2c19888aee1b974214cefc74a2e + Refs: where N>1) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance benchmark accuracy by implementing per-CPU counters in selftests for multi-threaded environments.', 'keywords': 'benchmark, per-CPU, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e9a826dd145bf2c19888aee1b974214cefc74a2e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e9a826dd145bf2c19888aee1b974214cefc74a2e + Author Name: Quentin Monnet + Author Email: qmo@kernel.org + Commit Date: 1710915475 + Commit Message: + bpftool: Remove unnecessary source files from bootstrap version + +Commit d510296d331a ("bpftool: Use syscall/loader program in "prog load" +and "gen skeleton" command.") added new files to the list of objects to +compile in order to build the bootstrap version of bpftool. As far as I +can tell + Parent Hashes: be24a895149b6df4c474848e3928c237ad10fdc4 + Refs: these objects are unnecessary and were added by mistake; maybe +a draft version intended to add support for loading loader programs from +the bootstrap version. Anyway + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Remove unnecessary source files from bpftool's bootstrap version due to mistaken inclusion.", 'keywords': 'bpftool, bootstrap, unnecessary', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: be24a895149b6df4c474848e3928c237ad10fdc4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: be24a895149b6df4c474848e3928c237ad10fdc4 + Author Name: Quentin Monnet + Author Email: qmo@kernel.org + Commit Date: 1710915142 + Commit Message: + bpftool: Enable libbpf logs when loading pid_iter in debug mode + +When trying to load the pid_iter BPF program used to iterate over the +PIDs of the processes holding file descriptors to BPF links + Parent Hashes: 2e244a72cd489e9b8d4c779c0674c80cf92b6aab + Refs: we would +unconditionally silence libbpf in order to keep the output clean if the +kernel does not support iterators and loading fails. + +Although this is the desirable behaviour in most cases + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable libbpf logs for pid_iter BPF program in debug mode in bpftool.', 'keywords': 'libbpf, pid_iter, debug', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 2e244a72cd489e9b8d4c779c0674c80cf92b6aab +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2e244a72cd489e9b8d4c779c0674c80cf92b6aab + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710914734 + Commit Message: + Merge branch 'bpf-raw-tracepoint-support-for-bpf-cookie' + +Andrii Nakryiko says: + +==================== +BPF raw tracepoint support for BPF cookie + +Add ability to specify and retrieve BPF cookie for raw tracepoint programs. +Both BTF-aware (SEC("tp_btf")) and non-BTF-aware (SEC("raw_tp")) are +supported + Parent Hashes: f803bcf9208a2540acb4c32bdc3616673169f490 51146ff0fae309a558bc8ab6cbf6cfda17356993 + Refs: as they are exactly the same at runtime. + +This issue recently came up in production use cases + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for specifying and retrieving BPF cookies in raw tracepoint programs, including BTF-aware and non-BTF-aware implementations.', 'keywords': 'BPF cookie,raw tracepoint,support', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 51146ff0fae309a558bc8ab6cbf6cfda17356993 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 51146ff0fae309a558bc8ab6cbf6cfda17356993 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710914734 + Commit Message: + selftests/bpf: add raw_tp/tp_btf BPF cookie subtests + +Add test validating BPF cookie can be passed during raw_tp/tp_btf +attachment and can be retried at runtime with bpf_get_attach_cookie() +helper. + +Acked-by: Stanislav Fomichev +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319233852.1977493-6-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 36ffb2023e3703a64266ca5fed30f710b1263c70 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add subtests for validating BPF cookie during raw_tp/tp_btf attachment using bpf_get_attach_cookie() helper.', 'keywords': 'BPF cookie,raw_tp,tp_btf', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 36ffb2023e3703a64266ca5fed30f710b1263c70 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 36ffb2023e3703a64266ca5fed30f710b1263c70 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710914734 + Commit Message: + libbpf: add support for BPF cookie for raw_tp/tp_btf programs + +Wire up BPF cookie passing or raw_tp and tp_btf programs + Parent Hashes: 68ca5d4eebb8c4de246ee5f634eee26bc689562d + Refs: both in +low-level and high-level APIs. + +Acked-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319233852.1977493-5-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support for BPF cookie in libbpf for raw_tp and tp_btf programs.', 'keywords': 'BPF cookie, raw_tp, tp_btf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 68ca5d4eebb8c4de246ee5f634eee26bc689562d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 68ca5d4eebb8c4de246ee5f634eee26bc689562d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710914734 + Commit Message: + bpf: support BPF cookie in raw tracepoint (raw_tp + Parent Hashes: d4dfc5700e867b22ab94f960f9a9972696a637d5 + Refs: tp_btf) programs + +Wire up BPF cookie for raw tracepoint programs (both BTF and non-BTF +aware variants). This brings them up to part w.r.t. BPF cookie usage +with classic tracepoint and fentry/fexit programs. + +Acked-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319233852.1977493-4-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Wire up BPF cookie support for raw tracepoint programs in both BTF and non-BTF variants.', 'keywords': 'BPF cookie, raw tracepoint, BTF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: d4dfc5700e867b22ab94f960f9a9972696a637d5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d4dfc5700e867b22ab94f960f9a9972696a637d5 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710914733 + Commit Message: + bpf: pass whole link instead of prog when triggering raw tracepoint + +Instead of passing prog as an argument to bpf_trace_runX() helpers + Parent Hashes: 6b9c2950c912780ce113079c9c52041b1e2a611a + Refs: that +are called from tracepoint triggering calls + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit changes the argument to bpf_trace_runX() helpers from prog to the whole link for triggering raw tracepoints.', 'keywords': 'bpf, tracepoints, link', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 6b9c2950c912780ce113079c9c52041b1e2a611a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6b9c2950c912780ce113079c9c52041b1e2a611a + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710914733 + Commit Message: + bpf: flatten bpf_probe_register call chain + +bpf_probe_register() and __bpf_probe_register() have identical +signatures and bpf_probe_register() just redirect to +__bpf_probe_register(). So get rid of this extra function call step to +simplify following the source code. + +It has no difference at runtime due to inlining + Parent Hashes: f803bcf9208a2540acb4c32bdc3616673169f490 + Refs: of course. + +Acked-by: Stanislav Fomichev +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319233852.1977493-2-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit simplifies the source code by removing an unnecessary function call step in bpf_probe_register.', 'keywords': 'simplify,function,call', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 114b5b3b4bde7358624437be2f12cde1b265224e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 114b5b3b4bde7358624437be2f12cde1b265224e + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1710914119 + Commit Message: + bpf + Parent Hashes: 5ab8cb89dbb6f3e111c8b0a9a86496da23c94439 + Refs: arm64: fix bug in BPF_LDX_MEMSX + +A64_LDRSW() takes three registers: Xt + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a bug related to the BPF_LDX_MEMSX instruction on arm64.', 'keywords': 'bug, BPF_LDX_MEMSX, arm64', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5ab8cb89dbb6f3e111c8b0a9a86496da23c94439 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5ab8cb89dbb6f3e111c8b0a9a86496da23c94439 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710914044 + Commit Message: + libbpf: fix u64-to-pointer cast on 32-bit arches + +It's been reported that (void *)map->map_extra is causing compilation +warnings on 32-bit architectures. It's easy enough to fix this by +casting to long first. + +Fixes: 79ff13e99169 ("libbpf: Add support for bpf_arena.") +Reported-by: Ryan Eatmon +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319215143.1279312-1-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 7ded842b356d151ece8ac4985940438e6d3998bb + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix compilation warning on 32-bit architectures by adjusting u64-to-pointer casting in libbpf.', 'keywords': 'libbpf,cast,32-bit', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 7ded842b356d151ece8ac4985940438e6d3998bb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7ded842b356d151ece8ac4985940438e6d3998bb + Author Name: Ilya Leoshkevich + Author Email: iii@linux.ibm.com + Commit Date: 1710913963 + Commit Message: + s390/bpf: Fix bpf_plt pointer arithmetic + +Kui-Feng Lee reported a crash on s390x triggered by the +dummy_st_ops/dummy_init_ptr_arg test [1]: + + [<0000000000000002>] 0x2 + [<00000000009d5cde>] bpf_struct_ops_test_run+0x156/0x250 + [<000000000033145a>] __sys_bpf+0xa1a/0xd00 + [<00000000003319dc>] __s390x_sys_bpf+0x44/0x50 + [<0000000000c4382c>] __do_syscall+0x244/0x300 + [<0000000000c59a40>] system_call+0x70/0x98 + +This is caused by GCC moving memcpy() after assignments in +bpf_jit_plt() + Parent Hashes: f6e922365faf4cd576bd1cf3e64b58c8a32e1856 + Refs: resulting in NULL pointers being written instead of +the return and the target addresses. + +Looking at the GCC internals + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes pointer arithmetic bug in s390 BPF leading to crashes during tests.', 'keywords': 'pointer, bug, arithmetic', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 956c0d6191075f0592367512bf07aede458f0151 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 956c0d6191075f0592367512bf07aede458f0151 + Author Name: Kuniyuki Iwashima + Author Email: kuniyu@amazon.com + Commit Date: 1710902159 + Commit Message: + tcp: Clear req->syncookie in reqsk_alloc(). + +syzkaller reported a read of uninit req->syncookie. [0] + +Originally + Parent Hashes: d27e2da94a42655861ca4baea30c8cd65546f25d + Refs: req->syncookie was used only in tcp_conn_request() +to indicate if we need to encode SYN cookie in SYN+ACK + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix uninitialized req->syncookie issue in reqsk_alloc() in TCP connection handling.', 'keywords': 'tcp, syncookie, syzkaller', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: f803bcf9208a2540acb4c32bdc3616673169f490 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f803bcf9208a2540acb4c32bdc3616673169f490 + Author Name: Alessandro Carminati (Red Hat) + Author Email: alessandro.carminati@gmail.com + Commit Date: 1710890169 + Commit Message: + selftests/bpf: Prevent client connect before server bind in test_tc_tunnel.sh + +In some systems + Parent Hashes: 437ffcb0bf97361e5c4062043309832f4724d1a8 + Refs: the netcat server can incur in delay to start listening. +When this happens + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix race condition by ensuring server is ready before the client connects in test_tc_tunnel.sh.', 'keywords': 'selftests,bpf,connect', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 437ffcb0bf97361e5c4062043309832f4724d1a8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 437ffcb0bf97361e5c4062043309832f4724d1a8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710883621 + Commit Message: + Merge branch 'current_pid_tgid-for-all-prog-types' + +Yonghong Song says: + +==================== +current_pid_tgid() for all prog types + +Currently bpf_get_current_pid_tgid() is allowed in tracing + Parent Hashes: 1a4a0cb7985f921548f1a7ac17686afbefe67f87 4c195ee4865d57786b3a63018d489b8a07877354 + Refs: cgroup +and sk_msg progs while bpf_get_ns_current_pid_tgid() is only allowed +in tracing progs. + +We have an internal use case where for an application running +in a container (with pid namespace) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extend support for bpf_get_current_pid_tgid() to all eBPF program types, improving container namespace compatibility.', 'keywords': 'bpf_get_current_pid_tgid,prog types,container', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4c195ee4865d57786b3a63018d489b8a07877354 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4c195ee4865d57786b3a63018d489b8a07877354 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1710883620 + Commit Message: + selftests/bpf: Add a sk_msg prog bpf_get_ns_current_pid_tgid() test + +Add a sk_msg bpf program test where the program is running in a pid +namespace. The test is successful: + #165/4 ns_current_pid_tgid/new_ns_sk_msg:OK + +Signed-off-by: Yonghong Song +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240315184915.2976718-1-yonghong.song@linux.dev + + Parent Hashes: 87ade6cd859ea9dbde6e80b3fcf717ed9a73b4a9 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest for sk_msg program using bpf_get_ns_current_pid_tgid().', 'keywords': 'selftest, sk_msg, bpf_get_ns_current_pid_tgid', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 87ade6cd859ea9dbde6e80b3fcf717ed9a73b4a9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 87ade6cd859ea9dbde6e80b3fcf717ed9a73b4a9 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1710883619 + Commit Message: + selftests/bpf: Add a cgroup prog bpf_get_ns_current_pid_tgid() test + +Add a cgroup bpf program test where the bpf program is running +in a pid namespace. The test is successfully: + #165/3 ns_current_pid_tgid/new_ns_cgrp:OK + +Signed-off-by: Yonghong Song +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240315184910.2976522-1-yonghong.song@linux.dev + + Parent Hashes: 4d4bd29e363c467752536f874a2cba10a5923c59 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test for cgroup BPF programs using bpf_get_ns_current_pid_tgid in a PID namespace.', 'keywords': 'cgroup, test, pid namespace', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 4d4bd29e363c467752536f874a2cba10a5923c59 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4d4bd29e363c467752536f874a2cba10a5923c59 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1710883618 + Commit Message: + selftests/bpf: Refactor out some functions in ns_current_pid_tgid test + +Refactor some functions in both user space code and bpf program +as these functions are used by later cgroup/sk_msg tests. +Another change is to mark tp program optional loading as later +patches will use optional loading as well since they have quite +different attachment and testing logic. + +There is no functionality change. + +Signed-off-by: Yonghong Song +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240315184904.2976123-1-yonghong.song@linux.dev + + Parent Hashes: 84239a24d10174fcfc7d6760cb120435a6ff69af + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor functions in the ns_current_pid_tgid test for future use in cgroup/sk_msg selftests without changing functionality.', 'keywords': 'refactor, selftests, optional loading', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs', 'tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 84239a24d10174fcfc7d6760cb120435a6ff69af +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 84239a24d10174fcfc7d6760cb120435a6ff69af + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1710883477 + Commit Message: + selftests/bpf: Replace CHECK with ASSERT_* in ns_current_pid_tgid test + +Replace CHECK in selftest ns_current_pid_tgid with recommended ASSERT_* style. +I also shortened subtest name as the prefix of subtest name is covered +by the test name already. + +This patch does fix a testing issue. Currently even if bss->user_{pid + Parent Hashes: eb166e522c77699fc19bfa705652327a1e51a117 + Refs: tgid} +is not correct + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaced CHECK with ASSERT_* in the ns_current_pid_tgid selftest for better clarity and error handling.', 'keywords': 'CHECK, ASSERT, selftest', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: eb166e522c77699fc19bfa705652327a1e51a117 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: eb166e522c77699fc19bfa705652327a1e51a117 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1710883447 + Commit Message: + bpf: Allow helper bpf_get_[ns_]current_pid_tgid() for all prog types + +Currently bpf_get_current_pid_tgid() is allowed in tracing + Parent Hashes: 1a4a0cb7985f921548f1a7ac17686afbefe67f87 + Refs: cgroup +and sk_msg progs while bpf_get_ns_current_pid_tgid() is only allowed +in tracing progs. + +We have an internal use case where for an application running +in a container (with pid namespace) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows bpf_get_[ns_]current_pid_tgid() helper function for all eBPF program types.', 'keywords': 'helper, prog types, pid tgid', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f6e922365faf4cd576bd1cf3e64b58c8a32e1856 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f6e922365faf4cd576bd1cf3e64b58c8a32e1856 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1710852449 + Commit Message: + xsk: Don't assume metadata is always requested in TX completion + +`compl->tx_timestam != NULL` means that the user has explicitly +requested the metadata via XDP_TX_METADATA+XDP_TX_METADATA_TIMESTAMP. + +Fixes: 48eb03dd2630 ("xsk: Add TX timestamp and TX checksum offload support") +Reported-by: Daniele Salvatore Albano +Signed-off-by: Stanislav Fomichev +Signed-off-by: Daniel Borkmann +Tested-by: Daniele Salvatore Albano +Link: https://lore.kernel.org/bpf/20240318165427.1403313-1-sdf@google.com + + Parent Hashes: 0740b6427e90ef03177888c50dc1c78ca6e0f7f0 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes assumption about metadata request in TX completion for xsk.', 'keywords': 'xsk,metadata,TX completion', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['xdp like programs', 'socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 1a4a0cb7985f921548f1a7ac17686afbefe67f87 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1a4a0cb7985f921548f1a7ac17686afbefe67f87 + Author Name: Jesper Dangaard Brouer + Author Email: hawk@kernel.org + Commit Date: 1710852363 + Commit Message: + bpf/lpm_trie: Inline longest_prefix_match for fastpath + +The BPF map type LPM (Longest Prefix Match) is used heavily +in production by multiple products that have BPF components. +Perf data shows trie_lookup_elem() and longest_prefix_match() +being part of kernels perf top. + +For every level in the LPM tree trie_lookup_elem() calls out +to longest_prefix_match(). The compiler is free to inline this +call + Parent Hashes: c733239f8f530872a1f80d8c45dcafbaff368737 + Refs: but chooses not to inline + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit inlines the longest_prefix_match function for performance improvements in the LPM trie BPF map.', 'keywords': 'inline, LPM trie, performance', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: c733239f8f530872a1f80d8c45dcafbaff368737 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c733239f8f530872a1f80d8c45dcafbaff368737 + Author Name: Christophe Leroy + Author Email: christophe.leroy@csgroup.eu + Commit Date: 1710796727 + Commit Message: + bpf: Check return from set_memory_rox() + +arch_protect_bpf_trampoline() and alloc_new_pack() call +set_memory_rox() which can fail + Parent Hashes: e3362acd796789dc0562eb1a3937007b0beb0c5b + Refs: leading to unprotected memory. + +Take into account return from set_memory_rox() function and add +__must_check flag to arch_protect_bpf_trampoline(). + +Signed-off-by: Christophe Leroy +Reviewed-by: Kees Cook +Link: https://lore.kernel.org/r/fe1c163c83767fde5cab31d209a4a6be3ddb3a73.1710574353.git.christophe.leroy@csgroup.eu +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ensures proper handling of set_memory_rox() return by using __must_check in arch_protect_bpf_trampoline().', 'keywords': 'set_memory_rox, arch_protect_bpf_trampoline, __must_check', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: e3362acd796789dc0562eb1a3937007b0beb0c5b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e3362acd796789dc0562eb1a3937007b0beb0c5b + Author Name: Christophe Leroy + Author Email: christophe.leroy@csgroup.eu + Commit Date: 1710796727 + Commit Message: + bpf: Remove arch_unprotect_bpf_trampoline() + +Last user of arch_unprotect_bpf_trampoline() was removed by +commit 187e2af05abe ("bpf: struct_ops supports more than one page for +trampolines.") + +Remove arch_unprotect_bpf_trampoline() + +Reported-by: Daniel Borkmann +Fixes: 187e2af05abe ("bpf: struct_ops supports more than one page for trampolines.") +Signed-off-by: Christophe Leroy +Link: https://lore.kernel.org/r/42c635bb54d3af91db0f9b85d724c7c290069f67.1710574353.git.christophe.leroy@csgroup.eu +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 7b30c296af6525571fc967f6a8661f6e1127369e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes the unused arch_unprotect_bpf_trampoline function after its last user was removed.', 'keywords': 'remove,arch_unprotect_bpf_trampoline,trampolines', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7b30c296af6525571fc967f6a8661f6e1127369e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7b30c296af6525571fc967f6a8661f6e1127369e + Author Name: Mykyta Yatsenko + Author Email: yatsenko@meta.com + Commit Date: 1710794711 + Commit Message: + libbpbpf: Check bpf_map/bpf_program fd validity + +libbpf creates bpf_program/bpf_map structs for each program/map that +user defines + Parent Hashes: 7f3edd0c72c3f7214f8f28495f2e6466348eb128 + Refs: but it allows to disable creating/loading those objects in +kernel + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a check for the validity of bpf_map and bpf_program file descriptors in libbpf.', 'keywords': 'libbpf, validity check, bpf_program', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7f3edd0c72c3f7214f8f28495f2e6466348eb128 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7f3edd0c72c3f7214f8f28495f2e6466348eb128 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1710791290 + Commit Message: + bpf: Remove unnecessary err < 0 check in bpf_struct_ops_map_update_elem + +There is a "if (err)" check earlier + Parent Hashes: 4c8644f86c854c214aaabbcc24a27fa4c7e6a951 + Refs: so the "if (err < 0)" +check that this patch removing is unnecessary. It was my overlook +when making adjustments to the bpf_struct_ops_prepare_trampoline() +such that the caller does not have to worry about the new page when +the function returns error. + +Fixes: 187e2af05abe ("bpf: struct_ops supports more than one page for trampolines.") +Signed-off-by: Martin KaFai Lau +Signed-off-by: Andrii Nakryiko +Acked-by: Stanislav Fomichev +Link: https://lore.kernel.org/bpf/20240315192112.2825039-1-martin.lau@linux.dev + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove redundant error check in bpf_struct_ops_map_update_elem function.', 'keywords': 'error check, redundant, bpf_struct_ops', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 35c3e27917568192927c785fc380f139255468b4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 35c3e27917568192927c785fc380f139255468b4 + Author Name: Abhishek Chauhan + Author Email: quic_abchauha@quicinc.com + Commit Date: 1710764993 + Commit Message: + Revert "net: Re-use and set mono_delivery_time bit for userspace tstamp packets" + +This reverts commit 885c36e59f46375c138de18ff1692f18eff67b7f. + +The patch currently broke the bpf selftest test_tc_dtime because +uapi field __sk_buff->tstamp_type depends on skb->mono_delivery_time which +does not necessarily mean mono with the original fix as the bit was re-used +for userspace timestamp as well to avoid tstamp reset in the forwarding +path. To solve this we need to keep mono_delivery_time as is and +introduce another bit called user_delivery_time and fall back to the +initial proposal of setting the user_delivery_time bit based on +sk_clockid set from userspace. + +Fixes: 885c36e59f46 ("net: Re-use and set mono_delivery_time bit for userspace tstamp packets") +Link: https://lore.kernel.org/netdev/bc037db4-58bb-4861-ac31-a361a93841d3@linux.dev/ +Signed-off-by: Abhishek Chauhan +Acked-by: Daniel Borkmann +Acked-by: Martin KaFai Lau +Signed-off-by: David S. Miller + + Parent Hashes: f490c492e946d8ffbe65ad4efc66de3c5ede30a4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit reverts a patch due to a selftest failure related to reuse of mono_delivery_time bit.', 'keywords': 'reverts, mono_delivery_time, selftest', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0740b6427e90ef03177888c50dc1c78ca6e0f7f0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0740b6427e90ef03177888c50dc1c78ca6e0f7f0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710537850 + Commit Message: + Merge branch 'bpf-arena-followups' + +Alexei Starovoitov says: + +==================== +bpf: arena followups. + +From: Alexei Starovoitov + +A set of follow ups to clean up bpf_arena and adjust to the latest LLVM. +==================== + +Link: https://lore.kernel.org/r/20240315021834.62988-1-alexei.starovoitov@gmail.com +Signed-off-by: Andrii Nakryiko + + Parent Hashes: aae08491b9438347e9656c44021824ad236052b4 a90c5845db958701ddc7659bc4f6db6fa647e449 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Clean up bpf_arena and adapt to latest LLVM updates.', 'keywords': 'bpf_arena, followups, LLVM', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: a90c5845db958701ddc7659bc4f6db6fa647e449 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a90c5845db958701ddc7659bc4f6db6fa647e449 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710537846 + Commit Message: + selftests/bpf: Add arena test case for 4Gbyte corner case + +Check that 4Gbyte arena can be allocated and overflow/underflow access in +the first and the last page behaves as expected. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Stanislav Fomichev +Link: https://lore.kernel.org/bpf/20240315021834.62988-5-alexei.starovoitov@gmail.com + + Parent Hashes: 9a2d5a966b47e5657b22dfa257365b7ef2abc3c0 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest for 4Gbyte allocation and access behavior in bpf arena.', 'keywords': '4Gbyte,arena,test', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9a2d5a966b47e5657b22dfa257365b7ef2abc3c0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9a2d5a966b47e5657b22dfa257365b7ef2abc3c0 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710537843 + Commit Message: + selftests/bpf: Remove hard coded PAGE_SIZE macro. + +Remove hard coded PAGE_SIZE. +Add #include instead (that works on x86-64 and s390) +and fallback to slow getpagesize() for aarch64. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Stanislav Fomichev +Link: https://lore.kernel.org/bpf/20240315021834.62988-4-alexei.starovoitov@gmail.com + + Parent Hashes: 10ebe835c937a11870690aa44c7c970fe906ff54 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes hard coded PAGE_SIZE and introduces new includes for compatibility.', 'keywords': 'PAGE_SIZE, compatibility, selftests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 10ebe835c937a11870690aa44c7c970fe906ff54 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 10ebe835c937a11870690aa44c7c970fe906ff54 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710537840 + Commit Message: + libbpf + Parent Hashes: ee498a38f3177d9ee0213839d3a05b94272aa48c + Refs: selftests/bpf: Adjust libbpf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adjustments made to libbpf in the selftests for bpf.', 'keywords': 'libbpf, selftests, bpf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ee498a38f3177d9ee0213839d3a05b94272aa48c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ee498a38f3177d9ee0213839d3a05b94272aa48c + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710537825 + Commit Message: + bpf: Clarify bpf_arena comments. + +Clarify two bpf_arena comments + Parent Hashes: aae08491b9438347e9656c44021824ad236052b4 + Refs: use existing SZ_4G #define + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit clarifies comments in the bpf_arena code section.', 'keywords': 'bpf, arena, comments', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 4c8644f86c854c214aaabbcc24a27fa4c7e6a951 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4c8644f86c854c214aaabbcc24a27fa4c7e6a951 + Author Name: Colin Ian King + Author Email: colin.i.king@gmail.com + Commit Date: 1710510836 + Commit Message: + selftests/bpf: Remove second semicolon + +There are statements with two semicolons. Remove the second one + Parent Hashes: e60adf513275c3a38e5cb67f7fd12387e43a3ff5 + Refs: it +is redundant. + +Signed-off-by: Colin Ian King +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240315092654.2431062-1-colin.i.king@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove redundant second semicolon in selftests for BPF.', 'keywords': 'selftests,semicolon,BPF', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5384cc0d1a88c27448a6a4e65b8abe6486de8012 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5384cc0d1a88c27448a6a4e65b8abe6486de8012 + Author Name: Hangbin Liu + Author Email: liuhangbin@gmail.com + Commit Date: 1710510391 + Commit Message: + scripts/bpf_doc: Use silent mode when exec make cmd + +When getting kernel version via make + Parent Hashes: 44d79142ede8162fd67bf8ca4ddbda1fbcfa94f1 + Refs: the result may be polluted by other +output + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit changes the bpf_doc script to use silent mode for make commands to avoid output pollution.', 'keywords': 'bpf_doc,silent mode,make', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: e60adf513275c3a38e5cb67f7fd12387e43a3ff5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e60adf513275c3a38e5cb67f7fd12387e43a3ff5 + Author Name: Christophe Leroy + Author Email: christophe.leroy@csgroup.eu + Commit Date: 1710469732 + Commit Message: + bpf: Take return from set_memory_rox() into account with bpf_jit_binary_lock_ro() + +set_memory_rox() can fail + Parent Hashes: 7d2cc63eca0c993c99d18893214abf8f85d566d8 + Refs: leaving memory unprotected. + +Check return and bail out when bpf_jit_binary_lock_ro() returns +an error. + +Link: https://github.com/KSPP/linux/issues/7 +Signed-off-by: Christophe Leroy +Cc: linux-hardening@vger.kernel.org +Reviewed-by: Kees Cook +Reviewed-by: Puranjay Mohan +Reviewed-by: Ilya Leoshkevich # s390x +Acked-by: Tiezhu Yang # LoongArch +Reviewed-by: Johan Almbladh # MIPS Part +Message-ID: <036b6393f23a2032ce75a1c92220b2afcb798d5d.1709850515.git.christophe.leroy@csgroup.eu> +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix check return handling in bpf_jit_binary_lock_ro() for set_memory_rox() failures.', 'keywords': 'bpf, jit, memory', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7d2cc63eca0c993c99d18893214abf8f85d566d8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7d2cc63eca0c993c99d18893214abf8f85d566d8 + Author Name: Christophe Leroy + Author Email: christophe.leroy@csgroup.eu + Commit Date: 1710469732 + Commit Message: + bpf: Take return from set_memory_ro() into account with bpf_prog_lock_ro() + +set_memory_ro() can fail + Parent Hashes: 4d8926a0407cff0c864b759b59104f4fb6f8efab + Refs: leaving memory unprotected. + +Check its return and take it into account as an error. + +Link: https://github.com/KSPP/linux/issues/7 +Signed-off-by: Christophe Leroy +Cc: linux-hardening@vger.kernel.org +Reviewed-by: Kees Cook +Message-ID: <286def78955e04382b227cb3e4b6ba272a7442e3.1709850515.git.christophe.leroy@csgroup.eu> +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit handles failures from the set_memory_ro() function within bpf_prog_lock_ro().', 'keywords': 'bpf, set_memory_ro, error-handling', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4d8926a0407cff0c864b759b59104f4fb6f8efab +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4d8926a0407cff0c864b759b59104f4fb6f8efab + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710469696 + Commit Message: + bpf: preserve sleepable bit in subprog info + +Copy over main program's sleepable bit into subprog's info. This might +be important for + Parent Hashes: 6cda7e17392e0eca9fcafcb9b1d269c31fd737b7 + Refs: e.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Preserve the sleepable bit in subprograms' info for eBPF programs.", 'keywords': 'sleepable, subprog, info', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6cda7e17392e0eca9fcafcb9b1d269c31fd737b7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6cda7e17392e0eca9fcafcb9b1d269c31fd737b7 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710449683 + Commit Message: + Merge branch 'ignore-additional-fields-in-the-struct_ops-maps-in-an-updated-version' + +Kui-Feng Lee says: + +==================== +Ignore additional fields in the struct_ops maps in an updated version. + +According to an offline discussion + Parent Hashes: 9bf48fa19a4b1d186e08b20bf7e5de26a15644fb 26a7cf2bbea656837583f9a1a0f9390db63d6cc3 + Refs: it would be beneficial to +implement a backward-compatible method for struct_ops types with +additional fields that are not present in older kernels. + +This patchset accepts additional fields of a struct_ops map with all +zero values even if these fields are not in the corresponding type in +the kernel. This provides a way to be backward compatible. User space +programs can use the same map on a machine running an old kernel by +clearing fields that do not exist in the kernel. + +For example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implemented backward-compatible handling for additional fields in struct_ops maps for older kernels.', 'keywords': 'backward-compatible, struct_ops, maps', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 26a7cf2bbea656837583f9a1a0f9390db63d6cc3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 26a7cf2bbea656837583f9a1a0f9390db63d6cc3 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1710449225 + Commit Message: + selftests/bpf: Ensure libbpf skip all-zeros fields of struct_ops maps. + +A new version of a type may have additional fields that do not exist in +older versions. Previously + Parent Hashes: c911fc61a7ce367f9ea48e457f31bb171e80ca4d + Refs: libbpf would reject struct_ops maps with a new +version containing extra fields when running on a machine with an old +kernel. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Ensure libbpf skips all-zero fields in struct_ops maps for compatibility with older kernels.', 'keywords': 'libbpf, struct_ops, compatibility', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c911fc61a7ce367f9ea48e457f31bb171e80ca4d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c911fc61a7ce367f9ea48e457f31bb171e80ca4d + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1710449225 + Commit Message: + libbpf: Skip zeroed or null fields if not found in the kernel type. + +Accept additional fields of a struct_ops type with all zero values even if +these fields are not in the corresponding type in the kernel. This provides +a way to be backward compatible. User space programs can use the same map +on a machine running an old kernel by clearing fields that do not exist in +the kernel. + +Signed-off-by: Kui-Feng Lee +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240313214139.685112-2-thinker.li@gmail.com + + Parent Hashes: 9bf48fa19a4b1d186e08b20bf7e5de26a15644fb + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'libbpf update to skip zeroed fields for backward compatibility with older kernels.', 'keywords': 'libbpf,backward compatibility,zeroed fields', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9bf48fa19a4b1d186e08b20bf7e5de26a15644fb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9bf48fa19a4b1d186e08b20bf7e5de26a15644fb + Author Name: Quentin Monnet + Author Email: qmo@kernel.org + Commit Date: 1710448877 + Commit Message: + libbpf: Prevent null-pointer dereference when prog to load has no BTF + +In bpf_objec_load_prog() + Parent Hashes: fe879bb42f8a6513ed18e9d22efb99cb35590201 + Refs: there's no guarantee that obj->btf is non-NULL +when passing it to btf__fd() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a null-pointer dereference in libbpf when the program to load has no BTF.', 'keywords': 'null-pointer,libbpf,BTF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fe879bb42f8a6513ed18e9d22efb99cb35590201 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fe879bb42f8a6513ed18e9d22efb99cb35590201 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1710448663 + Commit Message: + bpftool: Fix missing pids during link show + +Current 'bpftool link' command does not show pids + Parent Hashes: c2a0257c1edf16c6acd2afac7572d7e9043b6577 + Refs: e.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes missing process IDs in link information shown by bpftool command.', 'keywords': 'bpftool, pids, link', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c2a0257c1edf16c6acd2afac7572d7e9043b6577 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c2a0257c1edf16c6acd2afac7572d7e9043b6577 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1710448461 + Commit Message: + bpftool: Cast pointers for shadow types explicitly. + +According to a report + Parent Hashes: 9187210eee7d87eea37b45ea93454a88681894a4 + Refs: skeletons fail to assign shadow pointers when being +compiled with C++ programs. Unlike C doing implicit casting for void +pointers + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit explicitly casts pointers for shadow types in bpftool to address compilation issues with C++.', 'keywords': 'bpftool, pointers, shadow', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 44d79142ede8162fd67bf8ca4ddbda1fbcfa94f1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 44d79142ede8162fd67bf8ca4ddbda1fbcfa94f1 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1710443085 + Commit Message: + bpf: Temporarily disable atomic operations in BPF arena + +Currently + Parent Hashes: e30cef001da259e8df354b813015d0e5acc08740 + Refs: the x86 JIT handling PROBE_MEM32 tagged accesses is not +equipped to handle atomic accesses into PTR_TO_ARENA + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit temporarily disables atomic operations in the BPF arena due to limitations in x86 JIT handling.', 'keywords': 'atomic, JIT, PTR_TO_ARENA', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3e78a6c0d3e02e4cf881dc84c5127e9990f939d6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3e78a6c0d3e02e4cf881dc84c5127e9990f939d6 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1710435375 + Commit Message: + Merge tag 'hid-for-linus-2024031301' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid + +Pull HID updates from Jiri Kosina: + + - support for the following Bluetooth devices from Samsung: Samsung + wireless {Keyboard + Parent Hashes: b345ff698ec7ed52d90bd5603ec8fc1802f40110 0db18cd824f781584a880653e65a0cfd38f060ee + Refs: GamePad + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge HID subsystem updates for support of Samsung Bluetooth devices.', 'keywords': 'Merge,HID,Samsung', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 9187210eee7d87eea37b45ea93454a88681894a4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9187210eee7d87eea37b45ea93454a88681894a4 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1710290648 + Commit Message: + Merge tag 'net-next-6.9' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next + +Pull networking updates from Jakub Kicinski: + "Core & protocols: + + - Large effort by Eric to lower rtnl_lock pressure and remove locks: + + - Make commonly used parts of rtnetlink (address + Parent Hashes: 1f440397665f4241346e4cc6d93f8b73880815d1 ed1f164038b50c5864aa85389f3ffd456f050cca + Refs: route dumps + etc) lockless + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merging networking updates, focusing on reducing rtnl_lock pressure and achieving lockless operations in rtnetlink.', 'keywords': 'networking,rtnl_lock,rtnetlink', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5f20e6ab1f65aaaaae248e6946d5cb6d039e7de8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5f20e6ab1f65aaaaae248e6946d5cb6d039e7de8 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1710205564 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Alexei Starovoitov says: + +==================== +pull-request: bpf-next 2024-03-11 + +We've added 59 non-merge commits during the last 9 day(s) which contain +a total of 88 files changed + Parent Hashes: f095fefacdd35b4ea97dc6d88d054f2749a73d07 66c8473135c62f478301a0e5b3012f203562dfa6 + Refs: 4181 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merged changes from 'bpf-next' branch into the main network development branch.", 'keywords': 'merge,bpf-next,network', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 66c8473135c62f478301a0e5b3012f203562dfa6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 66c8473135c62f478301a0e5b3012f203562dfa6 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710200485 + Commit Message: + bpf: move sleepable flag from bpf_prog_aux to bpf_prog + +prog->aux->sleepable is checked very frequently as part of (some) BPF +program run hot paths. So this extra aux indirection seems wasteful and +on busy systems might cause unnecessary memory cache misses. + +Let's move sleepable flag into prog itself to eliminate unnecessary +pointer dereference. + +Signed-off-by: Andrii Nakryiko +Acked-by: Jiri Olsa +Message-ID: <20240309004739.2961431-1-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d6170e4aaf86424c24ce06e355b4573daa891b17 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Moved sleepable flag from bpf_prog_aux to bpf_prog for performance optimization.', 'keywords': 'sleepable,performance,flag', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d6170e4aaf86424c24ce06e355b4573daa891b17 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d6170e4aaf86424c24ce06e355b4573daa891b17 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1710200010 + Commit Message: + bpf: hardcode BPF_PROG_PACK_SIZE to 2MB * num_possible_nodes() + +On some architectures like ARM64 + Parent Hashes: 379b97bbf02feecae5ce870bc0c67e3d723e30f5 + Refs: PMD_SIZE can be really large in some +configurations. Like with CONFIG_ARM64_64K_PAGES=y the PMD_SIZE is +512MB. + +Use 2MB * num_possible_nodes() as the size for allocations done through +the prog pack allocator. On most architectures + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Hardcode BPF_PROG_PACK_SIZE to 2MB times num_possible_nodes across various architectures.', 'keywords': 'BPF, allocation, ARM64', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 379b97bbf02feecae5ce870bc0c67e3d723e30f5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 379b97bbf02feecae5ce870bc0c67e3d723e30f5 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1710198408 + Commit Message: + selftests/bpf: Add kprobe multi triggering benchmarks + +Adding kprobe multi triggering benchmarks. It's useful now to bench +new fprobe implementation and might be useful later as well. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240311211023.590321-1-jolsa@kernel.org + + Parent Hashes: 08701e306e480c56b68c1fa35f2c5b27204083e2 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds kprobe multi-triggering benchmarks for evaluating the new fprobe implementation.', 'keywords': 'kprobe, benchmarks, fprobe', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 08701e306e480c56b68c1fa35f2c5b27204083e2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 08701e306e480c56b68c1fa35f2c5b27204083e2 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710197023 + Commit Message: + Merge branch 'bpf-introduce-bpf-arena' + +Alexei Starovoitov says: + +==================== +bpf: Introduce BPF arena. + +From: Alexei Starovoitov + +v2->v3: +- contains bpf bits only + Parent Hashes: 365c2b32792e692bad6e3761ad19ac3f8f52c0fe 8df839ae23b8c581bdac4b6970d029d65a415852 + Refs: but cc-ing past audience for continuity +- since prerequisite patches landed + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces BPF arena to improve eBPF memory management.', 'keywords': 'BPF, arena, memory', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8df839ae23b8c581bdac4b6970d029d65a415852 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8df839ae23b8c581bdac4b6970d029d65a415852 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710197023 + Commit Message: + selftests/bpf: Add bpf_arena_htab test. + +bpf_arena_htab.h - hash table implemented as bpf program + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240308010812.89848-15-alexei.starovoitov@gmail.com + + Parent Hashes: 9f2c156f90a422b4897a8c2831076a96a31413d1 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test for bpf_arena_htab implemented as a BPF program.', 'keywords': 'test,bpf,hastable', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9f2c156f90a422b4897a8c2831076a96a31413d1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9f2c156f90a422b4897a8c2831076a96a31413d1 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710197023 + Commit Message: + selftests/bpf: Add bpf_arena_list test. + +bpf_arena_alloc.h - implements page_frag allocator as a bpf program. +bpf_arena_list.h - doubly linked link list as a bpf program. + +Compiled as a bpf program and as native C code. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240308010812.89848-14-alexei.starovoitov@gmail.com + + Parent Hashes: 80a4129fcf20da3c6941411155a9b3b45caa5b8d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for bpf_arena_list and page_frag allocator as bpf programs.', 'keywords': 'selftests,bpf_arena_list,page_frag', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 80a4129fcf20da3c6941411155a9b3b45caa5b8d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 80a4129fcf20da3c6941411155a9b3b45caa5b8d + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710197023 + Commit Message: + selftests/bpf: Add unit tests for bpf_arena_alloc/free_pages + +Add unit tests for bpf_arena_alloc/free_pages() functionality +and bpf_arena_common.h with a set of common helpers and macros that +is used in this test and the following patches. + +Also modify test_loader that didn't support running bpf_prog_type_syscall +programs. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240308010812.89848-13-alexei.starovoitov@gmail.com + + Parent Hashes: 204c628730c62de5a0b593008549a9b95aa96b01 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add unit tests for bpf_arena_alloc/free_pages and update test_loader for syscall programs.', 'keywords': 'unit tests,bpf_arena_alloc,syscall', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 204c628730c62de5a0b593008549a9b95aa96b01 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 204c628730c62de5a0b593008549a9b95aa96b01 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710197022 + Commit Message: + bpf: Add helper macro bpf_addr_space_cast() + +Introduce helper macro bpf_addr_space_cast() that emits: +rX = rX +instruction with off = BPF_ADDR_SPACE_CAST +and encodes dest and src address_space-s into imm32. + +It's useful with older LLVM that doesn't emit this insn automatically. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/bpf/20240308010812.89848-12-alexei.starovoitov@gmail.com + + Parent Hashes: 2e7ba4f8fd1fa879b37db0b738c23ba2af8292ee + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add helper macro bpf_addr_space_cast for older LLVM compatibility in eBPF.', 'keywords': 'helper macro, bpf_addr_space_cast, LLVM', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2e7ba4f8fd1fa879b37db0b738c23ba2af8292ee +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2e7ba4f8fd1fa879b37db0b738c23ba2af8292ee + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710197015 + Commit Message: + libbpf: Recognize __arena global variables. + +LLVM automatically places __arena variables into ".arena.1" ELF section. +In order to use such global variables bpf program must include definition +of arena map in ".maps" section + Parent Hashes: eed512e8ac64339cfc69da1a6a4b60982cb502ca + Refs: like: +struct { + __uint(type + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit updates libbpf to support __arena global variables in bpf programs.', 'keywords': 'libbpf,global variables,__arena', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: eed512e8ac64339cfc69da1a6a4b60982cb502ca +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: eed512e8ac64339cfc69da1a6a4b60982cb502ca + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196644 + Commit Message: + bpftool: Recognize arena map type + +Teach bpftool to recognize arena map type. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/bpf/20240308010812.89848-10-alexei.starovoitov@gmail.com + + Parent Hashes: 79ff13e99169ddb0e2277e046dbfb112f77dfac5 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds support for recognizing arena map type in bpftool.', 'keywords': 'bpftool, arena, map type', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 79ff13e99169ddb0e2277e046dbfb112f77dfac5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 79ff13e99169ddb0e2277e046dbfb112f77dfac5 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196644 + Commit Message: + libbpf: Add support for bpf_arena. + +mmap() bpf_arena right after creation + Parent Hashes: 4d2b56081c32cb33364745da434b88eeaa9d8d8d + Refs: since the kernel needs to +remember the address returned from mmap. This is user_vm_start. +LLVM will generate bpf_arena_cast_user() instructions where +necessary and JIT will add upper 32-bit of user_vm_start +to such pointers. + +Fix up bpf_map_mmap_sz() to compute mmap size as +map->value_size * map->max_entries for arrays and +PAGE_SIZE * map->max_entries for arena. + +Don't set BTF at arena creation time + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds support for bpf_arena in libbpf, enhancing mmap handling and pointer management.', 'keywords': 'libbpf,bpf_arena,mmap', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4d2b56081c32cb33364745da434b88eeaa9d8d8d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4d2b56081c32cb33364745da434b88eeaa9d8d8d + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196644 + Commit Message: + libbpf: Add __arg_arena to bpf_helpers.h + +Add __arg_arena to bpf_helpers.h + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Kumar Kartikeya Dwivedi +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240308010812.89848-8-alexei.starovoitov@gmail.com + + Parent Hashes: 2edc3de6fb650924a87fffebebc3b7572cbf6e38 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add __arg_arena to enhance functionality in bpf_helpers.h for libbpf.', 'keywords': 'libbpf,arg_arena,bpf_helpers', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2edc3de6fb650924a87fffebebc3b7572cbf6e38 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2edc3de6fb650924a87fffebebc3b7572cbf6e38 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196644 + Commit Message: + bpf: Recognize btf_decl_tag("arg: Arena") as PTR_TO_ARENA. + +In global bpf functions recognize btf_decl_tag("arg:arena") as PTR_TO_ARENA. + +Note + Parent Hashes: 6082b6c328b5486da2b356eae94b8b83c98b5565 + Refs: when the verifier sees: + +__weak void foo(struct bar *p) + +it recognizes 'p' as PTR_TO_MEM and 'struct bar' has to be a struct with scalars. +Hence the only way to use arena pointers in global functions is to tag them with "arg:arena". + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/bpf/20240308010812.89848-7-alexei.starovoitov@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit enables BPF functions to recognize arena pointers tagged with "arg:arena" as PTR_TO_ARENA in global functions.', 'keywords': 'btf_decl_tag,PTR_TO_ARENA,arena', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6082b6c328b5486da2b356eae94b8b83c98b5565 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6082b6c328b5486da2b356eae94b8b83c98b5565 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196644 + Commit Message: + bpf: Recognize addr_space_cast instruction in the verifier. + +rY = addr_space_cast(rX + Parent Hashes: 142fd4d2dcf58b1720a6af644f31de1a5551f219 + Refs: 0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds recognition of addr_space_cast instruction to the eBPF verifier.', 'keywords': 'addr_space_cast, verifier, bpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 142fd4d2dcf58b1720a6af644f31de1a5551f219 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 142fd4d2dcf58b1720a6af644f31de1a5551f219 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196644 + Commit Message: + bpf: Add x86-64 JIT support for bpf_addr_space_cast instruction. + +LLVM generates bpf_addr_space_cast instruction while translating +pointers between native (zero) address space and +__attribute__((address_space(N))). +The addr_space=1 is reserved as bpf_arena address space. + +rY = addr_space_cast(rX + Parent Hashes: 2fe99eb0ccf2bb73df65ebcbbf2f2ff70e63547b + Refs: 0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add x86-64 JIT support for bpf_addr_space_cast instruction to enhance pointer address space conversion.', 'keywords': 'x86-64 JIT, bpf_addr_space_cast, pointer conversion', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2fe99eb0ccf2bb73df65ebcbbf2f2ff70e63547b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2fe99eb0ccf2bb73df65ebcbbf2f2ff70e63547b + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196644 + Commit Message: + bpf: Add x86-64 JIT support for PROBE_MEM32 pseudo instructions. + +Add support for [LDX | STX | ST] + Parent Hashes: 667a86ad9b71d934c444eec193cf3508016f35c5 + Refs: PROBE_MEM32 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Support added for x86-64 JIT handling of PROBE_MEM32 pseudo instructions in eBPF.', 'keywords': 'x86-64, JIT, PROBE_MEM32', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 667a86ad9b71d934c444eec193cf3508016f35c5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 667a86ad9b71d934c444eec193cf3508016f35c5 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196644 + Commit Message: + bpf: Disasm support for addr_space_cast instruction. + +LLVM generates rX = addr_space_cast(rY + Parent Hashes: 317460317a02a1af512697e6e964298dedd8a163 + Refs: dst_addr_space + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added disassembly support for addr_space_cast instruction in bpf.', 'keywords': 'disassembly, addr_space_cast, instruction', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 317460317a02a1af512697e6e964298dedd8a163 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 317460317a02a1af512697e6e964298dedd8a163 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710196643 + Commit Message: + bpf: Introduce bpf_arena. + +Introduce bpf_arena + Parent Hashes: 365c2b32792e692bad6e3761ad19ac3f8f52c0fe + Refs: which is a sparse shared memory region between the bpf +program and user space. + +Use cases: +1. User space mmap-s bpf_arena and uses it as a traditional mmap-ed + anonymous region + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce bpf_arena for sparse shared memory usage between eBPF program and user space.', 'keywords': 'bpf_arena,sparse,memory', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 365c2b32792e692bad6e3761ad19ac3f8f52c0fe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 365c2b32792e692bad6e3761ad19ac3f8f52c0fe + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1710172800 + Commit Message: + selftests/bpf: Add fexit and kretprobe triggering benchmarks + +We already have kprobe and fentry benchmarks. Let's add kretprobe and +fexit ones for completeness. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/bpf/20240309005124.3004446-1-andrii@kernel.org + + Parent Hashes: d7bca9199a27b8690ae1c71dc11f825154af7234 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added benchmarks for fexit and kretprobe in selftests/bpf.', 'keywords': 'fexit,kretprobe,benchmarks', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: d7bca9199a27b8690ae1c71dc11f825154af7234 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d7bca9199a27b8690ae1c71dc11f825154af7234 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1710172690 + Commit Message: + mm: Introduce vmap_page_range() to map pages in PCI address space + +ioremap_page_range() should be used for ranges within vmalloc range only. +The vmalloc ranges are allocated by get_vm_area(). PCI has "resource" +allocator that manages PCI_IOBASE + Parent Hashes: 96b0f5addc7a0d9ed1f4969ca85ed7513cb1ed25 + Refs: IO_SPACE_LIMIT address range + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce vmap_page_range() for mapping pages in PCI address space, distinct from ioremap_page_range().', 'keywords': 'vmap_page_range, PCI, ioremap', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 08842c43d0165b0ed78907fd8cc92ce17d857913 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 08842c43d0165b0ed78907fd8cc92ce17d857913 + Author Name: Eric Dumazet + Author Email: edumazet@google.com + Commit Date: 1710150963 + Commit Message: + udp: no longer touch sk->sk_refcnt in early demux + +After commits ca065d0cf80f ("udp: no longer use SLAB_DESTROY_BY_RCU") +and 7ae215d23c12 ("bpf: Don't refcount LISTEN sockets in sk_assign()") +UDP early demux no longer need to grab a refcount on the UDP socket. + +This save two atomic operations per incoming packet for connected +sockets. + +Signed-off-by: Eric Dumazet +Cc: Martin KaFai Lau +Cc: Joe Stringer +Cc: Alexei Starovoitov +Cc: Willem de Bruijn +Cc: Kuniyuki Iwashima +Acked-by: Paolo Abeni +Signed-off-by: David S. Miller + + Parent Hashes: e996401e06a5232f61b4906e2eea643fffa88396 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes the need to modify sk_refcnt in UDP early demux for improved performance.', 'keywords': 'UDP, refcount, demux', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 96d9cbe2f2ff7abde021bac75eafaceabe9a51fa +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 96d9cbe2f2ff7abde021bac75eafaceabe9a51fa + Author Name: Manjunath Patil + Author Email: manjunath.b.patil@oracle.com + Commit Date: 1710069474 + Commit Message: + RDMA/cm: add timeout to cm_destroy_id wait + +Add timeout to cm_destroy_id + Parent Hashes: 2d5c00815778ec4f4e0a84e405e3e157b7815db1 + Refs: so that userspace can trigger any data +collection that would help in analyzing the cause of delay in destroying +the cm_id. + +New noinline function helps dtrace/ebpf programs to hook on to it. +Existing functionality isn't changed except triggering a probe-able new +function at every timeout interval. + +We have seen cases where CM messages stuck with MAD layer (either due to +software bug or faulty HCA) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a timeout to the cm_destroy_id wait for improved data collection during delays.', 'keywords': 'timeout,cm_destroy_id,dtrace', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 96b0f5addc7a0d9ed1f4969ca85ed7513cb1ed25 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 96b0f5addc7a0d9ed1f4969ca85ed7513cb1ed25 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1710002395 + Commit Message: + arm64 + Parent Hashes: a27e89673abf1623c298ea84eaa03f4c57aeca1b + Refs: bpf: Use bpf_prog_pack for arm64 bpf trampoline + +We used bpf_prog_pack to aggregate bpf programs into huge page to +relieve the iTLB pressure on the system. This was merged for ARM64[1] +We can apply it to bpf trampoline as well. This would increase the +preformance of fentry and struct_ops programs. + +[1] https://lore.kernel.org/bpf/20240228141824.119877-1-puranjay12@gmail.com/ + +Signed-off-by: Puranjay Mohan +Reviewed-by: Pu Lehui +Message-ID: <20240304202803.31400-1-puranjay12@gmail.com> +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit uses bpf_prog_pack to optimize bpf trampoline performance on ARM64, reducing iTLB pressure and enhancing fentry and struct_ops programs.', 'keywords': 'bpf_prog_pack,ARM64,iTLB', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: caabd859c41b50a571cfdf7747de9f245c5d531b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: caabd859c41b50a571cfdf7747de9f245c5d531b + Author Name: fuyuanli + Author Email: fuyuanli@didiglobal.com + Commit Date: 1709893547 + Commit Message: + tcp: Add skb addr and sock addr to arguments of tracepoint tcp_probe. + +It is useful to expose skb addr and sock addr to user in tracepoint +tcp_probe + Parent Hashes: 6025b9135f7a8b46826a5fcf947259da43bac281 + Refs: so that we can get more information while monitoring +receiving of tcp data + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds skb and sock addresses as arguments to the tcp_probe tracepoint for enhanced monitoring of TCP data reception.', 'keywords': 'tcp_probe, skb addr, sock addr', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: a27e89673abf1623c298ea84eaa03f4c57aeca1b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a27e89673abf1623c298ea84eaa03f4c57aeca1b + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709870792 + Commit Message: + Merge branch 'fix-hash-bucket-overflow-checks-for-32-bit-arches' + +Toke Høiland-Jørgensen says: + +==================== +Fix hash bucket overflow checks for 32-bit arches + +Syzbot managed to trigger a crash by creating a DEVMAP_HASH map with a +large number of buckets because the overflow check relies on +well-defined behaviour that is only correct on 64-bit arches. + +Fix the overflow checks to happen before values are rounded up in all +the affected map types. + +v3: +- Keep the htab->n_buckets > U32_MAX / sizeof(struct bucket) check +- Use 1UL << 31 instead of U32_MAX / 2 + 1 as the constant to check + against +- Add patch to fix stackmap.c +v2: +- Fix off-by-one error in overflow check +- Apply the same fix to hashtab + Parent Hashes: c7d4274e90a1e7aa43d11d2a16066cbbe610070e 7a4b21250bf79eef26543d35bd390448646c536b + Refs: where the devmap_hash code was copied + from (John) + +Toke Høiland-Jørgensen (3): + bpf: Fix DEVMAP_HASH overflow check on 32-bit arches + bpf: Fix hashtab overflow check on 32-bit arches + bpf: Fix stackmap overflow check on 32-bit arches + + kernel/bpf/devmap.c | 11 ++++++----- + kernel/bpf/hashtab.c | 14 +++++++++----- + kernel/bpf/stackmap.c | 9 ++++++--- + 3 files changed + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix overflow checks in hash buckets for 32-bit architectures in eBPF.', 'keywords': 'overflow, 32-bit, hash', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7a4b21250bf79eef26543d35bd390448646c536b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7a4b21250bf79eef26543d35bd390448646c536b + Author Name: Toke Høiland-Jørgensen + Author Email: toke@redhat.com + Commit Date: 1709870785 + Commit Message: + bpf: Fix stackmap overflow check on 32-bit arches + +The stackmap code relies on roundup_pow_of_two() to compute the number +of hash buckets + Parent Hashes: 6787d916c2cf9850c97a0a3f73e08c43e7d973b1 + Refs: and contains an overflow check by checking if the +resulting value is 0. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes stackmap overflow check issue on 32-bit architectures in BPF.', 'keywords': 'stackmap, overflow, 32-bit', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6787d916c2cf9850c97a0a3f73e08c43e7d973b1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6787d916c2cf9850c97a0a3f73e08c43e7d973b1 + Author Name: Toke Høiland-Jørgensen + Author Email: toke@redhat.com + Commit Date: 1709870756 + Commit Message: + bpf: Fix hashtab overflow check on 32-bit arches + +The hashtab code relies on roundup_pow_of_two() to compute the number of +hash buckets + Parent Hashes: 281d464a34f540de166cee74b723e97ac2515ec3 + Refs: and contains an overflow check by checking if the +resulting value is 0. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes overflow issue in hashtab code for 32-bit architectures.', 'keywords': 'hashtab,overflow,32-bit', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 281d464a34f540de166cee74b723e97ac2515ec3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 281d464a34f540de166cee74b723e97ac2515ec3 + Author Name: Toke Høiland-Jørgensen + Author Email: toke@redhat.com + Commit Date: 1709870558 + Commit Message: + bpf: Fix DEVMAP_HASH overflow check on 32-bit arches + +The devmap code allocates a number hash buckets equal to the next power +of two of the max_entries value provided when creating the map. When +rounding up to the next power of two + Parent Hashes: c7d4274e90a1e7aa43d11d2a16066cbbe610070e + Refs: the 32-bit variable storing the +number of buckets can overflow + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes DEVMAP_HASH overflow issue on 32-bit architectures in the eBPF subsystem.', 'keywords': 'DEVMAP_HASH, overflow, 32-bit', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c7d4274e90a1e7aa43d11d2a16066cbbe610070e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c7d4274e90a1e7aa43d11d2a16066cbbe610070e + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1709852517 + Commit Message: + Merge branch 'bpf: arena prerequisites' + +Alexei Starovoitov says: + +==================== +These are bpf_arena prerequisite patches. +Useful on its own. + +Alexei Starovoitov (5): + bpf: Allow kfuncs return 'void *' + bpf: Recognize '__map' suffix in kfunc arguments + bpf: Plumb get_unmapped_area() callback into bpf_map_ops + libbpf: Allow specifying 64-bit integers in map BTF. + bpf: Tell bpf programs kernel's PAGE_SIZE +==================== + +Signed-off-by: Martin KaFai Lau + + Parent Hashes: e63985ecd22681c7f5975f2e8637187a326b6791 fe5064158c561b807af5708c868f6c7cb5144e01 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit merges prerequisites for bpf_arena to enhance BPF functionalities including kfunc improvements and map operations.', 'keywords': 'bpf_arena, kfuncs, map_ops', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fe5064158c561b807af5708c868f6c7cb5144e01 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fe5064158c561b807af5708c868f6c7cb5144e01 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709852328 + Commit Message: + bpf: Tell bpf programs kernel's PAGE_SIZE + +vmlinux BTF includes all kernel enums. +Add __PAGE_SIZE = PAGE_SIZE enum + Parent Hashes: 1576b07961971d4eeb0e269c7133e9a6d430daf8 + Refs: so that bpf programs +that include vmlinux.h can easily access it. + +Acked-by: Kumar Kartikeya Dwivedi +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/r/20240307031228.42896-7-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit introduces a kernel enum for PAGE_SIZE to make it accessible to bpf programs using vmlinux.h.', 'keywords': 'PAGE_SIZE, bpf, vmlinux', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1576b07961971d4eeb0e269c7133e9a6d430daf8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1576b07961971d4eeb0e269c7133e9a6d430daf8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1709852328 + Commit Message: + bpftool: rename is_internal_mmapable_map into is_mmapable_map + +It's not restricted to working with "internal" maps + Parent Hashes: d147357e2e5977c5fe9218457a1e359fd1d36609 + Refs: it cares about any +map that can be mmap'ed. Reflect that in more succinct and generic name. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/r/20240307031228.42896-6-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Renamed function to reflect usage with any mmap'able map, not just internal ones.", 'keywords': 'rename, mmapable, bpftool', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d147357e2e5977c5fe9218457a1e359fd1d36609 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d147357e2e5977c5fe9218457a1e359fd1d36609 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709852328 + Commit Message: + libbpf: Allow specifying 64-bit integers in map BTF. + +__uint() macro that is used to specify map attributes like: + __uint(type + Parent Hashes: cf2c2e4a3d910270903d50462aaa75140cdb2c96 + Refs: BPF_MAP_TYPE_ARRAY); + __uint(map_flags + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit enables specifying 64-bit integers in map BTF using libbpf.', 'keywords': 'libbpf, 64-bit integers, map BTF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cf2c2e4a3d910270903d50462aaa75140cdb2c96 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cf2c2e4a3d910270903d50462aaa75140cdb2c96 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709852328 + Commit Message: + bpf: Plumb get_unmapped_area() callback into bpf_map_ops + +Subsequent patches introduce bpf_arena that imposes special alignment +requirements on address selection. + +Acked-by: Kumar Kartikeya Dwivedi +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/r/20240307031228.42896-4-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 8d94f1357c00d7706c1f3d0bb568e054cef6aea1 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Plumbs get_unmapped_area() callback into bpf_map_ops to support special alignment requirements.', 'keywords': 'get_unmapped_area, bpf_map_ops, alignment', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8d94f1357c00d7706c1f3d0bb568e054cef6aea1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8d94f1357c00d7706c1f3d0bb568e054cef6aea1 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709852328 + Commit Message: + bpf: Recognize '__map' suffix in kfunc arguments + +Recognize 'void *p__map' kfunc argument as 'struct bpf_map *p__map'. +It allows kfunc to have 'void *' argument for maps + Parent Hashes: 88d1d4a7eebea2836859246d91fe9d141789dfc3 + Refs: since bpf progs +will call them as: +struct { + __uint(type + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit allows kfunc arguments with a '__map' suffix to be recognized as 'struct bpf_map'.", 'keywords': 'kfunc, argument, map', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 88d1d4a7eebea2836859246d91fe9d141789dfc3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 88d1d4a7eebea2836859246d91fe9d141789dfc3 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709852328 + Commit Message: + bpf: Allow kfuncs return 'void *' + +Recognize return of 'void *' from kfunc as returning unknown scalar. + +Acked-by: Andrii Nakryiko +Acked-by: Kumar Kartikeya Dwivedi +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/r/20240307031228.42896-2-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: e63985ecd22681c7f5975f2e8637187a326b6791 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit allows kfuncs to return 'void *', treating it as unknown scalar.", 'keywords': 'kfuncs, void, scalar', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: df4793505abd5df399bc6d9a4d8fe81761f557cd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: df4793505abd5df399bc6d9a4d8fe81761f557cd + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1709832213 + Commit Message: + Merge tag 'net-6.8-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + "Including fixes from bpf + Parent Hashes: 67be068d31d423b857ffd8c34dbcc093f8dfff76 ba18deddd6d502da71fd6b6143c53042271b82bd + Refs: ipsec and netfilter. + + No solution yet for the stmmac issue mentioned in the last PR + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes including bpf from net-6.8-rc8 by Paolo Abeni.', 'keywords': 'networking,bpf,fixes', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tracepoints like programs', "It's not related to any of the above.", 'other']} +-------------------- +-------------------- +Processing Commit ID: d3eee81fd6111eb404318ddbaded3f86c7f21d70 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d3eee81fd6111eb404318ddbaded3f86c7f21d70 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1709785261 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-03-06 + +We've added 5 non-merge commits during the last 1 day(s) which contain +a total of 5 files changed + Parent Hashes: c055fc00c07be1f0df7375ab0036cebd1106ed38 2487007aa3b9fafbd2cb14068f49791ce1d7ede5 + Refs: 77 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merge tag 'for-netdev' with 5 non-merge commits affecting 5 files, totaling 77 insertions.", 'keywords': 'merge,netdev,commits', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e63985ecd22681c7f5975f2e8637187a326b6791 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e63985ecd22681c7f5975f2e8637187a326b6791 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1709767096 + Commit Message: + bpf + Parent Hashes: 516fca5a7516cde7a9968f84179ed20ffb438885 + Refs: riscv64/cfi: Support kCFI + BPF on riscv64 + +The riscv BPF JIT doesn't emit proper kCFI prologues for BPF programs +and struct_ops trampolines when CONFIG_CFI_CLANG is enabled. + +This causes CFI failures when calling BPF programs and can even crash +the kernel due to invalid memory accesses. + +Example crash: + +root@rv-selftester:~/bpf# ./test_progs -a dummy_st_ops + + Unable to handle kernel paging request at virtual address ffffffff78204ffc + Oops [#1] + Modules linked in: bpf_testmod(OE) [....] + CPU: 3 PID: 356 Comm: test_progs Tainted: P OE 6.8.0-rc1 #1 + Hardware name: riscv-virtio + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix riscv BPF JIT to emit correct kCFI prologues for BPF programs with CONFIG_CFI_CLANG enabled.', 'keywords': 'riscv, JIT, kCFI', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 516fca5a7516cde7a9968f84179ed20ffb438885 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 516fca5a7516cde7a9968f84179ed20ffb438885 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1709767096 + Commit Message: + Merge branch 'libbpf-type-suffixes-and-autocreate-flag-for-struct_ops-maps' + +Eduard Zingerman says: + +==================== +libbpf: type suffixes and autocreate flag for struct_ops maps + +Tweak struct_ops related APIs to allow the following features: +- specify version suffixes for stuct_ops map types; +- share same BPF program between several map definitions with + different local BTF types + Parent Hashes: 0f79bb8987a5c483362dc12d58b221a1a1c45578 5208930a909ad618363471e2872d79abef103626 + Refs: assuming only maps with same + kernel BTF type would be selected for load; +- toggle autocreate flag for struct_ops maps; +- automatically toggle autoload for struct_ops programs referenced + from struct_ops maps + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance struct_ops maps in libbpf with type suffixes, autocreate flag, and autoload toggle features.', 'keywords': 'struct_ops, type suffixes, autocreate', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5208930a909ad618363471e2872d79abef103626 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5208930a909ad618363471e2872d79abef103626 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767096 + Commit Message: + selftests/bpf: Test cases for '?' in BTF names + +Two test cases to verify that '?' and other printable characters are +allowed in BTF DATASEC names: +- DATASEC with name "?.foo bar:buz" should be accepted; +- type with name "?foo" should be rejected. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-16-eddyz87@gmail.com + + Parent Hashes: bd70a8fb7ca4fcb078086f4d96b048aaf1aa4786 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Add test cases to verify BTF names with '?' and other characters in eBPF.", 'keywords': 'test cases,BTF names,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: bd70a8fb7ca4fcb078086f4d96b048aaf1aa4786 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bd70a8fb7ca4fcb078086f4d96b048aaf1aa4786 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767096 + Commit Message: + bpf: Allow all printable characters in BTF DATASEC names + +The intent is to allow libbpf to use SEC("?.struct_ops") to identify +struct_ops maps that are optional + Parent Hashes: 733e5e875444fc5afc9b72714f0ecaca629ccf8a + Refs: e.g. like in the following BPF code: + + SEC("?.struct_ops") + struct test_ops optional_map = { ... }; + +Which yields the following BTF: + + ... + [13] DATASEC '?.struct_ops' size=0 vlen=... + ... + +To load such BTF libbpf rewrites DATASEC name before load. +After this patch the rewrite won't be necessary. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-15-eddyz87@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows all printable characters in BTF DATASEC names for struct_ops maps.', 'keywords': 'BTF, struct_ops, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 733e5e875444fc5afc9b72714f0ecaca629ccf8a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 733e5e875444fc5afc9b72714f0ecaca629ccf8a + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767096 + Commit Message: + selftests/bpf: Test case for SEC("?.struct_ops") + +Check that "?.struct_ops" and "?.struct_ops.link" section names define +struct_ops maps with autocreate == false after open. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-14-eddyz87@gmail.com + + Parent Hashes: 6ebaa3fb88bbe4c33a0e01ce27007e1dd4fd133c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test case for struct_ops map sections with autocreate set to false.', 'keywords': 'selftests struct_ops autocreate', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6ebaa3fb88bbe4c33a0e01ce27007e1dd4fd133c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6ebaa3fb88bbe4c33a0e01ce27007e1dd4fd133c + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767096 + Commit Message: + libbpf: Rewrite btf datasec names starting from '?' + +Optional struct_ops maps are defined using question mark at the start +of the section name + Parent Hashes: 5ad0ecbe056a4ea5ffaa73e58503a2f87b119a59 + Refs: e.g.: + + SEC("?.struct_ops") + struct test_ops optional_map = { ... }; + +This commit teaches libbpf to detect if kernel allows '?' prefix +in datasec names + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "This commit updates libbpf to support datasec names starting with '?' for optional struct_ops maps.", 'keywords': 'libbpf, datasec, struct_ops', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 5ad0ecbe056a4ea5ffaa73e58503a2f87b119a59 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5ad0ecbe056a4ea5ffaa73e58503a2f87b119a59 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767096 + Commit Message: + libbpf: Struct_ops in SEC("?.struct_ops") / SEC("?.struct_ops.link") + +Allow using two new section names for struct_ops maps: +- SEC("?.struct_ops") +- SEC("?.struct_ops.link") + +To specify maps that have bpf_map->autocreate == false after open. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-12-eddyz87@gmail.com + + Parent Hashes: 240bf8a5162e8c43cf368909582a01082d494d79 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces new section names for struct_ops maps in libbpf to specify autocreate flag as false.', 'keywords': 'struct_ops,section names,libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 240bf8a5162e8c43cf368909582a01082d494d79 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 240bf8a5162e8c43cf368909582a01082d494d79 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + libbpf: Replace elf_state->st_ops_* fields with SEC_ST_OPS sec_type + +The next patch would add two new section names for struct_ops maps. +To make working with multiple struct_ops sections more convenient: +- remove fields like elf_state->st_ops_{shndx + Parent Hashes: 651d49f15b2a84b3bcfe950fa99c3672b9619dbd + Refs: link_shndx}; +- mark section descriptions hosting struct_ops as + elf_sec_desc->sec_type == SEC_ST_OPS; + +After these changes struct_ops sections could be processed uniformly +by iterating bpf_object->efile.secs entries. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-11-eddyz87@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit refactors libbpf to enhance handling of struct_ops sections by consolidating section descriptors.', 'keywords': 'libbpf, struct_ops, elf_state', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 651d49f15b2a84b3bcfe950fa99c3672b9619dbd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 651d49f15b2a84b3bcfe950fa99c3672b9619dbd + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + selftests/bpf: Verify struct_ops autoload/autocreate sync + +Check that autocreate flags of struct_ops map cause autoload of +struct_ops corresponding programs: +- when struct_ops program is referenced only from a map for which + autocreate is set to false + Parent Hashes: fe9d049c3da06373a1a35914b7f695509e4cb1fe + Refs: that program should not be loaded; +- when struct_ops program with autoload == false is set to be used + from a map with autocreate == true using shadow var + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhances selftests to verify struct_ops map autocreate and autoload synchronization behavior.', 'keywords': 'selftests,bpf,struct_ops', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fe9d049c3da06373a1a35914b7f695509e4cb1fe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fe9d049c3da06373a1a35914b7f695509e4cb1fe + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + libbpf: Sync progs autoload with maps autocreate for struct_ops maps + +Automatically select which struct_ops programs to load depending on +which struct_ops maps are selected for automatic creation. +E.g. for the BPF code below: + + SEC("struct_ops/test_1") int BPF_PROG(foo) { ... } + SEC("struct_ops/test_2") int BPF_PROG(bar) { ... } + + SEC(".struct_ops.link") + struct test_ops___v1 A = { + .foo = (void *)foo + }; + + SEC(".struct_ops.link") + struct test_ops___v2 B = { + .foo = (void *)foo + Parent Hashes: 1863acccdf936c6917398165ca97e252d02fa6dd + Refs: + .bar = (void *)bar + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Sync program autoload with automatic map creation for struct_ops maps in libbpf.', 'keywords': 'libbpf, struct_ops, autoload', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1863acccdf936c6917398165ca97e252d02fa6dd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1863acccdf936c6917398165ca97e252d02fa6dd + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + selftests/bpf: Test autocreate behavior for struct_ops maps + +Check that bpf_map__set_autocreate() can be used to disable automatic +creation for struct_ops maps. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-8-eddyz87@gmail.com + + Parent Hashes: c1b93c07b3ac3204c6a42a7f7b6217e36f44df4f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Test added for autocreate behavior of struct_ops maps in selftests/bpf.', 'keywords': 'selftests,bpf,struct_ops', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c1b93c07b3ac3204c6a42a7f7b6217e36f44df4f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c1b93c07b3ac3204c6a42a7f7b6217e36f44df4f + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + selftests/bpf: Bad_struct_ops test + +When loading struct_ops programs kernel requires BTF id of the +struct_ops type and member index for attachment point inside that +type. This makes impossible to use same BPF program in several +struct_ops maps that have different struct_ops type. +Check if libbpf rejects such BPF objects files. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-7-eddyz87@gmail.com + + Parent Hashes: c8617e8bcf8d1ef357fadf5c96bd86b9952fb93f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds a selftest in BPF to verify libbpf rejection of BPF objects with mismatched struct_ops types and indices.', 'keywords': 'selftests, struct_ops, libbpf', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c8617e8bcf8d1ef357fadf5c96bd86b9952fb93f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c8617e8bcf8d1ef357fadf5c96bd86b9952fb93f + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + selftests/bpf: Utility functions to capture libbpf log in test_progs + +Several test_progs tests already capture libbpf log in order to check +for some expected output + Parent Hashes: 5bab7a277ca8d4ef377a50a6678577b5bd7f74d8 + Refs: e.g bpf_tcp_ca.c + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add utility functions for capturing libbpf log in test_progs selftests.', 'keywords': 'utility functions, libbpf log, test_progs', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5bab7a277ca8d4ef377a50a6678577b5bd7f74d8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5bab7a277ca8d4ef377a50a6678577b5bd7f74d8 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + selftests/bpf: Test struct_ops map definition with type suffix + +Extend struct_ops_module test case to check if it is possible to use +'___' suffixes for struct_ops type specification. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: David Vernet +Link: https://lore.kernel.org/bpf/20240306104529.6453-5-eddyz87@gmail.com + + Parent Hashes: 8db052615a9780b45e26d6afabc7abefe1ba20ac + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Extend struct_ops_module test case to verify struct_ops type specification with '___' suffixes.", 'keywords': 'selftests,bpf,struct_ops', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8db052615a9780b45e26d6afabc7abefe1ba20ac +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8db052615a9780b45e26d6afabc7abefe1ba20ac + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + libbpf: Honor autocreate flag for struct_ops maps + +Skip load steps for struct_ops maps not marked for automatic creation. +This should allow to load bpf object in situations like below: + + SEC("struct_ops/foo") int BPF_PROG(foo) { ... } + SEC("struct_ops/bar") int BPF_PROG(bar) { ... } + + struct test_ops___v1 { + int (*foo)(void); + }; + + struct test_ops___v2 { + int (*foo)(void); + int (*does_not_exist)(void); + }; + + SEC(".struct_ops.link") + struct test_ops___v1 map_for_old = { + .test_1 = (void *)foo + }; + + SEC(".struct_ops.link") + struct test_ops___v2 map_for_new = { + .test_1 = (void *)foo + Parent Hashes: d9ab2f76ef5abb76190ffb42d83bdc6caede807e + Refs: + .does_not_exist = (void *)bar + }; + +Suppose program is loaded on old kernel that does not have definition +for 'does_not_exist' struct_ops member. After this commit it would be +possible to load such object file after the following tweaks: + + bpf_program__set_autoload(skel->progs.bar + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Skip loading steps for struct_ops maps not marked for automatic creation in libbpf.', 'keywords': 'libbpf,struct_ops,autocreate', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d9ab2f76ef5abb76190ffb42d83bdc6caede807e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d9ab2f76ef5abb76190ffb42d83bdc6caede807e + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + libbpf: Tie struct_ops programs to kernel BTF ids + Parent Hashes: a2a5172cf1eb39472bd2038079f65c6f676906a5 + Refs: not to local ids + +Enforce the following existing limitation on struct_ops programs based +on kernel BTF id instead of program-local BTF id: + + struct_ops BPF prog can be re-used between multiple .struct_ops & + .struct_ops.link as long as it's the same struct_ops struct + definition and the same function pointer field + +This allows reusing same BPF program for versioned struct_ops map +definitions + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ties struct_ops programs to kernel BTF ids for reuse across multiple struct_ops definitions.', 'keywords': 'struct_ops,kernel BTF,reuse', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a2a5172cf1eb39472bd2038079f65c6f676906a5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a2a5172cf1eb39472bd2038079f65c6f676906a5 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709767095 + Commit Message: + libbpf: Allow version suffixes (___smth) for struct_ops types + +E.g. allow the following struct_ops definitions: + + struct bpf_testmod_ops___v1 { int (*test)(void); }; + struct bpf_testmod_ops___v2 { int (*test)(void); }; + + SEC(".struct_ops.link") + struct bpf_testmod_ops___v1 a = { .test = ... } + SEC(".struct_ops.link") + struct bpf_testmod_ops___v2 b = { .test = ... } + +Where both bpf_testmod_ops__v1 and bpf_testmod_ops__v2 would be +resolved as 'struct bpf_testmod_ops' from kernel BTF. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: David Vernet +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-2-eddyz87@gmail.com + + Parent Hashes: 0f79bb8987a5c483362dc12d58b221a1a1c45578 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable version suffixes for struct_ops types in the libbpf library to support multiple versions.', 'keywords': 'libbpf,struct_ops,BTF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0f79bb8987a5c483362dc12d58b221a1a1c45578 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0f79bb8987a5c483362dc12d58b221a1a1c45578 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1709767094 + Commit Message: + Merge branch 'bpf-introduce-may_goto-and-cond_break' + +Alexei Starovoitov says: + +==================== +bpf: Introduce may_goto and cond_break + +From: Alexei Starovoitov + +v5 -> v6: +- Rename BPF_JMA to BPF_JCOND +- Addressed Andrii's review comments + +v4 -> v5: +- rewrote patch 1 to avoid fake may_goto_reg and use 'u32 may_goto_cnt' instead. + This way may_goto handling is similar to bpf_loop() processing. +- fixed bug in patch 2 that RANGE_WITHIN should not use + rold->type == NOT_INIT as a safe signal. +- patch 3 fixed negative offset computation in cond_break macro +- using bpf_arena and cond_break recompiled lib/glob.c as bpf prog + and it works! It will be added as a selftest to arena series. + +v3 -> v4: +- fix drained issue reported by John. + may_goto insn could be implemented with sticky state (once + reaches 0 it stays 0) + Parent Hashes: 9a9d1d36050e486822dc54990c896761b04e7446 0c8bbf990bddef1a4f32889b18a4a016d9bd2cfd + Refs: but the verifier shouldn't assume that. + It has to explore both branches. + Arguably drained iterator state shouldn't be there at all. + bpf_iter_css_next() is not sticky. Can be fixed + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit introduces may_goto and cond_break constructs in the eBPF verifier.', 'keywords': 'may_goto, cond_break, eBPF', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0c8bbf990bddef1a4f32889b18a4a016d9bd2cfd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0c8bbf990bddef1a4f32889b18a4a016d9bd2cfd + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709767090 + Commit Message: + selftests/bpf: Test may_goto + +Add tests for may_goto instruction via cond_break macro. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: John Fastabend +Tested-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240306031929.42666-5-alexei.starovoitov@gmail.com + + Parent Hashes: 06375801525717173aee790310b7d959bb77879b + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for the may_goto instruction using the cond_break macro in BPF.', 'keywords': 'selftests,BPF,may_goto', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 06375801525717173aee790310b7d959bb77879b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 06375801525717173aee790310b7d959bb77879b + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709767084 + Commit Message: + bpf: Add cond_break macro + +Use may_goto instruction to implement cond_break macro. +Ideally the macro should be written as: + asm volatile goto(".byte 0xe5; + .byte 0; + .short %l[l_break] ... + .long 0; +but LLVM doesn't recognize fixup of 2 byte PC relative yet. +Hence use + asm volatile goto(".byte 0xe5; + .byte 0; + .long %l[l_break] ... + .short 0; +that produces correct asm on little endian. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Acked-by: John Fastabend +Tested-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240306031929.42666-4-alexei.starovoitov@gmail.com + + Parent Hashes: 4f81c16f50baf6d5d8bfa6eef3250dcfa22cbc08 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add cond_break macro using may_goto instruction for better assembly compatibility with little endian systems.', 'keywords': 'cond_break, macro, may_goto', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4f81c16f50baf6d5d8bfa6eef3250dcfa22cbc08 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4f81c16f50baf6d5d8bfa6eef3250dcfa22cbc08 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709767080 + Commit Message: + bpf: Recognize that two registers are safe when their ranges match + +When open code iterators + Parent Hashes: 011832b97b311bb9e3c27945bc0d1089a14209c9 + Refs: bpf_loop or may_goto are used the following two +states are equivalent and safe to prune the search: + +cur state: fp-8_w=scalar(id=3 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit optimizes register safety recognition by matching their ranges for bpf open code iterators.', 'keywords': 'registers,safe,ranges', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 011832b97b311bb9e3c27945bc0d1089a14209c9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 011832b97b311bb9e3c27945bc0d1089a14209c9 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709767051 + Commit Message: + bpf: Introduce may_goto instruction + +Introduce may_goto instruction that from the verifier pov is similar to +open coded iterators bpf_for()/bpf_repeat() and bpf_loop() helper + Parent Hashes: 9a9d1d36050e486822dc54990c896761b04e7446 + Refs: but it +doesn't iterate any objects. +In assembly 'may_goto' is a nop most of the time until bpf runtime has to +terminate the program for whatever reason. In the current implementation +may_goto has a hidden counter + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce may_goto instruction that acts as a conditional program termination point in BPF verifier.', 'keywords': 'may_goto,instruction,verifier', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e6f798225a31485e47a6e4f6aa07ee9fdf80c2cb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e6f798225a31485e47a6e4f6aa07ee9fdf80c2cb + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709767042 + Commit Message: + mm: Introduce VM_SPARSE kind and vm_area_[un]map_pages(). + +vmap/vmalloc APIs are used to map a set of pages into contiguous kernel +virtual space. + +get_vm_area() with appropriate flag is used to request an area of kernel +address range. It's used for vmalloc + Parent Hashes: 3e49a866c9dcbd8173e4f3e491293619a9e81fa4 + Refs: vmap + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces VM_SPARSE kind and vm_area_[un]map_pages() functionality to handle kernel virtual space mapping.', 'keywords': 'VM_SPARSE, vmap, vmalloc', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 3e49a866c9dcbd8173e4f3e491293619a9e81fa4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3e49a866c9dcbd8173e4f3e491293619a9e81fa4 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709749144 + Commit Message: + mm: Enforce VM_IOREMAP flag and range in ioremap_page_range. + +There are various users of get_vm_area() + ioremap_page_range() APIs. +Enforce that get_vm_area() was requested as VM_IOREMAP type and range +passed to ioremap_page_range() matches created vm_area to avoid +accidentally ioremap-ing into wrong address range. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Reviewed-by: Christoph Hellwig +Link: https://lore.kernel.org/bpf/20240305030516.41519-2-alexei.starovoitov@gmail.com + + Parent Hashes: 8f50d5c423551bfa259af792647a2f4799780ac5 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enforce VM_IOREMAP flag and range in ioremap_page_range to prevent incorrect ioremap usage.', 'keywords': 'VM_IOREMAP,enforce,ioremap', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 2487007aa3b9fafbd2cb14068f49791ce1d7ede5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2487007aa3b9fafbd2cb14068f49791ce1d7ede5 + Author Name: Toke Høiland-Jørgensen + Author Email: toke@redhat.com + Commit Date: 1709686133 + Commit Message: + cpumap: Zero-initialise xdp_rxq_info struct before running XDP program + +When running an XDP program that is attached to a cpumap entry + Parent Hashes: 0bfc0336e1348883fdab4689f0c8c56458f36dd8 + Refs: we don't +initialise the xdp_rxq_info data structure being used in the xdp_buff +that backs the XDP program invocation. Tobias noticed that this leads to +random values being returned as the xdp_md->rx_queue_index value for XDP +programs running in a cpumap. + +This means we're basically returning the contents of the uninitialised +memory + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit zero-initializes the xdp_rxq_info structure to prevent random values in xdp_md->rx_queue_index for cpumap entries.', 'keywords': 'zero-initialize,xdp_rxq_info,cpumap', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 0bfc0336e1348883fdab4689f0c8c56458f36dd8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0bfc0336e1348883fdab4689f0c8c56458f36dd8 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1709684382 + Commit Message: + selftests/bpf: Fix up xdp bonding test wrt feature flags + +Adjust the XDP feature flags for the bond device when no bond slave +devices are attached. After 9b0ed890ac2a ("bonding: do not report +NETDEV_XDP_ACT_XSK_ZEROCOPY") + Parent Hashes: f267f262815033452195f46c43b572159262f533 + Refs: the empty bond device must report 0 +as flags instead of NETDEV_XDP_ACT_MASK. + + # ./vmtest.sh -- ./test_progs -t xdp_bond + [...] + [ 3.983311] bond1 (unregistering): (slave veth1_1): Releasing backup interface + [ 3.995434] bond1 (unregistering): Released all slaves + [ 4.022311] bond2: (slave veth2_1): Releasing backup interface + #507/1 xdp_bonding/xdp_bonding_attach:OK + #507/2 xdp_bonding/xdp_bonding_nested:OK + #507/3 xdp_bonding/xdp_bonding_features:OK + #507/4 xdp_bonding/xdp_bonding_roundrobin:OK + #507/5 xdp_bonding/xdp_bonding_activebackup:OK + #507/6 xdp_bonding/xdp_bonding_xor_layer2:OK + #507/7 xdp_bonding/xdp_bonding_xor_layer23:OK + #507/8 xdp_bonding/xdp_bonding_xor_layer34:OK + #507/9 xdp_bonding/xdp_bonding_redirect_multi:OK + #507 xdp_bonding:OK + Summary: 1/9 PASSED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes XDP feature flags for bond devices when no slave devices are attached in selftests.', 'keywords': 'XDP,bonding,feature', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 399eca1bd4fc14645dcdf19ee10adf5cde85aecf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 399eca1bd4fc14645dcdf19ee10adf5cde85aecf + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709684157 + Commit Message: + Merge branch 'check-bpf_func_state-callback_depth-when-pruning-states' + +Eduard Zingerman says: + +==================== +check bpf_func_state->callback_depth when pruning states + +This patch-set fixes bug in states pruning logic hit in mailing list +discussion [0]. The details of the fix are in patch #1. + +The main idea for the fix belongs to Yonghong Song + Parent Hashes: 685f7d531264599b3f167f1e94bbd22f120e5fab 5c2bc5e2f81d3344095ae241032dde20a4ea2b48 + Refs: +mine contribution is merely in review and test cases. + +There are some changes in verification performance: + +File Program Insns (DIFF) States (DIFF) +------------------------- ------------- --------------- -------------- +pyperf600_bpf_loop.bpf.o on_event +15 (+0.42%) +0 (+0.00%) +strobemeta_bpf_loop.bpf.o on_event +857 (+37.95%) +60 (+38.96%) +xdp_synproxy_kern.bpf.o syncookie_tc +2892 (+30.39%) +109 (+36.33%) +xdp_synproxy_kern.bpf.o syncookie_xdp +2892 (+30.01%) +109 (+36.09%) + +(when tested on a subset of selftests identified by + selftests/bpf/veristat.cfg and Cilium bpf object files from [4]) + +Changelog: +v2 [2] -> v3: +- fixes for verifier.c commit message as suggested by Yonghong; +- patch-set re-rerouted to 'bpf' tree as suggested in [2]; +- patch for test_tcp_custom_syncookie is sent separately to 'bpf-next' [3]. +- veristat results updated using 'bpf' tree as baseline and clang 16. + +v1 [1] -> v2: +- patch #2 commit message updated to better reflect verifier behavior + with regards to checkpoints tree (suggested by Yonghong); +- veristat results added (suggested by Andrii). + +[0] https://lore.kernel.org/bpf/9b251840-7cb8-4d17-bd23-1fc8071d8eef@linux.dev/ +[1] https://lore.kernel.org/bpf/20240212143832.28838-1-eddyz87@gmail.com/ +[2] https://lore.kernel.org/bpf/20240216150334.31937-1-eddyz87@gmail.com/ +[3] https://lore.kernel.org/bpf/20240222150300.14909-1-eddyz87@gmail.com/ +[4] https://github.com/anakryiko/cilium +==================== + +Link: https://lore.kernel.org/r/20240222154121.6991-1-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a bug in eBPF verifier state pruning logic related to callback depth.', 'keywords': 'bugfix, pruning, verifier', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5c2bc5e2f81d3344095ae241032dde20a4ea2b48 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5c2bc5e2f81d3344095ae241032dde20a4ea2b48 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709684156 + Commit Message: + selftests/bpf: test case for callback_depth states pruning logic + +The test case was minimized from mailing list discussion [0]. +It is equivalent to the following C program: + + struct iter_limit_bug_ctx { __u64 a; __u64 b; __u64 c; }; + + static __naked void iter_limit_bug_cb(void) + { + switch (bpf_get_prandom_u32()) { + case 1: ctx->a = 42; break; + case 2: ctx->b = 42; break; + default: ctx->c = 42; break; + } + } + + int iter_limit_bug(struct __sk_buff *skb) + { + struct iter_limit_bug_ctx ctx = { 7 + Parent Hashes: e9a8e5a587ca55fec6c58e4881742705d45bee54 + Refs: 7 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test case for callback_depth states pruning logic in BPF selftests.', 'keywords': 'test case,callback_depth,pruning', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e9a8e5a587ca55fec6c58e4881742705d45bee54 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e9a8e5a587ca55fec6c58e4881742705d45bee54 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1709684156 + Commit Message: + bpf: check bpf_func_state->callback_depth when pruning states + +When comparing current and cached states verifier should consider +bpf_func_state->callback_depth. Current state cannot be pruned against +cached state + Parent Hashes: 685f7d531264599b3f167f1e94bbd22f120e5fab + Refs: when current states has more iterations left compared to +cached state. Current state has more iterations left when it's +callback_depth is smaller. + +Below is an example illustrating this bug + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix the pruning logic in the eBPF verifier by considering callback_depth in function states.', 'keywords': 'bpf,func_state,callback_depth', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ef27f655b438bed4c83680e4f01e1cde2739854b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ef27f655b438bed4c83680e4f01e1cde2739854b + Author Name: Florian Kauer + Author Email: florian.kauer@linutronix.de + Commit Date: 1709661033 + Commit Message: + igc: avoid returning frame twice in XDP_REDIRECT + +When a frame can not be transmitted in XDP_REDIRECT +(e.g. due to a full queue) + Parent Hashes: 36c824ca3e4fa8d1224c2dcdeaca39d2ca86a42f + Refs: it is necessary to free +it by calling xdp_return_frame_rx_napi. + +However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix to prevent returning frame twice in XDP_REDIRECT when the transmission queue is full.', 'keywords': 'XDP_REDIRECT,frame,transmit', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 8f50d5c423551bfa259af792647a2f4799780ac5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8f50d5c423551bfa259af792647a2f4799780ac5 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1709590164 + Commit Message: + Merge branch 'Allow struct_ops maps with a large number of programs' + +Kui-Feng Lee says: + +==================== +The BPF struct_ops previously only allowed for one page to be used for +the trampolines of all links in a map. However + Parent Hashes: 01031fd473059bf69bb6edc6d51d4bd58ad92e50 93bc28d859e57f1a654d3b63600d14c85c5630a4 + Refs: we have recently run +out of space due to the large number of BPF program links. By +allocating additional pages when we exhaust an existing page + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows struct_ops maps to support a larger number of BPF program links by allocating additional pages for trampolines.', 'keywords': 'struct_ops maps, trampolines, BPF programs', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 93bc28d859e57f1a654d3b63600d14c85c5630a4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 93bc28d859e57f1a654d3b63600d14c85c5630a4 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1709590164 + Commit Message: + selftests/bpf: Test struct_ops maps with a large number of struct_ops program. + +Create and load a struct_ops map with a large number of struct_ops +programs to generate trampolines taking a size over multiple pages. The +map includes 40 programs. Their trampolines takes 6.6k+ + Parent Hashes: 187e2af05abe6bf80581490239c449456627d17a + Refs: more than 1.5 +pages + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit tests struct_ops maps with many struct_ops programs generating large trampolines spanning multiple pages in selftests.', 'keywords': 'struct_ops, trampolines, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 187e2af05abe6bf80581490239c449456627d17a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 187e2af05abe6bf80581490239c449456627d17a + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1709590160 + Commit Message: + bpf: struct_ops supports more than one page for trampolines. + +The BPF struct_ops previously only allowed one page of trampolines. +Each function pointer of a struct_ops is implemented by a struct_ops +bpf program. Each struct_ops bpf program requires a trampoline. +The following selftest patch shows each page can hold a little more +than 20 trampolines. + +While one page is more than enough for the tcp-cc usecase + Parent Hashes: 73e4f9e615d7b99f39663d4722dc73e8fa5db5f9 + Refs: +the sched_ext use case shows that one page is not always enough and hits +the one page limit. This patch overcomes the one page limit by allocating +another page when needed and it is limited to a total of +MAX_IMAGE_PAGES (8) pages which is more than enough for +reasonable usages. + +The variable st_map->image has been changed to st_map->image_pages + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Increase the support for multiple pages in struct_ops trampolines to accommodate higher requirements.', 'keywords': 'struct_ops,trampolines,pages', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 73e4f9e615d7b99f39663d4722dc73e8fa5db5f9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 73e4f9e615d7b99f39663d4722dc73e8fa5db5f9 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1709575437 + Commit Message: + bpf + Parent Hashes: 01031fd473059bf69bb6edc6d51d4bd58ad92e50 + Refs: net: validate struct_ops when updating value. + +Perform all validations when updating values of struct_ops maps. Doing +validation in st_ops->reg() and st_ops->update() is not necessary anymore. +However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Perform validation of struct_ops maps on value updates instead of in reg and update functions.', 'keywords': 'validate, struct_ops, update', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 01031fd473059bf69bb6edc6d51d4bd58ad92e50 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 01031fd473059bf69bb6edc6d51d4bd58ad92e50 + Author Name: Song Yoong Siang + Author Email: yoong.siang.song@intel.com + Commit Date: 1709560919 + Commit Message: + selftests/bpf: xdp_hw_metadata reduce sleep interval + +In current ping-pong design + Parent Hashes: 8f79870ec8a9409983ad5981e1b7d599cbf047bd + Refs: xdp_hw_metadata will wait until the packet +transmission completely done + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reduce sleep interval in xdp_hw_metadata test to improve efficiency.', 'keywords': 'xdp_hw_metadata,sleep,interval', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 8f79870ec8a9409983ad5981e1b7d599cbf047bd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8f79870ec8a9409983ad5981e1b7d599cbf047bd + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1709559624 + Commit Message: + selftests/bpf: Extend uprobe/uretprobe triggering benchmarks + +Settle on three "flavors" of uprobe/uretprobe + Parent Hashes: 25703adf45f8430ec59effa20920c80139d13cdc + Refs: installed on different +kinds of instruction: nop + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extend uprobe/uretprobe benchmarks with different instruction types in selftests for BPF.', 'keywords': 'uprobe, uretprobe, benchmarks', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 25703adf45f8430ec59effa20920c80139d13cdc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 25703adf45f8430ec59effa20920c80139d13cdc + Author Name: Chen Shen + Author Email: peterchenshen@gmail.com + Commit Date: 1709559231 + Commit Message: + libbpf: Correct debug message in btf__load_vmlinux_btf + +In the function btf__load_vmlinux_btf + Parent Hashes: 0ef05e258b5e15c254534d9dd382ad4c3173dce0 + Refs: the debug message incorrectly +refers to 'path' instead of 'sysfs_btf_path'. + +Signed-off-by: Chen Shen +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240302062218.3587-1-peterchenshen@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Corrected debug message in btf__load_vmlinux_btf function to use correct path reference.', 'keywords': 'libbpf,debug path,correction', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0ef05e258b5e15c254534d9dd382ad4c3173dce0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0ef05e258b5e15c254534d9dd382ad4c3173dce0 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1709559066 + Commit Message: + bpf + Parent Hashes: 4e73e1bc1abf3181d57d6b8f1ab2a9f62a6a1a52 + Refs: docs: Rename legacy conformance group to packet + +There could be other legacy conformance groups in the future + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Renames legacy conformance group to packet in documentation.', 'keywords': 'rename, conformance, packet', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 4e73e1bc1abf3181d57d6b8f1ab2a9f62a6a1a52 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4e73e1bc1abf3181d57d6b8f1ab2a9f62a6a1a52 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1709444414 + Commit Message: + bpf + Parent Hashes: 4b2765ae410abf01154cf97876384d8a58c43953 + Refs: docs: Use IETF format for field definitions in instruction-set.rst + +In preparation for publication as an IETF RFC + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Updated instruction-set documentation to use IETF format for field definitions.', 'keywords': 'documentation,IETF,RFC', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 4b2765ae410abf01154cf97876384d8a58c43953 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4b2765ae410abf01154cf97876384d8a58c43953 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1709441459 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-02-29 + +We've added 119 non-merge commits during the last 32 day(s) which contain +a total of 150 files changed + Parent Hashes: e960825709330cb199d209740326cec37e8c419d 0270d69121ba7fbc449a386f989b9b7b5eaebde3 + Refs: 3589 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge various updates from the bpf-next branch affecting multiple files in the Linux kernel repository.', 'keywords': 'merge, bpf-next, updates', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dd267d056fed323f1684fa52d2a864fc93ca3be0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dd267d056fed323f1684fa52d2a864fc93ca3be0 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1709258893 + Commit Message: + perf vendor events intel: Add umasks/occ_sel to PCU events. + +UMasks were being dropped leading to all PCU +UNC_P_POWER_STATE_OCCUPANCY events having the same encoding. Don't +drop the umask trying to be consistent with other sources of events +like libpfm4 [1]. Older models need to use occ_sel rather than umask + Parent Hashes: ec42d3d56819688537ec7ee37ce97f695fb8e6d7 + Refs: +correct these values too. This applies the change from [2]. + +[1] https://sourceforge.net/p/perfmon2/libpfm4/ci/master/tree/lib/events/intel_skx_unc_pcu_events.h#l30 +[2] https://github.com/captain5050/perfmon/commit/cbd4aee81023e5bfa09677b1ce170ff69e9c423d + +Signed-off-by: Ian Rogers +Reviewed-by: Kan Liang +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240228170529.4035675-1-irogers@google.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix PCU event encoding by adding umasks/occ_sel for better consistency in perf vendor events on Intel.', 'keywords': 'PCU,umasks,events', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 0270d69121ba7fbc449a386f989b9b7b5eaebde3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0270d69121ba7fbc449a386f989b9b7b5eaebde3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1709245447 + Commit Message: + Merge branch 'create-shadow-types-for-struct_ops-maps-in-skeletons' + +Kui-Feng Lee says: + +==================== +Create shadow types for struct_ops maps in skeletons + +This patchset allows skeleton users to change the values of the fields +in struct_ops maps at runtime. It will create a shadow type pointer in +a skeleton for each struct_ops map + Parent Hashes: 896880ff30866f386ebed14ab81ce1ad3710cfc4 0623e73317940d052216fb6eef4efd55a0a7f602 + Refs: allowing users to access the +values of fields through these pointers. For instance + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit introduces shadow types for struct_ops maps to allow runtime modifications in skeletons.', 'keywords': 'shadow types, struct_ops, skeletons', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0623e73317940d052216fb6eef4efd55a0a7f602 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0623e73317940d052216fb6eef4efd55a0a7f602 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1709245433 + Commit Message: + selftests/bpf: Test if shadow types work correctly. + +Change the values of fields + Parent Hashes: f2e81192e07e87897ff1296c96775eceea8f582a + Refs: including scalar types and function pointers + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds selftests for verifying the correct functionality of shadow types in BPF programs.', 'keywords': 'selftests, shadow types, BPF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f2e81192e07e87897ff1296c96775eceea8f582a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f2e81192e07e87897ff1296c96775eceea8f582a + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1709245433 + Commit Message: + bpftool: Add an example for struct_ops map and shadow type. + +The example in bpftool-gen.8 explains how to use the pointer of the shadow +type to change the value of a field of a struct_ops map. + +Signed-off-by: Kui-Feng Lee +Signed-off-by: Andrii Nakryiko +Reviewed-by: Quentin Monnet +Link: https://lore.kernel.org/bpf/20240229064523.2091270-5-thinker.li@gmail.com + + Parent Hashes: a7b0fa352eafef95bd0d736ca94965d3f884ad18 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds an example in bpftool-gen for using the shadow type in struct_ops maps.', 'keywords': 'bpftool, struct_ops, shadow type', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a7b0fa352eafef95bd0d736ca94965d3f884ad18 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a7b0fa352eafef95bd0d736ca94965d3f884ad18 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1709245433 + Commit Message: + bpftool: Generated shadow variables for struct_ops maps. + +Declares and defines a pointer of the shadow type for each struct_ops map. + +The code generator will create an anonymous struct type as the shadow type +for each struct_ops map. The shadow type is translated from the original +struct type of the map. The user of the skeleton use pointers of them to +access the values of struct_ops maps. + +However + Parent Hashes: 69e4a9d2b3f5adf5af4feeab0a9f505da971265a + Refs: shadow types only supports certain types of fields + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduced shadow variable generation for struct_ops maps in bpftool.', 'keywords': 'shadow, struct_ops, bpftool', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 69e4a9d2b3f5adf5af4feeab0a9f505da971265a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 69e4a9d2b3f5adf5af4feeab0a9f505da971265a + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1709245432 + Commit Message: + libbpf: Convert st_ops->data to shadow type. + +Convert st_ops->data to the shadow type of the struct_ops map. The shadow +type of a struct_ops type is a variant of the original struct type +providing a way to access/change the values in the maps of the struct_ops +type. + +bpf_map__initial_value() will return st_ops->data for struct_ops types. The +skeleton is going to use it as the pointer to the shadow type of the +original struct type. + +One of the main differences between the original struct type and the shadow +type is that all function pointers of the shadow type are converted to +pointers of struct bpf_program. Users can replace these bpf_program +pointers with other BPF programs. The st_ops->progs[] will be updated +before updating the value of a map to reflect the changes made by users. + +Signed-off-by: Kui-Feng Lee +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240229064523.2091270-3-thinker.li@gmail.com + + Parent Hashes: 3644d285462a60c80ac225d508fcfe705640d2b4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Convert struct_ops data to a shadow type allowing modified program pointers in libbpf.', 'keywords': 'libbpf,shadow,struct_ops', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3644d285462a60c80ac225d508fcfe705640d2b4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3644d285462a60c80ac225d508fcfe705640d2b4 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1709245432 + Commit Message: + libbpf: Set btf_value_type_id of struct bpf_map for struct_ops. + +For a struct_ops map + Parent Hashes: 896880ff30866f386ebed14ab81ce1ad3710cfc4 + Refs: btf_value_type_id is the type ID of it's struct +type. This value is required by bpftool to generate skeleton including +pointers of shadow types. The code generator gets the type ID from +bpf_map__btf_value_type_id() in order to get the type information of the +struct type of a map. + +Signed-off-by: Kui-Feng Lee +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240229064523.2091270-2-thinker.li@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Set btf_value_type_id for struct_ops in bpf_map to enable bpftool skeleton generation.', 'keywords': 'libbpf,bpf_map,btf_value_type_id', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b44d66536859393772c67cb1da65345127f692e0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b44d66536859393772c67cb1da65345127f692e0 + Author Name: Namhyung Kim + Author Email: namhyung@kernel.org + Commit Date: 1709243636 + Commit Message: + perf lock contention: Account contending locks too + +Currently it accounts the contention using delta between timestamps in +lock:contention_begin and lock:contention_end tracepoints. But it means +the lock should see the both events during the monitoring period. + +Actually there are 4 cases that happen with the monitoring: + + monitoring period + / \ + | | + 1: B------+-----------------------+--------E + 2: B----+-------------E | + 3: | B-----------+----E + 4: | B-------------E | + | | + t0 t1 + +where B and E mean contention BEGIN and END + Parent Hashes: 97b6b4ac1c5dd42a473a4f8e775d97476c5da038 + Refs: respectively. So it only +accounts the case 4 for now. It seems there's no way to handle the case +1. The case 2 might be handled if it saved the timestamp (t0) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance lock contention accounting by handling additional cases in the monitoring period.', 'keywords': 'lock,contention,accounting', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 896880ff30866f386ebed14ab81ce1ad3710cfc4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 896880ff30866f386ebed14ab81ce1ad3710cfc4 + Author Name: Kees Cook + Author Email: keescook@chromium.org + Commit Date: 1709243563 + Commit Message: + bpf: Replace bpf_lpm_trie_key 0-length array with flexible array + +Replace deprecated 0-length array in struct bpf_lpm_trie_key with +flexible array. Found with GCC 13: + +../kernel/bpf/lpm_trie.c:207:51: warning: array subscript i is outside array bounds of 'const __u8[0]' {aka 'const unsigned char[]'} [-Warray-bounds=] + 207 | *(__be16 *)&key->data[i]); + | ^~~~~~~~~~~~~ +../include/uapi/linux/swab.h:102:54: note: in definition of macro '__swab16' + 102 | #define __swab16(x) (__u16)__builtin_bswap16((__u16)(x)) + | ^ +../include/linux/byteorder/generic.h:97:21: note: in expansion of macro '__be16_to_cpu' + 97 | #define be16_to_cpu __be16_to_cpu + | ^~~~~~~~~~~~~ +../kernel/bpf/lpm_trie.c:206:28: note: in expansion of macro 'be16_to_cpu' + 206 | u16 diff = be16_to_cpu(*(__be16 *)&node->data[i] +^ + | ^~~~~~~~~~~ +In file included from ../include/linux/bpf.h:7: +../include/uapi/linux/bpf.h:82:17: note: while referencing 'data' + 82 | __u8 data[0]; /* Arbitrary size */ + | ^~~~ + +And found at run-time under CONFIG_FORTIFY_SOURCE: + + UBSAN: array-index-out-of-bounds in kernel/bpf/lpm_trie.c:218:49 + index 0 is out of range for type '__u8 [*]' + +Changing struct bpf_lpm_trie_key is difficult since has been used by +userspace. For example + Parent Hashes: b9a62998482fa1488123f690bcacc26fd2351a18 + Refs: in Cilium: + + struct egress_gw_policy_key { + struct bpf_lpm_trie_key lpm_key; + __u32 saddr; + __u32 daddr; + }; + +While direct references to the "data" member haven't been found + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaced deprecated 0-length array with a flexible array in bpf_lpm_trie_key to address GCC warnings and runtime issues.', 'keywords': 'flexible array, 0-length array, bpf_lpm_trie_key', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8f5afe41148ce6a719864e23c2bf776c88e9212f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8f5afe41148ce6a719864e23c2bf776c88e9212f + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1709226439 + Commit Message: + Merge branch 'tls-a-few-more-fixes-for-async-decrypt' + +Sabrina Dubroca says: + +==================== +tls: a few more fixes for async decrypt + +The previous patchset [1] took care of "full async". This adds a few +fixes for cases where only part of the crypto operations go the async +route + Parent Hashes: 616d82c3cfa2a2146dd7e3ae47bda7e877ee549e 13114dc5543069f7b97991e3b79937b6da05f5b0 + Refs: found by extending my previous debug patch [2] to do N +synchronous operations followed by M asynchronous ops (with N and M +configurable). + +[1] https://patchwork.kernel.org/project/netdevbpf/list/?series=823784&state=* +[2] https://lore.kernel.org/all/9d664093b1bf7f47497b2c40b3a085b45f3274a2.1694021240.git.sd@queasysnail.net/ +==================== + +Link: https://lore.kernel.org/r/cover.1709132643.git.sd@queasysnail.net +Signed-off-by: Jakub Kicinski + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit merges several bug fixes for TLS asynchronous decryption pathways.', 'keywords': 'TLS, async, decrypt', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 616d82c3cfa2a2146dd7e3ae47bda7e877ee549e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 616d82c3cfa2a2146dd7e3ae47bda7e877ee549e + Author Name: Alexander Ofitserov + Author Email: oficerovas@altlinux.org + Commit Date: 1709212458 + Commit Message: + gtp: fix use-after-free and null-ptr-deref in gtp_newlink() + +The gtp_link_ops operations structure for the subsystem must be +registered after registering the gtp_net_ops pernet operations structure. + +Syzkaller hit 'general protection fault in gtp_genl_dump_pdp' bug: + +[ 1010.702740] gtp: GTP module unloaded +[ 1010.715877] general protection fault + Parent Hashes: b611b776a9c89a86e57ea6dbf8adfc99c6e8a62e + Refs: probably for non-canonical address 0xdffffc0000000001: 0000 [#1] SMP KASAN NOPTI +[ 1010.715888] KASAN: null-ptr-deref in range [0x0000000000000008-0x000000000000000f] +[ 1010.715895] CPU: 1 PID: 128616 Comm: a.out Not tainted 6.8.0-rc6-std-def-alt1 #1 +[ 1010.715899] Hardware name: QEMU Standard PC (Q35 + ICH9 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix use-after-free and null-pointer dereference in gtp_newlink function registration sequence.', 'keywords': 'gtp, use-after-free, null-ptr-deref', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 7e0f122c65912740327e4c54472acaa5f85868cb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7e0f122c65912740327e4c54472acaa5f85868cb + Author Name: Ignat Korchagin + Author Email: ignat@cloudflare.com + Commit Date: 1709160775 + Commit Message: + netfilter: nf_tables: allow NFPROTO_INET in nft_(match/target)_validate() + +Commit d0009effa886 ("netfilter: nf_tables: validate NFPROTO_* family") added +some validation of NFPROTO_* families in the nft_compat module + Parent Hashes: 359e54a93ab43d32ee1bff3c2f9f10cb9f6b6e79 + Refs: but it broke +the ability to use legacy iptables modules in dual-stack nftables. + +While with legacy iptables one had to independently manage IPv4 and IPv6 +tables + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix allows NFPROTO_INET use in nft_(match/target)_validate to support dual-stack nftables.', 'keywords': 'NFPROTO_INET, dual-stack, nftables', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: b9a62998482fa1488123f690bcacc26fd2351a18 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b9a62998482fa1488123f690bcacc26fd2351a18 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709156688 + Commit Message: + Merge branch 'bpf-arm64-use-bpf-prog-pack-allocator-in-bpf-jit' + +Puranjay Mohan says: + +==================== +bpf + Parent Hashes: e59997d9052599feb17419289f2a57ed300e1dfa 1dad391daef129e01e28206b8d586608ff026548 + Refs: arm64: use BPF prog pack allocator in BPF JIT + +Changes in V8 => V9: +V8: https://lore.kernel.org/bpf/20240221145106.105995-1-puranjay12@gmail.com/ +1. Rebased on bpf-next/master +2. Added Acked-by: Catalin Marinas + +Changes in V7 => V8: +V7: https://lore.kernel.org/bpf/20240125133159.85086-1-puranjay12@gmail.com/ +1. Rebase on bpf-next/master +2. Fix __text_poke() by removing usage of 'ret' that was never set. + +Changes in V6 => V7: +V6: https://lore.kernel.org/all/20240124164917.119997-1-puranjay12@gmail.com/ +1. Rebase on bpf-next/master. + +Changes in V5 => V6: +V5: https://lore.kernel.org/all/20230908144320.2474-1-puranjay12@gmail.com/ +1. Implement a text poke api to reduce code repeatition. +2. Use flush_icache_range() in place of caches_clean_inval_pou() in the + functions that modify code. +3. Optimize the bpf_jit_free() by not copying the all instructions on + the rw image to the ro_image + +Changes in V4 => v5: +1. Remove the patch for making prog pack allocator portable as it will come + through the RISCV tree[1]. + +2. Add a new function aarch64_insn_set() to be used in + bpf_arch_text_invalidate() for putting illegal instructions after a + program is removed. The earlier implementation of bpf_arch_text_invalidate() + was calling aarch64_insn_patch_text_nosync() in a loop and making it slow + because each call invalidated the cache. + + Here is test_tag now: + [root@ip-172-31-6-176 bpf]# time ./test_tag + test_tag: OK (40945 tests) + + real 0m19.695s + user 0m1.514s + sys 0m17.841s + + test_tag without these patches: + [root@ip-172-31-6-176 bpf]# time ./test_tag + test_tag: OK (40945 tests) + + real 0m21.487s + user 0m1.647s + sys 0m19.106s + + test_tag in the previous version was really slow > 2 minutes. see [2] + +3. Add cache invalidation in aarch64_insn_copy() so other users can call the + function without worrying about the cache. Currently only bpf_arch_text_copy() + is using it + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit integrates BPF prog pack allocator into BPF JIT for arm64 to improve performance.', 'keywords': 'BPF JIT, allocator, arm64', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1dad391daef129e01e28206b8d586608ff026548 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1dad391daef129e01e28206b8d586608ff026548 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1709156687 + Commit Message: + bpf + Parent Hashes: 451c3cab9a65e656c3b3d106831fc02d56b8c34a + Refs: arm64: use bpf_prog_pack for memory management + +Use bpf_jit_binary_pack_alloc for memory management of JIT binaries in +ARM64 BPF JIT. The bpf_jit_binary_pack_alloc creates a pair of RW and RX +buffers. The JIT writes the program into the RW buffer. When the JIT is +done + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces bpf_prog_pack for efficient memory management of JIT binaries in ARM64 BPF JIT.', 'keywords': 'bpf_prog_pack,JIT,ARM64', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e59997d9052599feb17419289f2a57ed300e1dfa +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e59997d9052599feb17419289f2a57ed300e1dfa + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1709070858 + Commit Message: + Merge branch 'bpf-arm64-support-exceptions' + +Puranjay Mohan says: + +==================== +bpf + Parent Hashes: 2ab256e93249f5ac1da665861aa0f03fb4208d9c 22fc0e80aeb5c0c1377e6c02d7248f8fbf5df7fc + Refs: arm64: Support Exceptions + +Changes in V2->V3: +V2: https://lore.kernel.org/all/20230917000045.56377-1-puranjay12@gmail.com/ +- Use unwinder from stacktrace.c rather than open coding the unwind logic. +- Fix a bug in the prologue related to BPF_FP (Xu Kuohai) + +Changes in V1->V2: +V1: https://lore.kernel.org/all/20230912233942.6734-1-puranjay12@gmail.com/ +- Remove exceptions from DENYLIST.aarch64 as they are supported now. + +The base support for exceptions was merged with [1] and it was enabled for +x86-64. + +This patch set enables the support on ARM64 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable exception support for eBPF on ARM64 architecture.', 'keywords': 'ARM64, exceptions, support', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 22fc0e80aeb5c0c1377e6c02d7248f8fbf5df7fc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 22fc0e80aeb5c0c1377e6c02d7248f8fbf5df7fc + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1709070857 + Commit Message: + bpf + Parent Hashes: e74cb1b422131615a0fe3bedd4ab2e38b7442d10 + Refs: arm64: support exceptions + +The prologue generation code has been modified to make the callback +program use the stack of the program marked as exception boundary where +callee-saved registers are already pushed. + +As the bpf_throw function never returns + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Modified prologue generation code to use stack of exception boundary programs for callbacks.', 'keywords': 'prologue,stack,exception', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e74cb1b422131615a0fe3bedd4ab2e38b7442d10 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e74cb1b422131615a0fe3bedd4ab2e38b7442d10 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1709070857 + Commit Message: + arm64: stacktrace: Implement arch_bpf_stack_walk() for the BPF JIT + +This will be used by bpf_throw() to unwind till the program marked as +exception boundary and run the callback with the stack of the main +program. + +This is required for supporting BPF exceptions on ARM64. + +Signed-off-by: Puranjay Mohan +Acked-by: Catalin Marinas +Link: https://lore.kernel.org/r/20240201125225.72796-2-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 2ab256e93249f5ac1da665861aa0f03fb4208d9c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement arch_bpf_stack_walk for ARM64 BPF JIT to support BPF exceptions.', 'keywords': 'ARM64,BPF JIT,stacktrace', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 529d5818a3bb0272ced031e022e4b41d6410a4da +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 529d5818a3bb0272ced031e022e4b41d6410a4da + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@kernel.org + Commit Date: 1708964168 + Commit Message: + perf bpf: Check that the minimal vmlinux.h installed is the latest one + +When building BPF skels perf will + Parent Hashes: c2bd08ba20a57e0ed55777a9d1724647a0f53e88 + Refs: by default + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Ensure the latest minimal vmlinux.h is checked when building BPF skeletons in perf.', 'keywords': 'perf,vmlinux,BPF', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2ab256e93249f5ac1da665861aa0f03fb4208d9c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2ab256e93249f5ac1da665861aa0f03fb4208d9c + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1708652933 + Commit Message: + bpf: add is_async_callback_calling_insn() helper + +Currently we have a special case for BPF_FUNC_timer_set_callback + Parent Hashes: dfe6625df48ec54c6dc9b86d361f26962d09de88 + Refs: +let's introduce a helper we can extend for the kfunc that will come in +a later patch + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240221-hid-bpf-sleepable-v3-3-1fb378ca6301@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add is_async_callback_calling_insn() helper to extend functionality for future kfuncs.', 'keywords': 'helper, kfunc, async', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dfe6625df48ec54c6dc9b86d361f26962d09de88 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dfe6625df48ec54c6dc9b86d361f26962d09de88 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1708652835 + Commit Message: + bpf: introduce in_sleepable() helper + +No code change + Parent Hashes: 55bad79e33aeb670317290158a4b2ff71cdc8380 + Refs: but it'll allow to have only one place to change +everything when we add in_sleepable in cur_state. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240221-hid-bpf-sleepable-v3-2-1fb378ca6301@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces the in_sleepable() helper function for eBPF.', 'keywords': 'in_sleepable, helper, eBPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 55bad79e33aeb670317290158a4b2ff71cdc8380 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 55bad79e33aeb670317290158a4b2ff71cdc8380 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1708652543 + Commit Message: + bpf: allow more maps in sleepable bpf programs + +These 2 maps types are required for HID-BPF when a user wants to do +IO with a device from a sleepable tracing point. + +Allowing BPF_MAP_TYPE_QUEUE (and therefore BPF_MAP_TYPE_STACK) allows +for a BPF program to prepare from an IRQ the list of HID commands to send +back to the device and then these commands can be retrieved from the +sleepable trace point. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240221-hid-bpf-sleepable-v3-1-1fb378ca6301@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 63c7049ef9d642ab60bb1eccf75b29dc40277664 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable additional map types in sleepable BPF programs for HID interaction.', 'keywords': 'sleepable,HID,MAP_TYPE_QUEUE', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tracepoints like programs', 'HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 63c7049ef9d642ab60bb1eccf75b29dc40277664 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 63c7049ef9d642ab60bb1eccf75b29dc40277664 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1708633602 + Commit Message: + Merge branch 'Check cfi_stubs before registering a struct_ops type.' + +Kui-Feng Lee says: + +==================== +Recently + Parent Hashes: 58fd62e0aa50fdd20bc41a01e787001f3af8a925 e9bbda13a7b876451285ab15fb600b809e5e2290 + Refs: st_ops->cfi_stubs was introduced. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit merges changes to check cfi_stubs before registering a struct_ops type.', 'keywords': 'cfi_stubs, struct_ops, merge', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e9bbda13a7b876451285ab15fb600b809e5e2290 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e9bbda13a7b876451285ab15fb600b809e5e2290 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1708633601 + Commit Message: + selftests/bpf: Test case for lacking CFI stub functions. + +Ensure struct_ops rejects the registration of struct_ops types without +proper CFI stub functions. + +bpf_test_no_cfi.ko is a module that attempts to register a struct_ops type +called "bpf_test_no_cfi_ops" with cfi_stubs of NULL and non-NULL value. +The NULL one should fail + Parent Hashes: 3e0008336ae3153fb89b1a15bb877ddd38680fe6 + Refs: and the non-NULL one should succeed. The module +can only be loaded successfully if these registrations yield the expected +results. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240222021105.1180475-3-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test case for struct_ops registration with CFI stub function validation in selftests/bpf.', 'keywords': 'test case, struct_ops, CFI', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3e0008336ae3153fb89b1a15bb877ddd38680fe6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3e0008336ae3153fb89b1a15bb877ddd38680fe6 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1708633600 + Commit Message: + bpf: Check cfi_stubs before registering a struct_ops type. + +Recently + Parent Hashes: 58fd62e0aa50fdd20bc41a01e787001f3af8a925 + Refs: st_ops->cfi_stubs was introduced. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ensures cfi_stubs are checked before registering a struct_ops type in the BPF subsystem.', 'keywords': 'cfi_stubs, struct_ops, register', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0827a1fb143fae588cb6f5b9a97c405d6c2ddec9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0827a1fb143fae588cb6f5b9a97c405d6c2ddec9 + Author Name: Chengming Zhou + Author Email: zhouchengming@bytedance.com + Commit Date: 1708626294 + Commit Message: + mm/zswap: invalidate zswap entry when swap entry free + +During testing I found there are some times the zswap_writeback_entry() +return -ENOMEM + Parent Hashes: f9c0f1c32cb568e16ef0676d8e7827a3ad443742 + Refs: which is not we expected: + +bpftrace -e 'kr:zswap_writeback_entry {@[(int32)retval]=count()}' +@[-12]: 1563 +@[0]: 277221 + +The reason is that __read_swap_cache_async() return NULL because +swapcache_prepare() failed. The reason is that we won't invalidate zswap +entry when swap entry freed to the per-cpu pool + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes an issue where zswap entries are not invalidated when swap entries are freed.', 'keywords': 'zswap, invalidate, swap', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: f9c0f1c32cb568e16ef0676d8e7827a3ad443742 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f9c0f1c32cb568e16ef0676d8e7827a3ad443742 + Author Name: Chengming Zhou + Author Email: zhouchengming@bytedance.com + Commit Date: 1708626294 + Commit Message: + mm/zswap: add more comments in shrink_memcg_cb() + +Patch series "mm/zswap: optimize zswap lru list" + Parent Hashes: e374ae2be2f7cb4aad46e17e3fa5da7bbb0d2a09 + Refs: v2. + +This series is motivated when observe the zswap lru list shrinking + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added comments in shrink_memcg_cb() function related to zswap lru list.', 'keywords': 'comments, zswap, lru', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 58fd62e0aa50fdd20bc41a01e787001f3af8a925 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 58fd62e0aa50fdd20bc41a01e787001f3af8a925 + Author Name: Martin Kelly + Author Email: martin.kelly@crowdstrike.com + Commit Date: 1708626278 + Commit Message: + bpf: Clarify batch lookup/lookup_and_delete semantics + +The batch lookup and lookup_and_delete APIs have two parameters + Parent Hashes: 89ee838130f470afcd02b30ca868f236a3f3b1d2 + Refs: +in_batch and out_batch + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit clarifies the semantics of batch lookup and lookup_and_delete APIs in eBPF.', 'keywords': 'batch,lookup,APIs', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6714ebb922ab15a209dfc3c1ed29d4bb0abc9f02 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6714ebb922ab15a209dfc3c1ed29d4bb0abc9f02 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1708624678 + Commit Message: + Merge tag 'net-6.8.0-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + "Including fixes from bpf and netfilter. + + Current release - regressions: + + - af_unix: fix another unix GC hangup + + Previous releases - regressions: + + - core: fix a possible AF_UNIX deadlock + + - bpf: fix NULL pointer dereference in sk_psock_verdict_data_ready() + + - netfilter: nft_flow_offload: release dst in case direct xmit path + is used + + - bridge: switchdev: ensure MDB events are delivered exactly once + + - l2tp: pass correct message length to ip6_append_data + + - dccp/tcp: unhash sk from ehash for tb2 alloc failure after + check_estalblished() + + - tls: fixes for record type handling with PEEK + + - devlink: fix possible use-after-free and memory leaks in + devlink_init() + + Previous releases - always broken: + + - bpf: fix an oops when attempting to read the vsyscall page through + bpf_probe_read_kernel + + - sched: act_mirred: use the backlog for mirred ingress + + - netfilter: nft_flow_offload: fix dst refcount underflow + + - ipv6: sr: fix possible use-after-free and null-ptr-deref + + - mptcp: fix several data races + + - phonet: take correct lock to peek at the RX queue + + Misc: + + - handful of fixes and reliability improvements for selftests" + +* tag 'net-6.8.0-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (72 commits) + l2tp: pass correct message length to ip6_append_data + net: phy: realtek: Fix rtl8211f_config_init() for RTL8211F(D)(I)-VD-CG PHY + selftests: ioam: refactoring to align with the fix + Fix write to cloned skb in ipv6_hop_ioam() + phonet/pep: fix racy skb_queue_empty() use + phonet: take correct lock to peek at the RX queue + net: sparx5: Add spinlock for frame transmission from CPU + net/sched: flower: Add lock protection when remove filter handle + devlink: fix port dump cmd type + net: stmmac: Fix EST offset for dwmac 5.10 + tools: ynl: don't leak mcast_groups on init error + tools: ynl: make sure we always pass yarg to mnl_cb_run + net: mctp: put sock on tag allocation failure + netfilter: nf_tables: use kzalloc for hook allocation + netfilter: nf_tables: register hooks last when adding new chain/flowtable + netfilter: nft_flow_offload: release dst in case direct xmit path is used + netfilter: nft_flow_offload: reset dst in route object after setting up flow + netfilter: nf_tables: set dormant flag on hook register failure + selftests: tls: add test for peeking past a record of a different type + selftests: tls: add test for merging of same-type control messages + ... + + Parent Hashes: efa80dcbb7a3ecc4a1b2f54624c49b5a612f92b3 359e54a93ab43d32ee1bff3c2f9f10cb9f6b6e79 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge various networking and BPF-related fixes for current and previous Linux kernel releases.', 'keywords': 'networking,fixed,regressions', 'commit_classification': "It's a bug fix.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 89ee838130f470afcd02b30ca868f236a3f3b1d2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 89ee838130f470afcd02b30ca868f236a3f3b1d2 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1708621909 + Commit Message: + bpf + Parent Hashes: c1bb68f6b2f6be5297c5fbad5caebf67d0dd3034 + Refs: docs: specify which BPF_ABS and BPF_IND fields were zero + +Specifying which fields were unused allows IANA to only list as deprecated +instructions that were actually used + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit specifies unused BPF_ABS and BPF_IND fields allowing IANA to list deprecated instructions accurately.', 'keywords': 'BPF_ABS,BPF_IND,deprecated', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c1bb68f6b2f6be5297c5fbad5caebf67d0dd3034 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c1bb68f6b2f6be5297c5fbad5caebf67d0dd3034 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1708621657 + Commit Message: + bpf + Parent Hashes: 8425b6eb51460ef429920b2ee7e2b0881d4e23c5 + Refs: docs: Fix typos in instruction-set.rst + +* "BPF ADD" should be "BPF_ADD". +* "src" should be "src_reg" in several places. The latter is the field name + in the instruction. The former refers to the value of the register + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix typos in the eBPF instruction-set documentation regarding field names.', 'keywords': 'BPF_ADD,src_reg,typos', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8425b6eb51460ef429920b2ee7e2b0881d4e23c5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8425b6eb51460ef429920b2ee7e2b0881d4e23c5 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1708620375 + Commit Message: + Merge branch 'selftests-bpf-reduce-tcp_custom_syncookie-verification-complexity' + +Eduard Zingerman says: + +==================== +selftests/bpf: reduce tcp_custom_syncookie verification complexity + +Thread [0] discusses a fix for bpf_loop() handling bug. +That change makes tcp_custom_syncookie test too complex to verify. +The fix discussed in [0] would be sent via 'bpf' tree + Parent Hashes: a3c70a3cf11eb4b6409afc2cce1a3747e1dfe96f b546b57526953be2981113171ed586c4c50b1b0a + Refs: +tcp_custom_syncookie test is not in 'bpf' tree yet. +As agreed in [0] I'm sending syncookie test update separately. + +[0] https://lore.kernel.org/bpf/20240216150334.31937-1-eddyz87@gmail.com/ +==================== + +Link: https://lore.kernel.org/r/20240222150300.14909-1-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize the tcp_custom_syncookie test in selftests/bpf by reducing its verification complexity.', 'keywords': 'tcp_custom_syncookie, selftests, complexity', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: b546b57526953be2981113171ed586c4c50b1b0a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b546b57526953be2981113171ed586c4c50b1b0a + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1708620375 + Commit Message: + selftests/bpf: update tcp_custom_syncookie to use scalar packet offset + +This commit updates tcp_custom_syncookie.c:tcp_parse_option() to use +explicit packet offset (ctx->off) for packet access instead of ever +moving pointer (ctx->ptr) + Parent Hashes: a3c70a3cf11eb4b6409afc2cce1a3747e1dfe96f + Refs: this reduces verification complexity: +- the tcp_parse_option() is passed as a callback to bpf_loop(); +- suppose a checkpoint is created each time at function entry; +- the ctx->ptr is tracked by verifier as PTR_TO_PACKET; +- the ctx->ptr is incremented in tcp_parse_option() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates tcp_custom_syncookie to use scalar packet offset in tcp_parse_option for better verification.', 'keywords': 'selftests,bpf,offset', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: fdcd4467ba154465402432888f9ba9ad2122a37a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fdcd4467ba154465402432888f9ba9ad2122a37a + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1708592687 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-02-22 + +The following pull-request contains BPF updates for your *net* tree. + +We've added 11 non-merge commits during the last 24 day(s) which contain +a total of 15 files changed + Parent Hashes: 3489182b11d35f1944c1245fc9c4867cf622c50f 4cd12c6065dfcdeba10f49949bffcf383b3952d8 + Refs: 217 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge of BPF updates into the net tree with changes across 15 files and 217 insertions.', 'keywords': 'BPF, netdev, updates', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a3c70a3cf11eb4b6409afc2cce1a3747e1dfe96f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a3c70a3cf11eb4b6409afc2cce1a3747e1dfe96f + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1708552154 + Commit Message: + bpf: Shrink size of struct bpf_map/bpf_array. + +Back in 2018 the commit be95a845cc44 ("bpf: avoid false sharing of map refcount +with max_entries") added ____cacheline_aligned to "struct bpf_map" to make sure +that fields like refcnt don't share a cache line with max_entries that is used +to bounds check map access. That was done to make spectre style attacks harder. +The main mitigation is done via code similar to array_index_nospec() + Parent Hashes: 01dbd7d8720a0cc97dad5e70ec674dacdc66cf3c + Refs: of course. +This was an additional precaution. + +It increased the size of "struct bpf_map" a little + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit reduces the size of struct bpf_map and struct bpf_array to improve efficiency.', 'keywords': 'bpf_map,bpf_array,shrinking', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 01dbd7d8720a0cc97dad5e70ec674dacdc66cf3c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 01dbd7d8720a0cc97dad5e70ec674dacdc66cf3c + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1708552154 + Commit Message: + selftests/bpf: Remove intermediate test files. + +The test of linking process creates several intermediate files. +Remove them once the build is over. + +This reduces the number of files in selftests/bpf/ directory +from ~4400 to ~2600. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240220231102.49090-1-alexei.starovoitov@gmail.com + + Parent Hashes: 7648f0c91eaa3598add9e91991a5483b29da32ee + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes intermediate test files in selftests/bpf to reduce directory clutter.', 'keywords': 'selftests, intermediate, files', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 4cd12c6065dfcdeba10f49949bffcf383b3952d8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4cd12c6065dfcdeba10f49949bffcf383b3952d8 + Author Name: Shigeru Yoshida + Author Email: syoshida@redhat.com + Commit Date: 1708532123 + Commit Message: + bpf + Parent Hashes: 5c138a8a4abe152fcbef1ed40a6a4b5727b2991b + Refs: sockmap: Fix NULL pointer dereference in sk_psock_verdict_data_ready() + +syzbot reported the following NULL pointer dereference issue [1]: + + BUG: kernel NULL pointer dereference + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a NULL pointer dereference issue in sk_psock_verdict_data_ready().', 'keywords': 'NULL, pointer, dereference', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 56667da7399eb19af857e30f41bea89aa6fa812c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 56667da7399eb19af857e30f41bea89aa6fa812c + Author Name: Eric Dumazet + Author Email: edumazet@google.com + Commit Date: 1708514660 + Commit Message: + net: implement lockless setsockopt(SO_PEEK_OFF) + +syzbot reported a lockdep violation [1] involving af_unix +support of SO_PEEK_OFF. + +Since SO_PEEK_OFF is inherently not thread safe (it uses a per-socket +sk_peek_off field) + Parent Hashes: 3b1ae9b71c2a97f848b00fb085a2bd29bddbe8d9 + Refs: there is really no point to enforce a pointless +thread safety in the kernel. + +After this patch : + +- setsockopt(SO_PEEK_OFF) no longer acquires the socket lock. + +- skb_consume_udp() no longer has to acquire the socket lock. + +- af_unix no longer needs a special version of sk_set_peek_off() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implemented a lockless version of setsockopt for SO_PEEK_OFF to prevent a lockdep violation in af_unix.', 'keywords': 'lockless,setsockopt,SO_PEEK_OFF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['socket like programs', 'other']} +-------------------- +-------------------- +Processing Commit ID: 5d4cc87414c5d11345c4b11d61377d351b5c28a2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5d4cc87414c5d11345c4b11d61377d351b5c28a2 + Author Name: Eric Dumazet + Author Email: edumazet@google.com + Commit Date: 1708426905 + Commit Message: + net: reorganize "struct sock" fields + +Last major reorg happened in commit 9115e8cd2a0c ("net: reorganize +struct sock for better data locality") + +Since then + Parent Hashes: 465c1abcb64426f0ff39e80e508e2432672c2dae + Refs: many changes have been done. + +Before SO_PEEK_OFF support is added to TCP + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reorganize struct sock fields for better data locality.', 'keywords': 'reorganize, struct sock, data locality', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 5c138a8a4abe152fcbef1ed40a6a4b5727b2991b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5c138a8a4abe152fcbef1ed40a6a4b5727b2991b + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1708342095 + Commit Message: + selftests/bpf: Add negtive test cases for task iter + +Incorporate a test case to assess the handling of invalid flags or +task__nullable parameters passed to bpf_iter_task_new(). Prior to the +preceding commit + Parent Hashes: 5f2ae606cb5a90839a9be9d22388c4200f820e75 + Refs: this scenario could potentially trigger a kernel panic. +However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add negative test cases to bpf_iter_task_new to prevent kernel panics with invalid inputs.', 'keywords': 'negtive,test cases,task iter', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5f2ae606cb5a90839a9be9d22388c4200f820e75 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5f2ae606cb5a90839a9be9d22388c4200f820e75 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1708342095 + Commit Message: + bpf: Fix an issue due to uninitialized bpf_iter_task + +Failure to initialize it->pos + Parent Hashes: 3f00e4a9c96f4488a924aff4e35b77c8eced897e + Refs: coupled with the presence of an invalid +value in the flags variable + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes an issue with uninitialized bpf_iter_task causing invalid values in flags.', 'keywords': 'bpf_iter_task,uninitialized,fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3f00e4a9c96f4488a924aff4e35b77c8eced897e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3f00e4a9c96f4488a924aff4e35b77c8eced897e + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1708342006 + Commit Message: + selftests/bpf: Test racing between bpf_timer_cancel_and_free and bpf_timer_cancel + +This selftest is based on a Alexei's test adopted from an internal +user to troubleshoot another bug. During this exercise + Parent Hashes: 0281b919e175bb9c3128bd3872ac2903e9436e3f + Refs: a separate +racing bug was discovered between bpf_timer_cancel_and_free +and bpf_timer_cancel. The details can be found in the previous +patch. + +This patch is to add a selftest that can trigger the bug. +I can trigger the UAF everytime in my qemu setup with KASAN. The idea +is to have multiple user space threads running in a tight loop to exercise +both bpf_map_update_elem (which calls into bpf_timer_cancel_and_free) +and bpf_timer_cancel. + +Signed-off-by: Martin KaFai Lau +Signed-off-by: Daniel Borkmann +Acked-by: Hou Tao +Link: https://lore.kernel.org/bpf/20240215211218.990808-2-martin.lau@linux.dev + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest to detect race conditions between bpf_timer_cancel_and_free and bpf_timer_cancel.', 'keywords': 'selftest,race,bug', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0281b919e175bb9c3128bd3872ac2903e9436e3f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0281b919e175bb9c3128bd3872ac2903e9436e3f + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1708342006 + Commit Message: + bpf: Fix racing between bpf_timer_cancel_and_free and bpf_timer_cancel + +The following race is possible between bpf_timer_cancel_and_free +and bpf_timer_cancel. It will lead a UAF on the timer->timer. + +bpf_timer_cancel(); + spin_lock(); + t = timer->time; + spin_unlock(); + + bpf_timer_cancel_and_free(); + spin_lock(); + t = timer->timer; + timer->timer = NULL; + spin_unlock(); + hrtimer_cancel(&t->timer); + kfree(t); + + /* UAF on t */ + hrtimer_cancel(&t->timer); + +In bpf_timer_cancel_and_free + Parent Hashes: 54d46c9f581d16ac6adad3c3e61766e02bbfcb60 + Refs: this patch frees the timer->timer +after a rcu grace period. This requires a rcu_head addition +to the "struct bpf_hrtimer". Another kfree(t) happens in bpf_timer_init + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix race condition in bpf_timer_cancel_and_free leading to use-after-free on timers.', 'keywords': 'bpf_timer,race condition,use-after-free', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: ac00b6546d390bc12d1d2824c2b5d95046097eb2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ac00b6546d390bc12d1d2824c2b5d95046097eb2 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1708186412 + Commit Message: + Merge tag 'media/v6.8-4' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media + +Pull media fixes from Mauro Carvalho Chehab: + + - regression fix for rkisp1 shared IRQ logic + + - fix atomisp breakage due to a kAPI change + + - permission fix for remote controller BPF support + + - memleak fix in ir_toy driver + + - Kconfig dependency fix for pwm-ir-rx + +* tag 'media/v6.8-4' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: + media: pwm-ir-tx: Depend on CONFIG_HIGH_RES_TIMERS + media: ir_toy: fix a memleak in irtoy_tx + media: rc: bpf attach/detach requires write permission + media: atomisp: Adjust for v4l2_subdev_state handling changes in 6.8 + media: rkisp1: Fix IRQ handling due to shared interrupts + media: Revert "media: rkisp1: Drop IRQF_SHARED" + + Parent Hashes: 4a7571485c467b76cc19fae304452fd56921c789 346c84e281a963437b9fe9dfcd92c531630289de + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge media fixes including IRQ logic, kAPI changes, and memory leak corrections.', 'keywords': 'media, fixes, IRQ', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: bacefe0c7b77b7527a613e053b6d378412a8a779 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bacefe0c7b77b7527a613e053b6d378412a8a779 + Author Name: Namhyung Kim + Author Email: namhyung@kernel.org + Commit Date: 1708128448 + Commit Message: + perf tools: Fixup module symbol end address properly + +I got a strange error on ARM to fail on processing FINISHED_ROUND +record. It turned out that it was failing in symbol__alloc_hist() +because the symbol size is too big. + +When a sample is captured on a specific BPF program + Parent Hashes: 6f146b249b3ada0082209b34abf01c90c702a96b + Refs: it failed. I've +added a debug code and found the end address of the symbol is from +the next module which is placed far way. + + ffff800008795778-ffff80000879d6d8: bpf_prog_1bac53b8aac4bc58_netcg_sock [bpf] + ffff80000879d6d8-ffff80000ad656b4: bpf_prog_76867454b5944e15_netcg_getsockopt [bpf] + ffff80000ad656b4-ffffd69b7af74048: bpf_prog_1d50286d2eb1be85_hn_egress [bpf] <---------- here + ffffd69b7af74048-ffffd69b7af74048: $x.5 [sha3_generic] + ffffd69b7af74048-ffffd69b7af740b8: crypto_sha3_init [sha3_generic] + ffffd69b7af740b8-ffffd69b7af741e0: crypto_sha3_update [sha3_generic] + +The logic in symbols__fixup_end() just uses curr->start to update the +prev->end. But in this case + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes end address calculation for module symbols in perf tools on ARM.', 'keywords': 'perf tools, symbol, ARM', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 29d16de26df17e94dd0310dc83c37f82b48a59cf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 29d16de26df17e94dd0310dc83c37f82b48a59cf + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@kernel.org + Commit Date: 1708125597 + Commit Message: + perf augmented_raw_syscalls.bpf: Move 'struct timespec64' to vmlinux.h + +If we instead decide to generate vmlinux.h from BTF info + Parent Hashes: f512e08fd0940fcd811d24e2cfd95683fe8042c3 + Refs: it will be +there: + + $ pahole timespec64 + struct timespec64 { + time64_t tv_sec; /* 0 8 */ + long int tv_nsec; /* 8 8 */ + + /* size: 16 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Moved 'struct timespec64' definition to vmlinux.h in perf augmented_raw_syscalls.bpf.", 'keywords': 'timespec64,vmlinux.h,perf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 7648f0c91eaa3598add9e91991a5483b29da32ee +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7648f0c91eaa3598add9e91991a5483b29da32ee + Author Name: Marcos Paulo de Souza + Author Email: mpdesouza@suse.com + Commit Date: 1708103306 + Commit Message: + selftests/bpf: Remove empty TEST_CUSTOM_PROGS + +Commit f04a32b2c5b5 ("selftests/bpf: Do not use sign-file as testcase") +removed the TEST_CUSTOM_PROGS assignment + Parent Hashes: 682158ab532a5bd24399fec25b65fec561f0f6e9 + Refs: and removed it from being used +on TEST_GEN_FILES. Remove two leftovers from that cleanup. Found by +inspection. + +Signed-off-by: Marcos Paulo de Souza +Signed-off-by: Daniel Borkmann +Cc: Alexey Gladkov +Link: https://lore.kernel.org/bpf/20240216-bpf-selftests-custom-progs-v1-1-f7cf281a1fda@suse.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes leftover entries relating to TEST_CUSTOM_PROGS in selftests for BPF.', 'keywords': 'selftests,bpf,cleanup', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 54d46c9f581d16ac6adad3c3e61766e02bbfcb60 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 54d46c9f581d16ac6adad3c3e61766e02bbfcb60 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1708053699 + Commit Message: + Merge branch 'fix-the-read-of-vsyscall-page-through-bpf' + +Hou Tao says: + +==================== +Fix the read of vsyscall page through bpf + +From: Hou Tao + +Hi + Parent Hashes: e37243b65d528a8a9f8b9a57a43885f8e8dfc15c be66d79189ec8a1006ec6ec302bb27b160b3e6ce + Refs: + +As reported by syzboot [1] and [2] + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes issue with reading the vsyscall page through BPF.', 'keywords': 'vsyscall, BPF, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: be66d79189ec8a1006ec6ec302bb27b160b3e6ce +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: be66d79189ec8a1006ec6ec302bb27b160b3e6ce + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1708053699 + Commit Message: + selftest/bpf: Test the read of vsyscall page under x86-64 + +Under x86-64 + Parent Hashes: 32019c659ecfe1d92e3bf9fcdfbb11a7c70acd58 + Refs: when using bpf_probe_read_kernel{_str}() or +bpf_probe_read{_str}() to read vsyscall page + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftest for reading vsyscall page using bpf_probe_read functions under x86-64 architecture.', 'keywords': 'selftest, vsyscall, bpf_probe_read', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 32019c659ecfe1d92e3bf9fcdfbb11a7c70acd58 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 32019c659ecfe1d92e3bf9fcdfbb11a7c70acd58 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1708053699 + Commit Message: + x86/mm: Disallow vsyscall page read for copy_from_kernel_nofault() + +When trying to use copy_from_kernel_nofault() to read vsyscall page +through a bpf program + Parent Hashes: ee0e39a63b78849f8abbef268b13e4838569f646 + Refs: the following oops was reported: + + BUG: unable to handle page fault for address: ffffffffff600000 + #PF: supervisor read access in kernel mode + #PF: error_code(0x0000) - not-present page + PGD 3231067 P4D 3231067 PUD 3233067 PMD 3235067 PTE 0 + Oops: 0000 [#1] PREEMPT SMP PTI + CPU: 1 PID: 20390 Comm: test_progs ...... 6.7.0+ #58 + Hardware name: QEMU Standard PC (i440FX + PIIX + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit disallows reading the vsyscall page through copy_from_kernel_nofault() in x86/mm for bpf programs.', 'keywords': 'vsyscall,copy_from_kernel_nofault,page fault', 'commit_classification': "It's a security fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 682158ab532a5bd24399fec25b65fec561f0f6e9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 682158ab532a5bd24399fec25b65fec561f0f6e9 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1708033527 + Commit Message: + bpf: Fix test verif_scale_strobemeta_subprogs failure due to llvm19 + +With latest llvm19 + Parent Hashes: 57354f5fdee8017783b5cc2e53b263641b6862e9 + Refs: I hit the following selftest failures with + + $ ./test_progs -j + libbpf: prog 'on_event': BPF program load failed: Permission denied + libbpf: prog 'on_event': -- BEGIN PROG LOAD LOG -- + combined stack size of 4 calls is 544. Too large + verification time 1344153 usec + stack depth 24+440+0+32 + processed 51008 insns (limit 1000000) max_states_per_insn 19 total_states 1467 peak_states 303 mark_read 146 + -- END PROG LOAD LOG -- + libbpf: prog 'on_event': failed to load: -13 + libbpf: failed to load object 'strobemeta_subprogs.bpf.o' + scale_test:FAIL:expect_success unexpected error: -13 (errno 13) + #498 verif_scale_strobemeta_subprogs:FAIL + +The verifier complains too big of the combined stack size (544 bytes) which +exceeds the maximum stack limit 512. This is a regression from llvm19 ([1]). + +In the above error log + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes a test failure caused by exceeding stack size limit due to llvm19 regression.', 'keywords': 'fix, verifier, llvm19', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 57354f5fdee8017783b5cc2e53b263641b6862e9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 57354f5fdee8017783b5cc2e53b263641b6862e9 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1708030848 + Commit Message: + bpf: improve duplicate source code line detection + +Verifier log avoids printing the same source code line multiple times +when a consecutive block of BPF assembly instructions are covered by the +same original (C) source code line. This greatly improves verifier log +legibility. + +Unfortunately + Parent Hashes: a4561f5afef8a8ff25a2cfd46d587f65869494f2 + Refs: this check is imperfect and in production applications it +quite often happens that verifier log will have multiple duplicated +source lines emitted + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improves detection of duplicate source code lines in eBPF verifier logs for better legibility.', 'keywords': 'duplicate detection logs', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a4561f5afef8a8ff25a2cfd46d587f65869494f2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a4561f5afef8a8ff25a2cfd46d587f65869494f2 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707951222 + Commit Message: + bpf: Use O(log(N)) binary search to find line info record + +Real-world BPF applications keep growing in size. Medium-sized production +application can easily have 50K+ verified instructions + Parent Hashes: 1159d27852207e8efb8d6ef2dae5aaa87ec4e225 + Refs: and its line +info section in .BTF.ext has more than 3K entries. + +When verifier emits log with log_level>=1 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit optimizes line info record lookup in bpf by implementing a binary search to improve performance.', 'keywords': 'binary search, line info, performance', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e3a9ee963ad8ba677ca925149812c5932b49af69 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e3a9ee963ad8ba677ca925149812c5932b49af69 + Author Name: Nathan Chancellor + Author Email: nathan@kernel.org + Commit Date: 1707947800 + Commit Message: + kbuild: Fix changing ELF file type for output of gen_btf for big endian + +Commit 90ceddcb4950 ("bpf: Support llvm-objcopy for vmlinux BTF") +changed the ELF type of .btf.vmlinux.bin.o to ET_REL via dd + Parent Hashes: 6388cfd0e69b56ca640610f1bf29334619d18142 + Refs: which works +fine for little endian platforms: + + 00000000 7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00 |.ELF............| + -00000010 03 00 b7 00 01 00 00 00 00 00 00 80 00 80 ff ff |................| + +00000010 01 00 b7 00 01 00 00 00 00 00 00 80 00 80 ff ff |................| + +However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes an ELF file type change issue for big endian platforms in gen_btf output.', 'keywords': 'big endian, ELF file, gen_btf', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1159d27852207e8efb8d6ef2dae5aaa87ec4e225 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1159d27852207e8efb8d6ef2dae5aaa87ec4e225 + Author Name: Matt Bobrowski + Author Email: mattbobrowski@google.com + Commit Date: 1707932926 + Commit Message: + libbpf: Make remark about zero-initializing bpf_*_info structs + +In some situations + Parent Hashes: 7cc13adbd057f1905564ec2a254883d7fd407deb + Refs: if you fail to zero-initialize the +bpf_{prog + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit addresses the necessity of zero-initializing bpf_info structs in the libbpf library.', 'keywords': 'zero-initializing,bpf_info,libbpf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e37243b65d528a8a9f8b9a57a43885f8e8dfc15c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e37243b65d528a8a9f8b9a57a43885f8e8dfc15c + Author Name: Gianmarco Lusvardi + Author Email: glusvardi@posteo.net + Commit Date: 1707927048 + Commit Message: + bpf + Parent Hashes: 2127c604383666675789fd4a5fc2aead46c73aad + Refs: scripts: Correct GPL license name + +The bpf_doc script refers to the GPL as the "GNU Privacy License". +I strongly suspect that the author wanted to refer to the GNU General +Public License + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Fix typo in bpf_doc script by correcting 'GNU Privacy License' to 'GNU General Public License'.", 'keywords': 'typo, GPL, correction', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 7cc13adbd057f1905564ec2a254883d7fd407deb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7cc13adbd057f1905564ec2a254883d7fd407deb + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707879092 + Commit Message: + bpf: emit source code file name and line number in verifier log + +As BPF applications grow in size and complexity and are separated into +multiple .bpf.c files that are statically linked together + Parent Hashes: 96adbf7125e49687e5c1dbd8a241c68e2441da98 + Refs: it becomes +harder and harder to match verifier's BPF assembly level output to +original C code. While often annotated C source code is unique enough to +be able to identify the file it belongs to + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance verifier log with source file and line number for better code traceability in BPF applications.', 'keywords': 'verifier, source code, log', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 96adbf7125e49687e5c1dbd8a241c68e2441da98 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 96adbf7125e49687e5c1dbd8a241c68e2441da98 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1707878807 + Commit Message: + Merge branch 'fix-global-subprog-ptr_to_ctx-arg-handling' + +Andrii Nakryiko says: + +==================== +Fix global subprog PTR_TO_CTX arg handling + +Fix confusing and incorrect inference of PTR_TO_CTX argument type in BPF +global subprogs. For some program types (iters + Parent Hashes: 32e18e7688c6847b0c9db073aafb00639ecf576c 63d5a33fb4ec2a4ed6907c8ac144b6f10f6dba47 + Refs: tracepoint + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes incorrect inference of PTR_TO_CTX argument type in BPF global subprograms.', 'keywords': 'PTR_TO_CTX,global subprog,fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 63d5a33fb4ec2a4ed6907c8ac144b6f10f6dba47 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 63d5a33fb4ec2a4ed6907c8ac144b6f10f6dba47 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707878807 + Commit Message: + selftests/bpf: add anonymous user struct as global subprog arg test + +Add tests validating that kernel handles pointer to anonymous struct +argument as PTR_TO_MEM case + Parent Hashes: 879bbe7aa4afa80acf72a1cad7f52416ea78c52d + Refs: not as PTR_TO_CTX case. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240212233221.2575350-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test case for handling anonymous struct pointers as PTR_TO_MEM in eBPF selftests.', 'keywords': 'anonymous, struct, test', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 879bbe7aa4afa80acf72a1cad7f52416ea78c52d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 879bbe7aa4afa80acf72a1cad7f52416ea78c52d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707878807 + Commit Message: + bpf: don't infer PTR_TO_CTX for programs with unnamed context type + +For program types that don't have named context type name (e.g. + Parent Hashes: 824c58fb1090ae5e502284400682e30841280a87 + Refs: BPF +iterator programs or tracepoint programs) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Prevent automatic inference of PTR_TO_CTX for eBPF programs with unnamed context types.', 'keywords': 'PTR_TO_CTX, unnamed context, programs', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['tracepoints like programs', "It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 824c58fb1090ae5e502284400682e30841280a87 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 824c58fb1090ae5e502284400682e30841280a87 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707878807 + Commit Message: + bpf: handle bpf_user_pt_regs_t typedef explicitly for PTR_TO_CTX global arg + +Expected canonical argument type for global function arguments +representing PTR_TO_CTX is `bpf_user_pt_regs_t *ctx`. This currently +works on s390x by accident because kernel resolves such typedef to +underlying struct (which is anonymous on s390x) + Parent Hashes: fb5b86cfd4ef21ea18966718f6bf6c8f1b9df12e + Refs: and erroneously +accepting it as expected context type. We are fixing this problem next + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed handling of bpf_user_pt_regs_t typedef for PTR_TO_CTX global argument to ensure proper context type recognition across architectures.', 'keywords': 'bpf typedef PTR_TO_CTX', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fb5b86cfd4ef21ea18966718f6bf6c8f1b9df12e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fb5b86cfd4ef21ea18966718f6bf6c8f1b9df12e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707878806 + Commit Message: + bpf: simplify btf_get_prog_ctx_type() into btf_is_prog_ctx_type() + +Return result of btf_get_prog_ctx_type() is never used and callers only +check NULL vs non-NULL case to determine if given type matches expected +PTR_TO_CTX type. So rename function to `btf_is_prog_ctx_type()` and +return a simple true/false. We'll use this simpler interface to handle +kprobe program type's special typedef case in the next patch. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240212233221.2575350-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 32e18e7688c6847b0c9db073aafb00639ecf576c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactored btf_get_prog_ctx_type() to btf_is_prog_ctx_type() simplifying its interface for detecting PTR_TO_CTX types.', 'keywords': 'BTF,simplify,kprobe', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 32e18e7688c6847b0c9db073aafb00639ecf576c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 32e18e7688c6847b0c9db073aafb00639ecf576c + Author Name: Oliver Crumrine + Author Email: ozlinuxc@gmail.com + Commit Date: 1707867677 + Commit Message: + bpf: remove check in __cgroup_bpf_run_filter_skb + +Originally + Parent Hashes: 2c21a0f67c8ce334b8a58332e8c2d71694bef0ab + Refs: this patch removed a redundant check in +BPF_CGROUP_RUN_PROG_INET_EGRESS + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed a redundant check in BPF_CGROUP_RUN_PROG_INET_EGRESS function.', 'keywords': 'remove, redundant, cgroup', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 2c21a0f67c8ce334b8a58332e8c2d71694bef0ab +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2c21a0f67c8ce334b8a58332e8c2d71694bef0ab + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1707866204 + Commit Message: + Merge branch 'Support PTR_MAYBE_NULL for struct_ops arguments.' + +Kui-Feng Lee says: + +==================== +Allow passing null pointers to the operators provided by a struct_ops +object. This is an RFC to collect feedbacks/opinions. + +The function pointers that are passed to struct_ops operators (the function +pointers) are always considered reliable until now. They cannot be +null. However + Parent Hashes: dc8543b597c282643a433e9a8af0459ed3046908 00f239eccf461a6403b3c16e767d04f3954cae98 + Refs: in certain scenarios + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows null pointers for struct_ops function arguments in certain scenarios.', 'keywords': 'null,pointers,struct_ops', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 00f239eccf461a6403b3c16e767d04f3954cae98 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 00f239eccf461a6403b3c16e767d04f3954cae98 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1707866204 + Commit Message: + selftests/bpf: Test PTR_MAYBE_NULL arguments of struct_ops operators. + +Test if the verifier verifies nullable pointer arguments correctly for BPF +struct_ops programs. + +"test_maybe_null" in struct bpf_testmod_ops is the operator defined for the +test cases here. + +A BPF program should check a pointer for NULL beforehand to access the +value pointed by the nullable pointer arguments + Parent Hashes: 1611603537a4b88cec7993f32b70c03113801a46 + Refs: or the verifier should +reject the programs. The test here includes two parts; the programs +checking pointers properly and the programs not checking pointers +beforehand. The test checks if the verifier accepts the programs checking +properly and rejects the programs not checking at all. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240209023750.1153905-5-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add tests for nullable pointer verification in BPF struct_ops programs.', 'keywords': 'selftests,bpf,nullable', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1611603537a4b88cec7993f32b70c03113801a46 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1611603537a4b88cec7993f32b70c03113801a46 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1707866204 + Commit Message: + bpf: Create argument information for nullable arguments. + +Collect argument information from the type information of stub functions to +mark arguments of BPF struct_ops programs with PTR_MAYBE_NULL if they are +nullable. A nullable argument is annotated by suffixing "__nullable" at +the argument name of stub function. + +For nullable arguments + Parent Hashes: 6115a0aeef01aef152ad7738393aad11422bfb82 + Refs: this patch sets a struct bpf_ctx_arg_aux to label +their reg_type with PTR_TO_BTF_ID | PTR_TRUSTED | PTR_MAYBE_NULL. This +makes the verifier to check programs and ensure that they properly check +the pointer. The programs should check if the pointer is null before +accessing the pointed memory. + +The implementer of a struct_ops type should annotate the arguments that can +be null. The implementer should define a stub function (empty) as a +placeholder for each defined operator. The name of a stub function should +be in the pattern "__". For example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds handling for nullable arguments in BPF struct_ops by marking them with PTR_MAYBE_NULL.', 'keywords': 'nullable, arguments, struct_ops', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6115a0aeef01aef152ad7738393aad11422bfb82 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6115a0aeef01aef152ad7738393aad11422bfb82 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1707866204 + Commit Message: + bpf: Move __kfunc_param_match_suffix() to btf.c. + +Move __kfunc_param_match_suffix() to btf.c and rename it as +btf_param_match_suffix(). It can be reused by bpf_struct_ops later. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240209023750.1153905-3-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 77c0208e199ccb0986fb3612f2409c8cdcb036ad + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The function __kfunc_param_match_suffix() is moved and renamed to btf_param_match_suffix() for reuse soon.', 'keywords': 'bpf,moved,reuse', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 77c0208e199ccb0986fb3612f2409c8cdcb036ad +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 77c0208e199ccb0986fb3612f2409c8cdcb036ad + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1707866204 + Commit Message: + bpf: add btf pointer to struct bpf_ctx_arg_aux. + +Enable the providers to use types defined in a module instead of in the +kernel (btf_vmlinux). + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240209023750.1153905-2-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: dc8543b597c282643a433e9a8af0459ed3046908 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add BTF pointer in struct bpf_ctx_arg_aux to enable use of module-defined types.', 'keywords': 'BTF, bpf_ctx_arg_aux, module', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dc8543b597c282643a433e9a8af0459ed3046908 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dc8543b597c282643a433e9a8af0459ed3046908 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1707862455 + Commit Message: + bpf + Parent Hashes: 12bbcf8e840f40b82b02981e96e0a5fbb0703ea9 + Refs: docs: Update ISA document title + +* Use "Instruction Set Architecture (ISA)" instead of "Instruction Set + Specification" +* Remove version number + +As previously discussed on the mailing list at +https://mailarchive.ietf.org/arch/msg/bpf/SEpn3OL9TabNRn-4rDX9A6XVbjM/ + +Signed-off-by: Dave Thaler +Signed-off-by: Daniel Borkmann +Acked-by: David Vernet +Link: https://lore.kernel.org/bpf/20240208221449.12274-1-dthaler1968@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Updated the BPF ISA document by changing the title and removing the version number.', 'keywords': 'ISA, document, update', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 2127c604383666675789fd4a5fc2aead46c73aad +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2127c604383666675789fd4a5fc2aead46c73aad + Author Name: Sebastian Andrzej Siewior + Author Email: bigeasy@linutronix.de + Commit Date: 1707862229 + Commit Message: + xsk: Add truesize to skb_add_rx_frag(). + +xsk_build_skb() allocates a page and adds it to the skb via +skb_add_rx_frag() and specifies 0 for truesize. This leads to a warning +in skb_add_rx_frag() with CONFIG_DEBUG_NET enabled because size is +larger than truesize. + +Increasing truesize requires to add the same amount to socket's +sk_wmem_alloc counter in order not to underflow the counter during +release in the destructor (sock_wfree()). + +Pass the size of the allocated page as truesize to skb_add_rx_frag(). +Add this mount to socket's sk_wmem_alloc counter. + +Fixes: cf24f5a5feea ("xsk: add support for AF_XDP multi-buffer on Tx path") +Signed-off-by: Sebastian Andrzej Siewior +Signed-off-by: Daniel Borkmann +Acked-by: Maciej Fijalkowski +Link: https://lore.kernel.org/bpf/20240202163221.2488589-1-bigeasy@linutronix.de + + Parent Hashes: 11f522256e9043b0fcd2f994278645d3e201d20c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit addresses a warning by adding truesize to skb_add_rx_frag and updating sk_wmem_alloc accordingly.', 'keywords': 'truesize, xsk, skb_add_rx_frag', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 12bbcf8e840f40b82b02981e96e0a5fbb0703ea9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 12bbcf8e840f40b82b02981e96e0a5fbb0703ea9 + Author Name: Cupertino Miranda + Author Email: cupertino.miranda@oracle.com + Commit Date: 1707852492 + Commit Message: + libbpf: Add support to GCC in CORE macro definitions + +Due to internal differences between LLVM and GCC the current +implementation for the CO-RE macros does not fit GCC parser + Parent Hashes: 52dbd67dff5d050e99301100e2cac578eef9b2e9 + Refs: as it will +optimize those expressions even before those would be accessible by the +BPF backend. + +As examples + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for GCC in CO-RE macro definitions in libbpf.', 'keywords': 'GCC, CORE, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 52dbd67dff5d050e99301100e2cac578eef9b2e9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 52dbd67dff5d050e99301100e2cac578eef9b2e9 + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1707851850 + Commit Message: + bpf: Abstract loop unrolling pragmas in BPF selftests + +[Changes from V1: +- Avoid conflict by rebasing with latest master.] + +Some BPF tests use loop unrolling compiler pragmas that are clang +specific and not supported by GCC. These pragmas + Parent Hashes: fc1c9e40da37905f87c73711a1ecc57f52c1fe1c + Refs: along with their +GCC equivalences are: + + #pragma clang loop unroll_count(N) + #pragma GCC unroll N + + #pragma clang loop unroll(full) + #pragma GCC unroll 65534 + + #pragma clang loop unroll(disable) + #pragma GCC unroll 1 + + #pragma unroll [aka #pragma clang loop unroll(enable)] + There is no GCC equivalence to this pragma. It enables unrolling on + loops that the compiler would not ordinarily unroll even with + -O2|-funroll-loops + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Abstracts loop unrolling pragmas for BPF selftests to support both Clang and GCC compilers.', 'keywords': 'loop unrolling, BPF selftests, compilers', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 11f522256e9043b0fcd2f994278645d3e201d20c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 11f522256e9043b0fcd2f994278645d3e201d20c + Author Name: Hari Bathini + Author Email: hbathini@linux.ibm.com + Commit Date: 1707851619 + Commit Message: + bpf: Fix warning for bpf_cpumask in verifier + +Compiling with CONFIG_BPF_SYSCALL & !CONFIG_BPF_JIT throws the below +warning: + + "WARN: resolve_btfids: unresolved symbol bpf_cpumask" + +Fix it by adding the appropriate #ifdef. + +Signed-off-by: Hari Bathini +Signed-off-by: Andrii Nakryiko +Acked-by: Jiri Olsa +Acked-by: Stanislav Fomichev +Acked-by: David Vernet +Link: https://lore.kernel.org/bpf/20240208100115.602172-1-hbathini@linux.ibm.com + + Parent Hashes: 577e4432f3ac810049cb7e6b71f4d96ec7c6e894 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix warning for unresolved symbol bpf_cpumask in the eBPF verifier using an appropriate #ifdef.', 'keywords': 'warning,bpf_cpumask,verifier', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fc1c9e40da37905f87c73711a1ecc57f52c1fe1c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fc1c9e40da37905f87c73711a1ecc57f52c1fe1c + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1707851485 + Commit Message: + selftests/bpf: Ensure fentry prog cannot attach to bpf_spin_{lock + Parent Hashes: 178c54666f9c4d2f49f2ea661d0c11b52f0ed190 + Refs: unlcok}() + +Add two tests to ensure fentry programs cannot attach to +bpf_spin_{lock + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds tests to ensure fentry programs cannot attach to bpf_spin_lock functions.', 'keywords': 'fentry, bpf_spin_lock, tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 178c54666f9c4d2f49f2ea661d0c11b52f0ed190 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 178c54666f9c4d2f49f2ea661d0c11b52f0ed190 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1707851485 + Commit Message: + bpf: Mark bpf_spin_{lock + Parent Hashes: 5b268d1ebcdceacf992dfda8f9031d56005a274e + Refs: unlock}() helpers with notrace correctly + +Currently tracing is supposed not to allow for bpf_spin_{lock + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit correctly marks bpf_spin_{lock,unlock} helpers with notrace attribute.', 'keywords': 'bpf_spin_lock,helpers,notrace', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5b268d1ebcdceacf992dfda8f9031d56005a274e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5b268d1ebcdceacf992dfda8f9031d56005a274e + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1707851126 + Commit Message: + bpf: Have bpf_rdonly_cast() take a const pointer + +Since 20d59ee55172 ("libbpf: add bpf_core_cast() macro") + Parent Hashes: 68bc61c26cacf152baf905786b5949769700f40d + Refs: libbpf is now +exporting a const arg version of bpf_rdonly_cast(). This causes the +following conflicting type error when generating kfunc prototypes from +BTF: + +In file included from skeleton/pid_iter.bpf.c:5: +/home/dxu/dev/linux/tools/bpf/bpftool/bootstrap/libbpf/include/bpf/bpf_core_read.h:297:14: error: conflicting types for 'bpf_rdonly_cast' +extern void *bpf_rdonly_cast(const void *obj__ign + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies bpf_rdonly_cast function to accept a constant pointer for compatibility with libbpf changes.', 'keywords': 'bpf,rdonly_cast,const', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ed94a8f8ca75ea0f607c919edf2ed5a5e707ef44 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ed94a8f8ca75ea0f607c919edf2ed5a5e707ef44 + Author Name: Jiri Slaby (SUSE) + Author Email: jirislaby@kernel.org + Commit Date: 1707821035 + Commit Message: + HID: protect hid_device::bpf by CONFIG_HID_BPF + +And not by CONFIG_BPF. BPF can be selected while HID_BPF does not have +to. It actually cannot be on some platforms due to Kconfig dependences. + +This saves quite some bytes on those setups. + +Found by https://github.com/jirislaby/clang-struct. + +Signed-off-by: Jiri Slaby (SUSE) +Cc: Jiri Kosina +Cc: Benjamin Tissoires +Signed-off-by: Jiri Kosina + + Parent Hashes: dcd5231f093b6cd8ea2015e7fe1f372cef5c643d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies HID device configuration dependency to use CONFIG_HID_BPF instead of CONFIG_BPF.', 'keywords': 'HID, CONFIG_HID_BPF, configuration', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 923e4616ec15b7feabdc353b229762069eb73c43 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 923e4616ec15b7feabdc353b229762069eb73c43 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1707770141 + Commit Message: + perf maps: Locking tidy up of nr_maps + +After this change maps__nr_maps is only used by tests + Parent Hashes: ff0bd79980fffa00c36eb2b9044dbe9cfdf4bb79 + Refs: existing users +are migrated to maps__empty. Compute maps__empty under the read lock. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-7-irogers@google.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit tidies up locking of nr_maps, migrating users to maps__empty under a read lock, used only by tests.', 'keywords': 'locking, maps, read-lock', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: ff0bd79980fffa00c36eb2b9044dbe9cfdf4bb79 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ff0bd79980fffa00c36eb2b9044dbe9cfdf4bb79 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1707770141 + Commit Message: + perf maps: Hide maps internals + +Move the struct into the C file. Add maps__equal to work around +exposing the struct for reference count checking. Add accessors for +the unwind_libunwind_ops. Move maps_list_node to its only use in +symbol.c. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-6-irogers@google.com + + Parent Hashes: 39a27325e6099e9f9a10d8b5f3b2470a3c10efa5 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor the perf map internals by moving structs, adding workarounds and accessors, and relocating specific elements to improve encapsulation.', 'keywords': 'perf maps, structures, encapsulation', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 39a27325e6099e9f9a10d8b5f3b2470a3c10efa5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 39a27325e6099e9f9a10d8b5f3b2470a3c10efa5 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1707770141 + Commit Message: + perf maps: Get map before returning in maps__find_next_entry + +Finding a map is done under a lock + Parent Hashes: 107ef66cb054f8d54e336236a31631a8cc167c1f + Refs: returning the map without a +reference count means it can be removed without notice and causing +uses after free. Grab a reference count to the map within the lock +region and return this. Fix up locations that need a map__put +following this. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-5-irogers@google.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Acquire map reference count within lock to prevent use-after-free in maps__find_next_entry.', 'keywords': 'map lock reference', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 107ef66cb054f8d54e336236a31631a8cc167c1f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 107ef66cb054f8d54e336236a31631a8cc167c1f + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1707770133 + Commit Message: + perf maps: Get map before returning in maps__find_by_name + +Finding a map is done under a lock + Parent Hashes: 42fd623b58dbcc48310705bbf3e3d4d7c1deec29 + Refs: returning the map without a +reference count means it can be removed without notice and causing +uses after free. Grab a reference count to the map within the lock +region and return this. Fix up locations that need a map__put +following this. Also fix some reference counted pointer comparisons. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-4-irogers@google.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix potential use after free in perf maps by ensuring reference count manipulation within lock.', 'keywords': 'perf maps,reference count,lock', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 42fd623b58dbcc48310705bbf3e3d4d7c1deec29 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 42fd623b58dbcc48310705bbf3e3d4d7c1deec29 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1707770126 + Commit Message: + perf maps: Get map before returning in maps__find + +Finding a map is done under a lock + Parent Hashes: 659ad3492b913c9033d47cb406ac5754780875b6 + Refs: returning the map without a +reference count means it can be removed without notice and causing +uses after free. Grab a reference count to the map within the lock +region and return this. Fix up locations that need a map__put +following this. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-3-irogers@google.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes use-after-free by managing reference counts for maps in perf maps.', 'keywords': 'perf maps, reference count, use-after-free', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 659ad3492b913c9033d47cb406ac5754780875b6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 659ad3492b913c9033d47cb406ac5754780875b6 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1707770114 + Commit Message: + perf maps: Switch from rbtree to lazily sorted array for addresses + +Maps is a collection of maps primarily sorted by the starting address +of the map. Prior to this change the maps were held in an rbtree +requiring 4 pointers per node. Prior to reference count checking + Parent Hashes: 39d14c0dd650f3de62242c2f92fb4d7a0ec3386a + Refs: the +rbnode was embedded in the map so 3 pointers per node were +necessary. This change switches the rbtree to an array lazily sorted +by address + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit switches perf maps from using an rbtree to a lazily sorted array for better memory efficiency.', 'keywords': 'perf maps,rbtree,lazily sorted array', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 68bc61c26cacf152baf905786b5949769700f40d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 68bc61c26cacf152baf905786b5949769700f40d + Author Name: Marco Elver + Author Email: elver@google.com + Commit Date: 1707689184 + Commit Message: + bpf: Allow compiler to inline most of bpf_local_storage_lookup() + +In various performance profiles of kernels with BPF programs attached + Parent Hashes: a7170d81e0002345576b5f87a5890d91bc06c106 + Refs: +bpf_local_storage_lookup() appears as a significant portion of CPU +cycles spent. To enable the compiler generate more optimal code + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable compiler to inline bpf_local_storage_lookup() for improved performance in BPF programs.', 'keywords': 'compiler,inlining,performance', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d27553c14f06f4db61cb9ddaf88e8d4df91d740c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d27553c14f06f4db61cb9ddaf88e8d4df91d740c + Author Name: Jinjian Song + Author Email: jinjian.song@fibocom.com + Commit Date: 1707480468 + Commit Message: + net: wwan: t7xx: Infrastructure for early port configuration + +To support cases such as FW update or Core dump + Parent Hashes: 409c38d4f156740bf3165fd6ceae4fa6425eebf4 + Refs: the t7xx +device is capable of signaling the host that a special port +needs to be created before the handshake phase. + +Adds the infrastructure required to create the early ports +which also requires a different configuration of CLDMA queues. + +Base on the v5 patch version of follow series: +'net: wwan: t7xx: fw flashing & coredump support' +(https://patchwork.kernel.org/project/netdevbpf/patch/3777bb382f4b0395cb594a602c5c79dbab86c9e0.1674307425.git.m.chetan.kumar@linux.intel.com/) + +Signed-off-by: Jinjian Song +Signed-off-by: David S. Miller + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds early port infrastructure for t7xx device in network subsystem, supporting firmware updates and core dumps.', 'keywords': 'early port infrastructure, firmware update, core dump', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: a7170d81e0002345576b5f87a5890d91bc06c106 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a7170d81e0002345576b5f87a5890d91bc06c106 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1707421218 + Commit Message: + Merge branch 'bpf + Parent Hashes: e55dad12abe42383b68ba88212eb3d0fba0e9820 947e56f82fd783a1ec1c9359b20b5699d09cae14 + Refs: btf: Add DEBUG_INFO_BTF checks for __register_bpf_struct_ops' + +Geliang Tang says: + +==================== +bpf: Add DEBUG_INFO_BTF checks for __register_bpf_struct_ops + +This patch set avoids module loading failure when the module +trying to register a struct_ops and the module has its btf section +stripped. This will then work similarly as module kfunc registration in +commit 3de4d22cc9ac ("bpf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix module loading issues by adding DEBUG_INFO_BTF checks for struct_ops registration in eBPF.', 'keywords': 'DEBUG_INFO_BTF, struct_ops, module', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 947e56f82fd783a1ec1c9359b20b5699d09cae14 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 947e56f82fd783a1ec1c9359b20b5699d09cae14 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1707421069 + Commit Message: + bpf + Parent Hashes: 9e60b0e02550aaf5f2301e49353641a5e3701674 + Refs: btf: Check btf for register_bpf_struct_ops + +Similar to the handling in the functions __register_btf_kfunc_id_set() +and register_btf_id_dtor_kfuncs() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add btf check for register_bpf_struct_ops aligning with similar btf use in registration functions.', 'keywords': 'btf, register, struct_ops', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9e60b0e02550aaf5f2301e49353641a5e3701674 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9e60b0e02550aaf5f2301e49353641a5e3701674 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1707420176 + Commit Message: + bpf + Parent Hashes: b9a395f0f7af66fe8224450481b99d4f83b57207 + Refs: btf: Add check_btf_kconfigs helper + +This patch extracts duplicate code on error path when btf_get_module_btf() +returns NULL from the functions __register_btf_kfunc_id_set() and +register_btf_id_dtor_kfuncs() into a new helper named check_btf_kconfigs() +to check CONFIG_DEBUG_INFO_BTF and CONFIG_DEBUG_INFO_BTF_MODULES in it. + +Signed-off-by: Geliang Tang +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/r/fa5537fc55f1e4d0bfd686598c81b7ab9dbd82b7.1707373307.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor error handling with check_btf_kconfigs helper for BTF module support.', 'keywords': 'duplicated, error, helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b9a395f0f7af66fe8224450481b99d4f83b57207 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b9a395f0f7af66fe8224450481b99d4f83b57207 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1707419107 + Commit Message: + bpf + Parent Hashes: e55dad12abe42383b68ba88212eb3d0fba0e9820 + Refs: btf: Fix return value of register_btf_id_dtor_kfuncs + +The same as __register_btf_kfunc_id_set() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes the return value handling for BTF ID destructor kfuncs registration in BPF.', 'keywords': 'BTF, return value, kfuncs', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 03fa49a386b298d357b90c9c5599f8d00dfc425c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 03fa49a386b298d357b90c9c5599f8d00dfc425c + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1707388402 + Commit Message: + Merge branch 'cpsw-enable-mac_managed_pm-to-fix-mdio' + +Sinthu Raja says: + +==================== +CPSW: enable mac_managed_pm to fix mdio + +This patch fix the resume/suspend issue on CPSW interface. + +Reference from the foloowing patchwork: +https://lore.kernel.org/netdev/20221014144729.1159257-2-shenwei.wang@nxp.com/T/ + +V1: https://patchwork.kernel.org/project/netdevbpf/patch/20240122083414.6246-1-sinthu.raja@ti.com/ +V2: https://patchwork.kernel.org/project/netdevbpf/patch/20240122093326.7618-1-sinthu.raja@ti.com/ +==================== + +Link: https://lore.kernel.org/r/20240206005928.15703-1-sinthu.raja@ti.com +Signed-off-by: Paolo Abeni + + Parent Hashes: 335bac1daae3fd9070d0f9f34d7d7ba708729256 bc4ce46b1e3d1da4309405cd4afc7c0fcddd0b90 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix resume/suspend issue on CPSW interface by enabling mac_managed_pm.', 'keywords': 'CPSW,mac_managed_pm,MDIO', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 79d72c68c58784a3e1cd2378669d51bfd0cb7498 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 79d72c68c58784a3e1cd2378669d51bfd0cb7498 + Author Name: Oscar Salvador + Author Email: osalvador@suse.de + Commit Date: 1707369636 + Commit Message: + fs + Parent Hashes: f2076032096775d1bb1af16b6eddbc6534575328 + Refs: hugetlb: fix NULL pointer dereference in hugetlbs_fill_super + +When configuring a hugetlb filesystem via the fsconfig() syscall + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a NULL pointer dereference in hugetlb filesystem configuration using fsconfig() syscall.', 'keywords': 'NULL pointer, hugetlb, fsconfig', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e55dad12abe42383b68ba88212eb3d0fba0e9820 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e55dad12abe42383b68ba88212eb3d0fba0e9820 + Author Name: Masahiro Yamada + Author Email: masahiroy@kernel.org + Commit Date: 1707352700 + Commit Message: + bpf: Merge two CONFIG_BPF entries + +'config BPF' exists in both init/Kconfig and kernel/bpf/Kconfig. + +Commit b24abcff918a ("bpf + Parent Hashes: ba6a6abb3bfa8377bcf386a11077c0533909f9e8 + Refs: kconfig: Add consolidated menu entry for bpf +with core options") added the second one to kernel/bpf/Kconfig instead +of moving the existing one. + +Merge them together. + +Signed-off-by: Masahiro Yamada +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240204075634.32969-1-masahiroy@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge two CONFIG_BPF entries from init/Kconfig and kernel/bpf/Kconfig into one.', 'keywords': 'CONFIG_BPF,Kconfig,merge', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: ba6a6abb3bfa8377bcf386a11077c0533909f9e8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ba6a6abb3bfa8377bcf386a11077c0533909f9e8 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1707351259 + Commit Message: + selftests/bpf: Mark cpumask kfunc declarations as __weak + +After the series "Annotate kfuncs in .BTF_ids section"[0] + Parent Hashes: a2bff65cfca93f0fe4c5996f55ce8f413e85e4fe + Refs: kfuncs can be +generated from bpftool. Let's mark the existing cpumask kfunc declarations +__weak so they don't conflict with definitions that will eventually come +from vmlinux.h. + +[0]. https://lore.kernel.org/all/cover.1706491398.git.dxu@dxuuu.xyz + +Suggested-by: Andrii Nakryiko +Signed-off-by: Yafang Shao +Signed-off-by: Andrii Nakryiko +Acked-by: Daniel Xu +Link: https://lore.kernel.org/bpf/20240206081416.26242-5-laoar.shao@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Mark cpumask kfunc declarations as __weak to avoid conflicts with future vmlinux.h definitions.', 'keywords': 'cpumask,kfunc,weak', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a2bff65cfca93f0fe4c5996f55ce8f413e85e4fe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a2bff65cfca93f0fe4c5996f55ce8f413e85e4fe + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1707351259 + Commit Message: + selftests/bpf: Fix error checking for cpumask_success__load() + +We should verify the return value of cpumask_success__load(). + +Signed-off-by: Yafang Shao +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240206081416.26242-4-laoar.shao@gmail.com + + Parent Hashes: abae1ac5231e56ecc3932f83f2de13701070803a + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added error checking for cpumask_success__load() in the selftests/bpf tests.', 'keywords': 'error checking,selftests,bpf', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: abae1ac5231e56ecc3932f83f2de13701070803a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: abae1ac5231e56ecc3932f83f2de13701070803a + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707350178 + Commit Message: + Merge branch 'tools-resolve_btfids-fix-cross-compilation-to-non-host-endianness' + +Viktor Malik says: + +==================== +tools/resolve_btfids: fix cross-compilation to non-host endianness + +The .BTF_ids section is pre-filled with zeroed BTF ID entries during the +build and afterwards patched by resolve_btfids with correct values. +Since resolve_btfids always writes in host-native endianness + Parent Hashes: 92a871ab9fa59a74d013bc04f321026a057618e7 903fad4394666bc23975c93fb58f137ce64b5192 + Refs: it relies +on libelf to do the translation when the target ELF is cross-compiled to +a different endianness (this was introduced in commit 61e8aeda9398 +("bpf: Fix libelf endian handling in resolv_btfids")). + +Unfortunately + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes cross-compilation of BTF ID entries in non-host endianness.', 'keywords': 'cross-compilation,BTF,endianness', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 903fad4394666bc23975c93fb58f137ce64b5192 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 903fad4394666bc23975c93fb58f137ce64b5192 + Author Name: Viktor Malik + Author Email: vmalik@redhat.com + Commit Date: 1707350178 + Commit Message: + tools/resolve_btfids: Fix cross-compilation to non-host endianness + +The .BTF_ids section is pre-filled with zeroed BTF ID entries during the +build and afterwards patched by resolve_btfids with correct values. +Since resolve_btfids always writes in host-native endianness + Parent Hashes: 9707ac4fe2f5bac6406d2403f8b8a64d7b3d8e43 + Refs: it relies +on libelf to do the translation when the target ELF is cross-compiled to +a different endianness (this was introduced in commit 61e8aeda9398 +("bpf: Fix libelf endian handling in resolv_btfids")). + +Unfortunately + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes cross-compilation issue in resolve_btfids for non-host endianness by correcting BTF ID entry handling.', 'keywords': 'cross-compilation,endian,BTF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9707ac4fe2f5bac6406d2403f8b8a64d7b3d8e43 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9707ac4fe2f5bac6406d2403f8b8a64d7b3d8e43 + Author Name: Viktor Malik + Author Email: vmalik@redhat.com + Commit Date: 1707350178 + Commit Message: + tools/resolve_btfids: Refactor set sorting with types from btf_ids.h + +Instead of using magic offsets to access BTF ID set data + Parent Hashes: 92a871ab9fa59a74d013bc04f321026a057618e7 + Refs: leverage types +from btf_ids.h (btf_id_set and btf_id_set8) which define the actual +layout of the data. Thanks to this change + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor tools/resolve_btfids to use type definitions from btf_ids.h for set sorting.', 'keywords': 'refactor,BTF ID,tools', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 92a871ab9fa59a74d013bc04f321026a057618e7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 92a871ab9fa59a74d013bc04f321026a057618e7 + Author Name: Toke Høiland-Jørgensen + Author Email: toke@redhat.com + Commit Date: 1707241886 + Commit Message: + libbpf: Use OPTS_SET() macro in bpf_xdp_query() + +When the feature_flags and xdp_zc_max_segs fields were added to the libbpf +bpf_xdp_query_opts + Parent Hashes: c27aa462aa78ff157fdda222af242e4571803d4a + Refs: the code writing them did not use the OPTS_SET() macro. +This causes libbpf to write to those fields unconditionally + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit updates libbpf's bpf_xdp_query function to use the OPTS_SET() macro for feature_flags and xdp_zc_max_segs fields.", 'keywords': 'libbpf, OPTS_SET, bpf_xdp_query', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: c27aa462aa78ff157fdda222af242e4571803d4a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c27aa462aa78ff157fdda222af242e4571803d4a + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1707241225 + Commit Message: + bpf: Use -Wno-address-of-packed-member in some selftests + +[Differences from V2: +- Remove conditionals in the source files pragmas + Parent Hashes: 563918a0e3afd97bcfb680b72c52ec080c82aea6 + Refs: as the + pragma is supported by both GCC and clang.] + +Both GCC and clang implement the -Wno-address-of-packed-member +warning + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Suppress the address-of-packed-member warning in certain BPF selftests using specific compiler flags.', 'keywords': 'compiler, selftests, warning', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 563918a0e3afd97bcfb680b72c52ec080c82aea6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 563918a0e3afd97bcfb680b72c52ec080c82aea6 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1707234299 + Commit Message: + bpf + Parent Hashes: c7dcb6c9aa85fa310251dad7e233eb955a5235ed + Refs: docs: Fix typos in instructions-set.rst + +* "imm32" should just be "imm" +* Add blank line to fix formatting error reported by Stephen Rothwell [0] + +[0]: https://lore.kernel.org/bpf/20240206153301.4ead0bad@canb.auug.org.au/T/#u + +Signed-off-by: Dave Thaler +Acked-by: David Vernet +Link: https://lore.kernel.org/r/20240206045146.4965-1-dthaler1968@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix typos and formatting errors in BPF documentation files.', 'keywords': 'typos, formatting, documentation', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c7dcb6c9aa85fa310251dad7e233eb955a5235ed +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c7dcb6c9aa85fa310251dad7e233eb955a5235ed + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707192158 + Commit Message: + selftests/bpf: mark dynptr kfuncs __weak to make them optional on old kernels + +Mark dynptr kfuncs as __weak to allow +verifier_global_subprogs/arg_ctx_{perf + Parent Hashes: d7bc416aa5cc183691287e8f0b1d5b182a7ce9c3 + Refs: kprobe + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Mark dynamic pointer kfuncs as __weak to ensure compatibility with older kernels in BPF selftests.', 'keywords': 'dynptr, optional, kfuncs', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: d7bc416aa5cc183691287e8f0b1d5b182a7ce9c3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d7bc416aa5cc183691287e8f0b1d5b182a7ce9c3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1707192106 + Commit Message: + libbpf: fix return value for PERF_EVENT __arg_ctx type fix up check + +If PERF_EVENT program has __arg_ctx argument with matching +architecture-specific pt_regs/user_pt_regs/user_regs_struct pointer +type + Parent Hashes: 6146fae67bc2b92100bff8b2d6a6d5bca07edcf8 + Refs: libbpf should still perform type rewrite for old kernels + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes return value handling for type fix-up check in libbpf for PERF_EVENT programs.', 'keywords': 'libbpf,return value,PERF_EVENT', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 20a286c1a35ba4dc2fca5d4c1fb2e7ced101e576 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 20a286c1a35ba4dc2fca5d4c1fb2e7ced101e576 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1707192014 + Commit Message: + Merge branch 'transfer-rcu-lock-state-across-subprog-calls' + +Kumar Kartikeya Dwivedi says: + +==================== +Transfer RCU lock state across subprog calls + +David suggested during the discussion in [0] that we should handle RCU +locks in a similar fashion to spin locks where the verifier understands +when a lock held in a caller is released in callee + Parent Hashes: 8244ab509f89d63941d5ee207967c5a3e00bb493 8be6a0147af314fd60db9da2158cd737dc6394a7 + Refs: or lock taken in +callee is released in a caller + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implements transfer of RCU lock state across subprogram calls in eBPF verifier.', 'keywords': 'RCU,verifier,locks', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8be6a0147af314fd60db9da2158cd737dc6394a7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8be6a0147af314fd60db9da2158cd737dc6394a7 + Author Name: Kumar Kartikeya Dwivedi + Author Email: memxor@gmail.com + Commit Date: 1707192014 + Commit Message: + selftests/bpf: Add tests for RCU lock transfer between subprogs + +Add selftests covering the following cases: +- A static or global subprog called from within a RCU read section works +- A static subprog taking an RCU read lock which is released in caller works +- A static subprog releasing the caller's RCU read lock works + +Global subprogs that leave the lock in an imbalanced state will not +work + Parent Hashes: 6fceea0fa59f6786a2847a4cae409117624e8b58 + Refs: as they are verified separately + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for RCU lock handling in static or global subprograms within BPF programs.', 'keywords': 'selftests, RCU lock, subprograms', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 6fceea0fa59f6786a2847a4cae409117624e8b58 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6fceea0fa59f6786a2847a4cae409117624e8b58 + Author Name: Kumar Kartikeya Dwivedi + Author Email: memxor@gmail.com + Commit Date: 1707192014 + Commit Message: + bpf: Transfer RCU lock state between subprog calls + +Allow transferring an imbalanced RCU lock state between subprog calls +during verification. This allows patterns where a subprog call returns +with an RCU lock held + Parent Hashes: 8244ab509f89d63941d5ee207967c5a3e00bb493 + Refs: or a subprog call releases an RCU lock held by +the caller. Currently + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable transferring imbalanced RCU lock state between subprogram calls during eBPF verification.', 'keywords': 'RCU lock,state transfer,subprog calls', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8244ab509f89d63941d5ee207967c5a3e00bb493 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8244ab509f89d63941d5ee207967c5a3e00bb493 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1707191927 + Commit Message: + Merge branch 'enable-static-subprog-calls-in-spin-lock-critical-sections' + +Kumar Kartikeya Dwivedi says: + +==================== +Enable static subprog calls in spin lock critical sections + +This set allows a BPF program to make a call to a static subprog within +a bpf_spin_lock critical section. This problem has been hit in sched-ext +and ghOSt [0] as well + Parent Hashes: 2d9a925d0fbf0dae99af148adaf4f5cadf1be5e0 e8699c4ff85baedcf40f33db816cc487cee39397 + Refs: and is mostly an annoyance which is worked around +by inling the static subprog into the critical section. + +In case of sched-ext + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable static subprog calls within bpf_spin_lock critical sections in eBPF programs.', 'keywords': 'static subprog, spin lock, eBPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['scheduler like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e8699c4ff85baedcf40f33db816cc487cee39397 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e8699c4ff85baedcf40f33db816cc487cee39397 + Author Name: Kumar Kartikeya Dwivedi + Author Email: memxor@gmail.com + Commit Date: 1707191927 + Commit Message: + selftests/bpf: Add test for static subprog call in lock cs + +Add selftests for static subprog calls within bpf_spin_lock critical +section + Parent Hashes: a44b1334aadd82203f661adb9adb41e53ad0e8d1 + Refs: and ensure we still reject global subprog calls. Also test the +case where a subprog call will unlock the caller's held lock + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds selftests for static subprogram calls within bpf_spin_lock critical section.', 'keywords': 'selftests, subprog, bpf_spin_lock', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a44b1334aadd82203f661adb9adb41e53ad0e8d1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a44b1334aadd82203f661adb9adb41e53ad0e8d1 + Author Name: Kumar Kartikeya Dwivedi + Author Email: memxor@gmail.com + Commit Date: 1707191927 + Commit Message: + bpf: Allow calling static subprogs while holding a bpf_spin_lock + +Currently + Parent Hashes: 2d9a925d0fbf0dae99af148adaf4f5cadf1be5e0 + Refs: calling any helpers + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit allows calling static subprograms while holding a bpf_spin_lock in eBPF programs.', 'keywords': 'bpf_spin_lock,static subprograms,eBPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['xdp like programs', 'tc/netfilter like programs', 'tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 2d9a925d0fbf0dae99af148adaf4f5cadf1be5e0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2d9a925d0fbf0dae99af148adaf4f5cadf1be5e0 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1707173085 + Commit Message: + bpf + Parent Hashes: e7f31873176a345d72ca77c7b4da48493ccd9efd + Refs: docs: Expand set of initial conformance groups + +This patch attempts to update the ISA specification according +to the latest mailing list discussion about conformance groups + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update the ISA specification with changes from latest mailing list discussion on conformance groups.', 'keywords': 'ISA,specification,conformance', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e7f31873176a345d72ca77c7b4da48493ccd9efd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e7f31873176a345d72ca77c7b4da48493ccd9efd + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1707160416 + Commit Message: + selftests/bpf: Fix flaky selftest lwt_redirect/lwt_reroute + +Recently + Parent Hashes: 169e650069647325496e5a65408ff301874c8e01 + Refs: when running './test_progs -j' + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a flaky selftest for lwt_redirect and lwt_reroute in the BPF testing suite.', 'keywords': 'flaky,selftest,lwt_redirect', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs', 'tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 169e650069647325496e5a65408ff301874c8e01 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 169e650069647325496e5a65408ff301874c8e01 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1707159158 + Commit Message: + selftests/bpf: Suppress warning message of an unused variable. + +"r" is used to receive the return value of test_2 in bpf_testmod.c + Parent Hashes: 7e428638bd784fd9e8944bfbf11513520e141b91 + Refs: but it +is not actually used. So + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Suppress unused variable warning in bpf_testmod.c selftest.', 'keywords': 'selftests,bpf,unused variable', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7e428638bd784fd9e8944bfbf11513520e141b91 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7e428638bd784fd9e8944bfbf11513520e141b91 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1707158921 + Commit Message: + selftests/bpf: Fix flaky test ptr_untrusted + +Somehow recently I frequently hit the following test failure +with either ./test_progs or ./test_progs-cpuv4: + serial_test_ptr_untrusted:PASS:skel_open 0 nsec + serial_test_ptr_untrusted:PASS:lsm_attach 0 nsec + serial_test_ptr_untrusted:PASS:raw_tp_attach 0 nsec + serial_test_ptr_untrusted:FAIL:cmp_tp_name unexpected cmp_tp_name: actual -115 != expected 0 + #182 ptr_untrusted:FAIL + +Further investigation found the failure is due to + bpf_probe_read_user_str() +where reading user-level string attr->raw_tracepoint.name +is not successfully + Parent Hashes: df9705eaa0bad034dad0f73386ff82f5c4dd7e24 + Refs: most likely due to the +string itself still in disk and not populated into memory yet. + +One solution is do a printf() call of the string before doing bpf +syscall which will force the raw_tracepoint.name into memory. +But I think a more robust solution is to use bpf_copy_from_user() +which is used in sleepable program and can tolerate page fault + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a flaky test caused by bpf_probe_read_user_str() failure in ptr_untrusted.', 'keywords': 'flaky,test,bpf_probe_read_user_str', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: df9705eaa0bad034dad0f73386ff82f5c4dd7e24 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: df9705eaa0bad034dad0f73386ff82f5c4dd7e24 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1707157508 + Commit Message: + bpf: Remove an unnecessary check. + +The "i" here is always equal to "btf_type_vlen(t)" since +the "for_each_member()" loop never breaks. + +Signed-off-by: Kui-Feng Lee +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240203055119.2235598-1-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 2a79690eae953daaac232f93e6c5ac47ac539f2d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed an unnecessary check in bpf code related to loop iteration.', 'keywords': 'unnecessary, check, loop', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a8882313c5640103f93a07cf352f6ccf8e7defc3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a8882313c5640103f93a07cf352f6ccf8e7defc3 + Author Name: David S. Miller + Author Email: davem@davemloft.net + Commit Date: 1707136767 + Commit Message: + Merge branch 'qca8k-cleanup-fixes' + +Vladimir Oltean says: + +==================== +Fixups for qca8k ds->user_mii_bus cleanup + +The series "ds->user_mii_bus cleanup (part 1)" from the last development +cycle: +https://patchwork.kernel.org/project/netdevbpf/cover/20240104140037.374166-1-vladimir.oltean@nxp.com/ + +had some review comments I didn't have the time to address at the time. +One from Alvin and one from Luiz. They can reasonably be treated as +improvements for v6.9. +==================== + +Signed-off-by: David S. Miller + + Parent Hashes: 0cd216d769fbd161c06f5a702bf7a951f276f558 709776ea85625fb668ced6b97b005cf53612996e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit merges cleanup and fix improvements for qca8k driver user MII bus implementation.', 'keywords': 'qca8k,cleanup,fixes', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: aad98efd0b121f63a2e1c221dcb4d4850128c697 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: aad98efd0b121f63a2e1c221dcb4d4850128c697 + Author Name: Naveen N Rao + Author Email: naveen@kernel.org + Commit Date: 1707133399 + Commit Message: + powerpc/64: Set task pt_regs->link to the LR value on scv entry + +Nysal reported that userspace backtraces are missing in offcputime bcc +tool. As an example: + $ sudo ./bcc/tools/offcputime.py -uU + Tracing off-CPU time (us) of user threads by user stack... Hit Ctrl-C to end. + + ^C + write + - python (9107) + 8 + + write + - sudo (9105) + 9 + + mmap + - python (9107) + 16 + + clock_nanosleep + - multipathd (697) + 3001604 + +The offcputime bcc tool attaches a bpf program to a kprobe on +finish_task_switch() + Parent Hashes: ed8b94f6e0acd652ce69bd69d678a0c769172df8 + Refs: which is usually hit on a syscall from userspace. +With the switch to system call vectored + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes the missing userspace backtraces in offcputime bcc tool by setting task pt_regs->link to the LR value on scv entry for powerpc.', 'keywords': 'offcputime, backtraces, powerpc', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 1eb986746a67952df86eb2c50a36450ef103d01b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1eb986746a67952df86eb2c50a36450ef103d01b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706926139 + Commit Message: + bpf: don't emit warnings intended for global subprogs for static subprogs + +When btf_prepare_func_args() was generalized to handle both static and +global subprogs + Parent Hashes: e2e70535dd76c6f17bdc9009ffca3d26cfd35ea4 + Refs: a few warnings/errors that are meant only for global +subprog cases started to be emitted for static subprogs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit stops warnings for global subprograms from being emitted for static subprograms in bpf.', 'keywords': 'warnings, global, subprograms', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e2e70535dd76c6f17bdc9009ffca3d26cfd35ea4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e2e70535dd76c6f17bdc9009ffca3d26cfd35ea4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706926138 + Commit Message: + selftests/bpf: add more cases for __arg_trusted __arg_nullable args + +Add extra layer of global functions to ensure that passing around +(trusted) PTR_TO_BTF_ID_OR_NULL registers works as expected. We also +extend trusted_task_arg_nullable subtest to check three possible valid +argumements: known NULL + Parent Hashes: 8f13c34087d3eb64329529b8517e5a6251653176 + Refs: known non-NULL + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added tests for handling __arg_trusted and __arg_nullable argument cases in BPF selftests.', 'keywords': 'tests,selftests,arguments', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8f13c34087d3eb64329529b8517e5a6251653176 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8f13c34087d3eb64329529b8517e5a6251653176 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706926138 + Commit Message: + bpf: handle trusted PTR_TO_BTF_ID_OR_NULL in argument check logic + +Add PTR_TRUSTED | PTR_MAYBE_NULL modifiers for PTR_TO_BTF_ID to +check_reg_type() to support passing trusted nullable PTR_TO_BTF_ID +registers into global functions accepting `__arg_trusted __arg_nullable` +arguments. This hasn't been caught earlier because tests were either +passing known non-NULL PTR_TO_BTF_ID registers or known NULL (SCALAR) +registers. + +When utilizing this functionality in complicated real-world BPF +application that passes around PTR_TO_BTF_ID_OR_NULL + Parent Hashes: a68b50f47bec8bd6a33b07b7e1562db2553981a7 + Refs: it became apparent +that verifier rejects valid case because check_reg_type() doesn't handle +this case explicitly. Existing check_reg_type() logic is already +anticipating this combination + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances argument check logic in eBPF verifier to support trusted nullable PTR_TO_BTF_ID registers.', 'keywords': 'PTR_TO_BTF_ID, trusted, nullable', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['kprobe/uprobe/ftrace like programs', 'tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ffd856537b95dd65facb4e0c78ca1cb92c2048ff +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ffd856537b95dd65facb4e0c78ca1cb92c2048ff + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@kernel.org + Commit Date: 1706925837 + Commit Message: + perf bpf: Clean up the generated/copied vmlinux.h + +When building perf with BPF skels we either copy the minimalistic +tools/perf/util/bpf_skel/vmlinux/vmlinux.h or use bpftool to generate a +vmlinux from BTF + Parent Hashes: b8db070f389c902f48e83ee7a94952e9557199e8 + Refs: storing the result in $(SKEL_OUT)/vmlinux.h. + +We need to remove that when doing a 'make -C tools/perf clean' + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit cleans up the generated/copied vmlinux.h file when cleaning the perf build directory.', 'keywords': 'perf,BPF,vmlinux.h', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a68b50f47bec8bd6a33b07b7e1562db2553981a7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a68b50f47bec8bd6a33b07b7e1562db2553981a7 + Author Name: Shung-Hsi Yu + Author Email: shung-hsi.yu@suse.com + Commit Date: 1706912043 + Commit Message: + selftests/bpf: trace_helpers.c: do not use poisoned type + +After commit c698eaebdf47 ("selftests/bpf: trace_helpers.c: Optimize +kallsyms cache") trace_helpers.c now includes libbpf_internal.h + Parent Hashes: 6fb3f72702fba97323a89e53f484de58bc59d13c + Refs: and +thus can no longer use the u32 type (among others) since they are poison +in libbpf_internal.h. Replace u32 with __u32 to fix the following error +when building trace_helpers.c on powerpc: + + error: attempt to use poisoned "u32" + +Fixes: c698eaebdf47 ("selftests/bpf: trace_helpers.c: Optimize kallsyms cache") +Signed-off-by: Shung-Hsi Yu +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/r/20240202095559.12900-1-shung-hsi.yu@suse.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replace poisoned u32 type with __u32 in trace_helpers.c to fix build error.', 'keywords': 'poisoned,u32,trace_helpers', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6fb3f72702fba97323a89e53f484de58bc59d13c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6fb3f72702fba97323a89e53f484de58bc59d13c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706908935 + Commit Message: + Merge branch 'improvements-for-tracking-scalars-in-the-bpf-verifier' + +Maxim Mikityanskiy says: + +==================== +Improvements for tracking scalars in the BPF verifier + +From: Maxim Mikityanskiy + +The goal of this series is to extend the verifier's capabilities of +tracking scalars when they are spilled to stack + Parent Hashes: 943b043aeecce9accb6d367af47791c633e95e4d 73a28d9d000e8d20b4b3c516b74ee92afe3ae4be + Refs: especially when the +spill or fill is narrowing. It also contains a fix by Eduard for +infinite loop detection and a state pruning optimization by Eduard that +compensates for a verification complexity regression introduced by +tracking unbounded scalars. These improvements reduce the surface of +false rejections that I saw while working on Cilium codebase. + +Patches 1-9 of the original series were previously applied in v2. + +Patches 1-2 (Maxim): Support the case when boundary checks are first +performed after the register was spilled to the stack. + +Patches 3-4 (Maxim): Support narrowing fills. + +Patches 5-6 (Eduard): Optimization for state pruning in stacksafe() to +mitigate the verification complexity regression. + +veristat -e file + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves scalar tracking in the BPF verifier, including state pruning optimization for verification complexity regression.', 'keywords': 'scalar tracking, BPF verifier, optimization', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 73a28d9d000e8d20b4b3c516b74ee92afe3ae4be +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 73a28d9d000e8d20b4b3c516b74ee92afe3ae4be + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1706908934 + Commit Message: + selftests/bpf: States pruning checks for scalar vs STACK_MISC + +Check that stacksafe() compares spilled scalars with STACK_MISC. +The following combinations are explored: +- old spill of imprecise scalar is equivalent to cur STACK_{MISC + Parent Hashes: 6efbde200bf3cf2dbf6e7181893fed13a79c789b + Refs: INVALID} + (plus error in unpriv mode); +- old spill of precise scalar is not equivalent to cur STACK_MISC; +- old STACK_MISC is equivalent to cur scalar; +- old STACK_MISC is not equivalent to cur non-scalar. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240127175237.526726-7-maxtram95@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for checking stack safety with scalar and STACK_MISC comparisons in eBPF.', 'keywords': 'selftests,stack,scalar', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6efbde200bf3cf2dbf6e7181893fed13a79c789b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6efbde200bf3cf2dbf6e7181893fed13a79c789b + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1706908934 + Commit Message: + bpf: Handle scalar spill vs all MISC in stacksafe() + +When check_stack_read_fixed_off() reads value from an spi +all stack slots of which are set to STACK_{MISC + Parent Hashes: 067313a85c6f213932518f12f628810f0092492b + Refs: INVALID} + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes handling of scalar spills vs all MISC states in stacksafe checks in eBPF.', 'keywords': 'scalar,spill,stacksafe', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 067313a85c6f213932518f12f628810f0092492b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 067313a85c6f213932518f12f628810f0092492b + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706908934 + Commit Message: + selftests/bpf: Add test cases for narrowing fill + +The previous commit allowed to preserve boundaries and track IDs of +scalars on narrowing fills. Add test cases for that pattern. + +Signed-off-by: Maxim Mikityanskiy +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20240127175237.526726-5-maxtram95@gmail.com + + Parent Hashes: c1e6148cb4f83cec841db1f066e8db4a86c1f118 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test cases for handling narrowing fill patterns in eBPF selftests.', 'keywords': 'test cases,narrowing fill,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c1e6148cb4f83cec841db1f066e8db4a86c1f118 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c1e6148cb4f83cec841db1f066e8db4a86c1f118 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706908934 + Commit Message: + bpf: Preserve boundaries and track scalars on narrowing fill + +When the width of a fill is smaller than the width of the preceding +spill + Parent Hashes: 6be503cec6c9bccd64f72c03697011d2e2b96fc3 + Refs: the information about scalar boundaries can still be preserved + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit preserves boundaries and tracks scalars when narrowing fills in eBPF programs.', 'keywords': 'preserve, boundaries, scalars', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6be503cec6c9bccd64f72c03697011d2e2b96fc3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6be503cec6c9bccd64f72c03697011d2e2b96fc3 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706908934 + Commit Message: + selftests/bpf: Test tracking spilled unbounded scalars + +The previous commit added tracking for unbounded scalars on spill. Add +the test case to check the new functionality. + +Signed-off-by: Maxim Mikityanskiy +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20240127175237.526726-3-maxtram95@gmail.com + + Parent Hashes: e67ddd9b1cff7872d43ead73a1403c4e532003d9 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test case to validate the functionality of tracking spilled unbounded scalars in selftests for BPF.', 'keywords': 'test, unbounded scalars, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e67ddd9b1cff7872d43ead73a1403c4e532003d9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e67ddd9b1cff7872d43ead73a1403c4e532003d9 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706908934 + Commit Message: + bpf: Track spilled unbounded scalars + +Support the pattern where an unbounded scalar is spilled to the stack + Parent Hashes: 943b043aeecce9accb6d367af47791c633e95e4d + Refs: +then boundary checks are performed on the src register + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit tracks spilled unbounded scalars to improve boundary checks for src registers in BPF programs.', 'keywords': 'spilled, scalars, unbounded', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 943b043aeecce9accb6d367af47791c633e95e4d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 943b043aeecce9accb6d367af47791c633e95e4d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706822172 + Commit Message: + selftests/bpf: Fix bench runner SIGSEGV + +Some benchmarks don't have either "consumer" or "producer" sides. For +example + Parent Hashes: b9551da8cf3ade01a50316df8a618fd945723ee0 + Refs: trig-tp and other BPF triggering benchmarks don't have +consumers + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a segmentation fault in the selftests benchmark runner due to missing consumer or producer sides.', 'keywords': 'selftests, benchmark, SIGSEGV', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: b9551da8cf3ade01a50316df8a618fd945723ee0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b9551da8cf3ade01a50316df8a618fd945723ee0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706822172 + Commit Message: + libbpf: Add missed btf_ext__raw_data() API + +Another API that was declared in libbpf.map but actual implementation +was missing. btf_ext__get_raw_data() was intended as a discouraged alias +to consistently-named btf_ext__raw_data() + Parent Hashes: c81a8ab196b5083d5109a51585fcc24fa2055a77 + Refs: so make this an actuality. + +Fixes: 20eccf29e297 ("libbpf: hide and discourage inconsistently named getters") +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20240201172027.604869-5-andrii@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add implementation of missing btf_ext__raw_data() API in libbpf.', 'keywords': 'libbpf, API, implementation', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c81a8ab196b5083d5109a51585fcc24fa2055a77 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c81a8ab196b5083d5109a51585fcc24fa2055a77 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706822172 + Commit Message: + libbpf: Add btf__new_split() API that was declared but not implemented + +Seems like original commit adding split BTF support intended to add +btf__new_split() API + Parent Hashes: 93ee1eb85e28d1e35bb059c1f5965d65d5fc83c2 + Refs: and even declared it in libbpf.map + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit implements the previously declared but unimplemented btf__new_split() API in libbpf.', 'keywords': 'libbpf BTF API', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 93ee1eb85e28d1e35bb059c1f5965d65d5fc83c2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 93ee1eb85e28d1e35bb059c1f5965d65d5fc83c2 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706822171 + Commit Message: + libbpf: Add missing LIBBPF_API annotation to libbpf_set_memlock_rlim API + +LIBBPF_API annotation seems missing on libbpf_set_memlock_rlim API + Parent Hashes: 9fa5e1a180aa639fb156a16e453ab820b7e7860b + Refs: so +add it to make this API callable from libbpf's shared library version. + +Fixes: e542f2c4cd16 ("libbpf: Auto-bump RLIMIT_MEMLOCK if kernel needs it for BPF") +Fixes: ab9a5a05dc48 ("libbpf: fix up few libbpf.map problems") +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20240201172027.604869-3-andrii@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add missing LIBBPF_API annotation to libbpf_set_memlock_rlim for shared library usage.', 'keywords': 'LIBBPF_API, libbpf, memlock', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9fa5e1a180aa639fb156a16e453ab820b7e7860b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9fa5e1a180aa639fb156a16e453ab820b7e7860b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706822171 + Commit Message: + libbpf: Call memfd_create() syscall directly + +Some versions of Android do not implement memfd_create() wrapper in +their libc implementation + Parent Hashes: 1581e5118e485e82cfb5d04d636a79aaefb6f266 + Refs: leading to build failures ([0]). On the other +hand + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit modifies libbpf to call the memfd_create syscall directly to avoid build issues on some Android platforms.', 'keywords': 'libbpf, memfd_create, Android', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 5c24e4e9e70822cf49955fc8174bc5efaa93d17f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5c24e4e9e70822cf49955fc8174bc5efaa93d17f + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1706811574 + Commit Message: + Merge tag 'hid-for-linus-2024020101' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid + +Pull HID fixes from Benjamin Tissoires: + + - cleanups in the error path in hid-steam (Dan Carpenter) + + - fixes for Wacom tablets selftests that sneaked in while the CI was + taking a break during the year end holidays (Benjamin Tissoires) + + - null pointer check in nvidia-shield (Kunwu Chan) + + - memory leak fix in hidraw (Su Hui) + + - another null pointer fix in i2c-hid-of (Johan Hovold) + + - another memory leak fix in HID-BPF this time + Parent Hashes: f6cdd897cc7030a573f56ab1e9ebaece26c7c10c 764ad6b02777d77dca3659ca490f0898aa593670 + Refs: as well as a double + fdget() fix reported by Dan Carpenter (Benjamin Tissoires) + + - fix for Cirque touchpad when they go on suspend (Kai-Heng Feng) + + - new device ID in hid-logitech-hidpp: "Logitech G Pro X SuperLight 2" + (Jiri Kosina) + +* tag 'hid-for-linus-2024020101' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid: + HID: bpf: use __bpf_kfunc instead of noinline + HID: bpf: actually free hdev memory after attaching a HID-BPF program + HID: bpf: remove double fdget() + HID: i2c-hid-of: fix NULL-deref on failed power up + HID: hidraw: fix a problem of memory leak in hidraw_release() + HID: i2c-hid: Skip SET_POWER SLEEP for Cirque touchpad on system suspend + HID: nvidia-shield: Add missing null pointer checks to LED initialization + HID: logitech-hidpp: add support for Logitech G Pro X Superlight 2 + selftests/hid: wacom: fix confidence tests + HID: hid-steam: Fix cleanup in probe() + HID: hid-steam: remove pointless error message + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit merges HID fixes including memory leak and null pointer checks for various devices.', 'keywords': 'HID, fixes, memory', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 1581e5118e485e82cfb5d04d636a79aaefb6f266 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1581e5118e485e82cfb5d04d636a79aaefb6f266 + Author Name: Matt Bobrowski + Author Email: mattbobrowski@google.com + Commit Date: 1706809065 + Commit Message: + bpf: Minor clean-up to sleepable_lsm_hooks BTF set + +There's already one main CONFIG_SECURITY_NETWORK ifdef block within +the sleepable_lsm_hooks BTF set. Consolidate this duplicated ifdef +block as there's no need for it and all things guarded by it should +remain in one place in this specific context. + +Signed-off-by: Matt Bobrowski +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/Zbt1smz43GDMbVU3@google.com + + Parent Hashes: 994ff2f7973982af286608da10c295383650fc28 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Consolidate duplicated ifdef blocks in sleepable_lsm_hooks BTF set for cleaner code structure.', 'keywords': 'clean-up, ifdef, BTF', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: e0526ec5360a48ad3ab2e26e802b0532302a7e11 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e0526ec5360a48ad3ab2e26e802b0532302a7e11 + Author Name: Souradeep Chakrabarti + Author Email: schakrabarti@linux.microsoft.com + Commit Date: 1706805223 + Commit Message: + hv_netvsc: Fix race condition between netvsc_probe and netvsc_remove + +In commit ac5047671758 ("hv_netvsc: Disable NAPI before closing the +VMBus channel") + Parent Hashes: 7b55984c96ffe9e236eb9c82a2196e0b1f84990d + Refs: napi_disable was getting called for all channels + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a race condition between netvsc_probe and netvsc_remove in hv_netvsc driver.', 'keywords': 'hv_netvsc,race condition,probe', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 6a9d552483d50953320b9d3b57abdee8d436f23f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6a9d552483d50953320b9d3b57abdee8d436f23f + Author Name: Sean Young + Author Email: sean@mess.org + Commit Date: 1706791737 + Commit Message: + media: rc: bpf attach/detach requires write permission + +Note that bpf attach/detach also requires CAP_NET_ADMIN. + +Cc: stable@vger.kernel.org +Signed-off-by: Sean Young +Signed-off-by: Mauro Carvalho Chehab + + Parent Hashes: f66556c1333b3bd4806fc98ee07c419ab545e6ee + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit requires write permission for bpf attach/detach operations in media rc subsystem.', 'keywords': 'bpf,attach,permission', 'commit_classification': "It's a security fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 994ff2f7973982af286608da10c295383650fc28 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 994ff2f7973982af286608da10c295383650fc28 + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706783748 + Commit Message: + selftests/bpf: Enable inline bpf_kptr_xchg() test for RV64 + +Enable inline bpf_kptr_xchg() test for RV64 + Parent Hashes: 69065aa11ca680d76a6c6bc088aa0f0abe24afdb + Refs: and the test have passed as +show below: + +Summary: 1/0 PASSED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable inline bpf_kptr_xchg() test for RV64 architecture in selftests.', 'keywords': 'bpf_kptr_xchg RV64 selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 69065aa11ca680d76a6c6bc088aa0f0abe24afdb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 69065aa11ca680d76a6c6bc088aa0f0abe24afdb + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706783748 + Commit Message: + riscv + Parent Hashes: 088a464ed53feeab9632c6748b9f25354639e2bd + Refs: bpf: Enable inline bpf_kptr_xchg() for RV64 + +RV64 JIT supports 64-bit BPF_XCHG atomic instructions. At the same time + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable inline bpf_kptr_xchg() support for RV64 JIT with 64-bit atomic instructions.', 'keywords': 'RV64,JIT,BPF_XCHG', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 088a464ed53feeab9632c6748b9f25354639e2bd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 088a464ed53feeab9632c6748b9f25354639e2bd + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1706783533 + Commit Message: + bpf + Parent Hashes: 8263b3382d8c1af0fffa27095a9f1db6f2dad899 + Refs: docs: Clarify which legacy packet instructions existed + +As discussed on the BPF IETF mailing list (see link) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit clarifies documentation regarding legacy packet instructions discussed on the BPF IETF mailing list.', 'keywords': 'docs, packet, instructions', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 8263b3382d8c1af0fffa27095a9f1db6f2dad899 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8263b3382d8c1af0fffa27095a9f1db6f2dad899 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1706782425 + Commit Message: + libbpf: Remove unnecessary null check in kernel_supports() + +After recent changes + Parent Hashes: b3d3e29376a3f898bc90063a1e8c36c76cea1901 + Refs: Coverity complained about inconsistent null checks +in kernel_supports() function: + + kernel_supports(const struct bpf_object *obj + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit removes an unnecessary null check in the kernel_supports() function in libbpf.', 'keywords': 'null check, libbpf, kernel_supports', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b3d3e29376a3f898bc90063a1e8c36c76cea1901 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b3d3e29376a3f898bc90063a1e8c36c76cea1901 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1706762456 + Commit Message: + Merge branch 'annotate-kfuncs-in-btf_ids-section' + +Daniel Xu says: + +==================== +Annotate kfuncs in .BTF_ids section + +=== Description === + +This is a bpf-treewide change that annotates all kfuncs as such inside +.BTF_ids. This annotation eventually allows us to automatically generate +kfunc prototypes from bpftool. + +We store this metadata inside a yet-unused flags field inside struct +btf_id_set8 (thanks Kumar!). pahole will be taught where to look. + +More details about the full chain of events are available in commit 3's +description. + +The accompanying pahole and bpftool changes can be viewed +here on these "frozen" branches [0][1]. + +[0]: https://github.com/danobi/pahole/tree/kfunc_btf-v3-mailed +[1]: https://github.com/danobi/linux/tree/kfunc_bpftool-mailed + +=== Changelog === + +Changes from v3: +* Rebase to bpf-next and add missing annotation on new kfunc + +Changes from v2: +* Only WARN() for vmlinux kfuncs + +Changes from v1: +* Move WARN_ON() up a call level +* Also return error when kfunc set is not properly tagged +* Use BTF_KFUNCS_START/END instead of flags +* Rename BTF_SET8_KFUNC to BTF_SET8_KFUNCS +==================== + +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/r/cover.1706491398.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 2ef61296d2844c6a4211e07ab70ef2fb412b2c30 6f3189f38a3e995232e028a4c341164c4aca1b20 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit annotates kfuncs in the .BTF_ids section for automatic kfunc prototype generation with bpftool.', 'keywords': 'kfuncs,BTF_ids,bpftool', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6f3189f38a3e995232e028a4c341164c4aca1b20 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6f3189f38a3e995232e028a4c341164c4aca1b20 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1706762456 + Commit Message: + bpf: treewide: Annotate BPF kfuncs in BTF + +This commit marks kfuncs as such inside the .BTF_ids section. The upshot +of these annotations is that we'll be able to automatically generate +kfunc prototypes for downstream users. The process is as follows: + +1. In source + Parent Hashes: a05e90427ef6706f59188b379ad6366b9d298bc5 + Refs: use BTF_KFUNCS_START/END macro pair to mark kfuncs +2. During build + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Annotate BPF kfuncs in BTF to enable automatic kfunc prototype generation for downstream users.', 'keywords': 'kfuncs,BTF,annotations', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a05e90427ef6706f59188b379ad6366b9d298bc5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a05e90427ef6706f59188b379ad6366b9d298bc5 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1706762452 + Commit Message: + bpf: btf: Add BTF_KFUNCS_START/END macro pair + +This macro pair is functionally equivalent to BTF_SET8_START/END + Parent Hashes: 79b47344bbc5a693a92ed6b2b09dac59254bfac8 + Refs: except +with BTF_SET8_KFUNCS flag set in the btf_id_set8 flags field. The next +commit will codemod all kfunc set8s to this new variant such that all +kfuncs are tagged as such in .BTF_ids section. + +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/d536c57c7c2af428686853cc7396b7a44faa53b7.1706491398.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add BTF_KFUNCS_START/END macro pair for improved kfunc tagging in BTF_ids section.', 'keywords': 'BTF,KFUNCS,macro', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 79b47344bbc5a693a92ed6b2b09dac59254bfac8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 79b47344bbc5a693a92ed6b2b09dac59254bfac8 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1706731524 + Commit Message: + bpf: btf: Support flags for BTF_SET8 sets + +This commit adds support for flags on BTF_SET8s. struct btf_id_set8 +already supported 32 bits worth of flags + Parent Hashes: 2ef61296d2844c6a4211e07ab70ef2fb412b2c30 + Refs: but was only used for +alignment purposes before. + +We now use these bits to encode flags. The first use case is tagging +kfunc sets with a flag so that pahole can recognize which +BTF_ID_FLAGS(func + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds support for flags in BTF_SET8 structures, enabling flag tagging for kfunc sets.', 'keywords': 'BTF_SET8, flags, kfunc', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2ef61296d2844c6a4211e07ab70ef2fb412b2c30 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2ef61296d2844c6a4211e07ab70ef2fb412b2c30 + Author Name: Manu Bretelle + Author Email: chantr4@gmail.com + Commit Date: 1706721243 + Commit Message: + selftests/bpf: Disable IPv6 for lwt_redirect test + +After a recent change in the vmtest runner + Parent Hashes: e4009250574c69d2a3dd838af81cc3d4d72058e4 + Refs: this test started failing +sporadically. + +Investigation showed that this test was subject to race condition which +got exacerbated after the vm runner change. The symptoms being that the +logic that waited for an ICMPv4 packet is naive and will break if 5 or +more non-ICMPv4 packets make it to tap0. +When ICMPv6 is enabled + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Disable IPv6 in lwt_redirect test due to race conditions causing sporadic failures.', 'keywords': 'selftests, IPv6, race condition', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 764ad6b02777d77dca3659ca490f0898aa593670 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 764ad6b02777d77dca3659ca490f0898aa593670 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1706693228 + Commit Message: + HID: bpf: use __bpf_kfunc instead of noinline + +Follow the docs at Documentation/bpf/kfuncs.rst: +- declare the function with `__bpf_kfunc` +- disables missing prototype warnings + Parent Hashes: 89be8aa5b0ecb3b729c7bcff64bb2af7921fec63 + Refs: which allows to remove them from + include/linux/hid-bpf.h + +Removing the prototypes is not an issue because we currently have to +redeclare them when writing the BPF program. They will eventually be +generated by bpftool directly AFAIU. + +Link: https://lore.kernel.org/r/20240124-b4-hid-bpf-fixes-v2-3-052520b1e5e6@kernel.org +Signed-off-by: Benjamin Tissoires + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit replaces noinline with __bpf_kfunc for HID related BPF functions to align with documentation and streamline prototype handling.', 'keywords': 'HID, __bpf_kfunc, prototype', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 89be8aa5b0ecb3b729c7bcff64bb2af7921fec63 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 89be8aa5b0ecb3b729c7bcff64bb2af7921fec63 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1706693225 + Commit Message: + HID: bpf: actually free hdev memory after attaching a HID-BPF program + +Turns out that I got my reference counts wrong and each successful +bus_find_device() actually calls get_device() + Parent Hashes: 7cdd2108903a4e369eb37579830afc12a6877ec2 + Refs: and we need to manually +call put_device(). + +Ensure each bus_find_device() gets a matching put_device() when releasing +the bpf programs and fix all the error paths. + +Cc: +Fixes: f5c27da4e3c8 ("HID: initial BPF implementation") +Link: https://lore.kernel.org/r/20240124-b4-hid-bpf-fixes-v2-2-052520b1e5e6@kernel.org +Signed-off-by: Benjamin Tissoires + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes memory leak by ensuring each bus_find_device() call is matched with a put_device() call in HID-BPF implementation.', 'keywords': 'memory, HID-BPF, bus_find_device', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 7cdd2108903a4e369eb37579830afc12a6877ec2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7cdd2108903a4e369eb37579830afc12a6877ec2 + Author Name: Benjamin Tissoires + Author Email: bentiss@kernel.org + Commit Date: 1706693220 + Commit Message: + HID: bpf: remove double fdget() + +When the kfunc hid_bpf_attach_prog() is called + Parent Hashes: 00aab7dcb2267f2aef59447602f34501efe1a07f + Refs: we called twice fdget(): +one for fetching the type of the bpf program + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed redundant fdget() call in hid_bpf_attach_prog() function.', 'keywords': 'HID,bpf,fdget', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: e4009250574c69d2a3dd838af81cc3d4d72058e4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e4009250574c69d2a3dd838af81cc3d4d72058e4 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1706658959 + Commit Message: + Merge branch 'libbpf: add bpf_core_cast() helper' + +Andrii Nakryiko says: + +==================== +Add bpf_core_cast( + Parent Hashes: 4d8ebe1304e99cf6e08e432c23041638d6d1de56 ea9d561686fbd0e1ddf05d861d8f2c1ae8291870 + Refs: ) macro wrapper around bpf_rdonly_cast() kfunc +to make it easier to use this functionality in BPF code. See patch #2 for +BPF selftests conversions demonstrating improvements in code succinctness. +==================== + +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add bpf_core_cast() macro in libbpf to simplify usage of bpf_rdonly_cast() in BPF code.', 'keywords': 'bpf_core_cast,libbpf,bpf_rdonly_cast', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ea9d561686fbd0e1ddf05d861d8f2c1ae8291870 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ea9d561686fbd0e1ddf05d861d8f2c1ae8291870 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706658950 + Commit Message: + selftests/bpf: convert bpf_rdonly_cast() uses to bpf_core_cast() macro + +Use more ergonomic bpf_core_cast() macro instead of bpf_rdonly_cast() in +selftests code. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240130212023.183765-3-andrii@kernel.org +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 20d59ee55172fdf6072abf871fa62b2070d6383f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates selftests to use bpf_core_cast() instead of bpf_rdonly_cast() for better ergonomics.', 'keywords': 'bpf_core_cast,selftests,ergonomic', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 20d59ee55172fdf6072abf871fa62b2070d6383f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 20d59ee55172fdf6072abf871fa62b2070d6383f + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706658950 + Commit Message: + libbpf: add bpf_core_cast() macro + +Add bpf_core_cast() macro that wraps bpf_rdonly_cast() kfunc. It's more +ergonomic than kfunc + Parent Hashes: 4d8ebe1304e99cf6e08e432c23041638d6d1de56 + Refs: as it automatically extracts btf_id with +bpf_core_type_id_kernel() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces bpf_core_cast() macro to enhance usability by wrapping bpf_rdonly_cast() kfunc in libbpf.', 'keywords': 'bpf_core_cast, ergonomic, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4207b556e62f0a8915afc5da4c5d5ad915a253a5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4207b556e62f0a8915afc5da4c5d5ad915a253a5 + Author Name: Tejun Heo + Author Email: tj@kernel.org + Commit Date: 1706658865 + Commit Message: + kernfs: RCU protect kernfs_nodes and avoid kernfs_idr_lock in kernfs_find_and_get_node_by_id() + +The BPF helper bpf_cgroup_from_id() calls kernfs_find_and_get_node_by_id() +which acquires kernfs_idr_lock + Parent Hashes: 1c9f2c7606afe149800986182638f636646dd824 + Refs: which is an non-raw non-IRQ-safe lock. This +can lead to deadlocks as bpf_cgroup_from_id() can be called from any BPF +programs including e.g. the ones that attach to functions which are holding +the scheduler rq lock. + +Consider the following BPF program: + + SEC("fentry/__set_cpus_allowed_ptr_locked") + int BPF_PROG(__set_cpus_allowed_ptr_locked + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit improves RCU protection for kernfs_nodes to avoid deadlocks in bpf_cgroup_from_id().', 'keywords': 'kernfs,RUC protection,deadlocks', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4d8ebe1304e99cf6e08e432c23041638d6d1de56 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4d8ebe1304e99cf6e08e432c23041638d6d1de56 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1706636511 + Commit Message: + Merge branch 'trusted-ptr_to_btf_id-arg-support-in-global-subprogs' + +Andrii Nakryiko says: + +==================== +Trusted PTR_TO_BTF_ID arg support in global subprogs + +This patch set follows recent changes that added btf_decl_tag-based argument +annotation support for global subprogs. This time we add ability to pass +PTR_TO_BTF_ID (BTF-aware kernel pointers) arguments into global subprograms. +We support explicitly trusted arguments only + Parent Hashes: 24219056805f3988bf93e494499b2329453fc706 c381203eadb76d5601fc04b814317e7608af5f5c + Refs: for now. + +Patch #1 adds logic for arg:trusted tag support on the verifier side. Default +semantic of such arguments is non-NULL + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit supports trusted PTR_TO_BTF_ID argument handling in global subprograms.', 'keywords': 'trusted arguments, PTR_TO_BTF_ID, global subprograms', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c381203eadb76d5601fc04b814317e7608af5f5c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c381203eadb76d5601fc04b814317e7608af5f5c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706636510 + Commit Message: + selftests/bpf: add trusted global subprog arg tests + +Add a bunch of test cases validating behavior of __arg_trusted and its +combination with __arg_nullable tag. We also validate CO-RE flavor +support by kernel for __arg_trusted args. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240130000648.2144827-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d28bb1a86e68a3d523e0acee8281bb904dd7f451 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for trusted global subprogram arguments in eBPF.', 'keywords': 'selftests,arg_trusted,CO-RE', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d28bb1a86e68a3d523e0acee8281bb904dd7f451 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d28bb1a86e68a3d523e0acee8281bb904dd7f451 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706636510 + Commit Message: + libbpf: add __arg_trusted and __arg_nullable tag macros + +Add __arg_trusted to annotate global func args that accept trusted +PTR_TO_BTF_ID arguments. + +Also add __arg_nullable to combine with __arg_trusted (and maybe other +tags in the future) to force global subprog itself (i.e. + Parent Hashes: 8f2b44cd9d69ec36c9ce9623993978babb575ee8 + Refs: callee) to do +NULL checks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces __arg_trusted and __arg_nullable tag macros for annotating global function arguments in libbpf.', 'keywords': 'libbpf, trusted, nullable', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8f2b44cd9d69ec36c9ce9623993978babb575ee8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8f2b44cd9d69ec36c9ce9623993978babb575ee8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706636510 + Commit Message: + bpf: add arg:nullable tag to be combined with trusted pointers + +Add ability to mark arg:trusted arguments with optional arg:nullable +tag to mark it as PTR_TO_BTF_ID_OR_NULL variant + Parent Hashes: e2b3c4ff5d183da6d1863c2321413406a2752e7a + Refs: which will allow +callers to pass NULL + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support for marking trusted pointer arguments as nullable in eBPF.', 'keywords': 'nullable, trusted, pointers', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e2b3c4ff5d183da6d1863c2321413406a2752e7a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e2b3c4ff5d183da6d1863c2321413406a2752e7a + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706636510 + Commit Message: + bpf: add __arg_trusted global func arg tag + +Add support for passing PTR_TO_BTF_ID registers to global subprogs. +Currently only PTR_TRUSTED flavor of PTR_TO_BTF_ID is supported. +Non-NULL semantics is assumed + Parent Hashes: 24219056805f3988bf93e494499b2329453fc706 + Refs: so caller will be forced to prove +PTR_TO_BTF_ID can't be NULL. + +Note + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Support is added for passing PTR_TO_BTF_ID registers with PTR_TRUSTED flavor to global subprogs in bpf.', 'keywords': 'PTR_TO_BTF_ID,PTR_TRUSTED,global subprogs', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 24219056805f3988bf93e494499b2329453fc706 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 24219056805f3988bf93e494499b2329453fc706 + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1706627620 + Commit Message: + bpf: Move -Wno-compare-distinct-pointer-types to BPF_CFLAGS + +Clang supports enabling/disabling certain conversion diagnostics via +the -W[no-]compare-distinct-pointer-types command line options. +Disabling this warning is required by some BPF selftests due to +-Werror. Until very recently GCC would emit these warnings +unconditionally + Parent Hashes: 27a90b14b93d3b2e1efd10764e456af7e2a42991 + Refs: which was a problem for gcc-bpf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Move Clang diagnostic flag -Wno-compare-distinct-pointer-types to BPF_CFLAGS for BPF selftests compatibility.', 'keywords': 'Clang, BPF_CFLAGS, selftests', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 27a90b14b93d3b2e1efd10764e456af7e2a42991 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 27a90b14b93d3b2e1efd10764e456af7e2a42991 + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1706627298 + Commit Message: + bpf: Build type-punning BPF selftests with -fno-strict-aliasing + +A few BPF selftests perform type punning and they may break strict +aliasing rules + Parent Hashes: 6668e818f960b0f32110a9efa7c97351a5771b35 + Refs: which are exploited by both GCC and clang by default +while optimizing. This can lead to broken compiled programs. + +This patch disables strict aliasing for these particular tests + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Disable strict aliasing in certain BPF selftests to prevent optimization-related issues by compilers.', 'keywords': 'type-punning,BPF selftests,strict-aliasing', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6668e818f960b0f32110a9efa7c97351a5771b35 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6668e818f960b0f32110a9efa7c97351a5771b35 + Author Name: Haiyue Wang + Author Email: haiyue.wang@intel.com + Commit Date: 1706587495 + Commit Message: + bpf + Parent Hashes: ff2071a7b7fd77908417603c4a785822939b3841 + Refs: token: Use BIT_ULL() to convert the bit mask + +Replace the '(1ULL << *)' with the macro BIT_ULL(nr). + +Signed-off-by: Haiyue Wang +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240127134901.3698613-1-haiyue.wang@intel.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replace bit mask calculation with BIT_ULL macro for improved readability.', 'keywords': 'BIT_ULL,macro,bit', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ff2071a7b7fd77908417603c4a785822939b3841 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ff2071a7b7fd77908417603c4a785822939b3841 + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1706575572 + Commit Message: + bpf: Generate const static pointers for kernel helpers + +The generated bpf_helper_defs.h file currently contains definitions +like this for the kernel helpers + Parent Hashes: f2e4040c82d3fddd11fa7c64e8f810e6f9cb7460 + Refs: which are static objects: + + static void *(*bpf_map_lookup_elem)(void *map + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit generates const static pointers for kernel helper functions in bpf_helper_defs.h file.', 'keywords': 'bpf, kernel helpers, pointers', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f2e4040c82d3fddd11fa7c64e8f810e6f9cb7460 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f2e4040c82d3fddd11fa7c64e8f810e6f9cb7460 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1706575362 + Commit Message: + libbpf: Add some details for BTF parsing failures + +As CONFIG_DEBUG_INFO_BTF is default off the existing "failed to find +valid kernel BTF" message makes diagnosing the kernel build issue somewhat +cryptic. Add a little more detail with the hope of helping users. + +Before: +``` +libbpf: failed to find valid kernel BTF +libbpf: Error loading vmlinux BTF: -3 +``` + +After not accessible: +``` +libbpf: kernel BTF is missing at '/sys/kernel/btf/vmlinux' + Parent Hashes: aecaa3ed48c3ae74c06f5e8ef0746b69c62397f1 + Refs: was CONFIG_DEBUG_INFO_BTF enabled? +libbpf: failed to find valid kernel BTF +libbpf: Error loading vmlinux BTF: -3 +``` + +After not readable: +``` +libbpf: failed to read kernel BTF from (/sys/kernel/btf/vmlinux): -1 +``` + +Closes: https://lore.kernel.org/bpf/CAP-5=fU+DN_+Y=Y4gtELUsJxKNDDCOvJzPHvjUVaUoeFAzNnig@mail.gmail.com/ + +Signed-off-by: Ian Rogers +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240125231840.1647951-1-irogers@google.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances error messages for BTF parsing failures to aid in diagnosing kernel build issues.', 'keywords': 'BTF,libbpf,error messages', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: aecaa3ed48c3ae74c06f5e8ef0746b69c62397f1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: aecaa3ed48c3ae74c06f5e8ef0746b69c62397f1 + Author Name: Florian Lehner + Author Email: dev@der-flo.net + Commit Date: 1706564437 + Commit Message: + perf/bpf: Fix duplicate type check + +Remove the duplicate check on type and unify result. + +Signed-off-by: Florian Lehner +Signed-off-by: Daniel Borkmann +Acked-by: Daniel Borkmann +Acked-by: Song Liu +Link: https://lore.kernel.org/bpf/20240120150920.3370-1-dev@der-flo.net + + Parent Hashes: 646751d523587cfd7ebcf1733298ecd470879eda + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove duplicate type check in perf/bpf for consistency.', 'keywords': 'perf,bpf,duplicate', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 646751d523587cfd7ebcf1733298ecd470879eda +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 646751d523587cfd7ebcf1733298ecd470879eda + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1706564328 + Commit Message: + bpf: Use -Wno-error in certain tests when building with GCC + +Certain BPF selftests contain code that + Parent Hashes: fbaf59a9f513416c05f4b4e87d26898d3dccd1cc + Refs: albeit being legal C + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add -Wno-error flag to certain BPF selftests when using GCC.', 'keywords': 'BPF selftests,GCC,-Wno-error', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fbaf59a9f513416c05f4b4e87d26898d3dccd1cc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fbaf59a9f513416c05f4b4e87d26898d3dccd1cc + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1706561312 + Commit Message: + selftests/bpf: Remove "&>" usage in the selftests + +In s390 + Parent Hashes: add9c58cd44e88a15f285945e26bf0d9d81c5890 + Refs: CI reported that the sock_iter_batch selftest +hits this error very often: + +2024-01-26T16:56:49.3091804Z Bind /proc/self/ns/net -> /run/netns/sock_iter_batch_netns failed: No such file or directory +2024-01-26T16:56:49.3149524Z Cannot remove namespace file "/run/netns/sock_iter_batch_netns": No such file or directory +2024-01-26T16:56:49.3772213Z test_sock_iter_batch:FAIL:ip netns add sock_iter_batch_netns unexpected error: 256 (errno 0) + +It happens very often in s390 but Manu also noticed it happens very +sparsely in other arch also. + +It turns out the default dash shell does not recognize "&>" +as a redirection operator + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove "&>" redirection usage in bpf selftests to address shell compatibility issues.', 'keywords': 'selftests, redirection, s390', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: add9c58cd44e88a15f285945e26bf0d9d81c5890 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: add9c58cd44e88a15f285945e26bf0d9d81c5890 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706560453 + Commit Message: + bpf: move arg:ctx type enforcement check inside the main logic loop + +Now that bpf and bpf-next trees converged and we don't run the risk of +merge conflicts + Parent Hashes: 9eea8fafe33eb70868f6ace2fc1e17c4ff5539c3 + Refs: move btf_validate_prog_ctx_type() into its most logical +place inside the main logic loop. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240125205510.3642094-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor the position of context type enforcement check inside the bpf main logic loop.', 'keywords': 'type enforcement, context, logic loop', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9eea8fafe33eb70868f6ace2fc1e17c4ff5539c3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9eea8fafe33eb70868f6ace2fc1e17c4ff5539c3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706560453 + Commit Message: + libbpf: fix __arg_ctx type enforcement for perf_event programs + +Adjust PERF_EVENT type enforcement around __arg_ctx to match exactly +what kernel is doing. + +Fixes: 76ec90a996e3 ("libbpf: warn on unexpected __arg_ctx type when rewriting BTF") +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240125205510.3642094-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 0e6d0a9d2348b64df74239e859fa9d6e86cdcdef + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes type enforcement for __arg_ctx in PERF_EVENT programs to match kernel behavior in libbpf.', 'keywords': 'libbpf, perf_event, __arg_ctx', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 0e6d0a9d2348b64df74239e859fa9d6e86cdcdef +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0e6d0a9d2348b64df74239e859fa9d6e86cdcdef + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706560453 + Commit Message: + libbpf: integrate __arg_ctx feature detector into kernel_supports() + +Now that feature detection code is in bpf-next tree + Parent Hashes: ced33f2cfa21a14a292a00e31dc9f85c1bfbda1c + Refs: integrate __arg_ctx +kernel-side support into kernel_supports() framework. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240125205510.3642094-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Integrates the __arg_ctx feature detection into the libbpf's kernel_supports framework.", 'keywords': 'libbpf,__arg_ctx,feature', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ced33f2cfa21a14a292a00e31dc9f85c1bfbda1c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ced33f2cfa21a14a292a00e31dc9f85c1bfbda1c + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1706543673 + Commit Message: + docs/bpf: Improve documentation of 64-bit immediate instructions + +For 64-bit immediate instruction + Parent Hashes: efaa47db92451608499ab7edf108bf30141c33db + Refs: 'BPF_IMM | BPF_DW | BPF_LD' and +src_reg=[0-6] + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve the documentation for 64-bit immediate instructions in eBPF.', 'keywords': 'documentation, 64-bit, instructions', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: efaa47db92451608499ab7edf108bf30141c33db +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: efaa47db92451608499ab7edf108bf30141c33db + Author Name: Menglong Dong + Author Email: dongmenglong.8@bytedance.com + Commit Date: 1706543093 + Commit Message: + bpf: Remove unused field "mod" in struct bpf_trampoline + +It seems that the field "mod" in struct bpf_trampoline is not used +anywhere after the commit 31bf1dbccfb0 ("bpf: Fix attaching +fentry/fexit/fmod_ret/lsm to modules"). So we can just remove it now. + +Fixes: 31bf1dbccfb0 ("bpf: Fix attaching fentry/fexit/fmod_ret/lsm to modules") +Signed-off-by: Menglong Dong +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/bpf/20240128055443.413291-1-dongmenglong.8@bytedance.com + + Parent Hashes: f149d03f450b4afab11f5e1ebd8fdfaf7eb24a28 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove unused "mod" field from bpf_trampoline structure for simplification.', 'keywords': 'unused field,bpf_trampoline,mod removal', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f149d03f450b4afab11f5e1ebd8fdfaf7eb24a28 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f149d03f450b4afab11f5e1ebd8fdfaf7eb24a28 + Author Name: Geliang Tang + Author Email: tanggeliang@kylinos.cn + Commit Date: 1706542889 + Commit Message: + selftests/bpf: Drop return in bpf_testmod_exit + +bpf_testmod_exit() does not need to have a return value (given the void) + Parent Hashes: 06a33d024838414432b6c0f51f994e7f1695b74f + Refs: +so this patch drops this useless 'return' in it. + +Signed-off-by: Geliang Tang +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/bpf/5765b287ea088f0c820f2a834faf9b20fb2f8215.1706442113.git.tanggeliang@kylinos.cn + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed unnecessary return statement in bpf_testmod_exit() due to void return type.', 'keywords': 'selftests,bpf,bpf_testmod_exit', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 06a33d024838414432b6c0f51f994e7f1695b74f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 06a33d024838414432b6c0f51f994e7f1695b74f + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706541933 + Commit Message: + riscv + Parent Hashes: 519fb722bea09ae2664ad21f8ef4360fb799eb2f + Refs: bpf: Optimize bswap insns with Zbb support + +Optimize bswap instructions by rev8 Zbb instruction conbined with srli +instruction. And Optimize 16-bit zero-extension with Zbb support. + +Signed-off-by: Pu Lehui +Signed-off-by: Daniel Borkmann +Tested-by: Björn Töpel +Acked-by: Björn Töpel +Link: https://lore.kernel.org/bpf/20240115131235.2914289-7-pulehui@huaweicloud.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize bswap instructions with Zbb support on RISC-V architecture.', 'keywords': 'Optimize,RISC-V,Zbb', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 519fb722bea09ae2664ad21f8ef4360fb799eb2f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 519fb722bea09ae2664ad21f8ef4360fb799eb2f + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706541933 + Commit Message: + riscv + Parent Hashes: 647b93f65daa128d9a0e4aac744a5fcf5f58b2d2 + Refs: bpf: Optimize sign-extention mov insns with Zbb support + +Add 8-bit and 16-bit sign-extention wraper with Zbb support to optimize +sign-extension mov instructions. + +Signed-off-by: Pu Lehui +Signed-off-by: Daniel Borkmann +Tested-by: Björn Töpel +Acked-by: Björn Töpel +Link: https://lore.kernel.org/bpf/20240115131235.2914289-6-pulehui@huaweicloud.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize sign-extension mov instructions on RISC-V with support for 8-bit and 16-bit Zbb extensions.', 'keywords': 'sign-extension,RISC-V,Zbb', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 647b93f65daa128d9a0e4aac744a5fcf5f58b2d2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 647b93f65daa128d9a0e4aac744a5fcf5f58b2d2 + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706541933 + Commit Message: + riscv + Parent Hashes: 361db44c3c59cde05e9926647f16255e274a37f4 + Refs: bpf: Add necessary Zbb instructions + +Add necessary Zbb instructions introduced by [0] to reduce code size and +improve performance of RV64 JIT. Meanwhile + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add Zbb instructions to enhance performance and reduce code size for RV64 JIT in RISC-V architecture.', 'keywords': 'Zbb, RV64, JIT', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 361db44c3c59cde05e9926647f16255e274a37f4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 361db44c3c59cde05e9926647f16255e274a37f4 + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706541933 + Commit Message: + riscv + Parent Hashes: 914c7a5ff18a225f7df254ae3433574f3d47b711 + Refs: bpf: Simplify sext and zext logics in branch instructions + +There are many extension helpers in the current branch instructions + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Simplify the extension logic in RISC-V branch instructions for the BPF subsystem.', 'keywords': 'riscv, simplify, branch', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 914c7a5ff18a225f7df254ae3433574f3d47b711 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 914c7a5ff18a225f7df254ae3433574f3d47b711 + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706541933 + Commit Message: + riscv + Parent Hashes: e33758f7493c9ad8cf6960bcf7c70f5761f3acfb + Refs: bpf: Unify 32-bit zero-extension to emit_zextw + +For code unification + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Unify 32-bit zero-extension code in riscv architecture.', 'keywords': 'riscv, code unification, emit_zextw', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e33758f7493c9ad8cf6960bcf7c70f5761f3acfb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e33758f7493c9ad8cf6960bcf7c70f5761f3acfb + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706541932 + Commit Message: + riscv + Parent Hashes: ad57654053805bf9a62602aaec74cc78edb6f235 + Refs: bpf: Unify 32-bit sign-extension to emit_sextw + +For code unification + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Unifies 32-bit sign-extension for the RISC-V architecture in BPF.', 'keywords': 'unify, sign-extension, riscv', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ad57654053805bf9a62602aaec74cc78edb6f235 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ad57654053805bf9a62602aaec74cc78edb6f235 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706541464 + Commit Message: + libbpf: Fix faccessat() usage on Android + +Android implementation of libc errors out with -EINVAL in faccessat() if +passed AT_EACCESS ([0]) + Parent Hashes: 29788f39a4171dd48a6d19eb78cf2ab168c4349a + Refs: this leads to ridiculous issue with libbpf +refusing to load /sys/kernel/btf/vmlinux on Androids ([1]). Fix by +detecting Android and redefining AT_EACCESS to 0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes faccessat() usage in libbpf on Android by handling AT_EACCESS error.', 'keywords': 'libbpf, Android, faccessat', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 29788f39a4171dd48a6d19eb78cf2ab168c4349a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 29788f39a4171dd48a6d19eb78cf2ab168c4349a + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@kernel.org + Commit Date: 1706540926 + Commit Message: + bpftool: Be more portable by using POSIX's basename() + +musl libc had the basename() prototype in string.h + Parent Hashes: 723de3ebef03bc14bd72531f00f9094337654009 + Refs: but this is a +glibc-ism + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve bpftool portability by using POSIX basename() function.', 'keywords': 'bpftool, portability, POSIX', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 92046e83c07b064ca65ac4ae7660a540016bdfc1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 92046e83c07b064ca65ac4ae7660a540016bdfc1 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1706332102 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-01-26 + +We've added 107 non-merge commits during the last 4 day(s) which contain +a total of 101 files changed + Parent Hashes: c09f32a859458002b40ba44fc736329a4c0fe4e5 fa7178b0f12e55a4f2d4906df3f25d6d4f88d962 + Refs: 6009 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merged branch 'for-netdev' from bpf-next with 107 new commits.", 'keywords': 'bpf-next, merge, netdev', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: d3cb3b0088ca92082e2bebc40cc6894a632173e2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d3cb3b0088ca92082e2bebc40cc6894a632173e2 + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1706306970 + Commit Message: + selftests: net: add missing required classifier + +the udpgro_fraglist self-test uses the BPF classifiers + Parent Hashes: 281cb9d65a95c00bb844f332cd187491d2d55496 + Refs: but the +current net self-test configuration does not include it + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a missing required BPF classifier for the udpgro_fraglist self-test in net self-tests.', 'keywords': 'self-test, BPF classifiers, net', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fa7178b0f12e55a4f2d4906df3f25d6d4f88d962 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fa7178b0f12e55a4f2d4906df3f25d6d4f88d962 + Author Name: Tiezhu Yang + Author Email: yangtiezhu@loongson.cn + Commit Date: 1706296172 + Commit Message: + selftests/bpf: Add missing line break in test_verifier + +There are no break lines in the test log for test_verifier #106 ~ #111 +if jit is disabled + Parent Hashes: e48f0f4a9bfed8947e4d1123e8b6a15c18ee1708 + Refs: add the missing line break at the end of printf() +to fix it. + +Without this patch: + + [root@linux bpf]# echo 0 > /proc/sys/net/core/bpf_jit_enable + [root@linux bpf]# ./test_verifier 106 + #106/p inline simple bpf_loop call SKIP (requires BPF JIT)Summary: 0 PASSED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added missing line break in test_verifier selftest to improve readability for non-JIT logs.', 'keywords': 'line break,selftests,test_verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e48f0f4a9bfed8947e4d1123e8b6a15c18ee1708 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e48f0f4a9bfed8947e4d1123e8b6a15c18ee1708 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1706292338 + Commit Message: + bpf + Parent Hashes: e6be8cd5d3cf54ccd0ae66027d6f4697b15f4c3e + Refs: docs: Clarify definitions of various instructions + +Clarify definitions of several instructions: + +* BPF_NEG does not support BPF_X +* BPF_CALL does not support BPF_JMP32 or BPF_X +* BPF_EXIT does not support BPF_X +* BPF_JA does not support BPF_X (was implied but not explicitly stated) + +Also fix a typo in the wide instruction figure where the field is +actually named "opcode" not "code". + +Signed-off-by: Dave Thaler +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240126040050.8464-1-dthaler1968@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Clarified instruction definitions in documentation and fixed typo in BPF opcode description.', 'keywords': 'documentation, instruction, typo', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e6be8cd5d3cf54ccd0ae66027d6f4697b15f4c3e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e6be8cd5d3cf54ccd0ae66027d6f4697b15f4c3e + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706244599 + Commit Message: + bpf: Fix error checks against bpf_get_btf_vmlinux(). + +In bpf_struct_ops_map_alloc + Parent Hashes: be4840b33eb2ea7d80830530aab5fcbeaa90e857 + Refs: it needs to check for NULL in the returned +pointer of bpf_get_btf_vmlinux() when CONFIG_DEBUG_INFO_BTF is not set. +ENOTSUPP is used to preserve the same behavior before the +struct_ops kmod support. + +In the function check_struct_ops_btf_id() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix NULL pointer checks for bpf_get_btf_vmlinux() in bpf_struct_ops_map_alloc.', 'keywords': 'NULL, ENOTSUPP, struct_ops', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: be4840b33eb2ea7d80830530aab5fcbeaa90e857 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: be4840b33eb2ea7d80830530aab5fcbeaa90e857 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1706241452 + Commit Message: + bpf: One more maintainer for libbpf and BPF selftests + +I've been working on BPF verifier + Parent Hashes: c8632acf193beac64bbdaebef013368c480bf74f + Refs: BPF selftests and + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added an additional maintainer for libbpf and BPF selftests.', 'keywords': 'maintainer, libbpf, selftests', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ce36ea754051cfae39eabd841f907de0e8d8a6b7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ce36ea754051cfae39eabd841f907de0e8d8a6b7 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1706227165 + Commit Message: + Merge branch 'selftests-net-a-few-fixes' + +Paolo Abeni says: + +==================== +selftests: net: a few fixes + +This series address self-tests failures for udp gro-related tests. + +The first patch addresses the main problem I observe locally - the XDP +program required by such tests + Parent Hashes: b64787840080bdbd048bb9c68222ad17236cbd7e 4acffb66630a0e4800880baa61a54ef18047ccd3 + Refs: xdp_dummy + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit integrates a series of fixes for self-tests related to udp gro and XDP programs.', 'keywords': 'self-tests, udp, XDP', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 98cb12eb52a780e682bea8372fdb2912c08132dd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 98cb12eb52a780e682bea8372fdb2912c08132dd + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1706227162 + Commit Message: + selftests: net: remove dependency on ebpf tests + +Several net tests requires an XDP program build under the ebpf +directory + Parent Hashes: b64787840080bdbd048bb9c68222ad17236cbd7e + Refs: and error out if such program is not available. + +That makes running successful net test hard + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes the dependency of net tests on building XDP programs in the ebpf directory.', 'keywords': 'selftests, net, dependency', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ecb1b8288dc7ccbdcb3b9df005fa1c0e0c0388a7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ecb1b8288dc7ccbdcb3b9df005fa1c0e0c0388a7 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1706209115 + Commit Message: + Merge tag 'net-6.8-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + "Including fixes from bpf + Parent Hashes: bdc010200eb5e2cddf1c76c83386bdde8aad0899 0a5bd0ffe790511d802e7f40898429a89e2487df + Refs: netfilter and WiFi. + + Jakub is doing a lot of work to include the self-tests in our CI + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes including BPF improvements in net-6.8-rc2.', 'keywords': 'Merge, networking, BPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', 'tc/netfilter like programs', 'other']} +-------------------- +-------------------- +Processing Commit ID: fdf8e6d18c6dcc0421d65aa6382f5a4fa0050149 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fdf8e6d18c6dcc0421d65aa6382f5a4fa0050149 + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1706178631 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-01-25 + +The following pull-request contains BPF updates for your *net* tree. + +We've added 12 non-merge commits during the last 2 day(s) which contain +a total of 13 files changed + Parent Hashes: 5e344807735023cd3a67c37a1852b849caa42620 9d71bc833f57a6549c753e37ce47136d35b67fc4 + Refs: 190 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merged BPF updates into the net tree, adding 12 commits over 13 files.', 'keywords': 'BPF, merge, net', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9d71bc833f57a6549c753e37ce47136d35b67fc4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9d71bc833f57a6549c753e37ce47136d35b67fc4 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1706142247 + Commit Message: + Merge branch 'net-bpf_xdp_adjust_tail-and-intel-mbuf-fixes' + +Maciej Fijalkowski says: + +==================== +net: bpf_xdp_adjust_tail() and Intel mbuf fixes + +Hey + Parent Hashes: 1732ebc4a26181c8f116c7639db99754b313edc8 0cbb08707c932b3f004bc1a8ec6200ef572c1f5f + Refs: + +after a break followed by dealing with sickness + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge of branch containing fixes for bpf_xdp_adjust_tail and Intel mbuf.', 'keywords': 'bpf_xdp_adjust_tail,Intel,fixes', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: fbadd83a612c3b7aad2987893faca6bd24aaebb3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fbadd83a612c3b7aad2987893faca6bd24aaebb3 + Author Name: Maciej Fijalkowski + Author Email: maciej.fijalkowski@intel.com + Commit Date: 1706142247 + Commit Message: + xdp: reflect tail increase for MEM_TYPE_XSK_BUFF_POOL + +XSK ZC Rx path calculates the size of data that will be posted to XSK Rx +queue via subtracting xdp_buff::data_end from xdp_buff::data. + +In bpf_xdp_frags_increase_tail() + Parent Hashes: 3de38c87174225487fc93befeea7d380db80aef6 + Refs: when underlying memory type of +xdp_rxq_info is MEM_TYPE_XSK_BUFF_POOL + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reflects tail increase in XDP path for MEM_TYPE_XSK_BUFF_POOL in XSK zero-copy RX path.', 'keywords': 'XDP, XSK, buffer', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 290779905d09d5fdf6caa4f58ddefc3f4db0c0a9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 290779905d09d5fdf6caa4f58ddefc3f4db0c0a9 + Author Name: Maciej Fijalkowski + Author Email: maciej.fijalkowski@intel.com + Commit Date: 1706142247 + Commit Message: + intel: xsk: initialize skb_frag_t::bv_offset in ZC drivers + +Ice and i40e ZC drivers currently set offset of a frag within +skb_shared_info to 0 + Parent Hashes: 2ee788c06493d02ee85855414cca39825e768aaf + Refs: which is incorrect. xdp_buffs that come from +xsk_buff_pool always have 256 bytes of a headroom + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Initialize skb_frag_t::bv_offset in Ice and i40e ZC drivers to ensure correct skb_shared_info handling.', 'keywords': 'ZC drivers,skb_frag_t,offset', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 2ee788c06493d02ee85855414cca39825e768aaf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2ee788c06493d02ee85855414cca39825e768aaf + Author Name: Maciej Fijalkowski + Author Email: maciej.fijalkowski@intel.com + Commit Date: 1706142246 + Commit Message: + ice: remove redundant xdp_rxq_info registration + +xdp_rxq_info struct can be registered by drivers via two functions - +xdp_rxq_info_reg() and __xdp_rxq_info_reg(). The latter one allows +drivers that support XDP multi-buffer to set up xdp_rxq_info::frag_size +which in turn will make it possible to grow the packet via +bpf_xdp_adjust_tail() BPF helper. + +Currently + Parent Hashes: 83014323c642b8faa2d64a5f303b41c019322478 + Refs: ice registers xdp_rxq_info in two spots: +1) ice_setup_rx_ring() // via xdp_rxq_info_reg() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove redundant xdp_rxq_info registration in the ice driver to optimize XDP multi-buffer usage.', 'keywords': 'xdp_rxq_info, ice, XDP', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 83014323c642b8faa2d64a5f303b41c019322478 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 83014323c642b8faa2d64a5f303b41c019322478 + Author Name: Tirthendu Sarkar + Author Email: tirthendu.sarkar@intel.com + Commit Date: 1706142246 + Commit Message: + i40e: handle multi-buffer packets that are shrunk by xdp prog + +XDP programs can shrink packets by calling the bpf_xdp_adjust_tail() +helper function. For multi-buffer packets this may lead to reduction of +frag count stored in skb_shared_info area of the xdp_buff struct. This +results in issues with the current handling of XDP_PASS and XDP_DROP +cases. + +For XDP_PASS + Parent Hashes: ad2047cf5d9313200e308612aed516548873d124 + Refs: currently skb is being built using frag count of +xdp_buffer before it was processed by XDP prog and thus will result in +an inconsistent skb when frag count gets reduced by XDP prog. To fix +this + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix handling of multi-buffer packets that are shrunk by XDP programs in the i40e driver.', 'keywords': 'XDP, multi-buffer, i40e', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: ad2047cf5d9313200e308612aed516548873d124 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ad2047cf5d9313200e308612aed516548873d124 + Author Name: Maciej Fijalkowski + Author Email: maciej.fijalkowski@intel.com + Commit Date: 1706142246 + Commit Message: + ice: work on pre-XDP prog frag count + +Fix an OOM panic in XDP_DRV mode when a XDP program shrinks a +multi-buffer packet by 4k bytes and then redirects it to an AF_XDP +socket. + +Since support for handling multi-buffer frames was added to XDP + Parent Hashes: c5114710c8ce86b8317e9b448f4fd15c711c2a82 + Refs: usage +of bpf_xdp_adjust_tail() helper within XDP program can free the page +that given fragment occupies and in turn decrease the fragment count +within skb_shared_info that is embedded in xdp_buff struct. In current +ice driver codebase + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes an OOM panic issue when shrinking multi-buffer packets in XDP_DRV mode for the ice driver.', 'keywords': 'OOM panic,XDP_DRV,multi-buffer', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: c5114710c8ce86b8317e9b448f4fd15c711c2a82 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c5114710c8ce86b8317e9b448f4fd15c711c2a82 + Author Name: Maciej Fijalkowski + Author Email: maciej.fijalkowski@intel.com + Commit Date: 1706142246 + Commit Message: + xsk: fix usage of multi-buffer BPF helpers for ZC XDP + +Currently when packet is shrunk via bpf_xdp_adjust_tail() and memory +type is set to MEM_TYPE_XSK_BUFF_POOL + Parent Hashes: f7f6aa8e24383fbb11ac55942e66da9660110f80 + Refs: null ptr dereference happens: + +[1136314.192256] BUG: kernel NULL pointer dereference + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes null pointer dereference in xsk multi-buffer BPF helpers for ZC XDP.', 'keywords': 'xsk, multi-buffer, BPF helpers', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: f7f6aa8e24383fbb11ac55942e66da9660110f80 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f7f6aa8e24383fbb11ac55942e66da9660110f80 + Author Name: Maciej Fijalkowski + Author Email: maciej.fijalkowski@intel.com + Commit Date: 1706142246 + Commit Message: + xsk: make xsk_buff_pool responsible for clearing xdp_buff::flags + +XDP multi-buffer support introduced XDP_FLAGS_HAS_FRAGS flag that is +used by drivers to notify data path whether xdp_buff contains fragments +or not. Data path looks up mentioned flag on first buffer that occupies +the linear part of xdp_buff + Parent Hashes: 269009893146c495f41e9572dd9319e787c2eba9 + Refs: so drivers only modify it there. This is +sufficient for SKB and XDP_DRV modes as usually xdp_buff is allocated on +stack or it resides within struct representing driver's queue and +fragments are carried via skb_frag_t structs. IOW + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ensures xsk_buff_pool handles the clearing of xdp_buff::flags for XDP multi-buffer support.', 'keywords': 'xdp_buff, xsk_buff_pool, flags', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: c8632acf193beac64bbdaebef013368c480bf74f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c8632acf193beac64bbdaebef013368c480bf74f + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142063 + Commit Message: + Merge branch 'bpf-token' + +Andrii Nakryiko says: + +==================== +BPF token + +This patch set is a combination of three BPF token-related patch sets ([0] + Parent Hashes: c9f115564561af63db662791e9a35fcf1dfefd2a 906ee42cb1be1152ef24465704cc89edc3f571c1 + Refs: +[1] + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge and integrate BPF token-related patch sets into the main branch.', 'keywords': 'BPF, token, merge', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 906ee42cb1be1152ef24465704cc89edc3f571c1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 906ee42cb1be1152ef24465704cc89edc3f571c1 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142063 + Commit Message: + selftests/bpf: Incorporate LSM policy to token-based tests + +Add tests for LSM interactions (both bpf_token_capable and bpf_token_cmd +LSM hooks) with BPF token in bpf() subsystem. Now child process passes +back token FD for parent to be able to do tests with token originating +in "wrong" userns. But we also create token in initns and check that +token LSMs don't accidentally reject BPF operations when capable() +checks pass without BPF token. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-31-andrii@kernel.org + + Parent Hashes: fadf54935e859c4d512aed6ad54f639b87a3b4d3 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds tests for LSM interactions with BPF tokens in the bpf() subsystem.', 'keywords': 'LSM,bpf,tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: fadf54935e859c4d512aed6ad54f639b87a3b4d3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fadf54935e859c4d512aed6ad54f639b87a3b4d3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142063 + Commit Message: + selftests/bpf: Add tests for LIBBPF_BPF_TOKEN_PATH envvar + +Add new subtest validating LIBBPF_BPF_TOKEN_PATH envvar semantics. +Extend existing test to validate that LIBBPF_BPF_TOKEN_PATH allows to +disable implicit BPF token creation by setting envvar to empty string. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-30-andrii@kernel.org + + Parent Hashes: cac270ad79afe212ed7986e8d271c72521cd8212 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new tests for validating LIBBPF_BPF_TOKEN_PATH environment variable semantics in selftests.', 'keywords': 'selftests,BPF,LIBBPF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cac270ad79afe212ed7986e8d271c72521cd8212 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cac270ad79afe212ed7986e8d271c72521cd8212 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142063 + Commit Message: + libbpf: Support BPF token path setting through LIBBPF_BPF_TOKEN_PATH envvar + +To allow external admin authority to override default BPF FS location +(/sys/fs/bpf) for implicit BPF token creation + Parent Hashes: b73d08d1318a2dde5bacbab77d0e2fd2aa47c933 + Refs: teach libbpf to recognize +LIBBPF_BPF_TOKEN_PATH envvar. If it is specified and user application +didn't explicitly specify bpf_token_path option + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for setting BPF token path via LIBBPF_BPF_TOKEN_PATH environment variable in libbpf.', 'keywords': 'libbpf, envvar, BPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b73d08d1318a2dde5bacbab77d0e2fd2aa47c933 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b73d08d1318a2dde5bacbab77d0e2fd2aa47c933 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142063 + Commit Message: + selftests/bpf: Add tests for BPF object load with implicit token + +Add a test to validate libbpf's implicit BPF token creation from default +BPF FS location (/sys/fs/bpf). Also validate that disabling this +implicit BPF token creation works. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-28-andrii@kernel.org + + Parent Hashes: d5baf0cac627fb3a00d9235955a388e5930b6d0e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add tests for validating implicit BPF token creation and disabling in libbpf.', 'keywords': 'tests, implicit token, libbpf', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d5baf0cac627fb3a00d9235955a388e5930b6d0e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d5baf0cac627fb3a00d9235955a388e5930b6d0e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142063 + Commit Message: + selftests/bpf: Add BPF object loading tests with explicit token passing + +Add a few tests that attempt to load BPF object containing privileged +map + Parent Hashes: 6b434b61b4d9e0e59f2947ce0f58f6fb4de048d8 + Refs: program + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add tests to load BPF objects with explicit token passing in selftests.', 'keywords': 'tests,BPF object,token passing', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6b434b61b4d9e0e59f2947ce0f58f6fb4de048d8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6b434b61b4d9e0e59f2947ce0f58f6fb4de048d8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + libbpf: Wire up BPF token support at BPF object level + +Add BPF token support to BPF object-level functionality. + +BPF token is supported by BPF object logic either as an explicitly +provided BPF token from outside (through BPF FS path) + Parent Hashes: f3dcee938f485cf403ba2acf1f1548afe637c904 + Refs: or implicitly +(unless prevented through bpf_object_open_opts). + +Implicit mode is assumed to be the most common one for user namespaced +unprivileged workloads. The assumption is that privileged container +manager sets up default BPF FS mount point at /sys/fs/bpf with BPF token +delegation options (delegate_{cmds + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for BPF token at the BPF object level in libbpf.', 'keywords': 'BPF token, BPF object, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f3dcee938f485cf403ba2acf1f1548afe637c904 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f3dcee938f485cf403ba2acf1f1548afe637c904 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + libbpf: Wire up token_fd into feature probing logic + +Adjust feature probing callbacks to take into account optional token_fd. +In unprivileged contexts + Parent Hashes: 05f9cdd55d61cf9c6283fd3dc0edc7cad09bd7fe + Refs: some feature detectors would fail to detect +kernel support just because BPF program + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adjust feature probing logic to incorporate optional token_fd in unprivileged contexts.', 'keywords': 'libbpf, token_fd, feature-probing', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 05f9cdd55d61cf9c6283fd3dc0edc7cad09bd7fe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 05f9cdd55d61cf9c6283fd3dc0edc7cad09bd7fe + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + libbpf: Move feature detection code into its own file + +It's quite a lot of well isolated code + Parent Hashes: d6dd1d49367ab03832b3c4b6f8211765d488c82b + Refs: so it seems like a good +candidate to move it out of libbpf.c to reduce its size. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-24-andrii@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactored libbpf by moving feature detection code to a separate file to reduce libbpf.c size.', 'keywords': 'libbpf,refactoring,feature detection', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d6dd1d49367ab03832b3c4b6f8211765d488c82b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d6dd1d49367ab03832b3c4b6f8211765d488c82b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + libbpf: Further decouple feature checking logic from bpf_object + +Add feat_supported() helper that accepts feature cache instead of +bpf_object. This allows low-level code in bpf.c to not know or care +about higher-level concept of bpf_object + Parent Hashes: ea4d587354eb5e32dfa93cebb055b072f518b193 + Refs: yet it will be able to utilize +custom feature checking in cases where BPF token might influence the +outcome. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-23-andrii@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a feat_supported() helper to decouple feature checking logic from bpf_object in libbpf.', 'keywords': 'feat_supported, feature checking, libbpf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ea4d587354eb5e32dfa93cebb055b072f518b193 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ea4d587354eb5e32dfa93cebb055b072f518b193 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + libbpf: Split feature detectors definitions from cached results + +Split a list of supported feature detectors with their corresponding +callbacks from actual cached supported/missing values. This will allow +to have more flexible per-token or per-object feature detectors in +subsequent refactorings. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-22-andrii@kernel.org + + Parent Hashes: 0350f9d99ee538f2ccf179f0216e704a5f39b317 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors libbpf feature detectors to separate definitions from cached results for improved flexibility.', 'keywords': 'libbpf,refactoring,feature detectors', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0350f9d99ee538f2ccf179f0216e704a5f39b317 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0350f9d99ee538f2ccf179f0216e704a5f39b317 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + selftests/bpf: Utilize string values for delegate_xxx mount options + +Use both hex-based and string-based way to specify delegate mount +options for BPF FS. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-21-andrii@kernel.org + + Parent Hashes: 6c1752e0b6ca8c7021d6da3926738d8d88f601a9 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates selftests to support string values for delegate mount options in BPF file system.', 'keywords': 'selftests, BPF FS, mount options', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6c1752e0b6ca8c7021d6da3926738d8d88f601a9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6c1752e0b6ca8c7021d6da3926738d8d88f601a9 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + bpf: Support symbolic BPF FS delegation mount options + +Besides already supported special "any" value and hex bit mask + Parent Hashes: aeaa97b006ddc7a8bf13e4adfdd02b3526f648a7 + Refs: support +string-based parsing of delegation masks based on exact enumerator +names. Utilize BTF information of `enum bpf_cmd` + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance BPF FS mount options to support symbolic delegation masks using BTF enum information.', 'keywords': 'BPF, symbolic, delegation', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: aeaa97b006ddc7a8bf13e4adfdd02b3526f648a7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: aeaa97b006ddc7a8bf13e4adfdd02b3526f648a7 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + bpf: Fail BPF_TOKEN_CREATE if no delegation option was set on BPF FS + +It's quite confusing in practice when it's possible to successfully +create a BPF token from BPF FS that didn't have any of delegate_xxx +mount options set up. While it's not wrong + Parent Hashes: 0054493e5141b16e316b8c52d6aa534397e48b6c + Refs: it's actually more +meaningful to reject BPF_TOKEN_CREATE with specific error code (-ENOENT) +to let user-space know that no token delegation is setup up. + +So + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fail BPF_TOKEN_CREATE if no delegation option is set on BPF FS to provide meaningful user-space error.', 'keywords': 'BPF_TOKEN_CREATE,delegation,ENOENT', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0054493e5141b16e316b8c52d6aa534397e48b6c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0054493e5141b16e316b8c52d6aa534397e48b6c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + bpf + Parent Hashes: fcb9597ff7d1f7c772c1237dd2d04dd44e622501 + Refs: selinux: Allocate bpf_security_struct per BPF token + +Utilize newly added bpf_token_create/bpf_token_free LSM hooks to +allocate struct bpf_security_struct for each BPF token object in +SELinux. This just follows similar pattern for BPF prog and map. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-18-andrii@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add LSM hooks to allocate security structure for BPF token objects in SELinux.', 'keywords': 'LSM hooks, SELinux, BPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: fcb9597ff7d1f7c772c1237dd2d04dd44e622501 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fcb9597ff7d1f7c772c1237dd2d04dd44e622501 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + selftests/bpf: Add BPF token-enabled tests + +Add a selftest that attempts to conceptually replicate intended BPF +token use cases inside user namespaced container. + +Child process is forked. It is then put into its own userns and mountns. +Child creates BPF FS context object. This ensures child userns is +captured as the owning userns for this instance of BPF FS. Given setting +delegation mount options is privileged operation + Parent Hashes: 404cbc149c3866e6ec2bfe1bce52c8864e1f81fc + Refs: we ensure that child +cannot set them. + +This context is passed back to privileged parent process through Unix +socket + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds selftests for BPF token use cases within user namespaced containers.', 'keywords': 'selftests,BPF,userns', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 404cbc149c3866e6ec2bfe1bce52c8864e1f81fc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 404cbc149c3866e6ec2bfe1bce52c8864e1f81fc + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + libbpf: Add BPF token support to bpf_prog_load() API + +Wire through token_fd into bpf_prog_load(). + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-16-andrii@kernel.org + + Parent Hashes: a3d63e85253b6c9b6aa34b99208e835358a91320 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Add BPF token support in libbpf library's bpf_prog_load() API.", 'keywords': 'BPF token support, bpf_prog_load, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a3d63e85253b6c9b6aa34b99208e835358a91320 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a3d63e85253b6c9b6aa34b99208e835358a91320 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142062 + Commit Message: + libbpf: Add BPF token support to bpf_btf_load() API + +Allow user to specify token_fd for bpf_btf_load() API that wraps +kernel's BPF_BTF_LOAD command. This allows loading BTF from unprivileged +process as long as it has BPF token allowing BPF_BTF_LOAD command + Parent Hashes: 364f848375af311150210a1ad3c5bcb800b65b48 + Refs: which +can be created and delegated by privileged process. + +Wire through new btf_flags as well + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds BPF token support to the bpf_btf_load() API for unprivileged process access to BPF_BTF_LOAD.', 'keywords': 'BPF token support, bpf_btf_load API, unprivileged access', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 364f848375af311150210a1ad3c5bcb800b65b48 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 364f848375af311150210a1ad3c5bcb800b65b48 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + libbpf: Add BPF token support to bpf_map_create() API + +Add ability to provide token_fd for BPF_MAP_CREATE command through +bpf_map_create() API. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-14-andrii@kernel.org + + Parent Hashes: 639ecd7d6247c48a0175f5b458b648f5d4b6dc34 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support for providing token_fd in BPF_MAP_CREATE using bpf_map_create() API in libbpf.', 'keywords': 'libbpf, BPF token, bpf_map_create', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 639ecd7d6247c48a0175f5b458b648f5d4b6dc34 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 639ecd7d6247c48a0175f5b458b648f5d4b6dc34 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + libbpf: Add bpf_token_create() API + +Add low-level wrapper API for BPF_TOKEN_CREATE command in bpf() syscall. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-13-andrii@kernel.org + + Parent Hashes: f568a3d49af9aed813a184353592efe29b0e3d16 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduced bpf_token_create() API as a low-level wrapper for BPF_TOKEN_CREATE syscall.', 'keywords': 'bpf_token_create, API, syscall', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f568a3d49af9aed813a184353592efe29b0e3d16 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f568a3d49af9aed813a184353592efe29b0e3d16 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf + Parent Hashes: a2431c7eabcf9bd5a1e7a1f7ecded40fdda4a8c5 + Refs: lsm: Add BPF token LSM hooks + +Wire up bpf_token_create and bpf_token_free LSM hooks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce LSM hooks for bpf_token_create and bpf_token_free in BPF.', 'keywords': 'LSM hooks, bpf_token_create, bpf_token_free', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: a2431c7eabcf9bd5a1e7a1f7ecded40fdda4a8c5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a2431c7eabcf9bd5a1e7a1f7ecded40fdda4a8c5 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf + Parent Hashes: 1b67772e4e3f16cd647b229cae95fc06d120be08 + Refs: lsm: Refactor bpf_map_alloc/bpf_map_free LSM hooks + +Similarly to bpf_prog_alloc LSM hook + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor bpf_map_alloc and bpf_map_free LSM hooks for consistency with bpf_prog_alloc.', 'keywords': 'refactor,bpf_map_alloc,LSM', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: 1b67772e4e3f16cd647b229cae95fc06d120be08 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1b67772e4e3f16cd647b229cae95fc06d120be08 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf + Parent Hashes: d79a3549754725bb90e58104417449edddf3da3d + Refs: lsm: Refactor bpf_prog_alloc/bpf_prog_free LSM hooks + +Based on upstream discussion ([0]) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor LSM hooks for bpf_prog_alloc and bpf_prog_free functions.', 'keywords': 'LSM hooks, refactor, allocation', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: d79a3549754725bb90e58104417449edddf3da3d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d79a3549754725bb90e58104417449edddf3da3d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf: Consistently use BPF token throughout BPF verifier logic + +Remove remaining direct queries to perfmon_capable() and bpf_capable() +in BPF verifier logic and instead use BPF token (if available) to make +decisions about privileges. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-9-andrii@kernel.org + + Parent Hashes: bbc1d24724e110b86a1a7c3c1724ce0d62cc1e2e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates the BPF verifier to consistently use BPF tokens for privilege checks.', 'keywords': 'BPF token, verifier, privileges', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: bbc1d24724e110b86a1a7c3c1724ce0d62cc1e2e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bbc1d24724e110b86a1a7c3c1724ce0d62cc1e2e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf: Take into account BPF token when fetching helper protos + +Instead of performing unconditional system-wide bpf_capable() and +perfmon_capable() calls inside bpf_base_func_proto() function (and other +similar ones) to determine eligibility of a given BPF helper for a given +program + Parent Hashes: caf8f28e036c4ba1e823355da6c0c01c39e70ab9 + Refs: use previously recorded BPF token during BPF_PROG_LOAD command +handling to inform the decision. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-8-andrii@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances BPF helper eligibility check using BPF token instead of global capability checks.', 'keywords': 'BPF token, helper protos, eligibility', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: caf8f28e036c4ba1e823355da6c0c01c39e70ab9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: caf8f28e036c4ba1e823355da6c0c01c39e70ab9 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf: Add BPF token support to BPF_PROG_LOAD command + +Add basic support of BPF token to BPF_PROG_LOAD. BPF_F_TOKEN_FD flag +should be set in prog_flags field when providing prog_token_fd. + +Wire through a set of allowed BPF program types and attach types + Parent Hashes: 9ea7c4bf17e39d463eb4782f948f401d9764b1b3 + Refs: +derived from BPF FS at BPF token creation time. Then make sure we +perform bpf_token_capable() checks everywhere where it's relevant. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-7-andrii@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add BPF token support to BPF_PROG_LOAD command with required security checks.', 'keywords': 'BPF token, BPF_PROG_LOAD, prog_flags', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9ea7c4bf17e39d463eb4782f948f401d9764b1b3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9ea7c4bf17e39d463eb4782f948f401d9764b1b3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf: Add BPF token support to BPF_BTF_LOAD command + +Accept BPF token FD in BPF_BTF_LOAD command to allow BTF data loading +through delegated BPF token. BPF_F_TOKEN_FD flag has to be specified +when passing BPF token FD. Given BPF_BTF_LOAD command didn't have flags +field before + Parent Hashes: a177fc2bf6fd83704854feaf7aae926b1df4f0b9 + Refs: we also add btf_flags field. + +BTF loading is a pretty straightforward operation + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add BPF token support to BPF_BTF_LOAD command for loading BTF data using delegated tokens.', 'keywords': 'BPF token, BTF_LOAD, delegation', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a177fc2bf6fd83704854feaf7aae926b1df4f0b9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a177fc2bf6fd83704854feaf7aae926b1df4f0b9 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf: Add BPF token support to BPF_MAP_CREATE command + +Allow providing token_fd for BPF_MAP_CREATE command to allow controlled +BPF map creation from unprivileged process through delegated BPF token. +New BPF_F_TOKEN_FD flag is added to specify together with BPF token FD +for BPF_MAP_CREATE command. + +Wire through a set of allowed BPF map types to BPF token + Parent Hashes: 35f96de04127d332a5c5e8a155d31f452f88c76d + Refs: derived from +BPF FS at BPF token creation time. This + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds BPF token support for controlled map creation from unprivileged processes in the BPF_MAP_CREATE command.', 'keywords': 'BPF token, BPF_MAP_CREATE, unprivileged', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 35f96de04127d332a5c5e8a155d31f452f88c76d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 35f96de04127d332a5c5e8a155d31f452f88c76d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142061 + Commit Message: + bpf: Introduce BPF token object + +Add new kind of BPF kernel object + Parent Hashes: 6fe01d3cbb924a72493eb3f4722dfcfd1c194234 + Refs: BPF token. BPF token is meant to +allow delegating privileged BPF functionality + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces a new BPF token object to delegate privileged BPF functionality.', 'keywords': 'BPF token, kernel object, privileged functionality', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 6fe01d3cbb924a72493eb3f4722dfcfd1c194234 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6fe01d3cbb924a72493eb3f4722dfcfd1c194234 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142060 + Commit Message: + bpf: Add BPF token delegation mount options to BPF FS + +Add few new mount options to BPF FS that allow to specify that a given +BPF FS instance allows creation of BPF token (added in the next patch) + Parent Hashes: ed1ad5a7415de8be121055e7ab1303d2be5407e0 + Refs: +and what sort of operations are allowed under BPF token. As such + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new mount options to BPF FS for BPF token delegation.', 'keywords': 'BPF FS,mount options,token', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ed1ad5a7415de8be121055e7ab1303d2be5407e0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ed1ad5a7415de8be121055e7ab1303d2be5407e0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706142060 + Commit Message: + bpf: Align CAP_NET_ADMIN checks with bpf_capable() approach + +Within BPF syscall handling code CAP_NET_ADMIN checks stand out a bit +compared to CAP_BPF and CAP_PERFMON checks. For the latter + Parent Hashes: c9f115564561af63db662791e9a35fcf1dfefd2a + Refs: CAP_BPF or +CAP_PERFMON are checked first + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Aligns CAP_NET_ADMIN checks with existing bpf_capable() approach for consistency in BPF syscall handling.', 'keywords': 'CAP_NET_ADMIN,bpf_capable,BPF', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c9f115564561af63db662791e9a35fcf1dfefd2a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c9f115564561af63db662791e9a35fcf1dfefd2a + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1706141979 + Commit Message: + libbpf: Ensure undefined bpf_attr field stays 0 + +The commit 9e926acda0c2 ("libbpf: Find correct module BTFs for struct_ops maps and progs.") +sets a newly added field (value_type_btf_obj_fd) to -1 in libbpf when +the caller of the libbpf's bpf_map_create did not define this field by +passing a NULL "opts" or passing in a "opts" that does not cover this +new field. OPT_HAS(opts + Parent Hashes: ce6f6cffaeaa0a3bcdafcae7fe03c68c3afae631 + Refs: field) is used to decide if the field is +defined or not: + + ((opts) && opts->sz >= offsetofend(typeof(*(opts)) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ensures that undefined bpf_attr fields in libbpf remain zero to prevent unintended behavior.', 'keywords': 'libbpf, bpf_attr, zero', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ce6f6cffaeaa0a3bcdafcae7fe03c68c3afae631 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ce6f6cffaeaa0a3bcdafcae7fe03c68c3afae631 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1706119426 + Commit Message: + selftests/bpf: Wait for the netstamp_needed_key static key to be turned on + +After the previous patch that speeded up the test (by avoiding neigh +discovery in IPv6) + Parent Hashes: 177f1d083a19af58f4b1206d299ed73689249fd8 + Refs: the BPF CI occasionally hits this error: + +rcv tstamp unexpected pkt rcv tstamp: actual 0 == expected 0 + +The test complains about the cmsg returned from the recvmsg() does not +have the rcv timestamp. Setting skb->tstamp or not is +controlled by a kernel static key "netstamp_needed_key". The static +key is enabled whenever this is at least one sk with the SOCK_TIMESTAMP +set. + +The test_redirect_dtime does use setsockopt() to turn on +the SOCK_TIMESTAMP for the reading sk. In the kernel +net_enable_timestamp() has a delay to enable the "netstamp_needed_key" +when CONFIG_JUMP_LABEL is set. This potential delay is the likely reason +for packet missing rcv timestamp occasionally. + +This patch is to create udp sockets with SOCK_TIMESTAMP set. +It sends and receives some packets until the received packet +has a rcv timestamp. It currently retries at most 5 times with 1s +in between. This should be enough to wait for the "netstamp_needed_key". +It then holds on to the socket and only closes it at the end of the test. +This guarantees that the test has the "netstamp_needed_key" key turned +on from the beginning. + +To simplify the udp sockets setup + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates selftests to ensure netstamp_needed_key static key is active for correct timestamping in tests.', 'keywords': 'selftests, netstamp_needed_key, timestamp', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 177f1d083a19af58f4b1206d299ed73689249fd8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 177f1d083a19af58f4b1206d299ed73689249fd8 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1706119426 + Commit Message: + selftests/bpf: Fix the flaky tc_redirect_dtime test + +BPF CI has been reporting the tc_redirect_dtime test failing +from time to time: + +test_inet_dtime:PASS:setns src 0 nsec +(network_helpers.c:253: errno: No route to host) Failed to connect to server +close_netns:PASS:setns 0 nsec +test_inet_dtime:FAIL:connect_to_fd unexpected connect_to_fd: actual -1 < expected 0 +test_tcp_clear_dtime:PASS:tcp ip6 clear dtime ingress_fwdns_p100 0 nsec + +The connect_to_fd failure (EHOSTUNREACH) is from the +test_tcp_clear_dtime() test and it is the very first IPv6 traffic +after setting up all the links + Parent Hashes: d47b9f68d2899b390a3655f2365f332a63396adf + Refs: addresses + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes the flaky tc_redirect_dtime test in BPF selftests due to IPv6 traffic issues.', 'keywords': 'flaky, tc_redirect_dtime, test', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d47b9f68d2899b390a3655f2365f332a63396adf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d47b9f68d2899b390a3655f2365f332a63396adf + Author Name: Dima Tisnek + Author Email: dimaqq@gmail.com + Commit Date: 1706070597 + Commit Message: + libbpf: Correct bpf_core_read.h comment wrt bpf_core_relo struct + +Past commit ([0]) removed the last vestiges of struct bpf_field_reloc + Parent Hashes: 32749605e3a9726f2cf277cbc032cf243c2da689 + Refs: +it's called struct bpf_core_relo now. + + [0] 28b93c64499a ("libbpf: Clean up and improve CO-RE reloc logging") + +Signed-off-by: Dima Tisnek +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240121060126.15650-1-dimaqq@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit corrects comments in libbpf related to struct bpf_core_relo.', 'keywords': 'libbpf, comments, bpf_core_relo', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 32749605e3a9726f2cf277cbc032cf243c2da689 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 32749605e3a9726f2cf277cbc032cf243c2da689 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706070486 + Commit Message: + Merge branch 'skip-callback-tests-if-jit-is-disabled-in-test_verifier' + +Tiezhu Yang says: + +==================== +Skip callback tests if jit is disabled in test_verifier + +Thanks very much for the feedbacks from Eduard + Parent Hashes: 8b593021319d4893a8fbeb7bd1f668657e68403c 0b50478fd8774f42721f4297293b711e17bc4b7b + Refs: John + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Skip eBPF callback tests in test_verifier when JIT is disabled.', 'keywords': 'callback,JIT,test_verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0b50478fd8774f42721f4297293b711e17bc4b7b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0b50478fd8774f42721f4297293b711e17bc4b7b + Author Name: Tiezhu Yang + Author Email: yangtiezhu@loongson.cn + Commit Date: 1706070461 + Commit Message: + selftests/bpf: Skip callback tests if jit is disabled in test_verifier + +If CONFIG_BPF_JIT_ALWAYS_ON is not set and bpf_jit_enable is 0 + Parent Hashes: 15b4f88dcc0a751f790bfea5ef9dcc6385c62236 + Refs: there +exist 6 failed tests. + + [root@linux bpf]# echo 0 > /proc/sys/net/core/bpf_jit_enable + [root@linux bpf]# echo 0 > /proc/sys/kernel/unprivileged_bpf_disabled + [root@linux bpf]# ./test_verifier | grep FAIL + #106/p inline simple bpf_loop call FAIL + #107/p don't inline bpf_loop call + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Skip callback tests in selftests/bpf if JIT is disabled in test_verifier.', 'keywords': 'skip, JIT, tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 15b4f88dcc0a751f790bfea5ef9dcc6385c62236 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 15b4f88dcc0a751f790bfea5ef9dcc6385c62236 + Author Name: Tiezhu Yang + Author Email: yangtiezhu@loongson.cn + Commit Date: 1706070377 + Commit Message: + selftests/bpf: Move is_jit_enabled() into testing_helpers + +Currently + Parent Hashes: 8b593021319d4893a8fbeb7bd1f668657e68403c + Refs: is_jit_enabled() is only used in test_progs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The function is_jit_enabled() is moved to testing_helpers for better organization in selftests.', 'keywords': 'selftests,bpf,testing_helpers', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 8b593021319d4893a8fbeb7bd1f668657e68403c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8b593021319d4893a8fbeb7bd1f668657e68403c + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1706058772 + Commit Message: + Merge branch 'Registrating struct_ops types from modules' + +Kui-Feng Lee says: + +==================== +Given the current constraints of the current implementation + Parent Hashes: b7d1af3791036a619ca8ffde5f832111b05ca833 0253e0590e2dc46996534371d56b5297099aed4e + Refs: +struct_ops cannot be registered dynamically. This presents a +significant limitation for modules like coming fuse-bpf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit addresses the limitation of dynamically registering struct_ops in eBPF modules.', 'keywords': 'struct_ops,dynamic registration,modules', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 0253e0590e2dc46996534371d56b5297099aed4e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0253e0590e2dc46996534371d56b5297099aed4e + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706058772 + Commit Message: + selftests/bpf: test case for register_bpf_struct_ops(). + +Create a new struct_ops type called bpf_testmod_ops within the bpf_testmod +module. When a struct_ops object is registered + Parent Hashes: 7c81c2490c73e614c6d48e4f339f4f224140b565 + Refs: the bpf_testmod module will +invoke test_2 from the module. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-15-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a new test case for register_bpf_struct_ops in the bpf_testmod module.', 'keywords': 'bpf_testmod,struct_ops,test case', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7c81c2490c73e614c6d48e4f339f4f224140b565 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7c81c2490c73e614c6d48e4f339f4f224140b565 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706058772 + Commit Message: + bpf: export btf_ctx_access to modules. + +The module requires the use of btf_ctx_access() to invoke +bpf_tracing_btf_ctx_access() from a module. This function is valuable for +implementing validation functions that ensure proper access to ctx. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-14-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 9e926acda0c2e21bca431a1818665ddcd6939755 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit exports btf_ctx_access to modules for implementing validation functions in eBPF.', 'keywords': 'btf_ctx_access, modules, validation', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['kprobe/uprobe/ftrace like programs', 'tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9e926acda0c2e21bca431a1818665ddcd6939755 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9e926acda0c2e21bca431a1818665ddcd6939755 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706058772 + Commit Message: + libbpf: Find correct module BTFs for struct_ops maps and progs. + +Locate the module BTFs for struct_ops maps and progs and pass them to the +kernel. This ensures that the kernel correctly resolves type IDs from the +appropriate module BTFs. + +For the map of a struct_ops object + Parent Hashes: f6be98d19985411ca1f3d53413d94d5b7f41c200 + Refs: the FD of the module BTF is set to +bpf_map to keep a reference to the module BTF. The FD is passed to the +kernel as value_type_btf_obj_fd when the struct_ops object is loaded. + +For a bpf_struct_ops prog + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ensures correct module BTFs are used for struct_ops maps and progs in libbpf.', 'keywords': 'libbpf, module BTFs, struct_ops', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f6be98d19985411ca1f3d53413d94d5b7f41c200 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f6be98d19985411ca1f3d53413d94d5b7f41c200 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706058766 + Commit Message: + bpf + Parent Hashes: 612d087d4ba54cef47946e22e5dabad762dd7ed5 + Refs: net: switch to dynamic registration + +Replace the static list of struct_ops types with per-btf struct_ops_tab to +enable dynamic registration. + +Both bpf_dummy_ops and bpf_tcp_ca now utilize the registration function +instead of being listed in bpf_struct_ops_types.h. + +Cc: netdev@vger.kernel.org +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-12-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce dynamic registration for bpf struct operations using per-btf struct_ops_tab in lieu of static listing.', 'keywords': 'dynamic registration, struct_ops, bpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['socket like programs', 'tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 612d087d4ba54cef47946e22e5dabad762dd7ed5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 612d087d4ba54cef47946e22e5dabad762dd7ed5 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056665 + Commit Message: + bpf: validate value_type + +A value_type should consist of three components: refcnt + Parent Hashes: e3f87fdfed7b770dd7066b02262b12747881e76d + Refs: state + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit ensures that value_type in eBPF is validated to contain three components including refcnt.', 'keywords': 'validate,value_type,refcnt', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e3f87fdfed7b770dd7066b02262b12747881e76d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e3f87fdfed7b770dd7066b02262b12747881e76d + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056664 + Commit Message: + bpf: hold module refcnt in bpf_struct_ops map creation and prog verification. + +To ensure that a module remains accessible whenever a struct_ops object of +a struct_ops type provided by the module is still in use. + +struct bpf_struct_ops_map doesn't hold a refcnt to btf anymore since a +module will hold a refcnt to it's btf already. But + Parent Hashes: fcc2c1fb0651477c8ed78a3a293c175ccd70697a + Refs: struct_ops programs are +different. They hold their associated btf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Ensure module refcount is maintained for struct_ops objects during map creation and program verification.', 'keywords': 'module, refcnt, struct_ops', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fcc2c1fb0651477c8ed78a3a293c175ccd70697a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fcc2c1fb0651477c8ed78a3a293c175ccd70697a + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056664 + Commit Message: + bpf: pass attached BTF to the bpf_struct_ops subsystem + +Pass the fd of a btf from the userspace to the bpf() syscall + Parent Hashes: 689423db3bda2244c24db8a64de4cdb37be1de41 + Refs: and then +convert the fd into a btf. The btf is generated from the module that +defines the target BPF struct_ops type. + +In order to inform the kernel about the module that defines the target +struct_ops type + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added functionality to pass BTF fd from userspace to bpf() syscall for struct_ops support.', 'keywords': 'BTF, struct_ops, syscall', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 689423db3bda2244c24db8a64de4cdb37be1de41 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 689423db3bda2244c24db8a64de4cdb37be1de41 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056664 + Commit Message: + bpf: lookup struct_ops types from a given module BTF. + +This is a preparation for searching for struct_ops types from a specified +module. BTF is always btf_vmlinux now. This patch passes a pointer of BTF +to bpf_struct_ops_find_value() and bpf_struct_ops_find(). Once the new +registration API of struct_ops types is used + Parent Hashes: 1338b93346587a2a6ac79bbcf55ef5b357745573 + Refs: other BTFs besides +btf_vmlinux can also be passed to them. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-8-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit prepares for searching struct_ops types from specified module BTF by passing BTF pointers to struct_ops functions.', 'keywords': 'struct_ops,BTF,module', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1338b93346587a2a6ac79bbcf55ef5b357745573 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1338b93346587a2a6ac79bbcf55ef5b357745573 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056664 + Commit Message: + bpf: pass btf object id in bpf_map_info. + +Include btf object id (btf_obj_id) in bpf_map_info so that tools (ex: +bpftools struct_ops dump) know the correct btf from the kernel to look up +type information of struct_ops types. + +Since struct_ops types can be defined and registered in a module. The +type information of a struct_ops type are defined in the btf of the +module defining it. The userspace tools need to know which btf is for +the module defining a struct_ops type. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-7-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 47f4f657acd5d04c78c5c5ac7022cba9ce3b4a7d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds btf_obj_id to bpf_map_info for proper type information lookup by tools.', 'keywords': 'btf_obj_id,bpf_map_info,struct_ops', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 47f4f657acd5d04c78c5c5ac7022cba9ce3b4a7d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 47f4f657acd5d04c78c5c5ac7022cba9ce3b4a7d + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056664 + Commit Message: + bpf: make struct_ops_map support btfs other than btf_vmlinux. + +Once new struct_ops can be registered from modules + Parent Hashes: e61995111a76633376419d1bccede8696e94e6e5 + Refs: btf_vmlinux is no +longer the only btf that struct_ops_map would face. st_map should remember +what btf it should use to get type information. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-6-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit extends struct_ops_map to support BTFs from modules beyond btf_vmlinux.', 'keywords': 'struct_ops_map,BTF,module', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e61995111a76633376419d1bccede8696e94e6e5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e61995111a76633376419d1bccede8696e94e6e5 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056664 + Commit Message: + bpf: add struct_ops_tab to btf. + +Maintain a registry of registered struct_ops types in the per-btf (module) +struct_ops_tab. This registry allows for easy lookup of struct_ops types +that are registered by a specific module. + +It is a preparation work for supporting kernel module struct_ops in a +latter patch. Each struct_ops will be registered under its own kernel +module btf and will be stored in the newly added btf->struct_ops_tab. The +bpf verifier and bpf syscall (e.g. prog and map cmd) can find the +struct_ops and its btf type/size/id... information from +btf->struct_ops_tab. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-5-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 4c5763ed996a61b51d721d0968d0df957826ea49 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds struct_ops_tab to BTF for registering and looking up struct_ops types within kernel modules.', 'keywords': 'struct_ops BTF registry', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4c5763ed996a61b51d721d0968d0df957826ea49 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4c5763ed996a61b51d721d0968d0df957826ea49 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056664 + Commit Message: + bpf + Parent Hashes: 95678395386d45fa0a075d2e7a6866326a469d76 + Refs: net: introduce bpf_struct_ops_desc. + +Move some of members of bpf_struct_ops to bpf_struct_ops_desc. type_id is +unavailabe in bpf_struct_ops anymore. Modules should get it from the btf +received by kmod's init function. + +Cc: netdev@vger.kernel.org +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-4-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates bpf_struct_ops by moving members to bpf_struct_ops_desc and modifies BTF handling.', 'keywords': 'bpf_struct_ops,bpf_struct_ops_desc,BTF', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 95678395386d45fa0a075d2e7a6866326a469d76 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 95678395386d45fa0a075d2e7a6866326a469d76 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056663 + Commit Message: + bpf: get type information with BTF_ID_LIST + +Get ready to remove bpf_struct_ops_init() in the future. By using +BTF_ID_LIST + Parent Hashes: 3b1f89e747cd4b24244f2798a35d28815b744303 + Refs: it is possible to gather type information while building +instead of runtime. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-3-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhances BTF usage by enabling type information gathering during the build to eventually remove bpf_struct_ops_init().', 'keywords': 'BTF_ID_LIST,type information,bpf_struct_ops_init', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 3b1f89e747cd4b24244f2798a35d28815b744303 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3b1f89e747cd4b24244f2798a35d28815b744303 + Author Name: Kui-Feng Lee + Author Email: thinker.li@gmail.com + Commit Date: 1706056663 + Commit Message: + bpf: refactory struct_ops type initialization to a function. + +Move the majority of the code to bpf_struct_ops_init_one() + Parent Hashes: b7d1af3791036a619ca8ffde5f832111b05ca833 + Refs: which can then +be utilized for the initialization of newly registered dynamically +allocated struct_ops types in the following patches. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-2-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor the struct_ops initialization into a dedicated function for dynamic type registration.', 'keywords': 'refactor, struct_ops, initialization', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b7d1af3791036a619ca8ffde5f832111b05ca833 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b7d1af3791036a619ca8ffde5f832111b05ca833 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1706054742 + Commit Message: + Merge branch 'bpf-add-cookies-retrieval-for-perf-kprobe-multi-links' + +Jiri Olsa says: + +==================== +bpf: Add cookies retrieval for perf/kprobe multi links + +hi + Parent Hashes: bbc094b3052647c188d6f155f5c09cb9492ce106 b0dc037399b19a777d569dbd9e2e9bbd62f3b3b1 + Refs: +this patchset adds support to retrieve cookies from existing tracing +links that still did not support it plus changes to bpftool to display +them. It's leftover we discussed some time ago [1]. + +thanks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds cookie retrieval support for perf and kprobe multi-links and updates bpftool to display them.', 'keywords': 'cookies,retrieval,bpftool', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: b0dc037399b19a777d569dbd9e2e9bbd62f3b3b1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b0dc037399b19a777d569dbd9e2e9bbd62f3b3b1 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1706054728 + Commit Message: + bpftool: Display cookie for kprobe multi link + +Displaying cookies for kprobe multi link + Parent Hashes: 54258324b934aa8552c239c443272ec7aea55285 + Refs: in plain mode: + + # bpftool link + ... + 1397: kprobe_multi prog 47532 + kretprobe.multi func_cnt 3 + addr cookie func [module] + ffffffff82b370c0 3 bpf_fentry_test1 + ffffffff82b39780 1 bpf_fentry_test2 + ffffffff82b397a0 2 bpf_fentry_test3 + +And in json mode: + + # bpftool link -j | jq + ... + { + "id": 1397 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance bpftool to display cookies for kprobe multi links in plain and JSON mode.', 'keywords': 'bpftool,kprobe,cookie', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 54258324b934aa8552c239c443272ec7aea55285 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 54258324b934aa8552c239c443272ec7aea55285 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1706054728 + Commit Message: + bpftool: Display cookie for perf event link probes + +Displaying cookie for perf event link probes + Parent Hashes: b7896486688af36e3bc5e27a6d5369cc5dcbcf69 + Refs: in plain mode: + + # bpftool link + 17: perf_event prog 90 + kprobe ffffffff82b1c2b0 bpf_fentry_test1 cookie 3735928559 + 18: perf_event prog 90 + kretprobe ffffffff82b1c2b0 bpf_fentry_test1 cookie 3735928559 + 20: perf_event prog 92 + tracepoint sched_switch cookie 3735928559 + 21: perf_event prog 93 + event software:page-faults cookie 3735928559 + 22: perf_event prog 91 + uprobe /proc/self/exe+0xd703c cookie 3735928559 + +And in json mode: + + # bpftool link -j | jq + + { + "id": 30 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a feature to display cookies for perf event links in bpftool.', 'keywords': 'bpftool, perf event, cookie', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: b7896486688af36e3bc5e27a6d5369cc5dcbcf69 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b7896486688af36e3bc5e27a6d5369cc5dcbcf69 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1706054728 + Commit Message: + selftests/bpf: Add fill_link_info test for perf event + +Adding fill_link_info test for perf event and testing we +get its values back through the bpf_link_info interface. + +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-7-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d74179708473c649c653f1db280e29875a532e99 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test case to verify bpf_link_info values for perf events.', 'keywords': 'fill_link_info, perf event, bpf_link_info', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: d74179708473c649c653f1db280e29875a532e99 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d74179708473c649c653f1db280e29875a532e99 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1706054727 + Commit Message: + selftests/bpf: Add cookies check for perf_event fill_link_info test + +Now that we get cookies for perf_event probes + Parent Hashes: 59a89706c40c153a74a3a9570b4d696cf9eebb0b + Refs: adding tests +for cookie for kprobe/uprobe/tracepoint. + +The perf_event test needs to be added completely and is coming +in following change. + +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-6-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftest for cookies check in perf_event fill_link_info for kprobe/uprobe/tracepoint.', 'keywords': 'cookies, perf_event, tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs', 'tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 59a89706c40c153a74a3a9570b4d696cf9eebb0b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 59a89706c40c153a74a3a9570b4d696cf9eebb0b + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1706054727 + Commit Message: + selftests/bpf: Add cookies check for kprobe_multi fill_link_info test + +Adding cookies check for kprobe_multi fill_link_info test + Parent Hashes: 2adb2e0fcdf3c6d8e28a5a9c33e458e1037ae5ad + Refs: +plus tests for invalid values related to cookies. + +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-5-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add cookies check and tests for kprobe_multi fill_link_info in selftests/bpf.', 'keywords': 'cookies,kprobe_multi,tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 2adb2e0fcdf3c6d8e28a5a9c33e458e1037ae5ad +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2adb2e0fcdf3c6d8e28a5a9c33e458e1037ae5ad + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1706054727 + Commit Message: + bpftool: Fix wrong free call in do_show_link + +The error path frees wrong array + Parent Hashes: 9fd112b1f82b587ffb12fb67dd032f551fdb571a + Refs: it should be ref_ctr_offsets. + +Acked-by: Yafang Shao +Reviewed-by: Quentin Monnet +Fixes: a7795698f8b6 ("bpftool: Add support to display uprobe_multi links") +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-4-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Fixed incorrect memory deallocation in bpftool's do_show_link function.", 'keywords': 'bpftool, free call, do_show_link', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9fd112b1f82b587ffb12fb67dd032f551fdb571a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9fd112b1f82b587ffb12fb67dd032f551fdb571a + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1706054727 + Commit Message: + bpf: Store cookies in kprobe_multi bpf_link_info data + +Storing cookies in kprobe_multi bpf_link_info data. The cookies +field is optional and if provided it needs to be an array of +__u64 with kprobe_multi.count length. + +Acked-by: Yafang Shao +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-3-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d5c16492c66fbfca85f36e42363d32212df5927b + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Store optional cookies array in kprobe_multi bpf_link_info data for better tracking.', 'keywords': 'cookies,kprobe_multi,bpf_link_info', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: d5c16492c66fbfca85f36e42363d32212df5927b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d5c16492c66fbfca85f36e42363d32212df5927b + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1706054727 + Commit Message: + bpf: Add cookie to perf_event bpf_link_info records + +At the moment we don't store cookie for perf_event probes + Parent Hashes: bbc094b3052647c188d6f155f5c09cb9492ce106 + Refs: +while we do that for the rest of the probes. + +Adding cookie fields to struct bpf_link_info perf event +probe records: + + perf_event.uprobe + perf_event.kprobe + perf_event.tracepoint + perf_event.perf_event + +And the code to store that in bpf_link_info struct. + +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Acked-by: Yafang Shao +Link: https://lore.kernel.org/r/20240119110505.400573-2-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add cookie field to perf_event bpf_link_info records for more event probe types.', 'keywords': 'cookie,perf_event,bpf_link_info', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs', 'tracepoints like programs', 'profile like programs']} +-------------------- +-------------------- +Processing Commit ID: bbc094b3052647c188d6f155f5c09cb9492ce106 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bbc094b3052647c188d6f155f5c09cb9492ce106 + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1706054146 + Commit Message: + bpf: Use r constraint instead of p constraint in selftests + +Some of the BPF selftests use the "p" constraint in inline assembly +snippets + Parent Hashes: 756e34da5380e4c0ed2cfbe5259e1b015567a099 + Refs: for input operands for MOV (rN = rM) instructions. + +This is mainly done via the __imm_ptr macro defined in +tools/testing/selftests/bpf/progs/bpf_misc.h: + + #define __imm_ptr(name) [name]"p"(&name) + +Example: + + int consume_first_item_only(void *ctx) + { + struct bpf_iter_num iter; + asm volatile ( + /* create iterator */ + "r1 = %[iter];" + [...] + : + : __imm_ptr(iter) + : CLOBBERS); + [...] + } + +The "p" constraint is a tricky one. It is documented in the GCC manual +section "Simple Constraints": + + An operand that is a valid memory address is allowed. This is for + ``load address'' and ``push address'' instructions. + + p in the constraint must be accompanied by address_operand as the + predicate in the match_operand. This predicate interprets the mode + specified in the match_operand as the mode of the memory reference for + which the address would be valid. + +There are two problems: + +1. It is questionable whether that constraint was ever intended to be + used in inline assembly templates + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit replaces 'p' constraint with 'r' constraint in BPF selftests inline assembly for better compatibility and correctness.", 'keywords': 'BPF,selftests,constraint', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 756e34da5380e4c0ed2cfbe5259e1b015567a099 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 756e34da5380e4c0ed2cfbe5259e1b015567a099 + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1706053984 + Commit Message: + bpf: fix constraint in test_tcpbpf_kern.c + +GCC emits a warning: + + progs/test_tcpbpf_kern.c:60:9: error: ‘op’ is used uninitialized [-Werror=uninitialized] + +when an uninialized op is used with a "+r" constraint. The + modifier +means a read-write operand + Parent Hashes: edb799035dd7d41c3e81e1bef83e2a2120b08abb + Refs: but that operand in the selftest is just +written to. + +This patch changes the selftest to use a "=r" constraint. This +pacifies GCC. + +Tested in bpf-next master. +No regressions. + +Signed-off-by: Jose E. Marchesi +Cc: Yonghong Song +Cc: Eduard Zingerman +Cc: david.faust@oracle.com +Cc: cupertino.miranda@oracle.com +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240123205624.14746-1-jose.marchesi@oracle.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed a GCC warning by changing a constraint in a selftest for BPF.', 'keywords': 'GCC, constraint, selftest', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: edb799035dd7d41c3e81e1bef83e2a2120b08abb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: edb799035dd7d41c3e81e1bef83e2a2120b08abb + Author Name: Jose E. Marchesi + Author Email: jose.marchesi@oracle.com + Commit Date: 1706053847 + Commit Message: + bpf: avoid VLAs in progs/test_xdp_dynptr.c + +VLAs are not supported by either the BPF port of clang nor GCC. The +selftest test_xdp_dynptr.c contains the following code: + + const size_t tcphdr_sz = sizeof(struct tcphdr); + const size_t udphdr_sz = sizeof(struct udphdr); + const size_t ethhdr_sz = sizeof(struct ethhdr); + const size_t iphdr_sz = sizeof(struct iphdr); + const size_t ipv6hdr_sz = sizeof(struct ipv6hdr); + + [...] + + static __always_inline int handle_ipv4(struct xdp_md *xdp + Parent Hashes: bc308d011ab8cc61bf1be15a2920bcd7d7b9b9d3 + Refs: struct bpf_dynptr *xdp_ptr) + { + __u8 eth_buffer[ethhdr_sz + iphdr_sz + ethhdr_sz]; + __u8 iph_buffer_tcp[iphdr_sz + tcphdr_sz]; + __u8 iph_buffer_udp[iphdr_sz + udphdr_sz]; + [...] + } + +The eth_buffer + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes VLAs from the test_xdp_dynptr.c to maintain compatibility with BPF port of clang and GCC.', 'keywords': 'VLAs,selftest,compatibility', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: bc308d011ab8cc61bf1be15a2920bcd7d7b9b9d3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bc308d011ab8cc61bf1be15a2920bcd7d7b9b9d3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706051627 + Commit Message: + libbpf: call dup2() syscall directly + +We've ran into issues with using dup2() API in production setting + Parent Hashes: c80c6434aaccc689b2c7ff432d43abad8f4217b2 + Refs: where +libbpf is linked into large production environment and ends up calling +unintended custom implementations of dup2(). These custom implementations +don't provide atomic FD replacement guarantees of dup2() syscall + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit alters libbpf to directly use the dup2() syscall, bypassing custom implementations causing production issues.', 'keywords': 'libbpf, dup2, syscall', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c80c6434aaccc689b2c7ff432d43abad8f4217b2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c80c6434aaccc689b2c7ff432d43abad8f4217b2 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1706051483 + Commit Message: + Merge branch 'enable-the-inline-of-kptr_xchg-for-arm64' + +Hou Tao says: + +==================== +Enable the inline of kptr_xchg for arm64 + +From: Hou Tao + +Hi + Parent Hashes: 20e109ea9842158a153b24ef42ec5cc3d44e9485 29f868887a7dd3efc6faecc6fc91b28fc25cf5b0 + Refs: + +The patch set is just a follow-up for "bpf: inline bpf_kptr_xchg()". It +enables the inline of bpf_kptr_xchg() and kptr_xchg_inline test for +arm64. + +Please see individual patches for more details. And comments are always +welcome. +==================== + +Link: https://lore.kernel.org/r/20240119102529.99581-1-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable inline support for bpf_kptr_xchg() on arm64 architecture.', 'keywords': 'bpf_kptr_xchg, inline, arm64', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 29f868887a7dd3efc6faecc6fc91b28fc25cf5b0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 29f868887a7dd3efc6faecc6fc91b28fc25cf5b0 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1706051483 + Commit Message: + selftests/bpf: Enable kptr_xchg_inline test for arm64 + +Now arm64 bpf jit has enable bpf_jit_supports_ptr_xchg() + Parent Hashes: 18a45f12d746c06b7361b0cce59cf8e8b9e38da6 + Refs: so enable +the test for arm64 as well. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20240119102529.99581-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable kptr_xchg_inline test for arm64 in bpf selftests after JIT support update.', 'keywords': 'kptr_xchg_inline, arm64, bpf_jit', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 18a45f12d746c06b7361b0cce59cf8e8b9e38da6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 18a45f12d746c06b7361b0cce59cf8e8b9e38da6 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1706051483 + Commit Message: + bpf + Parent Hashes: 20e109ea9842158a153b24ef42ec5cc3d44e9485 + Refs: arm64: Enable the inline of bpf_kptr_xchg() + +ARM64 bpf jit satisfies the following two conditions: +1) support BPF_XCHG() on pointer-sized word. +2) the implementation of xchg is the same as atomic_xchg() on + pointer-sized words. Both of these two functions use arch_xchg() to + implement the exchange. + +So enable the inline of bpf_kptr_xchg() for arm64 bpf jit. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20240119102529.99581-2-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable inline implementation of bpf_kptr_xchg for arm64 bpf jit.', 'keywords': 'bpf_kptr_xchg,ARM64,JIT', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 20e109ea9842158a153b24ef42ec5cc3d44e9485 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 20e109ea9842158a153b24ef42ec5cc3d44e9485 + Author Name: Dave Thaler + Author Email: dthaler1968@googlemail.com + Commit Date: 1706051408 + Commit Message: + bpf + Parent Hashes: b3f086a7a136d721d112f35fe4cd7272e93cf06b + Refs: docs: Clarify that MOVSX is only for BPF_X not BPF_K + +Per discussion on the mailing list at +https://mailarchive.ietf.org/arch/msg/bpf/uQiqhURdtxV_ZQOTgjCdm-seh74/ +the MOVSX operation is only defined to support register extension. + +The document didn't previously state this and incorrectly implied +that one could use an immediate value. + +Signed-off-by: Dave Thaler +Acked-by: David Vernet +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240118232954.27206-1-dthaler1968@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Clarified documentation for MOVSX operation to indicate it's only for BPF_X, not BPF_K.", 'keywords': 'MOVSX,BPF_X,BPF_K', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b3f086a7a136d721d112f35fe4cd7272e93cf06b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b3f086a7a136d721d112f35fe4cd7272e93cf06b + Author Name: Kuniyuki Iwashima + Author Email: kuniyu@amazon.com + Commit Date: 1706051283 + Commit Message: + bpf: Define struct bpf_tcp_req_attrs when CONFIG_SYN_COOKIES=n. + +kernel test robot reported the warning below: + + >> net/core/filter.c:11842:13: warning: declaration of 'struct bpf_tcp_req_attrs' will not be visible outside of this function [-Wvisibility] + 11842 | struct bpf_tcp_req_attrs *attrs + Parent Hashes: 2ce793ebe207328b1210bb53effd702740987148 + Refs: int attrs__sz) + | ^ + 1 warning generated. + +struct bpf_tcp_req_attrs is defined under CONFIG_SYN_COOKIES +but used in kfunc without the config. + +Let's move struct bpf_tcp_req_attrs definition outside of +CONFIG_SYN_COOKIES guard. + +Fixes: e472f88891ab ("bpf: tcp: Support arbitrary SYN Cookie.") +Reported-by: kernel test robot +Closes: https://lore.kernel.org/oe-kbuild-all/202401180418.CUVc0hxF-lkp@intel.com/ +Signed-off-by: Kuniyuki Iwashima +Link: https://lore.kernel.org/r/20240118211751.25790-1-kuniyu@amazon.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix visibility issue by defining struct bpf_tcp_req_attrs outside CONFIG_SYN_COOKIES guard.', 'keywords': 'struct bpf_tcp_req_attrs, visibility, CONFIG_SYN_COOKIES', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2ce793ebe207328b1210bb53effd702740987148 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2ce793ebe207328b1210bb53effd702740987148 + Author Name: Hao Sun + Author Email: sunhao.th@gmail.com + Commit Date: 1706050899 + Commit Message: + bpf: Refactor ptr alu checking rules to allow alu explicitly + +Current checking rules are structured to disallow alu on particular ptr +types explicitly + Parent Hashes: 40628f9fff73adecac77a9aa390f8016724cad99 + Refs: so default cases are allowed implicitly. This may lead +to newly added ptr types being allowed unexpectedly. So restruture it to +allow alu explicitly. The tradeoff is mainly a bit more cases added in +the switch. The following table from Eduard summarizes the rules: + + | Pointer type | Arithmetics allowed | + |---------------------+---------------------| + | PTR_TO_CTX | yes | + | CONST_PTR_TO_MAP | conditionally | + | PTR_TO_MAP_VALUE | yes | + | PTR_TO_MAP_KEY | yes | + | PTR_TO_STACK | yes | + | PTR_TO_PACKET_META | yes | + | PTR_TO_PACKET | yes | + | PTR_TO_PACKET_END | no | + | PTR_TO_FLOW_KEYS | conditionally | + | PTR_TO_SOCKET | no | + | PTR_TO_SOCK_COMMON | no | + | PTR_TO_TCP_SOCK | no | + | PTR_TO_TP_BUFFER | yes | + | PTR_TO_XDP_SOCK | no | + | PTR_TO_BTF_ID | yes | + | PTR_TO_MEM | yes | + | PTR_TO_BUF | yes | + | PTR_TO_FUNC | yes | + | CONST_PTR_TO_DYNPTR | yes | + +The refactored rules are equivalent to the original one. Note that +PTR_TO_FUNC and CONST_PTR_TO_DYNPTR are not reject here because: (1) +check_mem_access() rejects load/store on those ptrs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor ptr alu checking rules to explicitly allow certain arithmetic operations on pointer types in eBPF.', 'keywords': 'pointer, alu, refactor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 40628f9fff73adecac77a9aa390f8016724cad99 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 40628f9fff73adecac77a9aa390f8016724cad99 + Author Name: Andrey Grafin + Author Email: conquistador@yandex-team.ru + Commit Date: 1706049792 + Commit Message: + selftest/bpf: Add map_in_maps with BPF_MAP_TYPE_PERF_EVENT_ARRAY values + +Check that bpf_object__load() successfully creates map_in_maps +with BPF_MAP_TYPE_PERF_EVENT_ARRAY values. +These changes cover fix in the previous patch +"libbpf: Apply map_set_def_max_entries() for inner_maps on creation". + +A command line output is: +- w/o fix +$ sudo ./test_maps +libbpf: map 'mim_array_pe': failed to create inner map: -22 +libbpf: map 'mim_array_pe': failed to create: Invalid argument(-22) +libbpf: failed to load object './test_map_in_map.bpf.o' +Failed to load test prog + +- with fix +$ sudo ./test_maps +... +test_maps: OK + Parent Hashes: f04deb90e516e8e48bf8693397529bc942a9e80b + Refs: 0 SKIPPED + +Fixes: 646f02ffdd49 ("libbpf: Add BTF-defined map-in-map support") +Signed-off-by: Andrey Grafin +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: Hou Tao +Link: https://lore.kernel.org/bpf/20240117130619.9403-2-conquistador@yandex-team.ru +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds selftest to ensure map_in_maps with BPF_MAP_TYPE_PERF_EVENT_ARRAY values are correctly loaded.', 'keywords': 'selftest,map_in_maps,PERF_EVENT_ARRAY', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f04deb90e516e8e48bf8693397529bc942a9e80b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f04deb90e516e8e48bf8693397529bc942a9e80b + Author Name: Andrey Grafin + Author Email: conquistador@yandex-team.ru + Commit Date: 1706049792 + Commit Message: + libbpf: Apply map_set_def_max_entries() for inner_maps on creation + +This patch allows to auto create BPF_MAP_TYPE_ARRAY_OF_MAPS and +BPF_MAP_TYPE_HASH_OF_MAPS with values of BPF_MAP_TYPE_PERF_EVENT_ARRAY +by bpf_object__load(). + +Previous behaviour created a zero filled btf_map_def for inner maps and +tried to use it for a map creation but the linux kernel forbids to create +a BPF_MAP_TYPE_PERF_EVENT_ARRAY map with max_entries=0. + +Fixes: 646f02ffdd49 ("libbpf: Add BTF-defined map-in-map support") +Signed-off-by: Andrey Grafin +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: Hou Tao +Link: https://lore.kernel.org/bpf/20240117130619.9403-1-conquistador@yandex-team.ru +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 091f2bf60d52ac205c48dffcb8646ed9299078c9 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit updates libbpf to correctly set max_entries for inner maps on creation.', 'keywords': 'libbpf, inner_maps, max_entries', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 091f2bf60d52ac205c48dffcb8646ed9299078c9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 091f2bf60d52ac205c48dffcb8646ed9299078c9 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1706049792 + Commit Message: + bpf: Sync uapi bpf.h header for the tooling infra + +Both commit 91051f003948 ("tcp: Dump bound-only sockets in inet_diag.") +and commit 985b8ea9ec7e ("bpf + Parent Hashes: f98df79bf7f772597313adca2720cb38770490dd + Refs: docs: Fix bpf_redirect_peer header doc") +missed the tooling header sync. Fix it. + +Signed-off-by: Daniel Borkmann +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Sync the uapi bpf.h header for the tooling infrastructure to fix missed commits.', 'keywords': 'sync, tooling, header', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f98df79bf7f772597313adca2720cb38770490dd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f98df79bf7f772597313adca2720cb38770490dd + Author Name: Victor Stewart + Author Email: v@nametag.social + Commit Date: 1706049792 + Commit Message: + bpf + Parent Hashes: 4eaafe5a5b7b5f2fcec22914bc5b8b2d860896b7 + Refs: docs: Fix bpf_redirect_peer header doc + +Amend the bpf_redirect_peer() header documentation to also mention +support for the netkit device type. + +Signed-off-by: Victor Stewart +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240116202952.241009-1-v@nametag.social +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Amend the bpf_redirect_peer header documentation to mention netkit device support.', 'keywords': 'bpf_redirect_peer, header, documentation', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4eaafe5a5b7b5f2fcec22914bc5b8b2d860896b7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4eaafe5a5b7b5f2fcec22914bc5b8b2d860896b7 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1706049771 + Commit Message: + Merge branch 'bpf: tcp: Support arbitrary SYN Cookie at TC.' + +Kuniyuki Iwashima says: + +==================== +Under SYN Flood + Parent Hashes: d177c1be06ce28aa8c8710ac55be1b5ad3f314c6 a74712241b4675175cd8e3310fa206d8756ad5a1 + Refs: the TCP stack generates SYN Cookie to remain stateless +for the connection request until a valid ACK is responded to the SYN+ACK. + +The cookie contains two kinds of host-specific bits + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Support added for arbitrary SYN Cookie in TCP under TC to handle SYN Floods.', 'keywords': 'SYN Cookie, TCP, TC', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: a74712241b4675175cd8e3310fa206d8756ad5a1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a74712241b4675175cd8e3310fa206d8756ad5a1 + Author Name: Kuniyuki Iwashima + Author Email: kuniyu@amazon.com + Commit Date: 1706049624 + Commit Message: + selftest: bpf: Test bpf_sk_assign_tcp_reqsk(). + +This commit adds a sample selftest to demonstrate how we can use +bpf_sk_assign_tcp_reqsk() as the backend of SYN Proxy. + +The test creates IPv4/IPv6 x TCP connections and transfer messages +over them on lo with BPF tc prog attached. + +The tc prog will process SYN and returns SYN+ACK with the following +ISN and TS. In a real use case + Parent Hashes: e472f88891abbc535a5e16a68a104073985f6061 + Refs: this part will be done by other +hosts. + + MSB LSB + ISN: | 31 ... 8 | 7 6 | 5 | 4 | 3 2 1 0 | + | Hash_1 | MSS | ECN | SACK | WScale | + + TS: | 31 ... 8 | 7 ... 0 | + | Random | Hash_2 | + + WScale in SYN is reused in SYN+ACK. + +The client returns ACK + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a selftest for bpf_sk_assign_tcp_reqsk function using BPF tc program for TCP SYN Proxy backend.', 'keywords': 'selftest,BPF tc,bpf_sk_assign_tcp_reqsk', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: e472f88891abbc535a5e16a68a104073985f6061 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e472f88891abbc535a5e16a68a104073985f6061 + Author Name: Kuniyuki Iwashima + Author Email: kuniyu@amazon.com + Commit Date: 1706049624 + Commit Message: + bpf: tcp: Support arbitrary SYN Cookie. + +This patch adds a new kfunc available at TC hook to support arbitrary +SYN Cookie. + +The basic usage is as follows: + + struct bpf_tcp_req_attrs attrs = { + .mss = mss + Parent Hashes: 695751e31a63efd2bbe6779873adf1e4deb00cd5 + Refs: + .wscale_ok = wscale_ok + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a kfunc for arbitrary SYN Cookie support at TC hook in BPF.', 'keywords': 'SYN Cookie, TC hook, kfunc', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 695751e31a63efd2bbe6779873adf1e4deb00cd5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 695751e31a63efd2bbe6779873adf1e4deb00cd5 + Author Name: Kuniyuki Iwashima + Author Email: kuniyu@amazon.com + Commit Date: 1706049624 + Commit Message: + bpf: tcp: Handle BPF SYN Cookie in cookie_v[46]_check(). + +We will support arbitrary SYN Cookie with BPF in the following +patch. + +If BPF prog validates ACK and kfunc allocates a reqsk + Parent Hashes: 8b5ac68fb5ee416537c1214cbacf0ddc4293cce9 + Refs: it will +be carried to cookie_[46]_check() as skb->sk. If skb->sk is not +NULL + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhances TCP handling by managing BPF SYN Cookies in the cookie_v[46]_check functions.', 'keywords': 'SYN Cookie,BPF,ACK', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8b5ac68fb5ee416537c1214cbacf0ddc4293cce9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8b5ac68fb5ee416537c1214cbacf0ddc4293cce9 + Author Name: Kuniyuki Iwashima + Author Email: kuniyu@amazon.com + Commit Date: 1706049624 + Commit Message: + bpf: tcp: Handle BPF SYN Cookie in skb_steal_sock(). + +We will support arbitrary SYN Cookie with BPF. + +If BPF prog validates ACK and kfunc allocates a reqsk + Parent Hashes: 95e752b5299fa8c90099f7bc2aa1ee3e2e2c95ab + Refs: it will +be carried to TCP stack as skb->sk with req->syncookie 1. Also + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance BPF to handle arbitrary SYN cookies in TCP with skb_steal_sock().', 'keywords': 'BPF,SYN Cookie,TCP', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', 'other']} +-------------------- +-------------------- +Processing Commit ID: d177c1be06ce28aa8c8710ac55be1b5ad3f314c6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d177c1be06ce28aa8c8710ac55be1b5ad3f314c6 + Author Name: Artem Savkov + Author Email: asavkov@redhat.com + Commit Date: 1706049623 + Commit Message: + selftests/bpf: Fix potential premature unload in bpf_testmod + +It is possible for bpf_kfunc_call_test_release() to be called from +bpf_map_free_deferred() when bpf_testmod is already unloaded and +perf_test_stuct.cnt which it tries to decrease is no longer in memory. +This patch tries to fix the issue by waiting for all references to be +dropped in bpf_testmod_exit(). + +The issue can be triggered by running 'test_progs -t map_kptr' in 6.5 + Parent Hashes: f5f30386c78105cba520e443a6a9ee945ec1d066 + Refs: +but is obscured in 6.6 by d119357d07435 ("rcu-tasks: Treat only +synchronous grace periods urgently"). + +Fixes: 65eb006d85a2 ("bpf: Move kernel test kfuncs to bpf_testmod") +Signed-off-by: Artem Savkov +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Cc: Jiri Olsa +Link: https://lore.kernel.org/bpf/82f55c0e-0ec8-4fe1-8d8c-b1de07558ad9@linux.dev +Link: https://lore.kernel.org/bpf/20240110085737.8895-1-asavkov@redhat.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes potential premature unloading issue in bpf_testmod during reference drop in selftests.', 'keywords': 'premature unload,selftests,bpf_testmod', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f5f30386c78105cba520e443a6a9ee945ec1d066 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f5f30386c78105cba520e443a6a9ee945ec1d066 + Author Name: Tiezhu Yang + Author Email: yangtiezhu@loongson.cn + Commit Date: 1706049623 + Commit Message: + bpftool: Silence build warning about calloc() + +There exists the following warning when building bpftool: + + CC prog.o +prog.c: In function ‘profile_open_perf_events’: +prog.c:2301:24: warning: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument [-Wcalloc-transposed-args] + 2301 | sizeof(int) + Parent Hashes: 49c06547d5218b54fbcc6011864b8c8e3aa0b565 + Refs: obj->rodata->num_cpu * obj->rodata->num_metric); + | ^~~ +prog.c:2301:24: note: earlier argument should specify number of elements + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix build warning in bpftool related to incorrect usage of calloc.', 'keywords': 'bpftool, calloc, warning', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 49c06547d5218b54fbcc6011864b8c8e3aa0b565 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 49c06547d5218b54fbcc6011864b8c8e3aa0b565 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1706049623 + Commit Message: + bpf: Minor improvements for bpf_cmp. + +Few minor improvements for bpf_cmp() macro: +. reduce number of args in __bpf_cmp() +. rename NOFLIP to UNLIKELY +. add a comment about 64-bit truncation in "i" constraint +. use "ri" constraint for sizeof(rhs) <= 4 +. improve error message for bpf_cmp_likely() + +Before: +progs/iters_task_vma.c:31:7: error: variable 'ret' is uninitialized when used here [-Werror + Parent Hashes: 88031b929c01fe3686d34a848c413c2e51e6a7c8 + Refs: -Wuninitialized] + 31 | if (bpf_cmp_likely(seen + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Minor improvements made to bpf_cmp macro for better usage and error handling.', 'keywords': 'bpf_cmp, macro, improvements', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 88031b929c01fe3686d34a848c413c2e51e6a7c8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 88031b929c01fe3686d34a848c413c2e51e6a7c8 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1706049623 + Commit Message: + docs/bpf: Fix an incorrect statement in verifier.rst + +In verifier.rst + Parent Hashes: 6ae99ac8b7da30c9fdb15e380624dbc41f8200c8 + Refs: I found an incorrect statement (maybe a typo) in section +'Liveness marks tracking'. Basically + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Fixes an incorrect statement in the BPF verifier documentation under 'Liveness marks tracking' section.", 'keywords': 'verifier fix documentation', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6ae99ac8b7da30c9fdb15e380624dbc41f8200c8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6ae99ac8b7da30c9fdb15e380624dbc41f8200c8 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1706049623 + Commit Message: + selftests/bpf: Add a selftest with not-8-byte aligned BPF_ST + +Add a selftest with a 4 bytes BPF_ST of 0 where the store is not +8-byte aligned. The goal is to ensure that STACK_ZERO is properly +marked in stack slots and the STACK_ZERO value can propagate +properly during the load. + +Acked-by: Andrii Nakryiko +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240110051355.2737232-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 9a4c57f52b5e0de3a6b1f40c5b656730ce33ee01 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest to ensure proper STACK_ZERO propagation with non-8-byte aligned BPF_ST operations.', 'keywords': 'selftest, BPF_ST, STACK_ZERO', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9a4c57f52b5e0de3a6b1f40c5b656730ce33ee01 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9a4c57f52b5e0de3a6b1f40c5b656730ce33ee01 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1706049623 + Commit Message: + bpf: Track aligned st store as imprecise spilled registers + +With patch set [1] + Parent Hashes: 3893f0b6a0698aeeb3d27cb22baef7c4ca1a07f1 + Refs: precision backtracing supports register spill/fill +to/from the stack. The patch [2] allows initial imprecise register spill +with content 0. This is a common case for cpuv3 and lower for +initializing the stack variables with pattern + r1 = 0 + *(u64 *)(r10 - 8) = r1 +and the [2] has demonstrated good verification improvement. + +For cpuv4 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves precision of register spill/fill verification for aligned store in eBPF programs.', 'keywords': 'aligned store, register spill, precision', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3893f0b6a0698aeeb3d27cb22baef7c4ca1a07f1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3893f0b6a0698aeeb3d27cb22baef7c4ca1a07f1 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706049623 + Commit Message: + selftests/bpf: Test assigning ID to scalars on spill + +The previous commit implemented assigning IDs to registers holding +scalars before spill. Add the test cases to check the new functionality. + +Signed-off-by: Maxim Mikityanskiy +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-10-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 8ecfc371d829bfed75e0ef2cab45b2290b982f64 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds test cases for assigning IDs to scalar registers before spill in selftests.', 'keywords': 'test cases, scalars, spill', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8ecfc371d829bfed75e0ef2cab45b2290b982f64 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8ecfc371d829bfed75e0ef2cab45b2290b982f64 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706049623 + Commit Message: + bpf: Assign ID to scalars on spill + +Currently + Parent Hashes: 87e51ac6cb19c5d33d70d4cae9e26d2a3a5fcba0 + Refs: when a scalar bounded register is spilled to the stack + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Assign unique IDs to scalars when they are spilled to the stack in the BPF verifier.', 'keywords': 'scalars, IDs, spill', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 87e51ac6cb19c5d33d70d4cae9e26d2a3a5fcba0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 87e51ac6cb19c5d33d70d4cae9e26d2a3a5fcba0 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706049623 + Commit Message: + bpf: Add the get_reg_width function + +Put calculation of the register value width into a dedicated function. +This function will also be used in a following commit. + +Signed-off-by: Maxim Mikityanskiy +Link: https://lore.kernel.org/r/20240108205209.838365-8-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 8e0e074aafb8fec227363ed905ddd2ac7e4575e4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces a dedicated function to calculate register value width in eBPF.', 'keywords': 'register,function,get_reg_width', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8e0e074aafb8fec227363ed905ddd2ac7e4575e4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8e0e074aafb8fec227363ed905ddd2ac7e4575e4 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706049622 + Commit Message: + bpf: Add the assign_scalar_id_before_mov function + +Extract the common code that generates a register ID for src_reg before +MOV if needed into a new function. This function will also be used in +a following commit. + +Signed-off-by: Maxim Mikityanskiy +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-7-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: b827eee4c4d83ad92094b38d49cfec6844fb5863 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extracts common code for generating register ID into a new function for reuse before MOV operations.', 'keywords': 'register, function, MOV', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b827eee4c4d83ad92094b38d49cfec6844fb5863 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b827eee4c4d83ad92094b38d49cfec6844fb5863 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706049622 + Commit Message: + selftests/bpf: Add a test case for 32-bit spill tracking + +When a range check is performed on a register that was 32-bit spilled to +the stack + Parent Hashes: 32f55dd4add4df1a5bc8febc1fafd3086290dbf6 + Refs: the IDs of the two instances of the register are the same + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a selftest for verifying 32-bit spill tracking in BPF programs.', 'keywords': 'selftests,32-bit,spill', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 32f55dd4add4df1a5bc8febc1fafd3086290dbf6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 32f55dd4add4df1a5bc8febc1fafd3086290dbf6 + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706049622 + Commit Message: + bpf: Make bpf_for_each_spilled_reg consider narrow spills + +Adjust the check in bpf_get_spilled_reg to take into account spilled +registers narrower than 64 bits. That allows find_equal_scalars to +properly adjust the range of all spilled registers that have the same +ID. Before this change + Parent Hashes: c035b3e555b5642f786fb2d089a6ddf7b00eb374 + Refs: it was possible for a register and a spilled +register to have the same IDs but different ranges if the spill was +narrower than 64 bits and a range check was performed on the register. + +Signed-off-by: Maxim Mikityanskiy +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-5-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adjusts the bpf_get_spilled_reg function to handle narrower spills under 64 bits properly.', 'keywords': 'bpf,narrower spills,registers', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c035b3e555b5642f786fb2d089a6ddf7b00eb374 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c035b3e555b5642f786fb2d089a6ddf7b00eb374 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1706049622 + Commit Message: + selftests/bpf: check if imprecise stack spills confuse infinite loop detection + +Verify that infinite loop detection logic separates states with +identical register states but different imprecise scalars spilled to +stack. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-4-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d5b892fd607abec2a1e49b6a2afc278c329a0ee2 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit adds a selftest to verify eBPF's infinite loop detection when dealing with imprecise stack spills.", 'keywords': 'selftests, detection, stack spills', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d5b892fd607abec2a1e49b6a2afc278c329a0ee2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d5b892fd607abec2a1e49b6a2afc278c329a0ee2 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1706049622 + Commit Message: + bpf: make infinite loop detection in is_state_visited() exact + +Current infinite loops detection mechanism is speculative: +- first + Parent Hashes: 242d18514149d86b431b6f5db5a33579ea79ebad + Refs: states_maybe_looping() check is done which simply does memcmp + for R1-R10 in current frame; +- second + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves the detection of infinite loops in is_state_visited() within the bpf verification process.', 'keywords': 'infinite loops,detection,verification', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 242d18514149d86b431b6f5db5a33579ea79ebad +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 242d18514149d86b431b6f5db5a33579ea79ebad + Author Name: Maxim Mikityanskiy + Author Email: maxim@isovalent.com + Commit Date: 1706049622 + Commit Message: + selftests/bpf: Fix the u64_offset_to_skb_data test + +The u64_offset_to_skb_data test is supposed to make a 64-bit fill + Parent Hashes: f067074bafd5060428211ee7bb8a3f86ff6bc58d + Refs: but +instead makes a 16-bit one. Fix the test according to its intention and +update the comments accordingly (umax is no longer 0xffff). The 16-bit +fill is covered by u16_offset_to_skb_data. + +Signed-off-by: Maxim Mikityanskiy +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-2-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix the u64_offset_to_skb_data test to properly perform 64-bit fill and update comments.', 'keywords': 'fix,test,64-bit', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f067074bafd5060428211ee7bb8a3f86ff6bc58d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f067074bafd5060428211ee7bb8a3f86ff6bc58d + Author Name: Nathan Chancellor + Author Email: nathan@kernel.org + Commit Date: 1706049622 + Commit Message: + selftests/bpf: Update LLVM Phabricator links + +reviews.llvm.org was LLVM's Phabricator instances for code review. It +has been abandoned in favor of GitHub pull requests. While the majority +of links in the kernel sources still work because of the work Fangrui +has done turning the dynamic Phabricator instance into a static archive + Parent Hashes: 56d3e44af80c6b4c7cb89a73061ee35d4a7aee18 + Refs: +there are some issues with that work + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update LLVM Phabricator links in selftests to use new GitHub pull request locations.', 'keywords': 'LLVM,Phabricator,GitHub', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 56d3e44af80c6b4c7cb89a73061ee35d4a7aee18 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 56d3e44af80c6b4c7cb89a73061ee35d4a7aee18 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706049622 + Commit Message: + selftests/bpf: detect testing prog flags support + +Various tests specify extra testing prog_flags when loading BPF +programs + Parent Hashes: 81777efbf59305fa145bede97dd4abdc35540578 + Refs: like BPF_F_TEST_RND_HI32 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable selftests to detect support for testing prog_flags when loading BPF programs.', 'keywords': 'selftests, prog_flags, BPF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 15b8b0be985592fd19ee4e661d13d291877b09c7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 15b8b0be985592fd19ee4e661d13d291877b09c7 + Author Name: Randy Dunlap + Author Email: rdunlap@infradead.org + Commit Date: 1706049622 + Commit Message: + net: filter: fix spelling mistakes + +Fix spelling errors as reported by codespell. + +Signed-off-by: Randy Dunlap +Cc: Alexei Starovoitov +Cc: Daniel Borkmann +Cc: Andrii Nakryiko +Cc: bpf@vger.kernel.org +Cc: "David S. Miller" +Cc: Eric Dumazet +Cc: Jakub Kicinski +Cc: Paolo Abeni +Reviewed-by: Simon Horman +Link: https://lore.kernel.org/r/20240106065545.16855-1-rdunlap@infradead.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 522bb2c1f82b12eb7befaae815d1d959b8e6bba2 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes spelling mistakes in the net filter code.', 'keywords': 'spelling, mistakes, codespell', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 522bb2c1f82b12eb7befaae815d1d959b8e6bba2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 522bb2c1f82b12eb7befaae815d1d959b8e6bba2 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706049621 + Commit Message: + bpf: support multiple tags per argument + +Add ability to iterate multiple decl_tag types pointed to the same +function argument. Use this to support multiple __arg_xxx tags per +global subprog argument. + +We leave btf_find_decl_tag_value() intact + Parent Hashes: 54c11ec4935a61af32bb03fc52e7172c97bd7203 + Refs: but change its implementation +to use a new btf_find_next_decl_tag() which can be straightforwardly +used to find next BTF type ID of a matching btf_decl_tag type. +btf_prepare_func_args() is switched from btf_find_decl_tag_value() to +btf_find_next_decl_tag() to gain multiple tags per argument support. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240105000909.2818934-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds support for multiple declaration tags per function argument in eBPF.', 'keywords': 'multiple tags, function argument, btf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 54c11ec4935a61af32bb03fc52e7172c97bd7203 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 54c11ec4935a61af32bb03fc52e7172c97bd7203 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706049621 + Commit Message: + bpf: prepare btf_prepare_func_args() for multiple tags per argument + +Add btf_arg_tag flags enum to be able to record multiple tags per +argument. Also streamline pointer argument processing some more. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240105000909.2818934-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 18810ad3929ff6b5d8e67e3adc40d690bd780fd6 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhances btf_prepare_func_args to support multiple tags per argument and improves pointer argument processing.', 'keywords': 'multiple tags, argument, btf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 18810ad3929ff6b5d8e67e3adc40d690bd780fd6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 18810ad3929ff6b5d8e67e3adc40d690bd780fd6 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706049621 + Commit Message: + bpf: make sure scalar args don't accept __arg_nonnull tag + +Move scalar arg processing in btf_prepare_func_args() after all pointer +arg processing is done. This makes it easier to do validation. One +example of unintended behavior right now is ability to specify +__arg_nonnull for integer/enum arguments. This patch fixes this. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240105000909.2818934-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: e31f98c1af810a13395ee9ab57402d82272445af + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes scalar argument processing in btf_prepare_func_args to prevent __arg_nonnull for non-pointer args.', 'keywords': 'scalar,args,validation', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e31f98c1af810a13395ee9ab57402d82272445af +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e31f98c1af810a13395ee9ab57402d82272445af + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1706049621 + Commit Message: + selftests/bpf: fix test_loader check message + +Seeing: + + process_subtest:PASS:Can't alloc specs array 0 nsec + +... in verbose successful test log is very confusing. Use smaller +identifier-like test tag to denote that we are asserting specs array +allocation success. + +Now it's much less distracting: + + process_subtest:PASS:specs_alloc 0 nsec + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240105000909.2818934-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 55c14321dbf06c9e32050e99b2555c2f8f6429da + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit clarifies the test message in selftests for BPF regarding specs array allocation checks.', 'keywords': 'selftests,BPF,message', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 55c14321dbf06c9e32050e99b2555c2f8f6429da +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 55c14321dbf06c9e32050e99b2555c2f8f6429da + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1706049621 + Commit Message: + Merge branch 'bpf-inline-bpf_kptr_xchg' + +Hou Tao says: + +==================== +The motivation of inlining bpf_kptr_xchg() comes from the performance +profiling of bpf memory allocator benchmark [1]. The benchmark uses +bpf_kptr_xchg() to stash the allocated objects and to pop the stashed +objects for free. After inling bpf_kptr_xchg() + Parent Hashes: 2121c43f88f593eea51d483bedd638cb0623c7e2 17bda53e43bc41d881ca6a02b3c6f5376c55b3d3 + Refs: the performance for +object free on 8-CPUs VM increases about 2%~10%. However the performance +gain comes with costs: both the kasan and kcsan checks on the pointer +will be unavailable. Initially the inline is implemented in do_jit() for +x86-64 directly + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit merges changes for inlining bpf_kptr_xchg to improve memory allocator benchmark performance.', 'keywords': 'bpf_kptr_xchg, inlining, performance', 'commit_classification': "It's a performance optimization.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 17bda53e43bc41d881ca6a02b3c6f5376c55b3d3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 17bda53e43bc41d881ca6a02b3c6f5376c55b3d3 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1706049621 + Commit Message: + selftests/bpf: Test the inlining of bpf_kptr_xchg() + +The test uses bpf_prog_get_info_by_fd() to obtain the xlated +instructions of the program first. Since these instructions have +already been rewritten by the verifier + Parent Hashes: b4b7a4099b8ccea224577003fcf9d321bf0817b7 + Refs: the tests then checks whether +the rewritten instructions are as expected. And to ensure LLVM generates +code exactly as expected + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests to verify the inlining of bpf_kptr_xchg through bpf_prog_get_info_by_fd().', 'keywords': 'selftests,inlining,bpf_kptr_xchg', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b4b7a4099b8ccea224577003fcf9d321bf0817b7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b4b7a4099b8ccea224577003fcf9d321bf0817b7 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1706049621 + Commit Message: + selftests/bpf: Factor out get_xlated_program() helper + +Both test_verifier and test_progs use get_xlated_program() + Parent Hashes: 7c05e7f3e74e7e550534d524e04d7e6f78d6fa24 + Refs: so moving +the helper into testing_helpers.h to reuse it. + +Acked-by: Eduard Zingerman +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20240105104819.3916743-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor by moving get_xlated_program() helper into testing_helpers.h for reuse in selftests/bpf.', 'keywords': 'refactor,reuse,tests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7c05e7f3e74e7e550534d524e04d7e6f78d6fa24 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7c05e7f3e74e7e550534d524e04d7e6f78d6fa24 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1706049621 + Commit Message: + bpf: Support inlining bpf_kptr_xchg() helper + +The motivation of inlining bpf_kptr_xchg() comes from the performance +profiling of bpf memory allocator benchmark. The benchmark uses +bpf_kptr_xchg() to stash the allocated objects and to pop the stashed +objects for free. After inling bpf_kptr_xchg() + Parent Hashes: 2121c43f88f593eea51d483bedd638cb0623c7e2 + Refs: the performance for +object free on 8-CPUs VM increases about 2%~10%. The inline also has +downside: both the kasan and kcsan checks on the pointer will be +unavailable. + +bpf_kptr_xchg() can be inlined by converting the calling of +bpf_kptr_xchg() into an atomic_xchg() instruction. But the conversion +depends on two conditions: +1) JIT backend supports atomic_xchg() on pointer-sized word +2) For the specific arch + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves performance by inlining the bpf_kptr_xchg() helper function for better efficiency in memory allocation benchmarks.', 'keywords': 'bpf_kptr_xchg, inlining, performance', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 1732ebc4a26181c8f116c7639db99754b313edc8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1732ebc4a26181c8f116c7639db99754b313edc8 + Author Name: Pu Lehui + Author Email: pulehui@huawei.com + Commit Date: 1706048498 + Commit Message: + riscv + Parent Hashes: 1347775dea7f62798b4d5ef60771cdd7cfff25d8 + Refs: bpf: Fix unpredictable kernel crash about RV64 struct_ops + +We encountered a kernel crash triggered by the bpf_tcp_ca testcase as +show below: + +Unable to handle kernel paging request at virtual address ff60000088554500 +Oops [#1] +... +CPU: 3 PID: 458 Comm: test_progs Tainted: G OE 6.8.0-rc1-kselftest_plain #1 +Hardware name: riscv-virtio + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a kernel crash related to struct_ops in RISC-V when running bpf_tcp_ca test cases.', 'keywords': 'kernel crash, struct_ops, RISC-V', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 999eea92e8d7a1ffa83f7dc89c83d8ed1e746fa9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 999eea92e8d7a1ffa83f7dc89c83d8ed1e746fa9 + Author Name: Thomas Richter + Author Email: tmricht@linux.ibm.com + Commit Date: 1705954099 + Commit Message: + perf test: raise limit to 20 percent for perf_stat_--bpf-counters_test + +This test case often fails on s390 (about 2 out of 10) because the +10% percent limit on the difference between --bpf-counters event counting +and s390 hardware counting is more than 10% in all failure cases. +Raise the limit to 20% on s390 and the test case succeeds. + +Signed-off-by: Thomas Richter +Acked-by: Namhyung Kim +Cc: gor@linux.ibm.com +Cc: hca@linux.ibm.com +Cc: sumanthk@linux.ibm.com +Cc: svens@linux.ibm.com +Link: https://lore.kernel.org/r/20240108084009.3959211-1-tmricht@linux.ibm.com +Signed-off-by: Namhyung Kim + + Parent Hashes: 6613476e225e090cc9aad49be7fa504e290dd33d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Raise the limit for perf_stat bpf-counters test from 10% to 20% to reduce failures on s390 architecture.', 'keywords': 'perf,test,s390', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9d64bf433c53cab2f48a3fff7a1f2a696bc5229a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9d64bf433c53cab2f48a3fff7a1f2a696bc5229a + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1705703123 + Commit Message: + Merge tag 'perf-tools-for-v6.8-1-2024-01-09' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools + +Pull perf tools updates from Arnaldo Carvalho de Melo: + "Add Namhyung Kim as tools/perf/ co-maintainer + Parent Hashes: 57f22c8dab6b266ae36b89b073a4a33dea71e762 d988c9f511af71a3445b6a4f3a2c67208ff8e480 + Refs: we're taking turns + processing patches + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge perf tools updates adding Namhyung Kim as co-maintainer for tools/perf.', 'keywords': 'perf,tools,maintainer', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 736b5545d39ca59d4332a60e56cc8a1a5e264a8e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 736b5545d39ca59d4332a60e56cc8a1a5e264a8e + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1705628030 + Commit Message: + Merge tag 'net-6.8-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + "Including fixes from bpf and netfilter. + + Previous releases - regressions: + + - Revert "net: rtnetlink: Enslave device before bringing it up" + Parent Hashes: ed8d84530ab0a3b7b370e8b28f12179314dcfcc3 925781a471d8156011e8f8c1baf61bbe020dac55 + Refs: + breaks the case inverse to the one it was trying to fix + + - net: dsa: fix oob access in DSA's netdevice event handler + dereference netdev_priv() before check its a DSA port + + - sched: track device in tcf_block_get/put_ext() only for clsact + binder types + + - net: tls + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge of networking fixes including bpf and netfilter regressions', 'keywords': 'networking,fixes,bpf', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4349efc52b83af3851df7a4199567ad50b3d1f03 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4349efc52b83af3851df7a4199567ad50b3d1f03 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1705600464 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-01-18 + +We've added 10 non-merge commits during the last 5 day(s) which contain +a total of 12 files changed + Parent Hashes: 9cfd3b502153810b66ac0ce47f1fba682228f2d2 35ac085a94efe82d906d3a812612d432aa267cbe + Refs: 806 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merges recent non-merge commits from bpf to for-netdev tag affecting 12 files.', 'keywords': 'merge, commits, bpf', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 35ac085a94efe82d906d3a812612d432aa267cbe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 35ac085a94efe82d906d3a812612d432aa267cbe + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1705551606 + Commit Message: + Merge branch 'tighten-up-arg-ctx-type-enforcement' + +Andrii Nakryiko says: + +==================== +Tighten up arg:ctx type enforcement + +Follow up fixes for kernel-side and libbpf-side logic around handling arg:ctx +(__arg_ctx) tagged arguments of BPF global subprogs. + +Patch #1 adds libbpf feature detection of kernel-side __arg_ctx support to +avoid unnecessary rewriting BTF types. With stricter kernel-side type +enforcement this is now mandatory to avoid problems with using `struct +bpf_user_pt_regs_t` instead of actual typedef. For __arg_ctx tagged arguments +verifier is now supporting either `bpf_user_pt_regs_t` typedef or resolves it +down to the actual struct (pt_regs/user_pt_regs/user_regs_struct) + Parent Hashes: 33772ff3b887eb2f426ed66bcb1808837a40669c 76ec90a996e3c707eb6772510afa36faeba2ecff + Refs: depending +on architecture) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance type enforcement for BPF arg:ctx in kernel and libbpf for stricter verifier checks.', 'keywords': 'type enforcement, libbpf, BPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 76ec90a996e3c707eb6772510afa36faeba2ecff +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 76ec90a996e3c707eb6772510afa36faeba2ecff + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1705551606 + Commit Message: + libbpf: warn on unexpected __arg_ctx type when rewriting BTF + +On kernel that don't support arg:ctx tag + Parent Hashes: 989410cde81959c4033dc287d79b42b6eb04f04f + Refs: before adjusting global +subprog BTF information to match kernel's expected canonical type names + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add warning in libbpf for unexpected __arg_ctx type during BTF rewriting on unsupported kernels.', 'keywords': 'libbpf, BTF, warning', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 989410cde81959c4033dc287d79b42b6eb04f04f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 989410cde81959c4033dc287d79b42b6eb04f04f + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1705551606 + Commit Message: + selftests/bpf: add tests confirming type logic in kernel for __arg_ctx + +Add a bunch of global subprogs across variety of program types to +validate expected kernel type enforcement logic for __arg_ctx arguments. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240118033143.3384355-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 0ba971511d16603599f947459e59b435cc465b0d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add tests in selftests/bpf to validate type enforcement logic for __arg_ctx arguments across various program types.', 'keywords': 'type logic,__arg_ctx,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0ba971511d16603599f947459e59b435cc465b0d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0ba971511d16603599f947459e59b435cc465b0d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1705551606 + Commit Message: + bpf: enforce types for __arg_ctx-tagged arguments in global subprogs + +Add enforcement of expected types for context arguments tagged with +arg:ctx (__arg_ctx) tag. + +First + Parent Hashes: 66967a32d3b16ed447e76fed4d946bab52e43d86 + Refs: any program type will accept generic `void *` context type when +combined with __arg_ctx tag. + +Besides accepting "canonical" struct names and `void *` + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enforces expected types for context arguments with __arg_ctx tag in global subprograms in eBPF.', 'keywords': 'enforce, context, __arg_ctx', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 66967a32d3b16ed447e76fed4d946bab52e43d86 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 66967a32d3b16ed447e76fed4d946bab52e43d86 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1705551605 + Commit Message: + bpf: extract bpf_ctx_convert_map logic and make it more reusable + +Refactor btf_get_prog_ctx_type() a bit to allow reuse of +bpf_ctx_convert_map logic in more than one places. Simplify interface by +returning btf_type instead of btf_member (field reference in BTF). + +To do the above we need to touch and start untangling +btf_translate_to_vmlinux() implementation. We do the bare minimum to +not regress anything for btf_translate_to_vmlinux() + Parent Hashes: 01b55f4f0cd6ad1a16eca6c43a3190005892ef91 + Refs: but its +implementation is very questionable for what it claims to be doing. +Mapping kfunc argument types to kernel corresponding types conceptually +is quite different from recognizing program context types. Fixing this +is out of scope for this change though. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240118033143.3384355-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactors btf_get_prog_ctx_type to enhance reusability of bpf_ctx_convert_map logic.', 'keywords': 'refactor,reusability,btf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 01b55f4f0cd6ad1a16eca6c43a3190005892ef91 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 01b55f4f0cd6ad1a16eca6c43a3190005892ef91 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1705551605 + Commit Message: + libbpf: feature-detect arg:ctx tag support in kernel + +Add feature detector of kernel-side arg:ctx (__arg_ctx) tag support. If +this is detected + Parent Hashes: 33772ff3b887eb2f426ed66bcb1808837a40669c + Refs: libbpf will avoid doing any __arg_ctx-related BTF +rewriting and checks in favor of letting kernel handle this completely. + +test_global_funcs/ctx_arg_rewrite subtest is adjusted to do the same +feature detection (albeit in much simpler + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added feature detection for kernel support of arg:ctx tag in libbpf.', 'keywords': 'feature detection,arg:ctx,libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 36a87385e31c9343af9a4756598e704741250a67 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 36a87385e31c9343af9a4756598e704741250a67 + Author Name: Hengqi Chen + Author Email: hengqi.chen@gmail.com + Commit Date: 1705466593 + Commit Message: + LoongArch: BPF: Prevent out-of-bounds memory access + +The test_tag test triggers an unhandled page fault: + + # ./test_tag + [ 130.640218] CPU 0 Unable to handle kernel paging request at virtual address ffff80001b898004 + Parent Hashes: 21c5ae5cc1eee70f7f3b09f1d6b237d9812d4b9c + Refs: era == 9000000003137f7c + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit prevents out-of-bounds memory access on LoongArch architecture for BPF.', 'keywords': 'LoongArch,BPF,memory', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 21c5ae5cc1eee70f7f3b09f1d6b237d9812d4b9c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 21c5ae5cc1eee70f7f3b09f1d6b237d9812d4b9c + Author Name: Hengqi Chen + Author Email: hengqi.chen@gmail.com + Commit Date: 1705466593 + Commit Message: + LoongArch: BPF: Support 64-bit pointers to kfuncs + +Like commit 1cf3bfc60f9836f ("bpf: Support 64-bit pointers to kfuncs") +for s390x + Parent Hashes: 91af17cd7d03db8836554c91ba7c38b0817aa980 + Refs: add support for 64-bit pointers to kfuncs for LoongArch. +Since the infrastructure is already implemented in BPF core + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable 64-bit pointer support for kfuncs in LoongArch architecture.', 'keywords': 'LoongArch, 64-bit, kfuncs', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 33772ff3b887eb2f426ed66bcb1808837a40669c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 33772ff3b887eb2f426ed66bcb1808837a40669c + Author Name: Hao Sun + Author Email: sunhao.th@gmail.com + Commit Date: 1705421568 + Commit Message: + selftests/bpf: Add test for alu on PTR_TO_FLOW_KEYS + +Add a test case for PTR_TO_FLOW_KEYS alu. Testing if alu with variable +offset on flow_keys is rejected. For the fixed offset success case + Parent Hashes: 22c7fa171a02d310e3a3f6ed46a698ca8a0060ed + Refs: we +already have C code coverage to verify (e.g. via bpf_flow.c). + +Signed-off-by: Hao Sun +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240115082028.9992-2-sunhao.th@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test case for validating alu operations on PTR_TO_FLOW_KEYS in selftests.', 'keywords': 'alu, PTR_TO_FLOW_KEYS, test', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 22c7fa171a02d310e3a3f6ed46a698ca8a0060ed +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 22c7fa171a02d310e3a3f6ed46a698ca8a0060ed + Author Name: Hao Sun + Author Email: sunhao.th@gmail.com + Commit Date: 1705421549 + Commit Message: + bpf: Reject variable offset alu on PTR_TO_FLOW_KEYS + +For PTR_TO_FLOW_KEYS + Parent Hashes: 8e33d5db7d014ea2fb2994bbe42010d043997d60 + Refs: check_flow_keys_access() only uses fixed off +for validation. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit rejects variable offset ALU operations on PTR_TO_FLOW_KEYS to ensure fixed offset validation.', 'keywords': 'PTR_TO_FLOW_KEYS,variable offset,validation', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8e33d5db7d014ea2fb2994bbe42010d043997d60 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8e33d5db7d014ea2fb2994bbe42010d043997d60 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1705172504 + Commit Message: + Merge branch 'bpf-fix-backward-progress-bug-in-bpf_iter_udp' + +Martin KaFai Lau says: + +==================== +bpf: Fix backward progress bug in bpf_iter_udp + +From: Martin KaFai Lau + +This patch set fixes an issue in bpf_iter_udp that makes backward +progress and prevents the user space process from finishing. There is +a test at the end to reproduce the bug. + +Please see individual patches for details. + +v3: +- Fixed the iter_fd check and local_port check in the + patch 3 selftest. (Yonghong) +- Moved jhash2 to test_jhash.h in the patch 3. (Yonghong) +- Added explanation in the bucket selection in the patch 3. (Yonghong) + +v2: +- Added patch 1 to fix another bug that goes back to + the previous bucket +- Simplify the fix in patch 2 to always reset iter->offset to 0 +- Add a test case to close all udp_sk in a bucket while + in the middle of the iteration. +==================== + +Link: https://lore.kernel.org/r/20240112190530.3751661-1-martin.lau@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 894d7508316e7ad722df597d68b4b1797a9eee11 dbd7db7787ba1743a505a495e479550932836fa4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes backward progress bug in bpf_iter_udp that prevents user space process completion.', 'keywords': 'bpf_iter_udp, bug fix, backward progress', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dbd7db7787ba1743a505a495e479550932836fa4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dbd7db7787ba1743a505a495e479550932836fa4 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1705172504 + Commit Message: + selftests/bpf: Test udp and tcp iter batching + +The patch adds a test to exercise the bpf_iter_udp batching +logic. It specifically tests the case that there are multiple +so_reuseport udp_sk in a bucket of the udp_table. + +The test creates two sets of so_reuseport sockets and +each set on a different port. Meaning there will be +two buckets in the udp_table. + +The test does the following: +1. read() 3 out of 4 sockets in the first bucket. +2. close() all sockets in the first bucket. This + will ensure the current bucket's offset in + the kernel does not affect the read() of the + following bucket. +3. read() all 4 sockets in the second bucket. + +The test also reads one udp_sk at a time from +the bpf_iter_udp prog. The true case in +"do_test(... + Parent Hashes: 2242fd537fab52d5f4d2fbb1845f047c01fad0cf + Refs: bool onebyone)". This is the buggy case +that the previous patch fixed. + +It also tests the "false" case in "do_test(... + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a test for bpf_iter_udp batching in selftests.', 'keywords': 'bpf_iter_udp, batching, udp_sk', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2242fd537fab52d5f4d2fbb1845f047c01fad0cf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2242fd537fab52d5f4d2fbb1845f047c01fad0cf + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1705172504 + Commit Message: + bpf: Avoid iter->offset making backward progress in bpf_iter_udp + +There is a bug in the bpf_iter_udp_batch() function that stops +the userspace from making forward progress. + +The case that triggers the bug is the userspace passed in +a very small read buffer. When the bpf prog does bpf_seq_printf + Parent Hashes: 19ca0823f6eaad01d18f664a00550abe912c034c + Refs: +the userspace read buffer is not enough to capture the whole bucket. + +When the read buffer is not large enough + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a bug in bpf_iter_udp_batch to ensure forward progress with small userspace read buffers.', 'keywords': 'bug, bpf_iter_udp, userspace', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 19ca0823f6eaad01d18f664a00550abe912c034c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 19ca0823f6eaad01d18f664a00550abe912c034c + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1705172504 + Commit Message: + bpf: iter_udp: Retry with a larger batch size without going back to the previous bucket + +The current logic is to use a default size 16 to batch the whole bucket. +If it is too small + Parent Hashes: 894d7508316e7ad722df597d68b4b1797a9eee11 + Refs: it will retry with a larger batch size. + +The current code accidentally does a state->bucket-- before retrying. +This goes back to retry with the previous bucket which has already +been done. This patch fixed it. + +It is hard to create a selftest. I added a WARN_ON(state->bucket < 0) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes issue in iter_udp logic where retries incorrectly decrease bucket index, causing redundant processing of previous bucket.', 'keywords': 'iter_udp, batch, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: fef018d8199661962b5fc0f0d1501caa54b2b533 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fef018d8199661962b5fc0f0d1501caa54b2b533 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1705099513 + Commit Message: + Merge tag 'hid-for-linus-2024010801' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid + +Pull HID updates from Jiri Kosina: + + - assorted functional fixes for hid-steam ported from SteamOS betas + (Vicki Pfau) + + - fix for custom sensor-hub sensors (hinge angle sensor and LISS + sensors) not working (Yauhen Kharuzhy) + + - functional fix for handling Confidence in Wacom driver (Jason + Gerecke) + + - support for Ilitek ili2901 touchscreen (Zhengqiao Xia) + + - power management fix for Wacom userspace battery exporting + (Tatsunosuke Tobita) + + - rework of wait-for-reset in order to reduce the need for + I2C_HID_QUIRK_NO_IRQ_AFTER_RESET qurk; the success rate is now 50% + better + Parent Hashes: d97a78423c33f68ca6543de510a409167baed6f5 0b43615af19742e1f4f71d332e72381430804804 + Refs: but there are still further improvements to be made (Hans de + Goede) + + - greatly improved coverage of Tablets in hid-selftests (Benjamin + Tissoires) + + - support for Nintendo NSO controllers -- SNES + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merged HID updates including functional fixes, sensor support, power management fixes, and improved self-tests.', 'keywords': 'HID, fixes, support', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 3e7aeb78ab01c2c2f0e1f784e5ddec88fcd3d106 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3e7aeb78ab01c2c2f0e1f784e5ddec88fcd3d106 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1704996449 + Commit Message: + Merge tag 'net-next-6.8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next + +Pull networking updates from Paolo Abeni: + "The most interesting thing is probably the networking structs + reorganization and a significant amount of changes is around + self-tests. + + Core & protocols: + + - Analyze and reorganize core networking structs (socks + Parent Hashes: de927f6c0b07d9e698416c5b287c521b07694cac a7fe0881d9b78d402bbd9067dd4503a57c57a1d9 + Refs: netdev + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking updates from Paolo Abeni including core structs reorganization and self-tests.', 'keywords': 'networking, structs, reorganization', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e3977e0609a07d86406029fceea0fd40d7849368 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e3977e0609a07d86406029fceea0fd40d7849368 + Author Name: Tejun Heo + Author Email: tj@kernel.org + Commit Date: 1704970287 + Commit Message: + Revert "kernfs: convert kernfs_idr_lock to an irq safe raw spinlock" + +This reverts commit dad3fb67ca1cbef87ce700e83a55835e5921ce8a. + +The commit converted kernfs_idr_lock to an IRQ-safe raw_spinlock because it +could be acquired while holding an rq lock through bpf_cgroup_from_id(). +However + Parent Hashes: c312828c37a72fe2d033a961c47c227b0767e9f8 + Refs: kernfs_idr_lock is held while doing GPF_NOWAIT allocations which +involves acquiring an non-IRQ-safe and non-raw lock leading to the following +lockdep warning: + + ============================= + [ BUG: Invalid wait context ] + 6.7.0-rc5-kzm9g-00251-g655022a45b1c #578 Not tainted + ----------------------------- + swapper/0/0 is trying to lock: + dfbcd488 (&c->lock){....}-{3:3} + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Revert the conversion of kernfs_idr_lock to an IRQ-safe raw spinlock due to lockdep warning issues.', 'keywords': 'revert, spinlock, lockdep', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 8158a50f9058ce882a6a020c41cef6bae2c3eae3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8158a50f9058ce882a6a020c41cef6bae2c3eae3 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1704510932 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-01-05 + +We've added 40 non-merge commits during the last 2 day(s) which contain +a total of 73 files changed + Parent Hashes: 795fd9342c628839ac9c3f3133d063ce2e577ea7 5fe4ee6ae187523f710f1b93024437a073d88b17 + Refs: 1526 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merged 'bpf-next' changes with 73 files affected and 1526 insertions.", 'keywords': 'merge, bpf-next, changes', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5fe4ee6ae187523f710f1b93024437a073d88b17 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5fe4ee6ae187523f710f1b93024437a073d88b17 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704429654 + Commit Message: + Merge branch 'relax-tracing-prog-recursive-attach-rules' + +Dmitrii Dolgov says: + +==================== +Relax tracing prog recursive attach rules + +Currently + Parent Hashes: 00bc8988807985e32f5103f1ac099baf593bd8a3 e02feb3f1f47509ec1e07b604bfbeff8c3b4e639 + Refs: it's not allowed to attach an fentry/fexit prog to another +fentry/fexit. At the same time it's not uncommon to see a tracing +program with lots of logic in use + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit relaxes the rules for recursively attaching fentry/fexit tracing programs.', 'keywords': 'tracing recursive rules', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: e02feb3f1f47509ec1e07b604bfbeff8c3b4e639 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e02feb3f1f47509ec1e07b604bfbeff8c3b4e639 + Author Name: Dmitrii Dolgov + Author Email: 9erthalion6@gmail.com + Commit Date: 1704429649 + Commit Message: + selftests/bpf: Test re-attachment fix for bpf_tracing_prog_attach + +Add a test case to verify the fix for "prog->aux->dst_trampoline and +tgt_prog is NULL" branch in bpf_tracing_prog_attach. The sequence of +events: + +1. load rawtp program +2. load fentry program with rawtp as target_fd +3. create tracing link for fentry program with target_fd = 0 +4. repeat 3 + +Acked-by: Jiri Olsa +Acked-by: Song Liu +Signed-off-by: Dmitrii Dolgov <9erthalion6@gmail.com> +Link: https://lore.kernel.org/r/20240103190559.14750-5-9erthalion6@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 715d82ba636cb3629a6e18a33bb9dbe53f9936ee + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test case to verify the fix for re-attachment in bpf_tracing_prog_attach.', 'keywords': 'test case, re-attachment, bpf_tracing_prog_attach', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 715d82ba636cb3629a6e18a33bb9dbe53f9936ee +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 715d82ba636cb3629a6e18a33bb9dbe53f9936ee + Author Name: Jiri Olsa + Author Email: olsajiri@gmail.com + Commit Date: 1704429619 + Commit Message: + bpf: Fix re-attachment branch in bpf_tracing_prog_attach + +The following case can cause a crash due to missing attach_btf: + +1) load rawtp program +2) load fentry program with rawtp as target_fd +3) create tracing link for fentry program with target_fd = 0 +4) repeat 3 + +In the end we have: + +- prog->aux->dst_trampoline == NULL +- tgt_prog == NULL (because we did not provide target_fd to link_create) +- prog->aux->attach_btf == NULL (the program was loaded with attach_prog_fd=X) +- the program was loaded for tgt_prog but we have no way to find out which one + + BUG: kernel NULL pointer dereference + Parent Hashes: 5c5371e069e1ffc204dda8b20c609b170b823165 + Refs: address: 0000000000000058 + Call Trace: + + ? __die+0x20/0x70 + ? page_fault_oops+0x15b/0x430 + ? fixup_exception+0x22/0x330 + ? exc_page_fault+0x6f/0x170 + ? asm_exc_page_fault+0x22/0x30 + ? bpf_tracing_prog_attach+0x279/0x560 + ? btf_obj_id+0x5/0x10 + bpf_tracing_prog_attach+0x439/0x560 + __sys_bpf+0x1cf4/0x2de0 + __x64_sys_bpf+0x1c/0x30 + do_syscall_64+0x41/0xf0 + entry_SYSCALL_64_after_hwframe+0x6e/0x76 + +Return -EINVAL in this situation. + +Fixes: f3a95075549e0 ("bpf: Allow trampoline re-attach for tracing and lsm programs") +Cc: stable@vger.kernel.org +Signed-off-by: Jiri Olsa +Acked-by: Jiri Olsa +Acked-by: Song Liu +Signed-off-by: Dmitrii Dolgov <9erthalion6@gmail.com> +Link: https://lore.kernel.org/r/20240103190559.14750-4-9erthalion6@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix crash due to missing attach_btf in bpf_tracing_prog_attach when re-attaching fentry programs.', 'keywords': 'crash, attach_btf, bpf_tracing', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 5c5371e069e1ffc204dda8b20c609b170b823165 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5c5371e069e1ffc204dda8b20c609b170b823165 + Author Name: Dmitrii Dolgov + Author Email: 9erthalion6@gmail.com + Commit Date: 1704429614 + Commit Message: + selftests/bpf: Add test for recursive attachment of tracing progs + +Verify the fact that only one fentry prog could be attached to another +fentry + Parent Hashes: 19bfcdf9498aa968ea293417fbbc39e523527ca8 + Refs: building up an attachment chain of limited size. Use existing +bpf_testmod as a start of the chain. + +Acked-by: Jiri Olsa +Acked-by: Song Liu +Signed-off-by: Dmitrii Dolgov <9erthalion6@gmail.com> +Link: https://lore.kernel.org/r/20240103190559.14750-3-9erthalion6@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a test case for recursive attachment of tracing programs in eBPF selftests.', 'keywords': 'selftests,bpf,tracing', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 19bfcdf9498aa968ea293417fbbc39e523527ca8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 19bfcdf9498aa968ea293417fbbc39e523527ca8 + Author Name: Dmitrii Dolgov + Author Email: 9erthalion6@gmail.com + Commit Date: 1704429094 + Commit Message: + bpf: Relax tracing prog recursive attach rules + +Currently + Parent Hashes: 00bc8988807985e32f5103f1ac099baf593bd8a3 + Refs: it's not allowed to attach an fentry/fexit prog to another +one fentry/fexit. At the same time it's not uncommon to see a tracing +program with lots of logic in use + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit relaxes restrictions on attaching tracing programs like fentry/fexit to allow recursive attachment.', 'keywords': 'tracing, recursive, attach', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 00bc8988807985e32f5103f1ac099baf593bd8a3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 00bc8988807985e32f5103f1ac099baf593bd8a3 + Author Name: Leon Hwang + Author Email: hffilwlqm@gmail.com + Commit Date: 1704428530 + Commit Message: + bpf + Parent Hashes: 61a40c12496a763fdb95edc08d59f816a594a87a + Refs: x86: Use emit_nops to replace memcpy x86_nops + +Move emit_nops() before emit_prologue() and replace +memcpy(prog + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize x86 nop insertion by moving emit_nops() before emit_prologue() and replacing memcpy usage.', 'keywords': 'x86,emit_nops,optimization', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 61a40c12496a763fdb95edc08d59f816a594a87a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 61a40c12496a763fdb95edc08d59f816a594a87a + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704407845 + Commit Message: + Merge branch 's390-bpf-fix-gotol-with-large-offsets' + +Ilya Leoshkevich says: + +==================== +s390/bpf: Fix gotol with large offsets + +Hi + Parent Hashes: 98e20e5e13d2811898921f999288be7151a11954 63fac34669e4cc666f943173ed2aa76b8db999f0 + Refs: + +While looking at a pyperf180 failure on s390x (must be related to [1] + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix for BPF gotol instruction handling on s390 architecture with large offsets.', 'keywords': 's390,bpf,gotol', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 63fac34669e4cc666f943173ed2aa76b8db999f0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 63fac34669e4cc666f943173ed2aa76b8db999f0 + Author Name: Ilya Leoshkevich + Author Email: iii@linux.ibm.com + Commit Date: 1704407845 + Commit Message: + selftests/bpf: Test gotol with large offsets + +Test gotol with offsets that don't fit into a short (i.e. + Parent Hashes: 445aea5afda4759c13dc5c492b309cc1d5c1c486 + Refs: larger than +32k or smaller than -32k). + +Signed-off-by: Ilya Leoshkevich +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240102193531.3169422-4-iii@linux.ibm.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds tests for gotol instruction with large offsets exceeding 32k in BPF selftests.', 'keywords': 'gotol, offsets, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 445aea5afda4759c13dc5c492b309cc1d5c1c486 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 445aea5afda4759c13dc5c492b309cc1d5c1c486 + Author Name: Ilya Leoshkevich + Author Email: iii@linux.ibm.com + Commit Date: 1704407735 + Commit Message: + selftests/bpf: Double the size of test_loader log + +Testing long jumps requires having >32k instructions. That many +instructions require the verifier log buffer of 2 megabytes. + +The regular test_progs run doesn't need an increased buffer + Parent Hashes: ecba66cb36e3428e9f0c2362b45e213ad43ba8d0 + Refs: since +gotol test with 40k instructions doesn't request a log + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Increase the test_loader log size for selftests involving >32k instructions.', 'keywords': 'selftests log size', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ecba66cb36e3428e9f0c2362b45e213ad43ba8d0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ecba66cb36e3428e9f0c2362b45e213ad43ba8d0 + Author Name: Ilya Leoshkevich + Author Email: iii@linux.ibm.com + Commit Date: 1704396940 + Commit Message: + s390/bpf: Fix gotol with large offsets + +The gotol implementation uses a wrong data type for the offset: it +should be s32 + Parent Hashes: 98e20e5e13d2811898921f999288be7151a11954 + Refs: not s16. + +Fixes: c690191e23d8 ("s390/bpf: Implement unconditional jump with 32-bit offset") +Signed-off-by: Ilya Leoshkevich +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240102193531.3169422-2-iii@linux.ibm.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes the offset data type for gotol implementation in s390 architecture of BPF.', 'keywords': 'gotol,offset,s390', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 98e20e5e13d2811898921f999288be7151a11954 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 98e20e5e13d2811898921f999288be7151a11954 + Author Name: Quentin Deslandes + Author Email: qde@naccy.de + Commit Date: 1704392590 + Commit Message: + bpfilter: remove bpfilter + +bpfilter was supposed to convert iptables filtering rules into +BPF programs on the fly + Parent Hashes: 9ddf872b47e3ac8f27dbfc4a4737a976c7588de6 + Refs: from the kernel + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove bpfilter module responsible for converting iptables rules into BPF programs.', 'keywords': 'bpfilter, iptables, removal', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 9ddf872b47e3ac8f27dbfc4a4737a976c7588de6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9ddf872b47e3ac8f27dbfc4a4737a976c7588de6 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704392294 + Commit Message: + bpf: Remove unnecessary cpu == 0 check in memalloc + +After merging the patch set [1] to reduce memory usage +for bpf_global_percpu_ma + Parent Hashes: c040e902b07e946ff73e81d4abb4347d2c0b6044 + Refs: Alexei found a redundant check (cpu == 0) +in function bpf_mem_alloc_percpu_unit_init() ([2]). +Indeed + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed an unnecessary cpu check in bpf_mem_alloc_percpu_unit_init function.', 'keywords': 'cpu, check, memalloc', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c312828c37a72fe2d033a961c47c227b0767e9f8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c312828c37a72fe2d033a961c47c227b0767e9f8 + Author Name: Andrea Righi + Author Email: andrea.righi@canonical.com + Commit Date: 1704384795 + Commit Message: + kernfs: convert kernfs_idr_lock to an irq safe raw spinlock + +bpf_cgroup_from_id() is basically a wrapper to cgroup_get_from_id() + Parent Hashes: 93ec4a3b76404bce01bd5c9032bef5df6feb1d62 + Refs: +that is relying on kernfs to determine the right cgroup associated to +the target id. + +As a kfunc + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Convert kernfs_idr_lock to irq safe raw spinlock for bpf_cgroup_from_id function.', 'keywords': 'kernfs, irq, spinlock', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: c040e902b07e946ff73e81d4abb4347d2c0b6044 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c040e902b07e946ff73e81d4abb4347d2c0b6044 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704346689 + Commit Message: + Merge branch 'libbpf-side-__arg_ctx-fallback-support' + +Andrii Nakryiko says: + +==================== +Libbpf-side __arg_ctx fallback support + +Support __arg_ctx global function argument tag semantics even on older kernels +that don't natively support it through btf_decl_tag("arg:ctx"). + +Patches #2-#6 are preparatory work to allow to postpone BTF loading into the +kernel until after all the BPF program relocations (including global func +appending to main programs) are done. Patch #4 is perhaps the most important +and establishes pre-created stable placeholder FDs + Parent Hashes: f8506c5734902ebda5c7b4778859b46d0a2ae5f3 95226f5a36695fd5740e130016d9ed697cfb2bad + Refs: so that relocations can +embed valid map FDs into ldimm64 instructions. + +Once BTF is done after relocation + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit merges support for __arg_ctx fallback in libbpf to older kernels without native support.', 'keywords': 'libbpf, __arg_ctx, BTF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 95226f5a36695fd5740e130016d9ed697cfb2bad +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 95226f5a36695fd5740e130016d9ed697cfb2bad + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345769 + Commit Message: + selftests/bpf: add __arg_ctx BTF rewrite test + +Add a test validating that libbpf uploads BTF and func_info with +rewritten type information for arguments of global subprogs that are +marked with __arg_ctx tag. + +Suggested-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240104013847.3875810-10-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 67fe459144dd629855bd9fb4b12bd9c4f792a8cf + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest to validate BTF and func_info type rewriting for global subprograms with __arg_ctx tag.', 'keywords': 'selftests,bpf,BTF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 67fe459144dd629855bd9fb4b12bd9c4f792a8cf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 67fe459144dd629855bd9fb4b12bd9c4f792a8cf + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345769 + Commit Message: + selftests/bpf: add arg:ctx cases to test_global_funcs tests + +Add a few extra cases of global funcs with context arguments. This time +rely on "arg:ctx" decl_tag (__arg_ctx macro) + Parent Hashes: 2f38fe689470055440bf80fc644920023a643a82 + Refs: but put it next to +"classic" cases where context argument has to be of an exact type that +BPF verifier expects (e.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test cases for global functions with context arguments using "arg:ctx" macro in BPF selftests.', 'keywords': 'test cases, global funcs, context arguments', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2f38fe689470055440bf80fc644920023a643a82 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2f38fe689470055440bf80fc644920023a643a82 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345769 + Commit Message: + libbpf: implement __arg_ctx fallback logic + +Out of all special global func arg tag annotations + Parent Hashes: 1004742d7ff03a088e74133af2401556ac80092b + Refs: __arg_ctx is +practically is the most immediately useful and most critical to have +working across multitude kernel version + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement __arg_ctx fallback logic in libbpf to ensure compatibility across various kernel versions.', 'keywords': 'libbpf, __arg_ctx, fallback', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1004742d7ff03a088e74133af2401556ac80092b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1004742d7ff03a088e74133af2401556ac80092b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345769 + Commit Message: + libbpf: move BTF loading step after relocation step + +With all the preparations in previous patches done we are ready to +postpone BTF loading and sanitization step until after all the +relocations are performed. + +Acked-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240104013847.3875810-7-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: fb03be7c4a27c25696287df4ee06c5aafa31267c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Postpone BTF loading until after relocations in libbpf.', 'keywords': 'BTF,relocation,libbpf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fb03be7c4a27c25696287df4ee06c5aafa31267c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fb03be7c4a27c25696287df4ee06c5aafa31267c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345769 + Commit Message: + libbpf: move exception callbacks assignment logic into relocation step + +Move the logic of finding and assigning exception callback indices from +BTF sanitization step to program relocations step + Parent Hashes: dac645b950ea4fc0896fe46a645365cb8d9ab92b + Refs: which seems more +logical and will unblock moving BTF loading to after relocation step. + +Exception callbacks discovery and assignment has no dependency on BTF +being loaded into the kernel + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor the exception callbacks assignment logic from BTF sanitization to program relocations step in libbpf.', 'keywords': 'libbpf, exception callbacks, relocation', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dac645b950ea4fc0896fe46a645365cb8d9ab92b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dac645b950ea4fc0896fe46a645365cb8d9ab92b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345769 + Commit Message: + libbpf: use stable map placeholder FDs + +Move map creation to later during BPF object loading by pre-creating +stable placeholder FDs (utilizing memfd_create()). Use dup2() +syscall to then atomically make those placeholder FDs point to real +kernel BPF map objects. + +This change allows to delay BPF map creation to after all the BPF +program relocations. That + Parent Hashes: f08c18e083adfef92946ae1d44b07bb81e727e08 + Refs: in turn + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit introduces stable map placeholder FDs for delayed BPF map creation in libbpf.', 'keywords': 'libbpf,placeholder FDs,map creation', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f08c18e083adfef92946ae1d44b07bb81e727e08 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f08c18e083adfef92946ae1d44b07bb81e727e08 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345769 + Commit Message: + libbpf: don't rely on map->fd as an indicator of map being created + +With the upcoming switch to preallocated placeholder FDs for maps + Parent Hashes: fa98b54bff39f51c46fc96d3385c6292391c277b + Refs: +switch various getters/setter away from checking map->fd. Use +map_is_created() helper that detect whether BPF map can be modified based +on map->obj->loaded state + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Switch libbpf to use map_is_created() instead of map->fd to detect map modification eligibility.', 'keywords': 'libbpf,map,fd', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fa98b54bff39f51c46fc96d3385c6292391c277b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fa98b54bff39f51c46fc96d3385c6292391c277b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345769 + Commit Message: + libbpf: use explicit map reuse flag to skip map creation steps + +Instead of inferring whether map already point to previously +created/pinned BPF map (which user can specify with bpf_map__reuse_fd()) API) + Parent Hashes: df7c3f7d3a3ddab31ca8cfa9b86a8729ec43fd2e + Refs: +use explicit map->reused flag that is set in such case. + +Acked-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240104013847.3875810-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit introduces an explicit map reuse flag to simplify map creation in libbpf.', 'keywords': 'explicit,map,reuse', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: df7c3f7d3a3ddab31ca8cfa9b86a8729ec43fd2e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: df7c3f7d3a3ddab31ca8cfa9b86a8729ec43fd2e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704345768 + Commit Message: + libbpf: make uniform use of btf__fd() accessor inside libbpf + +It makes future grepping and code analysis a bit easier. + +Acked-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240104013847.3875810-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: f8506c5734902ebda5c7b4778859b46d0a2ae5f3 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Standardize the use of btf__fd() accessor in libbpf for easier code maintenance.', 'keywords': 'libbpf, btf__fd, accessor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f8506c5734902ebda5c7b4778859b46d0a2ae5f3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f8506c5734902ebda5c7b4778859b46d0a2ae5f3 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704344907 + Commit Message: + Merge branch 'bpf-reduce-memory-usage-for-bpf_global_percpu_ma' + +Yonghong Song says: + +==================== +bpf: Reduce memory usage for bpf_global_percpu_ma + +Currently when a bpf program intends to allocate memory for percpu kptr + Parent Hashes: 417fa6d163df6f13fb2cfad5132eff354c8a472e adc8c4549d9e74d2359c217d2478b18ecdd15c91 + Refs: +the verifier will call bpf_mem_alloc_init() to prefill all supported +unit sizes and this caused memory consumption very big for large number +of cpus. For example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize memory usage in bpf programs by adjusting bpf_global_percpu_ma behavior.', 'keywords': 'bpf, memory, optimization', 'commit_classification': "It's a performance optimization.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: adc8c4549d9e74d2359c217d2478b18ecdd15c91 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: adc8c4549d9e74d2359c217d2478b18ecdd15c91 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704344906 + Commit Message: + selftests/bpf: Add a selftest with > 512-byte percpu allocation size + +Add a selftest to capture the verification failure when the allocation +size is greater than 512. + +Acked-by: Hou Tao +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20231222031812.1293190-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 21f5a801c171dff4e728e38f62cf626c4197d07c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a selftest for verification failure due to percpu allocation size exceeding 512 bytes.', 'keywords': 'selftest, percpu, allocation', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 21f5a801c171dff4e728e38f62cf626c4197d07c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 21f5a801c171dff4e728e38f62cf626c4197d07c + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704344906 + Commit Message: + selftests/bpf: Cope with 512 bytes limit with bpf_global_percpu_ma + +In the previous patch + Parent Hashes: 5c1a37653260ed5d9c8b26fb7fe7b99629612982 + Refs: the maximum data size for bpf_global_percpu_ma +is 512 bytes. This breaks selftest test_bpf_ma. The test is adjusted +in two aspects: + - Since the maximum allowed data size for bpf_global_percpu_ma is + 512 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adjust selftests to accommodate 512-byte limit of bpf_global_percpu_ma.', 'keywords': 'selftests, bpf_global_percpu_ma, limit', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 5c1a37653260ed5d9c8b26fb7fe7b99629612982 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5c1a37653260ed5d9c8b26fb7fe7b99629612982 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704344906 + Commit Message: + bpf: Limit up to 512 bytes for bpf_global_percpu_ma allocation + +For percpu data structure allocation with bpf_global_percpu_ma + Parent Hashes: 0e2ba9f96f9b82893ba19170ae48d46003f8ef44 + Refs: +the maximum data size is 4K. But for a system with large +number of cpus + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit limits bpf_global_percpu_ma allocation size to 512 bytes for handling large CPU systems.', 'keywords': 'bpf, percpu, allocation', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0e2ba9f96f9b82893ba19170ae48d46003f8ef44 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0e2ba9f96f9b82893ba19170ae48d46003f8ef44 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704344905 + Commit Message: + bpf: Use smaller low/high marks for percpu allocation + +Currently + Parent Hashes: 5b95e638f134e552b5ba2976326c02babe248615 + Refs: refill low/high marks are set with the assumption +of normal non-percpu memory allocation. For example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adjust low and high marks for more efficient percpu memory allocation in BPF.', 'keywords': 'BPF, percpu, allocation', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5b95e638f134e552b5ba2976326c02babe248615 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5b95e638f134e552b5ba2976326c02babe248615 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704344905 + Commit Message: + bpf: Refill only one percpu element in memalloc + +Typically for percpu map element or data structure + Parent Hashes: c39aa3b289e9c10d0d246cd919b06809f13b72b8 + Refs: once allocated + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize memory allocation by refilling only one percpu element in memalloc.', 'keywords': 'bpf, percpu, memalloc', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c39aa3b289e9c10d0d246cd919b06809f13b72b8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c39aa3b289e9c10d0d246cd919b06809f13b72b8 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704344905 + Commit Message: + bpf: Allow per unit prefill for non-fix-size percpu memory allocator + +Commit 41a5db8d8161 ("Add support for non-fix-size percpu mem allocation") +added support for non-fix-size percpu memory allocation. +Such allocation will allocate percpu memory for all buckets on all +cpus and the memory consumption is in the order to quadratic. +For example + Parent Hashes: 9fc8e802048ad150e8032c4f3dbf40112160cfe9 + Refs: let us say + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit allows per-unit prefill for non-fixed-size percpu memory allocator to optimize memory usage.', 'keywords': 'percpu,memory,allocator', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9fc8e802048ad150e8032c4f3dbf40112160cfe9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9fc8e802048ad150e8032c4f3dbf40112160cfe9 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704344905 + Commit Message: + bpf: Add objcg to bpf_mem_alloc + +The objcg is a bpf_mem_alloc level property since all bpf_mem_cache's +are with the same objcg. This patch made such a property explicit. +The next patch will use this property to save and restore objcg +for percpu unit allocator. + +Acked-by: Hou Tao +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20231222031739.1288590-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 9beda16c257d55213f70adee2f16d7f13a8502e1 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds objcg as a property to bpf_mem_alloc to enhance its functionality.', 'keywords': 'objcg,bpf_mem_alloc,property', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9beda16c257d55213f70adee2f16d7f13a8502e1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9beda16c257d55213f70adee2f16d7f13a8502e1 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1704344905 + Commit Message: + bpf: Avoid unnecessary extra percpu memory allocation + +Currently + Parent Hashes: 417fa6d163df6f13fb2cfad5132eff354c8a472e + Refs: for percpu memory allocation + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize bpf by preventing extra percpu memory allocation.', 'keywords': 'bpf, percpu, memory', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: bdbca46d3f84a4455cd5c15a7483666218851549 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bdbca46d3f84a4455cd5c15a7483666218851549 + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1704329422 + Commit Message: + bpf: sockmap + Parent Hashes: f1300467dd9f67293a7aae86fd26471520fac36d + Refs: add tests for proto updates replace socket + +Add test that replaces the same socket with itself. This exercises a +corner case where old element and new element have the same posck. +Test protocols: TCP + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added tests to handle cases where a socket element is replaced with itself in sockmap, particularly focusing on TCP protocols.', 'keywords': 'sockmap, tests, TCP', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: f1300467dd9f67293a7aae86fd26471520fac36d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f1300467dd9f67293a7aae86fd26471520fac36d + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1704329421 + Commit Message: + bpf: sockmap + Parent Hashes: 8c1b382a555adcd2008ae964047a35b739dfaf24 + Refs: add tests for proto updates single socket to many map + +Add test with multiple maps where each socket is inserted in multiple +maps. Test protocols: TCP + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add tests for handling multiple maps with single socket updates for TCP protocols.', 'keywords': 'sockmap,TCP,multiple maps', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 8c1b382a555adcd2008ae964047a35b739dfaf24 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8c1b382a555adcd2008ae964047a35b739dfaf24 + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1704329419 + Commit Message: + bpf: sockmap + Parent Hashes: 7865dfb1eb941ddd25802a9e13b6ff5f3f4dc02f + Refs: add tests for proto updates many to single map + +Add test with a single map where each socket is inserted multiple +times. Test protocols: TCP + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test cases for TCP protocol updates using a single sockmap with multiple socket entries.', 'keywords': 'test,TCP,sockmap', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 7865dfb1eb941ddd25802a9e13b6ff5f3f4dc02f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7865dfb1eb941ddd25802a9e13b6ff5f3f4dc02f + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1704329416 + Commit Message: + bpf: sockmap + Parent Hashes: 16b2f264983dc264c1560cc0170e760dec1bf54f + Refs: added comments describing update proto rules + +Add a comment describing that the psock update proto callbback can be +called multiple times and this must be safe. + +Signed-off-by: John Fastabend +Signed-off-by: Martin KaFai Lau +Reviewed-by: Jakub Sitnicki +Link: https://lore.kernel.org/r/20231221232327.43678-3-john.fastabend@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add comments in sockmap for psock update proto callback safety.', 'keywords': 'sockmap, psock, comments', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 16b2f264983dc264c1560cc0170e760dec1bf54f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 16b2f264983dc264c1560cc0170e760dec1bf54f + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1704329406 + Commit Message: + bpf: sockmap + Parent Hashes: b4560055c8f11c5e2cfffb4de928b3cfd4eae3b4 + Refs: fix proto update hook to avoid dup calls + +When sockets are added to a sockmap or sockhash we allocate and init a +psock. Then update the proto ops with sock_map_init_proto the flow is + + sock_hash_update_common + sock_map_link + psock = sock_map_psock_get_checked() <-returns existing psock + sock_map_init_proto(sk + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes proto update hook to prevent duplicate calls when adding sockets to sockmaps or sockhashes.', 'keywords': 'proto update, sockmap, duplicate calls', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 9c51f8788b5d4e9f46afbcf563255cfd355690b3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9c51f8788b5d4e9f46afbcf563255cfd355690b3 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1704315294 + Commit Message: + perf env: Avoid recursively taking env->bpf_progs.lock + +Add variants of perf_env__insert_bpf_prog_info() + Parent Hashes: 58824fa0087e1cb732edbf1f112a5ea0b2205c8b + Refs: perf_env__insert_btf() +and perf_env__find_btf prefixed with __ to indicate the +env->bpf_progs.lock is assumed held. + +Call these variants when the lock is held to avoid recursively taking it +and potentially having a thread deadlock with itself. + +Fixes: f8dfeae009effc0b ("perf bpf: Show more BPF program info in print_bpf_prog_info()") +Signed-off-by: Ian Rogers +Acked-by: Jiri Olsa +Acked-by: Song Liu +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: K Prateek Nayak +Cc: Kan Liang +Cc: Mark Rutland +Cc: Ming Wang +Cc: Namhyung Kim +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Link: https://lore.kernel.org/r/20231207014655.1252484-1-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit addresses a potential deadlock issue in perf env by modifying lock usage when handling bpf prog information.', 'keywords': 'perf, deadlock, lock', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b4560055c8f11c5e2cfffb4de928b3cfd4eae3b4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b4560055c8f11c5e2cfffb4de928b3cfd4eae3b4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704308904 + Commit Message: + Merge branch 'bpf-volatile-compare' + +Alexei Starovoitov says: + +==================== +bpf: volatile compare + +From: Alexei Starovoitov + +v2->v3: +Debugged profiler.c regression. It was caused by basic block layout. +Introduce bpf_cmp_likely() and bpf_cmp_unlikely() macros. +Debugged redundant <<=32 + Parent Hashes: a640de4cf9fec0caf43ccb7404ec9f0fde9a6a65 7e3811cb998f0e2493677c7daf6cefb4ece27111 + Refs: >>=32 with u32 variables. Added cast workaround. + +v1->v2: +Fixed issues pointed out by Daniel + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce bpf_cmp_likely() and bpf_cmp_unlikely() macros for optimizing volatile comparisons in BPF programs.', 'keywords': 'bpf,cmp,macros', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7e3811cb998f0e2493677c7daf6cefb4ece27111 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7e3811cb998f0e2493677c7daf6cefb4ece27111 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704308903 + Commit Message: + selftests/bpf: Convert profiler.c to bpf_cmp. + +Convert profiler[123].c to "volatile compare" to compare barrier_var() approach vs bpf_cmp_likely() vs bpf_cmp_unlikely(). + +bpf_cmp_unlikely() produces correct code + Parent Hashes: 0bcc62aa9813f519db58df14ddf1d523fa971e62 + Refs: but takes much longer to verify: + +./veristat -C -e prog + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Convert profiler test files to use bpf_cmp for volatile comparison.', 'keywords': 'selftests,bpf_cmp,profiler', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0bcc62aa9813f519db58df14ddf1d523fa971e62 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0bcc62aa9813f519db58df14ddf1d523fa971e62 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704308903 + Commit Message: + bpf: Add bpf_nop_mov() asm macro. + +bpf_nop_mov(var) asm macro emits nop register move: rX = rX. +If 'var' is a scalar and not a fixed constant the verifier will assign ID to it. +If it's later spilled the stack slot will carry that ID as well. +Hence the range refining comparison "if rX < const" will update all copies +including spilled slot. +This macro is a temporary workaround until the verifier gets smarter. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231226191148.48536-6-alexei.starovoitov@gmail.com + + Parent Hashes: 907dbd3ede5ffd4f9519dd1fae2a8a983603bf3b + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces a new bpf_nop_mov() macro for improved control over variable registration and ID tracking.', 'keywords': 'bpf_nop_mov, asm macro, verifier', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 907dbd3ede5ffd4f9519dd1fae2a8a983603bf3b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 907dbd3ede5ffd4f9519dd1fae2a8a983603bf3b + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704308903 + Commit Message: + selftests/bpf: Remove bpf_assert_eq-like macros. + +Since the last user was converted to bpf_cmp + Parent Hashes: 624cd2a17672f4596fee97a5558bc990778bbcf9 + Refs: remove bpf_assert_eq/ne/... macros. + +__bpf_assert_op() macro is kept for experiments + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes bpf_assert_eq macros from selftests as they are redundant with the new bpf_cmp macro.', 'keywords': 'selftests, macros, bpf_cmp', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 624cd2a17672f4596fee97a5558bc990778bbcf9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 624cd2a17672f4596fee97a5558bc990778bbcf9 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704308903 + Commit Message: + selftests/bpf: Convert exceptions_assert.c to bpf_cmp + +Convert exceptions_assert.c to bpf_cmp_unlikely() macro. + +Since + +bpf_assert(bpf_cmp_unlikely(var + Parent Hashes: a8b242d77bd72556b7a9d8be779f7d27b95ba73c + Refs: == + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Convert exceptions_assert.c in selftests to use bpf_cmp_unlikely() macro.', 'keywords': 'exceptions_assert,bpf_cmp_unlikely,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a8b242d77bd72556b7a9d8be779f7d27b95ba73c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a8b242d77bd72556b7a9d8be779f7d27b95ba73c + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704308322 + Commit Message: + bpf: Introduce "volatile compare" macros + +Compilers optimize conditional operators at will + Parent Hashes: 495d2d8133fd1407519170a5238f455abbd9ec9b + Refs: but often bpf programmers +want to force compilers to keep the same operator in asm as it's written in C. +Introduce bpf_cmp_likely/unlikely(var1 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces macros for volatile comparisons to aid bpf programmers in controlling compiler optimizations.', 'keywords': 'volatile, macros, operators', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 495d2d8133fd1407519170a5238f455abbd9ec9b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 495d2d8133fd1407519170a5238f455abbd9ec9b + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1704307282 + Commit Message: + selftests/bpf: Attempt to build BPF programs with -Wsign-compare + +GCC's -Wall includes -Wsign-compare while clang does not. +Since BPF programs are built with clang we need to add this flag explicitly +to catch problematic comparisons like: + + int i = -1; + unsigned int j = 1; + if (i < j) // this is false. + + long i = -1; + unsigned int j = 1; + if (i < j) // this is true. + +C standard for reference: + +- If either operand is unsigned long the other shall be converted to unsigned long. + +- Otherwise + Parent Hashes: a640de4cf9fec0caf43ccb7404ec9f0fde9a6a65 + Refs: if one operand is a long int and the other unsigned int + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add -Wsign-compare flag to clang when building BPF programs to catch signed/unsigned comparison issues.', 'keywords': 'BPF programs, -Wsign-compare, clang', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a640de4cf9fec0caf43ccb7404ec9f0fde9a6a65 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a640de4cf9fec0caf43ccb7404ec9f0fde9a6a65 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1704307077 + Commit Message: + Merge branch 'bpf-simplify-checking-size-of-helper-accesses' + +Andrei Matei says: + +==================== +bpf: Simplify checking size of helper accesses + +v3->v4: +- kept only the minimal change + Parent Hashes: 2ab1efad60ad119b616722b81eeb73060728028c 72187506de4f19fcc8ae63a2b2f36d75e5259d9d + Refs: undoing debatable changes (Andrii) +- dropped the second patch from before + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Simplifies checking the size of eBPF helper accesses by retaining minimal changes.', 'keywords': 'bpf, helper, simplify', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 72187506de4f19fcc8ae63a2b2f36d75e5259d9d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 72187506de4f19fcc8ae63a2b2f36d75e5259d9d + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1704307076 + Commit Message: + bpf: Add a possibly-zero-sized read test + +This patch adds a test for the condition that the previous patch mucked +with - illegal zero-sized helper memory access. As opposed to existing +tests + Parent Hashes: 8a021e7fa10576eeb3938328f39bbf98fe7d4715 + Refs: this new one uses a size whose lower bound is zero + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test for zero-sized helper memory access in eBPF.', 'keywords': 'test, zero-sized, memory', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8a021e7fa10576eeb3938328f39bbf98fe7d4715 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8a021e7fa10576eeb3938328f39bbf98fe7d4715 + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1704307076 + Commit Message: + bpf: Simplify checking size of helper accesses + +This patch simplifies the verification of size arguments associated to +pointer arguments to helpers and kfuncs. Many helpers take a pointer +argument followed by the size of the memory access performed to be +performed through that pointer. Before this patch + Parent Hashes: 2ab1efad60ad119b616722b81eeb73060728028c + Refs: the handling of the +size argument in check_mem_size_reg() was confusing and wasteful: if the +size register's lower bound was 0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit simplifies the verification of size arguments for helper and kfunc pointer accesses in eBPF.', 'keywords': 'simplify, helper, verification', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9b0a3839e8d29663cd9ee2c43d38b06c3b91619e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9b0a3839e8d29663cd9ee2c43d38b06c3b91619e + Author Name: Greg Kroah-Hartman + Author Email: gregkh@linuxfoundation.org + Commit Date: 1704191128 + Commit Message: + HID: bpf: make bus_type const in struct hid_bpf_ops + +The struct bus_type pointer in hid_bpf_ops just passes the pointer to +the driver core + Parent Hashes: c4a9743699f3b093bad4bcc472c4ee34c7929f33 + Refs: and the driver core can handle + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Make bus_type const in struct hid_bpf_ops to work with driver core.', 'keywords': 'HID,bus_type,const', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['HID driver like programs']} +-------------------- +-------------------- +Processing Commit ID: 240436c06ce992879d59e504b0df3d32deebb43e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 240436c06ce992879d59e504b0df3d32deebb43e + Author Name: David S. Miller + Author Email: davem@davemloft.net + Commit Date: 1704120321 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +bpf-next-for-netdev +The following pull-request contains BPF updates for your *net-next* tree. + +We've added 22 non-merge commits during the last 3 day(s) which contain +a total of 23 files changed + Parent Hashes: cff9c565e65f3622e8dc1dcc21c1520a083dff35 5abde62465222edd3080b70099bd809f166d5d7d + Refs: 652 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge bpf-next branch into the net-next tree with updates containing various BPF enhancements.', 'keywords': 'BPF, merge, updates', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fc044c53b99fad039ac30b95b289992ebf7dd6b4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fc044c53b99fad039ac30b95b289992ebf7dd6b4 + Author Name: Namhyung Kim + Author Email: namhyung@kernel.org + Commit Date: 1703381982 + Commit Message: + perf annotate-data: Add dso->data_types tree + +To aggregate accesses to the same data type + Parent Hashes: b9c87f536c6f28c75ace8a014646faad00f0e1ec + Refs: add 'data_types' tree in +DSO to maintain data types and find it by name and size. + +It might have different data types that happen to have the same name + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a data tree structure in DSO to manage and differentiate data types by name and size.', 'keywords': 'data tree, DSO, data types', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 2437c0f5147b82b92075af6085b99051753f4a3c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2437c0f5147b82b92075af6085b99051753f4a3c + Author Name: David S. Miller + Author Email: davem@davemloft.net + Commit Date: 1703291192 + Commit Message: + Merge branch 'net-selftests-unique-namespace-last-part' + +Hangbin Liu says: + +==================== +Convert net selftests to run in unique namespace (last part) + +Here is the last part of converting net selftests to run in unique namespace. +This part converts all left tests. After the conversion + Parent Hashes: 6530b29f77c8960bd21639ce71070499d155396b 9d0b4ad82d6117e6d7ead50f64be54ec782aa1fe + Refs: we can run the net +sleftests in parallel. e.g. + + # ./run_kselftest.sh -n -t net:reuseport_bpf + TAP version 13 + 1..1 + # selftests: net: reuseport_bpf + ok 1 selftests: net: reuseport_bpf + mod 10... + # Socket 0: 0 + # Socket 1: 1 + ... + # Socket 4: 19 + # Testing filter add without bind... + # SUCCESS + + # ./run_kselftest.sh -p -n -t net:cmsg_so_mark.sh -t net:cmsg_time.sh -t net:cmsg_ipv6.sh + TAP version 13 + 1..3 + # selftests: net: cmsg_so_mark.sh + ok 1 selftests: net: cmsg_so_mark.sh + # selftests: net: cmsg_time.sh + ok 2 selftests: net: cmsg_time.sh + # selftests: net: cmsg_ipv6.sh + ok 3 selftests: net: cmsg_ipv6.sh + + # ./run_kselftest.sh -p -n -c net + TAP version 13 + 1..95 + # selftests: net: reuseport_bpf_numa + ok 3 selftests: net: reuseport_bpf_numa + # selftests: net: reuseport_bpf_cpu + ok 2 selftests: net: reuseport_bpf_cpu + # selftests: net: sk_bind_sendto_listen + ok 9 selftests: net: sk_bind_sendto_listen + # selftests: net: reuseaddr_conflict + ok 5 selftests: net: reuseaddr_conflict + ... + +Here is the part 1 link: +https://lore.kernel.org/netdev/20231202020110.362433-1-liuhangbin@gmail.com +part 2 link: +https://lore.kernel.org/netdev/20231206070801.1691247-1-liuhangbin@gmail.com +part 3 link: +https://lore.kernel.org/netdev/20231213060856.4030084-1-liuhangbin@gmail.com +==================== + +Signed-off-by: David S. Miller + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Convert remaining net selftests to run in unique namespaces for parallel execution.', 'keywords': 'net selftests, unique namespace, parallel execution', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 5abde62465222edd3080b70099bd809f166d5d7d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5abde62465222edd3080b70099bd809f166d5d7d + Author Name: Simon Horman + Author Email: horms@kernel.org + Commit Date: 1703194825 + Commit Message: + bpf: Avoid unnecessary use of comma operator in verifier + +Although it does not seem to have any untoward side-effects + Parent Hashes: b08c8fc0411dce0fc44b78ce4d67f1b67c35c196 + Refs: the use +of ';' to separate to assignments seems more appropriate than ' + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit improves the eBPF verifier by avoiding unnecessary use of the comma operator in assignments.', 'keywords': 'bpf, verifier, comma', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7c5e046bdcb2513f9decb3765d8bf92d604279cf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7c5e046bdcb2513f9decb3765d8bf92d604279cf + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1703178937 + Commit Message: + Merge tag 'net-6.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + "Including fixes from WiFi and bpf. + + Current release - regressions: + + - bpf: syzkaller found null ptr deref in unix_bpf proto add + + - eth: i40e: fix ST code value for clause 45 + + Previous releases - regressions: + + - core: return error from sk_stream_wait_connect() if sk_wait_event() + fails + + - ipv6: revert remove expired routes with a separated list of routes + + - wifi rfkill: + - set GPIO direction + - fix crash with WED rx support enabled + + - bluetooth: + - fix deadlock in vhci_send_frame + - fix use-after-free in bt_sock_recvmsg + + - eth: mlx5e: fix a race in command alloc flow + + - eth: ice: fix PF with enabled XDP going no-carrier after reset + + - eth: bnxt_en: do not map packet buffers twice + + Previous releases - always broken: + + - core: + - check vlan filter feature in vlan_vids_add_by_dev() and + vlan_vids_del_by_dev() + - check dev->gso_max_size in gso_features_check() + + - mptcp: fix inconsistent state on fastopen race + + - phy: skip LED triggers on PHYs on SFP modules + + - eth: mlx5e: + - fix double free of encap_header + - fix slab-out-of-bounds in mlx5_query_nic_vport_mac_list()" + +* tag 'net-6.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (69 commits) + net: check dev->gso_max_size in gso_features_check() + kselftest: rtnetlink.sh: use grep_fail when expecting the cmd fail + net/ipv6: Revert remove expired routes with a separated list of routes + net: avoid build bug in skb extension length calculation + net: ethernet: mtk_wed: fix possible NULL pointer dereference in mtk_wed_wo_queue_tx_clean() + net: stmmac: fix incorrect flag check in timestamp interrupt + selftests: add vlan hw filter tests + net: check vlan filter feature in vlan_vids_add_by_dev() and vlan_vids_del_by_dev() + net: hns3: add new maintainer for the HNS3 ethernet driver + net: mana: select PAGE_POOL + net: ks8851: Fix TX stall caused by TX buffer overrun + ice: Fix PF with enabled XDP going no-carrier after reset + ice: alter feature support check for SRIOV and LAG + ice: stop trashing VF VSI aggregator node ID information + mailmap: add entries for Geliang Tang + mptcp: fill in missing MODULE_DESCRIPTION() + mptcp: fix inconsistent state on fastopen race + selftests: mptcp: join: fix subflow_send_ack lookup + net: phy: skip LED triggers on PHYs on SFP modules + bpf: Add missing BPF_LINK_TYPE invocations + ... + + Parent Hashes: a4aebe936554dac6a91e5d091179c934f8325708 74769d810ead7e7af1a481f07a4d890861a6a4cc + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes including bpf and WiFi enhancements for current and previous release regressions.', 'keywords': 'networking, fixes, bpf', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['xdp like programs', 'socket like programs', 'tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: b08c8fc0411dce0fc44b78ce4d67f1b67c35c196 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b08c8fc0411dce0fc44b78ce4d67f1b67c35c196 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1703165070 + Commit Message: + bpf: Re-support uid and gid when mounting bpffs + +For a clean + Parent Hashes: fc3a5534e2a8855427403113cbeb54af5837bbe0 + Refs: conflict-free revert of the token-related patches in commit +d17aff807f84 ("Revert BPF token-related functionality") + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Re-supporting uid and gid functionality when mounting bpf filesystem with bpffs.', 'keywords': 'uid,gid,bpffs', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 74769d810ead7e7af1a481f07a4d890861a6a4cc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 74769d810ead7e7af1a481f07a4d890861a6a4cc + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1703158049 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-12-21 + +Hi David + Parent Hashes: 24ab059d2ebd62fdccc43794796f6ffbabe49ebc 117211aa739a926e6555cfea883be84bee6f1695 + Refs: hi Jakub + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merge branch 'for-netdev' from bpf to merge the latest changes.", 'keywords': 'merge, netdev, bpf', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: fc3a5534e2a8855427403113cbeb54af5837bbe0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fc3a5534e2a8855427403113cbeb54af5837bbe0 + Author Name: Mingyi Zhang + Author Email: zhangmingyi5@huawei.com + Commit Date: 1703149542 + Commit Message: + libbpf: Fix NULL pointer dereference in bpf_object__collect_prog_relos + +An issue occurred while reading an ELF file in libbpf.c during fuzzing: + + Program received signal SIGSEGV + Parent Hashes: 812d8bf87678f77055b575d20636fdbbbf15edaf + Refs: Segmentation fault. + 0x0000000000958e97 in bpf_object.collect_prog_relos () at libbpf.c:4206 + 4206 in libbpf.c + (gdb) bt + #0 0x0000000000958e97 in bpf_object.collect_prog_relos () at libbpf.c:4206 + #1 0x000000000094f9d6 in bpf_object.collect_relos () at libbpf.c:6706 + #2 0x000000000092bef3 in bpf_object_open () at libbpf.c:7437 + #3 0x000000000092c046 in bpf_object.open_mem () at libbpf.c:7497 + #4 0x0000000000924afa in LLVMFuzzerTestOneInput () at fuzz/bpf-object-fuzzer.c:16 + #5 0x000000000060be11 in testblitz_engine::fuzzer::Fuzzer::run_one () + #6 0x000000000087ad92 in tracing::span::Span::in_scope () + #7 0x00000000006078aa in testblitz_engine::fuzzer::util::walkdir () + #8 0x00000000005f3217 in testblitz_engine::entrypoint::main::{{closure}} () + #9 0x00000000005f2601 in main () + (gdb) + +scn_data was null at this code(tools/lib/bpf/src/libbpf.c): + + if (rel->r_offset % BPF_INSN_SZ || rel->r_offset >= scn_data->d_size) { + +The scn_data is derived from the code above: + + scn = elf_sec_by_idx(obj + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a NULL pointer dereference in libbpf during ELF file processing.', 'keywords': 'NULL,libbpf,dereference', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 812d8bf87678f77055b575d20636fdbbbf15edaf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 812d8bf87678f77055b575d20636fdbbbf15edaf + Author Name: Alyssa Ross + Author Email: hi@alyssa.is + Commit Date: 1703149515 + Commit Message: + libbpf: Skip DWARF sections in linker sanity check + +clang can generate (with -g -Wa + Parent Hashes: 92999245102a09ab2645424a9c9a0a5b16fda833 + Refs: --compress-debug-sections) 4-byte +aligned DWARF sections that declare themselves to be 8-byte aligned in +the section header. Since DWARF sections are dropped during linking +anyway + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies libbpf to skip DWARF sections in the linker sanity check.', 'keywords': 'libbpf, DWARF, linker', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 92999245102a09ab2645424a9c9a0a5b16fda833 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 92999245102a09ab2645424a9c9a0a5b16fda833 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1703107547 + Commit Message: + Merge branch 'bpf-fix-warning-in-check_obj_size' + +Hou Tao says: + +==================== +bpf: Fix warning in check_obj_size() + +From: Hou Tao + +Hi + Parent Hashes: 32f24938a1fce95fce314c1fa9a72af74588ea6c 69ff403d87be4812571c54b1159e24998414bcab + Refs: + +The patch set aims to fix the warning in check_obj_size() as reported by +lkp [1]. Patch #1 fixes the warning by selecting target cache for free +request through c->unit_size + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a warning in check_obj_size function within the BPF subsystem.', 'keywords': 'warning, check_obj_size, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 69ff403d87be4812571c54b1159e24998414bcab +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 69ff403d87be4812571c54b1159e24998414bcab + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1703107546 + Commit Message: + selftests/bpf: Remove tests for zeroed-array kptr + +bpf_mem_alloc() doesn't support zero-sized allocation + Parent Hashes: 7ac5c53e00735d183a0f5e2cfce5eeb6c16319f2 + Refs: so removing these +tests from test_bpf_ma test. After the removal + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed tests for zeroed-array kptr in selftests due to unsupported zero-sized allocations in bpf_mem_alloc().', 'keywords': 'zeroed-array kptr, bpf_mem_alloc, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7ac5c53e00735d183a0f5e2cfce5eeb6c16319f2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7ac5c53e00735d183a0f5e2cfce5eeb6c16319f2 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1703107546 + Commit Message: + bpf: Use c->unit_size to select target cache during free + +At present + Parent Hashes: 32f24938a1fce95fce314c1fa9a72af74588ea6c + Refs: bpf memory allocator uses check_obj_size() to ensure that +ksize() of allocated pointer is equal with the unit_size of used +bpf_mem_cache. Its purpose is to prevent bpf_mem_free() from selecting +a bpf_mem_cache which has different unit_size compared with the +bpf_mem_cache used for allocation. But as reported by lkp + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed unit size selection in bpf_mem_free to match allocation cache unit size.', 'keywords': 'unit_size, bpf_mem_cache, allocation', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e77b0236cd0cd1572c6a9b25097b207eab799e74 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e77b0236cd0cd1572c6a9b25097b207eab799e74 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1703094970 + Commit Message: + perf maps: Add maps__load_first() + +Avoid bpf_lock_contention_read touching the internal maps data structure +by adding a helper function. As access is done directly on the map in +maps + Parent Hashes: 9084952704ba075de28684301ec282b6626b5e7a + Refs: hold the read lock to stop it being removed. + +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Andi Kleen +Cc: Athira Rajeev +Cc: Changbin Du +Cc: Colin Ian King +Cc: Dmitrii Dolgov <9erthalion6@gmail.com> +Cc: German Gomez +Cc: Guilherme Amadio +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: James Clark +Cc: Jiri Olsa +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Li Dong +Cc: Liam Howlett +Cc: Mark Rutland +Cc: Masami Hiramatsu +Cc: Miguel Ojeda +Cc: Ming Wang +Cc: Namhyung Kim +Cc: Nick Terrell +Cc: Paolo Bonzini +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Vincent Whitchurch +Cc: Wenyu Liu +Cc: Yang Jihong +Link: https://lore.kernel.org/r/20231207011722.1220634-20-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Introduces the maps__load_first() helper function to reduce bpf_lock_contention_read's interaction with internal map data structures.", 'keywords': 'perf maps, helper function, lock contention', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 32f24938a1fce95fce314c1fa9a72af74588ea6c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 32f24938a1fce95fce314c1fa9a72af74588ea6c + Author Name: Colin Ian King + Author Email: colin.i.king@gmail.com + Commit Date: 1703082539 + Commit Message: + samples/bpf: Use %lu format specifier for unsigned long values + +Currently %ld format specifiers are being used for unsigned long +values. Fix this by using %lu instead. Cleans up cppcheck warnings: + +warning: %ld in format string (no. 1) requires 'long' but the argument +type is 'unsigned long'. [invalidPrintfArgType_sint] + +Signed-off-by: Colin Ian King +Signed-off-by: Daniel Borkmann +Reviewed-by: Randy Dunlap +Link: https://lore.kernel.org/bpf/20231219152307.368921-1-colin.i.king@gmail.com + + Parent Hashes: 441c725ed592cb22f2a82f2827dccd045356cc81 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix format specifiers in sample BPF code from %ld to %lu for unsigned long values to resolve cppcheck warnings.', 'keywords': 'format specifiers, cppcheck, cleanup', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 441c725ed592cb22f2a82f2827dccd045356cc81 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 441c725ed592cb22f2a82f2827dccd045356cc81 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1703038931 + Commit Message: + selftests/bpf: Close cgrp fd before calling cleanup_cgroup_environment() + +There is error log when htab-mem benchmark completes. The error log +looks as follows: + +$ ./bench htab-mem -d1 +Setting up benchmark 'htab-mem'... +Benchmark 'htab-mem' started. +...... +(cgroup_helpers.c:353: errno: Device or resource busy) umount cgroup2 + +Fix it by closing cgrp fd before invoking cleanup_cgroup_environment(). + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231219135727.2661527-1-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 85dd93ac6e00adf09fc27e4d2e7f5c9aaf275d38 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix htab-mem benchmark error by closing cgroup file descriptor before cleanup.', 'keywords': 'htab-mem,close,cgroup', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 85dd93ac6e00adf09fc27e4d2e7f5c9aaf275d38 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 85dd93ac6e00adf09fc27e4d2e7f5c9aaf275d38 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1703038007 + Commit Message: + Merge branch 'enhance-bpf-global-subprogs-with-argument-tags' + +Andrii Nakryiko says: + +==================== +Enhance BPF global subprogs with argument tags + +This patch set adds verifier support for annotating user's global BPF subprog +arguments with few commonly requested annotations + Parent Hashes: c337f237291b41b308c80124236876cf66c77906 f0a5056222f2cfa6d40b4c888cb6b01e8569e282 + Refs: to improve global subprog +verification experience. + +These tags are: + - ability to annotate a special PTR_TO_CTX argument; + - ability to annotate a generic PTR_TO_MEM as non-null. + +We utilize btf_decl_tag attribute for this and provide two helper macros as +part of bpf_helpers.h in libbpf (patch #8). + +Besides this we also add abilit to pass a pointer to dynptr into global +subprog. This is done based on type name match (struct bpf_dynptr *). This +allows to pass dynptrs into global subprogs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance BPF subprograms with argument tags for improved global subprogram verification experience.', 'keywords': 'BPF, argument, tags', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f0a5056222f2cfa6d40b4c888cb6b01e8569e282 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f0a5056222f2cfa6d40b4c888cb6b01e8569e282 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038007 + Commit Message: + selftests/bpf: add freplace of BTF-unreliable main prog test + +Add a test validating that freplace'ing another main (entry) BPF program +fails if the target BPF program doesn't have valid/expected func proto BTF. + +We extend fexit_bpf2bpf test to allow to specify expected log message +for negative test cases (where freplace program is expected to fail to +load). + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231215011334.2307144-11-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 0a0ffcac92d5b41133c97d260ad1f320572783a5 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a self-test for freplace of BTF-unreliable main BPF programs.', 'keywords': 'self-test,BTF-unreliable,freplace', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0a0ffcac92d5b41133c97d260ad1f320572783a5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0a0ffcac92d5b41133c97d260ad1f320572783a5 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038007 + Commit Message: + selftests/bpf: add global subprog annotation tests + +Add test cases to validate semantics of global subprog argument +annotations: + - non-null pointers; + - context argument; + - const dynptr passing; + - packet pointers (data + Parent Hashes: aae9c25dda159045b223ecb471cd0729ccec8285 + Refs: metadata + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test cases for global subprog argument annotations in BPF selftests.', 'keywords': 'selftests, annotations, subprog', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: aae9c25dda159045b223ecb471cd0729ccec8285 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: aae9c25dda159045b223ecb471cd0729ccec8285 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038007 + Commit Message: + libbpf: add __arg_xxx macros for annotating global func args + +Add a set of __arg_xxx macros which can be used to augment BPF global +subprogs/functions with extra information for use by BPF verifier. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231215011334.2307144-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: a64bfe618665ea9c722f922cba8c6e3234eac5ac + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds __arg_xxx macros to annotate global BPF functions for the verifier.', 'keywords': 'macros, global functions, verifier', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a64bfe618665ea9c722f922cba8c6e3234eac5ac +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a64bfe618665ea9c722f922cba8c6e3234eac5ac + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038006 + Commit Message: + bpf: add support for passing dynptr pointer to global subprog + +Add ability to pass a pointer to dynptr into global functions. +This allows to have global subprogs that accept and work with generic +dynptrs that are created by caller. Dynptr argument is detected based on +the name of a struct type + Parent Hashes: 94e1c70a34523b5e1529e4ec508316acc6a26a2b + Refs: if it's "bpf_dynptr" + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for passing dynamic pointer to global subprograms in BPF.', 'keywords': 'dynptr, global, subprog', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 94e1c70a34523b5e1529e4ec508316acc6a26a2b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 94e1c70a34523b5e1529e4ec508316acc6a26a2b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038006 + Commit Message: + bpf: support 'arg:xxx' btf_decl_tag-based hints for global subprog args + +Add support for annotating global BPF subprog arguments to provide more +information about expected semantics of the argument. Currently + Parent Hashes: f18c3d88deedf0defc3e4800341cc7bcaaabcdf9 + Refs: +verifier relies purely on argument's BTF type information + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for BTF declaration tag-based hints for global eBPF subprogram arguments.', 'keywords': 'BTF, subprogram, hints', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f18c3d88deedf0defc3e4800341cc7bcaaabcdf9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f18c3d88deedf0defc3e4800341cc7bcaaabcdf9 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038006 + Commit Message: + bpf: reuse subprog argument parsing logic for subprog call checks + +Remove duplicated BTF parsing logic when it comes to subprog call check. +Instead + Parent Hashes: c5a7244759b1eeacc59d0426fb73859afa942d0d + Refs: use (potentially cached) results of btf_prepare_func_args() to +abstract away expectations of each subprog argument in generic terms +(e.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes duplicated BTF parsing logic for subprogram call checks and improves argument parsing.', 'keywords': 'BTF, parsing, subprog', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c5a7244759b1eeacc59d0426fb73859afa942d0d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c5a7244759b1eeacc59d0426fb73859afa942d0d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038006 + Commit Message: + bpf: move subprog call logic back to verifier.c + +Subprog call logic in btf_check_subprog_call() currently has both a lot +of BTF parsing logic (which is + Parent Hashes: e26080d0da87f20222ca6712b65f95a856fadee0 + Refs: presumably + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit moves subprogram call logic back to verifier.c to separate it from BTF parsing logic.', 'keywords': 'subprog, verifier, BTF', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e26080d0da87f20222ca6712b65f95a856fadee0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e26080d0da87f20222ca6712b65f95a856fadee0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038006 + Commit Message: + bpf: prepare btf_prepare_func_args() for handling static subprogs + +Generalize btf_prepare_func_args() to support both global and static +subprogs. We are going to utilize this property in the next patch + Parent Hashes: 5eccd2db42d77e3570619c32d39e39bf486607cf + Refs: +reusing btf_prepare_func_args() for subprog call logic instead of +reparsing BTF information in a completely separate implementation. + +btf_prepare_func_args() now detects whether subprog is global or static +makes slight logic adjustments for static func cases + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Generalize btf_prepare_func_args() to support both global and static subprograms for BTF information parsing.', 'keywords': 'BTF, subprog, function', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5eccd2db42d77e3570619c32d39e39bf486607cf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5eccd2db42d77e3570619c32d39e39bf486607cf + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038006 + Commit Message: + bpf: reuse btf_prepare_func_args() check for main program BTF validation + +Instead of btf_check_subprog_arg_match() + Parent Hashes: 4ba1d0f23414135e4f426dae4cb5cdc2ce246f89 + Refs: use btf_prepare_func_args() +logic to validate "trustworthiness" of main BPF program's BTF information + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves main BPF program BTF validation by reusing btf_prepare_func_args() check.', 'keywords': 'BPF,BTF,validation', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4ba1d0f23414135e4f426dae4cb5cdc2ce246f89 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4ba1d0f23414135e4f426dae4cb5cdc2ce246f89 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703038006 + Commit Message: + bpf: abstract away global subprog arg preparation logic from reg state setup + +btf_prepare_func_args() is used to understand expectations and +restrictions on global subprog arguments. But current implementation is +hard to extend + Parent Hashes: c337f237291b41b308c80124236876cf66c77906 + Refs: as it intermixes BTF-based func prototype parsing and +interpretation logic with setting up register state at subprog entry. + +Worse still + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor global subprog argument handling logic for better extensibility in bpf.', 'keywords': 'global subprog, argument, extensibility', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c337f237291b41b308c80124236876cf66c77906 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c337f237291b41b308c80124236876cf66c77906 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1703035136 + Commit Message: + Merge branch 'bpf-support-to-track-bpf_jne' + +Menglong Dong says: + +==================== +bpf: support to track BPF_JNE + +For now + Parent Hashes: 1728df7fc11bf09322852ff05e73908244011594 463ea64eb008b7abb63245ed69446b404bf042b1 + Refs: the reg bounds is not handled for BPF_JNE case + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for tracking BPF_JNE instruction in the eBPF verifier.', 'keywords': 'BPF_JNE, verifier, tracking', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 463ea64eb008b7abb63245ed69446b404bf042b1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 463ea64eb008b7abb63245ed69446b404bf042b1 + Author Name: Menglong Dong + Author Email: menglong8.dong@gmail.com + Commit Date: 1703035136 + Commit Message: + selftests/bpf: add testcase to verifier_bounds.c for BPF_JNE + +Add testcase for the logic that the verifier tracks the BPF_JNE for regs. +The assembly function "reg_not_equal_const()" and "reg_equal_const" that +we add is exactly converted from the following case: + + u32 a = bpf_get_prandom_u32(); + u64 b = 0; + + a %= 8; + /* the "a > 0" here will be optimized to "a != 0" */ + if (a > 0) { + /* now the range of a should be [1 + Parent Hashes: 31d9cc96b1e3b28daf74938cb1233231474bbcf6 + Refs: 7] */ + bpf_skb_store_bytes(skb + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added new test case in selftests for BPF_JNE behavior in verifier_bounds.c.', 'keywords': 'testcase,BPF_JNE,verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 31d9cc96b1e3b28daf74938cb1233231474bbcf6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 31d9cc96b1e3b28daf74938cb1233231474bbcf6 + Author Name: Menglong Dong + Author Email: menglong8.dong@gmail.com + Commit Date: 1703035135 + Commit Message: + selftests/bpf: activate the OP_NE logic in range_cond() + +The edge range checking for the registers is supported by the verifier +now + Parent Hashes: 1de584832375d0dc4234ee406185384a58fb96ac + Refs: so we can activate the extended logic in +tools/testing/selftests/bpf/prog_tests/reg_bounds.c/range_cond() to test +such logic. + +Besides + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit activates the OP_NE logic in range_cond() for testing edge range checking in the BPF verifier.', 'keywords': 'OP_NE, range_cond, verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1de584832375d0dc4234ee406185384a58fb96ac +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1de584832375d0dc4234ee406185384a58fb96ac + Author Name: Menglong Dong + Author Email: menglong8.dong@gmail.com + Commit Date: 1703035135 + Commit Message: + selftests/bpf: remove reduplicated s32 casting in "crafted_cases" + +The "S32_MIN" is already defined with s32 casting + Parent Hashes: d028f87517d6775dccff4ddbca2740826f9e53f1 + Refs: so there is no need +to do it again. + +Signed-off-by: Menglong Dong +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231219134800.1550388-3-menglong8.dong@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Removed redundant s32 casting in selftests/bpf 'crafted_cases'.", 'keywords': 'reduplicated,s32,casting', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d028f87517d6775dccff4ddbca2740826f9e53f1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d028f87517d6775dccff4ddbca2740826f9e53f1 + Author Name: Menglong Dong + Author Email: menglong8.dong@gmail.com + Commit Date: 1703035135 + Commit Message: + bpf: make the verifier tracks the "not equal" for regs + +We can derive some new information for BPF_JNE in regs_refine_cond_op(). +Take following code for example: + + /* The type of "a" is u32 */ + if (a > 0 && a < 100) { + /* the range of the register for a is [0 + Parent Hashes: 1728df7fc11bf09322852ff05e73908244011594 + Refs: 99] + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Improve the eBPF verifier to track 'not equal' conditions for register refinements.", 'keywords': 'verifier, BPF_JNE, refine', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1728df7fc11bf09322852ff05e73908244011594 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1728df7fc11bf09322852ff05e73908244011594 + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1703007328 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-12-19 + +Hi David + Parent Hashes: 62ed78f3baff396bd928ee77077580c5aa940149 d17aff807f845cf93926c28705216639c7279110 + Refs: hi Jakub + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge updates from the bpf-next branch into the main branch.', 'keywords': 'merge,bpf-next,update', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d17aff807f845cf93926c28705216639c7279110 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d17aff807f845cf93926c28705216639c7279110 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1703002983 + Commit Message: + Revert BPF token-related functionality + +This patch includes the following revert (one conflicting BPF FS +patch and three token patch sets + Parent Hashes: 2130c519a401e576647040043cb46d6fdc361dcc + Refs: represented by merge commits): + - revert 0f5d5454c723 "Merge branch 'bpf-fs-mount-options-parsing-follow-ups'"; + - revert 750e785796bb "bpf: Support uid and gid when mounting bpffs"; + - revert 733763285acf "Merge branch 'bpf-token-support-in-libbpf-s-bpf-object'"; + - revert c35919dcce28 "Merge branch 'bpf-token-and-bpf-fs-based-delegation'". + +Link: https://lore.kernel.org/bpf/CAHk-=wg7JuFYwGy=GOMbRCtOL+jwSQsdUaBsRWkDVYbxipbM5A@mail.gmail.com +Signed-off-by: Andrii Nakryiko + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Revert BPF token-related functionality due to conflicting changes in BPF FS and token patch sets.', 'keywords': 'revert, BPF token, conflict', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 2130c519a401e576647040043cb46d6fdc361dcc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2130c519a401e576647040043cb46d6fdc361dcc + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1702995640 + Commit Message: + bpf: Use nla_ok() instead of checking nla_len directly + +nla_len may also be too short to be sane + Parent Hashes: f7dd48ea76be30666f0614d6a06061185ed38c60 + Refs: in which case after +recent changes nla_len() will return a wrapped value. + +Fixes: 172db56d90d2 ("netlink: Return unsigned value for nla_len()") +Reported-by: syzbot+f43a23b6e622797c7a28@syzkaller.appspotmail.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Daniel Borkmann +Reviewed-by: Simon Horman +Link: https://lore.kernel.org/bpf/20231218231904.260440-1-kuba@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix issue with nlattr length checking by using nla_ok() to ensure valid checks in eBPF.', 'keywords': 'nla_ok,nla_len,eBPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 624dda101e03c3a3a155d51e37a7bb7607cb760b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 624dda101e03c3a3a155d51e37a7bb7607cb760b + Author Name: Veronika Molnarova + Author Email: vmolnaro@redhat.com + Commit Date: 1702993699 + Commit Message: + perf archive: Add new option '--all' to pack perf.data with DSOs + +'perf archive' has limited functionality and people from Red Hat Global +Support Services sent a request for a new feature that would pack +perf.data file together with an archive with debug symbols created by +the command 'perf archive' as customers were being confused and often +would forget to send perf.data file with the debug symbols. + +With this patch 'perf archive' now accepts an option '--all' that +generates archive 'perf.all-hostname-date-time.tar.bz2' that holds file +'perf.data' and a sub-tar 'perf.symbols.tar.bz2' with debug symbols. The +functionality of the command 'perf archive' was not changed. + +Committer testing: + +Run 'perf record' on a Intel 14900K machine + Parent Hashes: ab1c247094e323177a578b38f0325bf79f0317ac + Refs: hybrid: + + root@number:~# perf record -a sleep 5s + [ perf record: Woken up 1 times to write data ] + [ perf record: Captured and wrote 4.006 MB perf.data (15427 samples) ] + root@number:~# perf archive --all + Now please run: + + $ tar xvf perf.all-number-20231219-104854.tar.bz2 && tar xvf perf.symbols.tar.bz2 -C ~/.debug + + wherever you need to run 'perf report' on. + root@number:~# + + root@number:~# perf report --header-only + # ======== + # captured on : Tue Dec 19 10:48:48 2023 + # header version : 1 + # data offset : 1008 + # data size : 4199936 + # feat offset : 4200944 + # hostname : number + # os release : 6.6.4-200.fc39.x86_64 + # perf version : 6.7.rc6.gca90f8e17b84 + # arch : x86_64 + # nrcpus online : 28 + # nrcpus avail : 28 + # cpudesc : Intel(R) Core(TM) i7-14700K + # cpuid : GenuineIntel + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Add '--all' option to 'perf archive' for packing perf.data with debug symbols.", 'keywords': 'perf archive option', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c49b292d031e385abf764ded32cd953c77e73f2d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c49b292d031e385abf764ded32cd953c77e73f2d + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1702946768 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Alexei Starovoitov says: + +==================== +pull-request: bpf-next 2023-12-18 + +This PR is larger than usual and contains changes in various parts +of the kernel. + +The main changes are: + +1) Fix kCFI bugs in BPF + Parent Hashes: 0ee28c9ae042e77100fae2cd82a54750668aafce 8e432e6197cef6250dfd6fdffd41c06613c874ca + Refs: from Peter Zijlstra. + +End result: all forms of indirect calls from BPF into kernel +and from kernel into BPF work with CFI enabled. This allows BPF +to work with CONFIG_FINEIBT=y. + +2) Introduce BPF token object + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit merges changes including a fix for kCFI bugs and the introduction of the BPF token object.', 'keywords': 'kCFI, BPF, token', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8e432e6197cef6250dfd6fdffd41c06613c874ca +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8e432e6197cef6250dfd6fdffd41c06613c874ca + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702940061 + Commit Message: + bpf: Ensure precise is reset to false in __mark_reg_const_zero() + +It is safe to always start with imprecise SCALAR_VALUE register. +Previously __mark_reg_const_zero() relied on caller to reset precise +mark + Parent Hashes: 6079ae6376181b49c9e4d65ef9fe954cca4974bd + Refs: but it's very error prone and we already missed it in a few +places. So instead make __mark_reg_const_zero() reset precision always + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit ensures precision is reset to false in __mark_reg_const_zero() to avoid error prone reliance on callers.', 'keywords': 'precision,register,reset', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6079ae6376181b49c9e4d65ef9fe954cca4974bd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6079ae6376181b49c9e4d65ef9fe954cca4974bd + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702921937 + Commit Message: + Merge branch 'bpf-add-check-for-negative-uprobe-multi-offset' + +Jiri Olsa says: + +==================== +bpf: Add check for negative uprobe multi offset + +hi + Parent Hashes: e58aac1a9a179fa9dab3025ef955cdb548c439f2 f17d1a18a3dd6cc4b38a5226b0acbbad3f2063ae + Refs: +adding the check for negative offset for uprobe multi link. + +v2 changes: +- add more failure checks [Alan] +- move the offset retrieval/check up in the loop to be done earlier [Song] + +thanks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a check for negative offset in uprobe multi-links in eBPF.', 'keywords': 'check,offset,uprobe', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: f17d1a18a3dd6cc4b38a5226b0acbbad3f2063ae +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f17d1a18a3dd6cc4b38a5226b0acbbad3f2063ae + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1702921910 + Commit Message: + selftests/bpf: Add more uprobe multi fail tests + +We fail to create uprobe if we pass negative offset. Add more tests +validating kernel-side error checking code. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Song Liu +Link: https://lore.kernel.org/bpf/20231217215538.3361991-3-jolsa@kernel.org + + Parent Hashes: 3983c00281d96af2ba611254d679107b5c390627 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add additional uprobe multi fail tests to ensure kernel-side error checking for negative offsets.', 'keywords': 'uprobe,multi fail,tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 3983c00281d96af2ba611254d679107b5c390627 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3983c00281d96af2ba611254d679107b5c390627 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1702921890 + Commit Message: + bpf: Fail uprobe multi link with negative offset + +Currently the __uprobe_register will return 0 (success) when called with +negative offset. The reason is that the call to register_for_each_vma and +then build_map_info won't return error for negative offset. They just won't +do anything - no matching vma is found so there's no registered breakpoint +for the uprobe. + +I don't think we can change the behaviour of __uprobe_register and fail +for negative uprobe offset + Parent Hashes: e58aac1a9a179fa9dab3025ef955cdb548c439f2 + Refs: because apps might depend on that already. + +But I think we can still make the change and check for it on bpf multi +link syscall level. + +Also moving the __get_user call and check for the offsets to the top of +loop + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enforces error checks for negative offsets in uprobe multi link syscalls to prevent unnoticed success responses.', 'keywords': 'uprobe,negative offset,syscall', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: e58aac1a9a179fa9dab3025ef955cdb548c439f2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e58aac1a9a179fa9dab3025ef955cdb548c439f2 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702919749 + Commit Message: + selftests/bpf: Test the release of map btf + +When there is bpf_list_head or bpf_rb_root field in map value + Parent Hashes: 0c970ed2f87c058fe3ddeb4d7d8f64f72cf41d7a + Refs: the free +of map btf and the free of map value may run concurrently and there may +be use-after-free problem + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test cases to check for use-after-free issues in map BTF with bpf_list_head and bpf_rb_root fields.', 'keywords': 'selftests use-after-free map', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0c970ed2f87c058fe3ddeb4d7d8f64f72cf41d7a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0c970ed2f87c058fe3ddeb4d7d8f64f72cf41d7a + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702897237 + Commit Message: + s390/bpf: Fix indirect trampoline generation + +The func_addr used to be NULL for indirect trampolines used by struct_ops. +Now func_addr is a valid function pointer. +Hence use BPF_TRAMP_F_INDIRECT flag to detect such condition. + +Fixes: 2cd3e3772e41 ("x86/cfi + Parent Hashes: 42d45c45624a098a9fdc477c7a8b86167f948c77 + Refs: bpf: Fix bpf_struct_ops CFI") +Signed-off-by: Alexei Starovoitov +Signed-off-by: Daniel Borkmann +Reviewed-by: Ilya Leoshkevich +Link: https://lore.kernel.org/bpf/20231216004549.78355-1-alexei.starovoitov@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes indirect trampoline generation for struct_ops in BPF on s390 architecture.', 'keywords': 'indirect, trampoline, struct_ops', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 117211aa739a926e6555cfea883be84bee6f1695 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 117211aa739a926e6555cfea883be84bee6f1695 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1702686852 + Commit Message: + bpf: Add missing BPF_LINK_TYPE invocations + +Pengfei Xu reported [1] Syzkaller/KASAN issue found in bpf_link_show_fdinfo. + +The reason is missing BPF_LINK_TYPE invocation for uprobe multi +link and for several other links + Parent Hashes: 2f2fee2bf74a7e31d06fc6cb7ba2bd4dd7753c99 + Refs: adding that. + +[1] https://lore.kernel.org/bpf/ZXptoKRSLspnk2ie@xpf.sh.intel.com/ + +Fixes: 89ae89f53d20 ("bpf: Add multi uprobe link") +Fixes: e420bed02507 ("bpf: Add fd-based tcx multi-prog infra with link support") +Fixes: 84601d6ee68a ("bpf: add bpf_link support for BPF_NETFILTER programs") +Fixes: 35dfaad7188c ("netkit + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add missing BPF_LINK_TYPE invocations in bpf_link_show_fdinfo to fix Syzkaller/KASAN issue.', 'keywords': 'BPF_LINK_TYPE, uprobe, Syzkaller', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs', 'tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 42d45c45624a098a9fdc477c7a8b86167f948c77 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 42d45c45624a098a9fdc477c7a8b86167f948c77 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702686505 + Commit Message: + selftests/bpf: Temporarily disable dummy_struct_ops test on s390 + +Temporarily disable dummy_struct_ops test on s390. +The breakage is likely due to +commit 2cd3e3772e41 ("x86/cfi + Parent Hashes: 3c302e14bd9d7698ea24885a7eee2b44c1a014be + Refs: bpf: Fix bpf_struct_ops CFI"). + +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Temporarily disables dummy_struct_ops test on s390 architecture due to recent breakage.', 'keywords': 'selftests,bpf,s390', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3c302e14bd9d7698ea24885a7eee2b44c1a014be +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3c302e14bd9d7698ea24885a7eee2b44c1a014be + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702686356 + Commit Message: + Merge branch 'x86-cfi-bpf-fix-cfi-vs-ebpf' + +Peter Zijlstra says: + +==================== +x86/cfi + Parent Hashes: 1467affd16b236fc86e1b8ec5eaa147e104cd2a6 852486b35f344887786d63250946dd921a05d7e8 + Refs: bpf: Fix CFI vs eBPF + +Hi! + +What started with the simple observation that bpf_dispatcher_*_func() was +broken for calling CFI functions with a __nocfi calling context for FineIBT +ended up with a complete BPF wide CFI fixup. + +With these changes on the BPF selftest suite passes without crashing -- there's +still a few failures + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes a compatibility issue between Control Flow Integrity (CFI) and eBPF in the x86 architecture.', 'keywords': 'CFI,eBPF,x86', 'commit_classification': "It's a bug fix.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 852486b35f344887786d63250946dd921a05d7e8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 852486b35f344887786d63250946dd921a05d7e8 + Author Name: Alexei Starovoitov + Author Email: alexei.starovoitov@gmail.com + Commit Date: 1702686355 + Commit Message: + x86/cfi + Parent Hashes: e4c00339891c074c76f626ac82981963cbba5332 + Refs: bpf: Fix bpf_exception_cb() signature + +As per the earlier patches + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes the signature of the bpf_exception_cb function.', 'keywords': 'bpf_exception_cb,fix,signature', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e4c00339891c074c76f626ac82981963cbba5332 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e4c00339891c074c76f626ac82981963cbba5332 + Author Name: Peter Zijlstra + Author Email: peterz@infradead.org + Commit Date: 1702686355 + Commit Message: + bpf: Fix dtor CFI + +Ensure the various dtor functions match their prototype and retain +their CFI signatures + Parent Hashes: e9d13b9d2f99ccf7afeab490d97eaa5ac9846598 + Refs: since they don't have their address taken + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes function prototypes to retain CFI signatures for destructor functions.', 'keywords': 'Fix, CFI, dtor', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2cd3e3772e41377f32d6eea643e0590774e9187c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2cd3e3772e41377f32d6eea643e0590774e9187c + Author Name: Peter Zijlstra + Author Email: peterz@infradead.org + Commit Date: 1702686355 + Commit Message: + x86/cfi + Parent Hashes: e72d88d18df4e03c80e64c2535f70c64f1dc6fc1 + Refs: bpf: Fix bpf_struct_ops CFI + +BPF struct_ops uses __arch_prepare_bpf_trampoline() to write +trampolines for indirect function calls. These tramplines much have +matching CFI. + +In order to obtain the correct CFI hash for the various methods + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes the bpf_struct_ops trampoline CFI to ensure correct indirect function call handling in x86 architecture.', 'keywords': 'bpf_struct_ops,Cfi,trampolines', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e72d88d18df4e03c80e64c2535f70c64f1dc6fc1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e72d88d18df4e03c80e64c2535f70c64f1dc6fc1 + Author Name: Peter Zijlstra + Author Email: peterz@infradead.org + Commit Date: 1702686355 + Commit Message: + x86/cfi + Parent Hashes: 4f9087f16651aca4a5f32da840a53f6660f0579a + Refs: bpf: Fix bpf_callback_t CFI + +Where the main BPF program is expected to match bpf_func_t + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a CFI issue in x86 architecture related to bpf_callback_t and bpf_func_t compatibility.', 'keywords': 'x86, CFI, compatibility', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 4f9087f16651aca4a5f32da840a53f6660f0579a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4f9087f16651aca4a5f32da840a53f6660f0579a + Author Name: Peter Zijlstra + Author Email: peterz@infradead.org + Commit Date: 1702686355 + Commit Message: + x86/cfi + Parent Hashes: 4382159696c9af67ee047ed55f2dbf05480f52f6 + Refs: bpf: Fix BPF JIT call + +The current BPF call convention is __nocfi + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes BPF JIT call on x86 architecture using current BPF call convention.', 'keywords': 'BPF,JIT,x86', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1467affd16b236fc86e1b8ec5eaa147e104cd2a6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1467affd16b236fc86e1b8ec5eaa147e104cd2a6 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702677295 + Commit Message: + selftests/bpf: Add test for abnormal cnt during multi-kprobe attachment + +If an abnormally huge cnt is used for multi-kprobes attachment + Parent Hashes: 00cdcd2900bdb9190d1e75438b39cef74cd99232 + Refs: the +following warning will be reported: + + ------------[ cut here ]------------ + WARNING: CPU: 1 PID: 392 at mm/util.c:632 kvmalloc_node+0xd9/0xe0 + Modules linked in: bpf_testmod(O) + CPU: 1 PID: 392 Comm: test_progs Tainted: G ...... 6.7.0-rc3+ #32 + Hardware name: QEMU Standard PC (i440FX + PIIX + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a new test for handling abnormal count during multi-kprobe attachment in eBPF selftests.', 'keywords': 'selftests,bpf,multi-kprobe', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 00cdcd2900bdb9190d1e75438b39cef74cd99232 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 00cdcd2900bdb9190d1e75438b39cef74cd99232 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702677295 + Commit Message: + selftests/bpf: Don't use libbpf_get_error() in kprobe_multi_test + +Since libbpf v1.0 + Parent Hashes: 0d83786f5661154d015b498a3d23d4c37e30f6ef + Refs: libbpf doesn't return error code embedded into the +pointer iteself + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update selftests/bpf to avoid using libbpf_get_error() in kprobe_multi_test due to changes in libbpf v1.0.', 'keywords': 'selftests,bpf,libbpf', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0d83786f5661154d015b498a3d23d4c37e30f6ef +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0d83786f5661154d015b498a3d23d4c37e30f6ef + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702677295 + Commit Message: + selftests/bpf: Add test for abnormal cnt during multi-uprobe attachment + +If an abnormally huge cnt is used for multi-uprobes attachment + Parent Hashes: d6d1e6c17cab2dcb7b8530c599f00e7de906d380 + Refs: the +following warning will be reported: + + ------------[ cut here ]------------ + WARNING: CPU: 7 PID: 406 at mm/util.c:632 kvmalloc_node+0xd9/0xe0 + Modules linked in: bpf_testmod(O) + CPU: 7 PID: 406 Comm: test_progs Tainted: G ...... 6.7.0-rc3+ #32 + Hardware name: QEMU Standard PC (i440FX + PIIX + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest for detecting abnormal cnt during multi-uprobe attachment in eBPF.', 'keywords': 'selftest, multi-uprobe, abnormal', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: d6d1e6c17cab2dcb7b8530c599f00e7de906d380 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d6d1e6c17cab2dcb7b8530c599f00e7de906d380 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702677295 + Commit Message: + bpf: Limit the number of kprobes when attaching program to multiple kprobes + +An abnormally big cnt may also be assigned to kprobe_multi.cnt when +attaching multiple kprobes. It will trigger the following warning in +kvmalloc_node(): + + if (unlikely(size > INT_MAX)) { + WARN_ON_ONCE(!(flags & __GFP_NOWARN)); + return NULL; + } + +Fix the warning by limiting the maximal number of kprobes in +bpf_kprobe_multi_link_attach(). If the number of kprobes is greater than +MAX_KPROBE_MULTI_CNT + Parent Hashes: 8b2efe51ba85ca83460941672afac6fca4199df6 + Refs: the attachment will fail and return -E2BIG. + +Fixes: 0dcac2725406 ("bpf: Add multi kprobe link") +Signed-off-by: Hou Tao +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231215100708.2265609-3-houtao@huaweicloud.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a warning by limiting the number of kprobes when attaching programs to multiple kprobes.', 'keywords': 'kprobes, warning, limit', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 8b2efe51ba85ca83460941672afac6fca4199df6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8b2efe51ba85ca83460941672afac6fca4199df6 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702677286 + Commit Message: + bpf: Limit the number of uprobes when attaching program to multiple uprobes + +An abnormally big cnt may be passed to link_create.uprobe_multi.cnt + Parent Hashes: 7489723c2e26504573dbb49b66bbc59092840008 + Refs: +and it will trigger the following warning in kvmalloc_node(): + + if (unlikely(size > INT_MAX)) { + WARN_ON_ONCE(!(flags & __GFP_NOWARN)); + return NULL; + } + +Fix the warning by limiting the maximal number of uprobes in +bpf_uprobe_multi_link_attach(). If the number of uprobes is greater than +MAX_UPROBE_MULTI_CNT + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a kvmalloc_node warning by limiting maximally allowed uprobes in bpf_uprobe_multi_link_attach.', 'keywords': 'uprobes, warning, limit', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: ff6d413b0b59466e5acf2e42f294b1842ae130a1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ff6d413b0b59466e5acf2e42f294b1842ae130a1 + Author Name: Kees Cook + Author Email: keescook@chromium.org + Commit Date: 1702657510 + Commit Message: + kernfs: Convert kernfs_path_from_node_locked() from strlcpy() to strscpy() + +One of the last remaining users of strlcpy() in the kernel is +kernfs_path_from_node_locked() + Parent Hashes: 5b56bf5cdb8b7c989055fe4d73fe3f409427d1d5 + Refs: which passes back the problematic "length +we _would_ have copied" return value to indicate truncation. Convert the +chain of all callers to use the negative return value (some of which +already doing this explicitly). All callers were already also checking +for negative return values + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Convert kernfs_path_from_node_locked() from strlcpy() to strscpy() to improve truncation return value handling.', 'keywords': 'strscpy, kernfs, truncation', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b84d66b0fd3709e36384a2cd893fbdddfc423f1f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b84d66b0fd3709e36384a2cd893fbdddfc423f1f + Author Name: David S. Miller + Author Email: davem@davemloft.net + Commit Date: 1702638303 + Commit Message: + Merge branch 'mv88e6xxx-counters' + +Tobias Waldekranz says: + +==================== +net: dsa: mv88e6xxx: Add "eth-mac" and "rmon" counter group support + +The majority of the changes (2/8) are about refactoring the existing +ethtool statistics support to make it possible to read individual +counters + Parent Hashes: 9ed816b106bb40be6f1254696c6887e48f2a2b8f 00e7f29d9b895cbee58b7071900dd52ed6dcec1e + Refs: rather than the whole set. + +4/8 tries to collect all information about a stat in a single place +using a mapper macro + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add "eth-mac" and "rmon" counter group support and refactor ethtool statistics for mv88e6xxx.', 'keywords': 'mv88e6xxx,counter,support', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 7489723c2e26504573dbb49b66bbc59092840008 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7489723c2e26504573dbb49b66bbc59092840008 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702609936 + Commit Message: + bpf: xdp: Register generic_kfunc_set with XDP programs + +Registering generic_kfunc_set with XDP programs enables some of the +newer BPF features inside XDP -- namely tree based data structures and +BPF exceptions. + +The current motivation for this commit is to enable assertions inside +XDP bpf progs. Assertions are a standard and useful tool to encode +intent. + +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/d07d4614b81ca6aada44fcb89bb6b618fb66e4ca.1702594357.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 0f5d5454c723d5c729d4676860a390c31c466f50 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Register generic_kfunc_set with XDP programs to enable assertions and newer BPF features.', 'keywords': 'generic_kfunc_set,XDP,assertions', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 52eda4641d041667fa059f4855c5f88dcebd8afe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 52eda4641d041667fa059f4855c5f88dcebd8afe + Author Name: Vladimir Oltean + Author Email: vladimir.oltean@nxp.com + Commit Date: 1702605489 + Commit Message: + net: mscc: ocelot: fix eMAC TX RMON stats for bucket 256-511 and above + +There is a typo in the driver due to which we report incorrect TX RMON +counters for the 256-511 octet bucket and all the other buckets larger +than that. + +Bug found with the selftest at +https://patchwork.kernel.org/project/netdevbpf/patch/20231211223346.2497157-9-tobias@waldekranz.com/ + +Fixes: e32036e1ae7b ("net: mscc: ocelot: add support for all sorts of standardized counters present in DSA") +Signed-off-by: Vladimir Oltean +Reviewed-by: Florian Fainelli +Link: https://lore.kernel.org/r/20231214000902.545625-1-vladimir.oltean@nxp.com +Signed-off-by: Jakub Kicinski + + Parent Hashes: c7402612e2e61b76177f22e6e7f705adcbecc6fe + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a typo in the ocelot driver to correct TX RMON stats reporting for certain octet buckets.', 'keywords': 'fix typo stats', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 0f5d5454c723d5c729d4676860a390c31c466f50 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0f5d5454c723d5c729d4676860a390c31c466f50 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702603827 + Commit Message: + Merge branch 'bpf-fs-mount-options-parsing-follow-ups' + +Andrii Nakryiko says: + +==================== +BPF FS mount options parsing follow ups + +Original BPF token patch set ([0]) added delegate_xxx mount options which +supported only special "any" value and hexadecimal bitmask. This patch set +attempts to make specifying and inspecting these mount options more +human-friendly by supporting string constants matching corresponding bpf_cmd + Parent Hashes: 403f3e8fda60f1a3e54741742d46aea98ecf671e f2d0ffee1f03395d9ae65f9c615b6a0ee05d0e12 + Refs: +bpf_map_type + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improved BPF FS mount options parsing for better usability with human-friendly string constants.', 'keywords': 'BPF, mount, parsing', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f2d0ffee1f03395d9ae65f9c615b6a0ee05d0e12 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f2d0ffee1f03395d9ae65f9c615b6a0ee05d0e12 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702603827 + Commit Message: + selftests/bpf: utilize string values for delegate_xxx mount options + +Use both hex-based and string-based way to specify delegate mount +options for BPF FS. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231214225016.1209867-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: c5707b2146d229691e193d5158ea70b21b8ba180 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Use string values for delegate mount options in BPF selftests.', 'keywords': 'selftests,mount options,string values', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c5707b2146d229691e193d5158ea70b21b8ba180 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c5707b2146d229691e193d5158ea70b21b8ba180 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702603827 + Commit Message: + bpf: support symbolic BPF FS delegation mount options + +Besides already supported special "any" value and hex bit mask + Parent Hashes: 403f3e8fda60f1a3e54741742d46aea98ecf671e + Refs: support +string-based parsing of delegation masks based on exact enumerator +names. Utilize BTF information of `enum bpf_cmd` + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Support added for symbolic BPF FS delegation mount options using BTF information.', 'keywords': 'symbolic, delegation, options', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 403f3e8fda60f1a3e54741742d46aea98ecf671e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 403f3e8fda60f1a3e54741742d46aea98ecf671e + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702602776 + Commit Message: + Merge branch 'add-bpf_xdp_get_xfrm_state-kfunc' + +Daniel Xu says: + +==================== +Add bpf_xdp_get_xfrm_state() kfunc + +This patchset adds two kfunc helpers + Parent Hashes: 56925f389e152dcb8d093435d43b78a310539c23 2cd07b0eb08c0ed63b1bd0bf0114146b19a4ab1f + Refs: bpf_xdp_get_xfrm_state() and +bpf_xdp_xfrm_state_release() that wrap xfrm_state_lookup() and +xfrm_state_put(). The intent is to support software RSS (via XDP) for +the ongoing/upcoming ipsec pcpu work [0]. Recent experiments performed +on (hopefully) reproducible AWS testbeds indicate that single tunnel +pcpu ipsec can reach line rate on 100G ENA nics. + +Note this patchset only tests/shows generic xfrm_state access. The +"secret sauce" (if you can really even call it that) involves accessing +a soon-to-be-upstreamed pcpu_num field in xfrm_state. Early example is +available here [1]. + +[0]: https://datatracker.ietf.org/doc/draft-ietf-ipsecme-multi-sa-performance/03/ +[1]: https://github.com/danobi/xdp-tools/blob/e89a1c617aba3b50d990f779357d6ce2863ecb27/xdp-bench/xdp_redirect_cpumap.bpf.c#L385-L406 + +Changes from v5: +* Improve kfunc doc comments +* Remove extraneous replay-window setting on selftest reverse path +* Squash two kfunc commits into one +* Rebase to bpf-next to pick up bitfield write patches +* Remove testing of opts.error in selftest prog + +Changes from v4: +* Fixup commit message for selftest +* Set opts->error -ENOENT for !x +* Revert single file xfrm + bpf + +Changes from v3: +* Place all xfrm bpf integrations in xfrm_bpf.c +* Avoid using nval as a temporary +* Rebase to bpf-next +* Remove extraneous __failure_unpriv annotation for verifier tests + +Changes from v2: +* Fix/simplify BPF_CORE_WRITE_BITFIELD() algorithm +* Added verifier tests for bitfield writes +* Fix state leakage across test_tunnel subtests + +Changes from v1: +* Move xfrm tunnel tests to test_progs +* Fix writing to opts->error when opts is invalid +* Use __bpf_kfunc_start_defs() +* Remove unused vxlanhdr definition +* Add and use BPF_CORE_WRITE_BITFIELD() macro +* Make series bisect clean + +Changes from RFCv2: +* Rebased to ipsec-next +* Fix netns leak + +Changes from RFCv1: +* Add Antony's commit tags +* Add KF_ACQUIRE and KF_RELEASE semantics +==================== + +Reviewed-by: Eyal Birger +Link: https://lore.kernel.org/r/cover.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add bpf_xdp_get_xfrm_state and bpf_xdp_xfrm_state_release kfuncs for improved XDP support in ipsec.', 'keywords': 'kfunc, XDP, ipsec', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 2cd07b0eb08c0ed63b1bd0bf0114146b19a4ab1f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2cd07b0eb08c0ed63b1bd0bf0114146b19a4ab1f + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702602769 + Commit Message: + bpf: xfrm: Add selftest for bpf_xdp_get_xfrm_state() + +This commit extends test_tunnel selftest to test the new XDP xfrm state +lookup kfunc. + +Co-developed-by: Antony Antony +Signed-off-by: Antony Antony +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/e704e9a4332e3eac7b458e4bfdec8fcc6984cdb6.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + Parent Hashes: e7adc8291a9e9c232d600d82465cbbb682164ca3 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a selftest for bpf_xdp_get_xfrm_state function in the test_tunnel selftest.', 'keywords': 'selftest,xdp,xfrm state', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: e7adc8291a9e9c232d600d82465cbbb682164ca3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e7adc8291a9e9c232d600d82465cbbb682164ca3 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702602769 + Commit Message: + bpf: selftests: Move xfrm tunnel test to test_progs + +test_progs is better than a shell script b/c C is a bit easier to +maintain than shell. Also it's easier to use new infra like memory +mapped global variables from C via bpf skeleton. + +Co-developed-by: Antony Antony +Signed-off-by: Antony Antony +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/a350db9e08520c64544562d88ec005a039124d9b.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 02b4e126e6a5f5552da2ccec47a028984d2d9654 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit moves the xfrm tunnel test from a shell script to the test_progs framework for easier maintenance and new infrastructure compatibility.', 'keywords': 'xfrm tunnel, test_progs, bpf skeleton', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 02b4e126e6a5f5552da2ccec47a028984d2d9654 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 02b4e126e6a5f5552da2ccec47a028984d2d9654 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702602769 + Commit Message: + bpf: selftests: test_tunnel: Use vmlinux.h declarations + +vmlinux.h declarations are more ergnomic + Parent Hashes: 77a7a8220f0d87c44425c0a12e0a72b14962535b + Refs: especially when working with +kfuncs. The uapi headers are often incomplete for kfunc definitions. + +This commit also switches bitfield accesses to use CO-RE helpers. +Switching to vmlinux.h definitions makes the verifier very +unhappy with raw bitfield accesses. The error is: + + ; md.u.md2.dir = direction; + 33: (69) r1 = *(u16 *)(r2 +11) + misaligned stack access off (0x0; 0x0)+-64+11 size 2 + +Fix by using CO-RE-aware bitfield reads and writes. + +Co-developed-by: Antony Antony +Signed-off-by: Antony Antony +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/884bde1d9a351d126a3923886b945ea6b1b0776b.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor selftests to use vmlinux.h declarations for improved ergonomics and compatibility with kfuncs.', 'keywords': 'vmlinux.h, kfuncs, CO-RE', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs', 'other']} +-------------------- +-------------------- +Processing Commit ID: 77a7a8220f0d87c44425c0a12e0a72b14962535b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 77a7a8220f0d87c44425c0a12e0a72b14962535b + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702602769 + Commit Message: + bpf: selftests: test_tunnel: Setup fresh topology for each subtest + +This helps with determinism b/c individual setup/teardown prevents +leaking state between different subtests. + +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/0fb59fa16fb58cca7def5239df606005a3e8dd0e.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 8f0ec8c681755f523cf842bfe350ea40609b83a9 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit sets up a fresh topology for each subtest in test_tunnel to ensure test determinism.', 'keywords': 'selftests, topology, determinism', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8f0ec8c681755f523cf842bfe350ea40609b83a9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8f0ec8c681755f523cf842bfe350ea40609b83a9 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702602769 + Commit Message: + bpf: xfrm: Add bpf_xdp_get_xfrm_state() kfunc + +This commit adds an unstable kfunc helper to access internal xfrm_state +associated with an SA. This is intended to be used for the upcoming +IPsec pcpu work to assign special pcpu SAs to a particular CPU. In other +words: for custom software RSS. + +That being said + Parent Hashes: 56925f389e152dcb8d093435d43b78a310539c23 + Refs: the function that this kfunc wraps is fairly generic +and used for a lot of xfrm tasks. I'm sure people will find uses +elsewhere over time. + +This commit also adds a corresponding bpf_xdp_xfrm_state_release() kfunc +to release the refcnt acquired by bpf_xdp_get_xfrm_state(). The verifier +will require that all acquired xfrm_state's are released. + +Co-developed-by: Antony Antony +Signed-off-by: Antony Antony +Acked-by: Steffen Klassert +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/a29699c42f5fad456b875c98dd11c6afc3ffb707.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added bpf_xdp_get_xfrm_state() and bpf_xdp_xfrm_state_release() kfuncs for internal xfrm_state management associated with SA.', 'keywords': 'bpf_xdp_get_xfrm_state, kfunc, xfrm_state', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 56925f389e152dcb8d093435d43b78a310539c23 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 56925f389e152dcb8d093435d43b78a310539c23 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1702602632 + Commit Message: + selftests/bpf: Remove flaky test_btf_id test + +With previous patch + Parent Hashes: 59e5791f59dd83e8aa72a4e74217eabb6e8cfd90 + Refs: one of subtests in test_btf_id becomes +flaky and may fail. The following is a failing example: + + Error: #26 btf + Error: #26/174 btf/BTF ID + Error: #26/174 btf/BTF ID + btf_raw_create:PASS:check 0 nsec + btf_raw_create:PASS:check 0 nsec + test_btf_id:PASS:check 0 nsec + ... + test_btf_id:PASS:check 0 nsec + test_btf_id:FAIL:check BTF lingersdo_test_get_info:FAIL:check failed: -1 + +The test tries to prove a btf_id not available after the map is closed. +But btf_id is freed only after workqueue and a rcu grace period + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit removes a flaky test from the BPF selftests related to BTF ID.', 'keywords': 'flaky,test,BTF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 59e5791f59dd83e8aa72a4e74217eabb6e8cfd90 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 59e5791f59dd83e8aa72a4e74217eabb6e8cfd90 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1702602632 + Commit Message: + bpf: Fix a race condition between btf_put() and map_free() + +When running `./test_progs -j` in my local vm with latest kernel + Parent Hashes: 04d25ccea2b3199269b7e500da33023b51418fde + Refs: +I once hit a kasan error like below: + + [ 1887.184724] BUG: KASAN: slab-use-after-free in bpf_rb_root_free+0x1f8/0x2b0 + [ 1887.185599] Read of size 4 at addr ffff888106806910 by task kworker/u12:2/2830 + [ 1887.186498] + [ 1887.186712] CPU: 3 PID: 2830 Comm: kworker/u12:2 Tainted: G OEL 6.7.0-rc3-00699-g90679706d486-dirty #494 + [ 1887.188034] Hardware name: QEMU Standard PC (i440FX + PIIX + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a race condition in bpf related to use-after-free errors in btf_put() and map_free().', 'keywords': 'race condition, btf_put, map_free', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 04d25ccea2b3199269b7e500da33023b51418fde +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 04d25ccea2b3199269b7e500da33023b51418fde + Author Name: Randy Dunlap + Author Email: rdunlap@infradead.org + Commit Date: 1702568339 + Commit Message: + net + Parent Hashes: 2e1d6a04116c373fbd25beddba4267178535bc60 + Refs: xdp: Correct grammar + +Use the correct verb form in 2 places in the XDP rx-queue comment. + +Signed-off-by: Randy Dunlap +Signed-off-by: Daniel Borkmann +Acked-by: Jesper Dangaard Brouer +Link: https://lore.kernel.org/bpf/20231213043735.30208-1-rdunlap@infradead.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Corrects verb form in XDP rx-queue comment for improved grammar.', 'keywords': 'grammar, XDP, comment', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 2e1d6a04116c373fbd25beddba4267178535bc60 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2e1d6a04116c373fbd25beddba4267178535bc60 + Author Name: Tushar Vyavahare + Author Email: tushar.vyavahare@intel.com + Commit Date: 1702566673 + Commit Message: + selftests/xsk: Fix for SEND_RECEIVE_UNALIGNED test + +Fix test broken by shared umem test and framework enhancement commit. + +Correct the current implementation of pkt_stream_replace_half() by +ensuring that nb_valid_entries are not set to half + Parent Hashes: c838fe1282df540ebf6e24e386ac34acb3ef3115 + Refs: as this is not true +for all the tests. Ensure that the expected value for valid_entries for +the SEND_RECEIVE_UNALIGNED test equals the total number of packets sent + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes SEND_RECEIVE_UNALIGNED test in selftests/xsk by correcting pkt_stream_replace_half() implementation.', 'keywords': 'selftests,xsk,unaligned', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: c838fe1282df540ebf6e24e386ac34acb3ef3115 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c838fe1282df540ebf6e24e386ac34acb3ef3115 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702530160 + Commit Message: + Merge branch 'bpf-use-gfp_kernel-in-bpf_event_entry_gen' + +Hou Tao says: + +==================== +The simple patch set aims to replace GFP_ATOMIC by GFP_KERNEL in +bpf_event_entry_gen(). These two patches in the patch set were +preparatory patches in "Fix the release of inner map" patchset [1] and +are not needed for v2 + Parent Hashes: 2a0c6b41eec90c2a138ea8b574836744783c67ff dc68540913ac523b46ebda3843cec179362c7a72 + Refs: so re-post it to bpf-next tree. + +Patch #1 reduces the scope of rcu_read_lock when updating fd map and +patch #2 replaces GFP_ATOMIC by GFP_KERNEL. Please see individual +patches for more details. + +Change Log: +v3: + * patch #1: fallback to patch #1 in v1. Update comments in + bpf_fd_htab_map_update_elem() to explain the reason for + rcu_read_lock() (Alexei) + +v2: https://lore.kernel.org/bpf/20231211073843.1888058-1-houtao@huaweicloud.com/ + * patch #1: add rcu_read_lock/unlock() for bpf_fd_array_map_update_elem + as well to make it consistent with + bpf_fd_htab_map_update_elem and update commit message + accordingly (Alexei) + * patch #1/#2: collects ack tags from Yonghong + +v1: https://lore.kernel.org/bpf/20231208103357.2637299-1-houtao@huaweicloud.com/ + +[1]: https://lore.kernel.org/bpf/20231107140702.1891778-1-houtao@huaweicloud.com/ +==================== + +Link: https://lore.kernel.org/r/20231214043010.3458072-1-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replace GFP_ATOMIC with GFP_KERNEL in bpf_event_entry_gen function to optimize memory allocation.', 'keywords': 'GFP_KERNEL, bpf_event_entry_gen, memory', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dc68540913ac523b46ebda3843cec179362c7a72 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dc68540913ac523b46ebda3843cec179362c7a72 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702529351 + Commit Message: + bpf: Use GFP_KERNEL in bpf_event_entry_gen() + +rcu_read_lock() is no longer held when invoking bpf_event_entry_gen() +which is called by perf_event_fd_array_get_ptr() + Parent Hashes: 8f82583f9527b3be9d70d9a5d1f33435e29d0480 + Refs: so using GFP_KERNEL +instead of GFP_ATOMIC to reduce the possibility of failures due to +out-of-memory. + +Acked-by: Yonghong Song +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231214043010.3458072-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Commit changes memory allocation from GFP_ATOMIC to GFP_KERNEL in bpf_event_entry_gen to reduce out-of-memory failures.', 'keywords': 'GFP_KERNEL,bpf_event_entry_gen,reduce failures', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8f82583f9527b3be9d70d9a5d1f33435e29d0480 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8f82583f9527b3be9d70d9a5d1f33435e29d0480 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702529351 + Commit Message: + bpf: Reduce the scope of rcu_read_lock when updating fd map + +There is no rcu-read-lock requirement for ops->map_fd_get_ptr() or +ops->map_fd_put_ptr() + Parent Hashes: 2a0c6b41eec90c2a138ea8b574836744783c67ff + Refs: so doesn't use rcu-read-lock for these two +callbacks. + +For bpf_fd_array_map_update_elem() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit reduces the rcu_read_lock scope when updating file descriptor maps in BPF.', 'keywords': 'rcu_read_lock, fd map, update', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2a0c6b41eec90c2a138ea8b574836744783c67ff +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2a0c6b41eec90c2a138ea8b574836744783c67ff + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702515702 + Commit Message: + bpf: Update the comments in maybe_wait_bpf_programs() + +Since commit 638e4b825d52 ("bpf: Allows per-cpu maps and map-in-map in +sleepable programs") + Parent Hashes: b13cddf633562b9b2c34fd63471d377019704ebe + Refs: sleepable BPF program can also use map-in-map + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit updates comments in the maybe_wait_bpf_programs function to reflect new capabilities for sleepable BPF programs.', 'keywords': 'comments, maybe_wait_bpf_programs, sleepable BPF', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b13cddf633562b9b2c34fd63471d377019704ebe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b13cddf633562b9b2c34fd63471d377019704ebe + Author Name: Matt Bobrowski + Author Email: mattbobrowski@google.com + Commit Date: 1702515379 + Commit Message: + bpf: add small subset of SECURITY_PATH hooks to BPF sleepable_lsm_hooks list + +security_path_* based LSM hooks appear to be generally missing from +the sleepable_lsm_hooks list. Initially add a small subset of them to +the preexisting sleepable_lsm_hooks list so that sleepable BPF helpers +like bpf_d_path() can be used from sleepable BPF LSM based programs. + +The security_path_* hooks added in this patch are similar to the +security_inode_* counterparts that already exist in the +sleepable_lsm_hooks list + Parent Hashes: ec14325c7339bf1d40fc29bb8a0d2121cfe649aa + Refs: and are called in roughly similar points and +contexts. Presumably + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added security_path hooks to sleepable_lsm_hooks list for BPF sleepable LSM programs.', 'keywords': 'security_path, LSM hooks, sleepable', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: 2f2fee2bf74a7e31d06fc6cb7ba2bd4dd7753c99 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2f2fee2bf74a7e31d06fc6cb7ba2bd4dd7753c99 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1702513997 + Commit Message: + Merge branch ' bpf fix for unconnect af_unix socket' + +John Fastabend says: + +==================== +Eric reported a syzbot splat from a null ptr deref from recent fix to +resolve a use-after-free with af-unix stream sockets and BPF sockmap +usage. + +The issue is I missed is we allow unconnected af_unix STREAM sockets to +be added to the sockmap. Fix this by blocking unconnected sockets. + +v2: change sk_is_unix to sk_is_stream_unix (Eric) and remove duplicate + ASSERTS in selftests the xsocket helper already marks FAIL (Jakub) +==================== + +Signed-off-by: Martin KaFai Lau + + Parent Hashes: e307b5a845c5951dabafc48d00b6424ee64716c4 50d96f05af6787a34b4eca2ee3fc1993289c4c24 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix null pointer dereference by blocking unconnected af_unix STREAM sockets from being added to sockmap.', 'keywords': 'af_unix, sockmap, unconnected', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 50d96f05af6787a34b4eca2ee3fc1993289c4c24 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 50d96f05af6787a34b4eca2ee3fc1993289c4c24 + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1702513981 + Commit Message: + bpf: sockmap + Parent Hashes: 8d6650646ce49e9a5b8c5c23eb94f74b1749f70f + Refs: test for unconnected af_unix sock + +Add test to sockmap_basic to ensure af_unix sockets that are not connected +can not be added to the map. Ensure we keep DGRAM sockets working however +as these will not be connected typically. + +Signed-off-by: John Fastabend +Acked-by: Jakub Sitnicki +Link: https://lore.kernel.org/r/20231201180139.328529-3-john.fastabend@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Add test to ensure unconnected af_unix sockets can't be added to sockmap while keeping DGRAM sockets functional.", 'keywords': 'test, sockmap, af_unix', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 8d6650646ce49e9a5b8c5c23eb94f74b1749f70f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8d6650646ce49e9a5b8c5c23eb94f74b1749f70f + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1702513948 + Commit Message: + bpf: syzkaller found null ptr deref in unix_bpf proto add + +I added logic to track the sock pair for stream_unix sockets so that we +ensure lifetime of the sock matches the time a sockmap could reference +the sock (see fixes tag). I forgot though that we allow af_unix unconnected +sockets into a sock{map|hash} map. + +This is problematic because previous fixed expected sk_pair() to exist +and did not NULL check it. Because unconnected sockets have a NULL +sk_pair this resulted in the NULL ptr dereference found by syzkaller. + +BUG: KASAN: null-ptr-deref in unix_stream_bpf_update_proto+0x72/0x430 net/unix/unix_bpf.c:171 +Write of size 4 at addr 0000000000000080 by task syz-executor360/5073 +Call Trace: + + ... + sock_hold include/net/sock.h:777 [inline] + unix_stream_bpf_update_proto+0x72/0x430 net/unix/unix_bpf.c:171 + sock_map_init_proto net/core/sock_map.c:190 [inline] + sock_map_link+0xb87/0x1100 net/core/sock_map.c:294 + sock_map_update_common+0xf6/0x870 net/core/sock_map.c:483 + sock_map_update_elem_sys+0x5b6/0x640 net/core/sock_map.c:577 + bpf_map_update_value+0x3af/0x820 kernel/bpf/syscall.c:167 + +We considered just checking for the null ptr and skipping taking a ref +on the NULL peer sock. But + Parent Hashes: e307b5a845c5951dabafc48d00b6424ee64716c4 + Refs: if the socket is then connected() after +being added to the sockmap we can cause the original issue again. So +instead this patch blocks adding af_unix sockets that are not in the +ESTABLISHED state. + +Reported-by: Eric Dumazet +Reported-by: syzbot+e8030702aefd3444fb9e@syzkaller.appspotmail.com +Fixes: 8866730aed51 ("bpf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix null pointer dereference issue in unix_bpf protocol by preventing unconnected af_unix sockets from being added to sockmap.', 'keywords': 'null pointer, sockmap, af_unix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: ec14325c7339bf1d40fc29bb8a0d2121cfe649aa +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ec14325c7339bf1d40fc29bb8a0d2121cfe649aa + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702513002 + Commit Message: + Merge branch 'xdp-metadata-via-kfuncs-for-ice-vlan-hint' + +Larysa Zaremba says: + +==================== +XDP metadata via kfuncs for ice + VLAN hint + +This series introduces XDP hints via kfuncs [0] to the ice driver. + +Series brings the following existing hints to the ice driver: + - HW timestamp + - RX hash with type + +Series also introduces VLAN tag with protocol XDP hint + Parent Hashes: 733763285acfe8dffd6e39ad2ed3d1222b32a901 4c6612f6100c2d85212865dbd1a5d8a7e391d3cb + Refs: it now be accessed by +XDP and userspace (AF_XDP) programs. They can also be checked with xdp_metadata +test and xdp_hw_metadata program. + +Impact of these patches on ice performance: +ZC: +* Full hints implementation decreases pps in ZC mode by less than 3% + (64B + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces XDP metadata via kfuncs for ice driver including VLAN hint and timestamp.', 'keywords': 'XDP, metadata, kfuncs', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 4c6612f6100c2d85212865dbd1a5d8a7e391d3cb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4c6612f6100c2d85212865dbd1a5d8a7e391d3cb + Author Name: Larysa Zaremba + Author Email: larysa.zaremba@intel.com + Commit Date: 1702513001 + Commit Message: + selftests/bpf: Check VLAN tag and proto in xdp_metadata + +Verify + Parent Hashes: a3850af4ea25dadc8b35edf132340907d523657e + Refs: whether VLAN tag and proto are set correctly. + +To simulate "stripped" VLAN tag on veth + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests to verify VLAN tag and protocol settings in xdp_metadata for veth interfaces.', 'keywords': 'VLAN, xdp_metadata, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: a3850af4ea25dadc8b35edf132340907d523657e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a3850af4ea25dadc8b35edf132340907d523657e + Author Name: Larysa Zaremba + Author Email: larysa.zaremba@intel.com + Commit Date: 1702513001 + Commit Message: + selftests/bpf: Add AF_INET packet generation to xdp_metadata + +The easiest way to simulate stripped VLAN tag in veth is to send a packet +from VLAN interface + Parent Hashes: 8e68a4beba943bdffb342c601c649223f44b7329 + Refs: attached to veth. Unfortunately + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add AF_INET packet generation to xdp_metadata selftests in eBPF to simulate stripped VLAN tag using VLAN interface.', 'keywords': 'AF_INET, packet generation, xdp_metadata', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 8e68a4beba943bdffb342c601c649223f44b7329 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8e68a4beba943bdffb342c601c649223f44b7329 + Author Name: Larysa Zaremba + Author Email: larysa.zaremba@intel.com + Commit Date: 1702513001 + Commit Message: + selftests/bpf: Add flags and VLAN hint to xdp_hw_metadata + +Add VLAN hint to the xdp_hw_metadata program. + +Also + Parent Hashes: e71a9fa7fdb2effcaaed37c207ec4f634c8f4901 + Refs: to make metadata layout more straightforward + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Add VLAN hint and flags to improve xdp_hw_metadata program's metadata layout in selftests.", 'keywords': 'VLAN,xdp_hw_metadata,metadata', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: e71a9fa7fdb2effcaaed37c207ec4f634c8f4901 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e71a9fa7fdb2effcaaed37c207ec4f634c8f4901 + Author Name: Larysa Zaremba + Author Email: larysa.zaremba@intel.com + Commit Date: 1702513001 + Commit Message: + selftests/bpf: Allow VLAN packets in xdp_hw_metadata + +Make VLAN c-tag and s-tag XDP hint testing more convenient +by not skipping VLAN-ed packets. + +Allow both 802.1ad and 802.1Q headers. + +Acked-by: Stanislav Fomichev +Signed-off-by: Larysa Zaremba +Link: https://lore.kernel.org/r/20231205210847.28460-16-larysa.zaremba@intel.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 7978bad4b6b9265a1e808a5f679ee428d1dd6523 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates selftests to include VLAN packets in xdp_hw_metadata for improved testing of XDP hints.', 'keywords': 'VLAN,XDP,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 537fec0733c4a72e2a2b69fee365459c5b75d92e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 537fec0733c4a72e2a2b69fee365459c5b75d92e + Author Name: Larysa Zaremba + Author Email: larysa.zaremba@intel.com + Commit Date: 1702513001 + Commit Message: + net: make vlan_get_tag() return -ENODATA instead of -EINVAL + +__vlan_hwaccel_get_tag() is used in veth XDP hints implementation + Parent Hashes: fca783799f64ac0a4f20228ff6a6d7598db11e64 + Refs: +its return value (-EINVAL if skb is not VLAN tagged) is passed to bpf code + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Change vlan_get_tag() return value to -ENODATA in the veth XDP hints implementation.', 'keywords': 'vlan_get_tag,ENODATA,XDP', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: e6795330f88b4f643c649a02662d47b779340535 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e6795330f88b4f643c649a02662d47b779340535 + Author Name: Larysa Zaremba + Author Email: larysa.zaremba@intel.com + Commit Date: 1702513000 + Commit Message: + xdp: Add VLAN tag hint + +Implement functionality that enables drivers to expose VLAN tag +to XDP code. + +VLAN tag is represented by 2 variables: +- protocol ID + Parent Hashes: d68d707dcbbf6a9cfe378fc2eb3ffffd5b47727e + Refs: which is passed to bpf code in BE +- VLAN TCI + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce functionality for XDP to process VLAN tag hints in drivers.', 'keywords': 'XDP,VLAN,drivers', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 733763285acfe8dffd6e39ad2ed3d1222b32a901 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 733763285acfe8dffd6e39ad2ed3d1222b32a901 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702511226 + Commit Message: + Merge branch 'bpf-token-support-in-libbpf-s-bpf-object' + +Andrii Nakryiko says: + +==================== +BPF token support in libbpf's BPF object + +Add fuller support for BPF token in high-level BPF object APIs. This is the +most frequently used way to work with BPF using libbpf + Parent Hashes: f04f2ce6018f3cb33ac96270b9153c2920ead190 322122bf8c75b1df78d6608516807a0354f6ab3c + Refs: so supporting BPF +token there is critical. + +Patch #1 is improving kernel-side BPF_TOKEN_CREATE behavior by rejecting to +create "empty" BPF token with no delegation. This seems like saner behavior +which also makes libbpf's caching better overall. If we ever want to create +BPF token with no delegate_xxx options set on BPF FS + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add BPF token support to high-level BPF object APIs in libbpf.', 'keywords': 'BPF token,libbpf,support', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 322122bf8c75b1df78d6608516807a0354f6ab3c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 322122bf8c75b1df78d6608516807a0354f6ab3c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511225 + Commit Message: + selftests/bpf: add tests for LIBBPF_BPF_TOKEN_PATH envvar + +Add new subtest validating LIBBPF_BPF_TOKEN_PATH envvar semantics. +Extend existing test to validate that LIBBPF_BPF_TOKEN_PATH allows to +disable implicit BPF token creation by setting envvar to empty string. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-11-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: ed54124b88056fd629c6af71664dfcd4d3b3e0b8 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new subtest to validate behavior of LIBBPF_BPF_TOKEN_PATH environment variable in selftests.', 'keywords': 'selftests,LIBBPF_BPF_TOKEN_PATH,subtest', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ed54124b88056fd629c6af71664dfcd4d3b3e0b8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ed54124b88056fd629c6af71664dfcd4d3b3e0b8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511225 + Commit Message: + libbpf: support BPF token path setting through LIBBPF_BPF_TOKEN_PATH envvar + +To allow external admin authority to override default BPF FS location +(/sys/fs/bpf) for implicit BPF token creation + Parent Hashes: 18678cf0ee13cf19bac4ecd55665e6d1d63108b3 + Refs: teach libbpf to recognize +LIBBPF_BPF_TOKEN_PATH envvar. If it is specified and user application +didn't explicitly specify neither bpf_token_path nor bpf_token_fd +option + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds support for setting BPF token path via LIBBPF_BPF_TOKEN_PATH environment variable in libbpf.', 'keywords': 'libbpf,BPF token,environment variable', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 18678cf0ee13cf19bac4ecd55665e6d1d63108b3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 18678cf0ee13cf19bac4ecd55665e6d1d63108b3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511225 + Commit Message: + selftests/bpf: add tests for BPF object load with implicit token + +Add a test to validate libbpf's implicit BPF token creation from default +BPF FS location (/sys/fs/bpf). Also validate that disabling this +implicit BPF token creation works. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 98e0eaa36adfb580a3aa43fca62847ec0f625d3f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for BPF object load with implicit token creation in libbpf.', 'keywords': 'selftests, BPF, libbpf', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 98e0eaa36adfb580a3aa43fca62847ec0f625d3f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 98e0eaa36adfb580a3aa43fca62847ec0f625d3f + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511225 + Commit Message: + selftests/bpf: add BPF object loading tests with explicit token passing + +Add a few tests that attempt to load BPF object containing privileged +map + Parent Hashes: 1d0dd6ea2e38c18e1b31a8c3c59b6bdfe4f4efde + Refs: program + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for BPF object loading with explicit token passing focusing on privileged maps.', 'keywords': 'selftests,BPF,token', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1d0dd6ea2e38c18e1b31a8c3c59b6bdfe4f4efde +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1d0dd6ea2e38c18e1b31a8c3c59b6bdfe4f4efde + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511225 + Commit Message: + libbpf: wire up BPF token support at BPF object level + +Add BPF token support to BPF object-level functionality. + +BPF token is supported by BPF object logic either as an explicitly +provided BPF token from outside (through BPF FS path or explicit BPF +token FD) + Parent Hashes: a75bb6a16518d4a224f24116633f3f9d5787f6d1 + Refs: or implicitly (unless prevented through +bpf_object_open_opts). + +Implicit mode is assumed to be the most common one for user namespaced +unprivileged workloads. The assumption is that privileged container +manager sets up default BPF FS mount point at /sys/fs/bpf with BPF token +delegation options (delegate_{cmds + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds BPF token support to BPF object-level functionality in libbpf.', 'keywords': 'BPF token, BPF object, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a75bb6a16518d4a224f24116633f3f9d5787f6d1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a75bb6a16518d4a224f24116633f3f9d5787f6d1 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511225 + Commit Message: + libbpf: wire up token_fd into feature probing logic + +Adjust feature probing callbacks to take into account optional token_fd. +In unprivileged contexts + Parent Hashes: ab8fc393b27cd2d6dd1ced1ba2358ddcd123fc15 + Refs: some feature detectors would fail to detect +kernel support just because BPF program + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adjusts feature probing logic to incorporate the optional token_fd in libbpf.', 'keywords': 'libbpf, token_fd, feature', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ab8fc393b27cd2d6dd1ced1ba2358ddcd123fc15 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ab8fc393b27cd2d6dd1ced1ba2358ddcd123fc15 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511225 + Commit Message: + libbpf: move feature detection code into its own file + +It's quite a lot of well isolated code + Parent Hashes: 29c302a2e265a356434b005155990a9e766db75d + Refs: so it seems like a good +candidate to move it out of libbpf.c to reduce its size. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactored libbpf by moving feature detection code to a separate file to reduce libbpf.c size.', 'keywords': 'libbpf, refactoring, feature detection', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 29c302a2e265a356434b005155990a9e766db75d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 29c302a2e265a356434b005155990a9e766db75d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511225 + Commit Message: + libbpf: further decouple feature checking logic from bpf_object + +Add feat_supported() helper that accepts feature cache instead of +bpf_object. This allows low-level code in bpf.c to not know or care +about higher-level concept of bpf_object + Parent Hashes: c6c5be3eee975ae640966844db66d404c1de79b1 + Refs: yet it will be able to utilize +custom feature checking in cases where BPF token might influence the +outcome. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Decouples feature checking logic from bpf_object using a feat_supported helper.', 'keywords': 'Libbpf, feature checking, decouple', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c6c5be3eee975ae640966844db66d404c1de79b1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c6c5be3eee975ae640966844db66d404c1de79b1 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511224 + Commit Message: + libbpf: split feature detectors definitions from cached results + +Split a list of supported feature detectors with their corresponding +callbacks from actual cached supported/missing values. This will allow +to have more flexible per-token or per-object feature detectors in +subsequent refactorings. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: f5fdb51fb980077a4c6c78f3f775821f611fb38b + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit separates feature detectors definitions from cached results for more flexibility in libbpf.', 'keywords': 'libbpf,feature detectors,refactoring', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f5fdb51fb980077a4c6c78f3f775821f611fb38b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f5fdb51fb980077a4c6c78f3f775821f611fb38b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702511224 + Commit Message: + bpf: fail BPF_TOKEN_CREATE if no delegation option was set on BPF FS + +It's quite confusing in practice when it's possible to successfully +create a BPF token from BPF FS that didn't have any of delegate_xxx +mount options set up. While it's not wrong + Parent Hashes: f04f2ce6018f3cb33ac96270b9153c2920ead190 + Refs: it's actually more +meaningful to reject BPF_TOKEN_CREATE with specific error code (-ENOENT) +to let user-space know that no token delegation is setup up. + +So + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies BPF_TOKEN_CREATE to fail with -ENOENT if no delegation option is set on BPF FS.', 'keywords': 'BPF_TOKEN_CREATE, delegation, ENOENT', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f04f2ce6018f3cb33ac96270b9153c2920ead190 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f04f2ce6018f3cb33ac96270b9153c2920ead190 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702510939 + Commit Message: + bpf: selftests: Add verifier tests for CO-RE bitfield writes + +Add some tests that exercise BPF_CORE_WRITE_BITFIELD() macro. Since some +non-trivial bit fiddling is going on + Parent Hashes: 7d19c00e9abc8ad3b3b72a1989331f45287e6bf5 + Refs: make sure various edge cases (such +as adjacent bitfields and bitfields at the edge of structs) are +exercised. + +Acked-by: Andrii Nakryiko +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/72698a1080fa565f541d5654705255984ea2a029.1702325874.git.dxu@dxuuu.xyz +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for CO-RE bitfield writes in the eBPF verifier.', 'keywords': 'CO-RE, selftests, bitfield', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7d19c00e9abc8ad3b3b72a1989331f45287e6bf5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7d19c00e9abc8ad3b3b72a1989331f45287e6bf5 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702510939 + Commit Message: + bpf: selftests: test_loader: Support __btf_path() annotation + +This commit adds support for per-prog btf_custom_path. This is necessary +for testing CO-RE relocations on non-vmlinux types using test_loader +infrastructure. + +Acked-by: Andrii Nakryiko +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/660ea7f2fdbdd5103bc1af87c9fc931f05327926.1702325874.git.dxu@dxuuu.xyz +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 2f70803532e9b7f14897d17f8944d431755661a7 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds support for per-prog BTF custom paths for testing CO-RE relocations.', 'keywords': 'selftests,test_loader,BTF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2f70803532e9b7f14897d17f8944d431755661a7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2f70803532e9b7f14897d17f8944d431755661a7 + Author Name: Daniel Xu + Author Email: dxu@dxuuu.xyz + Commit Date: 1702510939 + Commit Message: + libbpf: Add BPF_CORE_WRITE_BITFIELD() macro + +=== Motivation === + +Similar to reading from CO-RE bitfields + Parent Hashes: 750e785796bb72423b97cac21ecd0fa3b3b65610 + Refs: we need a CO-RE aware bitfield +writing wrapper to make the verifier happy. + +Two alternatives to this approach are: + +1. Use the upcoming `preserve_static_offset` [0] attribute to disable + CO-RE on specific structs. +2. Use broader byte-sized writes to write to bitfields. + +(1) is a bit hard to use. It requires specific and not-very-obvious +annotations to bpftool generated vmlinux.h. It's also not generally +available in released LLVM versions yet. + +(2) makes the code quite hard to read and write. And especially if +BPF_CORE_READ_BITFIELD() is already being used + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new macro BPF_CORE_WRITE_BITFIELD() in libbpf for CO-RE bitfield writing.', 'keywords': 'macro, libbpf, bitfield', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 750e785796bb72423b97cac21ecd0fa3b3b65610 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 750e785796bb72423b97cac21ecd0fa3b3b65610 + Author Name: Jie Jiang + Author Email: jiejiang@chromium.org + Commit Date: 1702510662 + Commit Message: + bpf: Support uid and gid when mounting bpffs + +Parse uid and gid in bpf_parse_param() so that they can be passed in as +the `data` parameter when mount() bpffs. This will be useful when we +want to control which user/group has the control to the mounted bpffs + Parent Hashes: 62d9a969f4a95219c757831e9ad66cd4dd9edee5 + Refs: +otherwise a separate chown() call will be needed. + +Signed-off-by: Jie Jiang +Signed-off-by: Andrii Nakryiko +Acked-by: Mike Frysinger +Acked-by: Christian Brauner +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231212093923.497838-1-jiejiang@chromium.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds support for uid and gid when mounting bpffs to control user/group access.', 'keywords': 'uid,gid,bpffs', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 62d9a969f4a95219c757831e9ad66cd4dd9edee5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 62d9a969f4a95219c757831e9ad66cd4dd9edee5 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702492036 + Commit Message: + selftests/bpf: fix compiler warnings in RELEASE=1 mode + +When compiling BPF selftests with RELEASE=1 + Parent Hashes: e1ba7f64b192f083b4423644be03bb9e3dc8ae84 + Refs: we get two new +warnings + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes compiler warnings in BPF selftests when using RELEASE=1.', 'keywords': 'compiler, warnings, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 43e8832fed08438e2a27afed9bac21acd0ceffe5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 43e8832fed08438e2a27afed9bac21acd0ceffe5 + Author Name: John Hubbard + Author Email: jhubbard@nvidia.com + Commit Date: 1702430419 + Commit Message: + Revert "selftests: error out if kernel header files are not yet built" + +This reverts commit 9fc96c7c19df ("selftests: error out if kernel header +files are not yet built"). + +It turns out that requiring the kernel headers to be built as a +prerequisite to building selftests + Parent Hashes: 1dd11e977360ad3493812da0b05ffd9adcdd15a1 + Refs: does not work in many cases. For +example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Revert a change requiring kernel headers to be built before selftests due to compatibility issues.', 'keywords': 'revert,selftests,headers', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e1ba7f64b192f083b4423644be03bb9e3dc8ae84 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e1ba7f64b192f083b4423644be03bb9e3dc8ae84 + Author Name: YiFei Zhu + Author Email: zhuyifei@google.com + Commit Date: 1702425214 + Commit Message: + selftests/bpf: Relax time_tai test for equal timestamps in tai_forward + +We're observing test flakiness on an arm64 platform which might not +have timestamps as precise as x86. The test log looks like: + + test_time_tai:PASS:tai_open 0 nsec + test_time_tai:PASS:test_run 0 nsec + test_time_tai:PASS:tai_ts1 0 nsec + test_time_tai:PASS:tai_ts2 0 nsec + test_time_tai:FAIL:tai_forward unexpected tai_forward: actual 1702348135471494160 <= expected 1702348135471494160 + test_time_tai:PASS:tai_gettime 0 nsec + test_time_tai:PASS:tai_future_ts1 0 nsec + test_time_tai:PASS:tai_future_ts2 0 nsec + test_time_tai:PASS:tai_range_ts1 0 nsec + test_time_tai:PASS:tai_range_ts2 0 nsec + #199 time_tai:FAIL + +This patch changes ASSERT_GT to ASSERT_GE in the tai_forward assertion +so that equal timestamps are permitted. + +Fixes: 64e15820b987 ("selftests/bpf: Add BPF-helper test for CLOCK_TAI access") +Signed-off-by: YiFei Zhu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231212182911.3784108-1-zhuyifei@google.com + + Parent Hashes: 745e0311306507ddbe1727ac798c8f956812b810 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Relaxed the tai_forward test assertion to allow equal timestamps to fix flakiness in ARM64 platforms.', 'keywords': 'test, timestamps, ARM64', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 745e0311306507ddbe1727ac798c8f956812b810 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 745e0311306507ddbe1727ac798c8f956812b810 + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1702424132 + Commit Message: + bpf: Comment on check_mem_size_reg + +This patch adds a comment to check_mem_size_reg -- a function whose +meaning is not very transparent. The function implicitly deals with two +registers connected by convention + Parent Hashes: 56c26d5ad86dfe48a76855a91b523ab4f372c003 + Refs: which is not obvious. + +Signed-off-by: Andrei Matei +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231210225149.67639-1-andreimatei1@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added comments to clarify functionality of check_mem_size_reg function in bpf code.', 'keywords': 'comments, check_mem_size_reg, function', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5805c82513c444333efb086017be8d666336858a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5805c82513c444333efb086017be8d666336858a + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1702403713 + Commit Message: + libperf cpumap: Add for_each_cpu() that skips the "any CPU" case + +When iterating CPUs in a CPU map it is often desirable to skip the "any +CPU" (aka dummy) case. Add a helper for this and use in builtin-record. + +Reviewed-by: James Clark +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Alexandre Ghiti +Cc: Andrew Jones +Cc: André Almeida +Cc: Athira Jajeev +Cc: Atish Patra +Cc: Changbin Du +Cc: Darren Hart +Cc: Davidlohr Bueso +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: John Garry +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Mark Rutland +Cc: Mike Leach +Cc: Namhyung Kim +Cc: Nick Desaulniers +Cc: Paolo Bonzini +Cc: Paran Lee +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Suzuki Poulouse +Cc: Thomas Gleixner +Cc: Will Deacon +Cc: Yang Jihong +Cc: Yang Li +Cc: Yanteng Si +Cc: bpf@vger.kernel.org +Cc: coresight@lists.linaro.org +Cc: linux-arm-kernel@lists.infradead.org +Link: https://lore.kernel.org/r/20231129060211.1890454-6-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + Parent Hashes: effe957c6bb70cac12918c0f5fd4cefb35967618 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a helper function for iterating CPUs in a CPU map that skips the "any CPU" case in libperf.', 'keywords': 'libperf, cpumap, helper', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: effe957c6bb70cac12918c0f5fd4cefb35967618 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: effe957c6bb70cac12918c0f5fd4cefb35967618 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1702403713 + Commit Message: + libperf cpumap: Replace usage of perf_cpu_map__new(NULL) with perf_cpu_map__new_online_cpus() + +Passing NULL to perf_cpu_map__new() performs +perf_cpu_map__new_online_cpus() + Parent Hashes: 923ca62a7b1edceaa61eb6ac8dc56fdac51913b8 + Refs: just directly call +perf_cpu_map__new_online_cpus() to be more intention revealing. + +Reviewed-by: James Clark +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Alexandre Ghiti +Cc: Andrew Jones +Cc: André Almeida +Cc: Athira Jajeev +Cc: Atish Patra +Cc: Changbin Du +Cc: Darren Hart +Cc: Davidlohr Bueso +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: John Garry +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Mark Rutland +Cc: Mike Leach +Cc: Namhyung Kim +Cc: Nick Desaulniers +Cc: Paolo Bonzini +Cc: Paran Lee +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Suzuki Poulouse +Cc: Thomas Gleixner +Cc: Will Deacon +Cc: Yang Jihong +Cc: Yang Li +Cc: Yanteng Si +Cc: bpf@vger.kernel.org +Cc: coresight@lists.linaro.org +Cc: linux-arm-kernel@lists.infradead.org +Link: https://lore.kernel.org/r/20231129060211.1890454-5-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaces perf_cpu_map__new(NULL) with perf_cpu_map__new_online_cpus() for clearer intention in libperf cpumap.', 'keywords': 'libperf, cpumap, intention', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 923ca62a7b1edceaa61eb6ac8dc56fdac51913b8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 923ca62a7b1edceaa61eb6ac8dc56fdac51913b8 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1702403713 + Commit Message: + libperf cpumap: Rename perf_cpu_map__empty() to perf_cpu_map__has_any_cpu_or_is_empty() + +The name perf_cpu_map_empty is misleading as true is also returned +when the map contains an "any" CPU (aka dummy) map. + +Rename to perf_cpu_map__has_any_cpu_or_is_empty() + Parent Hashes: 8f60f870a9af53295ab4301da05ca453f115a6b6 + Refs: later changes will +(re)introduce perf_cpu_map__empty() and perf_cpu_map__has_any_cpu(). + +Reviewed-by: James Clark +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Alexandre Ghiti +Cc: Andrew Jones +Cc: André Almeida +Cc: Athira Jajeev +Cc: Atish Patra +Cc: Changbin Du +Cc: Darren Hart +Cc: Davidlohr Bueso +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: John Garry +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Mark Rutland +Cc: Mike Leach +Cc: Namhyung Kim +Cc: Nick Desaulniers +Cc: Paolo Bonzini +Cc: Paran Lee +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Suzuki Poulouse +Cc: Thomas Gleixner +Cc: Will Deacon +Cc: Yang Jihong +Cc: Yang Li +Cc: Yanteng Si +Cc: bpf@vger.kernel.org +Cc: coresight@lists.linaro.org +Cc: linux-arm-kernel@lists.infradead.org +Link: https://lore.kernel.org/r/20231129060211.1890454-4-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Renamed a misleading function in libperf cpumap to improve accuracy and clarity.', 'keywords': 'function, rename, libperf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 8f60f870a9af53295ab4301da05ca453f115a6b6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8f60f870a9af53295ab4301da05ca453f115a6b6 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1702403691 + Commit Message: + libperf cpumap: Rename perf_cpu_map__default_new() to perf_cpu_map__new_online_cpus() and prefer sysfs + +Rename perf_cpu_map__default_new() to perf_cpu_map__new_online_cpus() to +better indicate what the implementation does. + +Read the online CPUs from /sys/devices/system/cpu/online first before +using sysconf() as it can't accurately configure holes in the CPU map. + +If sysconf() is used + Parent Hashes: 48219b089d84f109e8a81d8a7fa1bbc2e6e5f97d + Refs: warn when the configured and online processors +disagree. + +When reading from a file + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit renames a function to better describe its function of reading online CPUs from sysfs in the libperf library.', 'keywords': 'rename, libperf, cpumap', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 56c26d5ad86dfe48a76855a91b523ab4f372c003 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 56c26d5ad86dfe48a76855a91b523ab4f372c003 + Author Name: Yang Li + Author Email: yang.lee@linux.alibaba.com + Commit Date: 1702403527 + Commit Message: + bpf: Remove unused backtrack_state helper functions + +The function are defined in the verifier.c file + Parent Hashes: f77d795618b92ac6fdb43de0d4036c6ce49f0b82 + Refs: but not called +elsewhere + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove unused helper functions from verifier.c file in bpf codebase.', 'keywords': 'unused, backtrack, helper', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f77d795618b92ac6fdb43de0d4036c6ce49f0b82 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f77d795618b92ac6fdb43de0d4036c6ce49f0b82 + Author Name: Manu Bretelle + Author Email: chantr4@gmail.com + Commit Date: 1702403507 + Commit Message: + selftests/bpf: Fixes tests for filesystem kfuncs + +`fs_kfuncs.c`'s `test_xattr` would fail the test even when the +filesystem did not support xattr + Parent Hashes: 406a6fa44bfbc8563f0612b08d43df2fa65e8bc5 + Refs: for instance when /tmp is mounted as +tmpfs. + +This change checks errno when setxattr fail. If the failure is due to +the operation being unsupported + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes tests for filesystem kfuncs by checking errno when setxattr fails due to unsupported operations.', 'keywords': 'fixes, filesystem, kfuncs', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 48219b089d84f109e8a81d8a7fa1bbc2e6e5f97d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 48219b089d84f109e8a81d8a7fa1bbc2e6e5f97d + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1702400507 + Commit Message: + libperf cpumap: Rename perf_cpu_map__dummy_new() to perf_cpu_map__new_any_cpu() + +Rename perf_cpu_map__dummy_new() to perf_cpu_map__new_any_cpu() to +better indicate this is creating a CPU map for the perf_event_open "any" +CPU case. + +Reviewed-by: James Clark +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Alexandre Ghiti +Cc: Andrew Jones +Cc: André Almeida +Cc: Athira Jajeev +Cc: Atish Patra +Cc: Changbin Du +Cc: Darren Hart +Cc: Davidlohr Bueso +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: John Garry +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Mark Rutland +Cc: Mike Leach +Cc: Namhyung Kim +Cc: Nick Desaulniers +Cc: Paolo Bonzini +Cc: Paran Lee +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Suzuki Poulouse +Cc: Thomas Gleixner +Cc: Will Deacon +Cc: Yang Jihong +Cc: Yang Li +Cc: Yanteng Si +Cc: bpf@vger.kernel.org +Cc: coresight@lists.linaro.org +Cc: linux-arm-kernel@lists.infradead.org +Link: https://lore.kernel.org/r/20231129060211.1890454-2-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + Parent Hashes: 8596ba324356a7392a6639024de8c9ae7a9fce92 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Renamed perf_cpu_map__dummy_new() to perf_cpu_map__new_any_cpu() to clarify its purpose for 'any' CPU in perf_event_open.", 'keywords': 'CPU map, renaming, perf_event_open', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 406a6fa44bfbc8563f0612b08d43df2fa65e8bc5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 406a6fa44bfbc8563f0612b08d43df2fa65e8bc5 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702351417 + Commit Message: + bpf: use bitfields for simple per-subprog bool flags + +We have a bunch of bool flags for each subprog. Instead of wasting bytes +for them + Parent Hashes: 1a1ad782dcbbacd9e8d4e2e7ff1bf14d1db80727 + Refs: use bitfields instead. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231204233931.49758-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit optimizes memory usage by utilizing bitfields for subprogram boolean flags.', 'keywords': 'bitfields, bool flags, subprog', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1a1ad782dcbbacd9e8d4e2e7ff1bf14d1db80727 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1a1ad782dcbbacd9e8d4e2e7ff1bf14d1db80727 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702351412 + Commit Message: + bpf: tidy up exception callback management a bit + +Use the fact that we are passing subprog index around and have +a corresponding struct bpf_subprog_info in bpf_verifier_env for each +subprogram. We don't need to separately pass around a flag whether +subprog is exception callback or not + Parent Hashes: 22b769bb4f87060774bfdd6facbab438ed3b8453 + Refs: each relevant verifier function +can determine this using provided subprog index if we maintain +bpf_subprog_info properly. + +Also move out exception callback-specific logic from +btf_prepare_func_args() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor exception callback management using bpf_subprog_info with subprog index in bpf_verifier_env.', 'keywords': 'exception, subprog, management', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 22b769bb4f87060774bfdd6facbab438ed3b8453 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 22b769bb4f87060774bfdd6facbab438ed3b8453 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702351282 + Commit Message: + bpf: emit more dynptr information in verifier log + +Emit dynptr type for CONST_PTR_TO_DYNPTR register. Also emit id + Parent Hashes: 1e68485d8299860e68c4e1d29589ff0d20db0287 + Refs: +ref_obj_id + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances the verifier log by emitting more dynptr information including type and ID for CONST_PTR_TO_DYNPTR.', 'keywords': 'dynptr,verifier log,CONST_PTR_TO_DYNPTR', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1e68485d8299860e68c4e1d29589ff0d20db0287 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1e68485d8299860e68c4e1d29589ff0d20db0287 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702351282 + Commit Message: + bpf: log PTR_TO_MEM memory size in verifier log + +Emit valid memory size addressable through PTR_TO_MEM register. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231204233931.49758-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: e72c1ccfd449598f7eda10d3bb7441d501ddcfc3 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Addability to log memory size for PTR_TO_MEM in the verifier.', 'keywords': 'PTR_TO_MEM,memory size,verifier', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e72c1ccfd449598f7eda10d3bb7441d501ddcfc3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e72c1ccfd449598f7eda10d3bb7441d501ddcfc3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702350992 + Commit Message: + selftests/bpf: validate eliminated global subprog is not freplaceable + +Add selftest that establishes dead code-eliminated valid global subprog +(global_dead) and makes sure that it's not possible to freplace it + Parent Hashes: 2ebe81c814355d000fe49d9c4213983844dcb32b + Refs: as +it's effectively not there. This test will fail with unexpected success +before 2afae08c9dcb ("bpf: Validate global subprogs lazily"). + +v2->v3: + - add missing err assignment (Alan); + - undo unnecessary signature changes in verifier_global_subprogs.c (Eduard); +v1->v2: + - don't rely on assembly output in verifier log + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftest for global subprogs to ensure non-freplaceability of dead code-eliminated subprograms.', 'keywords': 'selftest, global subprog, freplace', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2ebe81c814355d000fe49d9c4213983844dcb32b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2ebe81c814355d000fe49d9c4213983844dcb32b + Author Name: Aleksander Lobakin + Author Email: aleksander.lobakin@intel.com + Commit Date: 1702307376 + Commit Message: + net + Parent Hashes: 15c79c6507c0eab5ec0d4cd402ac52d42735a43e + Refs: xdp: Allow metadata > 32 + +32 bytes may be not enough for some custom metadata. Relax the restriction + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit relaxes the metadata size restriction in XDP programs from 32 bytes to allow larger custom metadata.', 'keywords': 'metadata,XDP,restriction', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 15c79c6507c0eab5ec0d4cd402ac52d42735a43e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 15c79c6507c0eab5ec0d4cd402ac52d42735a43e + Author Name: Larysa Zaremba + Author Email: larysa.zaremba@intel.com + Commit Date: 1702307364 + Commit Message: + selftests/bpf: Increase invalid metadata size + +Changed check expects passed data meta to be deemed invalid. After loosening +the requirement + Parent Hashes: 5bcbdf72df88a351642627d94b93af7c9301b6e2 + Refs: the size of 36 bytes becomes valid. Therefore + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Increased invalid metadata size in selftests to ensure 36 bytes is recognized as valid.', 'keywords': 'invalid, metadata, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5bcbdf72df88a351642627d94b93af7c9301b6e2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5bcbdf72df88a351642627d94b93af7c9301b6e2 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702186653 + Commit Message: + Merge branch 'add-new-bpf_cpumask_weight-kfunc' + +David Vernet says: + +==================== +Add new bpf_cpumask_weight() kfunc + +It can be useful to query how many bits are set in a cpumask. For +example + Parent Hashes: 5181dc08f79583c6dead80208137a97e68ff07b0 88f6047191e69bdd02cf1b9b5b514f7e514e8b86 + Refs: if you want to perform special logic for the last remaining +core that's set in a mask. This logic is already exposed through the +main kernel's cpumask header as cpumask_weight() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a new bpf_cpumask_weight() kfunc to query the number of set bits in a cpumask.', 'keywords': 'bpf_cpumask_weight,kfunc,cpumask', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 88f6047191e69bdd02cf1b9b5b514f7e514e8b86 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 88f6047191e69bdd02cf1b9b5b514f7e514e8b86 + Author Name: David Vernet + Author Email: void@manifault.com + Commit Date: 1702186653 + Commit Message: + selftests/bpf: Add test for bpf_cpumask_weight() kfunc + +The new bpf_cpumask_weight() kfunc can be used to count the number of +bits that are set in a struct cpumask* kptr. Let's add a selftest to +verify its behavior. + +Signed-off-by: David Vernet +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231207210843.168466-3-void@manifault.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: a6de18f310a511278c1ff16b96eb2d500eada725 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest for the new bpf_cpumask_weight() kfunc for verifying its functionality.', 'keywords': 'selftest,kfunc,bpf_cpumask_weight', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a6de18f310a511278c1ff16b96eb2d500eada725 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a6de18f310a511278c1ff16b96eb2d500eada725 + Author Name: David Vernet + Author Email: void@manifault.com + Commit Date: 1702186653 + Commit Message: + bpf: Add bpf_cpumask_weight() kfunc + +It can be useful to query how many bits are set in a cpumask. For +example + Parent Hashes: 5181dc08f79583c6dead80208137a97e68ff07b0 + Refs: if you want to perform special logic for the last remaining +core that's set in a mask. Let's therefore add a new +bpf_cpumask_weight() kfunc which checks how many bits are set in a mask. + +Signed-off-by: David Vernet +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231207210843.168466-2-void@manifault.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a new kfunc bpf_cpumask_weight to count bits set in a cpumask.', 'keywords': 'bpf_cpumask_weight,kfunc,cpumask', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5181dc08f79583c6dead80208137a97e68ff07b0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5181dc08f79583c6dead80208137a97e68ff07b0 + Author Name: Tiezhu Yang + Author Email: yangtiezhu@loongson.cn + Commit Date: 1702186074 + Commit Message: + test_bpf: Rename second ALU64_SMOD_X to ALU64_SMOD_K + +Currently + Parent Hashes: 7d8ed51bcb32716a40d71043fcd01c4118858c51 + Refs: there are two test cases with same name +"ALU64_SMOD_X: -7 % 2 = -1" + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit renames a duplicate test case in test_bpf to uniquely identify ALU64_SMOD_X operations.', 'keywords': 'rename, test cases, ALU64_SMOD', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7d8ed51bcb32716a40d71043fcd01c4118858c51 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7d8ed51bcb32716a40d71043fcd01c4118858c51 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702176200 + Commit Message: + selftests/bpf: validate fake register spill/fill precision backtracking logic + +Add two tests validating that verifier's precision backtracking logic +handles BPF_ST_MEM instructions that produce fake register spill into +register slot. This is happening when non-zero constant is written +directly to a slot + Parent Hashes: 482d548d40b0af9af730e4869903d4433e44f014 + Refs: e.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Added tests for verifier's precision backtracking logic in BPF register spill handling.", 'keywords': 'precision, verifier, tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 482d548d40b0af9af730e4869903d4433e44f014 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 482d548d40b0af9af730e4869903d4433e44f014 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702176200 + Commit Message: + bpf: handle fake register spill to stack with BPF_ST_MEM instruction + +When verifier validates BPF_ST_MEM instruction that stores known +constant to stack (e.g. + Parent Hashes: 8477fe1de9a631d634ccfda7fe147eba90f55732 + Refs: *(u64 *)(r10 - 8) = 123) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhances the eBPF verifier to correctly handle BPF_ST_MEM instruction when storing known constants to stack.', 'keywords': 'BPF_ST_MEM, verifier, stack', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8477fe1de9a631d634ccfda7fe147eba90f55732 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8477fe1de9a631d634ccfda7fe147eba90f55732 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1702174403 + Commit Message: + Merge branch 'bpf-fixes-for-maybe_wait_bpf_programs' + +Hou Tao says: + +==================== +The patch set aims to fix the problems found when inspecting the code +related with maybe_wait_bpf_programs(). + +Patch #1 removes unnecessary invocation of maybe_wait_bpf_programs(). +Patch #2 calls maybe_wait_bpf_programs() only once for batched update. +Patch #3 adds the missed waiting when doing batched lookup_deletion on +htab of maps. Patch #4 does wait only if the update or deletion +operation succeeds. Patch #5 fixes the value of batch.count when memory +allocation fails. +==================== + +Link: https://lore.kernel.org/r/20231208102355.2628918-1-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 32fa058398624166dd04ff4af49cfef69c94abbc 06e5c999f10269a532304e89a6adb2fbfeb0593c + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit addresses issues with maybe_wait_bpf_programs in batched operations and enhances memory allocation handling for eBPF maps.', 'keywords': 'maybe_wait_bpf_programs, batched update, maps', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 06e5c999f10269a532304e89a6adb2fbfeb0593c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 06e5c999f10269a532304e89a6adb2fbfeb0593c + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702174354 + Commit Message: + bpf: Set uattr->batch.count as zero before batched update or deletion + +generic_map_{delete + Parent Hashes: 67ad2c73ff29b32bd09135ec07c26e59490dbb3b + Refs: update}_batch() doesn't set uattr->batch.count as +zero before it tries to allocate memory for key. If the memory +allocation fails + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit sets uattr->batch.count to zero before performing memory allocations for batched updates or deletions.', 'keywords': 'uattr, batch, update', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 67ad2c73ff29b32bd09135ec07c26e59490dbb3b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 67ad2c73ff29b32bd09135ec07c26e59490dbb3b + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702174354 + Commit Message: + bpf: Only call maybe_wait_bpf_programs() when map operation succeeds + +There is no need to call maybe_wait_bpf_programs() if update or deletion +operation fails. So only call maybe_wait_bpf_programs() if update or +deletion operation succeeds. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231208102355.2628918-5-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 012772581d040607ac1f981f47f6afd2336b4580 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize bpf map operation to conditionally call maybe_wait_bpf_programs() only on success.', 'keywords': 'bpf,map,operation', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 012772581d040607ac1f981f47f6afd2336b4580 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 012772581d040607ac1f981f47f6afd2336b4580 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702174354 + Commit Message: + bpf: Add missed maybe_wait_bpf_programs() for htab of maps + +When doing batched lookup and deletion operations on htab of maps + Parent Hashes: 37ba5b59d6adfa08926acd3a833608487a18c2ef + Refs: +maybe_wait_bpf_programs() is needed to ensure all programs don't use the +inner map after the bpf syscall returns. + +Instead of adding the wait in __htab_map_lookup_and_delete_batch() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add maybe_wait_bpf_programs() to ensure safe usage of maps after batched operations in eBPF.', 'keywords': 'maybe_wait_bpf_programs, htab, maps', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 37ba5b59d6adfa08926acd3a833608487a18c2ef +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 37ba5b59d6adfa08926acd3a833608487a18c2ef + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702174353 + Commit Message: + bpf: Call maybe_wait_bpf_programs() only once for generic_map_update_batch() + +Just like commit 9087c6ff8dfe ("bpf: Call maybe_wait_bpf_programs() only +once from generic_map_delete_batch()") + Parent Hashes: c26f2a8901393c9f81909da0a4324587092bd3a3 + Refs: there is also no need to call +maybe_wait_bpf_programs() for each update in batched update + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize the call to maybe_wait_bpf_programs() by executing it once for generic_map_update_batch().', 'keywords': 'maybe_wait_bpf_programs, generic_map_update_batch, optimize', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c26f2a8901393c9f81909da0a4324587092bd3a3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c26f2a8901393c9f81909da0a4324587092bd3a3 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1702174353 + Commit Message: + bpf: Remove unnecessary wait from bpf_map_copy_value() + +Both map_lookup_elem() and generic_map_lookup_batch() use +bpf_map_copy_value() to lookup and copy the value + Parent Hashes: 32fa058398624166dd04ff4af49cfef69c94abbc + Refs: and there is no +update operation in bpf_map_copy_value() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes unnecessary waiting from the function bpf_map_copy_value.', 'keywords': 'remove unnecessary wait, map_copy_value, map_lookup_elem', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b10a3ccaf6e39f6290ca29d7c24604082eacaea0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b10a3ccaf6e39f6290ca29d7c24604082eacaea0 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1702153556 + Commit Message: + Merge tag 'loongarch-fixes-6.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson + +Pull LoongArch fixes from Huacai Chen: + "Preserve syscall nr across execve() + Parent Hashes: b8503b215789628d3625ef6aa252f323e32be929 e2f7b3d8b4b300956a77fa1ab084c931ba1c7421 + Refs: slightly clean up drdtime() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge LoongArch fixes for preserving syscall number across execve and cleaning up drdtime.', 'keywords': 'LoongArch, syscall, fixes', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e2f7b3d8b4b300956a77fa1ab084c931ba1c7421 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e2f7b3d8b4b300956a77fa1ab084c931ba1c7421 + Author Name: Tiezhu Yang + Author Email: yangtiezhu@loongson.cn + Commit Date: 1702108156 + Commit Message: + LoongArch: BPF: Fix unconditional bswap instructions + +We can see that "bswap32: Takes an unsigned 32-bit number in either big- +or little-endian format and returns the equivalent number with the same +bit width but opposite endianness" in BPF Instruction Set Specification + Parent Hashes: 772cbe948fb07389639d4e698a2d3299f8e538b8 + Refs: +so it should clear the upper 32 bits in "case 32:" for both BPF_ALU and +BPF_ALU64. + +[root@linux fedora]# echo 1 > /proc/sys/net/core/bpf_jit_enable +[root@linux fedora]# modprobe test_bpf + +Before: +test_bpf: #313 BSWAP 32: 0x0123456789abcdef -> 0xefcdab89 jited:1 ret 1460850314 != -271733879 (0x5712ce8a != 0xefcdab89)FAIL (1 times) +test_bpf: #317 BSWAP 32: 0xfedcba9876543210 -> 0x10325476 jited:1 ret -1460850316 != 271733878 (0xa8ed3174 != 0x10325476)FAIL (1 times) + +After: +test_bpf: #313 BSWAP 32: 0x0123456789abcdef -> 0xefcdab89 jited:1 4 PASS +test_bpf: #317 BSWAP 32: 0xfedcba9876543210 -> 0x10325476 jited:1 4 PASS + +Fixes: 4ebf9216e7df ("LoongArch: BPF: Support unconditional bswap instructions") +Acked-by: Hengqi Chen +Signed-off-by: Tiezhu Yang +Signed-off-by: Huacai Chen + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix the unconditional bswap instruction bug for LoongArch BPF.', 'keywords': 'bswap, LoongArch, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The JIT compiler', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 772cbe948fb07389639d4e698a2d3299f8e538b8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 772cbe948fb07389639d4e698a2d3299f8e538b8 + Author Name: Tiezhu Yang + Author Email: yangtiezhu@loongson.cn + Commit Date: 1702108156 + Commit Message: + LoongArch: BPF: Fix sign-extension mov instructions + +We can see that "Short form of movsx + Parent Hashes: 5d47ec2e6f4c64e30e392cfe9532df98c9beb106 + Refs: dst_reg = (s8 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes sign-extension mov instructions for LoongArch in BPF.', 'keywords': 'LoongArch,BPF,fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5d47ec2e6f4c64e30e392cfe9532df98c9beb106 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5d47ec2e6f4c64e30e392cfe9532df98c9beb106 + Author Name: Hengqi Chen + Author Email: hengqi.chen@gmail.com + Commit Date: 1702108156 + Commit Message: + LoongArch: BPF: Don't sign extend function return value + +The `cls_redirect` test triggers a kernel panic like: + + # ./test_progs -t cls_redirect + Can't find bpf_testmod.ko kernel module: -2 + WARNING! Selftests relying on bpf_testmod.ko will be skipped. + [ 30.938489] CPU 3 Unable to handle kernel paging request at virtual address fffffffffd814de0 + Parent Hashes: fe5757553bf9ebe45ae8ecab5922f6937c8d8dfc + Refs: era == ffff800002009fb8 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a kernel panic issue on LoongArch architecture by preventing sign extension of function return value in BPF.', 'keywords': 'LoongArch, kernel panic, BPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: fe5757553bf9ebe45ae8ecab5922f6937c8d8dfc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fe5757553bf9ebe45ae8ecab5922f6937c8d8dfc + Author Name: Hengqi Chen + Author Email: hengqi.chen@gmail.com + Commit Date: 1702108156 + Commit Message: + LoongArch: BPF: Don't sign extend memory load operand + +The `cgrp_local_storage` test triggers a kernel panic like: + + # ./test_progs -t cgrp_local_storage + Can't find bpf_testmod.ko kernel module: -2 + WARNING! Selftests relying on bpf_testmod.ko will be skipped. + [ 550.930632] CPU 1 Unable to handle kernel paging request at virtual address 0000000000000080 + Parent Hashes: d6c5f06e46a836e6a70c7cfd95bb38a67d9252ec + Refs: era == ffff80000200be34 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes kernel panic issue by modifying memory load operand behavior on LoongArch architecture.', 'keywords': 'LoongArch,memory load,kernel panic', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 32fa058398624166dd04ff4af49cfef69c94abbc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 32fa058398624166dd04ff4af49cfef69c94abbc + Author Name: Sergei Trofimovich + Author Email: slyich@gmail.com + Commit Date: 1702084278 + Commit Message: + libbpf: Add pr_warn() for EINVAL cases in linker_sanity_check_elf + +Before the change on `i686-linux` `systemd` build failed as: + + $ bpftool gen object src/core/bpf/socket_bind/socket-bind.bpf.o src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o + Error: failed to link 'src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o': Invalid argument (22) + +After the change it fails as: + + $ bpftool gen object src/core/bpf/socket_bind/socket-bind.bpf.o src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o + libbpf: ELF section #9 has inconsistent alignment addr=8 != d=4 in src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o + Error: failed to link 'src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o': Invalid argument (22) + +Now it's slightly easier to figure out what is wrong with an ELF file. + +Signed-off-by: Sergei Trofimovich +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231208215100.435876-1-slyich@gmail.com + + Parent Hashes: 09115c33e6ec4a98a0609ac5fa702b7fe566d8f9 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances libbpf by adding a pr_warn() for better error reporting on EINVAL cases during linker sanity check of ELF files.', 'keywords': 'libbpf, pr_warn, EINVAL', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 09115c33e6ec4a98a0609ac5fa702b7fe566d8f9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 09115c33e6ec4a98a0609ac5fa702b7fe566d8f9 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1702084099 + Commit Message: + Merge branch 'bpf: Expand bpf_cgrp_storage to support cgroup1 non-attach case' + +Yafang Shao says: + +==================== +In the current cgroup1 environment + Parent Hashes: 1720c42b90c8f14ffcb2f2f39a1abafc82a5b22e a2c6380b17b6339bfedc98d253b6d85e7014953b + Refs: associating operations between a cgroup +and applications in a BPF program requires storing a mapping of cgroup_id +to application either in a hash map or maintaining it in userspace. +However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit expands the bpf_cgrp_storage to support non-attach cases in cgroup1.', 'keywords': 'bpf_cgrp_storage cgroup1 non-attach', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: a2c6380b17b6339bfedc98d253b6d85e7014953b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a2c6380b17b6339bfedc98d253b6d85e7014953b + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1702084098 + Commit Message: + selftests/bpf: Add selftests for cgroup1 local storage + +Expanding the test coverage from cgroup2 to include cgroup1. The result +as follows + Parent Hashes: f4199271dae12ae407fa739e7012914ea6b3f37b + Refs: + +Already existing test cases for cgroup2: + #48/1 cgrp_local_storage/tp_btf:OK + #48/2 cgrp_local_storage/attach_cgroup:OK + #48/3 cgrp_local_storage/recursion:OK + #48/4 cgrp_local_storage/negative:OK + #48/5 cgrp_local_storage/cgroup_iter_sleepable:OK + #48/6 cgrp_local_storage/yes_rcu_lock:OK + #48/7 cgrp_local_storage/no_rcu_lock:OK + +Expanded test cases for cgroup1: + #48/8 cgrp_local_storage/cgrp1_tp_btf:OK + #48/9 cgrp_local_storage/cgrp1_recursion:OK + #48/10 cgrp_local_storage/cgrp1_negative:OK + #48/11 cgrp_local_storage/cgrp1_iter_sleepable:OK + #48/12 cgrp_local_storage/cgrp1_yes_rcu_lock:OK + #48/13 cgrp_local_storage/cgrp1_no_rcu_lock:OK + +Summary: + #48 cgrp_local_storage:OK + Summary: 1/13 PASSED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for cgroup1 local storage by expanding test coverage from cgroup2.', 'keywords': 'selftests,cgroup1,test coverage', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: f4199271dae12ae407fa739e7012914ea6b3f37b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f4199271dae12ae407fa739e7012914ea6b3f37b + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1702084098 + Commit Message: + selftests/bpf: Add a new cgroup helper open_classid() + +This new helper allows us to obtain the fd of a net_cls cgroup + Parent Hashes: 73d9eb340d2b95e0e86a656a7f3157c137f10129 + Refs: which will +be utilized in the subsequent patch. + +Signed-off-by: Yafang Shao +Acked-by: Tejun Heo +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231206115326.4295-3-laoar.shao@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a new cgroup helper to obtain the file descriptor of a net_cls cgroup.', 'keywords': 'cgroup,helper,net_cls', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 73d9eb340d2b95e0e86a656a7f3157c137f10129 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 73d9eb340d2b95e0e86a656a7f3157c137f10129 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1702084098 + Commit Message: + bpf: Enable bpf_cgrp_storage for cgroup1 non-attach case + +In the current cgroup1 environment + Parent Hashes: 1720c42b90c8f14ffcb2f2f39a1abafc82a5b22e + Refs: associating operations between cgroups +and applications in a BPF program requires storing a mapping of cgroup_id +to application either in a hash map or maintaining it in userspace. +However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable cgroup storage support for BPF programs in cgroup1 non-attach mode.', 'keywords': 'bpf,cgroup1,storage', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 1720c42b90c8f14ffcb2f2f39a1abafc82a5b22e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1720c42b90c8f14ffcb2f2f39a1abafc82a5b22e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702083050 + Commit Message: + selftests/bpf: fix timer/test_bad_ret subtest on test_progs-cpuv4 flavor + +Because test_bad_ret main program is not written in assembly + Parent Hashes: 4af20ab9edee62aa2bb5b6f31b7f029de14e0756 + Refs: we don't +control instruction indices in timer_cb_ret_bad() subprog. This bites us +in timer/test_bad_ret subtest + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes the issue with timer/test_bad_ret subtest on the test_progs-cpuv4 by handling instruction indices in non-assembly code.', 'keywords': 'selftests,bpf,test', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 4af20ab9edee62aa2bb5b6f31b7f029de14e0756 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4af20ab9edee62aa2bb5b6f31b7f029de14e0756 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1702073941 + Commit Message: + Merge branch 'bpf-fix-accesses-to-uninit-stack-slots' + +Andrei Matei says: + +==================== +bpf: fix accesses to uninit stack slots + +Fix two related issues issues around verifying stack accesses: +1. accesses to uninitialized stack memory was allowed inconsistently +2. the maximum stack depth needed for a program was not always +maintained correctly + +The two issues are fixed together in one commit because the code for one +affects the other. + +V4 to V5: +- target bpf-next (Alexei) + +V3 to V4: +- minor fixup to comment in patch 1 (Eduard) +- C89-style in patch 3 (Andrii) + +V2 to V3: +- address review comments from Andrii and Eduard +- drop new verifier tests in favor of editing existing tests to check + for stack depth +- append a patch with a bit of cleanup coming out of the previous review +==================== + +Link: https://lore.kernel.org/r/20231208032519.260451-1-andreimatei1@gmail.com +Signed-off-by: Andrii Nakryiko + + Parent Hashes: 8b7b0e5fe47de90ba6c350f9abece589fb637f79 2929bfac006d8f8e22b307d04e0d71bcb84db698 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes issues with verifying accesses to uninitialized stack slots and maintaining maximum stack depth in bpf programs.', 'keywords': 'uninitialized,stack,depth', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2929bfac006d8f8e22b307d04e0d71bcb84db698 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2929bfac006d8f8e22b307d04e0d71bcb84db698 + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1702073940 + Commit Message: + bpf: Minor cleanup around stack bounds + +Push the rounding up of stack offsets into the function responsible for +growing the stack + Parent Hashes: 6b4a64bafd107e521c01eec3453ce94a3fb38529 + Refs: rather than relying on all the callers to do it. +Uncertainty about whether the callers did it or not tripped up people in +a previous review. + +Signed-off-by: Andrei Matei +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231208032519.260451-4-andreimatei1@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors stack offset rounding into the stack growing function for cleaner code.', 'keywords': 'cleanup, stack, bounds', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6b4a64bafd107e521c01eec3453ce94a3fb38529 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6b4a64bafd107e521c01eec3453ce94a3fb38529 + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1702073940 + Commit Message: + bpf: Fix accesses to uninit stack slots + +Privileged programs are supposed to be able to read uninitialized stack +memory (ever since 6715df8d5) but + Parent Hashes: 92e1567ee3e3f6f160e320890ac77eec50bf8e7d + Refs: before this patch + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes issue with privileged programs accessing uninitialized stack memory in eBPF.', 'keywords': 'fix,uninitialized,stack', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 92e1567ee3e3f6f160e320890ac77eec50bf8e7d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 92e1567ee3e3f6f160e320890ac77eec50bf8e7d + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1702073940 + Commit Message: + bpf: Add some comments to stack representation + +Add comments to the datastructure tracking the stack state + Parent Hashes: 8b7b0e5fe47de90ba6c350f9abece589fb637f79 + Refs: as the +mapping between each stack slot and where its state is stored is not +entirely obvious. + +Signed-off-by: Andrei Matei +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231208032519.260451-2-andreimatei1@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added comments to clarify the stack representation and state tracking in eBPF.', 'keywords': 'comments, stack, representation', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8b7b0e5fe47de90ba6c350f9abece589fb637f79 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8b7b0e5fe47de90ba6c350f9abece589fb637f79 + Author Name: David Vernet + Author Email: void@manifault.com + Commit Date: 1702057139 + Commit Message: + bpf: Load vmlinux btf for any struct_ops map + +In libbpf + Parent Hashes: 483af466e4ee3326d150877ea0626e95c67a395e + Refs: when determining whether we need to load vmlinux btf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates libbpf to load vmlinux BTF for any struct_ops map.', 'keywords': 'libbpf,vmlinux,struct_ops', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5e3f5b81de80c98338bcb47c233aebefee5a4801 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5e3f5b81de80c98338bcb47c233aebefee5a4801 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1701997453 + Commit Message: + Merge tag 'net-6.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + "Including fixes from bpf and netfilter. + + Current release - regressions: + + - veth: fix packet segmentation in veth_convert_skb_to_xdp_buff + + Current release - new code bugs: + + - tcp: assorted fixes to the new Auth Option support + + Older releases - regressions: + + - tcp: fix mid stream window clamp + + - tls: fix incorrect splice handling + + - ipv4: ip_gre: handle skb_pull() failure in ipgre_xmit() + + - dsa: mv88e6xxx: restore USXGMII support for 6393X + + - arcnet: restore support for multiple Sohard Arcnet cards + + Older releases - always broken: + + - tcp: do not accept ACK of bytes we never sent + + - require admin privileges to receive packet traces via netlink + + - packet: move reference count in packet_sock to atomic_long_t + + - bpf: + - fix incorrect branch offset comparison with cpu=v4 + - fix prog_array_map_poke_run map poke update + + - netfilter: + - three fixes for crashes on bad admin commands + - xt_owner: fix race accessing sk->sk_socket + Parent Hashes: 9ace34a8e446c1a566f3b0a3e0c4c483987e39a6 b0a930e8d90caf66a94fee7a9d0b8472bc3e7561 + Refs: TOCTOU null-deref + - nf_tables: fix 'exist' matching on bigendian arches + + - leds: netdev: fix RTNL handling to prevent potential deadlock + + - eth: tg3: prevent races in error/reset handling + + - eth: r8169: fix rtl8125b PAUSE storm when suspended + + - eth: r8152: improve reset and surprise removal handling + + - eth: hns: fix race between changing features and sending + + - eth: nfp: fix sleep in atomic for bonding offload" + +* tag 'net-6.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (62 commits) + vsock/virtio: fix "comparison of distinct pointer types lacks a cast" warning + net/smc: fix missing byte order conversion in CLC handshake + net: dsa: microchip: provide a list of valid protocols for xmit handler + drop_monitor: Require 'CAP_SYS_ADMIN' when joining "events" group + psample: Require 'CAP_NET_ADMIN' when joining "packets" group + bpf: sockmap + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit merges networking and eBPF related fixes for various issues in recent and older Linux kernel releases.', 'keywords': 'networking, eBPF, fixes', 'commit_classification': "It's a bug fix.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', "It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 483af466e4ee3326d150877ea0626e95c67a395e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 483af466e4ee3326d150877ea0626e95c67a395e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701986294 + Commit Message: + Merge branch 'bpf-fix-verification-of-indirect-var-off-stack-access' + +Andrei Matei says: + +==================== +bpf: fix verification of indirect var-off stack access + +V4 to V5: + - split the test into a separate patch + +V3 to V4: + - include a test per Eduard's request + - target bpf-next per Alexei's request (patches didn't change) + +V2 to V3: + - simplify checks for max_off (don't call + check_stack_slot_within_bounds for it) + - append a commit to protect against overflow in the addition of the + register and the offset + +V1 to V2: + - fix max_off calculation for access size = 0 +==================== + +Link: https://lore.kernel.org/r/20231207041150.229139-1-andreimatei1@gmail.com +Signed-off-by: Andrii Nakryiko + + Parent Hashes: 2146f7fe6e028a3905f0658a1a0d8ef7c115d6c1 1d38a9ee81570c4bd61f557832dead4d6f816760 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes the verification of indirect variable offset stack access in the eBPF verifier.', 'keywords': 'verification, indirect, stack', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1d38a9ee81570c4bd61f557832dead4d6f816760 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1d38a9ee81570c4bd61f557832dead4d6f816760 + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1701986290 + Commit Message: + bpf: Guard stack limits against 32bit overflow + +This patch promotes the arithmetic around checking stack bounds to be +done in the 64-bit domain + Parent Hashes: e28bd359bcc8eb849aaa475f3c3f9705fba26d6e + Refs: instead of the current 32bit. The arithmetic +implies adding together a 64-bit register with a int offset. The +register was checked to be below 1<<29 when it was variable + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates stack checks to use 64-bit arithmetic to prevent potential overflow issues.', 'keywords': 'stack,overflow,arithmetic', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e28bd359bcc8eb849aaa475f3c3f9705fba26d6e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e28bd359bcc8eb849aaa475f3c3f9705fba26d6e + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1701986282 + Commit Message: + bpf: Add verifier regression test for previous patch + +Add a regression test for var-off zero-sized reads. + +Signed-off-by: Andrei Matei +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231207041150.229139-3-andreimatei1@gmail.com + + Parent Hashes: a833a17aeac73b33f79433d7cee68d5cafd71e4f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a regression test for zero-sized reads in the BPF verifier.', 'keywords': 'verifier,regression,test', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a833a17aeac73b33f79433d7cee68d5cafd71e4f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a833a17aeac73b33f79433d7cee68d5cafd71e4f + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1701986273 + Commit Message: + bpf: Fix verification of indirect var-off stack access + +This patch fixes a bug around the verification of possibly-zero-sized +stack accesses. When the access was done through a var-offset stack +pointer + Parent Hashes: 2146f7fe6e028a3905f0658a1a0d8ef7c115d6c1 + Refs: check_stack_access_within_bounds was incorrectly computing the +maximum-offset of a zero-sized read to be the same as the register's min +offset. Instead + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a bug in eBPF verifier for incorrect computation of max offset in indirect variable-offset stack access.', 'keywords': 'bug fix,verification,stack access', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: bb9aefde5bbaf6c168c77ba635c155b4980c2287 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bb9aefde5bbaf6c168c77ba635c155b4980c2287 + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1701971549 + Commit Message: + bpf: sockmap + Parent Hashes: c5a595000e2677e865a39f249c056bc05d6e55fd + Refs: updating the sg structure should also update curr + +Curr pointer should be updated when the sg structure is shifted. + +Fixes: 7246d8ed4dcce ("bpf: helper to pop data from messages") +Signed-off-by: John Fastabend +Link: https://lore.kernel.org/r/20231206232706.374377-3-john.fastabend@gmail.com +Signed-off-by: Jakub Kicinski + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes a curr pointer update issue in the sockmap when the sg structure is shifted.', 'keywords': 'sockmap,curr pointer,fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 4de75d3e6b0ece518a2e6e48c2716f1b223716d3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4de75d3e6b0ece518a2e6e48c2716f1b223716d3 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1701971010 + Commit Message: + Merge tag 'nf-23-12-06' of git://git.kernel.org/pub/scm/linux/kernel/git/netfilter/nf + +Pablo Neira Ayuso says: + +==================== +Netfilter fixes for net + +The following patchset contains Netfilter fixes for net: + +1) Incorrect nf_defrag registration for bpf link infra + Parent Hashes: c85e5594b7456d55103fa1f1bde47cd4e002e7fb 7ae836a3d630e146b732fe8ef7d86b243748751f + Refs: from D. Wythe. + +2) Skip inactive elements in pipapo set backend walk to avoid double + deactivation + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge Netfilter fixes for net including nf_defrag registration update for BPF link infra.', 'keywords': 'Netfilter,BPF link,fixes', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c85e5594b7456d55103fa1f1bde47cd4e002e7fb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c85e5594b7456d55103fa1f1bde47cd4e002e7fb + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1701970344 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-12-06 + +We've added 4 non-merge commits during the last 6 day(s) which contain +a total of 7 files changed + Parent Hashes: 0ad722bd9ee3a9bdfca9613148645e4c9b7f26cf ffed24eff9e0e52d8e74df1c18db8ed43b4666e6 + Refs: 185 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge commit for updates in bpf subsystem containing changes to 7 files with 185 insertions.', 'keywords': 'merge, bpf, updates', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2146f7fe6e028a3905f0658a1a0d8ef7c115d6c1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2146f7fe6e028a3905f0658a1a0d8ef7c115d6c1 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1701911841 + Commit Message: + Merge branch 'allocate-bpf-trampoline-on-bpf_prog_pack' + +Song Liu says: + +==================== +Allocate bpf trampoline on bpf_prog_pack + +This set enables allocating bpf trampoline from bpf_prog_pack on x86. The +majority of this work + Parent Hashes: 7065eefb38f16c91e9ace36fb7c873e4c9857c27 3ba026fca8786161b0c4d75be396e61d6816e0a1 + Refs: however + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enables allocating BPF trampolines from bpf_prog_pack on x86.', 'keywords': 'BPF trampolines, bpf_prog_pack, x86', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3ba026fca8786161b0c4d75be396e61d6816e0a1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3ba026fca8786161b0c4d75be396e61d6816e0a1 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701911841 + Commit Message: + x86 + Parent Hashes: 26ef208c209a0e6eed8942a5d191b39dccfa6e38 + Refs: bpf: Use bpf_prog_pack for bpf trampoline + +There are three major changes here: + +1. Add arch_[alloc|free]_bpf_trampoline based on bpf_prog_pack; +2. Let arch_prepare_bpf_trampoline handle ROX input image + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds arch_alloc and free_bpf_trampoline based on bpf_prog_pack and modifies arch_prepare_bpf_trampoline for ROX input image.', 'keywords': 'bpf_prog_pack, bpf_trampoline, ROX', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 26ef208c209a0e6eed8942a5d191b39dccfa6e38 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 26ef208c209a0e6eed8942a5d191b39dccfa6e38 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701911840 + Commit Message: + bpf: Use arch_bpf_trampoline_size + +Instead of blindly allocating PAGE_SIZE for each trampoline + Parent Hashes: 96d1b7c081c0c96cbe8901045f4ff15a2e9974a2 + Refs: check the size +of the trampoline with arch_bpf_trampoline_size(). This size is saved in +bpf_tramp_image->size + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize trampoline allocation in BPF by using arch_bpf_trampoline_size instead of default PAGE_SIZE.', 'keywords': 'trampoline, allocation, BPF', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 96d1b7c081c0c96cbe8901045f4ff15a2e9974a2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 96d1b7c081c0c96cbe8901045f4ff15a2e9974a2 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701911840 + Commit Message: + bpf: Add arch_bpf_trampoline_size() + +This helper will be used to calculate the size of the trampoline before +allocating the memory. + +arch_prepare_bpf_trampoline() for arm64 and riscv64 can use +arch_bpf_trampoline_size() to check the trampoline fits in the image. + +OTOH + Parent Hashes: 38b8b58ae776bf748bd1bd7a24c3fd1d10f76f45 + Refs: arch_prepare_bpf_trampoline() for s390 has to call the JIT process +twice + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a helper to calculate trampoline size before memory allocation for arm64 and riscv64 architectures.', 'keywords': 'trampoline, arm64, riscv64', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 38b8b58ae776bf748bd1bd7a24c3fd1d10f76f45 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 38b8b58ae776bf748bd1bd7a24c3fd1d10f76f45 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701911840 + Commit Message: + bpf + Parent Hashes: 82583daa2efc2e336962b231a46bad03a280b3e0 + Refs: x86: Adjust arch_prepare_bpf_trampoline return value + +x86's implementation of arch_prepare_bpf_trampoline() requires +BPF_INSN_SAFETY buffer space between end of program and image_end. OTOH + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adjust return value of arch_prepare_bpf_trampoline on x86 to ensure buffer space for BPF_INSN_SAFETY.', 'keywords': 'x86, bpf trampoline, buffer space', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 82583daa2efc2e336962b231a46bad03a280b3e0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 82583daa2efc2e336962b231a46bad03a280b3e0 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701911840 + Commit Message: + bpf: Add helpers for trampoline image management + +As BPF trampoline of different archs moves from bpf_jit_[alloc|free]_exec() +to bpf_prog_pack_[alloc|free]() + Parent Hashes: 7a3d9a159b178e87306a6e989071ed9a114a1a31 + Refs: we need to use different _alloc + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add helpers for managing trampoline images in BPF by transitioning from bpf_jit to bpf_prog_pack.', 'keywords': 'trampoline, helpers, management', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7a3d9a159b178e87306a6e989071ed9a114a1a31 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7a3d9a159b178e87306a6e989071ed9a114a1a31 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701911840 + Commit Message: + bpf: Adjust argument names of arch_prepare_bpf_trampoline() + +We are using "im" for "struct bpf_tramp_image" and "tr" for "struct +bpf_trampoline" in most of the code base. The only exception is the +prototype and fallback version of arch_prepare_bpf_trampoline(). Update +them to match the rest of the code base. + +We mix "orig_call" and "func_addr" for the argument in different versions +of arch_prepare_bpf_trampoline(). s/orig_call/func_addr/g so they match. + +Signed-off-by: Song Liu +Acked-by: Ilya Leoshkevich +Tested-by: Ilya Leoshkevich # on s390x +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/r/20231206224054.492250-3-song@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: f08a1c658257c73697a819c4ded3a84b6f0ead74 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update argument names in arch_prepare_bpf_trampoline() for consistency across code base.', 'keywords': 'argument, names, consistency', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f08a1c658257c73697a819c4ded3a84b6f0ead74 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f08a1c658257c73697a819c4ded3a84b6f0ead74 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701911840 + Commit Message: + bpf: Let bpf_prog_pack_free handle any pointer + +Currently + Parent Hashes: 7065eefb38f16c91e9ace36fb7c873e4c9857c27 + Refs: bpf_prog_pack_free only can only free pointer to struct +bpf_binary_header + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhanced bpf_prog_pack_free to handle any pointer instead of just bpf_binary_header.', 'keywords': 'bpf_prog_pack_free,pointer,enhancement', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7065eefb38f16c91e9ace36fb7c873e4c9857c27 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7065eefb38f16c91e9ace36fb7c873e4c9857c27 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701902476 + Commit Message: + bpf: rename MAX_BPF_LINK_TYPE into __MAX_BPF_LINK_TYPE for consistency + +To stay consistent with the naming pattern used for similar cases in BPF +UAPI (__MAX_BPF_ATTACH_TYPE + Parent Hashes: c35919dcce2855d68cf45ffa427b8ea78e4f7c68 + Refs: etc) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Renamed MAX_BPF_LINK_TYPE to __MAX_BPF_LINK_TYPE for naming consistency.', 'keywords': 'rename, consistency, UAPI', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ffed24eff9e0e52d8e74df1c18db8ed43b4666e6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ffed24eff9e0e52d8e74df1c18db8ed43b4666e6 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1701898843 + Commit Message: + selftests/bpf: Add test for early update in prog_array_map_poke_run + +Adding test that tries to trigger the BUG_IN during early map update +in prog_array_map_poke_run function. + +The idea is to share prog array map between thread that constantly +updates it and another one loading a program that uses that prog +array. + +Eventually we will hit a place where the program is ok to be updated +(poke->tailcall_target_stable check) but the address is still not +registered in kallsyms + Parent Hashes: 4b7de801606e504e69689df71475d27e35336fb3 + Refs: so the bpf_arch_text_poke returns -EINVAL +and cause imbalance for the next tail call update check + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test to selftests/bpf for early map update in prog_array_map_poke_run function.', 'keywords': 'test, early update, prog_array_map_poke_run', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4b7de801606e504e69689df71475d27e35336fb3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4b7de801606e504e69689df71475d27e35336fb3 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1701898816 + Commit Message: + bpf: Fix prog_array_map_poke_run map poke update + +Lee pointed out issue found by syscaller [0] hitting BUG in prog array +map poke update in prog_array_map_poke_run function due to error value +returned from bpf_arch_text_poke function. + +There's race window where bpf_arch_text_poke can fail due to missing +bpf program kallsym symbols + Parent Hashes: e4d008d49a7135214e0ee70537405b6a069e3a3f + Refs: which is accounted for with check for +-EINVAL in that BUG_ON call. + +The problem is that in such case we won't update the tail call jump +and cause imbalance for the next tail call update check which will +fail with -EBUSY in bpf_arch_text_poke. + +I'm hitting following race during the program load: + + CPU 0 CPU 1 + + bpf_prog_load + bpf_check + do_misc_fixups + prog_array_map_poke_track + + map_update_elem + bpf_fd_array_map_update_elem + prog_array_map_poke_run + + bpf_arch_text_poke returns -EINVAL + + bpf_prog_kallsyms_add + +After bpf_arch_text_poke (CPU 1) fails to update the tail call jump + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a bug in prog_array_map_poke_run to handle race conditions during bpf_arch_text_poke failures.', 'keywords': 'bug,race condition,update', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c35919dcce2855d68cf45ffa427b8ea78e4f7c68 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c35919dcce2855d68cf45ffa427b8ea78e4f7c68 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1701885781 + Commit Message: + Merge branch 'bpf-token-and-bpf-fs-based-delegation' + +Andrii Nakryiko says: + +==================== +BPF token and BPF FS-based delegation + +This patch set introduces an ability to delegate a subset of BPF subsystem +functionality from privileged system-wide daemon (e.g. + Parent Hashes: 3aee2bf9c49be2144460d7267560232e3d45d367 36fb94944b35062db15ab3059f4123048cac658c + Refs: systemd or any other +container manager) through special mount options for userns-bound BPF FS to +a *trusted* unprivileged application. Trust is the key here. This +functionality is not about allowing unconditional unprivileged BPF usage. +Establishing trust + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit introduces BPF token and BPF FS-based delegation to unprivileged applications via trusted system-wide daemons.', 'keywords': 'BPF token, delegation, unprivileged', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 36fb94944b35062db15ab3059f4123048cac658c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 36fb94944b35062db15ab3059f4123048cac658c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885780 + Commit Message: + bpf + Parent Hashes: dc5196fac40c2cb96330bcb98eef868a7fd225b3 + Refs: selinux: allocate bpf_security_struct per BPF token + +Utilize newly added bpf_token_create/bpf_token_free LSM hooks to +allocate struct bpf_security_struct for each BPF token object in +SELinux. This just follows similar pattern for BPF prog and map. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-18-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Allocate bpf_security_struct for each BPF token in SELinux using new LSM hooks.', 'keywords': 'LSM hooks, BPF token, SELinux', 'commit_classification': "It's a security fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['cgroup like programs', 'LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: dc5196fac40c2cb96330bcb98eef868a7fd225b3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dc5196fac40c2cb96330bcb98eef868a7fd225b3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885780 + Commit Message: + selftests/bpf: add BPF token-enabled tests + +Add a selftest that attempts to conceptually replicate intended BPF +token use cases inside user namespaced container. + +Child process is forked. It is then put into its own userns and mountns. +Child creates BPF FS context object. This ensures child userns is +captured as the owning userns for this instance of BPF FS. Given setting +delegation mount options is privileged operation + Parent Hashes: 1571740a9ba036f26cc5211a86021199987219e8 + Refs: we ensure that child +cannot set them. + +This context is passed back to privileged parent process through Unix +socket + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for BPF token use cases in user namespaced containers.', 'keywords': 'BPF token selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1571740a9ba036f26cc5211a86021199987219e8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1571740a9ba036f26cc5211a86021199987219e8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885780 + Commit Message: + libbpf: add BPF token support to bpf_prog_load() API + +Wire through token_fd into bpf_prog_load(). + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-16-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 1a8df7fa00aac35aff9ef1941c5334b3a01d09e4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add BPF token support to bpf_prog_load API in libbpf.', 'keywords': 'BPF, token, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1a8df7fa00aac35aff9ef1941c5334b3a01d09e4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1a8df7fa00aac35aff9ef1941c5334b3a01d09e4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885780 + Commit Message: + libbpf: add BPF token support to bpf_btf_load() API + +Allow user to specify token_fd for bpf_btf_load() API that wraps +kernel's BPF_BTF_LOAD command. This allows loading BTF from unprivileged +process as long as it has BPF token allowing BPF_BTF_LOAD command + Parent Hashes: 37891cea6699200fb83eae464ebe1c0f73040474 + Refs: which +can be created and delegated by privileged process. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-15-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support for BPF token in bpf_btf_load() API to allow BTF loading from unprivileged processes.', 'keywords': 'BPF token,BTF loading,unprivileged', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 37891cea6699200fb83eae464ebe1c0f73040474 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 37891cea6699200fb83eae464ebe1c0f73040474 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885780 + Commit Message: + libbpf: add BPF token support to bpf_map_create() API + +Add ability to provide token_fd for BPF_MAP_CREATE command through +bpf_map_create() API. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-14-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: ecd435143eb03611e25694141bf59d1c04ad5b9e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add BPF token support to the bpf_map_create() API in libbpf.', 'keywords': 'BPF, token, libbpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ecd435143eb03611e25694141bf59d1c04ad5b9e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ecd435143eb03611e25694141bf59d1c04ad5b9e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885780 + Commit Message: + libbpf: add bpf_token_create() API + +Add low-level wrapper API for BPF_TOKEN_CREATE command in bpf() syscall. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-13-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d734ca7b33dbf60eb15dcf7c44f3da7073356777 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces a new API bpf_token_create() for BPF_TOKEN_CREATE command in the bpf() syscall.', 'keywords': 'API, bpf_token_create, syscall', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d734ca7b33dbf60eb15dcf7c44f3da7073356777 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d734ca7b33dbf60eb15dcf7c44f3da7073356777 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885780 + Commit Message: + bpf + Parent Hashes: 66d636d70a79c1d37e3eea67ab50969e6aaef983 + Refs: lsm: add BPF token LSM hooks + +Wire up bpf_token_create and bpf_token_free LSM hooks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added LSM hooks for BPF token creation and deletion in the BPF subsystem.', 'keywords': 'LSM hooks, BPF token, creation', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: 66d636d70a79c1d37e3eea67ab50969e6aaef983 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 66d636d70a79c1d37e3eea67ab50969e6aaef983 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885779 + Commit Message: + bpf + Parent Hashes: c3dd6e94df7193f33f45d33303f5e85afb2a72dc + Refs: lsm: refactor bpf_map_alloc/bpf_map_free LSM hooks + +Similarly to bpf_prog_alloc LSM hook + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor the bpf_map_alloc and bpf_map_free LSM hooks.', 'keywords': 'refactor, LSM hooks, bpf_map', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: c3dd6e94df7193f33f45d33303f5e85afb2a72dc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c3dd6e94df7193f33f45d33303f5e85afb2a72dc + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885779 + Commit Message: + bpf + Parent Hashes: 8062fb12de99b2da33754c6a3be1bfc30d9a35f4 + Refs: lsm: refactor bpf_prog_alloc/bpf_prog_free LSM hooks + +Based on upstream discussion ([0]) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor Linux Security Module (LSM) hooks for bpf_prog_alloc and bpf_prog_free functions.', 'keywords': 'refactor,LSM hooks,bpf_prog_alloc', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: 8062fb12de99b2da33754c6a3be1bfc30d9a35f4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8062fb12de99b2da33754c6a3be1bfc30d9a35f4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885779 + Commit Message: + bpf: consistently use BPF token throughout BPF verifier logic + +Remove remaining direct queries to perfmon_capable() and bpf_capable() +in BPF verifier logic and instead use BPF token (if available) to make +decisions about privileges. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 4cbb270e115bc197ff2046aeb54cc951666b16ec + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates the BPF verifier logic to consistently use BPF token instead of direct capability checks.', 'keywords': 'BPF verifier,BPF token,privileges', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4cbb270e115bc197ff2046aeb54cc951666b16ec +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4cbb270e115bc197ff2046aeb54cc951666b16ec + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885779 + Commit Message: + bpf: take into account BPF token when fetching helper protos + +Instead of performing unconditional system-wide bpf_capable() and +perfmon_capable() calls inside bpf_base_func_proto() function (and other +similar ones) to determine eligibility of a given BPF helper for a given +program + Parent Hashes: e1cef620f598853a90f17701fcb1057a6768f7b8 + Refs: use previously recorded BPF token during BPF_PROG_LOAD command +handling to inform the decision. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-8-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit optimizes BPF helper protos fetching by using recorded BPF token rather than system-wide capability checks.', 'keywords': 'BPF token, helper protos, bpf_capable', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e1cef620f598853a90f17701fcb1057a6768f7b8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e1cef620f598853a90f17701fcb1057a6768f7b8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885779 + Commit Message: + bpf: add BPF token support to BPF_PROG_LOAD command + +Add basic support of BPF token to BPF_PROG_LOAD. Wire through a set of +allowed BPF program types and attach types + Parent Hashes: ee54b1a910e4d49c9a104f31ae3f5b979131adf8 + Refs: derived from BPF FS at BPF +token creation time. Then make sure we perform bpf_token_capable() +checks everywhere where it's relevant. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-7-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add BPF token support to the BPF_PROG_LOAD command, allowing specific BPF program types and attach types.', 'keywords': 'BPF token,BPF_PROG_LOAD,support', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ee54b1a910e4d49c9a104f31ae3f5b979131adf8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ee54b1a910e4d49c9a104f31ae3f5b979131adf8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885779 + Commit Message: + bpf: add BPF token support to BPF_BTF_LOAD command + +Accept BPF token FD in BPF_BTF_LOAD command to allow BTF data loading +through delegated BPF token. BTF loading is a pretty straightforward +operation + Parent Hashes: 688b7270b3cb75e8ac78123d719967db40336e5b + Refs: so as long as BPF token is created with allow_cmds granting +BPF_BTF_LOAD command + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added BPF token support to the BPF_BTF_LOAD command for delegated BTF data loading.', 'keywords': 'BPF token, BPF_BTF_LOAD, BTF data', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 688b7270b3cb75e8ac78123d719967db40336e5b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 688b7270b3cb75e8ac78123d719967db40336e5b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885779 + Commit Message: + bpf: add BPF token support to BPF_MAP_CREATE command + +Allow providing token_fd for BPF_MAP_CREATE command to allow controlled +BPF map creation from unprivileged process through delegated BPF token. + +Wire through a set of allowed BPF map types to BPF token + Parent Hashes: 4527358b76861dfd64ee34aba45d81648fbc8a61 + Refs: derived from +BPF FS at BPF token creation time. This + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce BPF token support for controlled map creation by unprivileged processes using BPF_MAP_CREATE command.', 'keywords': 'BPF token support, map creation, unprivileged process', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['cgroup like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4527358b76861dfd64ee34aba45d81648fbc8a61 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4527358b76861dfd64ee34aba45d81648fbc8a61 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885779 + Commit Message: + bpf: introduce BPF token object + +Add new kind of BPF kernel object + Parent Hashes: 40bba140c60fbb3ee8df6203c82fbd3de9f19d95 + Refs: BPF token. BPF token is meant to +allow delegating privileged BPF functionality + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce BPF token object for delegating privileged BPF functionality.', 'keywords': 'BPF,token,delegating', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's an experimental feature that doesn't fit into existing categories."]} +-------------------- +-------------------- +Processing Commit ID: 40bba140c60fbb3ee8df6203c82fbd3de9f19d95 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 40bba140c60fbb3ee8df6203c82fbd3de9f19d95 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885778 + Commit Message: + bpf: add BPF token delegation mount options to BPF FS + +Add few new mount options to BPF FS that allow to specify that a given +BPF FS instance allows creation of BPF token (added in the next patch) + Parent Hashes: 909fa05dd3c181e5b403912889057f7cdbf3906c + Refs: +and what sort of operations are allowed under BPF token. As such + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new mount options to BPF FS for BPF token delegation.', 'keywords': 'BPF token, mount options, delegation', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 909fa05dd3c181e5b403912889057f7cdbf3906c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 909fa05dd3c181e5b403912889057f7cdbf3906c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701885778 + Commit Message: + bpf: align CAP_NET_ADMIN checks with bpf_capable() approach + +Within BPF syscall handling code CAP_NET_ADMIN checks stand out a bit +compared to CAP_BPF and CAP_PERFMON checks. For the latter + Parent Hashes: 3aee2bf9c49be2144460d7267560232e3d45d367 + Refs: CAP_BPF or +CAP_PERFMON are checked first + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Align CAP_NET_ADMIN checks with bpf_capable() approach in BPF syscall handling.', 'keywords': 'CAP_NET_ADMIN,bpf_capable,BPF', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1834d62ae88500f37cba4439c3237aa85242272e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1834d62ae88500f37cba4439c3237aa85242272e + Author Name: D. Wythe + Author Email: alibuda@linux.alibaba.com + Commit Date: 1701879266 + Commit Message: + netfilter: bpf: fix bad registration on nf_defrag + +We should pass a pointer to global_hook to the get_proto_defrag_hook() +instead of its value + Parent Hashes: 54d4434da824460a190d547404530eff12a7907d + Refs: since the passed value won't be updated even if +the request module was loaded successfully. + +Log: + +[ 54.915713] nf_defrag_ipv4 has bad registration +[ 54.915779] WARNING: CPU: 3 PID: 6323 at net/netfilter/nf_bpf_link.c:62 get_proto_defrag_hook+0x137/0x160 +[ 54.915835] CPU: 3 PID: 6323 Comm: fentry Kdump: loaded Tainted: G E 6.7.0-rc2+ #35 +[ 54.915839] Hardware name: QEMU Standard PC (i440FX + PIIX + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix bad registration in nf_defrag by passing a pointer to global_hook in netfilter BPF.', 'keywords': 'netfilter, registration, nf_defrag', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 3aee2bf9c49be2144460d7267560232e3d45d367 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3aee2bf9c49be2144460d7267560232e3d45d367 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1701812494 + Commit Message: + Merge branch 'complete-bpf-verifier-precision-tracking-support-for-register-spills' + +Andrii Nakryiko says: + +==================== +Complete BPF verifier precision tracking support for register spills + +Add support to BPF verifier to track and support register spill/fill to/from +stack regardless if it was done through read-only R10 register (which is the +only form supported today) + Parent Hashes: 5ffb260f754bf838507fe0c23d05254b33e2bf3d 064e0bea19b356c5d5f48a4549d80a3c03ce898b + Refs: or through a general register after copying R10 +into it + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhances BPF verifier with precision tracking for register spills and fills to/from stack.', 'keywords': 'verifier, precision, register', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 064e0bea19b356c5d5f48a4549d80a3c03ce898b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 064e0bea19b356c5d5f48a4549d80a3c03ce898b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812421 + Commit Message: + selftests/bpf: validate precision logic in partial_stack_load_preserves_zeros + +Enhance partial_stack_load_preserves_zeros subtest with detailed +precision propagation log checks. We know expect fp-16 to be spilled + Parent Hashes: 18a433b62061e3d787bfc3e670fa711fecbd7cb4 + Refs: +initially imprecise + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance BPF self-tests with precision propagation checks for partial stack load operations.', 'keywords': 'selftests, precision, stack', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 18a433b62061e3d787bfc3e670fa711fecbd7cb4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 18a433b62061e3d787bfc3e670fa711fecbd7cb4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812421 + Commit Message: + bpf: track aligned STACK_ZERO cases as imprecise spilled registers + +Now that precision backtracing is supporting register spill/fill to/from +stack + Parent Hashes: add1cd7f22e61756987865ada9fe95cd86569025 + Refs: there is another oportunity to be exploited here: minimizing +precise STACK_ZERO cases. With a simple code change we can rely on +initially imprecise register spill tracking for cases when register +spilled to stack was a known zero. + +This is a very common case for initializing on the stack variables + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances register spill tracking for STACK_ZERO cases as imprecise spilled registers in eBPF.', 'keywords': 'aligned, STACK_ZERO, registers', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: add1cd7f22e61756987865ada9fe95cd86569025 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: add1cd7f22e61756987865ada9fe95cd86569025 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812421 + Commit Message: + selftests/bpf: validate zero preservation for sub-slot loads + +Validate that 1- + Parent Hashes: e322f0bcb8d371f4606eaf141c7f967e1a79bcb7 + Refs: 2- + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for validating zero preservation for sub-slot loads in eBPF.', 'keywords': 'selftests,zero preservation,sub-slot loads', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e322f0bcb8d371f4606eaf141c7f967e1a79bcb7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e322f0bcb8d371f4606eaf141c7f967e1a79bcb7 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812421 + Commit Message: + bpf: preserve constant zero when doing partial register restore + +Similar to special handling of STACK_ZERO + Parent Hashes: b33ceb6a3d2ee07fdd836373383a6d4783581324 + Refs: when reading 1/2/4 bytes from +stack from slot that has register spilled into it and that register has +a constant value zero + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit ensures that constant zero values are maintained during partial register restorations in the eBPF verifier.', 'keywords': 'constant, register, restore', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b33ceb6a3d2ee07fdd836373383a6d4783581324 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b33ceb6a3d2ee07fdd836373383a6d4783581324 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812420 + Commit Message: + selftests/bpf: validate STACK_ZERO is preserved on subreg spill + +Add tests validating that STACK_ZERO slots are preserved when slot is +partially overwritten with subregister spill. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231205184248.1502704-6-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: eaf18febd6ebc381aeb61543705148b3e28c7c47 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added tests to validate STACK_ZERO preservation on subregister spill in bpf selftests.', 'keywords': 'STACK_ZERO, subregister, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: eaf18febd6ebc381aeb61543705148b3e28c7c47 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: eaf18febd6ebc381aeb61543705148b3e28c7c47 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812420 + Commit Message: + bpf: preserve STACK_ZERO slots on partial reg spills + +Instead of always forcing STACK_ZERO slots to STACK_MISC + Parent Hashes: ab125ed3ec1c10ccc36bc98c7a4256ad114a3dae + Refs: preserve it in +situations where this is possible. E.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit preserves STACK_ZERO slots during partial register spills in the eBPF verifier.', 'keywords': 'STACK_ZERO,register spills,verifier', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ab125ed3ec1c10ccc36bc98c7a4256ad114a3dae +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ab125ed3ec1c10ccc36bc98c7a4256ad114a3dae + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812420 + Commit Message: + bpf: fix check for attempt to corrupt spilled pointer + +When register is spilled onto a stack as a 1/2/4-byte register + Parent Hashes: 876301881c436bf38e83a2c0d276a24b642e4aab + Refs: we set +slot_type[BPF_REG_SIZE - 1] (plus potentially few more below it + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a check for attempts to corrupt spilled pointers in the eBPF verifier.', 'keywords': 'fix,corrupt,pointer', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 876301881c436bf38e83a2c0d276a24b642e4aab +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 876301881c436bf38e83a2c0d276a24b642e4aab + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812420 + Commit Message: + selftests/bpf: add stack access precision test + +Add a new selftests that validates precision tracking for stack access +instruction + Parent Hashes: 41f6f64e6999a837048b1bd13a2f8742964eca6b + Refs: using both r10-based and non-r10-based accesses. For +non-r10 ones we also make sure to have non-zero var_off to validate that +final stack offset is tracked properly in instruction history +information inside verifier. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231205184248.1502704-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest to validate precision tracking for stack access instructions in bpf verifier.', 'keywords': 'selftest, stack access, precision', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 41f6f64e6999a837048b1bd13a2f8742964eca6b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 41f6f64e6999a837048b1bd13a2f8742964eca6b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701812420 + Commit Message: + bpf: support non-r10 register spill/fill to/from stack in precision tracking + +Use instruction (jump) history to record instructions that performed +register spill/fill to/from stack + Parent Hashes: 5ffb260f754bf838507fe0c23d05254b33e2bf3d + Refs: regardless if this was done through +read-only r10 register + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for non-r10 register spill/fill in precision tracking for bpf.', 'keywords': 'register, spill, precision', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5ffb260f754bf838507fe0c23d05254b33e2bf3d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5ffb260f754bf838507fe0c23d05254b33e2bf3d + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1701785484 + Commit Message: + selftests/bpf: Make sure we trigger metadata kfuncs for dst 8080 + +xdp_metadata test is flaky sometimes: + + verify_xsk_metadata:FAIL:rx_hash_type unexpected rx_hash_type: actual 8 != expected 0 + +Where 8 means XDP_RSS_TYPE_L4_ANY and is exported from veth driver only when +'skb->l4_hash' condition is met. This makes me think that the program is +triggering again for some other packet. + +Let's have a filter + Parent Hashes: 5c399ae080ae507954f6f2efefc7349f8ed0e051 + Refs: similar to xdp_hw_metadata + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix flaky xdp_metadata test by ensuring kfuncs are triggered for destination port 8080.', 'keywords': 'xdp_metadata,test,kfuncs', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 5c399ae080ae507954f6f2efefc7349f8ed0e051 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5c399ae080ae507954f6f2efefc7349f8ed0e051 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1701785330 + Commit Message: + xsk: Add missing SPDX to AF_XDP TX metadata documentation + +Not sure how I missed that. I even acknowledged it explicitly +in the changelog [0]. Add the tag for real now. + + [0] https://lore.kernel.org/bpf/20231127190319.1190813-1-sdf@google.com/ + +Fixes: 11614723af26 ("xsk: Add option to calculate TX checksum in SW") +Suggested-by: Simon Horman +Signed-off-by: Stanislav Fomichev +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231204174231.3457705-1-sdf@google.com + + Parent Hashes: 1b4c7e20bfd6cfe0efbc51756d930a9406d41ea7 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added missing SPDX license tag to AF_XDP TX metadata documentation.', 'keywords': 'SPDX, AF_XDP, documentation', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 1b4c7e20bfd6cfe0efbc51756d930a9406d41ea7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1b4c7e20bfd6cfe0efbc51756d930a9406d41ea7 + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1701785207 + Commit Message: + selftests/bpf: Test bpf_kptr_xchg stashing of bpf_rb_root + +There was some confusion amongst Meta sched_ext folks regarding whether +stashing bpf_rb_root - the tree itself + Parent Hashes: ce3c49da11d77aa7d53cd549d308eb5f7fed8576 + Refs: rather than a single node - was +supported. This patch adds a small test which demonstrates this +functionality: a local kptr with rb_root is created + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a test for stashing bpf_rb_root in bpf_kptr_xchg.', 'keywords': 'bpf_rb_root,test,stashing', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e4d008d49a7135214e0ee70537405b6a069e3a3f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e4d008d49a7135214e0ee70537405b6a069e3a3f + Author Name: Yewon Choi + Author Email: woni9911@gmail.com + Commit Date: 1701780223 + Commit Message: + xsk: Skip polling event check for unbound socket + +In xsk_poll() + Parent Hashes: dfce9cb3140592b886838e06f3e0c25fea2a9cae + Refs: checking available events and setting mask bits should +be executed only when a socket has been bound. Setting mask bits for +unbound socket is meaningless. + +Currently + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit optimizes xsk_poll by skipping polling for unbound sockets.', 'keywords': 'xsk, polling, sockets', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: a931c6816078af3e306e0f444f492396ce40de31 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a931c6816078af3e306e0f444f492396ce40de31 + Author Name: JP Kobryn + Author Email: inwardvessel@gmail.com + Commit Date: 1701778724 + Commit Message: + 9p: prevent read overrun in protocol dump tracepoint + +An out of bounds read can occur within the tracepoint 9p_protocol_dump. In +the fast assign + Parent Hashes: 2cc14f52aeb78ce3f29677c2de1f06c0e91471ab + Refs: there is a memcpy that uses a constant size of 32 (macro +named P9_PROTO_DUMP_SZ). When the copy is invoked + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit prevents an out of bounds read in the 9p_protocol_dump tracepoint.', 'keywords': 'read overrun, tracepoint, 9p_protocol_dump', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: ce3c49da11d77aa7d53cd549d308eb5f7fed8576 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ce3c49da11d77aa7d53cd549d308eb5f7fed8576 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1701741027 + Commit Message: + Merge branch 'bpf-fix-the-release-of-inner-map' + +Hou Tao says: + +==================== +bpf: Fix the release of inner map + +From: Hou Tao + +Hi + Parent Hashes: 153de60e8bfb4501e1462a2f74cb787c137b996c e3dd40828534a67931e0dd00fcd35846271fd4e8 + Refs: + +The patchset aims to fix the release of inner map in map array or map +htab. The release of inner map is different with normal map. For normal +map + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix the release mechanism for inner maps within map arrays and hash tables in eBPF.', 'keywords': 'release,inner map,fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e3dd40828534a67931e0dd00fcd35846271fd4e8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e3dd40828534a67931e0dd00fcd35846271fd4e8 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1701741027 + Commit Message: + selftests/bpf: Test outer map update operations in syscall program + +Syscall program is running with rcu_read_lock_trace being held + Parent Hashes: 1624918be84a8bcc4f592e55635bc4fe4a96460a + Refs: so if +bpf_map_update_elem() or bpf_map_delete_elem() invokes +synchronize_rcu_tasks_trace() when operating on an outer map + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit tests outer map update operations in syscall programs under rcu_read_lock_trace conditions.', 'keywords': 'outer map update, syscall program, rcu_read_lock_trace', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1624918be84a8bcc4f592e55635bc4fe4a96460a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1624918be84a8bcc4f592e55635bc4fe4a96460a + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1701741027 + Commit Message: + selftests/bpf: Add test cases for inner map + +Add test cases to test the race between the destroy of inner map due to +map-in-map update and the access of inner map in bpf program. The +following 4 combinations are added: +(1) array map in map array + bpf program +(2) array map in map array + sleepable bpf program +(3) array map in map htab + bpf program +(4) array map in map htab + sleepable bpf program + +Before applying the fixes + Parent Hashes: af66bfd3c8538ed21cf72af18426fc4a408665cf + Refs: when running `./test_prog -a map_in_map` + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test cases to evaluate race conditions in inner map handling with map-in-map updates in bpf programs.', 'keywords': 'test cases, inner map, race', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: af66bfd3c8538ed21cf72af18426fc4a408665cf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: af66bfd3c8538ed21cf72af18426fc4a408665cf + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1701741026 + Commit Message: + bpf: Optimize the free of inner map + +When removing the inner map from the outer map + Parent Hashes: 876673364161da50eed6b472d746ef88242b2368 + Refs: the inner map will be +freed after one RCU grace period and one RCU tasks trace grace +period + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit optimizes the deallocation process for inner maps in eBPF by using RCU grace periods.', 'keywords': 'optimize, inner map, RCU', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 876673364161da50eed6b472d746ef88242b2368 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 876673364161da50eed6b472d746ef88242b2368 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1701741026 + Commit Message: + bpf: Defer the free of inner map when necessary + +When updating or deleting an inner map in map array or map htab + Parent Hashes: 79d93b3c6ffd79abcd8e43345980aa1e904879c4 + Refs: the map +may still be accessed by non-sleepable program or sleepable program. +However bpf_map_fd_put_ptr() decreases the ref-counter of the inner map +directly through bpf_map_put() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Defer free of inner map to ensure safe access by non-sleepable or sleepable programs.', 'keywords': 'defer, free, map', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 79d93b3c6ffd79abcd8e43345980aa1e904879c4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 79d93b3c6ffd79abcd8e43345980aa1e904879c4 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1701741026 + Commit Message: + bpf: Set need_defer as false when clearing fd array during map free + +Both map deletion operation + Parent Hashes: 20c20bd11a0702ce4dc9300c3da58acf551d9725 + Refs: map release and map free operation use +fd_array_map_delete_elem() to remove the element from fd array and +need_defer is always true in fd_array_map_delete_elem(). For the map +deletion operation and map release operation + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Set need_defer as false when clearing fd array during map deletion in eBPF.', 'keywords': 'need_defer,fd_array,map_deletion', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 20c20bd11a0702ce4dc9300c3da58acf551d9725 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 20c20bd11a0702ce4dc9300c3da58acf551d9725 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1701741026 + Commit Message: + bpf: Add map and need_defer parameters to .map_fd_put_ptr() + +map is the pointer of outer map + Parent Hashes: 169410eba271afc9f0fb476d996795aa26770c6d + Refs: and need_defer needs some explanation. +need_defer tells the implementation to defer the reference release of +the passed element and ensure that the element is still alive before +the bpf program + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add map and need_defer parameters to .map_fd_put_ptr() to manage reference release in BPF programs.', 'keywords': 'map, need_defer, reference', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 169410eba271afc9f0fb476d996795aa26770c6d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 169410eba271afc9f0fb476d996795aa26770c6d + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1701741026 + Commit Message: + bpf: Check rcu_read_lock_trace_held() before calling bpf map helpers + +These three bpf_map_{lookup + Parent Hashes: 153de60e8bfb4501e1462a2f74cb787c137b996c + Refs: update + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add checks for RCU read lock before calling BPF map helpers to ensure safety.', 'keywords': 'RCU, lock, helper', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 153de60e8bfb4501e1462a2f74cb787c137b996c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 153de60e8bfb4501e1462a2f74cb787c137b996c + Author Name: Colin Ian King + Author Email: colin.i.king@gmail.com + Commit Date: 1701701982 + Commit Message: + selftests/bpf: Fix spelling mistake "get_signaure_size" -> "get_signature_size" + +There is a spelling mistake in an ASSERT_GT message. Fix it. + +Signed-off-by: Colin Ian King +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231204093940.2611954-1-colin.i.king@gmail.com + + Parent Hashes: 5bd90cdc65ef9ef5e13c9ff23620079db5c608a0 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed spelling mistake in selftests related to signature size assertion.', 'keywords': 'spelling, selftests, bpf', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 5bd90cdc65ef9ef5e13c9ff23620079db5c608a0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5bd90cdc65ef9ef5e13c9ff23620079db5c608a0 + Author Name: Andrei Matei + Author Email: andreimatei1@gmail.com + Commit Date: 1701701847 + Commit Message: + bpf: Minor logging improvement + +One place where we were logging a register was only logging the variable +part + Parent Hashes: 90679706d486d3cb202d1b377a230f1f22edaf00 + Refs: not also the fixed part. + +Signed-off-by: Andrei Matei +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231204011248.2040084-1-andreimatei1@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves logging by including both variable and fixed parts of a register.', 'keywords': 'logging, register, improvement', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 90679706d486d3cb202d1b377a230f1f22edaf00 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 90679706d486d3cb202d1b377a230f1f22edaf00 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1701545811 + Commit Message: + Merge branch 'bpf-verifier-retval-logic-fixes' + +Andrii Nakryiko says: + +==================== +BPF verifier retval logic fixes + +This patch set fixes BPF verifier logic around validating and enforcing return +values for BPF programs that have specific range of expected return values. +Both sync and async callbacks have similar logic and are fixes as well. +A few tests are added that would fail without the fixes in this patch set. + +Also + Parent Hashes: 6685aadcab8f170ae3e4d508989a85c1b8a58dba 81eff2e36481c5cf4a2ac906ae56c3fbd3e6f305 + Refs: while at it + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit addresses logic fixes for BPF verifier return value validation and enforcement, including tests.', 'keywords': 'BPF, verifier, fixes', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 81eff2e36481c5cf4a2ac906ae56c3fbd3e6f305 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 81eff2e36481c5cf4a2ac906ae56c3fbd3e6f305 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545811 + Commit Message: + bpf: simplify tnum output if a fully known constant + +Emit tnum representation as just a constant if all bits are known. +Use decimal-vs-hex logic to determine exact format of emitted +constant value + Parent Hashes: 5c19e1d05e9e71b42d8e779f41959254239709da + Refs: just like it's done for register range values. +For that move tnum_strn() to kernel/bpf/log.c to reuse decimal-vs-hex +determination logic and constants. + +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-12-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Simplify tnum output to emit constants directly if all bits are known.', 'keywords': 'tnum,constant,output', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5c19e1d05e9e71b42d8e779f41959254239709da +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5c19e1d05e9e71b42d8e779f41959254239709da + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545811 + Commit Message: + selftests/bpf: adjust global_func15 test to validate prog exit precision + +Add one more subtest to global_func15 selftest to validate that +verifier properly marks r0 as precise and avoids erroneous state pruning +of the branch that has return value outside of expected [0 + Parent Hashes: e02dea158ddaebe6e725be715e0009923b96ec8e + Refs: 1] value. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-11-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a subtest to global_func15 selftest for verifying exit precision in the eBPF verifier.', 'keywords': 'selftest, verifier, precision', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e02dea158ddaebe6e725be715e0009923b96ec8e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e02dea158ddaebe6e725be715e0009923b96ec8e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545811 + Commit Message: + selftests/bpf: validate async callback return value check correctness + +Adjust timer/timer_ret_1 test to validate more carefully verifier logic +of enforcing async callback return value. This test will pass only if +return result is marked precise and read. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-10-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: eabe518de533a4291996020977054a7a7b78c7d3 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improves selftests/bpf by validating correctness of async callback return value checks.', 'keywords': 'selftests,bpf,async', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: eabe518de533a4291996020977054a7a7b78c7d3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: eabe518de533a4291996020977054a7a7b78c7d3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545811 + Commit Message: + bpf: enforce precision of R0 on program/async callback return + +Given we enforce a valid range for program and async callback return +value + Parent Hashes: 0ef24c8dfae24a4b8aa2e92eac20faecdc5502e5 + Refs: we must mark R0 as precise to avoid incorrect state pruning. + +Fixes: b5dc0163d8fd ("bpf: precise scalar_value tracking") +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enforces precision of R0 for program and async callback return values to prevent incorrect state pruning.', 'keywords': 'precision,R0,return', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0ef24c8dfae24a4b8aa2e92eac20faecdc5502e5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0ef24c8dfae24a4b8aa2e92eac20faecdc5502e5 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545810 + Commit Message: + bpf: unify async callback and program retval checks + +Use common logic to verify program return values and async callback +return values. This allows to avoid duplication of any extra steps +necessary + Parent Hashes: c871d0e00f0e8c207ce8ff89025e35cc49a8a3c3 + Refs: like precision marking + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit unifies the logic for verifying program return values and async callback return values in bpf.', 'keywords': 'async,callback,retval', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c871d0e00f0e8c207ce8ff89025e35cc49a8a3c3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c871d0e00f0e8c207ce8ff89025e35cc49a8a3c3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545810 + Commit Message: + bpf: enforce precise retval range on program exit + +Similarly to subprog/callback logic + Parent Hashes: 60a6b2c78c62d0a99ccb7ad5edc950f79e56306a + Refs: enforce return value of BPF program +using more precise smin/smax range. + +We need to adjust a bunch of tests due to a changed format of an error +message. + +Acked-by: Eduard Zingerman +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-7-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enforces precise return value ranges for BPF program exits, requiring test adjustments.', 'keywords': 'precise, retval, tests', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 60a6b2c78c62d0a99ccb7ad5edc950f79e56306a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 60a6b2c78c62d0a99ccb7ad5edc950f79e56306a + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545810 + Commit Message: + selftests/bpf: add selftest validating callback result is enforced + +BPF verifier expects callback subprogs to return values from specified +range (typically [0 + Parent Hashes: 8fa4ecd49b81ccd9d1d87f1c8b2260e218644878 + Refs: 1]). This requires that r0 at exit is both precise +(because we rely on specific value range) and is marked as read +(otherwise state comparison will ignore such register as unimportant). + +Add a simple test that validates that all these conditions are enforced. + +Acked-by: Eduard Zingerman +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-6-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a selftest for validating callback result enforcement in BPF verifier.', 'keywords': 'selftest, callback, verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8fa4ecd49b81ccd9d1d87f1c8b2260e218644878 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8fa4ecd49b81ccd9d1d87f1c8b2260e218644878 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545810 + Commit Message: + bpf: enforce exact retval range on subprog/callback exit + +Instead of relying on potentially imprecise tnum representation of +expected return value range for callbacks and subprogs + Parent Hashes: 0acd03a5bd188b0c501d285d938439618bd855c4 + Refs: validate that +smin/smax range satisfy exact expected range of return values. + +E.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enforces exact return value range verification for subprograms and callbacks in BPF.', 'keywords': 'retval,subprog,callbacks', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0acd03a5bd188b0c501d285d938439618bd855c4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0acd03a5bd188b0c501d285d938439618bd855c4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545810 + Commit Message: + bpf: enforce precision of R0 on callback return + +Given verifier checks actual value + Parent Hashes: 5fad52bee30414270104525e3a0266327a6e9d11 + Refs: r0 has to be precise + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enforces precision checks on the return value of R0 in callbacks within the eBPF verifier.', 'keywords': 'precision,R0,verifier', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5fad52bee30414270104525e3a0266327a6e9d11 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5fad52bee30414270104525e3a0266327a6e9d11 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545810 + Commit Message: + bpf: provide correct register name for exception callback retval check + +bpf_throw() is checking R1 + Parent Hashes: 45b5623f2d721c25d1a2fdc8c4600fb4b7b61c75 + Refs: so let's report R1 in the log. + +Acked-by: Eduard Zingerman +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix incorrect register name reported in bpf_throw() exception callback log.', 'keywords': 'register, exception, bpf_throw', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 45b5623f2d721c25d1a2fdc8c4600fb4b7b61c75 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 45b5623f2d721c25d1a2fdc8c4600fb4b7b61c75 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701545810 + Commit Message: + bpf: rearrange bpf_func_state fields to save a bit of memory + +It's a trivial rearrangement saving 8 bytes. We have 4 bytes of padding +at the end which can be filled with another field without increasing +struct bpf_func_state. + +copy_func_state() logic remains correct without any further changes. + +BEFORE +====== +struct bpf_func_state { + struct bpf_reg_state regs[11]; /* 0 1320 */ + /* --- cacheline 20 boundary (1280 bytes) was 40 bytes ago --- */ + int callsite; /* 1320 4 */ + u32 frameno; /* 1324 4 */ + u32 subprogno; /* 1328 4 */ + u32 async_entry_cnt; /* 1332 4 */ + bool in_callback_fn; /* 1336 1 */ + + /* XXX 7 bytes hole + Parent Hashes: 6685aadcab8f170ae3e4d508989a85c1b8a58dba + Refs: try to pack */ + + /* --- cacheline 21 boundary (1344 bytes) --- */ + struct tnum callback_ret_range; /* 1344 16 */ + bool in_async_callback_fn; /* 1360 1 */ + bool in_exception_callback_fn; /* 1361 1 */ + + /* XXX 2 bytes hole + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Rearrange fields in struct bpf_func_state to optimize memory usage by eliminating padding.', 'keywords': 'rearrange,memory,optimization', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6685aadcab8f170ae3e4d508989a85c1b8a58dba +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6685aadcab8f170ae3e4d508989a85c1b8a58dba + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1701476463 + Commit Message: + Merge branch 'bpf-file-verification-with-lsm-and-fsverity' + +Song Liu says: + +==================== +bpf: File verification with LSM and fsverity + +Changes v14 => v15: +1. Fix selftest build without CONFIG_FS_VERITY. (Alexei) +2. Add Acked-by from KP. + +Changes v13 => v14: +1. Add "static" for bpf_fs_kfunc_set. +2. Add Acked-by from Christian Brauner. + +Changes v12 => v13: +1. Only keep 4/9 through 9/9 of v12 + Parent Hashes: b6a3451e0847d5d70fb5fa2b2a80ab9f80bf2c7b 1030e9154258b54e3c7dc07c39e7b6dcf24bc3d2 + Refs: as the first 3 patches already + applied; +2. Use new macro __bpf_kfunc_[start|end]_defs(). + +Changes v11 => v12: +1. Fix typo (data_ptr => sig_ptr) in bpf_get_file_xattr(). + +Changes v10 => v11: +1. Let __bpf_dynptr_data() return const void *. (Andrii) +2. Optimize code to reuse output from __bpf_dynptr_size(). (Andrii) +3. Add __diag_ignore_all("-Wmissing-declarations") for kfunc definition. +4. Fix an off indentation. (Andrii) + +Changes v9 => v10: +1. Remove WARN_ON_ONCE() from check_reg_const_str. (Alexei) + +Changes v8 => v9: +1. Fix test_progs kfunc_dynptr_param/dynptr_data_null. + +Changes v7 => v8: +1. Do not use bpf_dynptr_slice* in the kernel. Add __bpf_dynptr_data* and + use them in ther kernel. (Andrii) + +Changes v6 => v7: +1. Change "__const_str" annotation to "__str". (Alexei + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Integrate file verification using LSM and fsverity in the BPF subsystem, with multiple incremental fixes and optimizations.', 'keywords': 'file verification, LSM, fsverity', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1030e9154258b54e3c7dc07c39e7b6dcf24bc3d2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1030e9154258b54e3c7dc07c39e7b6dcf24bc3d2 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701476463 + Commit Message: + selftests/bpf: Add test that uses fsverity and xattr to sign a file + +This selftests shows a proof of concept method to use BPF LSM to enforce +file signature. This test is added to verify_pkcs7_sig + Parent Hashes: 341f06fdddf72cd60a10945152f69f0f1d614519 + Refs: so that some +existing logic can be reused. + +This file signature method uses fsverity + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest to demonstrate using BPF LSM for file signature enforcement with fsverity and xattr.', 'keywords': 'selftests,BPF LSM,fsverity', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: 341f06fdddf72cd60a10945152f69f0f1d614519 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 341f06fdddf72cd60a10945152f69f0f1d614519 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701476463 + Commit Message: + selftests/bpf: Add tests for filesystem kfuncs + +Add selftests for two new filesystem kfuncs: + 1. bpf_get_file_xattr + 2. bpf_get_fsverity_digest + +These tests simply make sure the two kfuncs work. Another selftest will be +added to demonstrate how to use these kfuncs to verify file signature. + +CONFIG_FS_VERITY is added to selftests config. However + Parent Hashes: 6b0ae4566aba566a2ab4a2de9c59ab3d7f4b43c2 + Refs: this is not +sufficient to guarantee bpf_get_fsverity_digest works. This is because +fsverity need to be enabled at file system level (for example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for two new filesystem kfuncs: bpf_get_file_xattr and bpf_get_fsverity_digest.', 'keywords': 'selftests,kfuncs,filesystem', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 6b0ae4566aba566a2ab4a2de9c59ab3d7f4b43c2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6b0ae4566aba566a2ab4a2de9c59ab3d7f4b43c2 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701476463 + Commit Message: + selftests/bpf: Sort config in alphabetic order + +Move CONFIG_VSOCKETS up + Parent Hashes: 0de267d9ec6574536ec5ea2f2242df5c92bcdd4b + Refs: so the CONFIGs are in alphabetic order. + +Signed-off-by: Song Liu +Link: https://lore.kernel.org/r/20231129234417.856536-5-song@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit sorts the selftests/bpf configuration in alphabetical order by moving CONFIG_VSOCKETS up.', 'keywords': 'selftests, configuration, alphabetic', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 0de267d9ec6574536ec5ea2f2242df5c92bcdd4b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0de267d9ec6574536ec5ea2f2242df5c92bcdd4b + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701476463 + Commit Message: + Documentation/bpf: Add documentation for filesystem kfuncs + +Add a brief introduction for file system kfuncs: + + bpf_get_file_xattr() + bpf_get_fsverity_digest() + +The documentation highlights the strategy to avoid recursions of these +kfuncs. + +Signed-off-by: Song Liu +Link: https://lore.kernel.org/r/20231129234417.856536-4-song@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 67814c00de3161181cddd06c77aeaf86ac4cc584 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds documentation for filesystem kfuncs, specifically bpf_get_file_xattr() and bpf_get_fsverity_digest().', 'keywords': 'documentation, filesystem, kfuncs', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 67814c00de3161181cddd06c77aeaf86ac4cc584 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 67814c00de3161181cddd06c77aeaf86ac4cc584 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701476463 + Commit Message: + bpf + Parent Hashes: ac9c05e0e453cfcab2866f6d28f257590e4f66e5 + Refs: fsverity: Add kfunc bpf_get_fsverity_digest + +fsverity provides fast and reliable hash of files + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add kfunc bpf_get_fsverity_digest for fast and reliable file hash in fsverity.', 'keywords': 'fsverity,kfunc,hash', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ac9c05e0e453cfcab2866f6d28f257590e4f66e5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ac9c05e0e453cfcab2866f6d28f257590e4f66e5 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1701476463 + Commit Message: + bpf: Add kfunc bpf_get_file_xattr + +It is common practice for security solutions to store tags/labels in +xattrs. To implement similar functionalities in BPF LSM + Parent Hashes: b6a3451e0847d5d70fb5fa2b2a80ab9f80bf2c7b + Refs: add new kfunc +bpf_get_file_xattr(). + +The first use case of bpf_get_file_xattr() is to implement file +verifications with asymmetric keys. Specificially + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new kfunc bpf_get_file_xattr to support file verifications with BPF LSM.', 'keywords': 'kfunc,xattr,LSM', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['LSM like programs']} +-------------------- +-------------------- +Processing Commit ID: dfce9cb3140592b886838e06f3e0c25fea2a9cae +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dfce9cb3140592b886838e06f3e0c25fea2a9cae + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1701474110 + Commit Message: + bpf: Fix a verifier bug due to incorrect branch offset comparison with cpu=v4 + +Bpf cpu=v4 support is introduced in [1] and Commit 4cd58e9af8b9 +("bpf: Support new 32bit offset jmp instruction") added support for new +32bit offset jmp instruction. Unfortunately + Parent Hashes: 830139e7b6911266a84a77e1f18abf758995cc89 + Refs: in function +bpf_adj_delta_to_off() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a verifier bug related to incorrect branch offset comparison for CPU version v4 in eBPF.', 'keywords': 'verifier, bug, offset', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b6a3451e0847d5d70fb5fa2b2a80ab9f80bf2c7b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b6a3451e0847d5d70fb5fa2b2a80ab9f80bf2c7b + Author Name: Jeroen van Ingen Schenau + Author Email: jeroen.vaningenschenau@novoserve.com + Commit Date: 1701443565 + Commit Message: + selftests/bpf: Fix erroneous bitmask operation + +xdp_synproxy_kern.c is a BPF program that generates SYN cookies on +allowed TCP ports and sends SYNACKs to clients + Parent Hashes: 15bc81212f593fbd7bda787598418b931842dc14 + Refs: accelerating synproxy +iptables module. + +Fix the bitmask operation when checking the status of an existing +conntrack entry within tcp_lookup() function. Do not AND with the bit +position number + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes an erroneous bitmask operation in the xdp_synproxy_kern BPF program for tracking TCP connections.', 'keywords': 'bitmask, synproxy, conntrack', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs', 'socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 753c8608f3e579307493a63b9242667aee35a751 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 753c8608f3e579307493a63b9242667aee35a751 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1701392322 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-11-30 + +We've added 30 non-merge commits during the last 7 day(s) which contain +a total of 58 files changed + Parent Hashes: 975f2d73a99f35b57ffa2ad7bff8562225cdcfcb f690ff9122d2ca8e38769f3bcf217bd3df681a36 + Refs: 1598 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merged branch 'for-netdev' containing multiple eBPF related changes into the main tree.", 'keywords': 'merge,eBPF,changes', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6172a5180fcc65170bfa2d49e55427567860f2a7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6172a5180fcc65170bfa2d49e55427567860f2a7 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1701386686 + Commit Message: + Merge tag 'net-6.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + "Including fixes from bpf and wifi. + + Current release - regressions: + + - neighbour: fix __randomize_layout crash in struct neighbour + + - r8169: fix deadlock on RTL8125 in jumbo mtu mode + + Previous releases - regressions: + + - wifi: + - mac80211: fix warning at station removal time + - cfg80211: fix CQM for non-range use + + - tools: ynl-gen: fix unexpected response handling + + - octeontx2-af: fix possible buffer overflow + + - dpaa2: recycle the RX buffer only after all processing done + + - rswitch: fix missing dev_kfree_skb_any() in error path + + Previous releases - always broken: + + - ipv4: fix uaf issue when receiving igmp query packet + + - wifi: mac80211: fix debugfs deadlock at device removal time + + - bpf: + - sockmap: af_unix stream sockets need to hold ref for pair sock + - netdevsim: don't accept device bound programs + + - selftests: fix a char signedness issue + + - dsa: mv88e6xxx: fix marvell 6350 probe crash + + - octeontx2-pf: restore TC ingress police rules when interface is up + + - wangxun: fix memory leak on msix entry + + - ravb: keep reverse order of operations in ravb_remove()" + +* tag 'net-6.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (51 commits) + net: ravb: Keep reverse order of operations in ravb_remove() + net: ravb: Stop DMA in case of failures on ravb_open() + net: ravb: Start TX queues after HW initialization succeeded + net: ravb: Make write access to CXR35 first before accessing other EMAC registers + net: ravb: Use pm_runtime_resume_and_get() + net: ravb: Check return value of reset_control_deassert() + net: libwx: fix memory leak on msix entry + ice: Fix VF Reset paths when interface in a failed over aggregate + bpf + Parent Hashes: e8f60209d6cf652a9cfda64371acea69f62770aa 777f245eec8152926b411e3d4f4545310f52cbed + Refs: sockmap: Add af_unix test with both sockets in map + bpf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes for various components including bpf, wifi, and others.', 'keywords': 'networking, fixes, bpf', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', 'other']} +-------------------- +-------------------- +Processing Commit ID: f9893fdac319bb2817e5e7818870264d7fb2eb02 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f9893fdac319bb2817e5e7818870264d7fb2eb02 + Author Name: Eric Dumazet + Author Email: edumazet@google.com + Commit Date: 1701368098 + Commit Message: + net: page_pool: fix general protection fault in page_pool_unlist + +syzbot was able to trigger a crash [1] in page_pool_unlist() + +page_pool_list() only inserts a page pool into a netdev page pool list +if a netdev was set in params. + +Even if the kzalloc() call in page_pool_create happens to initialize +pool->user.list + Parent Hashes: 7e0222686316f5506e51182f02c1d83ecc34c471 + Refs: I chose to be more explicit in page_pool_list() +adding one INIT_HLIST_NODE(). + +We could test in page_pool_unlist() if netdev was set + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix protection fault issue in page_pool_unlist caused by missing netdev initialization.', 'keywords': 'net, page_pool, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: f690ff9122d2ca8e38769f3bcf217bd3df681a36 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f690ff9122d2ca8e38769f3bcf217bd3df681a36 + Author Name: Yujie Liu + Author Email: yujie.liu@intel.com + Commit Date: 1701343053 + Commit Message: + bpf/tests: Remove duplicate JSGT tests + +It seems unnecessary that JSGT is tested twice (one before JSGE and one +after JSGE) since others are tested only once. Remove the duplicate JSGT +tests. + +Fixes: 0bbaa02b4816 ("bpf/tests: Add tests to check source register zero-extension") +Signed-off-by: Yujie Liu +Signed-off-by: Daniel Borkmann +Acked-by: Johan Almbladh +Link: https://lore.kernel.org/bpf/20231130034018.2144963-1-yujie.liu@intel.com + + Parent Hashes: b5145153a7f33e33f729ee67a11a8901a5609064 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes duplicate JSGT tests in the BPF test suite to avoid redundancy.', 'keywords': 'JSGT,tests,duplicate', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0d47fa5cc91b9c8a0c90833bf1705048b2295714 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0d47fa5cc91b9c8a0c90833bf1705048b2295714 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1701315604 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-11-30 + +We've added 5 non-merge commits during the last 7 day(s) which contain +a total of 10 files changed + Parent Hashes: 83f2df9d66bc9e1e0dbd5d5586a701088f6a1d42 51354f700d400e55b329361e1386b04695e6e5c1 + Refs: 66 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge a series of bpf updates from the last 7 days with changes to 10 files.', 'keywords': 'merge, updates, bpf', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 51354f700d400e55b329361e1386b04695e6e5c1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 51354f700d400e55b329361e1386b04695e6e5c1 + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1701300325 + Commit Message: + bpf + Parent Hashes: 8866730aed5100f06d3d965c22f1c61f74942541 + Refs: sockmap: Add af_unix test with both sockets in map + +This adds a test where both pairs of a af_unix paired socket are put into a +BPF map. This ensures that when we tear down the af_unix pair we don't have +any issues on sockmap side with ordering and reference counting. + +Signed-off-by: John Fastabend +Signed-off-by: Daniel Borkmann +Reviewed-by: Jakub Sitnicki +Link: https://lore.kernel.org/bpf/20231129012557.95371-3-john.fastabend@gmail.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test for af_unix socket pairs in a BPF map to ensure no ordering or reference counting issues.', 'keywords': 'af_unix,bpf map,sockmap', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 8866730aed5100f06d3d965c22f1c61f74942541 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8866730aed5100f06d3d965c22f1c61f74942541 + Author Name: John Fastabend + Author Email: john.fastabend@gmail.com + Commit Date: 1701300316 + Commit Message: + bpf + Parent Hashes: 0bad281d0ecdf8391b0f42678b663336e7c3ceb0 + Refs: sockmap: af_unix stream sockets need to hold ref for pair sock + +AF_UNIX stream sockets are a paired socket. So sending on one of the pairs +will lookup the paired socket as part of the send operation. It is possible +however to put just one of the pairs in a BPF map. This currently increments +the refcnt on the sock in the sockmap to ensure it is not free'd by the +stack before sockmap cleans up its state and stops any skbs being sent/recv'd +to that socket. + +But we missed a case. If the peer socket is closed it will be free'd by the +stack. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix issue with AF_UNIX stream sockets in sockmap by handling peer socket closure.', 'keywords': 'AF_UNIX, sockmap, refcnt', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: b5145153a7f33e33f729ee67a11a8901a5609064 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b5145153a7f33e33f729ee67a11a8901a5609064 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1701298781 + Commit Message: + Merge branch 'xsk-tx-metadata' + +Stanislav Fomichev says: + +==================== +xsk: TX metadata + +This series implements initial TX metadata (offloads) for AF_XDP. +See patch #2 for the main implementation and mlx5/stmmac ones for the +example on how to consume the metadata on the device side. + +Starting with two types of offloads: +- request TX timestamp (and write it back into the metadata area) +- request TX checksum offload + +Changes since v5: +- preserve xsk_tx_metadata flags across tx and completion by moving + them out of 'request' union (Jesper) +- fix xdp_metadata checksum failure in big endian (Alexei) +- add SPDX to xdp-rx-metadata.rst (Simon) + +v5: https://lore.kernel.org/bpf/20231102225837.1141915-1-sdf@google.com/ + +Performance (mlx5): + +I've implemented a small xskgen tool to try to saturate single tx queue: +https://github.com/fomichev/xskgen/tree/master + +Here are the performance numbers with some analysis. + +1. Baseline. Running with commit eb62e6aef940 ("Merge branch 'bpf: +Support bpf_get_func_ip helper in uprobes'") + Parent Hashes: 40d0eb0259ae77ace3e81d7454d1068c38bc95c2 60523115c1b10c8855492d84c1ba88af452e221c + Refs: nothing from this series: + +- with 1400 bytes of payload: 98 gbps + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implements initial TX metadata offloads for AF_XDP including TX timestamp and checksum offloads.', 'keywords': 'TX metadata, offloads, AF_XDP', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 60523115c1b10c8855492d84c1ba88af452e221c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 60523115c1b10c8855492d84c1ba88af452e221c + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1701298781 + Commit Message: + selftests/bpf: Add TX side to xdp_hw_metadata + +When we get a packet on port 9091 + Parent Hashes: 12b4b7963d3cca253db3c31aa7611b988699e30f + Refs: we swap src/dst and send it out. +At this point we also request the timestamp and checksum offloads. + +Checksum offload is verified by looking at the tcpdump on the other side. +The tool prints pseudo-header csum and the final one it expects. +The final checksum actually matches the incoming packets checksum +because we only flip the src/dst and don't change the payload. + +Some other related changes: +- switched to zerocopy mode by default; new flag can be used to force + old behavior +- request fixed tx_metadata_len headroom +- some other small fixes (umem size + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds TX functionality to xdp_hw_metadata selftests, including swapping src/dst and verifying checksum offloads.', 'keywords': 'xdp_hw_metadata,checksum,zerocopy', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 12b4b7963d3cca253db3c31aa7611b988699e30f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 12b4b7963d3cca253db3c31aa7611b988699e30f + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1701298781 + Commit Message: + selftests/bpf: Convert xdp_hw_metadata to XDP_USE_NEED_WAKEUP + +This is the recommended way to run AF_XDP + Parent Hashes: 40808a237d9c8fcaa3eaeefe2ac59e4733907478 + Refs: so let's use it in the test. + +Also + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Convert selftests of xdp_hw_metadata to use XDP_USE_NEED_WAKEUP for AF_XDP.', 'keywords': 'selftests, xdp_hw_metadata, XDP_USE_NEED_WAKEUP', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 40808a237d9c8fcaa3eaeefe2ac59e4733907478 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 40808a237d9c8fcaa3eaeefe2ac59e4733907478 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1701298781 + Commit Message: + selftests/bpf: Add TX side to xdp_metadata + +Request TX timestamp and make sure it's not empty. +Request TX checksum offload (SW-only) and make sure it's resolved +to the correct one. + +Signed-off-by: Stanislav Fomichev +Link: https://lore.kernel.org/r/20231127190319.1190813-12-sdf@google.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: f6642de0c3e94d3ef6f44e127d11fcf4138873f7 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add transmission side handling to xdp_metadata selftests and verify TX timestamp and checksum offload.', 'keywords': 'xdp_metadata, TX timestamp, checksum offload', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: f6642de0c3e94d3ef6f44e127d11fcf4138873f7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f6642de0c3e94d3ef6f44e127d11fcf4138873f7 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1701298781 + Commit Message: + selftests/bpf: Add csum helpers + +Checksum helpers will be used to calculate pseudo-header checksum in +AF_XDP metadata selftests. + +The helpers are mirroring existing kernel ones: +- csum_tcpudp_magic : IPv4 pseudo header csum +- csum_ipv6_magic : IPv6 pseudo header csum +- csum_fold : fold csum and do one's complement + +Signed-off-by: Stanislav Fomichev +Link: https://lore.kernel.org/r/20231127190319.1190813-11-sdf@google.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: df3ed0003ec4994ce8ed4818c435c481281df89e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add checksum helpers for AF_XDP metadata selftests in BPF.', 'keywords': 'checksum, helpers, AF_XDP', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 1347b419318d6afa1c86d7865d82ca0a6cdf30ce +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1347b419318d6afa1c86d7865d82ca0a6cdf30ce + Author Name: Song Yoong Siang + Author Email: yoong.siang.song@intel.com + Commit Date: 1701298780 + Commit Message: + net: stmmac: Add Tx HWTS support to XDP ZC + +This patch enables transmit hardware timestamp support to XDP zero copy +via XDP Tx metadata framework. + +This patchset is tested with tools/testing/selftests/bpf/xdp_hw_metadata +on Intel Tiger Lake platform. Below are the test steps and results. + +Command on DUT: +sudo ./xdp_hw_metadata +sudo hwstamp_ctl -i -t 1 -r 1 + +Command on Link Partner: +echo -n xdp | nc -u -q1 9091 + +Result: +xsk_ring_cons__peek: 1 +0x55bbbf08b6d0: rx_desc[2]->addr=8c100 addr=8c100 comp_addr=8c100 EoP +No rx_hash err=-95 +rx_timestamp: 1677762688429141540 (sec:1677762688.4291) +HW RX-time: 1677762688429141540 (sec:1677762688.4291) delta to User RX-time sec:0.0003 (250.665 usec) +XDP RX-time: 1677762688429375597 (sec:1677762688.4294) delta to User RX-time sec:0.0000 (16.608 usec) +0x55bbbf08b6d0: ping-pong with csum=561c (want f488) csum_start=34 csum_offset=6 +0x55bbbf08b6d0: complete tx idx=2 addr=2008 +tx_timestamp: 1677762688431127273 (sec:1677762688.4311) +HW TX-complete-time: 1677762688431127273 (sec:1677762688.4311) delta to User TX-complete-time sec:0.0083 (8331.655 usec) +XDP RX-time: 1677762688429375597 (sec:1677762688.4294) delta to User TX-complete-time sec:0.0101 (10083.331 usec) +HW RX-time: 1677762688429141540 (sec:1677762688.4291) delta to HW TX-complete-time sec:0.0020 (1985.733 usec) +0x55bbbf08b6d0: complete rx idx=130 addr=8c100 + +Signed-off-by: Song Yoong Siang +Signed-off-by: Stanislav Fomichev +Link: https://lore.kernel.org/r/20231127190319.1190813-6-sdf@google.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: ec706a860eba99bf934d59f74b5db90af44e882e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds transmit hardware timestamp support to XDP zero copy in the stmmac driver.', 'keywords': 'XDP,timestamp,stmmac', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 40d0eb0259ae77ace3e81d7454d1068c38bc95c2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 40d0eb0259ae77ace3e81d7454d1068c38bc95c2 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701238530 + Commit Message: + Merge branch 'selftests-bpf-use-pkg-config-to-determine-ld-flags' + +Akihiko Odaki says: + +==================== +selftests/bpf: Use pkg-config to determine ld flags + +When linking statically + Parent Hashes: d4e7dd4842b190e87a5b7179a460f54b13da3ac4 8998a479fd96b0b209dcb2feb468eba7eddb4ddb + Refs: libraries may require other dependencies to be +included to ld flags. In particular + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Use pkg-config for determining ld flags in selftests/bpf linking process.', 'keywords': 'pkg-config, ld flags, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 8998a479fd96b0b209dcb2feb468eba7eddb4ddb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8998a479fd96b0b209dcb2feb468eba7eddb4ddb + Author Name: Akihiko Odaki + Author Email: akihiko.odaki@daynix.com + Commit Date: 1701238529 + Commit Message: + selftests/bpf: Use pkg-config for libelf + +When linking statically + Parent Hashes: 18f6f9de98d1d0f7040e6e6c39fce8939f55520f + Refs: libraries may require other dependencies to be +included to ld flags. In particular + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates selftests/bpf to use pkg-config for obtaining libelf dependencies when linking statically.', 'keywords': 'selftests,bpf,libelf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 18f6f9de98d1d0f7040e6e6c39fce8939f55520f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 18f6f9de98d1d0f7040e6e6c39fce8939f55520f + Author Name: Akihiko Odaki + Author Email: akihiko.odaki@daynix.com + Commit Date: 1701238529 + Commit Message: + selftests/bpf: Override PKG_CONFIG for static builds + +A library may need to depend on additional archive files for static +builds so pkg-config should be instructed to list them. + +Signed-off-by: Akihiko Odaki +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231125084253.85025-3-akihiko.odaki@daynix.com + + Parent Hashes: 2ce344b6891618063c0bebe22d9cdf9c086e0aa8 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Override PKG_CONFIG for static builds in selftests for enhanced library dependency handling.', 'keywords': 'static, PKG_CONFIG, selftests', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 2ce344b6891618063c0bebe22d9cdf9c086e0aa8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2ce344b6891618063c0bebe22d9cdf9c086e0aa8 + Author Name: Akihiko Odaki + Author Email: akihiko.odaki@daynix.com + Commit Date: 1701238529 + Commit Message: + selftests/bpf: Choose pkg-config for the target + +pkg-config is used to build sign-file executable. It should use the +library for the target instead of the host as it is called during tests. + +Signed-off-by: Akihiko Odaki +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231125084253.85025-2-akihiko.odaki@daynix.com + + Parent Hashes: d4e7dd4842b190e87a5b7179a460f54b13da3ac4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates selftests to use pkg-config for the target during tests instead of the host.', 'keywords': 'selftests,pkg-config,target', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: d4e7dd4842b190e87a5b7179a460f54b13da3ac4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d4e7dd4842b190e87a5b7179a460f54b13da3ac4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1701237010 + Commit Message: + Merge branch 'bpf-add-link_info-support-for-uprobe-multi-link' + +Jiri Olsa says: + +==================== +bpf: Add link_info support for uprobe multi link + +hi + Parent Hashes: cf9791631027a476f7cdb0e1b3ac6add16eff264 a7795698f8b6c48283fa4334eb313bc1350b2864 + Refs: +this patchset adds support to get bpf_link_info details for +uprobe_multi links and adding support for bpftool link to +display them. + +v4 changes: + - move flags field up in bpf_uprobe_multi_link [Andrii] + - include zero terminating byte in path_size [Andrii] + - return d_path error directly [Yonghong] + - use SEC(".probes") for semaphores [Yonghong] + - fix ref_ctr_offsets leak in test [Yonghong] + - other smaller fixes [Yonghong] + +thanks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhances bpf_link_info with support for uprobe multi-link and updates bpftool link display.', 'keywords': 'uprobe, bpf_link_info, bpftool', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: a7795698f8b6c48283fa4334eb313bc1350b2864 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a7795698f8b6c48283fa4334eb313bc1350b2864 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1701237009 + Commit Message: + bpftool: Add support to display uprobe_multi links + +Adding support to display details for uprobe_multi links + Parent Hashes: 147c69307bcf67f1f01246f9acb794da9837f299 + Refs: +both plain: + + # bpftool link -p + ... + 24: uprobe_multi prog 126 + uprobe.multi path /home/jolsa/bpf/test_progs func_cnt 3 pid 4143 + offset ref_ctr_offset cookies + 0xd1f88 0xf5d5a8 0xdead + 0xd1f8f 0xf5d5aa 0xbeef + 0xd1f96 0xf5d5ac 0xcafe + +and json: + + # bpftool link -p + [{ + ... + } + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support in bpftool to display details for uprobe_multi links.', 'keywords': 'bpftool, uprobe_multi, links', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 147c69307bcf67f1f01246f9acb794da9837f299 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 147c69307bcf67f1f01246f9acb794da9837f299 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1701237009 + Commit Message: + selftests/bpf: Add link_info test for uprobe_multi link + +Adding fill_link_info test for uprobe_multi link. + +Setting up uprobes with bogus ref_ctr_offsets and cookie values +to test all the bpf_link_info::uprobe_multi fields. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Song Liu +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20231125193130.834322-6-jolsa@kernel.org + + Parent Hashes: 1703612885723869064f18e8816c6f3f87987748 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add and test link_info for uprobe_multi link in BPF selftests.', 'keywords': 'uprobe_multi, bpf_link_info, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 1703612885723869064f18e8816c6f3f87987748 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1703612885723869064f18e8816c6f3f87987748 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1701237009 + Commit Message: + selftests/bpf: Use bpf_link__destroy in fill_link_info tests + +The fill_link_info test keeps skeleton open and just creates +various links. We are wrongly calling bpf_link__detach after +each test to close them + Parent Hashes: e56fdbfb06e26a7066b070967badef4148528df2 + Refs: we need to call bpf_link__destroy. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: Yafang Shao +Link: https://lore.kernel.org/bpf/20231125193130.834322-5-jolsa@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates fill_link_info tests to use bpf_link__destroy instead of bpf_link__detach to properly close links.', 'keywords': 'test update, bpf_link__destroy, fill_link_info', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e56fdbfb06e26a7066b070967badef4148528df2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e56fdbfb06e26a7066b070967badef4148528df2 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1701237009 + Commit Message: + bpf: Add link_info support for uprobe multi link + +Adding support to get uprobe_link details through bpf_link_info +interface. + +Adding new struct uprobe_multi to struct bpf_link_info to carry +the uprobe_multi link details. + +The uprobe_multi.count is passed from user space to denote size +of array fields (offsets/ref_ctr_offsets/cookies). The actual +array size is stored back to uprobe_multi.count (allowing user +to find out the actual array size) and array fields are populated +up to the user passed size. + +All the non-array fields (path/count/flags/pid) are always set. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20231125193130.834322-4-jolsa@kernel.org + + Parent Hashes: 4930b7f53a298533bc31d7540b6ea8b79a000331 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added support for uprobe multi link details in bpf_link_info interface.', 'keywords': 'uprobe,multi link,bpf_link_info', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 4930b7f53a298533bc31d7540b6ea8b79a000331 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4930b7f53a298533bc31d7540b6ea8b79a000331 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1701237009 + Commit Message: + bpf: Store ref_ctr_offsets values in bpf_uprobe array + +We will need to return ref_ctr_offsets values through link_info +interface in following change + Parent Hashes: 48f0dfd8d3e212ab27b6db147ed10407ff6aaa88 + Refs: so we need to keep them around. + +Storing ref_ctr_offsets values directly into bpf_uprobe array. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Acked-by: Song Liu +Link: https://lore.kernel.org/bpf/20231125193130.834322-3-jolsa@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit stores ref_ctr_offsets values in the bpf_uprobe array for future link_info interface usage.', 'keywords': 'ref_ctr_offsets, bpf_uprobe, link_info', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 48f0dfd8d3e212ab27b6db147ed10407ff6aaa88 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 48f0dfd8d3e212ab27b6db147ed10407ff6aaa88 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1701237009 + Commit Message: + libbpf: Add st_type argument to elf_resolve_syms_offsets function + +We need to get offsets for static variables in following changes + Parent Hashes: cf9791631027a476f7cdb0e1b3ac6add16eff264 + Refs: +so making elf_resolve_syms_offsets to take st_type value as argument +and passing it to elf_sym_iter_new. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Acked-by: Song Liu +Link: https://lore.kernel.org/bpf/20231125193130.834322-2-jolsa@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add st_type argument to elf_resolve_syms_offsets in libbpf for static variable offsets.', 'keywords': 'libbpf, elf_resolve_syms_offsets, st_type', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a79d8ba734bdbd2574ad16dd1b96506e5f642c4a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a79d8ba734bdbd2574ad16dd1b96506e5f642c4a + Author Name: Pedro Tammela + Author Email: pctammela@mojatatu.com + Commit Date: 1701137742 + Commit Message: + selftests: tc-testing: remove buildebpf plugin + +As tdc only tests loading/deleting and anything more complicated is +better left to the ebpf test suite + Parent Hashes: cae0de45c8fd62612e1ee429134fd82c2c0e335e + Refs: provide a pre-compiled version of +'action.c' and don't bother compiling it in kselftests or on the fly +at all. + +Cc: Davide Caratti +Signed-off-by: Pedro Tammela +Acked-by: Jamal Hadi Salim +Link: https://lore.kernel.org/r/20231124154248.315470-2-pctammela@mojatatu.com +Signed-off-by: Jakub Kicinski + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove buildebpf plugin from tc-testing as complex tasks are handled by the ebpf test suite.', 'keywords': 'buildebpf, tc-testing, selftests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: cf9791631027a476f7cdb0e1b3ac6add16eff264 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cf9791631027a476f7cdb0e1b3ac6add16eff264 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1701131024 + Commit Message: + selftests/bpf: update test_offload to use new orphaned property + +- filter orphaned programs by default +- when trying to query orphaned program + Parent Hashes: 876843ce1e4897e8ceade50bfa3d9a4ec483abf3 + Refs: don't expect bpftool failure + +Cc: netdev@vger.kernel.org +Signed-off-by: Stanislav Fomichev +Link: https://lore.kernel.org/r/20231127182057.1081138-2-sdf@google.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update selftests to use a new orphaned property for offload testing in BPF.', 'keywords': 'selftests, offload, orphaned', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 876843ce1e4897e8ceade50bfa3d9a4ec483abf3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 876843ce1e4897e8ceade50bfa3d9a4ec483abf3 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1701131018 + Commit Message: + bpftool: mark orphaned programs during prog show + +Commit ef01f4e25c17 ("bpf: restore the ebpf program ID for BPF_AUDIT_UNLOAD +and PERF_BPF_EVENT_PROG_UNLOAD") stopped removing program's id from +idr when the offloaded/bound netdev goes away. I was supposed to +take a look and check in [0] + Parent Hashes: b16904fd9f01b580db357ef2b1cc9e86d89576c2 + Refs: but apparently I did not. + +Martin points out it might be useful to keep it that way for +observability sake + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "This commit marks orphaned programs during 'prog show' in bpftool for improved observability.", 'keywords': 'orphaned, bpftool, observability', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0bad281d0ecdf8391b0f42678b663336e7c3ceb0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0bad281d0ecdf8391b0f42678b663336e7c3ceb0 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1701130054 + Commit Message: + netkit: Reject IFLA_NETKIT_PEER_INFO in netkit_change_link + +The IFLA_NETKIT_PEER_INFO attribute can only be used during device +creation + Parent Hashes: 75a442581d05edaee168222ffbe00d4389785636 + Refs: but not via changelink callback. Hence reject it there. + +Fixes: 35dfaad7188c ("netkit + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reject inappropriate use of IFLA_NETKIT_PEER_INFO in netkit_change_link.', 'keywords': 'netkit, ifla_netkit_peer_info, changelink', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1638b11ef8156c8551f5aaa5799069633593c5fe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1638b11ef8156c8551f5aaa5799069633593c5fe + Author Name: Athira Rajeev + Author Email: atrajeev@linux.vnet.ibm.com + Commit Date: 1701096513 + Commit Message: + perf tools: Add perf binary dependent rule for shellcheck log in Makefile.perf + +Add rule in new Makefile "tests/Makefile.tests" for running shellcheck +on shell test scripts. This automates below shellcheck into the build. + + $ for F in $(find tests/shell/ -perm -o=x -name '*.sh'); do shellcheck -S warning $F; done + +Condition for shellcheck is added in Makefile.perf to avoid build +breakage in the absence of shellcheck binary. Update Makefile.perf to +contain new rule for "SHELLCHECK_TEST" which is for making shellcheck +test as a dependency on perf binary. + +Added "tests/Makefile.tests" to run shellcheck on shellscripts in +tests/shell. The make rule "SHLLCHECK_RUN" ensures that + Parent Hashes: 5ebe2f4bf0a8fe8cceb5664a7dea4c17e2cf8477 + Refs: every time +during make + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a rule in Makefile to run shellcheck on shell scripts and prevent build breakage if the shellcheck binary is missing.', 'keywords': 'shellcheck, Makefile, tests', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b16904fd9f01b580db357ef2b1cc9e86d89576c2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b16904fd9f01b580db357ef2b1cc9e86d89576c2 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1701093219 + Commit Message: + bpf: Fix a few selftest failures due to llvm18 change + +With latest upstream llvm18 + Parent Hashes: e8a339b5235e294f29153149ea7cf26a9a87dbea + Refs: the following test cases failed: + + $ ./test_progs -j + #13/2 bpf_cookie/multi_kprobe_link_api:FAIL + #13/3 bpf_cookie/multi_kprobe_attach_api:FAIL + #13 bpf_cookie:FAIL + #77 fentry_fexit:FAIL + #78/1 fentry_test/fentry:FAIL + #78 fentry_test:FAIL + #82/1 fexit_test/fexit:FAIL + #82 fexit_test:FAIL + #112/1 kprobe_multi_test/skel_api:FAIL + #112/2 kprobe_multi_test/link_api_addrs:FAIL + [...] + #112 kprobe_multi_test:FAIL + #356/17 test_global_funcs/global_func17:FAIL + #356 test_global_funcs:FAIL + +Further analysis shows llvm upstream patch [1] is responsible for the above +failures. For example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes selftest failures caused by llvm18 changes in the Linux eBPF subsystem.', 'keywords': 'bpf,selftest,llvm18', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 75a442581d05edaee168222ffbe00d4389785636 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 75a442581d05edaee168222ffbe00d4389785636 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1701050426 + Commit Message: + bpf: Add missed allocation hint for bpf_mem_cache_alloc_flags() + +bpf_mem_cache_alloc_flags() may call __alloc() directly when there is no +free object in free list + Parent Hashes: c0c6bde586c7dce82719b4ff32a2db6af9ee3d65 + Refs: but it doesn't initialize the allocation hint +for the returned pointer. It may lead to bad memory dereference when +freeing the pointer + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add an allocation hint to bpf_mem_cache_alloc_flags() to prevent bad memory dereference.', 'keywords': 'allocation,memory,dereference', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e8a339b5235e294f29153149ea7cf26a9a87dbea +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e8a339b5235e294f29153149ea7cf26a9a87dbea + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700818806 + Commit Message: + selftests/bpf: Add lazy global subprog validation tests + +Add a few test that validate BPF verifier's lazy approach to validating +global subprogs. + +We check that global subprogs that are called transitively through +another global subprog is validated. + +We also check that invalid global subprog is not validated + Parent Hashes: 2afae08c9dcb8ac648414277cec70c2fe6a34d9e + Refs: if it's not +called from the main program. + +And we also check that main program is always validated first + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Add selftests for validating the BPF verifier's lazy approach to global subprog validation.", 'keywords': 'selftests,BPF verifier,validation', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2afae08c9dcb8ac648414277cec70c2fe6a34d9e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2afae08c9dcb8ac648414277cec70c2fe6a34d9e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700818806 + Commit Message: + bpf: Validate global subprogs lazily + +Slightly change BPF verifier logic around eagerness and order of global +subprog validation. Instead of going over every global subprog eagerly +and validating it before main (entry) BPF program is verified + Parent Hashes: 491dd8edecbc5027ee317f3f1e7e9800fb66d88f + Refs: turn it +around. Validate main program first + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "This commit changes the BPF verifier's approach to validate global subprograms lazily, focusing first on the main program.", 'keywords': 'BPF verifier, global subprogs, validation', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 491dd8edecbc5027ee317f3f1e7e9800fb66d88f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 491dd8edecbc5027ee317f3f1e7e9800fb66d88f + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700818806 + Commit Message: + bpf: Emit global subprog name in verifier logs + +We have the name + Parent Hashes: b8d78cb2e24d92352878a9f6525aec002c891528 + Refs: instead of emitting just func#N to identify global +subprog + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Emit global subprogram names in eBPF verifier logs for better identification.', 'keywords': 'verifier,logs,subprog', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b8d78cb2e24d92352878a9f6525aec002c891528 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b8d78cb2e24d92352878a9f6525aec002c891528 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700776181 + Commit Message: + libbpf: Start v1.4 development cycle + +Bump libbpf.map to v1.4.0 to start a new libbpf version cycle. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231123000439.12025-1-eddyz87@gmail.com + + Parent Hashes: 45c226dde742a92e22dcd65b96bf7e02620a9c19 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Bump libbpf.map to v1.4.0 to start a new libbpf version cycle.', 'keywords': 'libbpf, version, development', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c0c6bde586c7dce82719b4ff32a2db6af9ee3d65 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c0c6bde586c7dce82719b4ff32a2db6af9ee3d65 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1700773444 + Commit Message: + netdevsim: Don't accept device bound programs + +Commit 2b3486bc2d23 ("bpf: Introduce device-bound XDP programs") introduced +device-bound programs by largely reusing existing offloading infrastructure. +This changed the semantics of 'prog->aux->offload' a bit. Now + Parent Hashes: d3fa86b1a7b4cdc4367acacea16b72e0a200b3d7 + Refs: it's non-NULL +for both offloaded and device-bound programs. + +Instead of looking at 'prog->aux->offload' let's call bpf_prog_is_offloaded +which should be true iff the program is offloaded and not merely device-bound. + +Fixes: 2b3486bc2d23 ("bpf: Introduce device-bound XDP programs") +Reported-by: syzbot+44c2416196b7c607f226@syzkaller.appspotmail.com +Signed-off-by: Stanislav Fomichev +Signed-off-by: Daniel Borkmann +Reviewed-by: Jakub Kicinski +Cc: Dipendra Khadka +Link: https://lore.kernel.org/bpf/20231114045453.1816995-2-sdf@google.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit prevents netdevsim from accepting device-bound XDP programs by correctly checking program offloading status.', 'keywords': 'netdevsim, XDP program, offloading', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 45c226dde742a92e22dcd65b96bf7e02620a9c19 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 45c226dde742a92e22dcd65b96bf7e02620a9c19 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1700770858 + Commit Message: + Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Cross-merge networking fixes after downstream PR. + +Conflicts: + +drivers/net/ethernet/intel/ice/ice_main.c + c9663f79cd82 ("ice: adjust switchdev rebuild path") + 7758017911a4 ("ice: restore timestamp configuration after device reset") +https://lore.kernel.org/all/20231121211259.3348630-1-anthony.l.nguyen@intel.com/ + +Adjacent changes: + +kernel/bpf/verifier.c + bb124da69c47 ("bpf: keep track of max number of bpf_loop callback iterations") + 5f99f312bd3b ("bpf: add register bounds sanity checks and sanitization") + +Signed-off-by: Jakub Kicinski + + Parent Hashes: c5b9f4792ea6b9abfcfb9486ba256f55e296aaa7 d3fa86b1a7b4cdc4367acacea16b72e0a200b3d7 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Cross-merge of networking fixes including changes to ethernet and eBPF verifier subsystems.', 'keywords': 'networking, merge, fixes', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d3fa86b1a7b4cdc4367acacea16b72e0a200b3d7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d3fa86b1a7b4cdc4367acacea16b72e0a200b3d7 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1700764813 + Commit Message: + Merge tag 'net-6.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + "Including fixes from bpf. + + Current release - regressions: + + - Revert "net: r8169: Disable multicast filter for RTL8168H and + RTL8107E" + + - kselftest: rtnetlink: fix ip route command typo + + Current release - new code bugs: + + - s390/ism: make sure ism driver implies smc protocol in kconfig + + - two build fixes for tools/net + + Previous releases - regressions: + + - rxrpc: couple of ACK/PING/RTT handling fixes + + Previous releases - always broken: + + - bpf: verify bpf_loop() callbacks as if they are called unknown + number of times + + - improve stability of auto-bonding with Hyper-V + + - account BPF-neigh-redirected traffic in interface statistics + + Misc: + + - net: fill in some more MODULE_DESCRIPTION()s" + +* tag 'net-6.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (58 commits) + tools: ynl: fix duplicate op name in devlink + tools: ynl: fix header path for nfsd + net: ipa: fix one GSI register field width + tls: fix NULL deref on tls_sw_splice_eof() with empty record + net: axienet: Fix check for partial TX checksum + vsock/test: fix SEQPACKET message bounds test + i40e: Fix adding unsupported cloud filters + ice: restore timestamp configuration after device reset + ice: unify logic for programming PFINT_TSYN_MSK + ice: remove ptp_tx ring parameter flag + amd-xgbe: propagate the correct speed and duplex status + amd-xgbe: handle the corner-case during tx completion + amd-xgbe: handle corner-case during sfp hotplug + net: veth: fix ethtool stats reporting + octeontx2-pf: Fix ntuple rule creation to direct packet to VF with higher Rx queue than its PF + net: usb: qmi_wwan: claim interface 4 for ZTE MF290 + Revert "net: r8169: Disable multicast filter for RTL8168H and RTL8107E" + net/smc: avoid data corruption caused by decline + nfc: virtual_ncidev: Add variable to check if ndev is running + dpll: Fix potential msg memleak when genlmsg_put_reply failed + ... + + Parent Hashes: 9b6de136b5f0158c60844f85286a593cb70fb364 39f04b1406b23fcc129a67e70d6205d5a7322f38 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes that include BPF-related improvements and bug resolutions.', 'keywords': 'networking,BPF,fixes', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 53475287dad9b314ef477fc9a27b48b6999da053 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 53475287dad9b314ef477fc9a27b48b6999da053 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1700618000 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-11-21 + +We've added 85 non-merge commits during the last 12 day(s) which contain +a total of 63 files changed + Parent Hashes: 340bf2dbb11b4d2d44055fa5851d75fd335e3d45 3cbbf9192abdc9183eb215b5e8b06c778e5c2214 + Refs: 4464 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merge branch 'for-netdev' with updates from bpf-next into the main project, including 85 non-merge commits affecting 63 files.", 'keywords': 'merge, bpf-next, non-merge', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b2d66643dcf2c395207f9373c624e0ab32166e57 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b2d66643dcf2c395207f9373c624e0ab32166e57 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1700610571 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-11-21 + +We've added 19 non-merge commits during the last 4 day(s) which contain +a total of 18 files changed + Parent Hashes: 495ec91b48e489afefb2ad714f0d9b68c3016c6c acb12c859ac7c36d6d7632280fd1e263188cb07f + Refs: 1043 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merged 'for-netdev' tag containing 19 non-merge commits into the bpf tree.", 'keywords': 'merge, commits, bpf', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3cbbf9192abdc9183eb215b5e8b06c778e5c2214 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3cbbf9192abdc9183eb215b5e8b06c778e5c2214 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700592326 + Commit Message: + Merge branch 'selftests-bpf-update-multiple-prog_tests-to-use-assert_-macros' + +Yuran Pereira says: + +==================== +selftests/bpf: Update multiple prog_tests to use ASSERT_ macros + +Multiple files/programs in `tools/testing/selftests/bpf/prog_tests/` still +heavily use the `CHECK` macro + Parent Hashes: 57b97ecb40caeb116c22451bbdaaa9a1d12c0b43 3ece0e85f679c23d2a5128993846c58a2f5f890e + Refs: even when better `ASSERT_` alternatives are +available. + +As it was already pointed out by Yonghong Song [1] in the bpf selftests the use +of the ASSERT_* series of macros is preferred over the CHECK macro. + +This patchset replaces the usage of `CHECK(` macros to the equivalent `ASSERT_` +family of macros in the following prog_tests: +- bind_perm.c +- bpf_obj_id.c +- bpf_tcp_ca.c +- vmlinux.c + +[1] https://lore.kernel.org/lkml/0a142924-633c-44e6-9a92-2dc019656bf2@linux.dev + +Changes in v3: +- Addressed the following points mentioned by Yonghong Song +- Improved `bpf_map_lookup_elem` assertion in bpf_tcp_ca. +- Replaced assertion introduced in v2 with one that checks `thread_ret` + instead of `pthread_join`. This ensures that `server`'s return value + (thread_ret) is the one being checked + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update multiple BPF selftests to use ASSERT_ macros instead of CHECK.', 'keywords': 'selftests, ASSERT_ macros, prog_tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3ece0e85f679c23d2a5128993846c58a2f5f890e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3ece0e85f679c23d2a5128993846c58a2f5f890e + Author Name: Yuran Pereira + Author Email: yuran.pereira@hotmail.com + Commit Date: 1700592326 + Commit Message: + selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in vmlinux + +vmlinux.c uses the `CHECK` calls even though the use of ASSERT_ series +of macros is preferred in the bpf selftests. + +This patch replaces all `CHECK` calls for equivalent `ASSERT_` +macro calls. + +Signed-off-by: Yuran Pereira +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/GV1PR10MB6563ED1023A2A3AEF30BDA5DE8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM + + Parent Hashes: f125d09b99fc0ee43f865810390f10b8f23a2c98 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit replaces CHECK calls with ASSERT macros in vmlinux bpf selftests.', 'keywords': 'bpf,selftests,macros', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f125d09b99fc0ee43f865810390f10b8f23a2c98 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f125d09b99fc0ee43f865810390f10b8f23a2c98 + Author Name: Yuran Pereira + Author Email: yuran.pereira@hotmail.com + Commit Date: 1700592324 + Commit Message: + selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bpf_obj_id + +bpf_obj_id uses the `CHECK` calls even though the use of +ASSERT_ series of macros is preferred in the bpf selftests. + +This patch replaces all `CHECK` calls for equivalent `ASSERT_` +macro calls. + +Signed-off-by: Yuran Pereira +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/GV1PR10MB65639AA3A10B4BBAA79952C7E8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM + + Parent Hashes: 3ec1114a97457398077e45b231d502d1cc30439d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaced CHECK calls with ASSERT macros in bpf_obj_id selftests for better consistency.', 'keywords': 'selftests,ASSERT,macros', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3ec1114a97457398077e45b231d502d1cc30439d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3ec1114a97457398077e45b231d502d1cc30439d + Author Name: Yuran Pereira + Author Email: yuran.pereira@hotmail.com + Commit Date: 1700592183 + Commit Message: + selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bind_perm + +bind_perm uses the `CHECK` calls even though the use of +ASSERT_ series of macros is preferred in the bpf selftests. + +This patch replaces all `CHECK` calls for equivalent `ASSERT_` +macro calls. + +Signed-off-by: Yuran Pereira +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/GV1PR10MB656314F467E075A106CA02BFE8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM + + Parent Hashes: b0e2a0395312f4e53504ae84eeb5902e5518d1d7 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaced CHECK calls with ASSERT_ macros in the bind_perm bpf selftests.', 'keywords': 'ASSERT, CHECK, selftests', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b0e2a0395312f4e53504ae84eeb5902e5518d1d7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b0e2a0395312f4e53504ae84eeb5902e5518d1d7 + Author Name: Yuran Pereira + Author Email: yuran.pereira@hotmail.com + Commit Date: 1700592183 + Commit Message: + selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bpf_tcp_ca + +bpf_tcp_ca uses the `CHECK` calls even though the use of +ASSERT_ series of macros is preferred in the bpf selftests. + +This patch replaces all `CHECK` calls for equivalent `ASSERT_` +macro calls. + +Signed-off-by: Yuran Pereira +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/GV1PR10MB6563F180C0F2BB4F6CFA5130E8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM + + Parent Hashes: 57b97ecb40caeb116c22451bbdaaa9a1d12c0b43 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactors selftests by replacing CHECK calls with ASSERT macros in bpf_tcp_ca.', 'keywords': 'selftests, ASSERT, bpf_tcp_ca', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 29b8e94dcf2575c17541f843741ee96691ff1ded +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 29b8e94dcf2575c17541f843741ee96691ff1ded + Author Name: Yang Jihong + Author Email: yangjihong1@huawei.com + Commit Date: 1700589758 + Commit Message: + perf lock contention: Fix a build error on 32-bit + +Fix a build error on 32-bit system: + + util/bpf_lock_contention.c: In function 'lock_contention_get_name': + util/bpf_lock_contention.c:253:50: error: format '%lu' expects argument of type 'long unsigned int' + Parent Hashes: a6dda77a752d918b35ef4a3f94e6b8c7d7ba4a73 + Refs: but argument 4 has type 'u64 {aka long long unsigned int}' [-Werror=format=] + snprintf(name_buf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a build error related to format specifier on 32-bit systems in perf lock contention code.', 'keywords': 'build,error,32-bit', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: acb12c859ac7c36d6d7632280fd1e263188cb07f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: acb12c859ac7c36d6d7632280fd1e263188cb07f + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1700534201 + Commit Message: + Merge branch 'verify-callbacks-as-if-they-are-called-unknown-number-of-times' + +Eduard Zingerman says: + +==================== +verify callbacks as if they are called unknown number of times + +This series updates verifier logic for callback functions handling. +Current master simulates callback body execution exactly once + Parent Hashes: fcb905d831336ee0a67dd953837a904173cf7390 57e2a52deeb12ab84c15c6d0fb93638b5b94001b + Refs: +which leads to verifier not detecting unsafe programs like below: + + static int unsafe_on_zero_iter_cb(__u32 idx + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update verifier logic to handle callbacks as being called an unknown number of times.', 'keywords': 'verifier,callbacks,logic', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 57e2a52deeb12ab84c15c6d0fb93638b5b94001b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 57e2a52deeb12ab84c15c6d0fb93638b5b94001b + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534200 + Commit Message: + selftests/bpf: check if max number of bpf_loop iterations is tracked + +Check that even if bpf_loop() callback simulation does not converge to +a specific state + Parent Hashes: bb124da69c47dd98d69361ec13244ece50bec63e + Refs: verification could proceed via "brute force" +simulation of maximal number of callback calls. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231121020701.26440-12-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test to verify if the maximum number of bpf_loop iterations is correctly tracked in selftests.', 'keywords': 'bpf_loop,selftests,iterations', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: bb124da69c47dd98d69361ec13244ece50bec63e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bb124da69c47dd98d69361ec13244ece50bec63e + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534200 + Commit Message: + bpf: keep track of max number of bpf_loop callback iterations + +In some cases verifier can't infer convergence of the bpf_loop() +iteration. E.g. for the following program: + + static int cb(__u32 idx + Parent Hashes: 9f3330aa644d6d979eb064c46e85c62d4b4eac75 + Refs: struct num_context* ctx) + { + ctx->i++; + return 0; + } + + SEC("?raw_tp") + int prog(void *_) + { + struct num_context ctx = { .i = 0 }; + __u8 choice_arr[2] = { 0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances the verifier to track the maximum number of iterations for bpf_loop callbacks.', 'keywords': 'bpf,verifier,loop', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9f3330aa644d6d979eb064c46e85c62d4b4eac75 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9f3330aa644d6d979eb064c46e85c62d4b4eac75 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534200 + Commit Message: + selftests/bpf: test widening for iterating callbacks + +A test case to verify that imprecise scalars widening is applied to +callback entering state + Parent Hashes: cafe2c21508a38cdb3ed22708842e957b2572c3e + Refs: when callback call is simulated repeatedly. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231121020701.26440-10-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a test case to ensure imprecise scalars are widened in callback entering states during repeated simulations.', 'keywords': 'test,widening,callback', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cafe2c21508a38cdb3ed22708842e957b2572c3e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cafe2c21508a38cdb3ed22708842e957b2572c3e + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534200 + Commit Message: + bpf: widening for callback iterators + +Callbacks are similar to open coded iterators + Parent Hashes: 958465e217dbf5fc6677d42d8827fb3073d86afd + Refs: so add imprecise +widening logic for callback body processing. This makes callback based +loops behave identically to open coded iterators + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add imprecise widening logic for callback iterators in eBPF to match open coded iterators.', 'keywords': 'callback,iterators,widening', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 958465e217dbf5fc6677d42d8827fb3073d86afd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 958465e217dbf5fc6677d42d8827fb3073d86afd + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534200 + Commit Message: + selftests/bpf: tests for iterating callbacks + +A set of test cases to check behavior of callback handling logic + Parent Hashes: ab5cfac139ab8576fb54630d4cca23c3e690ee90 + Refs: +check if verifier catches the following situations: +- program not safe on second callback iteration; +- program not safe on zero callback iterations; +- infinite loop inside a callback. + +Verify that callback logic works for bpf_loop + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds test cases for verifying callback handling logic in selftests for BPF.', 'keywords': 'test cases, callback, iteration', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ab5cfac139ab8576fb54630d4cca23c3e690ee90 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ab5cfac139ab8576fb54630d4cca23c3e690ee90 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534144 + Commit Message: + bpf: verify callbacks as if they are called unknown number of times + +Prior to this patch callbacks were handled as regular function calls + Parent Hashes: 58124a98cb8eda69d248d7f1de954c8b2767c945 + Refs: +execution of callback body was modeled exactly once. +This patch updates callbacks handling logic as follows: +- introduces a function push_callback_call() that schedules callback + body verification in env->head stack; +- updates prepare_func_exit() to reschedule callback body verification + upon BPF_EXIT; +- as calls to bpf_*_iter_next() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update callback handling in eBPF to verify as called unknown number of times.', 'keywords': 'callbacks, verification, bpf', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 58124a98cb8eda69d248d7f1de954c8b2767c945 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 58124a98cb8eda69d248d7f1de954c8b2767c945 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534015 + Commit Message: + bpf: extract setup_func_entry() utility function + +Move code for simulated stack frame creation to a separate utility +function. This function would be used in the follow-up change for +callbacks handling. + +Acked-by: Andrii Nakryiko +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231121020701.26440-6-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 683b96f9606ab7308ffb23c46ab43cecdef8a241 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors code by extracting simulated stack frame creation to a separate utility function setup_func_entry.', 'keywords': 'utility function, stack frame, refactoring', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 683b96f9606ab7308ffb23c46ab43cecdef8a241 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 683b96f9606ab7308ffb23c46ab43cecdef8a241 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534015 + Commit Message: + bpf: extract __check_reg_arg() utility function + +Split check_reg_arg() into two utility functions: +- check_reg_arg() operating on registers from current verifier state; +- __check_reg_arg() operating on a specific set of registers passed as + a parameter; + +The __check_reg_arg() function would be used by a follow-up change for +callbacks handling. + +Acked-by: Andrii Nakryiko +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231121020701.26440-5-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: f40bfd1679446b22d321e64a1fa98b7d07d2be08 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactors check_reg_arg into two functions for better handling of register arguments in the eBPF verifier.', 'keywords': 'utility function,refactor,verifier', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f40bfd1679446b22d321e64a1fa98b7d07d2be08 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f40bfd1679446b22d321e64a1fa98b7d07d2be08 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534015 + Commit Message: + selftests/bpf: fix bpf_loop_bench for new callback verification scheme + +This is a preparatory change. A follow-up patch "bpf: verify callbacks +as if they are called unknown number of times" changes logic for +callbacks handling. While previously callbacks were verified as a +single function call + Parent Hashes: 87eb0152bcc102ecbda866978f4e54db5a3be1ef + Refs: new scheme takes into account that callbacks +could be executed unknown number of times. + +This has dire implications for bpf_loop_bench: + + SEC("fentry/" SYS_PREFIX "sys_getpgid") + int benchmark(void *ctx) + { + for (int i = 0; i < 1000; i++) { + bpf_loop(nr_loops + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes bpf_loop_bench for the new callback verification mechanism in selftests.', 'keywords': 'selftests, bpf, callback', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 87eb0152bcc102ecbda866978f4e54db5a3be1ef +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 87eb0152bcc102ecbda866978f4e54db5a3be1ef + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534015 + Commit Message: + selftests/bpf: track string payload offset as scalar in strobemeta + +This change prepares strobemeta for update in callbacks verification +logic. To allow bpf_loop() verification converge when multiple +callback iterations are considered: +- track offset inside strobemeta_payload->payload directly as scalar + value; +- at each iteration make sure that remaining + strobemeta_payload->payload capacity is sufficient for execution of + read_{map + Parent Hashes: 977bc146d4eb7070118d8a974919b33bb52732b4 + Refs: str}_var functions; +- make sure that offset is tracked as unbound scalar between + iterations + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Track scalar offset of string payload in strobemeta for bpf_loop() iteration verification.', 'keywords': 'strobemeta,scalar,offset', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 977bc146d4eb7070118d8a974919b33bb52732b4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 977bc146d4eb7070118d8a974919b33bb52732b4 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1700534015 + Commit Message: + selftests/bpf: track tcp payload offset as scalar in xdp_synproxy + +This change prepares syncookie_{tc + Parent Hashes: fcb905d831336ee0a67dd953837a904173cf7390 + Refs: xdp} for update in callbakcs +verification logic. To allow bpf_loop() verification converge when +multiple callback itreations are considered: +- track offset inside TCP payload explicitly + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Track TCP payload offset as a scalar in xdp_synproxy to improve bpf_loop() verification logic.', 'keywords': 'tcp,payload,offset', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs', 'tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 57b97ecb40caeb116c22451bbdaaa9a1d12c0b43 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 57b97ecb40caeb116c22451bbdaaa9a1d12c0b43 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700513644 + Commit Message: + selftests/bpf: reduce verboseness of reg_bounds selftest logs + +Reduce verboseness of test_progs' output in reg_bounds set of tests with +two changes. + +First + Parent Hashes: 3e124aa6cb5e74308f5997f63ebd3e5badb5c4e7 + Refs: instead of each different operator (< + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reduce verbosity of reg_bounds selftest logs in bpf selftests.', 'keywords': 'reduce verbosity,selftests,reg_bounds', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fcb905d831336ee0a67dd953837a904173cf7390 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fcb905d831336ee0a67dd953837a904173cf7390 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1700504192 + Commit Message: + Merge branch 'bpf_redirect_peer fixes' + +Daniel Borkmann says: + +==================== +This fixes bpf_redirect_peer stats accounting for veth and netkit + Parent Hashes: 76df934c6d5f5c93ba7a0112b1818620ddc10b19 adfeae2d243d9e5b83d094af481d189156b11779 + Refs: +and adds tstats in the first place for the latter. Utilise indirect +call wrapper for bpf_redirect_peer + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes bpf_redirect_peer stats accounting and adds tstats for veth and netkit.', 'keywords': 'bpf_redirect_peer,veth,tstats', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: adfeae2d243d9e5b83d094af481d189156b11779 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: adfeae2d243d9e5b83d094af481d189156b11779 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1700504116 + Commit Message: + selftests/bpf: Add netkit to tc_redirect selftest + +Extend the existing tc_redirect selftest to also cover netkit devices +for exercising the bpf_redirect_peer() code paths + Parent Hashes: eee82da79f036bb49ff80d3088b9530e3c2e57eb + Refs: so that we have both +veth as well as netkit covered + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extend tc_redirect selftest to include netkit devices for bpf_redirect_peer() path coverage.', 'keywords': 'tc_redirect,selftests,netkit', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: eee82da79f036bb49ff80d3088b9530e3c2e57eb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: eee82da79f036bb49ff80d3088b9530e3c2e57eb + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1700504116 + Commit Message: + selftests/bpf: De-veth-ize the tc_redirect test case + +No functional changes to the test case + Parent Hashes: 2c225425704078282e152ba692649237f78b3d7a + Refs: but just renaming various functions + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Renamed functions in the tc_redirect test case without functional changes.', 'keywords': 'selftests,bpf,tc_redirect', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 2c225425704078282e152ba692649237f78b3d7a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2c225425704078282e152ba692649237f78b3d7a + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1700504116 + Commit Message: + bpf + Parent Hashes: 024ee930cb3c9ae49e4266aee89cfde0ebb407e1 + Refs: netkit: Add indirect call wrapper for fetching peer dev + +ndo_get_peer_dev is used in tcx BPF fast path + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add indirect call wrapper for fetching peer device in tcx BPF fast path.', 'keywords': 'indirect, call, peer', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 024ee930cb3c9ae49e4266aee89cfde0ebb407e1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 024ee930cb3c9ae49e4266aee89cfde0ebb407e1 + Author Name: Peilin Ye + Author Email: peilin.ye@bytedance.com + Commit Date: 1700504116 + Commit Message: + bpf: Fix dev's rx stats for bpf_redirect_peer traffic + +Traffic redirected by bpf_redirect_peer() (used by recent CNIs like Cilium) +is not accounted for in the RX stats of supported devices (that is + Parent Hashes: 6f2684bf2b4460c84d0d34612a939f78b96b03fc + Refs: veth +and netkit) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes RX stats accounting for traffic redirected by bpf_redirect_peer on supported devices.', 'keywords': 'bpf_redirect_peer,RX stats,traffic', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 6f2684bf2b4460c84d0d34612a939f78b96b03fc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6f2684bf2b4460c84d0d34612a939f78b96b03fc + Author Name: Peilin Ye + Author Email: peilin.ye@bytedance.com + Commit Date: 1700504116 + Commit Message: + veth: Use tstats per-CPU traffic counters + +Currently veth devices use the lstats per-CPU traffic counters + Parent Hashes: ae1658272c6491a31ac968e39882fc569f312ac3 + Refs: which only +cover TX traffic. veth_get_stats64() actually populates RX stats of a veth +device from its peer's TX counters + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve veth device traffic statistics by using tstats per-CPU counters for RX and TX.', 'keywords': 'veth, per-CPU, traffic', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 3e124aa6cb5e74308f5997f63ebd3e5badb5c4e7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3e124aa6cb5e74308f5997f63ebd3e5badb5c4e7 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1700423032 + Commit Message: + Merge branch 'bpf-kernel-bpf-task_iter-c-don-t-abuse-next_thread' + +Oleg Nesterov says: + +==================== +bpf: kernel/bpf/task_iter.c: don't abuse next_thread() + +Compile tested. + +Every lockless usage of next_thread() was wrong + Parent Hashes: 16b3129e14bf2e7505512568b11c437c840a0c19 ac8148d957f50434411a0c15a2e4f352b5bb4ff2 + Refs: bpf/task_iter.c is +the last user and is no exception. + +==================== + +Link: https://lore.kernel.org/r/20231114163211.GA874@redhat.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes incorrect lockless usage of next_thread() in bpf/task_iter.c.', 'keywords': 'bpf,task_iter,next_thread', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ac8148d957f50434411a0c15a2e4f352b5bb4ff2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ac8148d957f50434411a0c15a2e4f352b5bb4ff2 + Author Name: Oleg Nesterov + Author Email: oleg@redhat.com + Commit Date: 1700423024 + Commit Message: + bpf: bpf_iter_task_next: use next_task(kit->task) rather than next_task(kit->pos) + +This looks more clear and simplifies the code. While at it + Parent Hashes: 5a34f9dabd9aa567e2d37e1aa27a67f80acfaa1c + Refs: remove the +unnecessary initialization of pos/task at the start of bpf_iter_task_new(). + +Note that we can even kill kit->task + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Simplifies bpf_iter_task_next by using next_task(kit->task) and removing unnecessary initialization.', 'keywords': 'simplifies,next_task,initialization', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 5a34f9dabd9aa567e2d37e1aa27a67f80acfaa1c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5a34f9dabd9aa567e2d37e1aa27a67f80acfaa1c + Author Name: Oleg Nesterov + Author Email: oleg@redhat.com + Commit Date: 1700423024 + Commit Message: + bpf: bpf_iter_task_next: use __next_thread() rather than next_thread() + +Lockless use of next_thread() should be avoided + Parent Hashes: 2d1618054f25e11c44d189dbff4a60342a4cfb4b + Refs: kernel/bpf/task_iter.c +is the last user and the usage is wrong. + +bpf_iter_task_next() can loop forever + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit replaces next_thread() with __next_thread() in bpf_iter_task_next to prevent infinite loops.', 'keywords': 'bpf_iter_task_next, next_thread, lockless', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2d1618054f25e11c44d189dbff4a60342a4cfb4b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2d1618054f25e11c44d189dbff4a60342a4cfb4b + Author Name: Oleg Nesterov + Author Email: oleg@redhat.com + Commit Date: 1700423024 + Commit Message: + bpf: task_group_seq_get_next: use __next_thread() rather than next_thread() + +Lockless use of next_thread() should be avoided + Parent Hashes: 16b3129e14bf2e7505512568b11c437c840a0c19 + Refs: kernel/bpf/task_iter.c +is the last user and the usage is wrong. + +task_group_seq_get_next() can return the group leader twice if it races +with mt-thread exec which changes the group->leader's pid. + +Change the main loop to use __next_thread() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit changes task_group_seq_get_next to use __next_thread() for thread iterating in BPF task iterator.', 'keywords': 'next_thread, lockless, task_group_seq_get_next', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 16b3129e14bf2e7505512568b11c437c840a0c19 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 16b3129e14bf2e7505512568b11c437c840a0c19 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1700336400 + Commit Message: + Merge branch 'bpf-verifier-log-improvements' + +Andrii Nakryiko says: + +==================== +BPF verifier log improvements + +This patch set moves a big chunk of verifier log related code from gigantic +verifier.c file into more focused kernel/bpf/log.c. This is not essential to +the rest of functionality in this patch set + Parent Hashes: ff8867af01daa7ea770bebf5f91199b7434b74e5 46862ee854b4f5a315d63b677ca3af14a89aefeb + Refs: so I can undo it + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor verifier logs into separate log.c file for better code organization.', 'keywords': 'verifier, log, refactor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 46862ee854b4f5a315d63b677ca3af14a89aefeb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 46862ee854b4f5a315d63b677ca3af14a89aefeb + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700336399 + Commit Message: + bpf: emit frameno for PTR_TO_STACK regs if it differs from current one + +It's possible to pass a pointer to parent's stack to child subprogs. In +such case verifier state output is ambiguous not showing whether +register container a pointer to "current" stack + Parent Hashes: 0f8dbdbc641b45a5fa31d497f9fc83ffe1174fa3 + Refs: belonging to current +subprog (frame) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Emit frame number for PTR_TO_STACK registers when it differs from the current frame in eBPF verifier.', 'keywords': 'PTR_TO_STACK,verifier,frame', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0f8dbdbc641b45a5fa31d497f9fc83ffe1174fa3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0f8dbdbc641b45a5fa31d497f9fc83ffe1174fa3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700336399 + Commit Message: + bpf: smarter verifier log number printing logic + +Instead of always printing numbers as either decimals (and in some +cases + Parent Hashes: 1db747d75b1dbe17bf4283ed87bd3b7a92010f34 + Refs: like for "imm=%llx" + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve verifier log number printing logic for better readability and understanding.', 'keywords': 'verifier,log,printing', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1db747d75b1dbe17bf4283ed87bd3b7a92010f34 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1db747d75b1dbe17bf4283ed87bd3b7a92010f34 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700336399 + Commit Message: + bpf: omit default off=0 and imm=0 in register state log + +Simplify BPF verifier log further by omitting default (and frequently +irrelevant) off=0 and imm=0 parts for non-SCALAR_VALUE registers. As can +be seen from fixed tests + Parent Hashes: 0c95c9fdb696f35c7864785ba84cb9a50152daff + Refs: this is often a visual noise for PTR_TO_CTX +register and even for PTR_TO_PACKET registers. + +Omitting default values follows the rest of register state logic: we +omit default values to keep verifier log succinct and to highlight +interesting state that deviates from default one. E.g. + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Simplified BPF verifier log by omitting default off=0 and imm=0 for non-SCALAR_VALUE registers.', 'keywords': 'BPF verifier, default, registers', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0c95c9fdb696f35c7864785ba84cb9a50152daff +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0c95c9fdb696f35c7864785ba84cb9a50152daff + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700336399 + Commit Message: + bpf: emit map name in register state if applicable and available + +In complicated real-world applications + Parent Hashes: 67d43dfbb42d6575304daea67733c88fbf536a1c + Refs: whenever debugging some +verification error through verifier log + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Emit the map name in the register state for better debugging in verifier logs.', 'keywords': 'map name, register state, verifier', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 67d43dfbb42d6575304daea67733c88fbf536a1c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 67d43dfbb42d6575304daea67733c88fbf536a1c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700336399 + Commit Message: + bpf: print spilled register state in stack slot + +Print the same register state representation when printing stack state + Parent Hashes: 009f5465be3636e9ce795cfbd5d3109d8978774d + Refs: +as we do for normal registers. Note that if stack slot contains +subregister spill (1 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve stack slot state printing in bpf to match register state representation.', 'keywords': 'register, printing, stack', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 009f5465be3636e9ce795cfbd5d3109d8978774d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 009f5465be3636e9ce795cfbd5d3109d8978774d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700336399 + Commit Message: + bpf: extract register state printing + +Extract printing register state representation logic into a separate +helper + Parent Hashes: 42feb6620accded89cad5f455665e21281813d79 + Refs: as we are going to reuse it for spilled register state printing +in the next patch. This also nicely reduces code nestedness. + +No functional changes. + +Acked-by: Eduard Zingerman +Acked-by: Stanislav Fomichev +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231118034623.3320920-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extract register state printing logic into a helper for reuse and code clarity.', 'keywords': 'printing, helper, state', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 42feb6620accded89cad5f455665e21281813d79 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 42feb6620accded89cad5f455665e21281813d79 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700336399 + Commit Message: + bpf: move verifier state printing code to kernel/bpf/log.c + +Move a good chunk of code from verifier.c to log.c: verifier state +verbose printing logic. This is an important and very much +logging/debugging oriented code. It fits the overlall log.c's focus on +verifier logging + Parent Hashes: db840d389bad60ce6f3aadc1079da13e7e993a16 + Refs: and moving it allows to keep growing it without +unnecessarily adding to verifier.c code that otherwise contains a core +verification logic. + +There are not many shared dependencies between this code and the rest of +verifier.c code + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor verifier state verbose printing logic from verifier.c to log.c to improve focus on verifier logging without adding complexity.', 'keywords': 'verifier, logging, refactor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: db840d389bad60ce6f3aadc1079da13e7e993a16 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: db840d389bad60ce6f3aadc1079da13e7e993a16 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700336398 + Commit Message: + bpf: move verbose_linfo() into kernel/bpf/log.c + +verifier.c is huge. Let's try to move out parts that are logging-related +into log.c + Parent Hashes: ff8867af01daa7ea770bebf5f91199b7434b74e5 + Refs: as we previously did with bpf_log() and other related stuff. +This patch moves line info verbose output routines: it's pretty +self-contained and isolated code + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Moved verbose logging functions from verifier.c to log.c to reduce file size.', 'keywords': 'verbose logging, log, bpf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ff8867af01daa7ea770bebf5f91199b7434b74e5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ff8867af01daa7ea770bebf5f91199b7434b74e5 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700245802 + Commit Message: + bpf: rename BPF_F_TEST_SANITY_STRICT to BPF_F_TEST_REG_INVARIANTS + +Rename verifier internal flag BPF_F_TEST_SANITY_STRICT to more neutral +BPF_F_TEST_REG_INVARIANTS. This is a follow up to [0]. + +A few selftests and veristat need to be adjusted in the same patch as +well. + + [0] https://patchwork.kernel.org/project/netdevbpf/patch/20231112010609.848406-5-andrii@kernel.org/ + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231117171404.225508-1-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 5fa201f37c2ef58a0f821e656d794af89b3a1738 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit renames an internal verifier flag and updates related selftests and veristat.', 'keywords': 'rename, verifier, flag', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e9cdebbe23f1aa9a1caea169862f479ab3fa2773 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e9cdebbe23f1aa9a1caea169862f479ab3fa2773 + Author Name: Jordan Rife + Author Email: jrife@google.com + Commit Date: 1700157522 + Commit Message: + dlm: use kernel_connect() and kernel_bind() + +Recent changes to kernel_connect() and kernel_bind() ensure that +callers are insulated from changes to the address parameter made by BPF +SOCK_ADDR hooks. This patch wraps direct calls to ops->connect() and +ops->bind() with kernel_connect() and kernel_bind() to protect callers +in such cases. + +Link: https://lore.kernel.org/netdev/9944248dba1bce861375fcce9de663934d933ba9.camel@redhat.com/ +Fixes: d74bad4e74ee ("bpf: Hooks for sys_connect") +Fixes: 4fbac77d2d09 ("bpf: Hooks for sys_bind") +Cc: stable@vger.kernel.org +Signed-off-by: Jordan Rife +Signed-off-by: David Teigland + + Parent Hashes: b85ea95d086471afb4ad062012a4d73cd328fa86 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Wraps direct calls to connect and bind operations with kernel_connect and kernel_bind for address parameter protection.', 'keywords': 'kernel_connect,kernel_bind,BPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7475e51b87969e01a6812eac713a1c8310372e8a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7475e51b87969e01a6812eac713a1c8310372e8a + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1700139086 + Commit Message: + Merge tag 'net-6.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + "Including fixes from BPF and netfilter. + + Current release - regressions: + + - core: fix undefined behavior in netdev name allocation + + - bpf: do not allocate percpu memory at init stage + + - netfilter: nf_tables: split async and sync catchall in two + functions + + - mptcp: fix possible NULL pointer dereference on close + + Current release - new code bugs: + + - eth: ice: dpll: fix initial lock status of dpll + + Previous releases - regressions: + + - bpf: fix precision backtracking instruction iteration + + - af_unix: fix use-after-free in unix_stream_read_actor() + + - tipc: fix kernel-infoleak due to uninitialized TLV value + + - eth: bonding: stop the device in bond_setup_by_slave() + + - eth: mlx5: + - fix double free of encap_header + - avoid referencing skb after free-ing in drop path + + - eth: hns3: fix VF reset + + - eth: mvneta: fix calls to page_pool_get_stats + + Previous releases - always broken: + + - core: set SOCK_RCU_FREE before inserting socket into hashtable + + - bpf: fix control-flow graph checking in privileged mode + + - eth: ppp: limit MRU to 64K + + - eth: stmmac: avoid rx queue overrun + + - eth: icssg-prueth: fix error cleanup on failing initialization + + - eth: hns3: fix out-of-bounds access may occur when coalesce info is + read via debugfs + + - eth: cortina: handle large frames + + Misc: + + - selftests: gso: support CONFIG_MAX_SKB_FRAGS up to 45" + +* tag 'net-6.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (78 commits) + macvlan: Don't propagate promisc change to lower dev in passthru + net: sched: do not offload flows with a helper in act_ct + net/mlx5e: Check return value of snprintf writing to fw_version buffer for representors + net/mlx5e: Check return value of snprintf writing to fw_version buffer + net/mlx5e: Reduce the size of icosq_str + net/mlx5: Increase size of irq name buffer + net/mlx5e: Update doorbell for port timestamping CQ before the software counter + net/mlx5e: Track xmit submission to PTP WQ after populating metadata map + net/mlx5e: Avoid referencing skb after free-ing in drop path of mlx5e_sq_xmit_wqe + net/mlx5e: Don't modify the peer sent-to-vport rules for IPSec offload + net/mlx5e: Fix pedit endianness + net/mlx5e: fix double free of encap_header in update funcs + net/mlx5e: fix double free of encap_header + net/mlx5: Decouple PHC .adjtime and .adjphase implementations + net/mlx5: DR + Parent Hashes: 6eb1acd9766a0dc9d85927843d85787408395e15 cff088d924df871296412e6b819823f42d1bb9a5 + Refs: Allow old devices to use multi destination FTE + net/mlx5: Free used cpus mask when an IRQ is released + Revert "net/mlx5: DR + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit merges networking fixes including BPF, netfilter, and other network driver issues.', 'keywords': 'networking, fixes, BPF', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a6a6a0a9fdb03af10513b5bb48e5419563f54413 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a6a6a0a9fdb03af10513b5bb48e5419563f54413 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1700116082 + Commit Message: + Merge https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Alexei Starovoitov says: + +==================== +pull-request: bpf 2023-11-15 + +We've added 7 non-merge commits during the last 6 day(s) which contain +a total of 9 files changed + Parent Hashes: 674e318089468ece99aef4796eaef7add57f36b2 1fda5bb66ad8fb24ecb3858e61a13a6548428898 + Refs: 200 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge pull request integrating 7 non-merge commits into BPF tree.', 'keywords': 'merge,BPF,commits', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5fa201f37c2ef58a0f821e656d794af89b3a1738 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5fa201f37c2ef58a0f821e656d794af89b3a1738 + Author Name: Puranjay Mohan + Author Email: puranjay12@gmail.com + Commit Date: 1700081187 + Commit Message: + bpf: Remove test for MOVSX32 with offset=32 + +MOVSX32 only supports sign extending 8-bit and 16-bit operands into 32 +bit operands. The "ALU_MOVSX | BPF_W" test tries to sign extend a 32 bit +operand into a 32 bit operand which is equivalent to a normal BPF_MOV. + +Remove this test as it tries to run an invalid instruction. + +Fixes: daabb2b098e0 ("bpf/tests: add tests for cpuv4 instructions") +Signed-off-by: Puranjay Mohan +Reported-by: kernel test robot +Closes: https://lore.kernel.org/oe-lkp/202310111838.46ff5b6a-oliver.sang@intel.com +Acked-by: Stanislav Fomichev +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231110175150.87803-1-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 9cea90c01f4bddfb4cea12a9c23eef6414714503 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed a test for an invalid MOVSX32 instruction with offset in BPF.', 'keywords': 'MOVSX32, test, invalid', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9cea90c01f4bddfb4cea12a9c23eef6414714503 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9cea90c01f4bddfb4cea12a9c23eef6414714503 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1700078623 + Commit Message: + Merge branch 'bpf-register-bounds-range-vs-range-support' + +Andrii Nakryiko says: + +==================== +BPF register bounds range vs range support + +This patch set is a continuation of work started in [0]. It adds a big set of +manual + Parent Hashes: 81427a62a22148cdc85db38a6fbe487d0d2044b6 882e3d873c2d8a2aebbc6c192aa1a2990b9d5b27 + Refs: auto-generated + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merges changes related to BPF register bounds and range support.', 'keywords': 'register bounds,range support,merge', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 882e3d873c2d8a2aebbc6c192aa1a2990b9d5b27 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 882e3d873c2d8a2aebbc6c192aa1a2990b9d5b27 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078623 + Commit Message: + selftests/bpf: add iter test requiring range x range logic + +Add a simple verifier test that requires deriving reg bounds for one +register from another register that's not a constant. This is +a realistic example of iterating elements of an array with fixed maximum +number of elements + Parent Hashes: a5c57f81eb2b5d6de4f46e47fd85be50d179bfd8 + Refs: but smaller actual number of elements. + +This small example was an original motivation for doing this whole patch +set in the first place + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a verifier test for range x range logic in selftests for BPF.', 'keywords': 'verifier,test,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8c5677f8b31e92b57be7d5d0fbb1ac66eedf4f91 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8c5677f8b31e92b57be7d5d0fbb1ac66eedf4f91 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + selftests/bpf: set BPF_F_TEST_SANITY_SCRIPT by default + +Make sure to set BPF_F_TEST_SANITY_STRICT program flag by default across +most verifier tests (and a bunch of others that set custom prog flags). + +There are currently two tests that do fail validation + Parent Hashes: dab16659c50e8c9c7c5d9584beacec28c769dcca + Refs: if enforced +strictly: verifier_bounds/crossing_64_bit_signed_boundary_2 and +verifier_bounds/crossing_32_bit_signed_boundary_2. To accommodate them + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Default BPF_F_TEST_SANITY_STRICT flag across most verifier tests, except for two specific cases.', 'keywords': 'verifier, tests, flag', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dab16659c50e8c9c7c5d9584beacec28c769dcca +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dab16659c50e8c9c7c5d9584beacec28c769dcca + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + selftests/bpf: add randomized reg_bounds tests + +Add random cases generation to reg_bounds.c and run them without +SLOW_TESTS=1 to increase a chance of BPF CI catching latent issues. + +Suggested-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231112010609.848406-11-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 2b0d204e368b306d4db894749947ed591b667ec5 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add randomized test case generation to reg_bounds.c for better BPF CI coverage.', 'keywords': 'randomized,reg_bounds,tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2b0d204e368b306d4db894749947ed591b667ec5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2b0d204e368b306d4db894749947ed591b667ec5 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + selftests/bpf: add range x range test to reg_bounds + +Now that verifier supports range vs range bounds adjustments + Parent Hashes: 774f94c5e74d86d554c4fd1e97c517a1a7ee7fe0 + Refs: validate +that by checking each generated range against every other generated +range + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a new range x range test case for reg_bounds in selftests to verify new verifier support.', 'keywords': 'range,test,verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 774f94c5e74d86d554c4fd1e97c517a1a7ee7fe0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 774f94c5e74d86d554c4fd1e97c517a1a7ee7fe0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + selftests/bpf: adjust OP_EQ/OP_NE handling to use subranges for branch taken + +Similar to kernel-side BPF verifier logic enhancements + Parent Hashes: 8863238993e23ccc6d5a9d4ff9f1c043f88f692e + Refs: use 32-bit +subrange knowledge for is_branch_taken() logic in reg_bounds selftests. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231112010609.848406-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adjusted BPF selftests to use subrange logic for branch conditions similar to kernel verifier.', 'keywords': 'BPF selftests, subrange logic, verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8863238993e23ccc6d5a9d4ff9f1c043f88f692e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8863238993e23ccc6d5a9d4ff9f1c043f88f692e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + selftests/bpf: BPF register range bounds tester + +Add test to validate BPF verifier's register range bounds tracking logic. + +The main bulk is a lot of auto-generated tests based on a small set of +seed values for lower and upper 32 bits of full 64-bit values. +Currently we validate only range vs const comparisons + Parent Hashes: cf5fe3c71c5a34ac0108afc550407c672d0a032d + Refs: but the idea is +to start validating range over range comparisons in subsequent patch set. + +When setting up initial register ranges we treat registers as one of +u64/s64/u32/s32 numeric types + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest for BPF verifier to test register range bounds logic.', 'keywords': 'selftests, BPF, verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cf5fe3c71c5a34ac0108afc550407c672d0a032d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cf5fe3c71c5a34ac0108afc550407c672d0a032d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + bpf: make __reg{32 + Parent Hashes: 3cf98cf594ea923b8b1e0385b580d3d8aae68c06 + Refs: 64}_deduce_bounds logic more robust + +This change doesn't seem to have any effect on selftests and production +BPF object files + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances the __reg{32, 64}_deduce_bounds logic for robustness without affecting existing tests and BPF object files.', 'keywords': 'robustness, deduction, logic', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3cf98cf594ea923b8b1e0385b580d3d8aae68c06 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3cf98cf594ea923b8b1e0385b580d3d8aae68c06 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + bpf: remove redundant s{32 + Parent Hashes: 5f99f312bd3bedb3b266b0d26376a8c500cdc97f + Refs: 64} -> u{32 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes redundant code by replacing s32 with u32.', 'keywords': 'remove,redundant,replace', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 5f99f312bd3bedb3b266b0d26376a8c500cdc97f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5f99f312bd3bedb3b266b0d26376a8c500cdc97f + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + bpf: add register bounds sanity checks and sanitization + +Add simple sanity checks that validate well-formed ranges (min <= max) +across u64 + Parent Hashes: be41a203bb9e0159099e189e510388fe61962eb8 + Refs: s64 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add sanity checks for register bounds to ensure well-formed ranges in u64.', 'keywords': 'sanity, register, bounds', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: be41a203bb9e0159099e189e510388fe61962eb8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: be41a203bb9e0159099e189e510388fe61962eb8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078622 + Commit Message: + bpf: enhance BPF_JEQ/BPF_JNE is_branch_taken logic + +Use 32-bit subranges to prune some 64-bit BPF_JEQ/BPF_JNE conditions +that otherwise would be "inconclusive" (i.e. + Parent Hashes: 96381879a370425a30b810906946f64c0726450e + Refs: is_branch_taken() would +return -1). This can happen + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance the is_branch_taken logic for BPF_JEQ/BPF_JNE using 32-bit subranges to handle inconclusive conditions more effectively.', 'keywords': 'BPF_JEQ,subranges,inconclusive', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 96381879a370425a30b810906946f64c0726450e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 96381879a370425a30b810906946f64c0726450e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078621 + Commit Message: + bpf: generalize is_scalar_branch_taken() logic + +Generalize is_branch_taken logic for SCALAR_VALUE register to handle +cases when both registers are not constants. Previously supported + vs cases are a natural subset of more generic +vs set of cases. + +Generalized logic relies on straightforward segment intersection checks. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: Shung-Hsi Yu +Link: https://lore.kernel.org/r/20231112010609.848406-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 67420501e8681ae18f9f0ea0a69cd2f432100e70 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Generalize SCALAR_VALUE branch logic to handle non-constant registers in the eBPF verifier.', 'keywords': 'generalize, SCALAR_VALUE, verifier', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 67420501e8681ae18f9f0ea0a69cd2f432100e70 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 67420501e8681ae18f9f0ea0a69cd2f432100e70 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1700078621 + Commit Message: + bpf: generalize reg_set_min_max() to handle non-const register comparisons + +Generalize bounds adjustment logic of reg_set_min_max() to handle not +just register vs constant case + Parent Hashes: 81427a62a22148cdc85db38a6fbe487d0d2044b6 + Refs: but in general any register vs any +register cases. For most of the operations it's trivial extension based +on range vs range comparison logic + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Generalize reg_set_min_max() to handle register comparisons beyond constant comparisons in BPF.', 'keywords': 'generalize, reg_set_min_max, register', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1fda5bb66ad8fb24ecb3858e61a13a6548428898 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1fda5bb66ad8fb24ecb3858e61a13a6548428898 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1700063466 + Commit Message: + bpf: Do not allocate percpu memory at init stage + +Kirill Shutemov reported significant percpu memory consumption increase after +booting in 288-cpu VM ([1]) due to commit 41a5db8d8161 ("bpf: Add support for +non-fix-size percpu mem allocation"). The percpu memory consumption is +increased from 111MB to 969MB. The number is from /proc/meminfo. + +I tried to reproduce the issue with my local VM which at most supports upto +255 cpus. With 252 cpus + Parent Hashes: e2e57d637aa5da0a2f49d83ad44e9febf95df7b4 + Refs: without the above commit + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit addresses excessive percpu memory usage by avoiding allocation at the initialization stage.', 'keywords': 'percpu, memory, optimization', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 81427a62a22148cdc85db38a6fbe487d0d2044b6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 81427a62a22148cdc85db38a6fbe487d0d2044b6 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1699981183 + Commit Message: + Merge branch 'bpf-add-support-for-cgroup1-bpf-part' + +Yafang Shao says: + +==================== +bpf: Add support for cgroup1 + Parent Hashes: 727a92d62fd6a382b4c5972008e45667e707b0e4 360769233cc9c921e90ae387d167ea3cd3cbb04c + Refs: BPF part + +This is the BPF part of the series "bpf + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for cgroup1 in BPF subsystem.', 'keywords': 'support,cgroup1,BPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 360769233cc9c921e90ae387d167ea3cd3cbb04c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 360769233cc9c921e90ae387d167ea3cd3cbb04c + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1699981163 + Commit Message: + selftests/bpf: Add selftests for cgroup1 hierarchy + +Add selftests for cgroup1 hierarchy. +The result as follows + Parent Hashes: bf47300b186facc8ae66a0e2aa89073565f82bb3 + Refs: + + $ tools/testing/selftests/bpf/test_progs --name=cgroup1_hierarchy + #36/1 cgroup1_hierarchy/test_cgroup1_hierarchy:OK + #36/2 cgroup1_hierarchy/test_root_cgid:OK + #36/3 cgroup1_hierarchy/test_invalid_level:OK + #36/4 cgroup1_hierarchy/test_invalid_cgid:OK + #36/5 cgroup1_hierarchy/test_invalid_hid:OK + #36/6 cgroup1_hierarchy/test_invalid_cgrp_name:OK + #36/7 cgroup1_hierarchy/test_invalid_cgrp_name2:OK + #36/8 cgroup1_hierarchy/test_sleepable_prog:OK + #36 cgroup1_hierarchy:OK + Summary: 1/8 PASSED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds selftests for the cgroup1 hierarchy in the BPF selftests.', 'keywords': 'selftests,cgroup1,hierarchy', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: bf47300b186facc8ae66a0e2aa89073565f82bb3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bf47300b186facc8ae66a0e2aa89073565f82bb3 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1699981016 + Commit Message: + selftests/bpf: Add a new cgroup helper get_cgroup_hierarchy_id() + +A new cgroup helper function + Parent Hashes: c1dcc050aa648bb3b831030d547c3fcc1c68140c + Refs: get_cgroup1_hierarchy_id() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces a new cgroup helper function for obtaining cgroup hierarchy ID in selftests.', 'keywords': 'cgroup, helper function, selftests', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: c1dcc050aa648bb3b831030d547c3fcc1c68140c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c1dcc050aa648bb3b831030d547c3fcc1c68140c + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1699981016 + Commit Message: + selftests/bpf: Add a new cgroup helper get_classid_cgroup_id() + +Introduce a new helper function to retrieve the cgroup ID from a net_cls +cgroup directory. + +Signed-off-by: Yafang Shao +Link: https://lore.kernel.org/r/20231111090034.4248-5-laoar.shao@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: f744d35ecf46f111bf9b54bfdbc89a28ee8b928a + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce a new helper function to retrieve the cgroup ID from a net_cls cgroup directory in selftests/bpf.', 'keywords': 'cgroup, helper, ID', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: f744d35ecf46f111bf9b54bfdbc89a28ee8b928a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f744d35ecf46f111bf9b54bfdbc89a28ee8b928a + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1699981016 + Commit Message: + selftests/bpf: Add parallel support for classid + +Include the current pid in the classid cgroup path. This way + Parent Hashes: 4849775587844e44d215289c425bcd70f315efe7 + Refs: different +testers relying on classid-based configurations will have distinct classid +cgroup directories + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add parallel support for classid by including current pid in cgroup path for distinct configurations.', 'keywords': 'parallel,classid,cgroup', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 4849775587844e44d215289c425bcd70f315efe7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4849775587844e44d215289c425bcd70f315efe7 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1699981016 + Commit Message: + selftests/bpf: Fix issues in setup_classid_environment() + +If the net_cls subsystem is already mounted + Parent Hashes: fe977716b40cb98cf9c91a66454adf3dc2f8c59a + Refs: attempting to mount it again +in setup_classid_environment() will result in a failure with the error code +EBUSY. Despite this + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix issues in setup_classid_environment by handling EBUSY error when net_cls is already mounted in selftests.', 'keywords': 'selftests,bpf,setup_classid_environment', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: fe977716b40cb98cf9c91a66454adf3dc2f8c59a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fe977716b40cb98cf9c91a66454adf3dc2f8c59a + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1699981016 + Commit Message: + bpf: Add a new kfunc for cgroup1 hierarchy + +A new kfunc is added to acquire cgroup1 of a task: + +- bpf_task_get_cgroup1 + Acquires the associated cgroup of a task whithin a specific cgroup1 + hierarchy. The cgroup1 hierarchy is identified by its hierarchy ID. + +This new kfunc enables the tracing of tasks within a designated +container or cgroup directory in BPF programs. + +Suggested-by: Tejun Heo +Signed-off-by: Yafang Shao +Acked-by: Tejun Heo +Link: https://lore.kernel.org/r/20231111090034.4248-2-laoar.shao@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 727a92d62fd6a382b4c5972008e45667e707b0e4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'A new kfunc for acquiring cgroup1 hierarchy of a task is added to BPF.', 'keywords': 'kfunc,cgroup1,task', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 727a92d62fd6a382b4c5972008e45667e707b0e4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 727a92d62fd6a382b4c5972008e45667e707b0e4 + Author Name: Jordan Rome + Author Email: linux@jordanrome.com + Commit Date: 1699929578 + Commit Message: + selftests/bpf: Add assert for user stacks in test_task_stack + +This is a follow up to: +commit b8e3a87a627b ("bpf: Add crosstask check to __bpf_get_stack"). + +This test ensures that the task iterator only gets a single +user stack (for the current task). + +Signed-off-by: Jordan Rome +Signed-off-by: Andrii Nakryiko +Acked-by: Stanislav Fomichev +Link: https://lore.kernel.org/bpf/20231112023010.144675-1-linux@jordanrome.com + + Parent Hashes: 100888fb6d8a185866b1520031ee7e3182b173de + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add assertion for user stack checks in BPF selftests.', 'keywords': 'selftests, BPF, user stack', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 4eeee6636af819454d7c43702e77ec7857a63000 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4eeee6636af819454d7c43702e77ec7857a63000 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1699815488 + Commit Message: + Merge tag 'loongarch-6.7' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson + +Pull LoongArch updates from Huacai Chen: + + - support PREEMPT_DYNAMIC with static keys + + - relax memory ordering for atomic operations + + - support BPF CPU v4 instructions for LoongArch + + - some build and runtime warning fixes + +* tag 'loongarch-6.7' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson: + selftests/bpf: Enable cpu v4 tests for LoongArch + LoongArch: BPF: Support signed mod instructions + LoongArch: BPF: Support signed div instructions + LoongArch: BPF: Support 32-bit offset jmp instructions + LoongArch: BPF: Support unconditional bswap instructions + LoongArch: BPF: Support sign-extension mov instructions + LoongArch: BPF: Support sign-extension load instructions + LoongArch: Add more instruction opcodes and emit_* helpers + LoongArch/smp: Call rcutree_report_cpu_starting() earlier + LoongArch: Relax memory ordering for atomic operations + LoongArch: Mark __percpu functions as always inline + LoongArch: Disable module from accessing external data directly + LoongArch: Support PREEMPT_DYNAMIC with static keys + + Parent Hashes: 5dd2020f335a7a60c154375a168791a2b87f35b5 1d375d65466e5c8d7a9406826d80d475a22e8c6d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge LoongArch updates to support new BPF CPU instructions, PREEMPT_DYNAMIC with static keys, and fix build warnings.', 'keywords': 'LoongArch,BPF instructions,PREEMPT_DYNAMIC', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 100888fb6d8a185866b1520031ee7e3182b173de +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 100888fb6d8a185866b1520031ee7e3182b173de + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1699733890 + Commit Message: + selftests/bpf: Fix pyperf180 compilation failure with clang18 + +With latest clang18 (main branch of llvm-project repo) + Parent Hashes: b8e3a87a627b575896e448021e5c2f8a3bc19931 + Refs: when building bpf selftests + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a compilation failure in BPF selftests with pyperf180 using clang18.', 'keywords': 'fix, pyperf180, clang18', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b8e3a87a627b575896e448021e5c2f8a3bc19931 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b8e3a87a627b575896e448021e5c2f8a3bc19931 + Author Name: Jordan Rome + Author Email: jordalgo@meta.com + Commit Date: 1699643170 + Commit Message: + bpf: Add crosstask check to __bpf_get_stack + +Currently get_perf_callchain only supports user stack walking for +the current task. Passing the correct *crosstask* param will return +0 frames if the task passed to __bpf_get_stack isn't the current +one instead of a single incorrect frame/address. This change +passes the correct *crosstask* param but also does a preemptive +check in __bpf_get_stack if the task is current and returns +-EOPNOTSUPP if it is not. + +This issue was found using bpf_get_task_stack inside a BPF +iterator ("iter/task") + Parent Hashes: 92411764e3106f38ac815d2fb1ae011e7bbe2abc + Refs: which iterates over all tasks. +bpf_get_task_stack works fine for fetching kernel stacks +but because get_perf_callchain relies on the caller to know +if the requested *task* is the current one (via *crosstask*) +it was failing in a confusing way. + +It might be possible to get user stacks for all tasks utilizing +something like access_process_vm but that requires the bpf +program calling bpf_get_task_stack to be sleepable and would +therefore be a breaking change. + +Fixes: fa28dcb82a38 ("bpf: Introduce helper bpf_get_task_stack()") +Signed-off-by: Jordan Rome +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231108112334.3433136-1-jordalgo@meta.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add crosstask parameter check to bpf_get_task_stack for accurate user stack walking.', 'keywords': 'crosstask, __bpf_get_stack, user stack', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 92411764e3106f38ac815d2fb1ae011e7bbe2abc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 92411764e3106f38ac815d2fb1ae011e7bbe2abc + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1699635733 + Commit Message: + Merge branch 'for-6.8-bpf' of https://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup into bpf-next + +Merge cgroup prerequisite patches. + +Link: https://lore.kernel.org/bpf/20231029061438.4215-1-laoar.shao@gmail.com/ + +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 689b097a06bafb461ec162fc3b3ecc9765cea67b aecd408b7e50742868b3305c24325a89024e2a30 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merged cgroup prerequisite patches from branch 'for-6.8-bpf'.", 'keywords': 'merge,cgroup,prerequisite', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 689b097a06bafb461ec162fc3b3ecc9765cea67b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 689b097a06bafb461ec162fc3b3ecc9765cea67b + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1699631599 + Commit Message: + compiler-gcc: Suppress -Wmissing-prototypes warning for all supported GCC + +The kernel supports a minimum GCC version of 5.1.0 for building. However + Parent Hashes: 155addf0814a92d08fce26a11b27e3315cdba977 + Refs: +the "__diag_ignore_all" directive only suppresses the +"-Wmissing-prototypes" warning for GCC versions >= 8.0.0. As a result + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Suppress -Wmissing-prototypes warning for all supported GCC versions in the kernel build system.', 'keywords': 'suppress, GCC, warnings', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 871019b22d1bcc9fab2d1feba1b9a564acbb6e99 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 871019b22d1bcc9fab2d1feba1b9a564acbb6e99 + Author Name: Stanislav Fomichev + Author Email: sdf@google.com + Commit Date: 1699605429 + Commit Message: + net: set SOCK_RCU_FREE before inserting socket into hashtable + +We've started to see the following kernel traces: + + WARNING: CPU: 83 PID: 0 at net/core/filter.c:6641 sk_lookup+0x1bd/0x1d0 + + Call Trace: + + __bpf_skc_lookup+0x10d/0x120 + bpf_sk_lookup+0x48/0xd0 + bpf_sk_lookup_tcp+0x19/0x20 + bpf_prog_+0x37c/0x16a3 + cls_bpf_classify+0x205/0x2e0 + tcf_classify+0x92/0x160 + __netif_receive_skb_core+0xe52/0xf10 + __netif_receive_skb_list_core+0x96/0x2b0 + napi_complete_done+0x7b5/0xb70 + _poll+0x94/0xb0 + net_rx_action+0x163/0x1d70 + __do_softirq+0xdc/0x32e + asm_call_irq_on_stack+0x12/0x20 + + do_softirq_own_stack+0x36/0x50 + do_softirq+0x44/0x70 + +__inet_hash can race with lockless (rcu) readers on the other cpus: + + __inet_hash + __sk_nulls_add_node_rcu + <- (bpf triggers here) + sock_set_flag(SOCK_RCU_FREE) + +Let's move the SOCK_RCU_FREE part up a bit + Parent Hashes: 8a4f030dbced6fc255cbe67b2d0a129947e18493 + Refs: before we are inserting +the socket into hashtables. Note + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Set SOCK_RCU_FREE before inserting socket into hashtable to prevent kernel trace warnings.', 'keywords': 'SOCK_RCU_FREE, socket, hashtable', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: e2e57d637aa5da0a2f49d83ad44e9febf95df7b4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e2e57d637aa5da0a2f49d83ad44e9febf95df7b4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699599445 + Commit Message: + selftests/bpf: add more test cases for check_cfg() + +Add a few more simple cases to validate proper privileged vs unprivileged +loop detection behavior. conditional_loop2 is the one reported by Hao +Sun that triggered this set of fixes. + +Acked-by: Eduard Zingerman +Suggested-by: Hao Sun +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231110061412.2995786-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 10e14e9652bf9e8104151bfd9200433083deae3d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add more test cases for privileged vs unprivileged loop detection in BPF selftests.', 'keywords': 'selftests,bpf,loop', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 10e14e9652bf9e8104151bfd9200433083deae3d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 10e14e9652bf9e8104151bfd9200433083deae3d + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699599444 + Commit Message: + bpf: fix control-flow graph checking in privileged mode + +When BPF program is verified in privileged mode + Parent Hashes: 8c74b27f4b30cd896ccf387102410a65b4a35c25 + Refs: BPF verifier allows +bounded loops. This means that from CFG point of view there are +definitely some back-edges. Original commit adjusted check_cfg() logic +to not detect back-edges in control flow graph if they are resulting +from conditional jumps + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes control-flow graph checking for BPF programs in privileged mode by adjusting treatment of back-edges from conditional jumps.', 'keywords': 'control-flow, privileged, back-edges', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8c74b27f4b30cd896ccf387102410a65b4a35c25 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8c74b27f4b30cd896ccf387102410a65b4a35c25 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1699589480 + Commit Message: + Merge branch 'bpf-control-flow-graph-and-precision-backtrack-fixes' + +Andrii Nakryiko says: + +==================== +BPF control flow graph and precision backtrack fixes + +A small fix to BPF verifier's CFG logic around handling and reporting ldimm64 +instructions. Patch #1 was previously submitted separately ([0]) + Parent Hashes: fe69a1b1b6ed9ffc2c578c63f526026a8ab74f0c 62ccdb11d3c63dc697dea1fd92b3496fe43dcc1e + Refs: and so this +patch set supersedes that patch. + +Second patch is fixing obscure corner case in mark_chain_precise() logic. See +patch for details. Patch #3 adds a dedicated test + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit merges fixes for BPF verifier's control flow graph and precision backtracking logic.", 'keywords': 'BPF verifier, control flow, fixes', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 62ccdb11d3c63dc697dea1fd92b3496fe43dcc1e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 62ccdb11d3c63dc697dea1fd92b3496fe43dcc1e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699589480 + Commit Message: + selftests/bpf: add edge case backtracking logic test + +Add a dedicated selftests to try to set up conditions to have a state +with same first and last instruction index + Parent Hashes: 4bb7ea946a370707315ab774432963ce47291946 + Refs: but it actually is a loop +3->4->1->2->3. This confuses mark_chain_precision() if verifier doesn't +take into account jump history. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231110002638.4168352-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a selftest to verify edge case handling in eBPF verifier regarding jump history and state consistency.', 'keywords': 'selftest, edge case, verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4bb7ea946a370707315ab774432963ce47291946 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4bb7ea946a370707315ab774432963ce47291946 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699589480 + Commit Message: + bpf: fix precision backtracking instruction iteration + +Fix an edge case in __mark_chain_precision() which prematurely stops +backtracking instructions in a state if it happens that state's first +and last instruction indexes are the same. This situations doesn't +necessarily mean that there were no instructions simulated in a state + Parent Hashes: 3feb263bb516ee7e1da0acd22b15afbb9a7daa19 + Refs: +but rather that we starting from the instruction + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Fixes an edge case in the bpf verifier's precision backtracking logic.", 'keywords': 'precision, backtracking, edge case', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3feb263bb516ee7e1da0acd22b15afbb9a7daa19 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3feb263bb516ee7e1da0acd22b15afbb9a7daa19 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699589480 + Commit Message: + bpf: handle ldimm64 properly in check_cfg() + +ldimm64 instructions are 16-byte long + Parent Hashes: fe69a1b1b6ed9ffc2c578c63f526026a8ab74f0c + Refs: and so have to be handled +appropriately in check_cfg() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix handling of ldimm64 instructions in check_cfg function for proper configuration checks.', 'keywords': 'ldimm64,check_cfg,instructions', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fe69a1b1b6ed9ffc2c578c63f526026a8ab74f0c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fe69a1b1b6ed9ffc2c578c63f526026a8ab74f0c + Author Name: Anders Roxell + Author Email: anders.roxell@linaro.org + Commit Date: 1699586292 + Commit Message: + selftests: bpf: xskxceiver: ksft_print_msg: fix format type error + +Crossbuilding selftests/bpf for architecture arm64 + Parent Hashes: 89cdf9d556016a54ff6ddd62324aa5ec790c05cc + Refs: format specifies +type error show up like. + +xskxceiver.c:912:34: error: format specifies type 'int' but the argument +has type '__u64' (aka 'unsigned long long') [-Werror + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a format type error in the ksft_print_msg function of the xskxceiver selftest for arm64 architecture.', 'keywords': 'format, ksft_print_msg, xskxceiver', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 155addf0814a92d08fce26a11b27e3315cdba977 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 155addf0814a92d08fce26a11b27e3315cdba977 + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1699585672 + Commit Message: + bpf: Use named fields for certain bpf uapi structs + +Martin and Vadim reported a verifier failure with bpf_dynptr usage. +The issue is mentioned but Vadim workarounded the issue with source +change ([1]). The below describes what is the issue and why there +is a verification failure. + + int BPF_PROG(skb_crypto_setup) { + struct bpf_dynptr algo + Parent Hashes: 3f6d04d742d9fbd492a79e28e7cfe4e2a97c66e5 + Refs: key; + ... + + bpf_dynptr_from_mem(... + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a verifier failure by using named fields in certain bpf uapi structs.', 'keywords': 'verifier failure, bpf_dynptr, uapi structs', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3f6d04d742d9fbd492a79e28e7cfe4e2a97c66e5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3f6d04d742d9fbd492a79e28e7cfe4e2a97c66e5 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1699585672 + Commit Message: + Merge branch 'allow-bpf_refcount_acquire-of-mapval-obtained-via-direct-ld' + +Dave Marchevsky says: + +==================== +Allow bpf_refcount_acquire of mapval obtained via direct LD + +Consider this BPF program: + + struct cgv_node { + int d; + struct bpf_refcount r; + struct bpf_rb_node rb; + }; + + struct val_stash { + struct cgv_node __kptr *v; + }; + + struct { + __uint(type + Parent Hashes: 82ce364c6087e31ff9837380a4641a856284064c e9ed8df7187cfdce1075d0ee591544ac15d072f1 + Refs: BPF_MAP_TYPE_ARRAY); + __type(key + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit merges changes to allow bpf_refcount_acquire of map values obtained via direct load.', 'keywords': 'bpf_refcount_acquire,mapval,direct LD', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 82ce364c6087e31ff9837380a4641a856284064c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 82ce364c6087e31ff9837380a4641a856284064c + Author Name: Shung-Hsi Yu + Author Email: shung-hsi.yu@suse.com + Commit Date: 1699585671 + Commit Message: + bpf: replace register_is_const() with is_reg_const() + +The addition of is_reg_const() in commit 171de12646d2 ("bpf: generalize +is_branch_taken to handle all conditional jumps in one place") has made the +register_is_const() redundant. Give the former has more feature + Parent Hashes: 27007fae704eb12547b9b5c7b1005e11640d4f19 + Refs: plus the +fact the latter is only used in one place + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Replaced redundant register_is_const() with is_reg_const() for handling conditional jumps in eBPF.', 'keywords': 'register replacement redundancy', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e9ed8df7187cfdce1075d0ee591544ac15d072f1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e9ed8df7187cfdce1075d0ee591544ac15d072f1 + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1699585671 + Commit Message: + selftests/bpf: Test bpf_refcount_acquire of node obtained via direct ld + +This patch demonstrates that verifier changes earlier in this series +result in bpf_refcount_acquire(mapval->stashed_kptr) passing +verification. The added test additionally validates that stashing a kptr +in mapval and - in a separate BPF program - refcount_acquiring the kptr +without unstashing works as expected at runtime. + +Signed-off-by: Dave Marchevsky +Link: https://lore.kernel.org/r/20231107085639.3016113-7-davemarchevsky@fb.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 1b12171533a9bb23cf6fba7262b479028b65e1e8 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add test for verifier behavior with bpf_refcount_acquire on stashed kptr in selftests.', 'keywords': 'bpf_refcount_acquire,selftests,verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 27007fae704eb12547b9b5c7b1005e11640d4f19 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 27007fae704eb12547b9b5c7b1005e11640d4f19 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585671 + Commit Message: + veristat: add ability to filter top N results + +Add ability to filter top B results + Parent Hashes: 5d4a7aaca1ebcc7c864caec13203662a061c4f4f + Refs: both in replay/verifier mode and +comparison mode. Just adding `-n10` will emit only first 10 rows + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added functionality to filter and display top N results in veristat.', 'keywords': 'veristat,filter,top', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 1b12171533a9bb23cf6fba7262b479028b65e1e8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1b12171533a9bb23cf6fba7262b479028b65e1e8 + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1699585671 + Commit Message: + bpf: Mark direct ld of stashed bpf_{rb + Parent Hashes: 790ce3cfefb1b768dccd4eee324ddef0f0ce3db4 + Refs: list}_node as non-owning ref + +This patch enables the following pattern: + + /* mapval contains a __kptr pointing to refcounted local kptr */ + mapval = bpf_map_lookup_elem(&map + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "This commit marks direct load of stashed bpf_map elements' node as non-owning references for eBPF programs.", 'keywords': 'direct ld, non-owning ref, bpf_map', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 790ce3cfefb1b768dccd4eee324ddef0f0ce3db4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 790ce3cfefb1b768dccd4eee324ddef0f0ce3db4 + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1699585671 + Commit Message: + bpf: Move GRAPH_{ROOT + Parent Hashes: 649924b76ab151a96bdd22a97a993fb0421f134c + Refs: NODE}_MASK macros into btf_field_type enum + +This refactoring patch removes the unused BPF_GRAPH_NODE_OR_ROOT +btf_field_type and moves BPF_GRAPH_{NODE + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors the code by moving certain macros into the btf_field_type enum and removing unused types.', 'keywords': 'refactoring, macros, btf_field_type', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7f7c43693c1b46652cfafb7af67ba31726d6ec4e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7f7c43693c1b46652cfafb7af67ba31726d6ec4e + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1699585671 + Commit Message: + libbpf: Fix potential uninitialized tail padding with LIBBPF_OPTS_RESET + +Martin reported that there is a libbpf complaining of non-zero-value tail +padding with LIBBPF_OPTS_RESET macro if struct bpf_netkit_opts is modified +to have a 4-byte tail padding. This only happens to clang compiler. +The commend line is: ./test_progs -t tc_netkit_multi_links +Martin and I did some investigation and found this indeed the case and +the following are the investigation details. + +Clang: + clang version 18.0.0 + + +tools/lib/bpf/libbpf_common.h: + #define LIBBPF_OPTS_RESET(NAME + Parent Hashes: b0d1c7294671af02369d7a4feaa5a9bb472372c6 + Refs: ...) \ + do { \ + memset(&NAME + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix uninitialized tail padding issue in libbpf when using LIBBPF_OPTS_RESET macro with clang compiler.', 'keywords': 'libbpf, uninitialized, clang', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 649924b76ab151a96bdd22a97a993fb0421f134c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 649924b76ab151a96bdd22a97a993fb0421f134c + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1699585671 + Commit Message: + bpf: Use bpf_mem_free_rcu when bpf_obj_dropping non-refcounted nodes + +The use of bpf_mem_free_rcu to free refcounted local kptrs was added +in commit 7e26cd12ad1c ("bpf: Use bpf_mem_free_rcu when +bpf_obj_dropping refcounted nodes"). In the cover letter for the +series containing that patch [0] I commented: + + Perhaps it makes sense to move to mem_free_rcu for _all_ + non-owning refs in the future + Parent Hashes: f460e7bdb027d1da93f0c5090b239889cd46a33d + Refs: not just refcounted. This might + allow custom non-owning ref lifetime + invalidation logic to be + entirely subsumed by MEM_RCU handling. IMO this needs a bit more + thought and should be tackled outside of a fix series + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Utilize bpf_mem_free_rcu for freeing non-refcounted nodes in bpf_obj_dropping to potentially streamline reference handling.', 'keywords': 'bpf_mem_free_rcu,non-refcounted,nodes', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f460e7bdb027d1da93f0c5090b239889cd46a33d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f460e7bdb027d1da93f0c5090b239889cd46a33d + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1699585671 + Commit Message: + selftests/bpf: Add test passing MAYBE_NULL reg to bpf_refcount_acquire + +The test added in this patch exercises the logic fixed in the previous +patch in this series. Before the previous patch's changes + Parent Hashes: 1500a5d9f49cb66906d3ea1c9158df25cc41dd40 + Refs: +bpf_refcount_acquire accepts MAYBE_NULL local kptrs; after the change +the verifier correctly rejects the such a call. + +Signed-off-by: Dave Marchevsky +Link: https://lore.kernel.org/r/20231107085639.3016113-3-davemarchevsky@fb.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a selftest for bpf_refcount_acquire handling of MAYBE_NULL reg in eBPF.', 'keywords': 'selftest,bpf_refcount_acquire,MAYBE_NULL', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1500a5d9f49cb66906d3ea1c9158df25cc41dd40 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1500a5d9f49cb66906d3ea1c9158df25cc41dd40 + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1699585671 + Commit Message: + bpf: Add KF_RCU flag to bpf_refcount_acquire_impl + +Refcounted local kptrs are kptrs to user-defined types with a +bpf_refcount field. Recent commits ([0] + Parent Hashes: 82ce364c6087e31ff9837380a4641a856284064c + Refs: [1]) modified the lifetime of +refcounted local kptrs such that the underlying memory is not reused +until RCU grace period has elapsed. + +Separately + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added KF_RCU flag to bpf_refcount_acquire_impl for refcounted local kptr memory handling.', 'keywords': 'KF_RCU, bpf_refcount, kptrs', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b0d1c7294671af02369d7a4feaa5a9bb472372c6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b0d1c7294671af02369d7a4feaa5a9bb472372c6 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585664 + Commit Message: + Merge branch 'bpf: __bpf_dynptr_data* and __str annotation' + +Song Liu says: + +==================== +This set contains the first 3 patches of set [1]. Currently + Parent Hashes: 9b75dbeb36fcd9fc7ed51d370310d0518a387769 045edee19d591e59ed53772bf6dfc9b1ed9577eb + Refs: [1] is waiting +for [3] to be merged to bpf-next tree. So send these 3 patches first to +unblock other works + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merges initial set of patches related to __bpf_dynptr_data and __str annotation to unblock further developments.', 'keywords': '__bpf_dynptr_data, __str annotation, patches', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9b75dbeb36fcd9fc7ed51d370310d0518a387769 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9b75dbeb36fcd9fc7ed51d370310d0518a387769 + Author Name: Florian Lehner + Author Email: dev@der-flo.net + Commit Date: 1699585658 + Commit Message: + bpf + Parent Hashes: f2d2c7e1b7c9e8847478769d6e1f8a76b5e91952 + Refs: lpm: Fix check prefixlen before walking trie + +When looking up an element in LPM trie + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes prefix length check before traversing LPM trie in eBPF.', 'keywords': 'prefixlen, trie, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 045edee19d591e59ed53772bf6dfc9b1ed9577eb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 045edee19d591e59ed53772bf6dfc9b1ed9577eb + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1699585658 + Commit Message: + bpf: Introduce KF_ARG_PTR_TO_CONST_STR + +Similar to ARG_PTR_TO_CONST_STR for BPF helpers + Parent Hashes: 0b51940729150e807fc4b7767164e6bb6cf4f7dd + Refs: KF_ARG_PTR_TO_CONST_STR +specifies kfunc args that point to const strings. Annotation "__str" is +used to specify kfunc arg of type KF_ARG_PTR_TO_CONST_STR. Also + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce KF_ARG_PTR_TO_CONST_STR for specifying kfunc args pointing to constant strings in BPF.', 'keywords': 'KF_ARG_PTR_TO_CONST_STR, kfunc, const strings', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f2d2c7e1b7c9e8847478769d6e1f8a76b5e91952 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f2d2c7e1b7c9e8847478769d6e1f8a76b5e91952 + Author Name: Anders Roxell + Author Email: anders.roxell@linaro.org + Commit Date: 1699585658 + Commit Message: + selftests/bpf: Disable CONFIG_DEBUG_INFO_REDUCED in config.aarch64 + +Building an arm64 kernel and seftests/bpf with defconfig + +selftests/bpf/config and selftests/bpf/config.aarch64 the fragment +CONFIG_DEBUG_INFO_REDUCED is enabled in arm64's defconfig + Parent Hashes: a46afaa03f6db8c65492302ffdafcb2e769e5667 + Refs: it should be +disabled in file sefltests/bpf/config.aarch64 since if its not disabled +CONFIG_DEBUG_INFO_BTF wont be enabled. + +Signed-off-by: Anders Roxell +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231103220912.333930-1-anders.roxell@linaro.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Disable CONFIG_DEBUG_INFO_REDUCED in config.aarch64 to ensure CONFIG_DEBUG_INFO_BTF can be enabled for selftests/bpf.', 'keywords': 'selftests, CONFIG_DEBUG_INFO, aarch64', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0b51940729150e807fc4b7767164e6bb6cf4f7dd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0b51940729150e807fc4b7767164e6bb6cf4f7dd + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1699585658 + Commit Message: + bpf: Factor out helper check_reg_const_str() + +ARG_PTR_TO_CONST_STR is used to specify constant string args for BPF +helpers. The logic that verifies a reg is ARG_PTR_TO_CONST_STR is +implemented in check_func_arg(). + +As we introduce kfuncs with constant string args + Parent Hashes: 74523c06ae20b83c5508a98af62393ac34913362 + Refs: it is necessary to +do the same check for kfuncs (in check_kfunc_args). Factor out the logic +for ARG_PTR_TO_CONST_STR to a new check_reg_const_str() so that it can be +reused. + +check_func_arg() ensures check_reg_const_str() is only called with reg of +type PTR_TO_MAP_VALUE. Add a redundent type check in check_reg_const_str() +to avoid misuse in the future. Other than this redundent check + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit refactors code to introduce a reusable function for constant string argument verification in BPF helpers and kfuncs.', 'keywords': 'helper, check, refactor', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a46afaa03f6db8c65492302ffdafcb2e769e5667 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a46afaa03f6db8c65492302ffdafcb2e769e5667 + Author Name: Artem Savkov + Author Email: asavkov@redhat.com + Commit Date: 1699585658 + Commit Message: + bpftool: Fix prog object type in manpage + +bpftool's man page lists "program" as one of possible values for OBJECT + Parent Hashes: b0cf0dcde8cae24571b1f382e81328229e475604 + Refs: +while in fact bpftool accepts "prog" instead. + +Reported-by: Jerry Snitselaar +Signed-off-by: Artem Savkov +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/bpf/20231103081126.170034-1-asavkov@redhat.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Corrects the bpftool man page to reflect the correct object type "prog" instead of "program".', 'keywords': 'bpftool,manpage,prog', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 74523c06ae20b83c5508a98af62393ac34913362 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 74523c06ae20b83c5508a98af62393ac34913362 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1699585658 + Commit Message: + bpf: Add __bpf_dynptr_data* for in kernel use + +Different types of bpf dynptr have different internal data storage. +Specifically + Parent Hashes: 9b75dbeb36fcd9fc7ed51d370310d0518a387769 + Refs: SKB and XDP type of dynptr may have non-continuous data. +Therefore + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add __bpf_dynptr_data* function for internal kernel use to handle bpf dynptr with non-continuous data storage.', 'keywords': 'bpf,dynptr,kernel', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['xdp like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b0cf0dcde8cae24571b1f382e81328229e475604 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b0cf0dcde8cae24571b1f382e81328229e475604 + Author Name: Manu Bretelle + Author Email: chantr4@gmail.com + Commit Date: 1699585658 + Commit Message: + selftests/bpf: Consolidate VIRTIO/9P configs in config.vm file + +Those configs are needed to be able to run VM somewhat consistently. +For instance + Parent Hashes: e3499962d836af085a621f005978fee20fc87276 + Refs: ATM + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Consolidate VIRTIO and 9P configuration settings in the config.vm file for consistent VM execution.', 'keywords': 'configs, VM, VIRTIO', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e3499962d836af085a621f005978fee20fc87276 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e3499962d836af085a621f005978fee20fc87276 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585583 + Commit Message: + Merge branch 'selftests/bpf: Fixes for map_percpu_stats test' + +Hou Tao says: + +==================== +From: Hou Tao + +Hi + Parent Hashes: cd9c127069c040d6b022f1ff32fed4b52b9a4017 2f553b032cad4993969cab356b3b0e306fcd1cd1 + Refs: + +BPF CI failed due to map_percpu_stats_percpu_hash from time to time [1]. +It seems that the failure reason is per-cpu bpf memory allocator may not +be able to allocate per-cpu pointer successfully and it can not refill +free llist timely + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes allocation issues in map_percpu_stats test to address BPF CI failures.', 'keywords': 'map_percpu_stats,test,allocation', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cd9c127069c040d6b022f1ff32fed4b52b9a4017 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cd9c127069c040d6b022f1ff32fed4b52b9a4017 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1699585120 + Commit Message: + Merge branch 'bpf-register-bounds-logic-and-testing-improvements' + +Andrii Nakryiko says: + +==================== +BPF register bounds logic and testing improvements + +This patch set adds a big set of manual and auto-generated test cases +validating BPF verifier's register bounds tracking and deduction logic. See +details in the last patch. + +We start with building a tester that validates existing vs +verifier logic for range bounds. To make all this work + Parent Hashes: bf4a64b9323f181df8aba32d66cb37b9fa5df959 4621202adc5bc0d1006af37fe8b9aca131387d3c + Refs: BPF verifier's logic +needed a bunch of improvements to handle some cases that previously were not +covered. This had no implications as to correctness of verifier logic + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Improves BPF verifier's register bounds logic and adds extensive testing.", 'keywords': 'verifier,bounds,testing', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2f553b032cad4993969cab356b3b0e306fcd1cd1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2f553b032cad4993969cab356b3b0e306fcd1cd1 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1699585120 + Commit Message: + selftsets/bpf: Retry map update for non-preallocated per-cpu map + +BPF CI failed due to map_percpu_stats_percpu_hash from time to time [1]. +It seems that the failure reason is per-cpu bpf memory allocator may not +be able to allocate per-cpu pointer successfully and it can not refill +free llist timely + Parent Hashes: b9b79553163788d3fc42e25c2662c0a46dc9a3c5 + Refs: and bpf_map_update_elem() will return -ENOMEM. + +So mitigate the problem by retrying the update operation for +non-preallocated per-cpu map. + +[1]: https://github.com/kernel-patches/bpf/actions/runs/6713177520/job/18244865326?pr=5909 + +Signed-off-by: Hou Tao +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231101032455.3808547-4-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Retry map update for non-preallocated per-cpu map to mitigate allocation failure issues.', 'keywords': 'non-preallocated,map update,retry', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4621202adc5bc0d1006af37fe8b9aca131387d3c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4621202adc5bc0d1006af37fe8b9aca131387d3c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585120 + Commit Message: + bpf: generalize reg_set_min_max() to handle two sets of two registers + +Change reg_set_min_max() to take FALSE/TRUE sets of two registers each + Parent Hashes: 811476e9cc578cb6c776627ac069dc45a8431791 + Refs: +instead of assuming that we are always comparing to a constant. For now +we still assume that right-hand side registers are constants (and make +sure that's the case by swapping src/dst regs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance reg_set_min_max to handle two register sets instead of constants in BPF.', 'keywords': 'reg_set_min_max,registers,BPF', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b9b79553163788d3fc42e25c2662c0a46dc9a3c5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b9b79553163788d3fc42e25c2662c0a46dc9a3c5 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1699585120 + Commit Message: + selftests/bpf: Export map_update_retriable() + +Export map_update_retriable() to make it usable for other map_test +cases. These cases may only need retry for specific errno + Parent Hashes: d79924ca579c647d5dc55f605899c98f7ea04d0f + Refs: so add +a new callback parameter to let map_update_retriable() decide whether or +not the errno is retriable. + +Signed-off-by: Hou Tao +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231101032455.3808547-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Exported map_update_retriable() for use in other test cases with a new callback for custom errno retries.', 'keywords': 'map_update_retriable, export, errno', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 811476e9cc578cb6c776627ac069dc45a8431791 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 811476e9cc578cb6c776627ac069dc45a8431791 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585120 + Commit Message: + bpf: prepare reg_set_min_max for second set of registers + +Similarly to is_branch_taken()-related refactorings + Parent Hashes: 4d345887d2e5a1915600cb5d37b16c4088c6ee1c + Refs: start preparing +reg_set_min_max() to handle more generic case of two non-const +registers. Start with renaming arguments to accommodate later addition +of second register as an input argument. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-17-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactoring reg_set_min_max function to accommodate handling two non-const registers.', 'keywords': 'refactoring, reg_set_min_max, registers', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d79924ca579c647d5dc55f605899c98f7ea04d0f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d79924ca579c647d5dc55f605899c98f7ea04d0f + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1699585120 + Commit Message: + selftests/bpf: Use value with enough-size when updating per-cpu map + +When updating per-cpu map in map_percpu_stats test + Parent Hashes: cd9c127069c040d6b022f1ff32fed4b52b9a4017 + Refs: patch_map_thread() +only passes 4-bytes-sized value to bpf_map_update_elem(). The expected +size of the value is 8 * num_possible_cpus() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes the update of per-cpu map with correct value size in selftests for bpf.', 'keywords': 'per-cpu map,bpf_map_update_elem,selftests', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 4d345887d2e5a1915600cb5d37b16c4088c6ee1c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4d345887d2e5a1915600cb5d37b16c4088c6ee1c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585120 + Commit Message: + bpf: unify 32-bit and 64-bit is_branch_taken logic + +Combine 32-bit and 64-bit is_branch_taken logic for SCALAR_VALUE +registers. It makes it easier to see parallels between two domains +(32-bit and 64-bit) + Parent Hashes: b74c2a842bba941945279027083fcee1e9aaa73f + Refs: and makes subsequent refactoring more +straightforward. + +No functional changes. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-16-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Combine 32-bit and 64-bit is_branch_taken logic for SCALAR_VALUE registers.', 'keywords': 'unify, is_branch_taken, SCALAR_VALUE', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b74c2a842bba941945279027083fcee1e9aaa73f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b74c2a842bba941945279027083fcee1e9aaa73f + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585120 + Commit Message: + bpf: generalize is_branch_taken to handle all conditional jumps in one place + +Make is_branch_taken() a single entry point for branch pruning decision +making + Parent Hashes: c697289efe4ef38bc5c62f119cb74433f784b826 + Refs: handling both pointer vs pointer + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Generalized is_branch_taken function to handle all conditional jumps for branch pruning in BPF.', 'keywords': 'is_branch_taken, branch, conditional', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c697289efe4ef38bc5c62f119cb74433f784b826 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c697289efe4ef38bc5c62f119cb74433f784b826 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: move is_branch_taken() down + +Move is_branch_taken() slightly down. In subsequent patched we'll need +both flip_opcode() and is_pkt_ptr_branch_taken() for is_branch_taken() + Parent Hashes: c31534267c180f7ed00288d239a501b554885300 + Refs: +but instead of sprinkling forward declarations around + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor to move is_branch_taken() function down for improved code organization.', 'keywords': 'bpf,refactor,branching', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c31534267c180f7ed00288d239a501b554885300 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c31534267c180f7ed00288d239a501b554885300 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: generalize is_branch_taken() to work with two registers + +While still assuming that second register is a constant + Parent Hashes: c2a3ab094683ddc154879a1364fc7cb0228f96a6 + Refs: generalize +is_branch_taken-related code to accept two registers instead of register +plus explicit constant value. This also + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit generalizes the is_branch_taken() function to work with two registers instead of a register plus a constant.', 'keywords': 'generalize, is_branch_taken, registers', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c2a3ab094683ddc154879a1364fc7cb0228f96a6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c2a3ab094683ddc154879a1364fc7cb0228f96a6 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: rename is_branch_taken reg arguments to prepare for the second one + +Just taking mundane refactoring bits out into a separate patch. No +functional changes. + +Signed-off-by: Andrii Nakryiko +Acked-by: Shung-Hsi Yu +Link: https://lore.kernel.org/r/20231102033759.2541186-12-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 9e314f5d8682e1fe6ac214fb34580a238b6fd3c4 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor bpf function is_branch_taken by renaming register arguments for future enhancements.', 'keywords': 'refactor,bpf,function', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9e314f5d8682e1fe6ac214fb34580a238b6fd3c4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9e314f5d8682e1fe6ac214fb34580a238b6fd3c4 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: drop knowledge-losing __reg_combine_{32 + Parent Hashes: d7f00873817129e62f8c70891cb13c8eafe9feef + Refs: 64}_into_{64 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Removed unnecessary knowledge-losing reg combine functions in eBPF verifier.', 'keywords': 'knowledge-losing, reg combine, eBPF verifier', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d7f00873817129e62f8c70891cb13c8eafe9feef +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d7f00873817129e62f8c70891cb13c8eafe9feef + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: try harder to deduce register bounds from different numeric domains + +There are cases (caught by subsequent reg_bounds tests in selftests/bpf) +where performing one round of __reg_deduce_bounds() doesn't propagate +all the information from + Parent Hashes: c51d5ad6543cc36334ef1fcd762d0df767a0bf7e + Refs: say + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve register bounds deduction in eBPF by enhancing boundary information propagation between numeric domains.', 'keywords': 'register,bounds,reg_deduce_bounds', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c51d5ad6543cc36334ef1fcd762d0df767a0bf7e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c51d5ad6543cc36334ef1fcd762d0df767a0bf7e + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: improve deduction of 64-bit bounds from 32-bit bounds + +Add a few interesting cases in which we can tighten 64-bit bounds based +on newly learnt information about 32-bit bounds. E.g. + Parent Hashes: 6593f2e6741f03b49bffc9d55ddd4c1c47853c39 + Refs: when full u64/s64 +registers are used in BPF program + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit improves deduction of 64-bit bounds from 32-bit bounds in BPF programs.', 'keywords': 'bounds, 64-bit, 32-bit', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6593f2e6741f03b49bffc9d55ddd4c1c47853c39 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6593f2e6741f03b49bffc9d55ddd4c1c47853c39 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: add special smin32/smax32 derivation from 64-bit bounds + +Add a special case where we can derive valid s32 bounds from umin/umax +or smin/smax by stitching together negative s32 subrange and +non-negative s32 subrange. That requires upper 32 bits to form a [N + Parent Hashes: c1efab6468fd5ef541d47d81dbb62cca27f8db3b + Refs: N+1] +range in u32 domain (taking into account wrap around + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces special handling to derive 32-bit bounds from 64-bit bounds using negative and non-negative subranges in the BPF verifier.', 'keywords': 'smin32,smax32,64-bit', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c1efab6468fd5ef541d47d81dbb62cca27f8db3b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c1efab6468fd5ef541d47d81dbb62cca27f8db3b + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: derive subreg bounds from full bounds when upper 32 bits are constant + +Comments in code try to explain the idea behind why this is correct. +Please check the code and comments. + +Acked-by: Eduard Zingerman +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-6-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: d540517990a9d105bf0312760665964916ac044f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve subreg bounds derivation from full bounds when upper 32 bits are constant in BPF.', 'keywords': 'subreg, bounds, constant', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d540517990a9d105bf0312760665964916ac044f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d540517990a9d105bf0312760665964916ac044f + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: derive smin32/smax32 from umin32/umax32 bounds + +All the logic that applies to u64 vs s64 + Parent Hashes: 93f7378734b595fb61e89b802002fb7e3a1267d2 + Refs: equally applies for u32 vs s32 +relationships (just taken in a smaller 32-bit numeric space). So do the +same deduction of smin32/smax32 from umin32/umax32 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit derives smin32/smax32 bounds from umin32/umax32 for 32-bit calculations.', 'keywords': 'smin32, smax32, bounds', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 93f7378734b595fb61e89b802002fb7e3a1267d2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 93f7378734b595fb61e89b802002fb7e3a1267d2 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585119 + Commit Message: + bpf: derive smin/smax from umin/max bounds + +Add smin/smax derivation from appropriate umin/umax values. Previously the +logic was surprisingly asymmetric + Parent Hashes: f4c7e887324f5776eef6e6e47a90e0ac8058a7a8 + Refs: trying to derive umin/umax from smin/smax +(if possible) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves the logic for deriving signed minimum and maximum from unsigned bounds in eBPF verifier.', 'keywords': 'smin, smax, bounds', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: bf4a64b9323f181df8aba32d66cb37b9fa5df959 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bf4a64b9323f181df8aba32d66cb37b9fa5df959 + Author Name: Yuran Pereira + Author Email: yuran.pereira@hotmail.com + Commit Date: 1699585118 + Commit Message: + selftests/bpf: Add malloc failure checks in bpf_iter + +Since some malloc calls in bpf_iter may at times fail + Parent Hashes: fac85c291e141a67fce46bdce01f9ee33aafabfe + Refs: +this patch adds the appropriate fail checks + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds malloc failure checks to bpf_iter in selftests/bpf.', 'keywords': 'malloc,failure,bpf_iter', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f4c7e887324f5776eef6e6e47a90e0ac8058a7a8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f4c7e887324f5776eef6e6e47a90e0ac8058a7a8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585118 + Commit Message: + selftests/bpf: satisfy compiler by having explicit return in btf test + +Some compilers complain about get_pprint_mapv_size() not returning value +in some code paths. Fix with explicit return. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 2b62aa59d02ed281fa4fc218df3ca91b773e1e62 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added an explicit return statement in btf test to satisfy compiler requirements.', 'keywords': 'compiler, return, btf', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fac85c291e141a67fce46bdce01f9ee33aafabfe +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fac85c291e141a67fce46bdce01f9ee33aafabfe + Author Name: Yuran Pereira + Author Email: yuran.pereira@hotmail.com + Commit Date: 1699585118 + Commit Message: + selftests/bpf: Convert CHECK macros to ASSERT_* macros in bpf_iter + +As it was pointed out by Yonghong Song [1] + Parent Hashes: 89cdf9d556016a54ff6ddd62324aa5ec790c05cc + Refs: in the bpf selftests the use +of the ASSERT_* series of macros is preferred over the CHECK macro. +This patch replaces all CHECK calls in bpf_iter with the appropriate +ASSERT_* macros. + +[1] https://lore.kernel.org/lkml/0a142924-633c-44e6-9a92-2dc019656bf2@linux.dev + +Suggested-by: Yonghong Song +Signed-off-by: Yuran Pereira +Acked-by: Yonghong Song +Acked-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/DB3PR10MB6835E9C8DFCA226DD6FEF914E8A3A@DB3PR10MB6835.EURPRD10.PROD.OUTLOOK.COM +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Convert CHECK macros to ASSERT_* macros in bpf_iter selftests.', 'keywords': 'selftests,bpf_iter,macros', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2b62aa59d02ed281fa4fc218df3ca91b773e1e62 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2b62aa59d02ed281fa4fc218df3ca91b773e1e62 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1699585118 + Commit Message: + selftests/bpf: fix RELEASE=1 build for tc_opts + +Compiler complains about malloc(). We also don't need to dynamically +allocate anything + Parent Hashes: bf4a64b9323f181df8aba32d66cb37b9fa5df959 + Refs: so make the life easier by using statically sized +buffer. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix static buffer allocation issue for tc_opts in bpf selftests to address malloc() compiler complaints.', 'keywords': 'selftests,bpf,static buffer', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 89cdf9d556016a54ff6ddd62324aa5ec790c05cc +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 89cdf9d556016a54ff6ddd62324aa5ec790c05cc + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1699578575 + Commit Message: + Merge tag 'net-6.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + "Including fixes from netfilter and bpf. + + Current release - regressions: + + - sched: fix SKB_NOT_DROPPED_YET splat under debug config + + Current release - new code bugs: + + - tcp: + - fix usec timestamps with TCP fastopen + - fix possible out-of-bounds reads in tcp_hash_fail() + - fix SYN option room calculation for TCP-AO + + - tcp_sigpool: fix some off by one bugs + + - bpf: fix compilation error without CGROUPS + + - ptp: + - ptp_read() should not release queue + - fix tsevqs corruption + + Previous releases - regressions: + + - llc: verify mac len before reading mac header + + Previous releases - always broken: + + - bpf: + - fix check_stack_write_fixed_off() to correctly spill imm + - fix precision tracking for BPF_ALU | BPF_TO_BE | BPF_END + - check map->usercnt after timer->timer is assigned + + - dsa: lan9303: consequently nested-lock physical MDIO + + - dccp/tcp: call security_inet_conn_request() after setting IP addr + + - tg3: fix the TX ring stall due to incorrect full ring handling + + - phylink: initialize carrier state at creation + + - ice: fix direction of VF rules in switchdev mode + + Misc: + + - fill in a bunch of missing MODULE_DESCRIPTION()s + Parent Hashes: 3b220413438184b352b297e7cf593fa56999b5b3 83b9dda8afa4e968d9cce253f390b01c0612a2a5 + Refs: more to come" + +* tag 'net-6.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (84 commits) + net: ti: icss-iep: fix setting counter value + ptp: fix corrupted list in ptp_open + ptp: ptp_read should not release queue + net_sched: sch_fq: better validate TCA_FQ_WEIGHTS and TCA_FQ_PRIOMAP + net: kcm: fill in MODULE_DESCRIPTION() + net/sched: act_ct: Always fill offloading tuple iifidx + netfilter: nat: fix ipv6 nat redirect with mapped and scoped addresses + netfilter: xt_recent: fix (increase) ipv6 literal buffer length + ipvs: add missing module descriptions + netfilter: nf_tables: remove catchall element in GC sync path + netfilter: add missing module descriptions + drivers/net/ppp: use standard array-copy-function + net: enetc: shorten enetc_setup_xdp_prog() error message to fit NETLINK_MAX_FMTMSG_LEN + virtio/vsock: Fix uninit-value in virtio_transport_recv_pkt() + r8169: respect userspace disabling IFF_MULTICAST + selftests/bpf: get trusted cgrp from bpf_iter__cgroup directly + bpf: Let verifier consider {task + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes addressing regressions and bugs for netfilter, bpf, and tcp subsystems.', 'keywords': 'networking, fixes, bpf', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0008454e8fd30ed0017a9a35b8dd708f168931b8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0008454e8fd30ed0017a9a35b8dd708f168931b8 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1699572347 + Commit Message: + cgroup: Add annotation for holding namespace_sem in current_cgns_cgroup_from_root() + +When I initially examined the function current_cgns_cgroup_from_root() + Parent Hashes: 9067d90006df089b9a1da0d74f0cad232a5d726a + Refs: I +was perplexed by its lack of holding cgroup_mutex. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added annotation for holding namespace_sem in the cgroup function current_cgns_cgroup_from_root().', 'keywords': 'annotation, cgroup, namespace_sem', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 6512b6aa237db36d881a81cc312db39668e61853 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6512b6aa237db36d881a81cc312db39668e61853 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1699548573 + Commit Message: + perf bpf: Don't synthesize BPF events when disabled + +If BPF sideband events are disabled on the command line + Parent Hashes: 6aad765d10c5cd8a62b258c359bae643ab2d45da + Refs: don't +synthesize BPF events too. + +Signed-off-by: Ian Rogers +Acked-by: Song Liu +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Andi Kleen +Cc: Athira Jajeev +Cc: Changbin Du +Cc: Colin Ian King +Cc: Dmitrii Dolgov <9erthalion6@gmail.com> +Cc: German Gomez +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: James Clark +Cc: Jiri Olsa +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Li Dong +Cc: Liam Howlett +Cc: Mark Rutland +Cc: Masami Hiramatsu +Cc: Miguel Ojeda +Cc: Ming Wang +Cc: Namhyung Kim +Cc: Nick Terrell +Cc: Paolo Bonzini +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Vincent Whitchurch +Cc: Wenyu Liu +Cc: Yang Jihong +Link: https://lore.kernel.org/r/20231102175735.2272696-13-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Disable synthesis of BPF events in perf tool when sideband events are disabled via command line.', 'keywords': 'BPF,perf,events', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 942b8b38de3fd38de1476b2abca562e729caa03d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 942b8b38de3fd38de1476b2abca562e729caa03d + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1699494974 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-11-08 + +We've added 16 non-merge commits during the last 6 day(s) which contain +a total of 30 files changed + Parent Hashes: 9bc64bd0cd765f696fcd40fc98909b1f7c73b2ba 8e1b802503bb630eafc3e97b2daf755368ec96e1 + Refs: 341 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "The commit merges the 'for-netdev' branch containing non-merge commits affecting 30 files into the main branch.", 'keywords': 'merge, for-netdev, files', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1d375d65466e5c8d7a9406826d80d475a22e8c6d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1d375d65466e5c8d7a9406826d80d475a22e8c6d + Author Name: Hengqi Chen + Author Email: hengqi.chen@gmail.com + Commit Date: 1699423941 + Commit Message: + selftests/bpf: Enable cpu v4 tests for LoongArch + +Enable the cpu v4 tests for LoongArch. Currently + Parent Hashes: 7b6b13d32965ad7f1eb889d1a7058868a88eb29f + Refs: we don't have BPF +trampoline in LoongArch JIT + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable cpu v4 tests for LoongArch in the BPF selftests.', 'keywords': 'cpu v4, LoongArch, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 8e1b802503bb630eafc3e97b2daf755368ec96e1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8e1b802503bb630eafc3e97b2daf755368ec96e1 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1699399686 + Commit Message: + Merge branch 'Let BPF verifier consider {task + Parent Hashes: d84b139f53e8fa8048f16814c6b2a53d7bc15c3d 3c5864ba9cf912ff9809f315d28f296f21563cce + Refs: cgroup} is trusted in bpf_iter_reg' + +Chuyi Zhou says: + +==================== +The patchset aims to let the BPF verivier consider +bpf_iter__cgroup->cgroup and bpf_iter__task->task is trusted suggested by +Alexei[1]. + +Please see individual patches for more details. And comments are always +welcome. + +Link[1]:https://lore.kernel.org/bpf/20231022154527.229117-1-zhouchuyi@bytedance.com/T/#mb57725edc8ccdd50a1b165765c7619b4d65ed1b0 + +v2->v1: + * Patch #1: Add Yonghong's ack and add description of similar case in + log. + * Patch #2: Add Yonghong's ack +==================== + +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhances the BPF verifier to trust specific cgroup and task iterators in bpf_iter_reg.', 'keywords': 'BPF verifier, trusted, iterators', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3c5864ba9cf912ff9809f315d28f296f21563cce +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3c5864ba9cf912ff9809f315d28f296f21563cce + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1699399686 + Commit Message: + selftests/bpf: get trusted cgrp from bpf_iter__cgroup directly + +Commit f49843afde (selftests/bpf: Add tests for css_task iter combining +with cgroup iter) added a test which demonstrates how css_task iter can be +combined with cgroup iter. That test used bpf_cgroup_from_id() to convert +bpf_iter__cgroup->cgroup to a trusted ptr which is pointless now + Parent Hashes: 0de4f50de25af79c2a46db55d70cdbd8f985c6d1 + Refs: since +with the previous fix + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates the test to retrieve the trusted cgroup from bpf_iter__cgroup directly.', 'keywords': 'trusted cgroup, bpf_iter, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 0de4f50de25af79c2a46db55d70cdbd8f985c6d1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0de4f50de25af79c2a46db55d70cdbd8f985c6d1 + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1699399465 + Commit Message: + bpf: Let verifier consider {task + Parent Hashes: d84b139f53e8fa8048f16814c6b2a53d7bc15c3d + Refs: cgroup} is trusted in bpf_iter_reg + +BTF_TYPE_SAFE_TRUSTED(struct bpf_iter__task) in verifier.c wanted to +teach BPF verifier that bpf_iter__task -> task is a trusted ptr. But it +doesn't work well. + +The reason is + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix BPF verifier to correctly trust the task pointer in bpf_iter__task context.', 'keywords': 'BPF verifier, trusted pointer, bpf_iter__task', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 707df298cbde200b939c70be2577b20775fe3345 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 707df298cbde200b939c70be2577b20775fe3345 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1699042059 + Commit Message: + Merge tag 'powerpc-6.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux + +Pull powerpc updates from Michael Ellerman: + + - Add support for KVM running as a nested hypervisor under development + versions of PowerVM + Parent Hashes: 6bdfe2d88b9ff8b0cce32ce87cd47c0e9d665f48 303d77a6e1707498f09c9d8ee91b1dc07ca315a5 + Refs: using the new PAPR nested virtualisation API + + - Add support for the BPF prog pack allocator + + - A rework of the non-server MMU handling to support execute-only on + all platforms + + - Some optimisations & cleanups for the powerpc qspinlock code + + - Various other small features and fixes + +Thanks to Aboorva Devarajan + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit merges powerpc updates including nested KVM support, BPF prog pack allocator, MMU rework, and qspinlock optimizations.', 'keywords': 'nested KVM,BPF prog,optimizations', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 7ab89417ed235f56d84c7893d38d4905e38d2692 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7ab89417ed235f56d84c7893d38d4905e38d2692 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1699035458 + Commit Message: + Merge tag 'perf-tools-for-v6.7-1-2023-11-01' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools + +Pull perf tools updates from Namhyung Kim: + "Build: + + - Compile BPF programs by default if clang (>= 12.0.1) is available + to enable more features like kernel lock contention + Parent Hashes: 31e5f934ff962820995c82a6953176a1c7d18ff5 fed3a1be6433e15833068c701bfde7b422d8b988 + Refs: off-cpu + profiling + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge updates to perf tools for enabling BPF program compilation with clang if available.', 'keywords': 'perf tools, BPF, clang', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['tracepoints like programs', 'profile like programs']} +-------------------- +-------------------- +Processing Commit ID: 851bbccf6b0c152d98ecf0ec83d75fc97aebf43c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 851bbccf6b0c152d98ecf0ec83d75fc97aebf43c + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@redhat.com + Commit Date: 1699025158 + Commit Message: + perf build: Warn about missing libelf before warning about missing libbpf + +As libelf is a requirement for libbpf if it is not available + Parent Hashes: c8e3ade38bc6545faece71cc6c642ad744d4cea3 + Refs: as in some +container build tests where NO_LIBELF=1 is used + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Update perf build script to warn about missing libelf before missing libbpf.', 'keywords': 'perf,libelf,libbpf', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: d84b139f53e8fa8048f16814c6b2a53d7bc15c3d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d84b139f53e8fa8048f16814c6b2a53d7bc15c3d + Author Name: Björn Töpel + Author Email: bjorn@rivosinc.com + Commit Date: 1698937041 + Commit Message: + selftests/bpf: Fix broken build where char is unsigned + +There are architectures where char is not signed. If so + Parent Hashes: 94e88b8a3e50d3e60c3ba6a5c316729587595210 + Refs: the following +error is triggered: + + | xdp_hw_metadata.c:435:42: error: result of comparison of constant -1 \ + | with expression of type 'char' is always true \ + | [-Werror + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix build error in selftests/bpf due to unsigned char architecture issue.', 'keywords': 'selftests,bpf,unsigned', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs', 'other']} +-------------------- +-------------------- +Processing Commit ID: 94e88b8a3e50d3e60c3ba6a5c316729587595210 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 94e88b8a3e50d3e60c3ba6a5c316729587595210 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1698904468 + Commit Message: + Merge branch 'bpf-fix-precision-tracking-for-bpf_alu-bpf_to_be-bpf_end' + +Shung-Hsi Yu says: + +==================== +bpf: Fix precision tracking for BPF_ALU | BPF_TO_BE | BPF_END + +Changes since v1: +- add test for negation and bswap (Alexei + Parent Hashes: 698b8c5e3b5505ac00102caf9e4843b71192b586 3c41971550f58f2e006c58aa71e8c23ad312110f + Refs: Eduard) +- add test for BPF_TO_LE as well to cover all types of BPF_END opcode +- remove vals map and trigger backtracking with jump instead + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes precision tracking for BPF_ALU, BPF_TO_BE, BPF_END and adds relevant tests.', 'keywords': 'precision, BPF_ALU, BPF_END', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3c41971550f58f2e006c58aa71e8c23ad312110f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3c41971550f58f2e006c58aa71e8c23ad312110f + Author Name: Shung-Hsi Yu + Author Email: shung-hsi.yu@suse.com + Commit Date: 1698904468 + Commit Message: + selftests/bpf: precision tracking test for BPF_NEG and BPF_END + +As seen from previous commit that fix backtracking for BPF_ALU | BPF_TO_BE +| BPF_END + Parent Hashes: 291d044fd51f8484066300ee42afecf8c8db7b3a + Refs: both BPF_NEG and BPF_END require special handling. Add tests +written with inline assembly to check that the verifier does not incorrecly +use the src_reg field of BPF_NEG and BPF_END (including bswap added in v4). + +Suggested-by: Eduard Zingerman +Signed-off-by: Shung-Hsi Yu +Link: https://lore.kernel.org/r/20231102053913.12004-4-shung-hsi.yu@suse.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add tests for precision tracking of BPF_NEG and BPF_END handling in verifier.', 'keywords': 'precision tracking,test cases,BPF_NEG', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 291d044fd51f8484066300ee42afecf8c8db7b3a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 291d044fd51f8484066300ee42afecf8c8db7b3a + Author Name: Shung-Hsi Yu + Author Email: shung-hsi.yu@suse.com + Commit Date: 1698904467 + Commit Message: + bpf: Fix precision tracking for BPF_ALU | BPF_TO_BE | BPF_END + +BPF_END and BPF_NEG has a different specification for the source bit in +the opcode compared to other ALU/ALU64 instructions + Parent Hashes: 698b8c5e3b5505ac00102caf9e4843b71192b586 + Refs: and is either +reserved or use to specify the byte swap endianness. In both cases the +source bit does not encode source operand location + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed precision tracking for BPF_ALU, BPF_TO_BE, and BPF_END instructions in eBPF.', 'keywords': 'precision tracking, BPF_ALU, BPF_END', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 698b8c5e3b5505ac00102caf9e4843b71192b586 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 698b8c5e3b5505ac00102caf9e4843b71192b586 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1698904160 + Commit Message: + Merge branch 'relax-allowlist-for-open-coded-css_task-iter' + +Chuyi Zhou says: + +==================== +Relax allowlist for open-coded css_task iter + +Hi + Parent Hashes: 9af3775962afa8b5cd0cc30c1e454405a650c1f3 d8234d47c4aa494d789b85562fa90e837b4575f9 + Refs: +The patchset aims to relax the allowlist for open-coded css_task iter +suggested by Alexei[1]. + +Please see individual patches for more details. And comments are always +welcome. + +Patch summary: + * Patch #1: Relax the allowlist and let css_task iter can be used in + bpf iters and any sleepable progs. + * Patch #2: Add a test in cgroup_iters.c which demonstrates how + css_task iters can be combined with cgroup iter. + * Patch #3: Add a test to prove css_task iter can be used in normal + * sleepable progs. +link[1]:https://lore.kernel.org/lkml/CAADnVQKafk_junRyE=-FVAik4hjTRDtThymYGEL8hGTuYoOGpA@mail.gmail.com/ +--- + +Changes in v2: + * Fix the incorrect logic in check_css_task_iter_allowlist. Use + expected_attach_type to check whether we are using bpf_iters. + * Link to v1:https://lore.kernel.org/bpf/20231022154527.229117-1-zhouchuyi@bytedance.com/T/#m946f9cde86b44a13265d9a44c5738a711eb578fd +Changes in v3: + * Add a testcase to prove css_task can be used in fentry.s + * Link to v2:https://lore.kernel.org/bpf/20231024024240.42790-1-zhouchuyi@bytedance.com/T/#m14a97041ff56c2df21bc0149449abd275b73f6a3 +Changes in v4: + * Add Yonghong's ack for patch #1 and patch #2. + * Solve Yonghong's comments for patch #2 + * Move prog 'iter_css_task_for_each_sleep' from iters_task_failure.c to + iters_css_task.c. Use RUN_TESTS to prove we can load this prog. + * Link to v3:https://lore.kernel.org/bpf/20231025075914.30979-1-zhouchuyi@bytedance.com/T/#m3200d8ad29af4ffab97588e297361d0a45d7585d + +--- +==================== + +Link: https://lore.kernel.org/r/20231031050438.93297-1-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit relaxes the allowlist for open-coded css_task iter in BPF iters and introduces associated tests.', 'keywords': 'allowlist, css_task, bpf iters', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['cgroup like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d8234d47c4aa494d789b85562fa90e837b4575f9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d8234d47c4aa494d789b85562fa90e837b4575f9 + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1698904160 + Commit Message: + selftests/bpf: Add test for using css_task iter in sleepable progs + +This Patch add a test to prove css_task iter can be used in normal +sleepable progs. + +Signed-off-by: Chuyi Zhou +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231031050438.93297-4-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: f49843afde6771ef6ed5d021eacafacfc98a58bf + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Adds a test to validate the use of css_task iter in sleepable eBPF programs.', 'keywords': 'selftests, css_task, sleepable', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', "It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: f49843afde6771ef6ed5d021eacafacfc98a58bf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f49843afde6771ef6ed5d021eacafacfc98a58bf + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1698904160 + Commit Message: + selftests/bpf: Add tests for css_task iter combining with cgroup iter + +This patch adds a test which demonstrates how css_task iter can be combined +with cgroup iter and it won't cause deadlock + Parent Hashes: 3091b667498b0a212e760e1033e5f9b8c33a948f + Refs: though cgroup iter is not +sleepable. + +Signed-off-by: Chuyi Zhou +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231031050438.93297-3-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests demonstrating the combination of css_task iter with cgroup iter to avoid deadlock.', 'keywords': 'css_task iter,cgroup iter,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 3091b667498b0a212e760e1033e5f9b8c33a948f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3091b667498b0a212e760e1033e5f9b8c33a948f + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1698904160 + Commit Message: + bpf: Relax allowlist for css_task iter + +The newly added open-coded css_task iter would try to hold the global +css_set_lock in bpf_iter_css_task_new + Parent Hashes: 9af3775962afa8b5cd0cc30c1e454405a650c1f3 + Refs: so the bpf side has to be careful in +where it allows to use this iter. The mainly concern is dead locking on +css_set_lock. check_css_task_iter_allowlist() in verifier enforced css_task +can only be used in bpf_lsm hooks and sleepable bpf_iter. + +This patch relax the allowlist for css_task iter. Any lsm and any iter +(even non-sleepable) and any sleepable are safe since they would not hold +the css_set_lock before entering BPF progs context. + +This patch also fixes the misused BPF_TRACE_ITER in +check_css_task_iter_allowlist which compared bpf_prog_type with +bpf_attach_type. + +Fixes: 9c66dc94b62ae ("bpf: Introduce css_task open-coded iterator kfuncs") +Signed-off-by: Chuyi Zhou +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231031050438.93297-2-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit relaxes the allowlist for css_task iterator to prevent deadlocks on css_set_lock in BPF programs.', 'keywords': 'relax allowlist css_task', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['LSM like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9af3775962afa8b5cd0cc30c1e454405a650c1f3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9af3775962afa8b5cd0cc30c1e454405a650c1f3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1698903758 + Commit Message: + selftests/bpf: fix test_maps' use of bpf_map_create_opts + +Use LIBBPF_OPTS() macro to properly initialize bpf_map_create_opts in +test_maps' tests. + +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231029011509.2479232-1-andrii@kernel.org +Signed-off-by: Alexei Starovoitov + + Parent Hashes: fd381ce60a2d79cc967506208085336d3d268ae0 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes initialization of bpf_map_create_opts in selftests/bpf using LIBBPF_OPTS() macro.', 'keywords': 'selftests,bpf,LIBBPF_OPTS', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: fd381ce60a2d79cc967506208085336d3d268ae0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: fd381ce60a2d79cc967506208085336d3d268ae0 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1698903451 + Commit Message: + bpf: Check map->usercnt after timer->timer is assigned + +When there are concurrent uref release and bpf timer init operations + Parent Hashes: 15fb6f2b6c4c3c129adc2412ae12ec15e60a6adb + Refs: +the following sequence diagram is possible. It will break the guarantee +provided by bpf_timer: bpf_timer will still be alive after userspace +application releases or unpins the map. It also will lead to kmemleak +for old kernel version which doesn't release bpf_timer when map is +released. + +bpf program X: + +bpf_timer_init() + lock timer->lock + read timer->timer as NULL + read map->usercnt != 0 + + process Y: + + close(map_fd) + // put last uref + bpf_map_put_uref() + atomic_dec_and_test(map->usercnt) + array_map_free_timers() + bpf_timer_cancel_and_free() + // just return + read timer->timer is NULL + + t = bpf_map_kmalloc_node() + timer->timer = t + unlock timer->lock + +Fix the problem by checking map->usercnt after timer->timer is assigned + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a race condition between BPF timer initialization and user reference release leading to memory leak in bpf programs.', 'keywords': 'bpf,timer,map', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 15fb6f2b6c4c3c129adc2412ae12ec15e60a6adb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 15fb6f2b6c4c3c129adc2412ae12ec15e60a6adb + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1698903233 + Commit Message: + bpf: Add __bpf_hook_{start + Parent Hashes: 391145ba2accc48b596f3d438af1a6255b62a555 + Refs: end} macros + +Not all uses of __diag_ignore_all(...) in BPF-related code in order to +suppress warnings are wrapping kfunc definitions. Some "hook point" +definitions - small functions meant to be used as attach points for +fentry and similar BPF progs - need to suppress -Wmissing-declarations. + +We could use __bpf_kfunc_{start + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add macros for suppressing missing declaration warnings in BPF-related hook point definitions.', 'keywords': 'macros,suppress,warnings', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 391145ba2accc48b596f3d438af1a6255b62a555 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 391145ba2accc48b596f3d438af1a6255b62a555 + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1698903233 + Commit Message: + bpf: Add __bpf_kfunc_{start + Parent Hashes: cd60f410ddc0cd663045d15936155421b6f708fd + Refs: end}_defs macros + +BPF kfuncs are meant to be called from BPF programs. Accordingly + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces macros for BPF kfunc definitions to support calling them from BPF programs.', 'keywords': 'kfuncs,macros,BPF', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cd60f410ddc0cd663045d15936155421b6f708fd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cd60f410ddc0cd663045d15936155421b6f708fd + Author Name: Manu Bretelle + Author Email: chantr4@gmail.com + Commit Date: 1698903101 + Commit Message: + selftests/bpf: fix test_bpffs + +Currently this tests tries to umount /sys/kernel/debug (TDIR) but the +system it is running on may have mounts below. + +For example + Parent Hashes: b479d38ba959a8e3ffc4d9f760a9f2e4b9027e66 + Refs: danobi/vmtest [0] VMs have + mount -t tracefs tracefs /sys/kernel/debug/tracing +as part of their init. + +This change instead creates a "random" directory under /tmp and uses this +as TDIR. +If the directory already exists + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes the test_bpffs by using a temporary directory instead of umounting /sys/kernel/debug.', 'keywords': 'selftests,bpf,test_bpffs', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b479d38ba959a8e3ffc4d9f760a9f2e4b9027e66 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b479d38ba959a8e3ffc4d9f760a9f2e4b9027e66 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1698903028 + Commit Message: + Merge branch 'bpf-fix-incorrect-immediate-spill' + +Hao Sun says: + +==================== +bpf: Fix incorrect immediate spill + +Immediate is incorrectly cast to u32 before being spilled + Parent Hashes: 05670f81d1287c40ec861186e4c4e3401013e7fb 85eb035e6cfd615071256592e1dbe72c1d99c24b + Refs: losing sign +information. The range information is incorrect after load again. Fix +immediate spill by remove the cast. The second patch add a test case +for this. + +Signed-off-by: Hao Sun +--- +Changes in v3: +- Change the expected log to fix the test case +- Link to v2: https://lore.kernel.org/r/20231101-fix-check-stack-write-v2-0-cb7c17b869b0@gmail.com + +Changes in v2: +- Add fix and cc tags. +- Link to v1: https://lore.kernel.org/r/20231026-fix-check-stack-write-v1-0-6b325ef3ce7e@gmail.com + +--- +==================== + +Link: https://lore.kernel.org/r/20231101-fix-check-stack-write-v3-0-f05c2b1473d5@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes an issue with immediate value spill and adds a test case to validate the correction.', 'keywords': 'fix, immediate, spill', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 85eb035e6cfd615071256592e1dbe72c1d99c24b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 85eb035e6cfd615071256592e1dbe72c1d99c24b + Author Name: Hao Sun + Author Email: sunhao.th@gmail.com + Commit Date: 1698903027 + Commit Message: + selftests/bpf: Add test for immediate spilled to stack + +Add a test to check if the verifier correctly reason about the sign +of an immediate spilled to stack by BPF_ST instruction. + +Signed-off-by: Hao Sun +Link: https://lore.kernel.org/r/20231101-fix-check-stack-write-v3-2-f05c2b1473d5@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 811c363645b33e6e22658634329e95f383dfc705 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a test case to verify immediate spill to stack in eBPF selftests.', 'keywords': 'test, immediate, stack', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 811c363645b33e6e22658634329e95f383dfc705 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 811c363645b33e6e22658634329e95f383dfc705 + Author Name: Hao Sun + Author Email: sunhao.th@gmail.com + Commit Date: 1698903027 + Commit Message: + bpf: Fix check_stack_write_fixed_off() to correctly spill imm + +In check_stack_write_fixed_off() + Parent Hashes: 05670f81d1287c40ec861186e4c4e3401013e7fb + Refs: imm value is cast to u32 before being +spilled to the stack. Therefore + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed the check_stack_write_fixed_off function to properly cast and spill imm values to the stack.', 'keywords': 'bpf, fix, spill', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 05670f81d1287c40ec861186e4c4e3401013e7fb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 05670f81d1287c40ec861186e4c4e3401013e7fb + Author Name: Matthieu Baerts + Author Email: matttbe@kernel.org + Commit Date: 1698902905 + Commit Message: + bpf: fix compilation error without CGROUPS + +Our MPTCP CI complained [1] -- and KBuild too -- that it was no longer +possible to build the kernel without CONFIG_CGROUPS: + + kernel/bpf/task_iter.c: In function 'bpf_iter_css_task_new': + kernel/bpf/task_iter.c:919:14: error: 'CSS_TASK_ITER_PROCS' undeclared (first use in this function) + 919 | case CSS_TASK_ITER_PROCS | CSS_TASK_ITER_THREADED: + | ^~~~~~~~~~~~~~~~~~~ + kernel/bpf/task_iter.c:919:14: note: each undeclared identifier is reported only once for each function it appears in + kernel/bpf/task_iter.c:919:36: error: 'CSS_TASK_ITER_THREADED' undeclared (first use in this function) + 919 | case CSS_TASK_ITER_PROCS | CSS_TASK_ITER_THREADED: + | ^~~~~~~~~~~~~~~~~~~~~~ + kernel/bpf/task_iter.c:927:60: error: invalid application of 'sizeof' to incomplete type 'struct css_task_iter' + 927 | kit->css_it = bpf_mem_alloc(&bpf_global_ma + Parent Hashes: 2b7ac0c87d985c92e519995853c52b9649ea4b07 + Refs: sizeof(struct css_task_iter)); + | ^~~~~~ + kernel/bpf/task_iter.c:930:9: error: implicit declaration of function 'css_task_iter_start'; did you mean 'task_seq_start'? [-Werror=implicit-function-declaration] + 930 | css_task_iter_start(css + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix compilation error in BPF task iterator when CONFIG_CGROUPS is not enabled in kernel build.', 'keywords': 'BPF, compilation, CONFIG_CGROUPS', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f5277ad1e9768dbd05b1ae8dcdba690215d8c5b7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f5277ad1e9768dbd05b1ae8dcdba690215d8c5b7 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1698873394 + Commit Message: + Merge tag 'for-6.7/io_uring-sockopt-2023-10-30' of git://git.kernel.dk/linux + +Pull io_uring {get + Parent Hashes: ffa059b262ba72571e7fefe7fa2b4ebb6776b277 b9ec913212e6e91efa5a0a612c4a8ec4cf5da896 + Refs: set}sockopt support from Jens Axboe: + "This adds support for using getsockopt and setsockopt via io_uring. + + The main use cases for this is to enable use of direct descriptors + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge io_uring getsockopt and setsockopt support for direct descriptors.', 'keywords': 'io_uring, getsockopt, setsockopt', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a6bdc082ad1c91d389a6ba0c7a1945818f732114 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a6bdc082ad1c91d389a6ba0c7a1945818f732114 + Author Name: Huacai Chen + Author Email: chenhuacai@loongson.cn + Commit Date: 1698807300 + Commit Message: + Merge 'bpf-next 2023-10-16' into loongarch-next + +LoongArch architecture changes for 6.7 (BPF CPU v4 support) depend on +the bpf changes to fix conflictions in selftests and work + Parent Hashes: ffc253263a1375a65fa6c9f62a893e9767fbebfa 99c9991f4e5d77328187187d0c921a3b62bfa998 + Refs: so merge them +to create a base. + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge LoongArch architecture changes with bpf-next tree for conflict resolution in selftests.', 'keywords': 'Merge, LoongArch, selftests', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 89ed67ef126c4160349c1b96fdb775ea6170ac90 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 89ed67ef126c4160349c1b96fdb775ea6170ac90 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1698765011 + Commit Message: + Merge tag 'net-next-6.7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next + +Pull networking updates from Jakub Kicinski: + "Core & protocols: + + - Support usec resolution of TCP timestamps + Parent Hashes: 5a6a09e97199d6600d31383055f9d43fbbcbe86f f1c73396133cb3d913e2075298005644ee8dfade + Refs: enabled selectively by a + route attribute. + + - Defer regular TCP ACK while processing socket backlog + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking updates including TCP timestamp resolution enhancements.', 'keywords': 'networking,TCP,updates', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 14ab6d425e80674b6a0145f05719b11e82e64824 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 14ab6d425e80674b6a0145f05719b11e82e64824 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1698695233 + Commit Message: + Merge tag 'vfs-6.7.ctime' of gitolite.kernel.org:pub/scm/linux/kernel/git/vfs/vfs + +Pull vfs inode time accessor updates from Christian Brauner: + "This finishes the conversion of all inode time fields to accessor + functions as discussed on list. Changing timestamps manually as we + used to do before is error prone. Using accessors function makes this + robust. + + It does not contain the switch of the time fields to discrete 64 bit + integers to replace struct timespec and free up space in struct inode. + But after this + Parent Hashes: 7352a6765cf5d95888b3952ac89efbb817b4c3cf 12cd44023651666bd44baa36a5c999698890debb + Refs: the switch can be trivially made and the patch should + only affect the vfs if we decide to do it" + +* tag 'vfs-6.7.ctime' of gitolite.kernel.org:pub/scm/linux/kernel/git/vfs/vfs: (86 commits) + fs: rename inode i_atime and i_mtime fields + security: convert to new timestamp accessors + selinux: convert to new timestamp accessors + apparmor: convert to new timestamp accessors + sunrpc: convert to new timestamp accessors + mm: convert to new timestamp accessors + bpf: convert to new timestamp accessors + ipc: convert to new timestamp accessors + linux: convert to new timestamp accessors + zonefs: convert to new timestamp accessors + xfs: convert to new timestamp accessors + vboxsf: convert to new timestamp accessors + ufs: convert to new timestamp accessors + udf: convert to new timestamp accessors + ubifs: convert to new timestamp accessors + tracefs: convert to new timestamp accessors + sysv: convert to new timestamp accessors + squashfs: convert to new timestamp accessors + server: convert to new timestamp accessors + client: convert to new timestamp accessors + ... + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This merge updates inode time fields to use accessor functions, enhancing robustness and reducing errors.', 'keywords': 'inode,timestamp,accessors', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1768d3a0144c7aae55b9cee66dabf94946eec01e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1768d3a0144c7aae55b9cee66dabf94946eec01e + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@kernel.org + Commit Date: 1698460053 + Commit Message: + perf build: Disable BPF skeletons if clang version is < 12.0.1 + +While building on a wide range of distros and clang versions it was +noticed that at least version 12.0.1 (noticed on Alpine 3.15 with +"Alpine clang version 12.0.1") is needed to not fail with BTF generation +errors such as: + +Debian:10 + + Debian clang version 11.0.1-2~deb10u1: + + CLANG /tmp/build/perf/util/bpf_skel/.tmp/sample_filter.bpf.o + + GENSKEL /tmp/build/perf/util/bpf_skel/sample_filter.skel.h + libbpf: failed to find BTF for extern 'bpf_cast_to_kern_ctx' [21] section: -2 + Error: failed to open BPF object file: No such file or directory + make[2]: *** [Makefile.perf:1121: /tmp/build/perf/util/bpf_skel/sample_filter.skel.h] Error 254 + make[2]: *** Deleting file '/tmp/build/perf/util/bpf_skel/sample_filter.skel.h' + +Amazon Linux 2: + + clang version 11.1.0 (Amazon Linux 2 11.1.0-1.amzn2.0.2) + + GENSKEL /tmp/build/perf/util/bpf_skel/sample_filter.skel.h + libbpf: elf: skipping unrecognized data section(18) .eh_frame + libbpf: elf: skipping relo section(19) .rel.eh_frame for section(18) .eh_frame + libbpf: failed to find BTF for extern 'bpf_cast_to_kern_ctx' [21] section: -2 + Error: failed to open BPF object file: No such file or directory + make[2]: *** [/tmp/build/perf/util/bpf_skel/sample_filter.skel.h] Error 254 + make[2]: *** Deleting file `/tmp/build/perf/util/bpf_skel/sample_filter.skel.h' + +Ubuntu 20.04: + + clang version 10.0.0-4ubuntu1 + + CLANG /tmp/build/perf/util/bpf_skel/.tmp/augmented_raw_syscalls.bpf.o + GENSKEL /tmp/build/perf/util/bpf_skel/bench_uprobe.skel.h + GENSKEL /tmp/build/perf/util/bpf_skel/bperf_leader.skel.h + libbpf: sec '.reluprobe': corrupted symbol #27 pointing to invalid section #65522 for relo #0 + GENSKEL /tmp/build/perf/util/bpf_skel/bperf_follower.skel.h + Error: failed to open BPF object file: BPF object format invalid + make[2]: *** [Makefile.perf:1121: /tmp/build/perf/util/bpf_skel/bench_uprobe.skel.h] Error 95 + make[2]: *** Deleting file '/tmp/build/perf/util/bpf_skel/bench_uprobe.skel.h' + +So check if the version is at least 12.0.1 otherwise disable building +BPF skels and provide a message about it + Parent Hashes: ee40490dd7cdcda38ece6d081f63ecddd3fdbe25 + Refs: continuing the build. + +The message + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Disable building BPF skeletons in perf if using a clang version older than 12.0.1 to avoid BTF generation errors.', 'keywords': 'BPF skeletons, clang version, BTF errors', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 06497763c8f15d08c0e356e651a61f2930a8987c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 06497763c8f15d08c0e356e651a61f2930a8987c + Author Name: Yonghong Song + Author Email: yonghong.song@linux.dev + Commit Date: 1698446488 + Commit Message: + net: bpf: Use sockopt_lock_sock() in ip_sock_set_tos() + +With latest sync from net-next tree + Parent Hashes: f5247a6ed5b5bbaa609f97049de868974eb7a7c2 + Refs: bpf-next has a bpf selftest failure: + [root@arch-fb-vm1 bpf]# ./test_progs -t setget_sockopt + ... + [ 76.194349] ============================================ + [ 76.194682] WARNING: possible recursive locking detected + [ 76.195039] 6.6.0-rc7-g37884503df08-dirty #67 Tainted: G W OE + [ 76.195518] -------------------------------------------- + [ 76.195852] new_name/154 is trying to acquire lock: + [ 76.196159] ffff8c3e06ad8d30 (sk_lock-AF_INET){+.+.}-{0:0} + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates the net bpf code to use sockopt_lock_sock in ip_sock_set_tos to avoid recursive locking issues.', 'keywords': 'sockopt_lock_sock, ip_sock_set_tos, recursive locking', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['socket like programs', 'other']} +-------------------- +-------------------- +Processing Commit ID: c6f9b7138bf5c6b826175c9e0ad5f5dbfff4fa36 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c6f9b7138bf5c6b826175c9e0ad5f5dbfff4fa36 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1698375761 + Commit Message: + Merge tag 'for-netdev' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-10-26 + +We've added 51 non-merge commits during the last 10 day(s) which contain +a total of 75 files changed + Parent Hashes: cc33a80b816406f900a53c7f98a50f6eacdd2e31 ea41b880cc85f0a992571f66e4554a69f7806246 + Refs: 5037 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge commit integrating 51 non-merge commits from bpf-next branch.', 'keywords': 'merge, bpf-next, commits', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ea41b880cc85f0a992571f66e4554a69f7806246 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ea41b880cc85f0a992571f66e4554a69f7806246 + Author Name: Nikolay Aleksandrov + Author Email: razor@blackwall.org + Commit Date: 1698328719 + Commit Message: + netkit: Remove explicit active/peer ptr initialization + +Remove the explicit NULLing of active/peer pointers and rely on the +implicit one done at net device allocation. + +Suggested-by: Jiri Pirko +Signed-off-by: Nikolay Aleksandrov +Signed-off-by: Daniel Borkmann +Reviewed-by: Jiri Pirko +Acked-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231026094106.1505892-2-razor@blackwall.org + + Parent Hashes: 399f6185a1c02f39bcadb8749bc2d9d48685816f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit removes explicit pointer initialization and relies on implicit initialization during net device allocation.', 'keywords': 'pointer initialization, net device, implicit nulling', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 399f6185a1c02f39bcadb8749bc2d9d48685816f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 399f6185a1c02f39bcadb8749bc2d9d48685816f + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1698327723 + Commit Message: + selftests/bpf: Fix selftests broken by mitigations=off + +When we configure the kernel command line with 'mitigations=off' and set +the sysctl knob 'kernel.unprivileged_bpf_disabled' to 0 + Parent Hashes: 37db10bc247d5d0b448babd7ff386f092246e732 + Refs: the commit +bc5bc309db45 ("bpf: Inherit system settings for CPU security mitigations") +causes issues in the execution of `test_progs -t verifier`. This is +because 'mitigations=off' bypasses Spectre v1 and Spectre v4 protections. + +Currently + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Fixes broken eBPF selftests when kernel configured with 'mitigations=off' affecting test execution.", 'keywords': 'selftests, mitigations, verifier', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 37db10bc247d5d0b448babd7ff386f092246e732 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 37db10bc247d5d0b448babd7ff386f092246e732 + Author Name: Viktor Malik + Author Email: vmalik@redhat.com + Commit Date: 1698327133 + Commit Message: + samples/bpf: Allow building with custom bpftool + +samples/bpf build its own bpftool boostrap to generate vmlinux.h as well +as some BPF objects. This is a redundant step if bpftool has been +already built + Parent Hashes: f56bcfadf7d6d56b099726df4fc262b76486b0e0 + Refs: so update samples/bpf/Makefile such that it accepts a +path to bpftool passed via the BPFTOOL variable. The approach is +practically the same as tools/testing/selftests/bpf/Makefile uses. + +Signed-off-by: Viktor Malik +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/bd746954ac271b02468d8d951ff9f11e655d485b.1698213811.git.vmalik@redhat.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit allows samples/bpf to build with a custom bpftool by modifying the Makefile.', 'keywords': 'samples,bpf,Makefile', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: f56bcfadf7d6d56b099726df4fc262b76486b0e0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f56bcfadf7d6d56b099726df4fc262b76486b0e0 + Author Name: Viktor Malik + Author Email: vmalik@redhat.com + Commit Date: 1698327133 + Commit Message: + samples/bpf: Fix passing LDFLAGS to libbpf + +samples/bpf/Makefile passes LDFLAGS=$(TPROGS_LDFLAGS) to libbpf build +without surrounding quotes + Parent Hashes: 870f09f1ba3014e2c157b14299c172b4bb716638 + Refs: which may cause compilation errors when +passing custom TPROGS_USER_LDFLAGS. + +For example: + + $ make -C samples/bpf/ TPROGS_USER_LDFLAGS="-Wl + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes LDFLAGS passing issue in samples/bpf Makefile to prevent compilation errors.', 'keywords': 'LDFLAGS, Makefile, compilation', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 870f09f1ba3014e2c157b14299c172b4bb716638 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 870f09f1ba3014e2c157b14299c172b4bb716638 + Author Name: Viktor Malik + Author Email: vmalik@redhat.com + Commit Date: 1698327132 + Commit Message: + samples/bpf: Allow building with custom CFLAGS/LDFLAGS + +Currently + Parent Hashes: c421c12586b3f00fb96b5c9af15c9a051a9090b1 + Refs: it is not possible to specify custom flags when building +samples/bpf. The flags are defined in TPROGS_CFLAGS/TPROGS_LDFLAGS +variables + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows building samples/bpf with custom CFLAGS/LDFLAGS.', 'keywords': 'custom CFLAGS LDFLAGS', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c421c12586b3f00fb96b5c9af15c9a051a9090b1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c421c12586b3f00fb96b5c9af15c9a051a9090b1 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1698323013 + Commit Message: + bpf: Add more WARN_ON_ONCE checks for mismatched alloc and free + +There are two possible mismatched alloc and free cases in BPF memory +allocator: + +1) allocate from cache X but free by cache Y with a different unit_size +2) allocate from per-cpu cache but free by kmalloc cache or vice versa + +So add more WARN_ON_ONCE checks in free_bulk() and __free_by_rcu() to +spot these mismatched alloc and free early. + +Signed-off-by: Hou Tao +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231021014959.3563841-1-houtao@huaweicloud.com + + Parent Hashes: 22360fad5889cbefe1eca695b0cc0273ab280b56 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add checks to detect mismatched allocation and freeing in the BPF memory allocator.', 'keywords': 'memory allocator checks', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e56808fef8f71a192b2740c0b6ea8be7ab865d54 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e56808fef8f71a192b2740c0b6ea8be7ab865d54 + Author Name: Roman Gushchin + Author Email: roman.gushchin@linux.dev + Commit Date: 1698277631 + Commit Message: + mm: kmem: reimplement get_obj_cgroup_from_current() + +Reimplement get_obj_cgroup_from_current() using current_obj_cgroup(). +get_obj_cgroup_from_current() and current_obj_cgroup() share 80% of the +code + Parent Hashes: c63b835d0eafc956c43b8c6605708240ac52b8cd + Refs: so the new implementation is almost trivial. + +get_obj_cgroup_from_current() is a convenient function used by the +bpf subsystem + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Reimplemented get_obj_cgroup_from_current() using existing common code in current_obj_cgroup() to reduce redundancy.', 'keywords': 'reimplement, obj_cgroup, bpf', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b5711042a1c8cc88ed40a5ebf612b36e83a4e2e4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b5711042a1c8cc88ed40a5ebf612b36e83a4e2e4 + Author Name: Namhyung Kim + Author Email: namhyung@kernel.org + Commit Date: 1698253375 + Commit Message: + perf lock contention: Use per-cpu array map for spinlocks + +Currently lock contention timestamp is maintained in a hash map keyed by +pid. That means it needs to get and release a map element (which is +proctected by spinlock!) on each contention begin and end pair. This +can impact on performance if there are a lot of contention (usually from +spinlocks). + +It used to go with task local storage but it had an issue on memory +allocation in some critical paths. Although it's addressed in recent +kernels IIUC + Parent Hashes: 6a070573f290f99a6129ac3e13b9df521a1a65de + Refs: the tool should support old kernels too. So it cannot +simply switch to the task local storage at least for now. + +As spinlocks create lots of contention and they disabled preemption +during the spinning + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimized lock contention handling by using per-cpu array map instead of hash map for spinlocks in perf tool.', 'keywords': 'lock contention, spinlocks, per-cpu', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6a070573f290f99a6129ac3e13b9df521a1a65de +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6a070573f290f99a6129ac3e13b9df521a1a65de + Author Name: Namhyung Kim + Author Email: namhyung@kernel.org + Commit Date: 1698253367 + Commit Message: + perf lock contention: Check race in tstamp elem creation + +When pelem is NULL + Parent Hashes: d99317f214ca3d381f7b17a75c41263885664e06 + Refs: it'd create a new entry with zero data. But it +might be preempted by IRQ/NMI just before calling bpf_map_update_elem() +then there's a chance to call it twice for the same pid. So it'd be +better to use BPF_NOEXIST flag and check the return value to prevent +the race. + +Signed-off-by: Namhyung Kim +Acked-by: Ian Rogers +Cc: Hao Luo +Cc: Song Liu +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231020204741.1869520-2-namhyung@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement BPF_NOEXIST flag to prevent race conditions in perf lock contention element creation.', 'keywords': 'race, BPF_NOEXIST, contention', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: d99317f214ca3d381f7b17a75c41263885664e06 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d99317f214ca3d381f7b17a75c41263885664e06 + Author Name: Namhyung Kim + Author Email: namhyung@kernel.org + Commit Date: 1698253354 + Commit Message: + perf lock contention: Clear lock addr after use + +It checks the current lock to calculated the delta of contention time. +The address is saved in the tstamp map which is allocated at begining of +contention and released at end of contention. + +But it's possible for bpf_map_delete_elem() to fail. In that case + Parent Hashes: e093a222d7cba1eb6c36887e58ce8a4ff249f1c6 + Refs: the +element in the tstamp map kept for the current lock and it makes the +next contention for the same lock tracked incorrectly. Specificially +the next contention begin will see the existing element for the task and +it'd just return. Then the next contention end will see the element and +calculate the time using the timestamp for the previous begin. + +This can result in a large value for two small contentions happened from +time to time. Let's clear the lock address so that it can be updated +next time even if the bpf_map_delete_elem() failed. + +Signed-off-by: Namhyung Kim +Acked-by: Ian Rogers +Cc: Hao Luo +Cc: Song Liu +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231020204741.1869520-1-namhyung@kernel.org + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix contention time tracking in perf lock by clearing lock address after use.', 'keywords': 'perf,lock,contention', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 22360fad5889cbefe1eca695b0cc0273ab280b56 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 22360fad5889cbefe1eca695b0cc0273ab280b56 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1698188868 + Commit Message: + Merge branch 'Add bpf programmable net device' + +Daniel Borkmann says: + +==================== +This work adds a BPF programmable device which can operate in L3 or L2 +mode where the BPF program is part of the xmit routine. It's program +management is done via bpf_mprog and it comes with BPF link support. +For details see patch 1 and following. Thanks! + +v3 -> v4: + - Moved netkit_release_all() into ndo_uninit (Stan) + - Two small commit msg corrections (Toke) + - Added Acked/Reviewed-by +v2 -> v3: + - Remove setting dev->min_mtu to ETH_MIN_MTU (Andrew) + - Do not populate ethtool info->version (Andrew) + - Populate netdev private data before register_netdevice (Andrew) + - Use strscpy for ifname template (Jakub) + - Use GFP_KERNEL_ACCOUNT for link kzalloc (Jakub) + - Carry and dump link attach type for bpftool (Toke) +v1 -> v2: + - Rename from meta (Toke + Parent Hashes: 42d31dd601fa43b9afdf069d1ba410b2306a4c76 ace15f91e569172dac71ae0aeb3a2e76d1ce1b17 + Refs: Andrii + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added a BPF programmable net device with L2/L3 mode and BPF link support via bpf_mprog.', 'keywords': 'BPF programmable, net device, bpf_mprog', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['xdp like programs', 'tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: ace15f91e569172dac71ae0aeb3a2e76d1ce1b17 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ace15f91e569172dac71ae0aeb3a2e76d1ce1b17 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1698188863 + Commit Message: + selftests/bpf: Add selftests for netkit + +Add a bigger batch of test coverage to assert correct operation of +netkit devices and their BPF program management: + + # ./test_progs -t tc_netkit + [...] + [ 1.166267] bpf_testmod: loading out-of-tree module taints kernel. + [ 1.166831] bpf_testmod: module verification failed: signature and/or required key missing - tainting kernel + [ 1.270957] tsc: Refined TSC clocksource calibration: 3407.988 MHz + [ 1.272579] clocksource: tsc: mask: 0xffffffffffffffff max_cycles: 0x311fc932722 + Parent Hashes: 51f1892b5289f0c09745d3bedb36493555d6d90c + Refs: max_idle_ns: 440795381586 ns + [ 1.275336] clocksource: Switched to clocksource tsc + #257 tc_netkit_basic:OK + #258 tc_netkit_device:OK + #259 tc_netkit_multi_links:OK + #260 tc_netkit_multi_opts:OK + #261 tc_netkit_neigh_links:OK + Summary: 5/0 PASSED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests to ensure netkit devices and BPF program management function correctly.', 'keywords': 'selftests, netkit, tc_netkit', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 51f1892b5289f0c09745d3bedb36493555d6d90c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 51f1892b5289f0c09745d3bedb36493555d6d90c + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1698188859 + Commit Message: + selftests/bpf: Add netlink helper library + +Add a minimal netlink helper library for the BPF selftests. This has been +taken and cut down and cleaned up from iproute2. This covers basics such +as netdevice creation which we need for BPF selftests / BPF CI given +iproute2 package cannot cover it yet. + +Stanislav Fomichev suggested that this could be replaced in future by ynl +tool generated C code once it has RTNL support to create devices. Once we +get to this point the BPF CI would also need to add libmnl. If no further +extensions are needed + Parent Hashes: bec981a4add6dd6a63065e54e2b2e67c2af6c3fa + Refs: a second option could be that we remove this code +again once iproute2 package has support. + +Signed-off-by: Daniel Borkmann +Acked-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20231024214904.29825-7-daniel@iogearbox.net +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds a minimal netlink helper library for BPF selftests, derived from iproute2, to support BPF CI.', 'keywords': 'netlink, helper library, selftests', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: bec981a4add6dd6a63065e54e2b2e67c2af6c3fa +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bec981a4add6dd6a63065e54e2b2e67c2af6c3fa + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1698188852 + Commit Message: + bpftool: Extend net dump with netkit progs + +Add support to dump BPF programs on netkit via bpftool. This includes both +the BPF link and attach ops programs. Dumped information contain the attach +location + Parent Hashes: 92a85e18ad4705c66ace55a19f4f8301ef0eb59f + Refs: function entry name + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extend bpftool to support dumping BPF programs on netkit, including link and attach ops programs.', 'keywords': 'bpftool, netkit, dump', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 92a85e18ad4705c66ace55a19f4f8301ef0eb59f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 92a85e18ad4705c66ace55a19f4f8301ef0eb59f + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1698188844 + Commit Message: + bpftool: Implement link show support for netkit + +Add support to dump netkit link information to bpftool in similar way as +we have for XDP. The netkit link info only exposes the ifindex and the +attach_type. + +Below shows an example link dump output + Parent Hashes: 05c31b4ab20527c4d1695130aaecc54ef59a0e54 + Refs: and a cgroup link is included for +comparison + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement support for displaying netkit link information in bpftool.', 'keywords': 'bpftool, netkit, link', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['tracepoints like programs', 'cgroup like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 05c31b4ab20527c4d1695130aaecc54ef59a0e54 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 05c31b4ab20527c4d1695130aaecc54ef59a0e54 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1698188818 + Commit Message: + libbpf: Add link-based API for netkit + +This adds bpf_program__attach_netkit() API to libbpf. Overall it is very +similar to tcx. The API looks as following: + + LIBBPF_API struct bpf_link * + bpf_program__attach_netkit(const struct bpf_program *prog + Parent Hashes: 5c1b994de4be8a27afa3281be2ff58b38e8bc50c + Refs: int ifindex + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces a new link-based API, bpf_program__attach_netkit, to libbpf for attaching eBPF programs.', 'keywords': 'libbpf, link-based API, netkit', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 35dfaad7188cdc043fde31709c796f5a692ba2bd +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 35dfaad7188cdc043fde31709c796f5a692ba2bd + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1698188763 + Commit Message: + netkit + Parent Hashes: 42d31dd601fa43b9afdf069d1ba410b2306a4c76 + Refs: bpf: Add bpf programmable net device + +This work adds a new + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add a BPF programmable network device in the Linux kernel.', 'keywords': 'BPF, network, device', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['socket like programs', 'tc/netfilter like programs', 'other']} +-------------------- +-------------------- +Processing Commit ID: 42d31dd601fa43b9afdf069d1ba410b2306a4c76 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 42d31dd601fa43b9afdf069d1ba410b2306a4c76 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1698151551 + Commit Message: + bpf: Improve JEQ/JNE branch taken logic + +When determining if an if/else branch will always or never be taken + Parent Hashes: 06646da01458682023321bdc7553b8140e95d077 + Refs: use +signed range knowledge in addition to currently used unsigned range knowledge. +If either signed or unsigned range suggests that condition is always/never +taken + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves the logic for determining JEQ/JNE branch conditions using both signed and unsigned range knowledge.', 'keywords': 'JEQ,JNE,branch', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 06646da01458682023321bdc7553b8140e95d077 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 06646da01458682023321bdc7553b8140e95d077 + Author Name: Paul E. McKenney + Author Email: paulmck@kernel.org + Commit Date: 1698150367 + Commit Message: + bpf: Fold smp_mb__before_atomic() into atomic_set_release() + +The bpf_user_ringbuf_drain() BPF_CALL function uses an atomic_set() +immediately preceded by smp_mb__before_atomic() so as to order storing +of ring-buffer consumer and producer positions prior to the atomic_set() +call's clearing of the ->busy flag + Parent Hashes: d35381aa73f7e1e8b25f3ed5283287a64d9ddff5 + Refs: as follows: + + smp_mb__before_atomic(); + atomic_set(&rb->busy + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit folds smp_mb__before_atomic() into atomic_set_release() in bpf_user_ringbuf_drain() for ring-buffer ordering.', 'keywords': 'smp_mb_before_atomic,atomic_set_release,ring-buffer', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d35381aa73f7e1e8b25f3ed5283287a64d9ddff5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d35381aa73f7e1e8b25f3ed5283287a64d9ddff5 + Author Name: Song Liu + Author Email: song@kernel.org + Commit Date: 1698150355 + Commit Message: + bpf: Fix unnecessary -EBUSY from htab_lock_bucket + +htab_lock_bucket uses the following logic to avoid recursion: + +1. preempt_disable(); +2. check percpu counter htab->map_locked[hash] for recursion; + 2.1. if map_lock[hash] is already taken + Parent Hashes: 99b29a499b5fdfb7ab274835b8e4d4c11df2f6d7 + Refs: return -BUSY; +3. raw_spin_lock_irqsave(); + +However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes erroneous -EBUSY error from htab_lock_bucket in eBPF maps.', 'keywords': 'fix, htab_lock_bucket, eBPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 99b29a499b5fdfb7ab274835b8e4d4c11df2f6d7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 99b29a499b5fdfb7ab274835b8e4d4c11df2f6d7 + Author Name: Albert Huang + Author Email: huangjie.albert@bytedance.com + Commit Date: 1698141336 + Commit Message: + xsk: Avoid starving the xsk further down the list + +In the previous implementation + Parent Hashes: dedd6c894110371d3c218cf24ecca2f0730408ac + Refs: when multiple xsk sockets were +associated with a single xsk_buff_pool + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize XSK socket handling to prevent resource starvation in shared buffer pools.', 'keywords': 'xsk,starvation,buffer', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: dedd6c894110371d3c218cf24ecca2f0730408ac +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dedd6c894110371d3c218cf24ecca2f0730408ac + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1698122972 + Commit Message: + Merge branch 'exact-states-comparison-for-iterator-convergence-checks' + +Eduard Zingerman says: + +==================== +exact states comparison for iterator convergence checks + +Iterator convergence logic in is_state_visited() uses state_equals() +for states with branches counter > 0 to check if iterator based loop +converges. This is not fully correct because state_equals() relies on +presence of read and precision marks on registers. These marks are not +guaranteed to be finalized while state has branches. +Commit message for patch #3 describes a program that exhibits such +behavior. + +This patch-set aims to fix iterator convergence logic by adding notion +of exact states comparison. Exact comparison does not rely on presence +of read or precision marks and thus is more strict. +As explained in commit message for patch #3 exact comparisons require +addition of speculative register bounds widening. The end result for +BPF verifier users could be summarized as follows: + +(!) After this update verifier would reject programs that conjure an + imprecise value on the first loop iteration and use it as precise + on the second (for iterator based loops). + +I urge people to at least skim over the commit message for patch #3. + +Patches are organized as follows: +- patches #1 + Parent Hashes: b63dadd6f97522513fe9497b5fde84a154e39a0b b4d8239534fddc036abe4a0fdbf474d9894d4641 + Refs: 2: moving/extracting utility functions; +- patch #3: introduces exact mode for states comparison and adds + widening heuristic; +- patch #4: adds test-cases that demonstrate why the series is + necessary; +- patch #5: extends patch #3 with a notion of state loop entries + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enhances iterator convergence checks in the BPF verifier by implementing exact states comparison.', 'keywords': 'iterator, convergence, verifier', 'commit_classification': "It's a bug fix.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b4d8239534fddc036abe4a0fdbf474d9894d4641 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b4d8239534fddc036abe4a0fdbf474d9894d4641 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1698122972 + Commit Message: + bpf: print full verifier states on infinite loop detection + +Additional logging in is_state_visited(): if infinite loop is detected +print full verifier state for both current and equivalent states. + +Acked-by: Andrii Nakryiko +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-8-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 64870feebecb7130291a55caf0ce839a87405a70 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add logging to print full verifier states when an infinite loop is detected in eBPF programs.', 'keywords': 'verifier,logging,infinite loop', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 64870feebecb7130291a55caf0ce839a87405a70 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 64870feebecb7130291a55caf0ce839a87405a70 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1698122972 + Commit Message: + selftests/bpf: test if state loops are detected in a tricky case + +A convoluted test case for iterators convergence logic that +demonstrates that states with branch count equal to 0 might still be +a part of not completely explored loop. + +E.g. consider the following state diagram: + + initial Here state 'succ' was processed first + Parent Hashes: 2a0992829ea3864939d917a5c7b48be6629c6217 + Refs: + | it was eventually tracked to produce a + V state identical to 'hdr'. + .---------> hdr All branches from 'succ' had been explored + | | and thus 'succ' has its .branches == 0. + | V + | .------... Suppose states 'cur' and 'succ' correspond + | | | to the same instruction + callsites. + | V V In such case it is necessary to check + | ... ... whether 'succ' and 'cur' are identical. + | | | If 'succ' and 'cur' are a part of the same loop + | V V they have to be compared exactly. + | succ <- cur + | | + | V + | ... + | | + '----' + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-7-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds a test to ensure state loops are detected in complex cases within eBPF selftests.', 'keywords': 'state loops,test case,iterators', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2a0992829ea3864939d917a5c7b48be6629c6217 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2a0992829ea3864939d917a5c7b48be6629c6217 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1698122972 + Commit Message: + bpf: correct loop detection for iterators convergence + +It turns out that .branches > 0 in is_state_visited() is not a +sufficient condition to identify if two verifier states form a loop +when iterators convergence is computed. This commit adds logic to +distinguish situations like below: + + (I) initial (II) initial + | | + V V + .---------> hdr .. + | | | + | V V + | .------... .------.. + | | | | | + | V V V V + | ... ... .-> hdr .. + | | | | | | + | V V | V V + | succ <- cur | succ <- cur + | | | | + | V | V + | ... | ... + | | | | + '----' '----' + +For both (I) and (II) successor 'succ' of the current state 'cur' was +previously explored and has branches count at 0. However + Parent Hashes: 389ede06c2974b2f878a7ebff6b0f4f707f9db74 + Refs: loop entry +'hdr' corresponding to 'succ' might be a part of current DFS path. +If that is the case 'succ' and 'cur' are members of the same loop +and have to be compared exactly. + +Co-developed-by: Andrii Nakryiko +Co-developed-by: Alexei Starovoitov +Reviewed-by: Andrii Nakryiko +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-6-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Correct loop detection logic for iterators convergence in the eBPF verifier.', 'keywords': 'loop detection, iterators, verifier', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 389ede06c2974b2f878a7ebff6b0f4f707f9db74 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 389ede06c2974b2f878a7ebff6b0f4f707f9db74 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1698122971 + Commit Message: + selftests/bpf: tests with delayed read/precision makrs in loop body + +These test cases try to hide read and precision marks from loop +convergence logic: marks would only be assigned on subsequent loop +iterations or after exploring states pushed to env->head stack first. +Without verifier fix to use exact states comparison logic for +iterators convergence these tests (except 'triple_continue') would be +errorneously marked as safe. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-5-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 2793a8b015f7f1caadb9bce9c63dc659f7522676 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce selftests for BPF validating delayed read and precision marks in loop convergence logic.', 'keywords': 'selftests,loop,verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 2793a8b015f7f1caadb9bce9c63dc659f7522676 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2793a8b015f7f1caadb9bce9c63dc659f7522676 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1698122971 + Commit Message: + bpf: exact states comparison for iterator convergence checks + +Convergence for open coded iterators is computed in is_state_visited() +by examining states with branches count > 1 and using states_equal(). +states_equal() computes sub-state relation using read and precision marks. +Read and precision marks are propagated from children states + Parent Hashes: 4c97259abc9bc8df7712f76f58ce385581876857 + Refs: +thus are not guaranteed to be complete inside a loop when branches +count > 1. This could be demonstrated using the following unsafe program: + + 1. r7 = -16 + 2. r6 = bpf_get_prandom_u32() + 3. while (bpf_iter_num_next(&fp[-8])) { + 4. if (r6 != 42) { + 5. r7 = -32 + 6. r6 = bpf_get_prandom_u32() + 7. continue + 8. } + 9. r0 = r10 + 10. r0 += r7 + 11. r8 = *(u64 *)(r0 + 0) + 12. r6 = bpf_get_prandom_u32() + 13. } + +Here verifier would first visit path 1-3 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhanced state comparison for open coded iterator convergence checks in the BPF verifier.', 'keywords': 'exact state comparison, convergence, iterators', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4c97259abc9bc8df7712f76f58ce385581876857 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4c97259abc9bc8df7712f76f58ce385581876857 + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1698122971 + Commit Message: + bpf: extract same_callsites() as utility function + +Extract same_callsites() from clean_live_states() as a utility function. +This function would be used by the next patch in the set. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-3-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 3c4e420cb6536026ddd50eaaff5f30e4f144200d + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Extracted same_callsites() as a utility function for reuse.', 'keywords': 'utility,function,extraction', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3c4e420cb6536026ddd50eaaff5f30e4f144200d +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3c4e420cb6536026ddd50eaaff5f30e4f144200d + Author Name: Eduard Zingerman + Author Email: eddyz87@gmail.com + Commit Date: 1698122971 + Commit Message: + bpf: move explored_state() closer to the beginning of verifier.c + +Subsequent patches would make use of explored_state() function. +Move it up to avoid adding unnecessary prototype. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-2-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: b63dadd6f97522513fe9497b5fde84a154e39a0b + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The explored_state() function is moved to the beginning of verifier.c for upcoming patches.', 'keywords': 'explored_state, verifier, function', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: efb3e0e1649f944c032095e3f0533a235a7477d3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: efb3e0e1649f944c032095e3f0533a235a7477d3 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1698113691 + Commit Message: + Merge branch 'introduce-page_pool_alloc-related-api' + +Yunsheng Lin says: + +==================== +introduce page_pool_alloc() related API + +In [1] & [2] & [3] + Parent Hashes: f4dbc2bb7a54d3bff234a9f1915f1b7187bedb1f 2d0de67da51a90c6acf7bf08d7b0501f45408002 + Refs: there are usecases for veth and virtio_net +to use frag support in page pool to reduce memory usage + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce page_pool_alloc related API to support fragmentation in page pool, optimizing memory usage.', 'keywords': 'page_pool_alloc, API, memory', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b63dadd6f97522513fe9497b5fde84a154e39a0b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b63dadd6f97522513fe9497b5fde84a154e39a0b + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1698098513 + Commit Message: + bpf + Parent Hashes: 69a19170303ff2f802049be94cfcf62f714002a3 + Refs: tcx: Get rid of tcx_link_const + +Small clean up to get rid of the extra tcx_link_const() and only retain +the tcx_link(). + +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/r/20231023185015.21152-1-daniel@iogearbox.net +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove redundant tcx_link_const() to simplify code by retaining only tcx_link() usage.', 'keywords': 'cleanup, tcx_link, simplification', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 69a19170303ff2f802049be94cfcf62f714002a3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 69a19170303ff2f802049be94cfcf62f714002a3 + Author Name: Denys Zagorui + Author Email: dzagorui@cisco.com + Commit Date: 1698080295 + Commit Message: + samples: bpf: Fix syscall_tp openat argument + +This modification doesn't change behaviour of the syscall_tp +But such code is often used as a reference so it should be +correct anyway + +Signed-off-by: Denys Zagorui +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231019113521.4103825-1-dzagorui@cisco.com + + Parent Hashes: cf559a416f9bc061f3b96f8afc6ceae5eec9b2b0 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Corrected the syscall_tp openat argument in BPF samples for improved reference accuracy.', 'keywords': 'syscall_tp, openat, BPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: 90d862f370b6e9de1b5d607843c5a2f9823990f3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 90d862f370b6e9de1b5d607843c5a2f9823990f3 + Author Name: Hari Bathini + Author Email: hbathini@linux.ibm.com + Commit Date: 1698053599 + Commit Message: + powerpc/bpf: use bpf_jit_binary_pack_[alloc|finalize|free] + +Use bpf_jit_binary_pack_alloc in powerpc jit. The jit engine first +writes the program to the rw buffer. When the jit is done + Parent Hashes: de04e40600ae15fa5e484be242e74aad6de7418f + Refs: the program +is copied to the final location with bpf_jit_binary_pack_finalize. +With multiple jit_subprogs + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enable bpf_jit_binary_pack_usage in PowerPC JIT engine for enhanced program execution.', 'keywords': 'PowerPC,JIT,bpf_jit_binary_pack', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: de04e40600ae15fa5e484be242e74aad6de7418f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: de04e40600ae15fa5e484be242e74aad6de7418f + Author Name: Hari Bathini + Author Email: hbathini@linux.ibm.com + Commit Date: 1698053599 + Commit Message: + powerpc/bpf: rename powerpc64_jit_data to powerpc_jit_data + +powerpc64_jit_data is a misnomer as it is meant for both ppc32 and +ppc64. Rename it to powerpc_jit_data. + +Signed-off-by: Hari Bathini +Acked-by: Song Liu +Signed-off-by: Michael Ellerman +Link: https://msgid.link/20231020141358.643575-5-hbathini@linux.ibm.com + + + Parent Hashes: 033ffaf0af1f974ecf401db3f70aae6fe1a90fc5 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit renames powerpc64_jit_data to powerpc_jit_data for consistency across ppc32 and ppc64.', 'keywords': 'renaming, powerpc, jit', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The JIT compiler', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 033ffaf0af1f974ecf401db3f70aae6fe1a90fc5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 033ffaf0af1f974ecf401db3f70aae6fe1a90fc5 + Author Name: Hari Bathini + Author Email: hbathini@linux.ibm.com + Commit Date: 1698053599 + Commit Message: + powerpc/bpf: implement bpf_arch_text_invalidate for bpf_prog_pack + +Implement bpf_arch_text_invalidate and use it to fill unused part of +the bpf_prog_pack with trap instructions when a BPF program is freed. + +Signed-off-by: Hari Bathini +Acked-by: Song Liu +Signed-off-by: Michael Ellerman +Link: https://msgid.link/20231020141358.643575-4-hbathini@linux.ibm.com + + + Parent Hashes: 6efc1675acb88eef45ef0156b93f95d66a8ee759 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement bpf_arch_text_invalidate to manage unused areas in bpf_prog_pack for powerpc.', 'keywords': 'powerpc,bpf_arch_text_invalidate,bpf_prog_pack', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6efc1675acb88eef45ef0156b93f95d66a8ee759 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6efc1675acb88eef45ef0156b93f95d66a8ee759 + Author Name: Hari Bathini + Author Email: hbathini@linux.ibm.com + Commit Date: 1698053599 + Commit Message: + powerpc/bpf: implement bpf_arch_text_copy + +bpf_arch_text_copy is used to dump JITed binary to RX page + Parent Hashes: 465cabc97b42405eb89380ea6ba8d8b03e4ae1a2 + Refs: allowing +multiple BPF programs to share the same page. Use the newly introduced +patch_instructions() to implement it. + +Signed-off-by: Hari Bathini +Acked-by: Song Liu +Signed-off-by: Michael Ellerman +Link: https://msgid.link/20231020141358.643575-3-hbathini@linux.ibm.com + + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Implement bpf_arch_text_copy for dumping JITed binary to RX page in powerpc architecture.', 'keywords': 'powerpc,JITed binary,bpf_arch_text_copy', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9c5d00cb7b6bbc5a7965d9ab7d223b5402d1f02c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9c5d00cb7b6bbc5a7965d9ab7d223b5402d1f02c + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1697838564 + Commit Message: + Merge tag 'perf-tools-fixes-for-v6.6-2-2023-10-20' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools + +Pull perf tools fixes from Arnaldo Carvalho de Melo: + + - Fix regression in reading scale and unit files from sysfs for PMU + events + Parent Hashes: 444ccf1b11a0dbc54e789d6d2634c2649dc27498 4fa008a2db484024a5cb52676a1b1534dc82330c + Refs: so that we can use that info to pretty print instead of + printing raw numbers: + + # perf stat -e power/energy-ram/ + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge perf tool fixes for improved PMU event parsing from sysfs to enhance pretty printing in perf stat outputs.', 'keywords': 'perf tools, regression, PMU', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: cf559a416f9bc061f3b96f8afc6ceae5eec9b2b0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cf559a416f9bc061f3b96f8afc6ceae5eec9b2b0 + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1697836513 + Commit Message: + Merge branch 'bpf-fixes-for-per-cpu-kptr' + +Hou Tao says: + +==================== +bpf: Fixes for per-cpu kptr + +From: Hou Tao + +Hi + Parent Hashes: da1055b673f3baac2249571c9882ce767a0aa746 d440ba91ca4d3004709876779d40713a99e21f6a + Refs: + +The patchset aims to fix the problems found in the review of per-cpu +kptr patch-set [0]. Patch #1 moves pcpu_lock after the invocation of +pcpu_chunk_addr_search() and it is a micro-optimization for +free_percpu(). The reason includes it in the patch is that the same +logic is used in newly-added API pcpu_alloc_size(). Patch #2 introduces +pcpu_alloc_size() for dynamic per-cpu area. Patch #2 and #3 use +pcpu_alloc_size() to check whether or not unit_size matches with the +size of underlying per-cpu area and to select a matching bpf_mem_cache. +Patch #4 fixes the freeing of per-cpu kptr when these kptrs are freed by +map destruction. The last patch adds test cases for these problems. + +Please see individual patches for details. And comments are always +welcome. + +Change Log: +v3: + * rebased on bpf-next + * patch 2: update API document to note that pcpu_alloc_size() doesn't + support statically allocated per-cpu area. (Dennis) + * patch 1 & 2: add Acked-by from Dennis + +v2: https://lore.kernel.org/bpf/20231018113343.2446300-1-houtao@huaweicloud.com/ + * add a new patch "don't acquire pcpu_lock for pcpu_chunk_addr_search()" + * patch 2: change type of bit_off and end to unsigned long (Andrew) + * patch 2: rename the new API as pcpu_alloc_size and follow 80-column convention (Dennis) + * patch 5: move the common declaration into bpf.h (Stanislav + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit addresses fixes for per-cpu kptr handling in eBPF, including a micro-optimization and test cases addition.', 'keywords': 'per-cpu,kptr,fixed', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: d440ba91ca4d3004709876779d40713a99e21f6a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d440ba91ca4d3004709876779d40713a99e21f6a + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1697836513 + Commit Message: + selftests/bpf: Add more test cases for bpf memory allocator + +Add the following 3 test cases for bpf memory allocator: +1) Do allocation in bpf program and free through map free +2) Do batch per-cpu allocation and per-cpu free in bpf program +3) Do per-cpu allocation in bpf program and free through map free + +For per-cpu allocation + Parent Hashes: e383a45902337356d9ccad797094a27c6b2150f9 + Refs: because per-cpu allocation can not refill timely +sometimes + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added test cases for memory allocation and management in bpf programs.', 'keywords': 'bpf,test cases,allocator', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e383a45902337356d9ccad797094a27c6b2150f9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e383a45902337356d9ccad797094a27c6b2150f9 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1697836513 + Commit Message: + bpf: Use bpf_global_percpu_ma for per-cpu kptr in __bpf_obj_drop_impl() + +The following warning was reported when running "./test_progs -t +test_bpf_ma/percpu_free_through_map_free": + + ------------[ cut here ]------------ + WARNING: CPU: 1 PID: 68 at kernel/bpf/memalloc.c:342 + CPU: 1 PID: 68 Comm: kworker/u16:2 Not tainted 6.6.0-rc2+ #222 + Hardware name: QEMU Standard PC (i440FX + PIIX + Parent Hashes: e581a3461de3f129cfe888a67d9f31086328271f + Refs: 1996) + Workqueue: events_unbound bpf_map_free_deferred + RIP: 0010:bpf_mem_refill+0x21c/0x2a0 + ...... + Call Trace: + + ? bpf_mem_refill+0x21c/0x2a0 + irq_work_single+0x27/0x70 + irq_work_run_list+0x2a/0x40 + irq_work_run+0x18/0x40 + __sysvec_irq_work+0x1c/0xc0 + sysvec_irq_work+0x73/0x90 + + + asm_sysvec_irq_work+0x1b/0x20 + RIP: 0010:unit_free+0x50/0x80 + ...... + bpf_mem_free+0x46/0x60 + __bpf_obj_drop_impl+0x40/0x90 + bpf_obj_free_fields+0x17d/0x1a0 + array_map_free+0x6b/0x170 + bpf_map_free_deferred+0x54/0xa0 + process_scheduled_works+0xba/0x370 + worker_thread+0x16d/0x2e0 + kthread+0x105/0x140 + ret_from_fork+0x39/0x60 + ret_from_fork_asm+0x1b/0x30 + + ---[ end trace 0000000000000000 ]--- + +The reason is simple: __bpf_obj_drop_impl() does not know the freeing +field is a per-cpu pointer and it uses bpf_global_ma to free the +pointer. Because bpf_global_ma is not a per-cpu allocator + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes per-cpu kptr allocation issue in __bpf_obj_drop_impl related to bpf_global_percpu_ma.', 'keywords': 'per-cpu,kptr,bpf_global_percpu_ma', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: e581a3461de3f129cfe888a67d9f31086328271f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e581a3461de3f129cfe888a67d9f31086328271f + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1697836513 + Commit Message: + bpf: Move the declaration of __bpf_obj_drop_impl() to bpf.h + +both syscall.c and helpers.c have the declaration of +__bpf_obj_drop_impl() + Parent Hashes: 3f2189e4f77b7a3e979d143dc4ff586488c7e8a5 + Refs: so just move it to a common header file. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231020133202.4043247-6-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The declaration of __bpf_obj_drop_impl() is moved to a common header file bpf.h.', 'keywords': 'declaration, bpf_obj_drop_impl, header', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3f2189e4f77b7a3e979d143dc4ff586488c7e8a5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3f2189e4f77b7a3e979d143dc4ff586488c7e8a5 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1697836513 + Commit Message: + bpf: Use pcpu_alloc_size() in bpf_mem_free{_rcu}() + +For bpf_global_percpu_ma + Parent Hashes: baa8fdecd87bb8751237b45e3bcb5a179e5a12ca + Refs: the pointer passed to bpf_mem_free_rcu() is +allocated by kmalloc() and its size is fixed (16-bytes on x86-64). So +no matter which cache allocates the dynamic per-cpu area + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Optimize memory allocation in bpf_mem_free_rcu using pcpu_alloc_size.', 'keywords': 'pcpu_alloc_size, bpf_mem_free_rcu, optimization', 'commit_classification': "It's a performance optimization.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: baa8fdecd87bb8751237b45e3bcb5a179e5a12ca +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: baa8fdecd87bb8751237b45e3bcb5a179e5a12ca + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1697836513 + Commit Message: + bpf: Re-enable unit_size checking for global per-cpu allocator + +With pcpu_alloc_size() in place + Parent Hashes: b460bc8302f222d346f0c15bba980eb8c36d6278 + Refs: check whether or not the size of +the dynamic per-cpu area is matched with unit_size. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231020133202.4043247-4-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Re-enable unit size checking for global per-cpu allocator in eBPF.', 'keywords': 'unit size, per-cpu allocator, checking', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF maps', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: b460bc8302f222d346f0c15bba980eb8c36d6278 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b460bc8302f222d346f0c15bba980eb8c36d6278 + Author Name: Hou Tao + Author Email: houtao1@huawei.com + Commit Date: 1697836506 + Commit Message: + mm/percpu.c: introduce pcpu_alloc_size() + +Introduce pcpu_alloc_size() to get the size of the dynamic per-cpu +area. It will be used by bpf memory allocator in the following patches. +BPF memory allocator maintains per-cpu area caches for multiple area +sizes and its free API only has the to-be-freed per-cpu pointer + Parent Hashes: 394e6869f0185e89cb815db29bf819474df858ae + Refs: so it +needs the size of dynamic per-cpu area to select the corresponding cache +when bpf program frees the dynamic per-cpu pointer. + +Acked-by: Dennis Zhou +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231020133202.4043247-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce pcpu_alloc_size() to assist BPF memory allocator in managing per-cpu area caches.', 'keywords': 'pcpu_alloc_size,dynamic,per-cpu', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: da1055b673f3baac2249571c9882ce767a0aa746 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: da1055b673f3baac2249571c9882ce767a0aa746 + Author Name: Kumar Kartikeya Dwivedi + Author Email: memxor@gmail.com + Commit Date: 1697819379 + Commit Message: + selftests/bpf: Make linked_list failure test more robust + +The linked list failure test 'pop_front_off' and 'pop_back_off' +currently rely on matching exact instruction and register values. The +purpose of the test is to ensure the offset is correctly incremented for +the returned pointers from list pop helpers + Parent Hashes: bab8ac3c5339d7ec5312dcd836cfa8645edb954f + Refs: which can then be used with +container_of to obtain the real object. Hence + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improved robustness of linked list failure test in selftests/bpf by ensuring accurate offset increment for list pop helpers.', 'keywords': 'linked list,test robustness,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 5069211e2f0b47e75119805e23ae6352d871e263 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 5069211e2f0b47e75119805e23ae6352d871e263 + Author Name: Thomas Richter + Author Email: tmricht@linux.ibm.com + Commit Date: 1697780506 + Commit Message: + perf trace: Use the right bpf_probe_read(_str) variant for reading user data + +Perf test case 111 Check open filename arg using perf trace + vfs_getname +fails on s390. This is caused by a failing function +bpf_probe_read() in file util/bpf_skel/augmented_raw_syscalls.bpf.c. + +The root cause is the lookup by address. Function bpf_probe_read() +is used. This function works only for architectures +with ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE. + +On s390 is not possible to determine from the address to which +address space the address belongs to (user or kernel space). + +Replace bpf_probe_read() by bpf_probe_read_kernel() +and bpf_probe_read_str() by bpf_probe_read_user_str() to +explicity specify the address space the address refers to. + +Output before: + # ./perf trace -eopen + Parent Hashes: 1f36b190ad2dea68e3a7e84b7b2f24ce8c4063ea + Refs: openat -- touch /tmp/111 + libbpf: prog 'sys_enter': BPF program load failed: Invalid argument + libbpf: prog 'sys_enter': -- BEGIN PROG LOAD LOG -- + reg type unsupported for arg#0 function sys_enter#75 + 0: R1=ctx(off=0 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix bpf_probe_read variant usage for user data reading in perf tool on s390 architecture.', 'keywords': 'perf,bpf_probe_read,s390', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 4fa008a2db484024a5cb52676a1b1534dc82330c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4fa008a2db484024a5cb52676a1b1534dc82330c + Author Name: Arnaldo Carvalho de Melo + Author Email: acme@redhat.com + Commit Date: 1697765638 + Commit Message: + tools build: Fix llvm feature detection + Parent Hashes: f38f547314b858b94d36aeb9a4401f0aade7d1af + Refs: still used by bpftool + +When removing the BPF event for perf a feature test that checks if the +llvm devel files are availabe was removed but that is also used by +bpftool. + +bpftool uses it to decide what kind of disassembly it will use: llvm or +binutils based. + +Removing the tools/build/feature/test-llvm.cpp file made bpftool to +always fallback to binutils disassembly + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes llvm feature detection in tools build affecting bpftool disassembly selection.', 'keywords': 'llvm,bpftool,disassembly', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: bab8ac3c5339d7ec5312dcd836cfa8645edb954f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bab8ac3c5339d7ec5312dcd836cfa8645edb954f + Author Name: Alexei Starovoitov + Author Email: ast@kernel.org + Commit Date: 1697760167 + Commit Message: + Merge branch 'add-open-coded-task-css_task-and-css-iters' + +Chuyi Zhou says: + +==================== +Add Open-coded task + Parent Hashes: 6bd5e167af2e9d1aa79e4a1a2598abcdc8fafd59 130e0f7af9fc7388b90fb016ca13ff3840c48d4a + Refs: css_task and css iters + +This is version 6 of task + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit merges changes introducing open-coded task iterations, adding new task and CSS iteration features.', 'keywords': 'open-coded, task, CSS', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 130e0f7af9fc7388b90fb016ca13ff3840c48d4a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 130e0f7af9fc7388b90fb016ca13ff3840c48d4a + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1697760167 + Commit Message: + selftests/bpf: Add tests for open-coded task and css iter + +This patch adds 4 subtests to demonstrate these patterns and validating +correctness. + +subtest1: + +1) We use task_iter to iterate all process in the system and search for the +current process with a given pid. + +2) We create some threads in current process context + Parent Hashes: ddab78cbb52f81f7f7598482602342955b2ff8b8 + Refs: and use +BPF_TASK_ITER_PROC_THREADS to iterate all threads of current process. As +expected + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces four subtests for open-coded task and CSS iterator patterns in selftests for BPF.', 'keywords': 'tests,selftests,BPF', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ddab78cbb52f81f7f7598482602342955b2ff8b8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ddab78cbb52f81f7f7598482602342955b2ff8b8 + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1697760167 + Commit Message: + selftests/bpf: rename bpf_iter_task.c to bpf_iter_tasks.c + +The newly-added struct bpf_iter_task has a name collision with a selftest +for the seq_file task iter's bpf skel + Parent Hashes: cb3ecf7915a1d7ce5304402f4d8616d9fa5193f7 + Refs: so the selftests/bpf/progs file is +renamed in order to avoid the collision. + +Signed-off-by: Chuyi Zhou +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231018061746.111364-8-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Renamed bpf_iter_task.c to bpf_iter_tasks.c in selftests to avoid a name collision.', 'keywords': 'rename, selftests, collision', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs']} +-------------------- +-------------------- +Processing Commit ID: cb3ecf7915a1d7ce5304402f4d8616d9fa5193f7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cb3ecf7915a1d7ce5304402f4d8616d9fa5193f7 + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1697760166 + Commit Message: + bpf: Let bpf_iter_task_new accept null task ptr + +When using task_iter to iterate all threads of a specific task + Parent Hashes: dfab99df147b0d364f0c199f832ff2aedfb2265a + Refs: we enforce +that the user must pass a valid task pointer to ensure safety. However + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows bpf_iter_task_new to accept a null task pointer for iterating threads.', 'keywords': 'bpf, task_ptr, iter', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: dfab99df147b0d364f0c199f832ff2aedfb2265a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: dfab99df147b0d364f0c199f832ff2aedfb2265a + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1697760166 + Commit Message: + bpf: teach the verifier to enforce css_iter and task_iter in RCU CS + +css_iter and task_iter should be used in rcu section. Specifically + Parent Hashes: 7251d0905e7518bcb990c8e9a3615b1bb23c78f2 + Refs: in +sleepable progs explicit bpf_rcu_read_lock() is needed before use these +iters. In normal bpf progs that have implicit rcu_read_lock() + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit enforces css_iter and task_iter usage in RCU critical sections within BPF programs.', 'keywords': 'verifier,css_iter,RCU', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 7251d0905e7518bcb990c8e9a3615b1bb23c78f2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7251d0905e7518bcb990c8e9a3615b1bb23c78f2 + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1697760166 + Commit Message: + bpf: Introduce css open-coded iterator kfuncs + +This Patch adds kfuncs bpf_iter_css_{new + Parent Hashes: c68a78ffe2cb4207f64fd0f4262818c728c67be0 + Refs: next + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit introduces kfuncs for open-coded iterator in eBPF.', 'keywords': 'kfuncs, iterator, bpf', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: c68a78ffe2cb4207f64fd0f4262818c728c67be0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c68a78ffe2cb4207f64fd0f4262818c728c67be0 + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1697760166 + Commit Message: + bpf: Introduce task open coded iterator kfuncs + +This patch adds kfuncs bpf_iter_task_{new + Parent Hashes: 9c66dc94b62aef23300f05f63404afb8990920b4 + Refs: next + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces task open coded iterator kfuncs for eBPF.', 'keywords': 'bpf, task, kfuncs', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9c66dc94b62aef23300f05f63404afb8990920b4 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9c66dc94b62aef23300f05f63404afb8990920b4 + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1697760166 + Commit Message: + bpf: Introduce css_task open-coded iterator kfuncs + +This patch adds kfuncs bpf_iter_css_task_{new + Parent Hashes: 6da88306811b40a207c94c9da9faf07bdb20776e + Refs: next + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduce open-coded iterator kfuncs for css_task in bpf.', 'keywords': 'bpf, kfuncs, iterator', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 6da88306811b40a207c94c9da9faf07bdb20776e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6da88306811b40a207c94c9da9faf07bdb20776e + Author Name: Chuyi Zhou + Author Email: zhouchuyi@bytedance.com + Commit Date: 1697760166 + Commit Message: + cgroup: Prepare for using css_task_iter_*() in BPF + +This patch makes some preparations for using css_task_iter_*() in BPF +Program. + +1. Flags CSS_TASK_ITER_* are #define-s and it's not easy for bpf prog to +use them. Convert them to enum so bpf prog can take them from vmlinux.h. + +2. In the next patch we will add css_task_iter_*() in common kfuncs which +is not safe. Since css_task_iter_*() does spin_unlock_irq() which might +screw up irq flags depending on the context where bpf prog is running. +So we should use irqsave/irqrestore here and the switching is harmless. + +Suggested-by: Alexei Starovoitov +Signed-off-by: Chuyi Zhou +Acked-by: Tejun Heo +Link: https://lore.kernel.org/r/20231018061746.111364-2-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov + + Parent Hashes: 6bd5e167af2e9d1aa79e4a1a2598abcdc8fafd59 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Prepare for using css_task_iter functions in BPF by converting defines to enums and addressing irq issues.', 'keywords': 'css_task_iter, BPF, preparation', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: b9ec913212e6e91efa5a0a612c4a8ec4cf5da896 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b9ec913212e6e91efa5a0a612c4a8ec4cf5da896 + Author Name: Breno Leitao + Author Email: leitao@debian.org + Commit Date: 1697755324 + Commit Message: + selftests/bpf/sockopt: Add io_uring support + +Expand the sockopt test to use also check for io_uring {g + Parent Hashes: 4232c6e349f3a591fd0f432e6b858d32095adce6 + Refs: s}etsockopt +commands operations. + +This patch starts by marking each test if they support io_uring support +or not. + +Right now + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds io_uring support to the sockopt selftests for checking setsockopt commands operations.', 'keywords': 'io_uring,sockopt,selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: 7746a6adfc81e2e0386a85117d5e8fd824da367b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7746a6adfc81e2e0386a85117d5e8fd824da367b + Author Name: Breno Leitao + Author Email: leitao@debian.org + Commit Date: 1697755323 + Commit Message: + tools headers: Grab copy of io_uring.h + +This file will be used by mini_uring.h and allow tests to run without +the need of installing liburing to run the tests. + +This is needed to run io_uring tests in BPF + Parent Hashes: 5fea44a6e05b86bf49019fbbf2ab30098d03e0dc + Refs: such as +(tools/testing/selftests/bpf/prog_tests/sockopt.c). + +Signed-off-by: Breno Leitao +Link: https://lore.kernel.org/r/20231016134750.1381153-7-leitao@debian.org +Signed-off-by: Jens Axboe + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit grabs a copy of io_uring.h for running io_uring tests without liburing installation.', 'keywords': 'io_uring,h,tests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 3f31e0d14d44ad491a81b7c1f83f32fbc300a867 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3f31e0d14d44ad491a81b7c1f83f32fbc300a867 + Author Name: Breno Leitao + Author Email: leitao@debian.org + Commit Date: 1697745937 + Commit Message: + bpf: Add sockptr support for setsockopt + +The whole network stack uses sockptr + Parent Hashes: a615f67e1a426f35366b8398c11f31c148e7df48 + Refs: and while it doesn't move to +something more modern + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add support for sockptr in the bpf setsockopt function.', 'keywords': 'sockptr, setsockopt, network', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: a615f67e1a426f35366b8398c11f31c148e7df48 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a615f67e1a426f35366b8398c11f31c148e7df48 + Author Name: Breno Leitao + Author Email: leitao@debian.org + Commit Date: 1697745928 + Commit Message: + bpf: Add sockptr support for getsockopt + +The whole network stack uses sockptr + Parent Hashes: 6ce4a93dbb5bd93bc2bdf14da63f9360a4dcd6a1 + Refs: and while it doesn't move to +something more modern + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit adds sockptr support for getsockopt in the BPF subsystem.', 'keywords': 'bpf,sockptr,getsockopt', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: ce55c22ec8b223a90ff3e084d842f73cfba35588 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ce55c22ec8b223a90ff3e084d842f73cfba35588 + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1697742498 + Commit Message: + Merge tag 'net-6.6-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + "Including fixes from bluetooth + Parent Hashes: 74e9347ebc5be452935fe4f3eddb150aa5a6f4fe 524515020f2552759a7ef1c9d03e7dac9b1ff3c2 + Refs: netfilter + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge network-related fixes for the Linux kernel, including updates from bluetooth.', 'keywords': 'networking, fixes, bluetooth', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 6bd5e167af2e9d1aa79e4a1a2598abcdc8fafd59 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 6bd5e167af2e9d1aa79e4a1a2598abcdc8fafd59 + Author Name: Manu Bretelle + Author Email: chantr4@gmail.com + Commit Date: 1697725815 + Commit Message: + bpftool: Wrap struct_ops dump in an array + +When dumping a struct_ops + Parent Hashes: 90704b4be0b0d6d0a7a9369d4b9aae6a579602c7 + Refs: 2 dictionaries are emitted. + +When using `name` + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Wraps struct_ops dump in an array within bpftool utility.', 'keywords': 'bpftool,struct_ops,array', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 90704b4be0b0d6d0a7a9369d4b9aae6a579602c7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 90704b4be0b0d6d0a7a9369d4b9aae6a579602c7 + Author Name: Manu Bretelle + Author Email: chantr4@gmail.com + Commit Date: 1697725776 + Commit Message: + bpftool: Fix printing of pointer value + +When printing a pointer value + Parent Hashes: 0e133a13370389d3894891eafe54fec2c44ad735 + Refs: "%p" will either print the hexadecimal +value of the pointer (e.g `0x1234`) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes the way bpftool prints pointer values to display them in hexadecimal format.', 'keywords': 'bpftool,pointer printing,bug fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 68b54aeff804acceb02f228ea2e28419272c1fb9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 68b54aeff804acceb02f228ea2e28419272c1fb9 + Author Name: Paolo Abeni + Author Email: pabeni@redhat.com + Commit Date: 1697677771 + Commit Message: + tcp_bpf: properly release resources on error paths + +In the blamed commit below + Parent Hashes: a13b67c9a015c4e21601ef9aa4ec9c5d972df1b4 + Refs: I completely forgot to release the acquired +resources before erroring out in the TCP BPF code + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes resource release on error paths in the TCP BPF code.', 'keywords': 'TCP BPF,release,errorpaths', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['socket like programs']} +-------------------- +-------------------- +Processing Commit ID: bdcb37a5d8de3253da48b120e3f10863696fb654 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bdcb37a5d8de3253da48b120e3f10863696fb654 + Author Name: Arnd Bergmann + Author Email: arnd@arndb.de + Commit Date: 1697677677 + Commit Message: + buildid: reduce header file dependencies for module + +The vmlinux decompressor code intentionally has only a limited set of +included header files + Parent Hashes: 6cb42f91aa6dfd10fd847c469caebe63b35141ff + Refs: but this started running into a build failure +because of the bitmap logic needing linux/errno.h: + +In file included from include/linux/cpumask.h:12 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit reduces header file dependencies for the vmlinux decompressor module to fix build failures.', 'keywords': 'header, dependencies, module', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 0e133a13370389d3894891eafe54fec2c44ad735 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0e133a13370389d3894891eafe54fec2c44ad735 + Author Name: Dave Thaler + Author Email: dthaler@microsoft.com + Commit Date: 1697672172 + Commit Message: + bpf + Parent Hashes: bb6a88885fde24835afdaa1c5bb976a1bf5c5d71 + Refs: docs: Define signed modulo as using truncated division + +There's different mathematical definitions (truncated + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Clarified the definition of signed modulo using truncated division in documentation.', 'keywords': 'signed modulo, truncated division, documentation', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b5c532e90478e134b66b067c2b0487526ac4161e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b5c532e90478e134b66b067c2b0487526ac4161e + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1697668187 + Commit Message: + tools/build: Fix -s detection code in tools/scripts/Makefile.include + +As Dmitry described in [1] changelog the current way of detecting +-s option is broken for new make. + +Changing the tools/build -s option detection the same way as it was +fixed for root Makefile in [1]. + +[1] 4bf73588165b ("kbuild: Port silent mode detection to future gnu make.") + +Cc: Dmitry Goncharov +Signed-off-by: Jiri Olsa +Tested-by: Arnaldo Carvalho de Melo +Acked-by: Namhyung Kim +Cc: Peter Zijlstra +Cc: KP Singh +Cc: Martin KaFai Lau +Cc: Song Liu +Cc: Yonghong Song +Cc: John Fastabend +Cc: Hao Luo +Cc: Ian Rogers +Cc: Stanislav Fomichev +Cc: Daniel Borkmann +Cc: Quentin Monnet +Cc: Arnaldo Carvalho de Melo +Cc: Andrii Nakryiko +Cc: Alexei Starovoitov +Cc: Ingo Molnar +Cc: Alexander Shishkin +Cc: bpf@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231008212251.236023-3-jolsa@kernel.org +Signed-off-by: Namhyung Kim + + Parent Hashes: d9997f7ffb137447aa2f820c26cb1e6f5890d978 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix detection of the -s option in Makefile for compatibility with new versions of GNU make.', 'keywords': 'detection, Makefile, compatibility', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: d9997f7ffb137447aa2f820c26cb1e6f5890d978 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d9997f7ffb137447aa2f820c26cb1e6f5890d978 + Author Name: Jiri Olsa + Author Email: jolsa@kernel.org + Commit Date: 1697668175 + Commit Message: + tools/build: Fix -s detection code in tools/build/Makefile.build + +As Dmitry described in [1] changelog the current way of detecting +-s option is broken for new make. + +Changing the tools/build -s option detection the same way as it was +fixed for root Makefile in [1]. + +[1] 4bf73588165b ("kbuild: Port silent mode detection to future gnu make.") + +Cc: Dmitry Goncharov +Signed-off-by: Jiri Olsa +Tested-by: Arnaldo Carvalho de Melo +Acked-by: Namhyung Kim +Cc: Peter Zijlstra +Cc: KP Singh +Cc: Martin KaFai Lau +Cc: Song Liu +Cc: Yonghong Song +Cc: John Fastabend +Cc: Hao Luo +Cc: Ian Rogers +Cc: Stanislav Fomichev +Cc: Daniel Borkmann +Cc: Quentin Monnet +Cc: Arnaldo Carvalho de Melo +Cc: Andrii Nakryiko +Cc: Alexei Starovoitov +Cc: Ingo Molnar +Cc: Alexander Shishkin +Cc: bpf@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231008212251.236023-2-jolsa@kernel.org +Signed-off-by: Namhyung Kim + + Parent Hashes: 9a13ee457a6e7a850ac1d145b0731b1d729b8f42 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix the -s option detection in tools/build/Makefile.build for compatibility with new make versions.', 'keywords': 'Fix, Makefile, tools', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 71ca5ee18708c1f9f086e20ac0a657009bcfe43a +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 71ca5ee18708c1f9f086e20ac0a657009bcfe43a + Author Name: Joe Perches + Author Email: joe@perches.com + Commit Date: 1697665402 + Commit Message: + get_maintainer: add --keywords-in-file option + +There were some recent attempts [1] [2] to make the K: field less noisy +and its behavior more obvious. Ultimately + Parent Hashes: ead5a727739fa63b94ccd281d848a503032444ee + Refs: a shift in the default +behavior and an associated command line flag is the best choice. + +Currently + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added an option to get_maintainer for filtering with keywords in the file.', 'keywords': 'get_maintainer, keywords, filtering', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 1bc628a756d93a7bed2f80914b15821bb9a4369c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1bc628a756d93a7bed2f80914b15821bb9a4369c + Author Name: Jeff Layton + Author Email: jlayton@kernel.org + Commit Date: 1697630910 + Commit Message: + bpf: convert to new timestamp accessors + +Convert to using the new inode timestamp accessor functions. + +Signed-off-by: Jeff Layton +Link: https://lore.kernel.org/r/20231004185347.80880-79-jlayton@kernel.org +Signed-off-by: Christian Brauner + + Parent Hashes: d162a3cf6ee1a64417e11693c1410d79878c9917 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates BPF code to use new inode timestamp accessors.', 'keywords': 'bpf, timestamp, accessors', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4b47b0fa4b15e0de916e7dd93cd787fdab208ff2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4b47b0fa4b15e0de916e7dd93cd787fdab208ff2 + Author Name: Muhammad Muzammil + Author Email: m.muzzammilashraf@gmail.com + Commit Date: 1697628420 + Commit Message: + powerpc/bpf: Fixed 'instead' typo in bpf_jit_build_body() + +Fixed 'instead' typo. + +Signed-off-by: Muhammad Muzammil +Signed-off-by: Michael Ellerman +Link: https://msgid.link/20231013053118.11221-1-m.muzzammilashraf@gmail.com + + + Parent Hashes: 1c7b4bc375c2a235e3dcb53c46111883df838e42 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Corrected a typo in the bpf_jit_build_body function for PowerPC architecture.', 'keywords': 'typo, bpf, PowerPC', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The JIT compiler', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: bb6a88885fde24835afdaa1c5bb976a1bf5c5d71 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: bb6a88885fde24835afdaa1c5bb976a1bf5c5d71 + Author Name: Larysa Zaremba + Author Email: larysa.zaremba@intel.com + Commit Date: 1697616508 + Commit Message: + selftests/bpf: Add options and frags to xdp_hw_metadata + +This is a follow-up to the commit 9b2b86332a9b ("bpf: Allow to use kfunc +XDP hints and frags together"). + +The are some possible implementations problems that may arise when providing +metadata specifically for multi-buffer packets + Parent Hashes: 24516309e330cd592c04d0467313d885584af4e8 + Refs: therefore there must be a +possibility to test such option separately. + +Add an option to use multi-buffer AF_XDP xdp_hw_metadata and mark used XDP +program as capable to use frags. + +As for now + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add an option to test XDP hardware metadata with multi-buffer and frags support in selftests.', 'keywords': 'XDP, metadata, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 24516309e330cd592c04d0467313d885584af4e8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 24516309e330cd592c04d0467313d885584af4e8 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1697572663 + Commit Message: + selftests/bpf: Add additional mprog query test coverage + +Add several new test cases which assert corner cases on the mprog query +mechanism + Parent Hashes: 44cb03f19b38c11cfc5bf76ea6d6885da210ded2 + Refs: for example + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add new test cases for mprog query to cover corner cases in selftests for BPF.', 'keywords': 'selftests, mprog, query', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: eff65ee26ed73f3ca635bac13c386a4538a608d8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: eff65ee26ed73f3ca635bac13c386a4538a608d8 + Author Name: Athira Rajeev + Author Email: atrajeev@linux.vnet.ibm.com + Commit Date: 1697571651 + Commit Message: + perf tests: Fix shellcheck warning in record_sideband.sh + +Running shellcheck on record_sideband.sh throws below +warning: + + In tests/shell/record_sideband.sh line 25: + if ! perf record -o ${perfdata} -BN --no-bpf-event -C $1 true 2>&1 >/dev/null + ^--^ SC2069: To redirect stdout+stderr + Parent Hashes: 47f5693c4ce9b2bf2364303a531423e43278d3b6 + Refs: 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify). + +This shows shellcheck warning SC2069 where the redirection +order needs to be fixed. Use "cmd > /dev/null 2>&1" to fix +the redirection of perf record output + +Fixes: 23b97c7ee963 ("perf test: Add test case for record sideband events") +Signed-off-by: Athira Rajeev +Reviewed-by: Kajol Jain +Acked-by: Namhyung Kim +Cc: disgoel@linux.vnet.ibm.com +Link: https://lore.kernel.org/r/20231013073021.99794-3-atrajeev@linux.vnet.ibm.com +Signed-off-by: Namhyung Kim + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes shellcheck warnings by correcting stdout and stderr redirection in record_sideband.sh script.', 'keywords': 'shellcheck, redirection, record_sideband.sh', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 44cb03f19b38c11cfc5bf76ea6d6885da210ded2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 44cb03f19b38c11cfc5bf76ea6d6885da210ded2 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1697560287 + Commit Message: + selftests/bpf: Add selftest for bpf_task_under_cgroup() in sleepable prog + +The result is as follows: + + $ tools/testing/selftests/bpf/test_progs --name=task_under_cgroup + #237 task_under_cgroup:OK + Summary: 1/0 PASSED + Parent Hashes: 29a7e00ffadddd8d68eff311de1bf12ae10687bb + Refs: 0 SKIPPED + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Added selftest for the bpf_task_under_cgroup function in sleepable program.', 'keywords': 'selftest,bpf_task_under_cgroup,sleepable', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 29a7e00ffadddd8d68eff311de1bf12ae10687bb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 29a7e00ffadddd8d68eff311de1bf12ae10687bb + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1697560061 + Commit Message: + bpf: Fix missed rcu read lock in bpf_task_under_cgroup() + +When employed within a sleepable program not under RCU protection + Parent Hashes: 9a675ba55a96a45a9fb69e6a5c43f80c6682e541 + Refs: the +use of 'bpf_task_under_cgroup()' may trigger a warning in the kernel log + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a missing RCU read lock in bpf_task_under_cgroup for sleepable programs.', 'keywords': 'RCU, bpf_task_under_cgroup, fix', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The helper and kfuncs', 'program_types_related': ['cgroup like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 9a675ba55a96a45a9fb69e6a5c43f80c6682e541 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9a675ba55a96a45a9fb69e6a5c43f80c6682e541 + Author Name: Sebastian Andrzej Siewior + Author Email: bigeasy@linutronix.de + Commit Date: 1697547723 + Commit Message: + net + Parent Hashes: 137df1189d128a6b5dee2f653e054b40ef36b94c + Refs: bpf: Add a warning if NAPI cb missed xdp_do_flush(). + +A few drivers were missing a xdp_do_flush() invocation after +XDP_REDIRECT. + +Add three helper functions each for one of the per-CPU lists. Return +true if the per-CPU list is non-empty and flush the list. + +Add xdp_do_check_flushed() which invokes each helper functions and +creates a warning if one of the functions had a non-empty list. + +Hide everything behind CONFIG_DEBUG_NET. + +Suggested-by: Jesper Dangaard Brouer +Signed-off-by: Sebastian Andrzej Siewior +Signed-off-by: Daniel Borkmann +Reviewed-by: Toke Høiland-Jørgensen +Acked-by: Jakub Kicinski +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20231016125738.Yt79p1uF@linutronix.de + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add warning for missed xdp_do_flush invocation in NAPI callbacks for XDP_REDIRECT.', 'keywords': 'xdp_do_flush,NAPI,warning', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['xdp like programs']} +-------------------- +-------------------- +Processing Commit ID: 137df1189d128a6b5dee2f653e054b40ef36b94c +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 137df1189d128a6b5dee2f653e054b40ef36b94c + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1697535800 + Commit Message: + libbpf: Don't assume SHT_GNU_verdef presence for SHT_GNU_versym section + +Fix too eager assumption that SHT_GNU_verdef ELF section is going to be +present whenever binary has SHT_GNU_versym section. It seems like either +SHT_GNU_verdef or SHT_GNU_verneed can be used + Parent Hashes: a3c2dd96487f1dd734c9443a3472c8dafa689813 + Refs: so failing on missing +SHT_GNU_verdef actually breaks use cases in production. + +One specific reported issue + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix assumption regarding SHT_GNU_verdef and SHT_GNU_versym ELF sections in libbpf.', 'keywords': 'SHT_GNU_verdef,SHT_GNU_versym,libbpf', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The libbpf library', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: a3c2dd96487f1dd734c9443a3472c8dafa689813 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: a3c2dd96487f1dd734c9443a3472c8dafa689813 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1697515533 + Commit Message: + Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-10-16 + +We've added 90 non-merge commits during the last 25 day(s) which contain +a total of 120 files changed + Parent Hashes: 90de47f020db086f7929e09f64efd0cf627d6869 99c9991f4e5d77328187187d0c921a3b62bfa998 + Refs: 3519 insertions(+) + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Merged 90 non-merge commits from the 'bpf-next' branch containing 120 files changed.", 'keywords': 'merge,bpf-next,files', 'commit_classification': "It's other type of commit.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 54a59aed395ce0f4177b5212e5746a6462de3ad9 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 54a59aed395ce0f4177b5212e5746a6462de3ad9 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1697476056 + Commit Message: + net + Parent Hashes: dccce1d7c04051bc25d3abbe7716d0ae7af9c28a + Refs: sched: Make tc-related drop reason more flexible + +Currently + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Refactor tc-related drop reasons for increased flexibility in network scheduling.', 'keywords': 'tc drop flexible', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['tc/netfilter like programs']} +-------------------- +-------------------- +Processing Commit ID: 99c9991f4e5d77328187187d0c921a3b62bfa998 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 99c9991f4e5d77328187187d0c921a3b62bfa998 + Author Name: Daniel Borkmann + Author Email: daniel@iogearbox.net + Commit Date: 1697456981 + Commit Message: + Merge branch 'bpf-log-improvements' + +Andrii Nakryiko says: + +==================== +This patch set fixes ambiguity in BPF verifier log output of SCALAR register +in the parts that emit umin/umax + Parent Hashes: 0e10fd4b7a6dd03cf6d1da293d5d50082917f0e0 1a8a315f008a58f54fecb012b928aa6a494435b3 + Refs: smin/smax + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improves BPF verifier log output for scalar register to fix umin/umax ambiguity.', 'keywords': 'BPF verifier, log, scalar', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 1a8a315f008a58f54fecb012b928aa6a494435b3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1a8a315f008a58f54fecb012b928aa6a494435b3 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1697456958 + Commit Message: + bpf: Ensure proper register state printing for cond jumps + +Verifier emits relevant register state involved in any given instruction +next to it after `;` to the right + Parent Hashes: 72f8a1de4a7ecb23393a920dface58d5a96f42d8 + Refs: if possible. Or + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Ensure correct register state printing for conditional jumps in the eBPF verifier.', 'keywords': 'register, verifier, cond jumps', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 72f8a1de4a7ecb23393a920dface58d5a96f42d8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 72f8a1de4a7ecb23393a920dface58d5a96f42d8 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1697456958 + Commit Message: + bpf: Disambiguate SCALAR register state output in verifier logs + +Currently the way that verifier prints SCALAR_VALUE register state (and +PTR_TO_PACKET + Parent Hashes: cde785142885e1fc62a9ae92e7aae90285ed3d79 + Refs: which can have var_off and ranges info as well) is very +ambiguous. + +In the name of brevity we are trying to eliminate "unnecessary" output +of umin/umax + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improve the clarity of SCALAR register state outputs in bpf verifier logs.', 'keywords': 'verifier, SCALAR, disambiguate', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF verifier', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: cde785142885e1fc62a9ae92e7aae90285ed3d79 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: cde785142885e1fc62a9ae92e7aae90285ed3d79 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1697456958 + Commit Message: + selftests/bpf: Make align selftests more robust + +Align subtest is very specific and finicky about expected verifier log +output and format. This is often completely unnecessary as in a bunch of +situations test actually cares about var_off part of register state. But +given how exact it is right now + Parent Hashes: 08a7078feacf419305d86d36b974c48347f3abb0 + Refs: any tiny verifier log changes can lead +to align tests failures + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improves robustness of align selftests by focusing on var_off part of register state in verifier logs.', 'keywords': 'selftests, align, verifier', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 08a7078feacf419305d86d36b974c48347f3abb0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 08a7078feacf419305d86d36b974c48347f3abb0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1697456958 + Commit Message: + selftests/bpf: Improve missed_kprobe_recursion test robustness + +Given missed_kprobe_recursion is non-serial and uses common testing +kfuncs to count number of recursion misses it's possible that some other +parallel test can trigger extraneous recursion misses. So we can't +expect exactly 1 miss. Relax conditions and expect at least one. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Acked-by: John Fastabend +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231011223728.3188086-3-andrii@kernel.org + + Parent Hashes: 2d78928c9cf7bee08c3e2344e6e1755412855448 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Improves robustness of missed_kprobe_recursion test by relaxing conditions on recursion misses.', 'keywords': 'robustness,test,recursion', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['kprobe/uprobe/ftrace like programs']} +-------------------- +-------------------- +Processing Commit ID: 2d78928c9cf7bee08c3e2344e6e1755412855448 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 2d78928c9cf7bee08c3e2344e6e1755412855448 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1697456958 + Commit Message: + selftests/bpf: Improve percpu_alloc test robustness + +Make these non-serial tests filter BPF programs by intended PID of +a test runner process. This makes it isolated from other parallel tests +that might interfere accidentally. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: John Fastabend +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231011223728.3188086-2-andrii@kernel.org + + Parent Hashes: 0e10fd4b7a6dd03cf6d1da293d5d50082917f0e0 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit improves robustness of the percpu_alloc test by isolating BPF programs using intended PID to avoid interference.', 'keywords': 'percpu_alloc, BPF programs, robustness', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 0e10fd4b7a6dd03cf6d1da293d5d50082917f0e0 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0e10fd4b7a6dd03cf6d1da293d5d50082917f0e0 + Author Name: Andrii Nakryiko + Author Email: andrii@kernel.org + Commit Date: 1697237369 + Commit Message: + Merge branch 'Open-coded task_vma iter' + +Dave Marchevsky says: + +==================== +At Meta we have a profiling daemon which periodically collects +information on many hosts. This collection usually involves grabbing +stacks (user and kernel) using perf_event BPF progs and later symbolicating +them. For user stacks we try to use BPF_F_USER_BUILD_ID and rely on +remote symbolication + Parent Hashes: ba8ea72388a192c10f1ee5f5a4a32332e7cced76 e0e1a7a5fc377d54bd792c6368a375d41fc316ef + Refs: but BPF_F_USER_BUILD_ID doesn't always succeed. In +those cases we must fall back to digging around in /proc/PID/maps to map +virtual address to (binary + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': "Integration of 'Open-coded task_vma iter' for improved profiling with perf_event BPF programs.", 'keywords': 'profiling, perf_event, task_vma', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['profile like programs']} +-------------------- +-------------------- +Processing Commit ID: e0e1a7a5fc377d54bd792c6368a375d41fc316ef +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e0e1a7a5fc377d54bd792c6368a375d41fc316ef + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1697237338 + Commit Message: + selftests/bpf: Add tests for open-coded task_vma iter + +The open-coded task_vma iter added earlier in this series allows for +natural iteration over a task's vmas using existing open-coded iter +infrastructure + Parent Hashes: 4ac4546821584736798aaa9e97da9f6eaf689ea3 + Refs: specifically bpf_for_each. + +This patch adds a test demonstrating this pattern and validating +correctness. The vma->vm_start and vma->vm_end addresses of the first +1000 vmas are recorded and compared to /proc/PID/maps output. As +expected + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds tests for open-coded task_vma iterator in selftests/bpf.', 'keywords': 'task_vma, iterator, selftests', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 4ac4546821584736798aaa9e97da9f6eaf689ea3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 4ac4546821584736798aaa9e97da9f6eaf689ea3 + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1697237338 + Commit Message: + bpf: Introduce task_vma open-coded iterator kfuncs + +This patch adds kfuncs bpf_iter_task_vma_{new + Parent Hashes: 45b38941c81f16bb2e9b0115f03e164a3576ea8b + Refs: next + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Introduces task_vma open-coded iterator kernel functions for BPF.', 'keywords': 'task_vma, iterator, kfuncs', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: 45b38941c81f16bb2e9b0115f03e164a3576ea8b +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 45b38941c81f16bb2e9b0115f03e164a3576ea8b + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1697237338 + Commit Message: + selftests/bpf: Rename bpf_iter_task_vma.c to bpf_iter_task_vmas.c + +Further patches in this series will add a struct bpf_iter_task_vma + Parent Hashes: f10ca5da5bd71e5cefed7995e75a7c873ce3816e + Refs: +which will result in a name collision with the selftest prog renamed in +this patch. Rename the selftest to avoid the collision. + +Signed-off-by: Dave Marchevsky +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231013204426.1074286-3-davemarchevsky@fb.com + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Rename bpf_iter_task_vma.c to bpf_iter_task_vmas.c to avoid name collision with future patches in selftests.', 'keywords': 'rename,selftests,collision', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: f10ca5da5bd71e5cefed7995e75a7c873ce3816e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: f10ca5da5bd71e5cefed7995e75a7c873ce3816e + Author Name: Dave Marchevsky + Author Email: davemarchevsky@fb.com + Commit Date: 1697237338 + Commit Message: + bpf: Don't explicitly emit BTF for struct btf_iter_num + +Commit 6018e1f407cc ("bpf: implement numbers iterator") added the +BTF_TYPE_EMIT line that this patch is modifying. The struct btf_iter_num +doesn't exist + Parent Hashes: ba8ea72388a192c10f1ee5f5a4a32332e7cced76 + Refs: so only a forward declaration is emitted in BTF: + + FWD 'btf_iter_num' fwd_kind=struct + +That commit was probably hoping to ensure that struct bpf_iter_num is +emitted in vmlinux BTF. A previous version of this patch changed the +line to emit the correct type + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit modifies BTF emission for struct btf_iter_num to only emit a forward declaration.', 'keywords': 'BTF, emit, forward declaration', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The BPF Type Format (BTF)', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: ba8ea72388a192c10f1ee5f5a4a32332e7cced76 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ba8ea72388a192c10f1ee5f5a4a32332e7cced76 + Author Name: Artem Savkov + Author Email: asavkov@redhat.com + Commit Date: 1697225976 + Commit Message: + bpf: Change syscall_nr type to int in struct syscall_tp_t + +linux-rt-devel tree contains a patch (b1773eac3f29c ("sched: Add support +for lazy preemption")) that adds an extra member to struct trace_entry. +This causes the offset of args field in struct trace_event_raw_sys_enter +be different from the one in struct syscall_trace_enter: + +struct trace_event_raw_sys_enter { + struct trace_entry ent; /* 0 12 */ + + /* XXX last struct has 3 bytes of padding */ + /* XXX 4 bytes hole + Parent Hashes: 9c1292eca243821249fa99f40175b0660d9329e3 + Refs: try to pack */ + + long int id; /* 16 8 */ + long unsigned int args[6]; /* 24 48 */ + /* --- cacheline 1 boundary (64 bytes) was 8 bytes ago --- */ + char __data[]; /* 72 0 */ + + /* size: 72 + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit changes the syscall_nr type to int in struct syscall_tp_t to ensure compatibility with trace_event_raw_sys_enter.', 'keywords': 'syscall_nr,type,trace_event', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The syscall interface', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 9c1292eca243821249fa99f40175b0660d9329e3 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9c1292eca243821249fa99f40175b0660d9329e3 + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1697225743 + Commit Message: + net/bpf: Avoid unused "sin_addr_len" warning when CONFIG_CGROUP_BPF is not set + +It was reported that there is a compiler warning on the unused variable +"sin_addr_len" in af_inet.c when CONFIG_CGROUP_BPF is not set. +This patch is to address it similar to the ipv6 counterpart +in inet6_getname(). It is to "return sin_addr_len;" +instead of "return sizeof(*sin);". + +Fixes: fefba7d1ae19 ("bpf: Propagate modified uaddrlen from cgroup sockaddr programs") +Reported-by: Stephen Rothwell +Signed-off-by: Martin KaFai Lau +Signed-off-by: Andrii Nakryiko +Reviewed-by: Kuniyuki Iwashima +Link: https://lore.kernel.org/bpf/20231013185702.3993710-1-martin.lau@linux.dev + +Closes: https://lore.kernel.org/bpf/20231013114007.2fb09691@canb.auug.org.au/ + + Parent Hashes: 236334aeec0f93217cf9235f2004e61a0a1a5985 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes unused variable warning in net/bpf related to CONFIG_CGROUP_BPF.', 'keywords': 'warning, sin_addr_len, CONFIG_CGROUP_BPF', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The eBPF maps', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 236334aeec0f93217cf9235f2004e61a0a1a5985 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 236334aeec0f93217cf9235f2004e61a0a1a5985 + Author Name: Yafang Shao + Author Email: laoar.shao@gmail.com + Commit Date: 1697225601 + Commit Message: + bpf: Avoid unnecessary audit log for CPU security mitigations + +Check cpu_mitigations_off() first to avoid calling capable() if it is off. +This can avoid unnecessary audit log. + +Fixes: bc5bc309db45 ("bpf: Inherit system settings for CPU security mitigations") +Suggested-by: Andrii Nakryiko +Signed-off-by: Yafang Shao +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/CAEf4Bza6UVUWqcWQ-66weZ-nMDr+TFU3Mtq=dumZFD-pSqU7Ow@mail.gmail.com/ +Link: https://lore.kernel.org/bpf/20231013083916.4199-1-laoar.shao@gmail.com + + Parent Hashes: d2dc885b8c9ddb6fc374d93a87f8f2d1b97d2caf + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit prevents unnecessary audit logs by checking cpu_mitigations_off() before calling capable() for CPU security mitigations.', 'keywords': 'audit log, CPU security, mitigations', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 0e6bb5b7f4c8e6665e76bdafce37ad4a8daf83c5 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 0e6bb5b7f4c8e6665e76bdafce37ad4a8daf83c5 + Author Name: Jakub Kicinski + Author Email: kuba@kernel.org + Commit Date: 1697155654 + Commit Message: + Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Cross-merge networking fixes after downstream PR. + +No conflicts. + +Adjacent changes: + +kernel/bpf/verifier.c + 829955981c55 ("bpf: Fix verifier log for async callback return values") + a923819fb2c5 ("bpf: Treat first argument as return value for bpf_throw") + +Signed-off-by: Jakub Kicinski + + Parent Hashes: 2f0968a030f2a5dd4897a0151c8395bf5babe5b0 e8c127b0576660da9195504fe8393fe9da3de9ce + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes from upstream into the current branch without conflicts.', 'keywords': 'networking, fixes, merge', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: e8c127b0576660da9195504fe8393fe9da3de9ce +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e8c127b0576660da9195504fe8393fe9da3de9ce + Author Name: Linus Torvalds + Author Email: torvalds@linux-foundation.org + Commit Date: 1697141220 + Commit Message: + Merge tag 'net-6.6-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + "Including fixes from CAN and BPF. + + We have a regression in TC currently under investigation + Parent Hashes: 9a5a14948574ee09f339990cab69b4ab997d2f7d b91e8403373cab79375a65f5cf3495e2cd0bbdfa + Refs: otherwise + the things that stand off most are probably the TCP and AF_PACKET + fixes + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Merge networking fixes for CAN, BPF, and address regression in TC subsystem.', 'keywords': 'networking, CAN, BPF', 'commit_classification': "It's other type of commit.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', "It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 3fec323339a4a9801a54e8b282eb571965b67b23 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3fec323339a4a9801a54e8b282eb571965b67b23 + Author Name: Alexandre Ghiti + Author Email: alexghiti@rivosinc.com + Commit Date: 1697136395 + Commit Message: + drivers: perf: Fix panic in riscv SBI mmap support + +The following panic can happen when mmap is called before the pmu add +callback which sets the hardware counter index: this happens for example +with the following command `perf record --no-bpf-event -n kill`. + +[ 99.461486] CPU: 1 PID: 1259 Comm: perf Tainted: G E 6.6.0-rc4ubuntu-defconfig #2 +[ 99.461669] Hardware name: riscv-virtio + Parent Hashes: a87e7d3e8832271ecb7d5eaaabc5b49fe25a469b + Refs: qemu (DT) +[ 99.461748] epc : pmu_sbi_set_scounteren+0x42/0x44 +[ 99.462337] ra : smp_call_function_many_cond+0x126/0x5b0 +[ 99.462369] epc : ffffffff809f9d24 ra : ffffffff800f93e0 sp : ff60000082153aa0 +[ 99.462407] gp : ffffffff82395c98 tp : ff6000009a218040 t0 : ff6000009ab3a4f0 +[ 99.462425] t1 : 0000000000000004 t2 : 0000000000000100 s0 : ff60000082153ab0 +[ 99.462459] s1 : 0000000000000000 a0 : ff60000098869528 a1 : 0000000000000000 +[ 99.462473] a2 : 000000000000001f a3 : 0000000000f00000 a4 : fffffffffffffff8 +[ 99.462488] a5 : 00000000000000cc a6 : 0000000000000000 a7 : 0000000000735049 +[ 99.462502] s2 : 0000000000000001 s3 : ffffffff809f9ce2 s4 : ff60000098869528 +[ 99.462516] s5 : 0000000000000002 s6 : 0000000000000004 s7 : 0000000000000001 +[ 99.462530] s8 : ff600003fec98bc0 s9 : ffffffff826c5890 s10: ff600003fecfcde0 +[ 99.462544] s11: ff600003fec98bc0 t3 : ffffffff819e2558 t4 : ff1c000004623840 +[ 99.462557] t5 : 0000000000000901 t6 : ff6000008feeb890 +[ 99.462570] status: 0000000200000100 badaddr: 0000000000000000 cause: 0000000000000003 +[ 99.462658] [] pmu_sbi_set_scounteren+0x42/0x44 +[ 99.462979] Code: 1060 4785 97bb 00d7 8fd9 9073 1067 6422 0141 8082 (9002) 0013 +[ 99.463335] Kernel BUG [#2] + +To circumvent this + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit fixes a panic in the RISC-V SBI mmap support by addressing a hardware counter index issue.', 'keywords': 'panic,RISC-V,mmap', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b84b3f47921568a8172bec77d0370268e9fc62a2 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b84b3f47921568a8172bec77d0370268e9fc62a2 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130117 + Commit Message: + perf bpf_counter: Fix a few memory leaks + +Memory leaks were detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-20-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: 105254501770c8952e50c71618fca6a8b63890f1 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix memory leaks in the perf bpf_counter component.', 'keywords': 'memory leaks, perf, bpf_counter', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']} +-------------------- +-------------------- +Processing Commit ID: 105254501770c8952e50c71618fca6a8b63890f1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 105254501770c8952e50c71618fca6a8b63890f1 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130117 + Commit Message: + perf header: Fix various error path memory leaks + +Memory leaks were detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-19-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: 97fe038374bdf43fd025ac0e7aebf8bfbdd6d54f + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes memory leaks in perf header error paths identified by clang-tidy.', 'keywords': 'memory leaks, clang-tidy, perf header', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 97fe038374bdf43fd025ac0e7aebf8bfbdd6d54f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 97fe038374bdf43fd025ac0e7aebf8bfbdd6d54f + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130117 + Commit Message: + perf trace-event-info: Avoid passing NULL value to closedir + +If opendir failed then closedir was passed NULL which is +erroneous. Caught by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-18-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: c4b5140c6eac2f757d9706c6c783b60554c48cb7 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixed erroneous passing of NULL value to closedir in perf trace-event-info.', 'keywords': 'NULL,closedir,clang-tidy', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: c4b5140c6eac2f757d9706c6c783b60554c48cb7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: c4b5140c6eac2f757d9706c6c783b60554c48cb7 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130117 + Commit Message: + tools api: Avoid potential double free + +io__getline will free the line on error but it doesn't clear the out +argument. This may lead to the line being freed twice + Parent Hashes: 7875c72c8b0566590c888a2420d7e8fc12f67154 + Refs: like in +tools/perf/util/srcline.c as detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-17-irogers@google.com +Signed-off-by: Namhyung Kim + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a potential double free issue in tools API related to error handling in io__getline function.', 'keywords': 'double free,error,io__getline', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 7875c72c8b0566590c888a2420d7e8fc12f67154 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 7875c72c8b0566590c888a2420d7e8fc12f67154 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130117 + Commit Message: + perf parse-events: Fix unlikely memory leak when cloning terms + +Add missing free on an error path as detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-16-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: 1370406d35b45457aae295a6cfce9fae2bbd785e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix a memory leak in perf parse-events by adding a missing free on an error path.', 'keywords': 'memory leak, perf, free', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 1370406d35b45457aae295a6cfce9fae2bbd785e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 1370406d35b45457aae295a6cfce9fae2bbd785e + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130117 + Commit Message: + perf lock: Fix a memory leak on an error path + +If a memory allocation fails then the strdup-ed string needs +freeing. Detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-15-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: 63d471979e49148e59eae0b33a57c12d535e20c6 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes a memory leak in perf lock by freeing strdup-ed string on error path.', 'keywords': 'memory leak, error path, strdup', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 63d471979e49148e59eae0b33a57c12d535e20c6 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 63d471979e49148e59eae0b33a57c12d535e20c6 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130116 + Commit Message: + perf svghelper: Avoid memory leak + +On success path the sib_core and sib_thr values weren't being +freed. Detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-14-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: ef1aec6000a7364a6c1ef0a6f9cbf8b98b685255 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit addresses a memory leak in the perf svghelper by ensuring sib_core and sib_thr values are freed.', 'keywords': 'perf,memory leak,clang-tidy', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: ef1aec6000a7364a6c1ef0a6f9cbf8b98b685255 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: ef1aec6000a7364a6c1ef0a6f9cbf8b98b685255 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130116 + Commit Message: + perf hists browser: Avoid potential NULL dereference + +On other code paths browser->he_selection is NULL checked + Parent Hashes: 51e9ea99f9bfe6a9c283d041dbc2c1c0be9c3a0f + Refs: add a +missing case reported by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-13-irogers@google.com +Signed-off-by: Namhyung Kim + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit fixes a potential NULL dereference in the perf hists browser code.', 'keywords': 'NULL dereference, perf, browser', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 51e9ea99f9bfe6a9c283d041dbc2c1c0be9c3a0f +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 51e9ea99f9bfe6a9c283d041dbc2c1c0be9c3a0f + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130116 + Commit Message: + perf hists browser: Reorder variables to reduce padding + +Address clang-tidy warning: +``` +tools/perf/ui/browsers/hists.c:2416:8: warning: Excessive padding in 'struct popup_action' (8 padding bytes + Parent Hashes: 52a5ad12f2147506899ee83e680ea2a1d763adeb + Refs: where 0 is optimal). +Optimal fields order: +time + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit reorders variables in perf hists browser to address a clang-tidy padding warning.', 'keywords': 'variable reordering, clang-tidy, padding', 'commit_classification': "It's a cleanup or refactoring in the code.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 52a5ad12f2147506899ee83e680ea2a1d763adeb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 52a5ad12f2147506899ee83e680ea2a1d763adeb + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130116 + Commit Message: + perf dlfilter: Be defensive against potential NULL dereference + +In the unlikely case of having a symbol without a mapping + Parent Hashes: 85f73c377b2ac9988a204b119aebb33ca5c60083 + Refs: avoid a +NULL dereference that clang-tidy warns about. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-11-irogers@google.com +Signed-off-by: Namhyung Kim + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit addresses a NULL dereference issue in perf dlfilter to improve stability and avoid clang-tidy warnings.', 'keywords': 'NULL dereference, perf dlfilter, clang-tidy', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 85f73c377b2ac9988a204b119aebb33ca5c60083 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 85f73c377b2ac9988a204b119aebb33ca5c60083 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130116 + Commit Message: + perf mem-events: Avoid uninitialized read + +pmu should be initialized to NULL before perf_pmus__scan loop. Fix and +shrink the scope of pmu at the same time. Issue detected by clang-tidy. + +Fixes: 5752c20f3787 ("perf mem: Scan all PMUs instead of just core ones") +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-10-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: b3aa09ee78defd3d2e5f7debb5279f8a92b69749 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Initialize pmu to NULL to prevent uninitialized read in perf mem-events and reduce its scope.', 'keywords': 'uninitialized read, clang-tidy, pmu', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: b3aa09ee78defd3d2e5f7debb5279f8a92b69749 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b3aa09ee78defd3d2e5f7debb5279f8a92b69749 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130116 + Commit Message: + perf jitdump: Avoid memory leak + +jit_repipe_unwinding_info is called in a loop by jit_process_dump + Parent Hashes: e2372136700d460276ca7ff07da523e8f61b69c7 + Refs: +avoid leaking unwinding_data by free-ing before overwriting. Error +detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-9-irogers@google.com +Signed-off-by: Namhyung Kim + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix memory leak in perf jitdump by freeing unwinding_data before overwriting it, as identified by clang-tidy.', 'keywords': 'perf,jitdump,memory leak', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: e2372136700d460276ca7ff07da523e8f61b69c7 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: e2372136700d460276ca7ff07da523e8f61b69c7 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130116 + Commit Message: + perf env: Remove unnecessary NULL tests + +clang-tidy was warning: +``` +util/env.c:334:23: warning: Access to field 'nr_pmu_mappings' results in a dereference of a null pointer (loaded from variable 'env') [clang-analyzer-core.NullDereference] + env->nr_pmu_mappings = pmu_num; +``` + +As functions are called potentially when !env was true. This condition +could never be true as it would produce a segv + Parent Hashes: 319d459898ce507dba58c28c17610314d16b7beb + Refs: so remove the +unnecessary NULL tests and silence clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-8-irogers@google.com +Signed-off-by: Namhyung Kim + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Remove unnecessary NULL pointer checks in perf environment code to prevent segfaults and silence clang-tidy warnings.', 'keywords': 'NULL tests, clang-tidy, segfault', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The bpftool utility', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 319d459898ce507dba58c28c17610314d16b7beb +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 319d459898ce507dba58c28c17610314d16b7beb + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130116 + Commit Message: + perf buildid-cache: Fix use of uninitialized value + +The buildid filename is first determined and then from this the +buildid read. If getting the filename fails then the buildid will be +used for a later memcmp uninitialized. Detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-7-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: da0c884b0756fc97a1c15f4cdb81e0a8490a6d7e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fix uninitialized value usage in perf buildid-cache to prevent memcmp issues.', 'keywords': 'uninitialized value, buildid-cache, memcmp', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: da0c884b0756fc97a1c15f4cdb81e0a8490a6d7e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: da0c884b0756fc97a1c15f4cdb81e0a8490a6d7e + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130115 + Commit Message: + perf bench uprobe: Fix potential use of memory after free + +Found by clang-tidy: +``` +bench/uprobe.c:98:3: warning: Use of memory after it is freed [clang-analyzer-unix.Malloc] + bench_uprobe_bpf__destroy(skel); +``` + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-6-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: b24520ffa9695c7249bdd181cf10bc0a3e365019 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Fixes use-after-free issue in uprobe benchmarking tool detected by clang-tidy.', 'keywords': 'memory leak, clang-tidy, uprobe', 'commit_classification': "It's a bug fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ['other']} +-------------------- +-------------------- +Processing Commit ID: b24520ffa9695c7249bdd181cf10bc0a3e365019 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: b24520ffa9695c7249bdd181cf10bc0a3e365019 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130115 + Commit Message: + run-clang-tools: Add pass through checks and and header-filter arguments + +Add a -checks argument to allow the checks passed to the clang-tool to +be set on the command line. + +Add a pass through -header-filter option. + +Don't run analysis on non-C or CPP files. + +Signed-off-by: Ian Rogers +Reviewed-by: Nick Desaulniers +Cc: Ravi Bangoria +Cc: Mark Rutland +Cc: Yang Jihong +Cc: Peter Zijlstra +Cc: Adrian Hunter +Cc: Arnaldo Carvalho de Melo +Cc: Huacai Chen +Cc: Jiri Olsa +Cc: Nathan Chancellor +Cc: Alexander Shishkin +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Ingo Molnar +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Cc: linux-kernel@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-4-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: 9e56d3be4bfd2ec6433a7c44195bd1e687b8ed2e + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Enhance run-clang-tools with command-line options for checks and header filtering, excluding non-C/CPP files.', 'keywords': 'clang-tools, header-filter, checks', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': "It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.", 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 9e56d3be4bfd2ec6433a7c44195bd1e687b8ed2e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 9e56d3be4bfd2ec6433a7c44195bd1e687b8ed2e + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130115 + Commit Message: + gen_compile_commands: Sort output compile commands by file name + +Make the output more stable and deterministic. + +Signed-off-by: Ian Rogers +Reviewed-by: Nick Desaulniers +Cc: Ravi Bangoria +Cc: Mark Rutland +Cc: Yang Jihong +Cc: Peter Zijlstra +Cc: Adrian Hunter +Cc: Arnaldo Carvalho de Melo +Cc: Huacai Chen +Cc: Jiri Olsa +Cc: Nathan Chancellor +Cc: Alexander Shishkin +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Ingo Molnar +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Cc: linux-kernel@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-3-irogers@google.com +Signed-off-by: Namhyung Kim + + Parent Hashes: 52c15e7e792857c42b4a926e45228e981c5a5f13 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates gen_compile_commands to sort output compile commands by file name for stability and determinism.', 'keywords': 'gen_compile_commands, sort, stability', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 52c15e7e792857c42b4a926e45228e981c5a5f13 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 52c15e7e792857c42b4a926e45228e981c5a5f13 + Author Name: Ian Rogers + Author Email: irogers@google.com + Commit Date: 1697130115 + Commit Message: + gen_compile_commands: Allow the line prefix to still be cmd_ + +Builds in tools still use the cmd_ prefix in .cmd files + Parent Hashes: b20576fd7fe39554b212095c3c0d7a3dff512515 + Refs: so don't +require the saved part. Name the groups in the line pattern match so +that changing the regular expression is more robust and works with the +addition of a new match group. + +Signed-off-by: Ian Rogers +Reviewed-by: Nick Desaulniers +Cc: Ravi Bangoria +Cc: Mark Rutland +Cc: Yang Jihong +Cc: Peter Zijlstra +Cc: Adrian Hunter +Cc: Arnaldo Carvalho de Melo +Cc: Huacai Chen +Cc: Jiri Olsa +Cc: Nathan Chancellor +Cc: Alexander Shishkin +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Ingo Molnar +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Cc: linux-kernel@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-2-irogers@google.com +Signed-off-by: Namhyung Kim + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit allows the gen_compile_commands to maintain the cmd_ prefix for robustness with new match groups.', 'keywords': 'gen_compile_commands, cmd_prefix, robustness', 'commit_classification': "It's a build system or CI/CD change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: d2dc885b8c9ddb6fc374d93a87f8f2d1b97d2caf +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: d2dc885b8c9ddb6fc374d93a87f8f2d1b97d2caf + Author Name: Martin KaFai Lau + Author Email: martin.lau@kernel.org + Commit Date: 1697070476 + Commit Message: + Merge branch 'Add cgroup sockaddr hooks for unix sockets' + +Daan De Meyer says: + +==================== +Changes since v10: + +* Removed extra check from bpf_sock_addr_set_sun_path() again in favor of + calling unix_validate_addr() everywhere in af_unix.c before calling the hooks. + +Changes since v9: + +* Renamed bpf_sock_addr_set_unix_addr() to bpf_sock_addr_set_sun_path() and + rennamed arguments to match the new name. +* Added an extra check to bpf_sock_addr_set_sun_path() to disallow changing the + address of an unnamed unix socket. +* Removed unnecessary NULL check on uaddrlen in + __cgroup_bpf_run_filter_sock_addr(). + +Changes since v8: + +* Added missing test programs to last patch + +Changes since v7: + +* Fixed formatting nit in comment +* Renamed from cgroup/connectun to cgroup/connect_unix (and similar for all + other hooks) + +Changes since v6: + +* Actually removed bpf_bind() helper for AF_UNIX hooks. +* Fixed merge conflict +* Updated comment to mention uaddrlen is read-only for AF_INET[6] +* Removed unnecessary forward declaration of struct sock_addr_test +* Removed unused BPF_CGROUP_RUN_PROG_UNIX_CONNECT() +* Fixed formatting nit reported by checkpatch +* Added more information to commit message about recvmsg() on connected socket + +Changes since v5: + +* Fixed kernel version in bpftool documentation (6.3 => 6.7). +* Added connection mode socket recvmsg() test. +* Removed bpf_bind() helper for AF_UNIX hooks. +* Added missing getpeernameun and getsocknameun BPF test programs. +* Added note for bind() test being unused currently. + +Changes since v4: + +* Dropped support for intercepting bind() as when using bind() with unix sockets + and a pathname sockaddr + Parent Hashes: 1ef09e1281a1add0a86ecd594f748d7fb8bfd78e 82ab6b505e8199cc4537f00025a7391973c3847e + Refs: bind() will create an inode in the filesystem that + needs to be cleaned up. If the address is rewritten + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds cgroup sockaddr hooks for Unix sockets and includes various fixes and renamings from previous versions.', 'keywords': 'cgroup, unix sockets, hooks', 'commit_classification': "It's a new feature.", 'commit_complexity': "Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.", 'Major related component': 'The attach events and bpf link. e.g. perf events, tracepoints, etc.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 82ab6b505e8199cc4537f00025a7391973c3847e +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 82ab6b505e8199cc4537f00025a7391973c3847e + Author Name: Daan De Meyer + Author Email: daan.j.demeyer@gmail.com + Commit Date: 1697070475 + Commit Message: + selftests/bpf: Add tests for cgroup unix socket address hooks + +These selftests are written in prog_tests style instead of adding +them to the existing test_sock_addr tests. Migrating the existing +sock addr tests to prog_tests style is left for future work. This +commit adds support for testing bind() sockaddr hooks + Parent Hashes: af2752ed450e71fc0bd596d0b4b9b805a64ae2c1 + Refs: even though +there's no unix socket sockaddr hook for bind(). We leave this code +intact for when the INET and INET6 tests are migrated in the future +which do support intercepting bind(). + +Signed-off-by: Daan De Meyer +Link: https://lore.kernel.org/r/20231011185113.140426-10-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau + + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Add selftests for cgroup unix socket address hooks in prog_tests style.', 'keywords': 'selftests,cgroup,socket', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ['socket like programs', 'cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: af2752ed450e71fc0bd596d0b4b9b805a64ae2c1 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: af2752ed450e71fc0bd596d0b4b9b805a64ae2c1 + Author Name: Daan De Meyer + Author Email: daan.j.demeyer@gmail.com + Commit Date: 1697070475 + Commit Message: + selftests/bpf: Make sure mount directory exists + +The mount directory for the selftests cgroup tree might +not exist so let's make sure it does exist by creating +it ourselves if it doesn't exist. + +Signed-off-by: Daan De Meyer +Link: https://lore.kernel.org/r/20231011185113.140426-9-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 3243fef6a4c0db2dbb01ee3cf30bd787e65b8d56 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'Ensure selftests create necessary mount directories for cgroup trees if not present.', 'keywords': 'selftests, cgroup, directory', 'commit_classification': "It's a test case or test infrastructure change.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'The test cases and makefiles', 'program_types_related': ["It's not related to any of the above."]} +-------------------- +-------------------- +Processing Commit ID: 3243fef6a4c0db2dbb01ee3cf30bd787e65b8d56 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 3243fef6a4c0db2dbb01ee3cf30bd787e65b8d56 + Author Name: Daan De Meyer + Author Email: daan.j.demeyer@gmail.com + Commit Date: 1697070475 + Commit Message: + documentation/bpf: Document cgroup unix socket address hooks + +Update the documentation to mention the new cgroup unix sockaddr +hooks. + +Signed-off-by: Daan De Meyer +Link: https://lore.kernel.org/r/20231011185113.140426-8-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: 8b3cba987e6d9464bb533d957de923f891b57bf8 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'The commit updates documentation to include cgroup unix socket address hooks.', 'keywords': 'documentation,cgroup,socket', 'commit_classification': "It's a documentation change or typo fix.", 'commit_complexity': 'Simple, can be used without much configuration. For example, a simple helper function.', 'Major related component': 'Other component related to eBPF but not listed above.', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: 8b3cba987e6d9464bb533d957de923f891b57bf8 +Survey Title: Commit Classification Survey + + +Description: A survey about the type, use cases and summary of commit in Linux eBPF. + +Commit Details: + Commit ID: 8b3cba987e6d9464bb533d957de923f891b57bf8 + Author Name: Daan De Meyer + Author Email: daan.j.demeyer@gmail.com + Commit Date: 1697070475 + Commit Message: + bpftool: Add support for cgroup unix socket address hooks + +Add the necessary plumbing to hook up the new cgroup unix sockaddr +hooks into bpftool. + +Signed-off-by: Daan De Meyer +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/r/20231011185113.140426-7-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau + + Parent Hashes: bf90438c78df885c17a3474276ed39abb4a7c026 + Refs: + +- Please provide a summary of the commit in one short sentence not longer than 30 words. Only output one sentence. + +- Please extract no more than 3 keywords from the commit. Only output 3 keywords, without any special characters. + +- What may be the main type of the commit? + +- What is the estimated complexity of implementing this commit? + +- What major component that the commit is related to? + +- What eBPF program(s) may the commit relate to and designed for? + +{'summary': 'This commit adds support for cgroup unix socket address hooks into bpftool.', 'keywords': 'bpftool,cgroup,unix', 'commit_classification': "It's a new feature.", 'commit_complexity': 'Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.', 'Major related component': 'The bpftool utility', 'program_types_related': ['cgroup like programs']} +-------------------- +-------------------- +Processing Commit ID: bf90438c78df885c17a3474276ed39abb4a7c026 diff --git a/data/commit_survey.csv b/data/commit_survey.csv index 389635a..b89cfab 100644 --- a/data/commit_survey.csv +++ b/data/commit_survey.csv @@ -8034,3 +8034,15465 @@ Acked-by: Eduard Zingerman Link: https://lore.kernel.org/r/20240426231621.2716876-4-sdf@google.com Signed-off-by: Martin KaFai Lau ",,Added sockopt test case to ensure only sockopt programs attach to setsockopt/getsockopt hooks.,"sockopt,test case,prog_type",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +d70b2660e75b85bdaa9d75f9c4224c2f6f89cf23,d70b2660e75b85bdaa9d75f9c4224c2f6f89cf23,Stanislav Fomichev,sdf@google.com,1714173379,Martin KaFai Lau,martin.lau@kernel.org,1714499017,cb3eed3fda2e2255c69b4cd992882e7e7b48141f,543576ec15b17c0c93301ac8297333c7b6e84ac7,"selftests/bpf: Extend sockopt tests to use BPF_LINK_CREATE + +Run all existing test cases with the attachment created via +BPF_LINK_CREATE. Next commit will add extra test cases to verify +link_create attach_type enforcement. + +Signed-off-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240426231621.2716876-3-sdf@google.com +Signed-off-by: Martin KaFai Lau +",,Extend existing BPF sockopt tests to utilize BPF_LINK_CREATE for attachment.,"selftests,bpf,BPF_LINK_CREATE",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +543576ec15b17c0c93301ac8297333c7b6e84ac7,543576ec15b17c0c93301ac8297333c7b6e84ac7,Stanislav Fomichev,sdf@google.com,1714173378,Martin KaFai Lau,martin.lau@kernel.org,1714499017,9ee27656356c0a9d30f53a807ef9f42a931f5c00,b867247555c4181bf84eb10b72b176862c29112d,"bpf: Add BPF_PROG_TYPE_CGROUP_SKB attach type enforcement in BPF_LINK_CREATE + +bpf_prog_attach uses attach_type_to_prog_type to enforce proper +attach type for BPF_PROG_TYPE_CGROUP_SKB. link_create uses +bpf_prog_get and relies on bpf_prog_attach_check_attach_type +to properly verify prog_type <> attach_type association. + +Add missing attach_type enforcement for the link_create case. +Otherwise"," it's currently possible to attach cgroup_skb prog +types to other cgroup hooks. + +Fixes: af6eea57437a (""bpf: Implement bpf_link-based cgroup BPF program attachment"") +Link: https://lore.kernel.org/bpf/0000000000004792a90615a1dde0@google.com/ +Reported-by: syzbot+838346b979830606c854@syzkaller.appspotmail.com +Signed-off-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240426231621.2716876-2-sdf@google.com +Signed-off-by: Martin KaFai Lau +",[''],This commit enforces attach type verification for cgroup_skb programs in BPF_LINK_CREATE.,"attach type, cgroup_skb, link_create",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['cgroup like programs'] +06ebfd11678ad63cfd7021580e13d1582ee6c782,06ebfd11678ad63cfd7021580e13d1582ee6c782,Andrii Nakryiko,andrii@kernel.org,1714495554,Andrii Nakryiko,andrii@kernel.org,1714497807,b575361002db6d53f2840aa2562b19dac72f64fc,05cbc217aafbc631a6c2fab4accf95850cb48358 a3a5113393ccfad2eb23ca091aa6e55b5bd67eb4,"Merge branch 'bpf-introduce-kprobe_multi-session-attach' + +Jiri Olsa says: + +==================== +bpf: Introduce kprobe_multi session attach + +hi"," +adding support to attach kprobe program through kprobe_multi link +in a session mode","[' which means:\n - program is attached to both function entry and return\n - entry program can decided if the return program gets executed\n - entry program can share u64 cookie value with return program\n\nThe initial RFC for this was posted in [0] and later discussed more\nand which ended up with the session idea [1]\n\nHaving entry together with return probe for given function is common\nuse case for tetragon', ' bpftrace and most likely for others.\n\nAt the moment if we want both entry and return probe to execute bpf\nprogram we need to create two (entry and return probe) links. The link\nfor return probe creates extra entry probe to setup the return probe.\nThe extra entry probe execution could be omitted if we had a way to\nuse just single link for both entry and exit probe.\n\nIn addition the possibility to control the return program execution\nand sharing data within entry and return probe allows for other use\ncases.\n\nv2 changes:\n - renamed BPF_TRACE_KPROBE_MULTI_SESSION to BPF_TRACE_KPROBE_SESSION\n [Andrii]\n - use arrays for results in selftest [Andrii]\n - various small selftests and libbpf changes [Andrii]\n - moved the verifier cookie setup earlier in check_kfunc_call [Andrii]\n - added acks\n\nAlso available at:\n https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git\n bpf/session_data\n\nthanks', '\njirka\n\n[0] https://lore.kernel.org/bpf/20240207153550.856536-1-jolsa@kernel.org/\n[1] https://lore.kernel.org/bpf/20240228090242.4040210-1-jolsa@kernel.org/\n---\n====================\n\nLink: https://lore.kernel.org/r/20240430112830.1184228-1-jolsa@kernel.org\nSigned-off-by: Andrii Nakryiko \n', '']",Introduce support for attaching kprobe programs using kprobe_multi in session mode.,"kprobe, session, attach",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +a3a5113393ccfad2eb23ca091aa6e55b5bd67eb4,a3a5113393ccfad2eb23ca091aa6e55b5bd67eb4,Jiri Olsa,jolsa@kernel.org,1714476510,Andrii Nakryiko,andrii@kernel.org,1714497805,b575361002db6d53f2840aa2562b19dac72f64fc,0983b1697aefbf69f465f907b934b89bbce467ea,"selftests/bpf: Add kprobe session cookie test + +Adding kprobe session test that verifies the cookie value +get properly propagated from entry to return program. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-8-jolsa@kernel.org +",,Add a kprobe selftest to verify cookie propagation from entry to return program.,"kprobe,selftest,cookie",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +0983b1697aefbf69f465f907b934b89bbce467ea,0983b1697aefbf69f465f907b934b89bbce467ea,Jiri Olsa,jolsa@kernel.org,1714476509,Andrii Nakryiko,andrii@kernel.org,1714497781,283de1dbd8467acb6090369c5cc5dc71fb3c6371,7b94965429f2fa32a83e1275c6bf6ed0add08603,"selftests/bpf: Add kprobe session test + +Adding kprobe session test and testing that the entry program +return value controls execution of the return probe program. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-7-jolsa@kernel.org +",,Add test case for kprobe session to verify entry program's control over return probe execution.,"kprobe,test,session",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +7b94965429f2fa32a83e1275c6bf6ed0add08603,7b94965429f2fa32a83e1275c6bf6ed0add08603,Jiri Olsa,jolsa@kernel.org,1714476508,Andrii Nakryiko,andrii@kernel.org,1714495553,92edffe018c8abf1adce83fe45250bb7ce80d067,2ca178f02b2f4e523e970894def16282e4adbc39,"libbpf: Add kprobe session attach type name to attach_type_name + +Adding kprobe session attach type name to attach_type_name"," +so libbpf_bpf_attach_type_str returns proper string name for +BPF_TRACE_KPROBE_SESSION attach type. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-6-jolsa@kernel.org +",[''],Add kprobe session attach type name to attach_type_name in libbpf.,"libbpf,kprobe,attach type",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,['kprobe/uprobe/ftrace like programs'] +2ca178f02b2f4e523e970894def16282e4adbc39,2ca178f02b2f4e523e970894def16282e4adbc39,Jiri Olsa,jolsa@kernel.org,1714476507,Andrii Nakryiko,andrii@kernel.org,1714495553,d4e662ddc8bf58b47007e8da3e2ee2c2853e337a,5c919acef85147886eb2abf86fb147f94680a8b0,"libbpf: Add support for kprobe session attach + +Adding support to attach program in kprobe session mode +with bpf_program__attach_kprobe_multi_opts function. + +Adding session bool to bpf_kprobe_multi_opts struct that allows +to load and attach the bpf program via kprobe session. +the attachment to create kprobe multi session. + +Also adding new program loader section that allows: + SEC(""kprobe.session/bpf_fentry_test*"") + +and loads/attaches kprobe program as kprobe session. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-5-jolsa@kernel.org +",,Add support for kprobe session mode attachment to bpf programs with new loader section and options.,"kprobe, session, attach",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,['kprobe/uprobe/ftrace like programs'] +5c919acef85147886eb2abf86fb147f94680a8b0,5c919acef85147886eb2abf86fb147f94680a8b0,Jiri Olsa,jolsa@kernel.org,1714476506,Andrii Nakryiko,andrii@kernel.org,1714495553,045b9f1176ff8ddecdf9fe1b31f2b7e19aa4aa16,adf46d88ae4b2557f7e2e02547a25fb866935711,"bpf: Add support for kprobe session cookie + +Adding support for cookie within the session of kprobe multi +entry and return program. + +The session cookie is u64 value and can be retrieved be new +kfunc bpf_session_cookie"," which returns pointer to the cookie +value. The bpf program can use the pointer to store (on entry) +and load (on return) the value. + +The cookie value is implemented via fprobe feature that allows +to share values between entry and return ftrace fprobe callbacks. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-4-jolsa@kernel.org +",[''],This commit adds support for a session cookie in kprobe programs using fprobe to share values between entry and return callbacks.,"kprobe, session cookie, fprobe",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +adf46d88ae4b2557f7e2e02547a25fb866935711,adf46d88ae4b2557f7e2e02547a25fb866935711,Jiri Olsa,jolsa@kernel.org,1714476505,Andrii Nakryiko,andrii@kernel.org,1714495553,aa4dd40c1ba688087885a2d0374c790aad2b23ac,535a3692ba7245792e6f23654507865d4293c850,"bpf: Add support for kprobe session context + +Adding struct bpf_session_run_ctx object to hold session related +data"," which is atm is_return bool and data pointer coming in +following changes. + +Placing bpf_session_run_ctx layer in between bpf_run_ctx and +bpf_kprobe_multi_run_ctx so the session data can be retrieved +regardless of if it's kprobe_multi or uprobe_multi link","[' which\nsupport is coming in future. This way both kprobe_multi and\nuprobe_multi can use same kfuncs to access the session data.\n\nAdding bpf_session_is_return kfunc that returns true if the\nbpf program is executed from the exit probe of the kprobe multi\nlink attached in wrapper mode. It returns false otherwise.\n\nAdding new kprobe hook for kprobe program type.\n\nSigned-off-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240430112830.1184228-3-jolsa@kernel.org\n', '']",The commit adds kprobe session context support by introducing struct bpf_session_run_ctx for session data management.,"kprobe, session, context",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['kprobe/uprobe/ftrace like programs'] +535a3692ba7245792e6f23654507865d4293c850,535a3692ba7245792e6f23654507865d4293c850,Jiri Olsa,jolsa@kernel.org,1714476504,Andrii Nakryiko,andrii@kernel.org,1714495553,7352550565832f6ebad9e0e333c9857821e624dc,05cbc217aafbc631a6c2fab4accf95850cb48358,"bpf: Add support for kprobe session attach + +Adding support to attach bpf program for entry and return probe +of the same function. This is common use case which at the moment +requires to create two kprobe multi links. + +Adding new BPF_TRACE_KPROBE_SESSION attach type that instructs +kernel to attach single link program to both entry and exit probe. + +It's possible to control execution of the bpf program on return +probe simply by returning zero or non zero from the entry bpf +program execution to execute or not the bpf program on return +probe respectively. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240430112830.1184228-2-jolsa@kernel.org +",,Add support for attaching BPF programs to both entry and return kprobe sessions with a single link.,"kprobe,BPF,attach",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +32a4ca1361d7a51e5003d4af4dfbf570f1b5fd00,32a4ca1361d7a51e5003d4af4dfbf570f1b5fd00,Jakub Kicinski,kuba@kernel.org,1714401863,Jakub Kicinski,kuba@kernel.org,1714490132,ae88dade4a4cc727704e96456e9c090eee7329c2,ff4b2bfa63bd07cca35f6e704dc5035650595950,"selftests: net: py: extract tool logic + +The main use of the ip() wrapper over cmd() is that it can parse JSON. +cmd(""ip -j link show"") will return stdout as a string"," and test has +to call json.loads(). With ip(""link show""","[' json=True) the return value\nwill be already parsed.\n\nMore tools (ethtool', ' bpftool etc.) support the --json switch.\nTo avoid having to wrap all of them individually create a tool()\nhelper.\n\nSwitch from -j to --json (for ethtool).\nWhile at it consume the netns attribute at the ip() level.\n\nReviewed-by: Willem de Bruijn \nLink: https://lore.kernel.org/r/20240429144426.743476-4-kuba@kernel.org\nSigned-off-by: Jakub Kicinski \n', '']",Refactor selftests to improve JSON parsing by extracting tool logic into the ip() wrapper.,"selftests, JSON, wrapper",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +05cbc217aafbc631a6c2fab4accf95850cb48358,05cbc217aafbc631a6c2fab4accf95850cb48358,Benjamin Tissoires,bentiss@kernel.org,1714473806,Daniel Borkmann,daniel@iogearbox.net,1714487338,7a6b3c7b3b4ba041afba675efe19bebefaa878ce,a891711d0166133ec5120615fcf365d9745d82b2,"selftests/bpf: Drop an unused local variable + +Some copy/paste leftover"," this is never used. + +Fixes: e3d9eac99afd (""selftests/bpf: wq: add bpf_wq_init() checks"") +Signed-off-by: Benjamin Tissoires +Signed-off-by: Daniel Borkmann +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/bpf/20240430-bpf-next-v3-3-27afe7f3b17c@kernel.org +",[''],The commit removes an unused local variable in selftests/bpf.,"unused variable, selftests, cleanup",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +a891711d0166133ec5120615fcf365d9745d82b2,a891711d0166133ec5120615fcf365d9745d82b2,Benjamin Tissoires,bentiss@kernel.org,1714473805,Daniel Borkmann,daniel@iogearbox.net,1714487326,7011e016746a27dcc06228506e6d2d6ab806ff9b,b98a5c68ccaa94e93b9e898091fe2cf21c1500e6,"bpf: Do not walk twice the hash map on free + +If someone stores both a timer and a workqueue in a hash map", on free,"[' we\nwould walk it twice.\n\nAdd a check in htab_free_malloced_timers_or_wq and free the timers and\nworkqueues if they are present.\n\nFixes: 246331e3f1ea (""bpf: allow struct bpf_wq to be embedded in arraymaps and hashmaps"")\nSigned-off-by: Benjamin Tissoires \nSigned-off-by: Daniel Borkmann \nAcked-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/bpf/20240430-bpf-next-v3-2-27afe7f3b17c@kernel.org\n', '']",Optimize hash map free operation to prevent double walking in bpf subsystem.,"hash map, bpf, optimize",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b98a5c68ccaa94e93b9e898091fe2cf21c1500e6,b98a5c68ccaa94e93b9e898091fe2cf21c1500e6,Benjamin Tissoires,bentiss@kernel.org,1714473804,Daniel Borkmann,daniel@iogearbox.net,1714487313,1d966ca8b4a480aaa183bc5d1eb2759645af885a,1bba3b3d373dbafae891e7cb06b8c82c8d62aba1,"bpf: Do not walk twice the map on free + +If someone stores both a timer and a workqueue in a map"," on free +we would walk it twice. + +Add a check in array_map_free_timers_wq and free the timers and +workqueues if they are present. + +Fixes: 246331e3f1ea (""bpf: allow struct bpf_wq to be embedded in arraymaps and hashmaps"") +Signed-off-by: Benjamin Tissoires +Signed-off-by: Daniel Borkmann +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/bpf/20240430-bpf-next-v3-1-27afe7f3b17c@kernel.org +",[''],Prevent twice traversal of map containing timers and workqueues during free operation in eBPF.,"map,free,twice",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['other'] +1bba3b3d373dbafae891e7cb06b8c82c8d62aba1,1bba3b3d373dbafae891e7cb06b8c82c8d62aba1,Andrii Nakryiko,andrii@kernel.org,1714273794,Martin KaFai Lau,martin.lau@kernel.org,1714434513,a0dbfaaf0e1970a93b7b2536632329019a219d49,f973fccd43d34b096077d5d21d051ef75b22a7ea,"selftests/bpf: validate nulled-out struct_ops program is handled properly + +Add a selftests validating that it's possible to have some struct_ops +callback set declaratively"," then disable it (by setting to NULL) +programmatically. Libbpf should detect that such program should +not be loaded. Otherwise","[' it will unnecessarily fail the loading\nwhen the host kernel does not have the type information.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240428030954.3918764-2-andrii@kernel.org\nSigned-off-by: Martin KaFai Lau \n', '']",Added selftests to ensure struct_ops program handles nulled-out callbacks properly in libbpf.,"selftests, struct_ops, libbpf",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f973fccd43d34b096077d5d21d051ef75b22a7ea,f973fccd43d34b096077d5d21d051ef75b22a7ea,Andrii Nakryiko,andrii@kernel.org,1714273793,Martin KaFai Lau,martin.lau@kernel.org,1714434366,9cd7d6ace7c93aedc960a429e91ed40d45e8bcf4,cfd3bfe9507b4aa39f7e86772e60b50b799e490e,"libbpf: handle nulled-out program in struct_ops correctly + +If struct_ops has one of program callbacks set declaratively and host +kernel is old and doesn't support this callback"," libbpf will allow to +load such struct_ops as long as that callback was explicitly nulled-out +(presumably through skeleton). This is all working correctly","["" except we\nwon't reset corresponding program slot to NULL before bailing out"", ' which\nwill lead to libbpf not detecting that BPF program has to be not\nauto-loaded. Fix this by unconditionally resetting corresponding program\nslot to NULL.\n\nFixes: c911fc61a7ce (""libbpf: Skip zeroed or null fields if not found in the kernel type."")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240428030954.3918764-1-andrii@kernel.org\nSigned-off-by: Martin KaFai Lau \n', '']",Ensure libbpf handles nulled-out program callbacks in struct_ops for compatibility with older kernels.,"libbpf,struct_ops,nulled-out",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cfd3bfe9507b4aa39f7e86772e60b50b799e490e,cfd3bfe9507b4aa39f7e86772e60b50b799e490e,Dmitrii Bundin,dmitrii.bundin.a@gmail.com,1713587097,Andrii Nakryiko,andrii@kernel.org,1714433287,7d7acbf0cc7591c094ce3445254b943236bdae04,789d9a53d2f633317c64de3eba0940f31a8f0cd6,"bpf: Include linux/types.h for u32 + +Inclusion of the header linux/btf_ids.h relies on indirect inclusion of +the header linux/types.h. Including it directly on the top level helps +to avoid potential problems if linux/types.h hasn't been included +before. + +The main motivation to introduce this it is to avoid similar problems that +have shown up in the bpftool where GNU libc indirectly pulls +linux/types.h causing compile error of the form: + + error: unknown type name 'u32' + u32 cnt; + ^~~ + +The bpftool compile error was fixed in +62248b22d01e (""tools/resolve_btfids: fix build with musl libc""). + +Signed-off-by: Dmitrii Bundin +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240420042457.3198883-1-dmitrii.bundin.a@gmail.com +",,Directly include linux/types.h to prevent build errors related to missing u32 type in bpftool.,"linux types, bpftool, u32",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +25927d0a1bec5091d371693c9fdd9640478837de,25927d0a1bec5091d371693c9fdd9640478837de,Geliang Tang,tanggeliang@kylinos.cn,1714374454,Andrii Nakryiko,andrii@kernel.org,1714432635,f4e0204c8bf1d4b7ca95c274c723c5fe18e82bf1,237c522c1d5d19e8d3057a38ce690c753020c7d1,"selftests/bpf: Free strdup memory in veristat + +The strdup() function returns a pointer to a new string which is a +duplicate of the string ""input"". Memory for the new string is obtained +with malloc()"," and need to be freed with free(). + +This patch adds these missing ""free(input)"" in parse_stats() to avoid +memory leak in veristat.c. + +Signed-off-by: Geliang Tang +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/ded44f8865cd7f337f52fc5fb0a5fbed7d6bd641.1714374022.git.tanggeliang@kylinos.cn +",[''],The commit fixes a memory leak by freeing strdup memory in the selftests for veristat.,"memory, leak, free",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +237c522c1d5d19e8d3057a38ce690c753020c7d1,237c522c1d5d19e8d3057a38ce690c753020c7d1,Geliang Tang,tanggeliang@kylinos.cn,1714374453,Andrii Nakryiko,andrii@kernel.org,1714432635,9c1dec9405c26bceeb19a41fb0c09e652455381e,19468ed51488dae19254e8a67c75d583b05fa5e3,"selftests/bpf: Free strdup memory in test_sockmap + +The strdup() function returns a pointer to a new string which is a +duplicate of the string ""ptr"". Memory for the new string is obtained +with malloc()"," and need to be freed with free(). + +This patch adds these missing ""free(ptr)"" in check_whitelist() and +check_blacklist() to avoid memory leaks in test_sockmap.c. + +Signed-off-by: Geliang Tang +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/b76f2f4c550aebe4ab8ea73d23c4cbe4f06ea996.1714374022.git.tanggeliang@kylinos.cn +",[''],Fixes memory leaks by adding missing free calls in test_sockmap.c for strdup allocations.,"memory leak, strdup, test_sockmap",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +19468ed51488dae19254e8a67c75d583b05fa5e3,19468ed51488dae19254e8a67c75d583b05fa5e3,Viktor Malik,vmalik@redhat.com,1714389791,Andrii Nakryiko,andrii@kernel.org,1714432451,33543407c7963e4b6d72ed400dcdb4eb7bce0c9c,a3034872cd90a6881ad4e10ca6d30e1215a99ada,"selftests/bpf: Run cgroup1_hierarchy test in own mount namespace + +The cgroup1_hierarchy test uses setup_classid_environment to setup +cgroupv1 environment. The problem is that the environment is set in +/sys/fs/cgroup and therefore", if not run under an own mount namespace,"['\neffectively deletes all system cgroups:\n\n $ ls /sys/fs/cgroup | wc -l\n 27\n $ sudo ./test_progs -t cgroup1_hierarchy\n #41/1 cgroup1_hierarchy/test_cgroup1_hierarchy:OK\n #41/2 cgroup1_hierarchy/test_root_cgid:OK\n #41/3 cgroup1_hierarchy/test_invalid_level:OK\n #41/4 cgroup1_hierarchy/test_invalid_cgid:OK\n #41/5 cgroup1_hierarchy/test_invalid_hid:OK\n #41/6 cgroup1_hierarchy/test_invalid_cgrp_name:OK\n #41/7 cgroup1_hierarchy/test_invalid_cgrp_name2:OK\n #41/8 cgroup1_hierarchy/test_sleepable_prog:OK\n #41 cgroup1_hierarchy:OK\n Summary: 1/8 PASSED', ' 0 SKIPPED', ' 0 FAILED\n $ ls /sys/fs/cgroup | wc -l\n 1\n\nTo avoid this', ' run setup_cgroup_environment first which will create an\nown mount namespace. This only affects the cgroupv1_hierarchy test as\nall other cgroup1 test progs already run setup_cgroup_environment prior\nto running setup_classid_environment.\n\nAlso add a comment to the header of setup_classid_environment to warn\nagainst this invalid usage in future.\n\nFixes: 360769233cc9 (""selftests/bpf: Add selftests for cgroup1 hierarchy"")\nSigned-off-by: Viktor Malik \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240429112311.402497-1-vmalik@redhat.com\n', '']",The commit modifies the cgroup1_hierarchy test to run in its own mount namespace to avoid environment setup conflicts.,"cgroup1_hierarchy,mount namespace,environment",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a3034872cd90a6881ad4e10ca6d30e1215a99ada,a3034872cd90a6881ad4e10ca6d30e1215a99ada,Andy Shevchenko,andriy.shevchenko@linux.intel.com,1714392005,Andrii Nakryiko,andrii@kernel.org,1714432394,4e8c7500b29b275356a9a793c60009ee59b865ee,cb01621b6d91567ac74c8b95e4db731febdbdec3,"bpf: Switch to krealloc_array() + +Let the krealloc_array() copy the original data and +check for a multiplication overflow. + +Signed-off-by: Andy Shevchenko +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240429120005.3539116-1-andriy.shevchenko@linux.intel.com +",,Switches to using krealloc_array() for memory allocation with overflow check in eBPF.,"krealloc_array,memory overflow",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cb01621b6d91567ac74c8b95e4db731febdbdec3,cb01621b6d91567ac74c8b95e4db731febdbdec3,Andy Shevchenko,andriy.shevchenko@linux.intel.com,1714392802,Andrii Nakryiko,andrii@kernel.org,1714432323,824adabc8b3315962dc97d52a7dd79a93a3255e9,397658ddc88ce3c21d2aa3bed8e15fc69dfec946,"bpf: Use struct_size() + +Use struct_size() instead of hand writing it. +This is less verbose and more robust. + +Signed-off-by: Andy Shevchenko +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240429121323.3818497-1-andriy.shevchenko@linux.intel.com +",,Refactor code to use struct_size() for improved code robustness and clarity.,"struct_size, robust, refactor",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +397658ddc88ce3c21d2aa3bed8e15fc69dfec946,397658ddc88ce3c21d2aa3bed8e15fc69dfec946,Tao Chen,chen.dylane@gmail.com,1714320632,Andrii Nakryiko,andrii@kernel.org,1714432203,a3b94164746442be2099cba5133067d3698adbed,0db63c0b86e981a1e97d2596d64ceceba1a5470e,"samples/bpf: Add valid info for VMLINUX_BTF + +When I use the command 'make M=samples/bpf' to compile samples/bpf code +in ubuntu 22.04"," the error info occured: +Cannot find a vmlinux for VMLINUX_BTF at any of "" /home/ubuntu/code/linux/vmlinux""","['\nbuild the kernel or set VMLINUX_BTF or VMLINUX_H variable\n\nOthers often encounter this kind of issue', ' new kernel has the vmlinux', ' so we can\nset the path in error info which seems more intuitive', ' like:\nCannot find a vmlinux for VMLINUX_BTF at any of "" /home/ubuntu/code/linux/vmlinux""', '\nbuiild the kernel or set VMLINUX_BTF like ""VMLINUX_BTF=/sys/kernel/btf/vmlinux"" or\nVMLINUX_H variable\n\nSigned-off-by: Tao Chen \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240428161032.239043-1-chen.dylane@gmail.com\n', '']",Add valid information to VMLINUX_BTF in samples/bpf for compile error resolution.,"samples,bpf,VMLINUX_BTF",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['other'] +0db63c0b86e981a1e97d2596d64ceceba1a5470e,0db63c0b86e981a1e97d2596d64ceceba1a5470e,Alexei Starovoitov,ast@kernel.org,1714177544,Martin KaFai Lau,martin.lau@kernel.org,1714425401,d7e6ddaca356bbd5069fe7a5a8aab2cfa0fe97d7,89de2db19317fb89a6e9163f33c3a7b23ee75a18,"bpf: Fix verifier assumptions about socket->sk + +The verifier assumes that 'sk' field in 'struct socket' is valid +and non-NULL when 'socket' pointer itself is trusted and non-NULL. +That may not be the case when socket was just created and +passed to LSM socket_accept hook. +Fix this verifier assumption and adjust tests. + +Reported-by: Liam Wisehart +Acked-by: Kumar Kartikeya Dwivedi +Fixes: 6fcd486b3a0a (""bpf: Refactor RCU enforcement in the verifier."") +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/r/20240427002544.68803-1-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau +",,Fix verifier assumptions regarding non-NULL 'sk' field in sockets when accepted by LSM hooks.,"verifier, socket, non-NULL",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['socket like programs', 'LSM like programs']" +89de2db19317fb89a6e9163f33c3a7b23ee75a18,89de2db19317fb89a6e9163f33c3a7b23ee75a18,Jakub Kicinski,kuba@kernel.org,1714417160,Jakub Kicinski,kuba@kernel.org,1714421539,6518d797d4c9a54979ace148307ba5c0c25335a5,b3f1a08fcf0dd58d99b14b9f8fbd1929f188b746 07801a24e2f18624cd2400ce15f14569eb416c9a,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-04-29 + +We've added 147 non-merge commits during the last 32 day(s) which contain +a total of 158 files changed", 9400 insertions(+),"[' 2213 deletions(-).\n\nThe main changes are:\n\n1) Add an internal-only BPF per-CPU instruction for resolving per-CPU\n memory addresses and implement support in x86 BPF JIT. This allows\n inlining per-CPU array and hashmap lookups\n and the bpf_get_smp_processor_id() helper', ' from Andrii Nakryiko.\n\n2) Add BPF link support for sk_msg and sk_skb programs', "" from Yonghong Song.\n\n3) Optimize x86 BPF JIT's emit_mov_imm64"", ' and add support for various\n atomics in bpf_arena which can be JITed as a single x86 instruction', '\n from Alexei Starovoitov.\n\n4) Add support for passing mark with bpf_fib_lookup helper', '\n from Anton Protopopov.\n\n5) Add a new bpf_wq API for deferring events and refactor sleepable\n bpf_timer code to keep common code where possible', '\n from Benjamin Tissoires.\n\n6) Fix BPF_PROG_TEST_RUN infra with regards to bpf_dummy_struct_ops programs\n to check when NULL is passed for non-NULLable parameters', ""\n from Eduard Zingerman.\n\n7) Harden the BPF verifier's and/or/xor value tracking"", '\n from Harishankar Vishwanathan.\n\n8) Introduce crypto kfuncs to make BPF programs able to utilize the kernel\n crypto subsystem', ' from Vadim Fedorenko.\n\n9) Various improvements to the BPF instruction set standardization doc', '\n from Dave Thaler.\n\n10) Extend libbpf APIs to partially consume items from the BPF ringbuffer', '\n from Andrea Righi.\n\n11) Bigger batch of BPF selftests refactoring to use common network helpers\n and to drop duplicate code', ' from Geliang Tang.\n\n12) Support bpf_tail_call_static() helper for BPF programs with GCC 13', '\n from Jose E. Marchesi.\n\n13) Add bpf_preempt_{disable', 'enable}() kfuncs in order to allow a BPF\n program to have code sections where preemption is disabled', '\n from Kumar Kartikeya Dwivedi.\n\n14) Allow invoking BPF kfuncs from BPF_PROG_TYPE_SYSCALL programs', '\n from David Vernet.\n\n15) Extend the BPF verifier to allow different input maps for a given\n bpf_for_each_map_elem() helper call in a BPF program', ' from Philo Lu.\n\n16) Add support for PROBE_MEM32 and bpf_addr_space_cast instructions\n for riscv64 and arm64 JITs to enable BPF Arena', ' from Puranjay Mohan.\n\n17) Shut up a false-positive KMSAN splat in interpreter mode by unpoison\n the stack memory', ' from Martin KaFai Lau.\n\n18) Improve xsk selftest coverage with new tests on maximum and minimum\n hardware ring size configurations', ' from Tushar Vyavahare.\n\n19) Various ReST man pages fixes as well as documentation and bash completion\n improvements for bpftool', ' from Rameez Rehman & Quentin Monnet.\n\n20) Fix libbpf with regards to dumping subsequent char arrays', ""\n from Quentin Deslandes.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (147 commits)\n bpf"", ' docs: Clarify PC use in instruction-set.rst\n bpf_helpers.h: Define bpf_tail_call_static when building with GCC\n bpf', ' docs: Add introduction for use in the ISA Internet Draft\n selftests/bpf: extend BPF_SOCK_OPS_RTT_CB test for srtt and mrtt_us\n bpf: add mrtt and srtt as BPF_SOCK_OPS_RTT_CB args\n selftests/bpf: dummy_st_ops should reject 0 for non-nullable params\n bpf: check bpf_dummy_struct_ops program params for test runs\n selftests/bpf: do not pass NULL for non-nullable params in dummy_st_ops\n selftests/bpf: adjust dummy_st_ops_success to detect additional error\n bpf: mark bpf_dummy_struct_ops.test_1 parameter as nullable\n selftests/bpf: Add ring_buffer__consume_n test.\n bpf: Add bpf_guard_preempt() convenience macro\n selftests: bpf: crypto: add benchmark for crypto functions\n selftests: bpf: crypto skcipher algo selftests\n bpf: crypto: add skcipher to bpf crypto\n bpf: make common crypto API for TC/XDP programs\n bpf: update the comment for BTF_FIELDS_MAX\n selftests/bpf: Fix wq test.\n selftests/bpf: Use make_sockaddr in test_sock_addr\n selftests/bpf: Use connect_to_addr in test_sock_addr\n ...\n====================\n\nLink: https://lore.kernel.org/r/20240429131657.19423-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merge update includes 147 non-merge commits with multiple file changes from bpf-next branch.,"merge, commits, bpf-next",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +07801a24e2f18624cd2400ce15f14569eb416c9a,07801a24e2f18624cd2400ce15f14569eb416c9a,Dave Thaler,dthaler1968@googlemail.com,1714173086,Daniel Borkmann,daniel@iogearbox.net,1714384482,19e50ffbf18843caa1fee3e790f8a3b28ac5354d,6e25bcf06af0341691f7058e17e04800f6a19e26,bpf," docs: Clarify PC use in instruction-set.rst + +This patch elaborates on the use of PC by expanding the PC acronym","['\nexplaining the units', ' and the relative position to which the offset\napplies.\n\nSigned-off-by: Dave Thaler \nSigned-off-by: Daniel Borkmann \nReviewed-by: David Vernet \nLink: https://lore.kernel.org/bpf/20240426231126.5130-1-dthaler1968@gmail.com\n', '']",This commit clarifies the use of the PC acronym in the bpf instruction set documentation.,"PC,documentation,clarity",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +8524d71cebfa6ddcfbb89f0fe0e174c8d0477c6d,8524d71cebfa6ddcfbb89f0fe0e174c8d0477c6d,Ian Rogers,irogers@google.com,1710952364,Arnaldo Carvalho de Melo,acme@redhat.com,1714180390,30a010bed9cb209543edb150c652962f526a4821,e101a05f79fd4ee3e89d2f3fb716493c33a33708,"perf build: Pretend scandirat is missing with msan + +Memory sanitizer lacks an interceptor for scandirat"," reporting all +memory it allocates as uninitialized. Memory sanitizer has a scandir +interceptor so use the fallback function in this case. This allows +'perf test' to run under memory sanitizer. + +Additional notes from Ian on running in this mode: + +Note","[' as msan needs to instrument memory allocations libraries need to\nbe compiled with it. I lacked the msan built libraries and so built\nwith:\n```\n$ make -C tools/perf O=/tmp/perf DEBUG=1 EXTRA_CFLAGS=""-O0 -g\n-fno-omit-frame-pointer -fsanitize=memory\n-fsanitize-memory-track-origins"" CC=clang CXX=clang++ HOSTCC=clang\nNO_LIBTRACEEVENT=1 NO_LIBELF=1 BUILD_BPF_SKEL=0 NO_LIBPFM=1\n```\noh', ' I disabled libbpf here as the bpf system call also lacks msan interceptors.\n\nSigned-off-by: Ian Rogers \nCc: Adrian Hunter \nCc: Alexander Shishkin \nCc: Ingo Molnar \nCc: Jiri Olsa \nCc: Mark Rutland \nCc: Namhyung Kim \nCc: Peter Zijlstra \nLink: https://lore.kernel.org/r/20240320163244.1287780-1-irogers@google.com\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",The commit modifies the perf build to use a fallback function for scandirat with memory sanitizer.,"perf, msan, scandirat",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +b2ff42c6d3abc26ef0f395fe9ee8c64364fbaa22,b2ff42c6d3abc26ef0f395fe9ee8c64364fbaa22,Jakub Kicinski,kuba@kernel.org,1714178213,Jakub Kicinski,kuba@kernel.org,1714178213,43837bf05515276032c904214ad3021693a43890,6a30653b604aaad1bf0f2e74b068ceb8b6fc7aea a86538a2efb826b9a62c7b41e0499948b04aec7d,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-04-26 + +We've added 12 non-merge commits during the last 22 day(s) which contain +a total of 14 files changed", 168 insertions(+),"[' 72 deletions(-).\n\nThe main changes are:\n\n1) Fix BPF_PROBE_MEM in verifier and JIT to skip loads from vsyscall page', '\n from Puranjay Mohan.\n\n2) Fix a crash in XDP with devmap broadcast redirect when the latter map\n is in process of being torn down', ' from Toke Høiland-Jørgensen.\n\n3) Fix arm64 and riscv64 BPF JITs to properly clear start time for BPF\n program runtime stats', ' from Xu Kuohai.\n\n4) Fix a sockmap KCSAN-reported data race in sk_psock_skb_ingress_enqueue', '\n from Jason Xing.\n\n5) Fix BPF verifier error message in resolve_pseudo_ldimm64', '\n from Anton Protopopov.\n\n6) Fix missing DEBUG_INFO_BTF_MODULES Kconfig menu item', ""\n from Andrii Nakryiko.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n selftests/bpf: Test PROBE_MEM of VSYSCALL_ADDR on x86-64\n bpf"", ' x86: Fix PROBE_MEM runtime load check\n bpf: verifier: prevent userspace memory access\n xdp: use flags field to disambiguate broadcast redirect\n arm32', ' bpf: Reimplement sign-extension mov instruction\n riscv', ' bpf: Fix incorrect runtime stats\n bpf', ' arm64: Fix incorrect runtime stats\n bpf: Fix a verifier verbose message\n bpf', ' skmsg: Fix NULL pointer dereference in sk_psock_skb_ingress_enqueue\n MAINTAINERS: bpf: Add Lehui and Puranjay as riscv64 reviewers\n MAINTAINERS: Update email address for Puranjay Mohan\n bpf', ' kconfig: Fix DEBUG_INFO_BTF_MODULES Kconfig definition\n====================\n\nLink: https://lore.kernel.org/r/20240426224248.26197-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merged bpf-related changes from the 'for-netdev' tag into the main branch involving 12 non-merge commits.,"bpf, netdev, merge",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +a86538a2efb826b9a62c7b41e0499948b04aec7d,a86538a2efb826b9a62c7b41e0499948b04aec7d,Alexei Starovoitov,ast@kernel.org,1714149919,Alexei Starovoitov,ast@kernel.org,1714149919,abcf803874950c1abaeacc544d3a317d2ff8d2fb,5bcf0dcbf9066348058b88a510c57f70f384c92c 7cd6750d9a560fa69bb640a7280479d6a67999ad,"Merge branch 'bpf-prevent-userspace-memory-access' + +Puranjay Mohan says: + +==================== +bpf: prevent userspace memory access + +V5: https://lore.kernel.org/bpf/20240324185356.59111-1-puranjay12@gmail.com/ +Changes in V6: +- Disable the verifier's instrumentation in x86-64 and update the JIT to + take care of vsyscall page in addition to userspace addresses. +- Update bpf_testmod to test for vsyscall addresses. + +V4: https://lore.kernel.org/bpf/20240321124640.8870-1-puranjay12@gmail.com/ +Changes in V5: +- Use TASK_SIZE_MAX + PAGE_SIZE"," VSYSCALL_ADDR as userspace boundary in + x86-64 JIT. +- Added Acked-by: Ilya Leoshkevich + +V3: https://lore.kernel.org/bpf/20240321120842.78983-1-puranjay12@gmail.com/ +Changes in V4: +- Disable this feature on architectures that don't define + CONFIG_ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE. +- By doing the above","["" we don't need anything explicitly for s390x.\n\nV2: https://lore.kernel.org/bpf/20240321101058.68530-1-puranjay12@gmail.com/\nChanges in V3:\n- Return 0 from bpf_arch_uaddress_limit() in disabled case because it\n returns u64.\n- Modify the check in verifier to no do instrumentation when uaddress_limit\n is 0.\n\nV1: https://lore.kernel.org/bpf/20240320105436.4781-1-puranjay12@gmail.com/\nChanges in V2:\n- Disable this feature on s390x.\n\nWith BPF_PROBE_MEM"", ' BPF allows de-referencing an untrusted pointer. To\nthwart invalid memory accesses', ' the JITs add an exception table entry for\nall such accesses. But in case the src_reg + offset is a userspace address', '\nthe BPF program might read that memory if the user has mapped it.\n\nx86-64 JIT already instruments the BPF_PROBE_MEM based loads with checks to\nskip loads from userspace addresses', "" but is doesn't check for vsyscall page\nbecause it falls in the kernel address space but is considered a userspace\npage. The second patch in this series fixes the x86-64 JIT to also skip\nloads from the vsyscall page. The last patch updates the bpf_testmod so\nthis address can be checked as part of the selftests.\n\nOther architectures don't have the complexity of the vsyscall address and\njust need to skip loads from the userspace. To make this more scalable and\nrobust"", ' the verifier is updated in the first patch to instrument\nBPF_PROBE_MEM to skip loads from the userspace addresses.\n====================\n\nLink: https://lore.kernel.org/r/20240424100210.11982-1-puranjay@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit prevents userspace memory access in eBPF by updating the verifier and JIT on x86-64.,"userspace memory access, verifier, JIT",It's a security fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7cd6750d9a560fa69bb640a7280479d6a67999ad,7cd6750d9a560fa69bb640a7280479d6a67999ad,Puranjay Mohan,puranjay@kernel.org,1713952930,Alexei Starovoitov,ast@kernel.org,1714149918,abcf803874950c1abaeacc544d3a317d2ff8d2fb,b599d7d26d6ad1fc9975218574bc2ca6d0293cfd,"selftests/bpf: Test PROBE_MEM of VSYSCALL_ADDR on x86-64 + +The vsyscall is a legacy API for fast execution of system calls. It maps +a page at address VSYSCALL_ADDR into the userspace program. This address +is in the top 10MB of the address space: + +ffffffffff600000 - ffffffffff600fff | 4 kB | legacy vsyscall ABI + +The last commit fixes the x86-64 BPF JIT to skip accessing addresses in +this memory region. Add this address to bpf_testmod_return_ptr() so we +can make sure that it is fixed. + +After this change and without the previous commit"," subprogs_extable +selftest will crash the kernel. + +Signed-off-by: Puranjay Mohan +Link: https://lore.kernel.org/r/20240424100210.11982-4-puranjay@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Test PROBE_MEM of VSYSCALL_ADDR in BPF selftests on x86-64 architecture.,"PROBE_MEM, VSYSCALL_ADDR, x86-64",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's an experimental feature that doesn't fit into existing categories.""]" +b599d7d26d6ad1fc9975218574bc2ca6d0293cfd,b599d7d26d6ad1fc9975218574bc2ca6d0293cfd,Puranjay Mohan,puranjay@kernel.org,1713952929,Alexei Starovoitov,ast@kernel.org,1714149918,2a49ec8ac3062864225e4d95d2906a758170b54c,66e13b615a0ce76b785d780ecc9776ba71983629,bpf," x86: Fix PROBE_MEM runtime load check + +When a load is marked PROBE_MEM - e.g. due to PTR_UNTRUSTED access - the +address being loaded from is not necessarily valid. The BPF jit sets up +exception handlers for each such load which catch page faults and 0 out +the destination register. + +If the address for the load is outside kernel address space","[' the load\nwill escape the exception handling and crash the kernel. To prevent this\nfrom happening', ' the emits some instruction to verify that addr is > end\nof userspace addresses.\n\nx86 has a legacy vsyscall ABI where a page at address 0xffffffffff600000\nis mapped with user accessible permissions. The addresses in this page\nare considered userspace addresses by the fault handler. Therefore', ' a\nBPF program accessing this page will crash the kernel.\n\nThis patch fixes the runtime checks to also check that the PROBE_MEM\naddress is below VSYSCALL_ADDR.\n\nExample BPF program:\n\n SEC(""fentry/tcp_v4_connect"")\n int BPF_PROG(fentry_tcp_v4_connect', ' struct sock *sk)\n {\n\t*(volatile unsigned long *)&sk->sk_tsq_flags;\n\treturn 0;\n }\n\nBPF Assembly:\n\n 0: (79) r1 = *(u64 *)(r1 +0)\n 1: (79) r1 = *(u64 *)(r1 +344)\n 2: (b7) r0 = 0\n 3: (95) exit\n\n\t\t\t x86-64 JIT\n\t\t\t ==========\n\n BEFORE AFTER\n\t ------ -----\n\n 0: nopl 0x0(%rax', '%rax', '1) 0: nopl 0x0(%rax', '%rax', '1)\n 5: xchg %ax', '%ax 5: xchg %ax', '%ax\n 7: push %rbp 7: push %rbp\n 8: mov %rsp', '%rbp 8: mov %rsp', '%rbp\n b: mov 0x0(%rdi)', '%rdi b: mov 0x0(%rdi)', '%rdi\n-------------------------------------------------------------------------------\n f: movabs $0x100000000000000', '%r11 f: movabs $0xffffffffff600000', '%r10\n19: add $0x2a0', '%rdi 19: mov %rdi', '%r11\n20: cmp %r11', '%rdi 1c: add $0x2a0', '%r11\n23: jae 0x0000000000000029 23: sub %r10', '%r11\n25: xor %edi', '%edi 26: movabs $0x100000000a00000', '%r10\n27: jmp 0x000000000000002d 30: cmp %r10', '%r11\n29: mov 0x0(%rdi)', '%rdi 33: ja 0x0000000000000039\n--------------------------------\\ 35: xor %edi', '%edi\n2d: xor %eax', '%eax \\ 37: jmp 0x0000000000000040\n2f: leave \\ 39: mov 0x2a0(%rdi)', '%rdi\n30: ret \\--------------------------------------------\n 40: xor %eax', '%eax\n 42: leave\n 43: ret\n\nSigned-off-by: Puranjay Mohan \nLink: https://lore.kernel.org/r/20240424100210.11982-3-puranjay@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fix PROBE_MEM runtime load check and exception handling in the BPF JIT compiler for untrusted pointer accesses.,"PROBE_MEM,BPF JIT,exception",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +66e13b615a0ce76b785d780ecc9776ba71983629,66e13b615a0ce76b785d780ecc9776ba71983629,Puranjay Mohan,puranjay12@gmail.com,1713952928,Alexei Starovoitov,ast@kernel.org,1714149918,946fd8a18546f2856341ad612e69e97aef4cd8b9,5bcf0dcbf9066348058b88a510c57f70f384c92c,"bpf: verifier: prevent userspace memory access + +With BPF_PROBE_MEM"," BPF allows de-referencing an untrusted pointer. To +thwart invalid memory accesses","[' the JITs add an exception table entry\nfor all such accesses. But in case the src_reg + offset is a userspace\naddress', ' the BPF program might read that memory if the user has\nmapped it.\n\nMake the verifier add guard instructions around such memory accesses and\nskip the load if the address falls into the userspace region.\n\nThe JITs need to implement bpf_arch_uaddress_limit() to define where\nthe userspace addresses end for that architecture or TASK_SIZE is taken\nas default.\n\nThe implementation is as follows:\n\nREG_AX = SRC_REG\nif(offset)\n\tREG_AX += offset;\nREG_AX >>= 32;\nif (REG_AX <= (uaddress_limit >> 32))\n\tDST_REG = 0;\nelse\n\tDST_REG = *(size *)(SRC_REG + offset);\n\nComparing just the upper 32 bits of the load address with the upper\n32 bits of uaddress_limit implies that the values are being aligned down\nto a 4GB boundary before comparison.\n\nThe above means that all loads with address <= uaddress_limit + 4GB are\nskipped. This is acceptable because there is a large hole (much larger\nthan 4GB) between userspace and kernel space memory', ' therefore a\ncorrectly functioning BPF program should not access this 4GB memory\nabove the userspace.\n\nLet\'s analyze what this patch does to the following fentry program\ndereferencing an untrusted pointer:\n\n SEC(""fentry/tcp_v4_connect"")\n int BPF_PROG(fentry_tcp_v4_connect', ' struct sock *sk)\n {\n *(volatile long *)sk;\n return 0;\n }\n\n BPF Program before | BPF Program after\n ------------------ | -----------------\n\n 0: (79) r1 = *(u64 *)(r1 +0) 0: (79) r1 = *(u64 *)(r1 +0)\n -----------------------------------------------------------------------\n 1: (79) r1 = *(u64 *)(r1 +0) --\\ 1: (bf) r11 = r1\n ----------------------------\\ \\ 2: (77) r11 >>= 32\n 2: (b7) r0 = 0 \\ \\ 3: (b5) if r11 <= 0x8000 goto pc+2\n 3: (95) exit \\ \\-> 4: (79) r1 = *(u64 *)(r1 +0)\n \\ 5: (05) goto pc+1\n \\ 6: (b7) r1 = 0\n \\--------------------------------------\n 7: (b7) r0 = 0\n 8: (95) exit\n\nAs you can see from above', ' in the best case (off=0)', ' 5 extra instructions\nare emitted.\n\nNow', "" we analyze the same program after it has gone through the JITs of\nARM64 and RISC-V architectures. We follow the single load instruction\nthat has the untrusted pointer and see what instrumentation has been\nadded around it.\n\n x86-64 JIT\n ==========\n JIT's Instrumentation\n (upstream)\n ---------------------\n\n 0: nopl 0x0(%rax"", '%rax', '1)\n 5: xchg %ax', '%ax\n 7: push %rbp\n 8: mov %rsp', '%rbp\n b: mov 0x0(%rdi)', '%rdi\n ---------------------------------\n f: movabs $0x800000000000', '%r11\n 19: cmp %r11', '%rdi\n 1c: jb 0x000000000000002a\n 1e: mov %rdi', '%r11\n 21: add $0x0', '%r11\n 28: jae 0x000000000000002e\n 2a: xor %edi', '%edi\n 2c: jmp 0x0000000000000032\n 2e: mov 0x0(%rdi)', '%rdi\n ---------------------------------\n 32: xor %eax', ""%eax\n 34: leave\n 35: ret\n\nThe x86-64 JIT already emits some instructions to protect against user\nmemory access. This patch doesn't make any changes for the x86-64 JIT.\n\n ARM64 JIT\n =========\n\n No Intrumentation Verifier's Instrumentation\n (upstream) (This patch)\n ----------------- --------------------------\n\n 0: add x9"", ' x30', ' #0x0 0: add x9', ' x30', ' #0x0\n 4: nop 4: nop\n 8: paciasp 8: paciasp\n c: stp x29', ' x30', ' [sp', ' #-16]! c: stp x29', ' x30', ' [sp', ' #-16]!\n 10: mov x29', ' sp 10: mov x29', ' sp\n 14: stp x19', ' x20', ' [sp', ' #-16]! 14: stp x19', ' x20', ' [sp', ' #-16]!\n 18: stp x21', ' x22', ' [sp', ' #-16]! 18: stp x21', ' x22', ' [sp', ' #-16]!\n 1c: stp x25', ' x26', ' [sp', ' #-16]! 1c: stp x25', ' x26', ' [sp', ' #-16]!\n 20: stp x27', ' x28', ' [sp', ' #-16]! 20: stp x27', ' x28', ' [sp', ' #-16]!\n 24: mov x25', ' sp 24: mov x25', ' sp\n 28: mov x26', ' #0x0 28: mov x26', ' #0x0\n 2c: sub x27', ' x25', ' #0x0 2c: sub x27', ' x25', ' #0x0\n 30: sub sp', ' sp', ' #0x0 30: sub sp', ' sp', ' #0x0\n 34: ldr x0', ' [x0] 34: ldr x0', ' [x0]\n--------------------------------------------------------------------------------\n 38: ldr x0', ' [x0] ----------\\ 38: add x9', ' x0', ' #0x0\n-----------------------------------\\\\ 3c: lsr x9', ' x9', ' #32\n 3c: mov x7', ' #0x0 \\\\ 40: cmp x9', ' #0x10', ' lsl #12\n 40: mov sp', ' sp \\\\ 44: b.ls 0x0000000000000050\n 44: ldp x27', ' x28', ' [sp]', ' #16 \\\\--> 48: ldr x0', ' [x0]\n 48: ldp x25', ' x26', ' [sp]', ' #16 \\ 4c: b 0x0000000000000054\n 4c: ldp x21', ' x22', ' [sp]', ' #16 \\ 50: mov x0', ' #0x0\n 50: ldp x19', ' x20', ' [sp]', ' #16 \\---------------------------------------\n 54: ldp x29', ' x30', ' [sp]', ' #16 54: mov x7', ' #0x0\n 58: add x0', ' x7', ' #0x0 58: mov sp', ' sp\n 5c: autiasp 5c: ldp x27', ' x28', ' [sp]', ' #16\n 60: ret 60: ldp x25', ' x26', ' [sp]', ' #16\n 64: nop 64: ldp x21', ' x22', ' [sp]', ' #16\n 68: ldr x10', ' 0x0000000000000070 68: ldp x19', ' x20', ' [sp]', ' #16\n 6c: br x10 6c: ldp x29', ' x30', ' [sp]', ' #16\n 70: add x0', ' x7', ' #0x0\n 74: autiasp\n 78: ret\n 7c: nop\n 80: ldr x10', "" 0x0000000000000088\n 84: br x10\n\nThere are 6 extra instructions added in ARM64 in the best case. This will\nbecome 7 in the worst case (off != 0).\n\n RISC-V JIT (RISCV_ISA_C Disabled)\n ==========\n\n No Intrumentation Verifier's Instrumentation\n (upstream) (This patch)\n ----------------- --------------------------\n\n 0: nop 0: nop\n 4: nop 4: nop\n 8: li a6"", ' 33 8: li a6', ' 33\n c: addi sp', ' sp', ' -16 c: addi sp', ' sp', ' -16\n 10: sd s0', ' 8(sp) 10: sd s0', ' 8(sp)\n 14: addi s0', ' sp', ' 16 14: addi s0', ' sp', ' 16\n 18: ld a0', ' 0(a0) 18: ld a0', ' 0(a0)\n---------------------------------------------------------------\n 1c: ld a0', ' 0(a0) --\\ 1c: mv t0', ' a0\n--------------------------\\ \\ 20: srli t0', ' t0', ' 32\n 20: li a5', ' 0 \\ \\ 24: lui t1', ' 4096\n 24: ld s0', ' 8(sp) \\ \\ 28: sext.w t1', ' t1\n 28: addi sp', ' sp', ' 16 \\ \\ 2c: bgeu t1', ' t0', ' 12\n 2c: sext.w a0', ' a5 \\ \\--> 30: ld a0', ' 0(a0)\n 30: ret \\ 34: j 8\n \\ 38: li a0', ' 0\n \\------------------------------\n 3c: li a5', ' 0\n 40: ld s0', ' 8(sp)\n 44: addi sp', ' sp', ' 16\n 48: sext.w a0', ' a5\n 4c: ret\n\nThere are 7 extra instructions added in RISC-V.\n\nFixes: 800834285361 (""bpf', ' arm64: Add BPF exception tables"")\nReported-by: Breno Leitao \nSuggested-by: Alexei Starovoitov \nAcked-by: Ilya Leoshkevich \nSigned-off-by: Puranjay Mohan \nLink: https://lore.kernel.org/r/20240424100210.11982-2-puranjay@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit improves memory access safety in BPF by using BPF_PROBE_MEM to prevent userspace memory access issues.,"verifier, memory, prevention",It's a security fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6e25bcf06af0341691f7058e17e04800f6a19e26,6e25bcf06af0341691f7058e17e04800f6a19e26,Jose E. Marchesi,jose.marchesi@oracle.com,1714143118,Daniel Borkmann,daniel@iogearbox.net,1714144204,28e1c6d15b6bd1941da881beaa8ca72ed4b40fa5,e51b907d40329d4b4517a155e0bc0bf593d6767d,"bpf_helpers.h: Define bpf_tail_call_static when building with GCC + +The definition of bpf_tail_call_static in tools/lib/bpf/bpf_helpers.h +is guarded by a preprocessor check to assure that clang is recent +enough to support it. This patch updates the guard so the function is +compiled when using GCC 13 or later as well. + +Tested in bpf-next master. No regressions. + +Signed-off-by: Jose E. Marchesi +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240426145158.14409-1-jose.marchesi@oracle.com +",,Added support for bpf_tail_call_static function in GCC 13 or later.,"bpf_tail_call_static,GCC,compile",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['other'] +15fd021bc4270273d8f4b7f58fdda8a16214a377,15fd021bc4270273d8f4b7f58fdda8a16214a377,Song Yoong Siang,yoong.siang.song@intel.com,1713992574,Paolo Abeni,pabeni@redhat.com,1714137839,d199ce09d3e6cda93e327af0a037826e578a4671,dba86b7d8778102998a6a2989f6a2d935efc6d47,"igc: Add Tx hardware timestamp request for AF_XDP zero-copy packet + +This patch adds support to per-packet Tx hardware timestamp request to +AF_XDP zero-copy packet via XDP Tx metadata framework. Please note that +user needs to enable Tx HW timestamp capability via igc_ioctl() with +SIOCSHWTSTAMP cmd before sending xsk Tx hardware timestamp request. + +Same as implementation in RX timestamp XDP hints kfunc metadata"," Timer 0 +(adjustable clock) is used in xsk Tx hardware timestamp. i225/i226 have +four sets of timestamping registers. *skb and *xsk_tx_buffer pointers +are used to indicate whether the timestamping register is already occupied. + +Furthermore","[' a boolean variable named xsk_pending_ts is used to hold the\ntransmit completion until the tx hardware timestamp is ready. This is\nbecause', ' for i225/i226', ' the timestamp notification event comes some time\nafter the transmit completion event. The driver will retrigger hardware irq\nto clean the packet after retrieve the tx hardware timestamp.\n\nBesides', ' xsk_meta is added into struct igc_tx_timestamp_request as a hook\nto the metadata location of the transmit packet. When the Tx timestamp\ninterrupt is fired', "" the interrupt handler will copy the value of Tx hwts\ninto metadata location via xsk_tx_metadata_complete().\n\nThis patch is tested with tools/testing/selftests/bpf/xdp_hw_metadata\non Intel ADL-S platform. Below are the test steps and results.\n\nTest Step 1: Run xdp_hw_metadata app\n ./xdp_hw_metadata > /dev/shm/result.log\n\nTest Step 2: Enable Tx hardware timestamp\n hwstamp_ctl -i -t 1 -r 1\n\nTest Step 3: Run ptp4l and phc2sys for time synchronization\n\nTest Step 4: Generate UDP packets with 1ms interval for 10s\n trafgen --dev '{eth(da=)"", "" udp(dp=9091)}' -t 1ms -n 10000\n\nTest Step 5: Rerun Step 1-3 with 10s iperf3 as background traffic\n\nTest Step 6: Rerun Step 1-4 with 10s iperf3 as background traffic\n\nBased on iperf3 results below"", ' the impact of holding tx completion to\nthroughput is not observable.\n\nResult of last UDP packet (no. 10000) in Step 4:\npoll: 1 (0) skip=99 fail=0 redir=10000\nxsk_ring_cons__peek: 1\n0x5640a37972d0: rx_desc[9999]->addr=f2110 addr=f2110 comp_addr=f2110 EoP\nrx_hash: 0x2049BE1D with RSS type:0x1\nHW RX-time: 1679819246792971268 (sec:1679819246.7930) delta to User RX-time sec:0.0000 (14.990 usec)\nXDP RX-time: 1679819246792981987 (sec:1679819246.7930) delta to User RX-time sec:0.0000 (4.271 usec)\nNo rx_vlan_tci or rx_vlan_proto', ' err=-95\n0x5640a37972d0: ping-pong with csum=ab19 (want 315b) csum_start=34 csum_offset=6\n0x5640a37972d0: complete tx idx=9999 addr=f010\nHW TX-complete-time: 1679819246793036971 (sec:1679819246.7930) delta to User TX-complete-time sec:0.0001 (77.656 usec)\nXDP RX-time: 1679819246792981987 (sec:1679819246.7930) delta to User TX-complete-time sec:0.0001 (132.640 usec)\nHW RX-time: 1679819246792971268 (sec:1679819246.7930) delta to HW TX-complete-time sec:0.0001 (65.703 usec)\n0x5640a37972d0: complete rx idx=10127 addr=f2110\n\nResult of iperf3 without tx hwts request in step 5:\n[ ID] Interval Transfer Bitrate Retr\n[ 5] 0.00-10.00 sec 2.74 GBytes 2.36 Gbits/sec 0 sender\n[ 5] 0.00-10.05 sec 2.74 GBytes 2.34 Gbits/sec receiver\n\nResult of iperf3 running parallel with trafgen command in step 6:\n[ ID] Interval Transfer Bitrate Retr\n[ 5] 0.00-10.00 sec 2.74 GBytes 2.36 Gbits/sec 0 sender\n[ 5] 0.00-10.04 sec 2.74 GBytes 2.34 Gbits/sec receiver\n\nCo-developed-by: Lai Peter Jun Ann \nSigned-off-by: Lai Peter Jun Ann \nSigned-off-by: Song Yoong Siang \nAcked-by: John Fastabend \nAcked-by: Vinicius Costa Gomes \nTested-by: Naama Meir \nSigned-off-by: Tony Nguyen \nLink: https://lore.kernel.org/r/20240424210256.3440903-1-anthony.l.nguyen@intel.com\nSigned-off-by: Paolo Abeni \n', '']",The commit adds Tx hardware timestamp support for AF_XDP zero-copy packets using XDP Tx metadata framework.,"Tx hardware timestamp, AF_XDP, zero-copy",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['xdp like programs'] +e51b907d40329d4b4517a155e0bc0bf593d6767d,e51b907d40329d4b4517a155e0bc0bf593d6767d,Dave Thaler,dthaler1968@googlemail.com,1713812982,Alexei Starovoitov,ast@kernel.org,1714097721,84b8f50253faec3d6b523f4ea08e621b2696cfde,876373985efb87844ca7cacd2d1d3ef4c9398c9c,bpf," docs: Add introduction for use in the ISA Internet Draft + +The proposed intro paragraph text is derived from the first paragraph +of the IETF BPF WG charter at https://datatracker.ietf.org/wg/bpf/about/ + +Signed-off-by: Dave Thaler +Acked-by: David Vernet +Link: https://lore.kernel.org/r/20240422190942.24658-1-dthaler1968@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Add introduction text for BPF ISA in the related Internet Draft documentation.,"BPF, ISA, documentation",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +876373985efb87844ca7cacd2d1d3ef4c9398c9c,876373985efb87844ca7cacd2d1d3ef4c9398c9c,Martin KaFai Lau,martin.lau@kernel.org,1714076781,Martin KaFai Lau,martin.lau@kernel.org,1714079345,90f30033f73d8801ca45d1ac453134c80b65b4db,a311c3f9c342fc12e6c8a27e22c81955ab2a336c 7eb4f66b38069eec9c86c9d115f0bba1cf73ef2c,"Merge branch 'bpf: add mrtt and srtt as ctx->args for BPF_SOCK_OPS_RTT_CB' + +Philo Lu says: + +==================== +These provides more information about tcp RTT estimation. The selftest for +BPF_SOCK_OPS_RTT_CB is extended for the added args. + +changelogs +-> v1: +- extend rtt selftest for added args (suggested by Stanislav) +==================== + +Signed-off-by: Martin KaFai Lau +",,Merge branch to add mrtt and srtt as ctx->args for BPF_SOCK_OPS_RTT_CB with extended selftests.,"mrtt, srtt, BPF_SOCK_OPS_RTT_CB",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['socket like programs'] +7eb4f66b38069eec9c86c9d115f0bba1cf73ef2c,7eb4f66b38069eec9c86c9d115f0bba1cf73ef2c,Philo Lu,lulie@linux.alibaba.com,1714061844,Martin KaFai Lau,martin.lau@kernel.org,1714079345,90f30033f73d8801ca45d1ac453134c80b65b4db,48e2cd3e3dcfe04f212df4fb189fa04c2a87b980,"selftests/bpf: extend BPF_SOCK_OPS_RTT_CB test for srtt and mrtt_us + +Because srtt and mrtt_us are added as args in bpf_sock_ops at +BPF_SOCK_OPS_RTT_CB"," a simple check is added to make sure they are both +non-zero. + +$ ./test_progs -t tcp_rtt + #373 tcp_rtt:OK + Summary: 1/0 PASSED","[' 0 SKIPPED', ' 0 FAILED\n\nSuggested-by: Stanislav Fomichev \nSigned-off-by: Philo Lu \nLink: https://lore.kernel.org/r/20240425161724.73707-3-lulie@linux.alibaba.com\nSigned-off-by: Martin KaFai Lau \n', '']",Extend BPF_SOCK_OPS_RTT_CB test to include checks for non-zero srtt and mrtt_us arguments.,"BPF_SOCK_OPS_RTT_CB,srtt,mrtt_us",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +48e2cd3e3dcfe04f212df4fb189fa04c2a87b980,48e2cd3e3dcfe04f212df4fb189fa04c2a87b980,Philo Lu,lulie@linux.alibaba.com,1714061843,Martin KaFai Lau,martin.lau@kernel.org,1714079345,25a93be2e1812044e50c7cf4909e18c8f5c8ff43,a311c3f9c342fc12e6c8a27e22c81955ab2a336c,"bpf: add mrtt and srtt as BPF_SOCK_OPS_RTT_CB args + +Two important arguments in RTT estimation", mrtt and srtt,"[' are passed to\ntcp_bpf_rtt()', ' so that bpf programs get more information about RTT\ncomputation in BPF_SOCK_OPS_RTT_CB.\n\nThe difference between bpf_sock_ops->srtt_us and the srtt here is: the\nformer is an old rtt before update', ' while srtt passed by tcp_bpf_rtt()\nis that after update.\n\nSigned-off-by: Philo Lu \nLink: https://lore.kernel.org/r/20240425161724.73707-2-lulie@linux.alibaba.com\nSigned-off-by: Martin KaFai Lau \n', '']",Add new arguments mrtt and srtt to BPF_SOCK_OPS_RTT_CB for RTT estimation.,"mrtt,srtt,RTT",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['socket like programs'] +a311c3f9c342fc12e6c8a27e22c81955ab2a336c,a311c3f9c342fc12e6c8a27e22c81955ab2a336c,Alexei Starovoitov,ast@kernel.org,1714074020,Alexei Starovoitov,ast@kernel.org,1714074163,dce5b752510c9ff8741a4cac01ea49fb0a7d3d99,638a485c4996be1d38303cf25ea8d12dfd16011b 6a2d30d3c5bf9f088dcfd5f3746b04d84f2fab83,"Merge branch 'check-bpf_dummy_struct_ops-program-params-for-test-runs' + +Eduard Zingerman says: + +==================== +check bpf_dummy_struct_ops program params for test runs + +When doing BPF_PROG_TEST_RUN for bpf_dummy_struct_ops programs"," +execution should be rejected when NULL is passed for non-nullable +params","["" because for such params verifier assumes that such params are\nnever NULL and thus might optimize out NULL checks.\n\nThis problem was reported by Jose E. Marchesi in off-list discussion.\nThe code generated by GCC for dummy_st_ops_success/test_1() function\ndiffers from LLVM variant in a way that allows verifier to remove the\nNULL check. The test dummy_st_ops/dummy_init_ret_value actually sets\nthe 'state' parameter to NULL"", ' thus GCC-generated version of the test\ntriggers NULL pointer dereference when BPF program is executed.\n\nThis patch-set addresses the issue in the following steps:\n- patch #1 marks bpf_dummy_struct_ops.test_1 parameter as nullable', ""\n for verifier to have correct assumptions about test_1() programs;\n- patch #2 modifies dummy_st_ops/dummy_init_ret_value to trigger NULL\n dereference with both GCC and LLVM (if patch #1 is not applied);\n- patch #3 adjusts a few dummy_st_ops test cases to avoid passing NULL\n for 'state' parameter of test_2() and test_sleepable() functions"", '\n as parameters of these functions are not marked as nullable;\n- patch #4 adjusts bpf_dummy_struct_ops to reject test execution of\n programs if NULL is passed for non-nullable parameter;\n- patch #5 adds a test to verify logic from patch #4.\n====================\n\nLink: https://lore.kernel.org/r/20240424012821.595216-1-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Ensure BPF_PROG_TEST_RUN rejects NULL non-nullable parameters for bpf_dummy_struct_ops programs.,"BPF_PROG_TEST_RUN,NULL,params",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6a2d30d3c5bf9f088dcfd5f3746b04d84f2fab83,6a2d30d3c5bf9f088dcfd5f3746b04d84f2fab83,Eduard Zingerman,eddyz87@gmail.com,1713922101,Alexei Starovoitov,ast@kernel.org,1714074163,dce5b752510c9ff8741a4cac01ea49fb0a7d3d99,980ca8ceeae69ddf362870ea9183f389ae26324a,"selftests/bpf: dummy_st_ops should reject 0 for non-nullable params + +Check if BPF_PROG_TEST_RUN for bpf_dummy_struct_ops programs +rejects execution if NULL is passed for non-nullable parameter. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240424012821.595216-6-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",,Ensure bpf_dummy_struct_ops programs reject null parameters in BPF_PROG_TEST_RUN tests.,"selftests,bpf,rejects",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +980ca8ceeae69ddf362870ea9183f389ae26324a,980ca8ceeae69ddf362870ea9183f389ae26324a,Eduard Zingerman,eddyz87@gmail.com,1713922100,Alexei Starovoitov,ast@kernel.org,1714074163,b66c8c8eacef1fd3ce9d0dd4afa3f04643706a6b,f612210d456a0b969a0adca91e68dbea0e0ea301,"bpf: check bpf_dummy_struct_ops program params for test runs + +When doing BPF_PROG_TEST_RUN for bpf_dummy_struct_ops programs"," +reject execution when NULL is passed for non-nullable params. +For programs with non-nullable params verifier assumes that +such params are never NULL and thus might optimize out NULL checks. + +Suggested-by: Kui-Feng Lee +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240424012821.595216-5-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Reject BPF_PROG_TEST_RUN for bpf_dummy_struct_ops with nullable params to prevent incorrect verifier optimizations.,"bpf_dummy_struct_ops, BPF_PROG_TEST_RUN, nullable",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f612210d456a0b969a0adca91e68dbea0e0ea301,f612210d456a0b969a0adca91e68dbea0e0ea301,Eduard Zingerman,eddyz87@gmail.com,1713922099,Alexei Starovoitov,ast@kernel.org,1714074163,1158bf3d384b77d23829af05650ae92f3668c44a,3b3b84aacb4420226576c9732e7b539ca7b79633,"selftests/bpf: do not pass NULL for non-nullable params in dummy_st_ops + +dummy_st_ops.test_2 and dummy_st_ops.test_sleepable do not have their +'state' parameter marked as nullable. Update dummy_st_ops.c to avoid +passing NULL for such parameters"," as the next patch would allow kernel +to enforce this restriction. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240424012821.595216-4-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Correct selftests/bpf by avoiding NULL parameters for non-nullable 'state' params in dummy_st_ops functions.,"selftests,bpf,dummy_st_ops",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +3b3b84aacb4420226576c9732e7b539ca7b79633,3b3b84aacb4420226576c9732e7b539ca7b79633,Eduard Zingerman,eddyz87@gmail.com,1713922098,Alexei Starovoitov,ast@kernel.org,1714074163,542564b85c01b47de38e1ab91e12169f97a6c483,1479eaff1f16983d8fda7c5a08a586c21891087d,"selftests/bpf: adjust dummy_st_ops_success to detect additional error + +As reported by Jose E. Marchesi in off-list discussion"," GCC and LLVM +generate slightly different code for dummy_st_ops_success/test_1(): + + SEC(""struct_ops/test_1"") + int BPF_PROG(test_1","["" struct bpf_dummy_ops_state *state)\n {\n \tint ret;\n\n \tif (!state)\n \t\treturn 0xf2f3f4f5;\n\n \tret = state->val;\n \tstate->val = 0x5a;\n \treturn ret;\n }\n\n GCC-generated LLVM-generated\n ---------------------------- ---------------------------\n 0: r1 = *(u64 *)(r1 + 0x0) 0: w0 = -0xd0c0b0b\n 1: if r1 == 0x0 goto 5f 1: r1 = *(u64 *)(r1 + 0x0)\n 2: r0 = *(s32 *)(r1 + 0x0) 2: if r1 == 0x0 goto 6f\n 3: *(u32 *)(r1 + 0x0) = 0x5a 3: r0 = *(u32 *)(r1 + 0x0)\n 4: exit 4: w2 = 0x5a\n 5: r0 = -0xd0c0b0b 5: *(u32 *)(r1 + 0x0) = r2\n 6: exit 6: exit\n\nIf the 'state' argument is not marked as nullable in\nnet/bpf/bpf_dummy_struct_ops.c"", "" the verifier would assume that\n'r1 == 0x0' is never true:\n- for the GCC version"", ' this means that instructions #5-6 would be\n marked as dead and removed;\n- for the LLVM version', "" all instructions would be marked as live.\n\nThe test dummy_st_ops/dummy_init_ret_value actually sets the 'state'\nparameter to NULL.\n\nTherefore"", "" when the 'state' argument is not marked as nullable"", '\nthe GCC-generated version of the code would trigger a NULL pointer\ndereference at instruction #3.\n\nThis patch updates the test_1() test case to always follow a shape\nsimilar to the GCC-generated version above', "" in order to verify whether\nthe 'state' nullability is marked correctly.\n\nReported-by: Jose E. Marchesi \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240424012821.595216-3-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n"", '']",The commit adjusts selftests in bpf to detect additional error cases highlighted by Jose E. Marchesi.,"selftests,bpf,error",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tracepoints like programs'] +1479eaff1f16983d8fda7c5a08a586c21891087d,1479eaff1f16983d8fda7c5a08a586c21891087d,Eduard Zingerman,eddyz87@gmail.com,1713922097,Alexei Starovoitov,ast@kernel.org,1714074163,673573b21f8fe60c3aee6bf8fc7461055d858624,638a485c4996be1d38303cf25ea8d12dfd16011b,"bpf: mark bpf_dummy_struct_ops.test_1 parameter as nullable + +Test case dummy_st_ops/dummy_init_ret_value passes NULL as the first +parameter of the test_1() function. Mark this parameter as nullable to +make verifier aware of such possibility. +Otherwise"," NULL check in the test_1() code: + + SEC(""struct_ops/test_1"") + int BPF_PROG(test_1","[' struct bpf_dummy_ops_state *state)\n {\n if (!state)\n return ...;\n\n ... access state ...\n }\n\nMight be removed by verifier', ' thus triggering NULL pointer dereference\nunder certain conditions.\n\nReported-by: Jose E. Marchesi \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240424012821.595216-2-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit marks the bpf_dummy_struct_ops.test_1 parameter as nullable to improve verifier awareness.,"nullable,test_1,verifier",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +638a485c4996be1d38303cf25ea8d12dfd16011b,638a485c4996be1d38303cf25ea8d12dfd16011b,Andrea Righi,andrea.righi@canonical.com,1714053987,Andrii Nakryiko,andrii@kernel.org,1714070764,e37af36defb714e5389207c788c35f4ae534f837,8ec3bf5c31d2a59c320ff59397f6ac362341d9d7,"selftests/bpf: Add ring_buffer__consume_n test. + +Add a testcase for the ring_buffer__consume_n() API. + +The test produces multiple samples in a ring buffer"," using a +sys_getpid() fentry prog","[' and consumes them from user-space in batches', '\nrather than consuming all of them greedily', ' like ring_buffer__consume()\ndoes.\n\nSigned-off-by: Andrea Righi \nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/lkml/CAEf4BzaR4zqUpDmj44KNLdpJ=Tpa97GrvzuzVNO5nM6b7oWd1w@mail.gmail.com\nLink: https://lore.kernel.org/bpf/20240425140627.112728-1-andrea.righi@canonical.com\n', '']",Add a test case for ring_buffer__consume_n in selftests/bpf.,"testcase, ring_buffer, API",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +8ec3bf5c31d2a59c320ff59397f6ac362341d9d7,8ec3bf5c31d2a59c320ff59397f6ac362341d9d7,Alexei Starovoitov,ast@kernel.org,1713999329,Martin KaFai Lau,martin.lau@kernel.org,1714067320,bf3311fccbe189adc9b5c517807599e111d9da8f,52578f7f53ff8fe3a8f6f3bc8b5956615c07a16e,"bpf: Add bpf_guard_preempt() convenience macro + +Add bpf_guard_preempt() macro that uses newly introduced +bpf_preempt_disable/enable() kfuncs to guard a critical section. + +Signed-off-by: Alexei Starovoitov +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/r/20240424225529.16782-1-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau +",,Introduce bpf_guard_preempt() macro for critical section protection using new bpf_preempt_disable/enable() kfuncs.,"bpf, macro, preempt",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +caf93883f623ebd29989e3c35423f386ea4a41bb,caf93883f623ebd29989e3c35423f386ea4a41bb,David S. Miller,davem@davemloft.net,1714031532,David S. Miller,davem@davemloft.net,1714031532,3e523116c5e7de8d0a426fa022f7a4c13966e453,d806871612712f1d08eb7ce81efd4ca81ca5bca1 2bf90a57f0e682872c5cfb66ffa45e432bb9c7ae,"Merge branch 'tcp-trace-next' + +Philo Lu says: + +==================== +tcp: update TCPCB_EVER_RETRANS after trace_tcp_retransmit_skb() + +Move TCPCB_EVER_RETRANS updating after the trace_tcp_retransmit_skb() +in __tcp_retransmit_skb()"," and then we are aware of whether the skb has +ever been retransmitted in this tracepoint. This can be used","[' e.g.', ' to get\nretransmission efficiency by counting skbs w/ and w/o TCPCB_EVER_RETRANS\n(through bpf tracing programs).\n\nFor this purpose', ' TCPCB_EVER_RETRANS is also needed to be exposed to bpf.\nPreviously', ' the flags are defined as macros in struct tcp_skb_cb. I moved them\nout into a new enum', ' and then they can be accessed with vmlinux.h.\n\nWe have discussed to achieve this with BPF_SOCK_OPS in [0]', ' and using\ntracepoint is thought to be a better solution.\n\n[0]\nhttps://lore.kernel.org/all/20240417124622.35333-1-lulie@linux.alibaba.com/\n====================\n\nSigned-off-by: David S. Miller \n', '']",The commit updates TCPCB_EVER_RETRANS after trace_tcp_retransmit_skb in TCP retransmission handling.,"TCP,tracepoint,retransmission",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +14b5fb2145caeb909a1cd57d9cd5e0c3cd005642,14b5fb2145caeb909a1cd57d9cd5e0c3cd005642,Philo Lu,lulie@linux.alibaba.com,1713673208,David S. Miller,davem@davemloft.net,1714031532,aa8c4baa2eae97db46536dfef4c67f067608e3b2,d806871612712f1d08eb7ce81efd4ca81ca5bca1,"tcp: move tcp_skb_cb->sacked flags to enum + +Move the flag definitions for tcp_skb_cb->sacked into a new enum named +tcp_skb_cb_sacked_flags"," then we can get access to them in bpf via +vmlinux.h","[' e.g.', ' in tracepoints.\n\nThis patch does not change any existing functionality.\n\nSigned-off-by: Philo Lu \nReviewed-by: Eric Dumazet \nSigned-off-by: David S. Miller \n', '']",Move tcp_skb_cb->sacked flags to a new enum for better access via vmlinux.h in BPF.,"tcp,flags,enum",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d806871612712f1d08eb7ce81efd4ca81ca5bca1,d806871612712f1d08eb7ce81efd4ca81ca5bca1,Jakub Kicinski,kuba@kernel.org,1714014947,Jakub Kicinski,kuba@kernel.org,1714014947,d66380e8a6418c7d824b07c2994fbcae96d63684,2fa809b90617817fec2802c7cfaeb2c66fd04c2b 3f584c211d8cc049848620472aaec1bebd8ddaae,"Merge branch 'selftests-net-extract-bpf-building-logic-from-the-makefile' + +Jakub Kicinski says: + +==================== +selftests: net: extract BPF building logic from the Makefile + +This has been sitting in my tree for a while. I will soon add YNL/libynl +support for networking selftests. This prompted a small cleanup of +the selftest makefile for net/. We don't want to be piling logic +for each library in there. YNL will get its own .mk file which can +be included. Do the same for the BPF building section"," already. + +No funcional changes here","[' just a code move and small rename.\n====================\n\nLink: https://lore.kernel.org/r/20240423183542.3807234-1-kuba@kernel.org\nSigned-off-by: Jakub Kicinski \n', '']",The commit extracts BPF building logic from the network selftests Makefile for better organization.,"selftests, BPF, Makefile",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6b88ce902f0bdcb3694a6ceddc8b3d0b40db3772,6b88ce902f0bdcb3694a6ceddc8b3d0b40db3772,Jakub Kicinski,kuba@kernel.org,1713897341,Jakub Kicinski,kuba@kernel.org,1714014945,fe004b46fad8cbb08507761b6985ee10e3a8d003,2fa809b90617817fec2802c7cfaeb2c66fd04c2b,"selftests: net: name bpf objects consistently and simplify Makefile + +The BPF sources moved with bpf_offload.py have a suffix of .bpf.c +which seems to be useful convention. Rename the 2 other BPF sources +we had. Use wildcard in the Makefile"," since we can match all those +files easily now. + +Link: https://lore.kernel.org/r/20240423183542.3807234-2-kuba@kernel.org +Signed-off-by: Jakub Kicinski +",[''],This commit renames BPF source files and simplifies the Makefile in the selftests for net.,"rename, Makefile, selftests",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8000e627dc98efc44658af6150fd81c62d936b1b,8000e627dc98efc44658af6150fd81c62d936b1b,Vadim Fedorenko,vadfed@meta.com,1713826224,Martin KaFai Lau,martin.lau@kernel.org,1713999670,788f59542e51908ad78c8fb9d32be432a2b44397,91541ab192fc7f573e6c711ba9c2ae22a299c408,"selftests: bpf: crypto: add benchmark for crypto functions + +Some simple benchmarks are added to understand the baseline of +performance. + +Signed-off-by: Vadim Fedorenko +Link: https://lore.kernel.org/r/20240422225024.2847039-5-vadfed@meta.com +Signed-off-by: Martin KaFai Lau +",,Added benchmark tests for eBPF crypto functions to assess baseline performance.,"benchmark, crypto functions, performance",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +91541ab192fc7f573e6c711ba9c2ae22a299c408,91541ab192fc7f573e6c711ba9c2ae22a299c408,Vadim Fedorenko,vadfed@meta.com,1713826223,Martin KaFai Lau,martin.lau@kernel.org,1713999670,229a0f6d70ca1af847a13a6e29f737dbfeb19685,fda4f71282b21a8cf230b656781efb0a41371fd4,"selftests: bpf: crypto skcipher algo selftests + +Add simple tc hook selftests to show the way to work with new crypto +BPF API. Some tricky dynptr initialization is used to provide empty iv +dynptr. Simple AES-ECB algo is used to demonstrate encryption and +decryption of fixed size buffers. + +Signed-off-by: Vadim Fedorenko +Link: https://lore.kernel.org/r/20240422225024.2847039-4-vadfed@meta.com +Signed-off-by: Martin KaFai Lau +",,Add selftests for tc hook using the new crypto BPF API with AES-ECB encryption demonstration.,"selftests, crypto, AES",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tc/netfilter like programs'] +fda4f71282b21a8cf230b656781efb0a41371fd4,fda4f71282b21a8cf230b656781efb0a41371fd4,Vadim Fedorenko,vadfed@meta.com,1713826222,Martin KaFai Lau,martin.lau@kernel.org,1713999670,79d1a3e8f78b070461d92be74bf086cebc21387b,3e1c6f35409f9e447bf37f64840f5b65576bfb78,"bpf: crypto: add skcipher to bpf crypto + +Implement skcipher crypto in BPF crypto framework. + +Signed-off-by: Vadim Fedorenko +Acked-by: Herbert Xu +Link: https://lore.kernel.org/r/20240422225024.2847039-3-vadfed@meta.com +Signed-off-by: Martin KaFai Lau +",,Add skcipher cryptographic support to BPF crypto framework.,"skcipher,crypto,BPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3e1c6f35409f9e447bf37f64840f5b65576bfb78,3e1c6f35409f9e447bf37f64840f5b65576bfb78,Vadim Fedorenko,vadfed@meta.com,1713826221,Martin KaFai Lau,martin.lau@kernel.org,1713999670,6ff5c59d598f975728cfdd1f4d29407d4b6cae01,95c07d58250ca3ed01855c20be568cf04e15382f,"bpf: make common crypto API for TC/XDP programs + +Add crypto API support to BPF to be able to decrypt or encrypt packets +in TC/XDP BPF programs. Special care should be taken for initialization +part of crypto algo because crypto alloc) doesn't work with preemtion +disabled"," it can be run only in sleepable BPF program. Also async crypto +is not supported because of the very same issue - TC/XDP BPF programs +are not sleepable. + +Signed-off-by: Vadim Fedorenko +Link: https://lore.kernel.org/r/20240422225024.2847039-2-vadfed@meta.com +Signed-off-by: Martin KaFai Lau +",[''],Introduce crypto API to enable packet encryption and decryption in TC/XDP BPF programs.,"crypto,API,TC/XDP",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['xdp like programs', 'tc/netfilter like programs']" +95c07d58250ca3ed01855c20be568cf04e15382f,95c07d58250ca3ed01855c20be568cf04e15382f,Haiyue Wang,haiyue.wang@intel.com,1713937507,Alexei Starovoitov,ast@kernel.org,1713999506,8dc6f962a3ed628cc02cfcd2b862a96a38c72c0f,82e38a505c9868e784ec31e743fd8a9fa5ca1084,"bpf: update the comment for BTF_FIELDS_MAX + +The commit d56b63cf0c0f (""bpf: add support for bpf_wq user type"") +changes the fields support number to 11"," just sync the comment. + +Signed-off-by: Haiyue Wang +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240424054526.8031-1-haiyue.wang@intel.com +Signed-off-by: Alexei Starovoitov +",[''],Update comment for BTF_FIELDS_MAX to reflect support for 11 fields.,"BTF_FIELDS_MAX,comment,update",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +82e38a505c9868e784ec31e743fd8a9fa5ca1084,82e38a505c9868e784ec31e743fd8a9fa5ca1084,Alexei Starovoitov,ast@kernel.org,1713992238,Alexei Starovoitov,ast@kernel.org,1713992705,90df058db0db4dde730a1aff5fb2eb4119db8634,5305b378b351dc5fd55f5f1f37ef362ae0e11d7e,"selftests/bpf: Fix wq test. + +The wq test was missing destroy(skel) part which was causing bpf progs to stay +loaded. That was causing test_progs to complain with +""Failed to unload bpf_testmod.ko from kernel: -11"" message"," but adding +destroy() wasn't enough","[' since wq callback may be delayed', ' so loop on unload of\nbpf_testmod if errno is EAGAIN.\n\nAcked-by: Andrii Nakryiko \nFixes: 8290dba51910 (""selftests/bpf: wq: add bpf_wq_start() checks"")\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes wq test by adding missing destroy(skel) to unload BPF programs correctly.,"wq test, destroy, unload",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e4c68bbaff1153e8730c16f566c78a25b2046372,e4c68bbaff1153e8730c16f566c78a25b2046372,Geliang Tang,tanggeliang@kylinos.cn,1713868531,Martin KaFai Lau,martin.lau@kernel.org,1713989549,2aa5dc5da492f6587ba40aea30d9f93339e18172,c6c40798428180516df80ce89da7bbfe1f6a828a,"selftests/bpf: Use make_sockaddr in test_sock_addr + +This patch uses public helper make_sockaddr() exported in network_helpers.h +instead of the local defined function mk_sockaddr() in test_sock_addr.c. +This can avoid duplicate code. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/1473e189d6ca1a3925de4c5354d191a14eca0f3f.1713868264.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",,"Refactored test_sock_addr to use make_sockaddr from network_helpers.h, reducing code duplication.","selftests,bpf,make_sockaddr",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +c6c40798428180516df80ce89da7bbfe1f6a828a,c6c40798428180516df80ce89da7bbfe1f6a828a,Geliang Tang,tanggeliang@kylinos.cn,1713868530,Martin KaFai Lau,martin.lau@kernel.org,1713989548,fddfaf7dc4a7b906aa8983a699d1e007733dd977,e1cdb70d075e02b1f410b8446a8ff959fa15f0ee,"selftests/bpf: Use connect_to_addr in test_sock_addr + +This patch uses public network helper connect_to_addr() exported in +network_helpers.h instead of the local defined function connect_to_server() +in test_sock_addr.c. This can avoid duplicate code. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/f263797712d93fdfaf2943585c5dfae56714a00b.1713868264.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",,Replace local function connect_to_server with public helper connect_to_addr in bpf selftests.,"selftests,bpf,connect_to_addr",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +e1cdb70d075e02b1f410b8446a8ff959fa15f0ee,e1cdb70d075e02b1f410b8446a8ff959fa15f0ee,Geliang Tang,tanggeliang@kylinos.cn,1713868529,Martin KaFai Lau,martin.lau@kernel.org,1713989548,50215708f243c87eec87717cfbe66a97877325dd,285cffbaa8e6056c2595e07e3a320e55c71870ad,"selftests/bpf: Use start_server_addr in test_sock_addr + +Include network_helpers.h in test_sock_addr.c"," use the newly added public +helper start_server_addr() instead of the local defined function +start_server(). This can avoid duplicate code. + +In order to use functions defined in network_helpers.c in test_sock_addr.c","['\nMakefile needs to be updated and needs to be included in\nnetwork_helpers.h to avoid compilation errors.\n\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/3101f57bde5502383eb41723c8956cc26be06893.1713868264.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Refactor test_sock_addr to use the start_server_addr helper from network_helpers for cleaner code.,"selftests,bpf,network_helpers",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +285cffbaa8e6056c2595e07e3a320e55c71870ad,285cffbaa8e6056c2595e07e3a320e55c71870ad,Geliang Tang,tanggeliang@kylinos.cn,1713868528,Martin KaFai Lau,martin.lau@kernel.org,1713989548,22eb34fa81d0539efda298351b62c08b15845dfb,151f7442436658ee84076681d8f52e987fe147ea,"selftests/bpf: Use log_err in open_netns/close_netns + +ASSERT helpers defined in test_progs.h shouldn't be used in public +functions like open_netns() and close_netns(). Since they depend on +test__fail() which defined in test_progs.c. Public functions may be +used not only in test_progs.c"," but in other tests like test_sock_addr.c +in the next commit. + +This patch uses log_err() to replace ASSERT helpers in open_netns() +and close_netns() in network_helpers.c to decouple dependencies","[' then\nuses ASSERT_OK_PTR() to check the return values of all open_netns().\n\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/d1dad22b2ff4909af3f8bfd0667d046e235303cb.1713868264.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Replaced ASSERT helpers with log_err in open_netns and close_netns to reduce dependencies.,"log_err, open_netns, dependencies",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +151f7442436658ee84076681d8f52e987fe147ea,151f7442436658ee84076681d8f52e987fe147ea,Geliang Tang,tanggeliang@kylinos.cn,1713868527,Martin KaFai Lau,martin.lau@kernel.org,1713989548,207cd2dec61f6841b4257c91909de2b07d628490,55d30cc90fd42587594345a025b34399585e6e19,"selftests/bpf: Fix a fd leak in error paths in open_netns + +As Martin mentioned in review comment"," there is an existing bug that +orig_netns_fd will be leaked in the later ""goto fail;"" case after +open(""/proc/self/ns/net"") in open_netns() in network_helpers.c. This +patch adds ""close(token->orig_netns_fd);"" before ""free(token);"" to +fix it. + +Fixes: a30338840fa5 (""selftests/bpf: Move open_netns() and close_netns() into network_helpers.c"") +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/a104040b47c3c34c67f3f125cdfdde244a870d3c.1713868264.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",[''],Fix a file descriptor leak in open_netns() in the BPF selftests network_helpers.c file.,"fd leak,selftests,BPF",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +55d30cc90fd42587594345a025b34399585e6e19,55d30cc90fd42587594345a025b34399585e6e19,Alexei Starovoitov,ast@kernel.org,1713977269,Alexei Starovoitov,ast@kernel.org,1713977285,c5582f4ddd6e4f9bba3bf865a063d8d7ac39f45e,dc92febf7b93da5049fe177804e6b1961fcc6bd7 3134396f1cba939783b87c63dae3a54708285a9a,"Merge branch 'introduce-bpf_preempt_-disable-enable' + +Kumar Kartikeya Dwivedi says: + +==================== +Introduce bpf_preempt_{disable","enable} + +This set introduces two kfuncs","[' bpf_preempt_disable and\nbpf_preempt_enable', ' which are wrappers around preempt_disable and\npreempt_enable in the kernel. These functions allow a BPF program to\nhave code sections where preemption is disabled. There are multiple use\ncases that are served by such a feature', ' a few are listed below:\n\n1. Writing safe per-CPU alogrithms/data structures that work correctly\n across different contexts.\n2. Writing safe per-CPU allocators similar to bpf_memalloc on top of\n array/arena memory blobs.\n3. Writing locking algorithms in BPF programs natively.\n\nNote that local_irq_disable/enable equivalent is also needed for proper\nIRQ context protection', ' but that is a more involved change and will be\nsent later.\n\nWhile bpf_preempt_{disable', 'enable} is not sufficient for all of these\nusage scenarios on its own', ' it is still necessary.\n\nThe same effect as these kfuncs can in some sense be already achieved\nusing the bpf_spin_lock or rcu_read_lock APIs', ' therefore from the\nstandpoint of kernel functionality exposure in the verifier', ' this is\nwell understood territory.\n\nNote that these helpers do allow calling kernel helpers and kfuncs from\nwithin the non-preemptible region (unless sleepable). Otherwise', ' any\nlocks built using the preemption helpers will be as limited as\nexisting bpf_spin_lock.\n\nNesting is allowed by keeping a counter for tracking remaining enables\nrequired to be performed. Similar approach can be applied to\nrcu_read_locks in a follow up.\n\nChangelog\n=========\nv1: https://lore.kernel.org/bpf/20240423061922.2295517-1-memxor@gmail.com\n\n * Move kfunc BTF ID declerations above css task kfunc for\n !CONFIG_CGROUPS config (Alexei)\n * Add test case for global function call in non-preemptible region\n (Jiri)\n====================\n\nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/r/20240424031315.2757363-1-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Introduce new kfuncs for managing preemption in eBPF programs.,"kfuncs,preemption,eBPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3134396f1cba939783b87c63dae3a54708285a9a,3134396f1cba939783b87c63dae3a54708285a9a,Kumar Kartikeya Dwivedi,memxor@gmail.com,1713928395,Alexei Starovoitov,ast@kernel.org,1713977269,c5582f4ddd6e4f9bba3bf865a063d8d7ac39f45e,fc7566ad0a826cdc8886c5dbbb39ce72a0dc6333,"selftests/bpf: Add tests for preempt kfuncs + +Add tests for nested cases"," nested count preservation upon different +subprog calls that disable/enable preemption","[' and test sleepable helper\ncall in non-preemptible regions.\n\n182/1 preempt_lock/preempt_lock_missing_1:OK\n182/2 preempt_lock/preempt_lock_missing_2:OK\n182/3 preempt_lock/preempt_lock_missing_3:OK\n182/4 preempt_lock/preempt_lock_missing_3_minus_2:OK\n182/5 preempt_lock/preempt_lock_missing_1_subprog:OK\n182/6 preempt_lock/preempt_lock_missing_2_subprog:OK\n182/7 preempt_lock/preempt_lock_missing_2_minus_1_subprog:OK\n182/8 preempt_lock/preempt_balance:OK\n182/9 preempt_lock/preempt_balance_subprog_test:OK\n182/10 preempt_lock/preempt_global_subprog_test:OK\n182/11 preempt_lock/preempt_sleepable_helper:OK\n182 preempt_lock:OK\nSummary: 1/11 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\nSigned-off-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/r/20240424031315.2757363-3-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftests for nested preempt kfunc cases in BPF.,"selftests, preempt, kfuncs",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fc7566ad0a826cdc8886c5dbbb39ce72a0dc6333,fc7566ad0a826cdc8886c5dbbb39ce72a0dc6333,Kumar Kartikeya Dwivedi,memxor@gmail.com,1713928394,Alexei Starovoitov,ast@kernel.org,1713977269,141b3fc7a2c4174e8d6d685a20229ffedea61846,dc92febf7b93da5049fe177804e6b1961fcc6bd7,bpf: Introduce bpf_preempt_[disable,"enable] kfuncs + +Introduce two new BPF kfuncs","[' bpf_preempt_disable and\nbpf_preempt_enable. These kfuncs allow disabling preemption in BPF\nprograms. Nesting is allowed', ' since the intended use cases includes\nbuilding native BPF spin locks without kernel helper involvement. Apart\nfrom that', ' this can be used to per-CPU data structures for cases where\nprograms (or userspace) may preempt one or the other. Currently', ' while\nper-CPU access is stable', ' whether it will be consistent is not\nguaranteed', ' as only migration is disabled for BPF programs.\n\nGlobal functions are disallowed from being called', ' but support for them\nwill be added as a follow up not just preempt kfuncs', ' but rcu_read_lock\nkfuncs as well. Static subprog calls are permitted. Sleepable helpers\nand kfuncs are disallowed in non-preemptible regions.\n\nSigned-off-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/r/20240424031315.2757363-2-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Introduce two new BPF kfuncs for preempt disable support.,BPF kfuncs preempt,It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dc92febf7b93da5049fe177804e6b1961fcc6bd7,dc92febf7b93da5049fe177804e6b1961fcc6bd7,Alexei Starovoitov,ast@kernel.org,1713974423,Alexei Starovoitov,ast@kernel.org,1713974810,cd49ada6055ba7c3933b03d82998efb303ec19a1,6e10b6350a67d398c795ac0b93a7bb7103633fe4,"bpf: Don't check for recursion in bpf_wq_work. + +__bpf_prog_enter_sleepable_recur does recursion check which is not applicable +to wq callback. The callback function is part of bpf program and bpf prog might +be running on the same cpu. So recursion check would incorrectly prevent +callback from running. The code can call __bpf_prog_enter_sleepable()"," but +run_ctx would be fake","[' hence use explicit rcu_read_lock_trace();\nmigrate_disable(); to address this problem. Another reason to open code is\n__bpf_prog_enter* are not available in !JIT configs.\n\nReported-by: kernel test robot \nCloses: https://lore.kernel.org/oe-kbuild-all/202404241719.IIGdpAku-lkp@intel.com/\nCloses: https://lore.kernel.org/oe-kbuild-all/202404241811.FFV4Bku3-lkp@intel.com/\nFixes: eb48f6cd41a0 (""bpf: wq: add bpf_wq_init"")\nSigned-off-by: Alexei Starovoitov \n', '']",Remove unnecessary recursion check in bpf_wq_work callback function.,"recursion, bpf_wq_work, callback",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['other'] +1adb825af946fa6b2104c1713ad4999283e09fbc,1adb825af946fa6b2104c1713ad4999283e09fbc,Joel Granados,j.granados@samsung.com,1687872619,Joel Granados,j.granados@samsung.com,1713944634,975b06017d9e24f8f150b792b3e44b8da0d1fc5e,f15843f725a55d7232aa9b699be52c2c3da06982,"bpf: Remove the now superfluous sentinel elements from ctl_table array + +This commit comes at the tail end of a greater effort to remove the +empty elements at the end of the ctl_table arrays (sentinels) which +will reduce the overall build time size of the kernel and run time +memory bloat by ~64 bytes per sentinel (further information Link : +https://lore.kernel.org/all/ZO5Yx5JFogGi%2FcBo@bombadil.infradead.org/) + +Remove sentinel element from bpf_syscall_table. + +Acked-by: Andrii Nakryiko +Signed-off-by: Joel Granados +",,This commit removes superfluous sentinel elements from the ctl_table array to reduce kernel build size and memory usage.,"sentinel, ctl_table, bpf",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6e10b6350a67d398c795ac0b93a7bb7103633fe4,6e10b6350a67d398c795ac0b93a7bb7103633fe4,Alexei Starovoitov,ast@kernel.org,1713922286,Alexei Starovoitov,ast@kernel.org,1713926817,93ee7e7ef3781f5b19811715f4dc05a5a78c06cb,a7de265cb2d849f8986a197499ad58dca0a4f209 8290dba51910d36721ced6ccf03049ed6b7ea2ce,"Merge branch 'introduce-bpf_wq' + +Benjamin Tissoires says: + +==================== +Introduce bpf_wq + +This is a followup of sleepable bpf_timer[0]. + +When discussing sleepable bpf_timer"," it was thought that we should give +a try to bpf_wq","["" as the 2 APIs are similar but distinct enough to\njustify a new one.\n\nSo here it is.\n\nI tried to keep as much as possible common code in kernel/bpf/helpers.c\nbut I couldn't get away with code duplication in kernel/bpf/verifier.c.\n\nThis series introduces a basic bpf_wq support:\n- creation is supported\n- assignment is supported\n- running a simple bpf_wq is also supported.\n\nWe will probably need to extend the API further with:\n- a full delayed_work API (can be piggy backed on top with a correct\n flag)\n- bpf_wq_cancel() <- apparently not"", ' this is shooting ourself in the\n foot\n- bpf_wq_cancel_sync() (for sleepable programs)\n- documentation\n---\n\nFor reference', ' the use cases I have in mind:\n\n---\n\nBasically', ' I need to be able to defer a HID-BPF program for the\nfollowing reasons (from the aforementioned patch):\n1. defer an event:\n Sometimes we receive an out of proximity event', ' but the device can not\n be trusted enough', "" and we need to ensure that we won't receive another\n one in the following n milliseconds. So we need to wait those n\n milliseconds"", ' and eventually re-inject that event in the stack.\n\n2. inject new events in reaction to one given event:\n We might want to transform one given event into several. This is the\n case for macro keys where a single key press is supposed to send\n a sequence of key presses. But this could also be used to patch a\n faulty behavior', ' if a device forgets to send a release event.\n\n3. communicate with the device in reaction to one event:\n We might want to communicate back to the device after a given event.\n For example a device might send us an event saying that it came back\n from sleeping state and needs to be re-initialized.\n\nCurrently we can achieve that by keeping a userspace program around', '\nraise a bpf event', ' and let that userspace program inject the events and\ncommands.\nHowever', ' we are just keeping that program alive as a daemon for just\nscheduling commands. There is no logic in it', "" so it doesn't really justify\nan actual userspace wakeup. So a kernel workqueue seems simpler to handle.\n\nbpf_timers are currently running in a soft IRQ context"", ' this patch\nseries implements a sleppable context for them.\n\nCheers', '\nBenjamin\n\n[0] https://lore.kernel.org/all/20240408-hid-bpf-sleepable-v6-0-0499ddd91b94@kernel.org/\n\nChanges in v2:\n- took previous review into account\n- mainly dropped BPF_F_WQ_SLEEPABLE\n- Link to v1: https://lore.kernel.org/r/20240416-bpf_wq-v1-0-c9e66092f842@kernel.org\n\n====================\n\nLink: https://lore.kernel.org/r/20240420-bpf_wq-v2-0-6c986a5a741f@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit introduces a new bpf_wq following the development of sleepable bpf_timer.,"bpf_wq,sleepable,bpf_timer",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8290dba51910d36721ced6ccf03049ed6b7ea2ce,8290dba51910d36721ced6ccf03049ed6b7ea2ce,Benjamin Tissoires,bentiss@kernel.org,1713604156,Alexei Starovoitov,ast@kernel.org,1713926817,93ee7e7ef3781f5b19811715f4dc05a5a78c06cb,8e83da9732d91c60fdc651b2486c8e5935eb0ca2,"selftests/bpf: wq: add bpf_wq_start() checks + +Allows to test if allocation/free works + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-16-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",,This commit adds bpf_wq_start() checks in selftests for allocation and free operations.,"bpf_wq_start, selftests, allocation",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8e83da9732d91c60fdc651b2486c8e5935eb0ca2,8e83da9732d91c60fdc651b2486c8e5935eb0ca2,Benjamin Tissoires,bentiss@kernel.org,1713604155,Alexei Starovoitov,ast@kernel.org,1713926817,18999a6bd18485265aaa1b5767373890b899118a,01b7b1c5f3cc029bdd2652eba61e953ccd286c0e,"bpf: add bpf_wq_start + +again"," copy/paste from bpf_timer_start(). + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-15-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],The commit adds a new function bpf_wq_start to the eBPF subsystem.,"bpf, wq, start",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +01b7b1c5f3cc029bdd2652eba61e953ccd286c0e,01b7b1c5f3cc029bdd2652eba61e953ccd286c0e,Benjamin Tissoires,bentiss@kernel.org,1713604154,Alexei Starovoitov,ast@kernel.org,1713926817,d42f14399f3586735de7a902beeb691b43ae1f24,81f1d7a583fa1fa14f0c4e6140d34b5e3d08d227,"selftests/bpf: add checks for bpf_wq_set_callback() + +We assign the callback and set everything up. +The actual tests of these callbacks will be done when bpf_wq_start() is +available. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-14-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",,Added selftests for bpf_wq_set_callback() function but await further tests with bpf_wq_start().,"selftests, bpf_wq_set_callback, callback",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +81f1d7a583fa1fa14f0c4e6140d34b5e3d08d227,81f1d7a583fa1fa14f0c4e6140d34b5e3d08d227,Benjamin Tissoires,bentiss@kernel.org,1713604153,Alexei Starovoitov,ast@kernel.org,1713926817,17f05f9ee42a2660f9ad0a48a2179800634fc5e9,e3d9eac99afd94980475833479332fefd74c5c2b,"bpf: wq: add bpf_wq_set_callback_impl + +To support sleepable async callbacks"," we need to tell push_async_cb() +whether the cb is sleepable or not. + +The verifier now detects that we are in bpf_wq_set_callback_impl and +can allow a sleepable callback to happen. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-13-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add bpf_wq_set_callback_impl to support sleepable async callbacks in eBPF.,"bpf, wq, sleepable",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e3d9eac99afd94980475833479332fefd74c5c2b,e3d9eac99afd94980475833479332fefd74c5c2b,Benjamin Tissoires,bentiss@kernel.org,1713604152,Alexei Starovoitov,ast@kernel.org,1713926817,574bb867d45251d887c5ace80758a5f01322909b,eb48f6cd41a0f7803770a76bbffb6bd5b1b2ae2f,"selftests/bpf: wq: add bpf_wq_init() checks + +Allows to test if allocation/free works + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-12-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add selftests for bpf_wq_init to verify allocation and free operations.,"selftests,bpf_wq_init,allocation",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +eb48f6cd41a0f7803770a76bbffb6bd5b1b2ae2f,eb48f6cd41a0f7803770a76bbffb6bd5b1b2ae2f,Benjamin Tissoires,bentiss@kernel.org,1713604151,Alexei Starovoitov,ast@kernel.org,1713926817,46da490f63b2559a7d0915df149ab549f7ab0fdf,b4abee7c1ae3d59440e7915da28c6d2cd394738a,"bpf: wq: add bpf_wq_init + +We need to teach the verifier about the second argument which is declared +as void * but which is of type KF_ARG_PTR_TO_MAP. We could have dropped +this extra case if we declared the second argument as struct bpf_map *"," +but that means users will have to do extra casting to have their program +compile. + +We also need to duplicate the timer code for the checking if the map +argument is matching the provided workqueue. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-11-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add bpf_wq_init with type check for the second argument to handle pointers to maps in eBPF verifier.,"bpf_wq_init,pointer,map",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b4abee7c1ae3d59440e7915da28c6d2cd394738a,b4abee7c1ae3d59440e7915da28c6d2cd394738a,Benjamin Tissoires,bentiss@kernel.org,1713604150,Alexei Starovoitov,ast@kernel.org,1713926813,a871c296f683f80a3bc59ffdcc383b357af5f497,246331e3f1eac905170a923f0ec76725c2558232,"selftests/bpf: add bpf_wq tests + +We simply try in all supported map types if we can store/load a bpf_wq. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-10-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",,Adds tests for storing/loading bpf_wq in all supported eBPF map types.,"bpf_wq,test,map",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +58a4c9b1e5a3e53c9148e80b90e1e43897ce77d1,58a4c9b1e5a3e53c9148e80b90e1e43897ce77d1,Eric Dumazet,edumazet@google.com,1713725006,Jakub Kicinski,kuba@kernel.org,1713924177,900327ad1156d87dc962da75decf355905324aa2,3584718cf2ec7e79b6814f2596dcf398c5fb2eca,"ipv4: check for NULL idev in ip_route_use_hint() + +syzbot was able to trigger a NULL deref in fib_validate_source() +in an old tree [1]. + +It appears the bug exists in latest trees. + +All calls to __in_dev_get_rcu() must be checked for a NULL result. + +[1] +general protection fault"," probably for non-canonical address 0xdffffc0000000000: 0000 [#1] SMP KASAN +KASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007] +CPU: 2 PID: 3257 Comm: syz-executor.3 Not tainted 5.10.0-syzkaller #0 +Hardware name: QEMU Standard PC (Q35 + ICH9","[' 2009)', ' BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014\n RIP: 0010:fib_validate_source+0xbf/0x15a0 net/ipv4/fib_frontend.c:425\nCode: 18 f2 f2 f2 f2 42 c7 44 20 23 f3 f3 f3 f3 48 89 44 24 78 42 c6 44 20 27 f3 e8 5d 88 48 fc 4c 89 e8 48 c1 e8 03 48 89 44 24 18 <42> 80 3c 20 00 74 08 4c 89 ef e8 d2 15 98 fc 48 89 5c 24 10 41 bf\nRSP: 0018:ffffc900015fee40 EFLAGS: 00010246\nRAX: 0000000000000000 RBX: ffff88800f7a4000 RCX: ffff88800f4f90c0\nRDX: 0000000000000000 RSI: 0000000004001eac RDI: ffff8880160c64c0\nRBP: ffffc900015ff060 R08: 0000000000000000 R09: ffff88800f7a4000\nR10: 0000000000000002 R11: ffff88800f4f90c0 R12: dffffc0000000000\nR13: 0000000000000000 R14: 0000000000000000 R15: ffff88800f7a4000\nFS: 00007f938acfe6c0(0000) GS:ffff888058c00000(0000) knlGS:0000000000000000\nCS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033\nCR2: 00007f938acddd58 CR3: 000000001248e000 CR4: 0000000000352ef0\nDR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000\nDR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400\nCall Trace:\n ip_route_use_hint+0x410/0x9b0 net/ipv4/route.c:2231\n ip_rcv_finish_core+0x2c4/0x1a30 net/ipv4/ip_input.c:327\n ip_list_rcv_finish net/ipv4/ip_input.c:612 [inline]\n ip_sublist_rcv+0x3ed/0xe50 net/ipv4/ip_input.c:638\n ip_list_rcv+0x422/0x470 net/ipv4/ip_input.c:673\n __netif_receive_skb_list_ptype net/core/dev.c:5572 [inline]\n __netif_receive_skb_list_core+0x6b1/0x890 net/core/dev.c:5620\n __netif_receive_skb_list net/core/dev.c:5672 [inline]\n netif_receive_skb_list_internal+0x9f9/0xdc0 net/core/dev.c:5764\n netif_receive_skb_list+0x55/0x3e0 net/core/dev.c:5816\n xdp_recv_frames net/bpf/test_run.c:257 [inline]\n xdp_test_run_batch net/bpf/test_run.c:335 [inline]\n bpf_test_run_xdp_live+0x1818/0x1d00 net/bpf/test_run.c:363\n bpf_prog_test_run_xdp+0x81f/0x1170 net/bpf/test_run.c:1376\n bpf_prog_test_run+0x349/0x3c0 kernel/bpf/syscall.c:3736\n __sys_bpf+0x45c/0x710 kernel/bpf/syscall.c:5115\n __do_sys_bpf kernel/bpf/syscall.c:5201 [inline]\n __se_sys_bpf kernel/bpf/syscall.c:5199 [inline]\n __x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:5199\n\nFixes: 02b24941619f (""ipv4: use dst hint for ipv4 list receive"")\nReported-by: syzbot \nSigned-off-by: Eric Dumazet \nAcked-by: Paolo Abeni \nLink: https://lore.kernel.org/r/20240421184326.1704930-1-edumazet@google.com\nSigned-off-by: Jakub Kicinski \n', '']",Fixes a NULL pointer dereference in ip_route_use_hint by ensuring __in_dev_get_rcu() results are checked for NULL.,"NULL dereference, ipv4, ip_route_use_hint",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['other'] +246331e3f1eac905170a923f0ec76725c2558232,246331e3f1eac905170a923f0ec76725c2558232,Benjamin Tissoires,bentiss@kernel.org,1713604149,Alexei Starovoitov,ast@kernel.org,1713922285,1755b8cb148983f6d91ea433cbad3d2432167300,d940c9b94d7e6d9cff288623e3e8bf5fdea98b79,"bpf: allow struct bpf_wq to be embedded in arraymaps and hashmaps + +Currently bpf_wq_cancel_and_free() is just a placeholder as there is +no memory allocation for bpf_wq just yet. + +Again"," duplication of the bpf_timer approach + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-9-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Allow embedding of struct bpf_wq in arraymaps and hashmaps.,"bpf_wq,arraymaps,hashmaps",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d940c9b94d7e6d9cff288623e3e8bf5fdea98b79,d940c9b94d7e6d9cff288623e3e8bf5fdea98b79,Benjamin Tissoires,bentiss@kernel.org,1713604148,Alexei Starovoitov,ast@kernel.org,1713922285,2d9e3416aff6486023963dfb28622aa28f454fd4,ad2c03e691be3268eefc75ff1d892db3f0e79f62,"bpf: add support for KF_ARG_PTR_TO_WORKQUEUE + +Introduce support for KF_ARG_PTR_TO_WORKQUEUE. The kfuncs will use bpf_wq +as argument and that will be recognized as workqueue argument by verifier. +bpf_wq_kern casting can happen inside kfunc"," but using bpf_wq in +argument makes life easier for users who work with non-kern type in BPF +progs. + +Duplicate process_timer_func into process_wq_func. +meta argument is only needed to ensure bpf_wq_init's workqueue and map +arguments are coming from the same map (map_uid logic is necessary for +correct inner-map handling)","[' so also amend check_kfunc_args() to\nmatch what helpers functions check is doing.\n\nSigned-off-by: Benjamin Tissoires \nLink: https://lore.kernel.org/r/20240420-bpf_wq-v2-8-6c986a5a741f@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit adds support for KF_ARG_PTR_TO_WORKQUEUE to recognize workqueue arguments within kfuncs for eBPF programs.,"KF_ARG_PTR_TO_WORKQUEUE,bpf_wq,verifier",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ad2c03e691be3268eefc75ff1d892db3f0e79f62,ad2c03e691be3268eefc75ff1d892db3f0e79f62,Benjamin Tissoires,bentiss@kernel.org,1713604147,Alexei Starovoitov,ast@kernel.org,1713922284,915aecb9964c714c552cd7b37c765e0eb053858c,f1d0a2fbb0088675cceeab73d1f4b4308b289984,"bpf: verifier: bail out if the argument is not a map + +When a kfunc is declared with a KF_ARG_PTR_TO_MAP"," we should have +reg->map_ptr set to a non NULL value","[' otherwise', ' that means that the\nunderlying type is not a map.\n\nSigned-off-by: Benjamin Tissoires \nLink: https://lore.kernel.org/r/20240420-bpf_wq-v2-7-6c986a5a741f@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add a check to ensure reg->map_ptr is non-NULL when kfunc declares with KF_ARG_PTR_TO_MAP.,"bpf,verifier,map",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f1d0a2fbb0088675cceeab73d1f4b4308b289984,f1d0a2fbb0088675cceeab73d1f4b4308b289984,Benjamin Tissoires,bentiss@kernel.org,1713604146,Alexei Starovoitov,ast@kernel.org,1713922284,33e61cc04c43af72b130a1e5e1d10ecf49b69cf8,d56b63cf0c0f71e1b2e04dd8220b408f049e67ff,"tools: sync include/uapi/linux/bpf.h + +cp include/uapi/linux/bpf.h tools/include/uapi/linux/bpf.h + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-6-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",,Syncs bpf.h header files between include and tools directories.,"sync,uapi,bpf.h",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +d56b63cf0c0f71e1b2e04dd8220b408f049e67ff,d56b63cf0c0f71e1b2e04dd8220b408f049e67ff,Benjamin Tissoires,bentiss@kernel.org,1713604145,Alexei Starovoitov,ast@kernel.org,1713922284,c285bc78a8db309b3e1ec39e5881ba1477b611d9,fc22d9495f0b32d75b5d25a17b300b7aad05c55d,"bpf: add support for bpf_wq user type + +Mostly a copy/paste from the bpf_timer API"," without the initialization +and free","[' as they will be done in a separate patch.\n\nSigned-off-by: Benjamin Tissoires \nLink: https://lore.kernel.org/r/20240420-bpf_wq-v2-5-6c986a5a741f@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']","Added support for a new bpf_wq user type in eBPF, similar to bpf_timer API.","bpf_wq,user,type",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fc22d9495f0b32d75b5d25a17b300b7aad05c55d,fc22d9495f0b32d75b5d25a17b300b7aad05c55d,Benjamin Tissoires,bentiss@kernel.org,1713604144,Alexei Starovoitov,ast@kernel.org,1713922284,0230b90cf5d85d42df5000db0ba50ea2c59e2a46,073f11b0264310b85754b6a0946afee753790c66,"bpf: replace bpf_timer_cancel_and_free with a generic helper + +Same reason than most bpf_timer* functions"," we need almost the same for +workqueues. +So extract the generic part out of it so bpf_wq_cancel_and_free can reuse +it. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-4-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Refactor bpf_timer_cancel_and_free to a generic helper for reuse in bpf_wq_cancel_and_free.,bpf timer helper,It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +073f11b0264310b85754b6a0946afee753790c66,073f11b0264310b85754b6a0946afee753790c66,Benjamin Tissoires,bentiss@kernel.org,1713604143,Alexei Starovoitov,ast@kernel.org,1713922284,e43f0fad5af09702d86484afd32511e0b6bee870,56b4a177ae6322173360a93ea828ad18570a5a14,"bpf: replace bpf_timer_set_callback with a generic helper + +In the same way we have a generic __bpf_async_init()"," we also need +to share code between timer and workqueue for the set_callback call. + +We just add an unused flags parameter","[' as it will be used for workqueues.\n\nSigned-off-by: Benjamin Tissoires \nLink: https://lore.kernel.org/r/20240420-bpf_wq-v2-3-6c986a5a741f@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit replaces bpf_timer_set_callback with a generic helper function for shared code between timer and workqueue.,"bpf,generic,helper",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +56b4a177ae6322173360a93ea828ad18570a5a14,56b4a177ae6322173360a93ea828ad18570a5a14,Benjamin Tissoires,bentiss@kernel.org,1713604142,Alexei Starovoitov,ast@kernel.org,1713922284,acb7ffd67d20b48bdce8617c3c5de6de46ecfedc,be2749beff62e0d63cf97fe63cabc79a68443139,"bpf: replace bpf_timer_init with a generic helper + +No code change except for the new flags argument being stored in the +local data struct. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240420-bpf_wq-v2-2-6c986a5a741f@kernel.org +Signed-off-by: Alexei Starovoitov +",,The commit replaces bpf_timer_init with a generic helper function while adding a new flags argument.,"bpf_timer_init,generic helper,flags argument",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +be2749beff62e0d63cf97fe63cabc79a68443139,be2749beff62e0d63cf97fe63cabc79a68443139,Benjamin Tissoires,bentiss@kernel.org,1713604141,Alexei Starovoitov,ast@kernel.org,1713922284,61df1e8b730fe4ccaf8953e015e043e767f20a30,a7de265cb2d849f8986a197499ad58dca0a4f209,"bpf: make timer data struct more generic + +To be able to add workqueues and reuse most of the timer code"," we need +to make bpf_hrtimer more generic. + +There is no code change except that the new struct gets a new u64 flags +attribute. We are still below 2 cache lines","["" so this shouldn't impact\nthe current running codes.\n\nThe ordering is also changed. Everything related to async callback\nis now on top of bpf_hrtimer.\n\nSigned-off-by: Benjamin Tissoires \nLink: https://lore.kernel.org/r/20240420-bpf_wq-v2-1-6c986a5a741f@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",Refactor the bpf_hrtimer to be more generic and reusable for workqueues.,"bpf_hrtimer,generic,reusable",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b240fc56b8fd5d383bd00e59ddf67a4f66b86bb8,b240fc56b8fd5d383bd00e59ddf67a4f66b86bb8,Jakub Kicinski,kuba@kernel.org,1713820815,Jakub Kicinski,kuba@kernel.org,1713820892,3892e41bc52cb28a06d3d8707db5bde6d3c36ddc,c51db4ac10d57c366f9a92121e3889bfc6c324cd 96944aafaaa64e6ead1d3d227a1493dd8196a827,"Merge branch 'net-dsa-vsc73xx-convert-to-phylink-and-do-some-cleanup' + +Pawel Dembicki says: + +==================== +net: dsa: vsc73xx: convert to PHYLINK and do some cleanup + +This patch series is a result of splitting a larger patch series [0]"," +where some parts needed to be refactored. + +The first patch switches from a poll loop to read_poll_timeout. + +The second patch is a simple conversion to phylink because adjust_link +won't work anymore. + +The third patch is preparation for future use. Using the +""phy_interface_mode_is_rgmii"" macro allows for the proper recognition +of all RGMII modes. + +Patches 4-5 involve some cleanup: The fourth patch introduces +a definition with the maximum number of ports to avoid using +magic numbers. The next one fills in documentation. + +[0] https://patchwork.kernel.org/project/netdevbpf/list/?series=841034&state=%2A&archive=both +==================== + +Link: https://lore.kernel.org/r/20240417205048.3542839-1-paweldembicki@gmail.com +Signed-off-by: Jakub Kicinski +",[''],The commit converts net-dsa-vsc73xx to PHYLINK and includes code cleanup and refactoring.,"PHYLINK, cleanup, refactoring",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +584ed2f76ff5fe360d87a04d17b6520c7999e06b,584ed2f76ff5fe360d87a04d17b6520c7999e06b,Johannes Berg,johannes.berg@intel.com,1711616796,Richard Weinberger,richard@nod.at,1713817720,ecf59a02c9fd01f5d5030d404d135eedbc5b4027,e3cce8d87d6407f83a5741c3c5d54bf1365c6ac6,"um: vector: fix bpfflash parameter evaluation + +With W=1 the build complains about a pointer compared to +zero"," clearly the result should've been compared. + +Fixes: 9807019a62dc (""um: Loadable BPF ""Firmware"" for vector drivers"") +Signed-off-by: Johannes Berg +Reviewed-by: Tiwei Bie +Signed-off-by: Richard Weinberger +",[''],Fixes pointer comparison issue in bpfflash parameter evaluation for vector drivers in UML.,"bpfflash,vector,UML",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +5bcf0dcbf9066348058b88a510c57f70f384c92c,5bcf0dcbf9066348058b88a510c57f70f384c92c,Toke Høiland-Jørgensen,toke@redhat.com,1713424719,Martin KaFai Lau,martin.lau@kernel.org,1713806681,5dbacf55aeaf1098c36f41e79ed39dec96660800,c6f48506ba30c722dd9d89aa6a40eb1926277dff,"xdp: use flags field to disambiguate broadcast redirect + +When redirecting a packet using XDP"," the bpf_redirect_map() helper will set +up the redirect destination information in struct bpf_redirect_info (using +the __bpf_xdp_redirect_map() helper function)","[' and the xdp_do_redirect()\nfunction will read this information after the XDP program returns and pass\nthe frame on to the right redirect destination.\n\nWhen using the BPF_F_BROADCAST flag to do multicast redirect to a whole\nmap', "" __bpf_xdp_redirect_map() sets the 'map' pointer in struct\nbpf_redirect_info to point to the destination map to be broadcast. And\nxdp_do_redirect() reacts to the value of this map pointer to decide whether\nit's dealing with a broadcast or a single-value redirect. However"", ' if the\ndestination map is being destroyed before xdp_do_redirect() is called', ' the\nmap pointer will be cleared out (by bpf_clear_redirect_map()) without\nwaiting for any XDP programs to stop running. This causes xdp_do_redirect()\nto think that the redirect was to a single target', "" but the target pointer\nis also NULL (since broadcast redirects don't have a single target)"", ' so\nthis causes a crash when a NULL pointer is passed to dev_map_enqueue().\n\nTo fix this', "" change xdp_do_redirect() to react directly to the presence of\nthe BPF_F_BROADCAST flag in the 'flags' value in struct bpf_redirect_info\nto disambiguate between a single-target and a broadcast redirect. And only\nread the 'map' pointer if the broadcast flag is set"", ' aborting if that has\nbeen cleared out in the meantime. This prevents the crash', ' while keeping\nthe atomic (cmpxchg-based) clearing of the map pointer itself', ' and without\nadding any more checks in the non-broadcast fast path.\n\nFixes: e624d4ed4aa8 (""xdp: Extend xdp_redirect_map with broadcast support"")\nReported-and-tested-by: syzbot+af9492708df9797198d6@syzkaller.appspotmail.com\nSigned-off-by: Toke Høiland-Jørgensen \nAcked-by: Stanislav Fomichev \nReviewed-by: Hangbin Liu \nAcked-by: Jesper Dangaard Brouer \nLink: https://lore.kernel.org/r/20240418071840.156411-1-toke@redhat.com\nSigned-off-by: Martin KaFai Lau \n', '']",The commit utilizes flags to clarify broadcast redirects in XDP packet redirection.,"xdp, broadcast, redirect",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['xdp like programs'] +a7de265cb2d849f8986a197499ad58dca0a4f209,a7de265cb2d849f8986a197499ad58dca0a4f209,Rafael Passos,rafael@rcpassos.me,1713379754,Daniel Borkmann,daniel@iogearbox.net,1713800888,6eb07d5ab07cd7d48c1069be16c56fd7301af821,e1a7545981e2086feaa40dcb7b0db8de0bdada19,"bpf: Fix typos in comments + +Found the following typos in comments"," and fixed them: + +s/unpriviledged/unprivileged/ +s/reponsible/responsible/ +s/possiblities/possibilities/ +s/Divison/Division/ +s/precsion/precision/ +s/havea/have a/ +s/reponsible/responsible/ +s/responsibile/responsible/ +s/tigher/tighter/ +s/respecitve/respective/ + +Signed-off-by: Rafael Passos +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/6af7deb4-bb24-49e8-b3f1-8dd410597337@smtp-relay.sendinblue.com +",[''],Fixed multiple typos in comments in the bpf subsystem code.,"typos, comments, bpf",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +c6f48506ba30c722dd9d89aa6a40eb1926277dff,c6f48506ba30c722dd9d89aa6a40eb1926277dff,Puranjay Mohan,puranjay@kernel.org,1713551312,Daniel Borkmann,daniel@iogearbox.net,1713799565,558174f3f15cb2a30d7468aba6518a62912ed39c,10541b374aa05c8118cc6a529a615882e53f261b,arm32," bpf: Reimplement sign-extension mov instruction + +The current implementation of the mov instruction with sign extension has the +following problems: + + 1. It clobbers the source register if it is not stacked because it + sign extends the source and then moves it to the destination. + 2. If the dst_reg is stacked","["" the current code doesn't write the value\n back in case of 64-bit mov.\n 3. There is room for improvement by emitting fewer instructions.\n\nThe steps for fixing this and the instructions emitted by the JIT are explained\nbelow with examples in all combinations:\n\nCase A: offset == 32:\n=====================\n\n Case A.1: src and dst are stacked registers:\n --------------------------------------------\n 1. Load src_lo into tmp_lo\n 2. Store tmp_lo into dst_lo\n 3. Sign extend tmp_lo into tmp_hi\n 4. Store tmp_hi to dst_hi\n\n Example: r3 = (s32)r3\n\tr3 is a stacked register\n\n\tldr r6"", ' [r11', ' #-16]\t// Load r3_lo into tmp_lo\n\t// str to dst_lo is not emitted because src_lo == dst_lo\n\tasr r7', ' r6', ' #31\t// Sign extend tmp_lo into tmp_hi\n\tstr r7', ' [r11', ' #-12] // Store tmp_hi into r3_hi\n\n Case A.2: src is stacked but dst is not:\n ----------------------------------------\n 1. Load src_lo into dst_lo\n 2. Sign extend dst_lo into dst_hi\n\n Example: r6 = (s32)r3\n\tr6 maps to {ARM_R5', ' ARM_R4} and r3 is stacked\n\n\tldr r4', ' [r11', ' #-16] // Load r3_lo into r6_lo\n\tasr r5', ' r4', ' #31\t// Sign extend r6_lo into r6_hi\n\n Case A.3: src is not stacked but dst is stacked:\n ------------------------------------------------\n 1. Store src_lo into dst_lo\n 2. Sign extend src_lo into tmp_hi\n 3. Store tmp_hi to dst_hi\n\n Example: r3 = (s32)r6\n\tr3 is stacked and r6 maps to {ARM_R5', ' ARM_R4}\n\n\tstr r4', ' [r11', ' #-16] // Store r6_lo to r3_lo\n\tasr r7', ' r4', ' #31\t// Sign extend r6_lo into tmp_hi\n\tstr r7', ' [r11', ' #-12]\t// Store tmp_hi to dest_hi\n\n Case A.4: Both src and dst are not stacked:\n -------------------------------------------\n 1. Mov src_lo into dst_lo\n 2. Sign extend src_lo into dst_hi\n\n Example: (bf) r6 = (s32)r6\n\tr6 maps to {ARM_R5', ' ARM_R4}\n\n\t// Mov not emitted because dst == src\n\tasr r5', ' r4', ' #31 // Sign extend r6_lo into r6_hi\n\nCase B: offset != 32:\n=====================\n\n Case B.1: src and dst are stacked registers:\n --------------------------------------------\n 1. Load src_lo into tmp_lo\n 2. Sign extend tmp_lo according to offset.\n 3. Store tmp_lo into dst_lo\n 4. Sign extend tmp_lo into tmp_hi\n 5. Store tmp_hi to dst_hi\n\n Example: r9 = (s8)r3\n\tr9 and r3 are both stacked registers\n\n\tldr r6', ' [r11', ' #-16] // Load r3_lo into tmp_lo\n\tlsl r6', ' r6', ' #24\t// Sign extend tmp_lo\n\tasr r6', ' r6', ' #24\t// ..\n\tstr r6', ' [r11', ' #-56] // Store tmp_lo to r9_lo\n\tasr r7', ' r6', ' #31\t// Sign extend tmp_lo to tmp_hi\n\tstr r7', ' [r11', ' #-52] // Store tmp_hi to r9_hi\n\n Case B.2: src is stacked but dst is not:\n ----------------------------------------\n 1. Load src_lo into dst_lo\n 2. Sign extend dst_lo according to offset.\n 3. Sign extend tmp_lo into dst_hi\n\n Example: r6 = (s8)r3\n\tr6 maps to {ARM_R5', ' ARM_R4} and r3 is stacked\n\n\tldr r4', ' [r11', ' #-16] // Load r3_lo to r6_lo\n\tlsl r4', ' r4', ' #24\t// Sign extend r6_lo\n\tasr r4', ' r4', ' #24\t// ..\n\tasr r5', ' r4', ' #31\t// Sign extend r6_lo into r6_hi\n\n Case B.3: src is not stacked but dst is stacked:\n ------------------------------------------------\n 1. Sign extend src_lo into tmp_lo according to offset.\n 2. Store tmp_lo into dst_lo.\n 3. Sign extend src_lo into tmp_hi.\n 4. Store tmp_hi to dst_hi.\n\n Example: r3 = (s8)r1\n\tr3 is stacked and r1 maps to {ARM_R3', ' ARM_R2}\n\n\tlsl r6', ' r2', ' #24 \t// Sign extend r1_lo to tmp_lo\n\tasr r6', ' r6', ' #24\t// ..\n\tstr r6', ' [r11', ' #-16] // Store tmp_lo to r3_lo\n\tasr r7', ' r6', ' #31\t// Sign extend tmp_lo to tmp_hi\n\tstr r7', ' [r11', ' #-12] // Store tmp_hi to r3_hi\n\n Case B.4: Both src and dst are not stacked:\n -------------------------------------------\n 1. Sign extend src_lo into dst_lo according to offset.\n 2. Sign extend dst_lo into dst_hi.\n\n Example: r6 = (s8)r1\n\tr6 maps to {ARM_R5', ' ARM_R4} and r1 maps to {ARM_R3', ' ARM_R2}\n\n\tlsl r4', ' r2', ' #24\t// Sign extend r1_lo to r6_lo\n\tasr r4', ' r4', ' #24\t// ..\n\tasr r5', ' r4', ' #31\t// Sign extend r6_lo to r6_hi\n\nFixes: fc832653fa0d (""arm32', ' bpf: add support for sign-extension mov instruction"")\nReported-by: syzbot+186522670e6722692d86@syzkaller.appspotmail.com\nSigned-off-by: Puranjay Mohan \nSigned-off-by: Daniel Borkmann \nReviewed-by: Russell King (Oracle) \nCloses: https://lore.kernel.org/all/000000000000e9a8d80615163f2a@google.com\nLink: https://lore.kernel.org/bpf/20240419182832.27707-1-puranjay@kernel.org\n', '']",The commit reimplements the ARM32 sign-extension mov instruction to address issues with source register clobbering and stacked destination registers.,"ARM32, sign-extension, mov instruction",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e1a7545981e2086feaa40dcb7b0db8de0bdada19,e1a7545981e2086feaa40dcb7b0db8de0bdada19,Rafael Passos,rafael@rcpassos.me,1713376346,Daniel Borkmann,daniel@iogearbox.net,1713798725,065a30b2159f15e0f760d058ec7c8fb8cc45d921,735f5b8a7ccf383e50d76f7d1c25769eee474812,"bpf: Fix typo in function save_aux_ptr_type + +I found this typo in the save_aux_ptr_type function. +s/allow_trust_missmatch/allow_trust_mismatch/ +I did not find this anywhere else in the codebase. + +Signed-off-by: Rafael Passos +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/fbe1d636-8172-4698-9a5a-5a3444b55322@smtp-relay.sendinblue.com +",,Fixes a typo in the save_aux_ptr_type function's variable name.,"typo, save_aux_ptr_type, fix",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +735f5b8a7ccf383e50d76f7d1c25769eee474812,735f5b8a7ccf383e50d76f7d1c25769eee474812,Dave Thaler,dthaler1968@googlemail.com,1713562706,Alexei Starovoitov,ast@kernel.org,1713719352,2a11d1cffa7203004e9cb150f26aa0eab671b847,db50040d09cc511889b2c949a0c93d017e44f081,bpf," docs: Fix formatting nit in instruction-set.rst + +Other places that had pseudocode were prefixed with :: +so as to appear in a literal block","[' but one place was inconsistent.\nThis patch fixes that inconsistency.\n\nSigned-off-by: Dave Thaler \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240419213826.7301-1-dthaler1968@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit fixes formatting in the instruction-set documentation by using pseudocode blocks.,"formatting, pseudocode, documentation",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +db50040d09cc511889b2c949a0c93d017e44f081,db50040d09cc511889b2c949a0c93d017e44f081,Dave Thaler,dthaler1968@googlemail.com,1713558977,Alexei Starovoitov,ast@kernel.org,1713719336,dac684be17e5cff7f0713a1b524859fd2321ff15,2ea0aa535818622395fb55e01086ef2a490fc734,bpf," docs: Clarify helper ID and pointer terms in instruction-set.rst + +Per IETF 119 meeting discussion and mailing list discussion at +https://mailarchive.ietf.org/arch/msg/bpf/2JwWQwFdOeMGv0VTbD0CKWwAOEA/ +the following changes are made. + +First","[' say call by ""static ID"" rather than call by ""address""\n\nSecond', ' change ""pointer"" to ""address""\n\nSigned-off-by: Dave Thaler \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240419203617.6850-1-dthaler1968@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Clarifies helper ID and pointer terms in bpf instruction-set documentation based on IETF and mailing list discussions.,"documentation,helper ID,pointer",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +63a51820d29bdfcf52abed2db2d32b4f6843988e,63a51820d29bdfcf52abed2db2d32b4f6843988e,Geliang Tang,tanggeliang@kylinos.cn,1713427752,Martin KaFai Lau,martin.lau@kernel.org,1713572009,88100b5ba9343cdf4f30d3b7f2ce7bfe27a71569,805b4d90c0df79a88907623b2528954a0125313d,"selftests/bpf: Use connect_to_addr in sk_assign + +This patch uses public helper connect_to_addr() exported in +network_helpers.h instead of the local defined function connect_to_server() +in prog_tests/sk_assign.c. This can avoid duplicate code. + +The code that sets SO_SNDTIMEO timeout as timeo_sec (3s) can be dropped"," +since connect_to_addr() sets default timeout as 3s. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/98fdd384872bda10b2adb052e900a2212c9047b9.1713427236.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",[''],Refactor sk_assign test by replacing connect_to_server with connect_to_addr to reduce code duplication.,"connect_to_addr, sk_assign, refactor",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +805b4d90c0df79a88907623b2528954a0125313d,805b4d90c0df79a88907623b2528954a0125313d,Geliang Tang,tanggeliang@kylinos.cn,1713427751,Martin KaFai Lau,martin.lau@kernel.org,1713572009,61e8c8309491a7579791b04e71f5d830afe6b62d,db9994d022ecd42006354609f6e4e3f57e5a4b03,"selftests/bpf: Use connect_to_addr in cls_redirect + +This patch uses public helper connect_to_addr() exported in +network_helpers.h instead of the local defined function connect_to_server() +in prog_tests/cls_redirect.c. This can avoid duplicate code. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/4a03ac92d2d392f8721f398fa449a83ac75577bc.1713427236.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",,Refactor cls_redirect test to use connect_to_addr helper to avoid code duplication.,"selftests,bpf,refactor",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +db9994d022ecd42006354609f6e4e3f57e5a4b03,db9994d022ecd42006354609f6e4e3f57e5a4b03,Geliang Tang,tanggeliang@kylinos.cn,1713427750,Martin KaFai Lau,martin.lau@kernel.org,1713572008,9211f503d5d85c9add809589018f514f7e71b6f4,a2e4979536c440838794ee292955ce9ed55ad181,"selftests/bpf: Update arguments of connect_to_addr + +Move the third argument ""int type"" of connect_to_addr() to the first one +which is closer to how the socket syscall is doing it. And add a +network_helper_opts argument as the fourth one. Then change its usages in +sock_addr.c too. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/088ea8a95055f93409c5f57d12f0e58d43059ac4.1713427236.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",,Reorder and update arguments of connect_to_addr in selftests/bpf to match socket syscall style.,"connect_to_addr, arguments, selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +a2e4979536c440838794ee292955ce9ed55ad181,a2e4979536c440838794ee292955ce9ed55ad181,Geliang Tang,tanggeliang@kylinos.cn,1713427749,Martin KaFai Lau,martin.lau@kernel.org,1713572008,659e784263c0ca1f18aa6dc368796c50dc6e3c9a,9851382fb3697efb2f4234d70596bd845b3af535,"selftests/bpf: Use start_server_addr in sk_assign + +Include network_helpers.h in prog_tests/sk_assign.c"," use the newly +added public helper start_server_addr() instead of the local defined +function start_server(). This can avoid duplicate code. + +The code that sets SO_RCVTIMEO timeout as timeo_sec (3s) can be dropped","['\nsince start_server_addr() sets default timeout as 3s.\n\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/2af706ffbad63b4f7eaf93a426ed1076eadf1a05.1713427236.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Refactored sk_assign.c to use public helper start_server_addr and removed duplicate timeout setting.,"refactor, sk_assign, network_helpers",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +9851382fb3697efb2f4234d70596bd845b3af535,9851382fb3697efb2f4234d70596bd845b3af535,Geliang Tang,tanggeliang@kylinos.cn,1713427748,Martin KaFai Lau,martin.lau@kernel.org,1713572008,f346ded6df39911c629138f9932a593792b29b01,9c598a83b7eab7b05002911fd25b0be7b996ce6d,"selftests/bpf: Use start_server_addr in cls_redirect + +Include network_helpers.h in prog_tests/cls_redirect.c"," use the newly +added public helper start_server_addr() instead of the local defined +function start_server(). This can avoid duplicate code. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/13f336cb4c6680175d50bb963d9532e11528c758.1713427236.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",[''],Refactor selftests to use start_server_addr in cls_redirect for code reuse.,"start_server_addr,code reuse,selftests",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tc/netfilter like programs'] +9c598a83b7eab7b05002911fd25b0be7b996ce6d,9c598a83b7eab7b05002911fd25b0be7b996ce6d,Geliang Tang,tanggeliang@kylinos.cn,1713427747,Martin KaFai Lau,martin.lau@kernel.org,1713572008,d58378eebf479dc42be5fb1b1fa700f98d32f90f,462e5e2a5938d0241ad146d21dd0da1be8e7eaf0,"selftests/bpf: Add start_server_addr helper + +In order to pair up with connect_to_addr()"," this patch adds a new helper +start_server_addr()","["" which is a wrapper of __start_server(). It accepts\nan argument 'addr' of 'struct sockaddr_storage' type instead of a string\ntype argument like start_server()"", ' and a network_helper_opts argument as\nthe last one.\n\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/2f01d48fa026467926738debe554ac452c19b86f.1713427236.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Added a new helper function 'start_server_addr' to bpf selftests for pairing with 'connect_to_addr'.,"helper,selftests,bpf",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +50449ca66cc5a8cbc64749cf4b9f3d3fc5f4b457,50449ca66cc5a8cbc64749cf4b9f3d3fc5f4b457,Yaxiong Tian,tianyaxiong@kylinos.cn,1713322368,Catalin Marinas,catalin.marinas@arm.com,1713540780,775c8217a6a739148ab6be7da99de09b657e961f,34e526cb7d46726b2ae5f83f2892d00ebb088509,"arm64: hibernate: Fix level3 translation fault in swsusp_save() + +On arm64 machines"," swsusp_save() faults if it attempts to access +MEMBLOCK_NOMAP memory ranges. This can be reproduced in QEMU using UEFI +when booting with rodata=off debug_pagealloc=off and CONFIG_KFENCE=n: + + Unable to handle kernel paging request at virtual address ffffff8000000000 + Mem abort info: + ESR = 0x0000000096000007 + EC = 0x25: DABT (current EL)","[' IL = 32 bits\n SET = 0', ' FnV = 0\n EA = 0', ' S1PTW = 0\n FSC = 0x07: level 3 translation fault\n Data abort info:\n ISV = 0', ' ISS = 0x00000007', ' ISS2 = 0x00000000\n CM = 0', ' WnR = 0', ' TnD = 0', ' TagAccess = 0\n GCS = 0', ' Overlay = 0', ' DirtyBit = 0', ' Xs = 0\n swapper pgtable: 4k pages', ' 39-bit VAs', ' pgdp=00000000eeb0b000\n [ffffff8000000000] pgd=180000217fff9803', ' p4d=180000217fff9803', ' pud=180000217fff9803', ' pmd=180000217fff8803', ' pte=0000000000000000\n Internal error: Oops: 0000000096000007 [#1] SMP\n Internal error: Oops: 0000000096000007 [#1] SMP\n Modules linked in: xt_multiport ipt_REJECT nf_reject_ipv4 xt_conntrack nf_conntrack nf_defrag_ipv6 nf_defrag_ipv4 libcrc32c iptable_filter bpfilter rfkill at803x snd_hda_codec_hdmi snd_hda_intel snd_intel_dspcfg dwmac_generic stmmac_platform snd_hda_codec stmmac joydev pcs_xpcs snd_hda_core phylink ppdev lp parport ramoops reed_solomon ip_tables x_tables nls_iso8859_1 vfat multipath linear amdgpu amdxcp drm_exec gpu_sched drm_buddy hid_generic usbhid hid radeon video drm_suballoc_helper drm_ttm_helper ttm i2c_algo_bit drm_display_helper cec drm_kms_helper drm\n CPU: 0 PID: 3663 Comm: systemd-sleep Not tainted 6.6.2+ #76\n Source Version: 4e22ed63a0a48e7a7cff9b98b7806d8d4add7dc0\n Hardware name: Greatwall GW-XXXXXX-XXX/GW-XXXXXX-XXX', ' BIOS KunLun BIOS V4.0 01/19/2021\n pstate: 600003c5 (nZCv DAIF -PAN -UAO -TCO -DIT -SSBS BTYPE=--)\n pc : swsusp_save+0x280/0x538\n lr : swsusp_save+0x280/0x538\n sp : ffffffa034a3fa40\n x29: ffffffa034a3fa40 x28: ffffff8000001000 x27: 0000000000000000\n x26: ffffff8001400000 x25: ffffffc08113e248 x24: 0000000000000000\n x23: 0000000000080000 x22: ffffffc08113e280 x21: 00000000000c69f2\n x20: ffffff8000000000 x19: ffffffc081ae2500 x18: 0000000000000000\n x17: 6666662074736420 x16: 3030303030303030 x15: 3038666666666666\n x14: 0000000000000b69 x13: ffffff9f89088530 x12: 00000000ffffffea\n x11: 00000000ffff7fff x10: 00000000ffff7fff x9 : ffffffc08193f0d0\n x8 : 00000000000bffe8 x7 : c0000000ffff7fff x6 : 0000000000000001\n x5 : ffffffa0fff09dc8 x4 : 0000000000000000 x3 : 0000000000000027\n x2 : 0000000000000000 x1 : 0000000000000000 x0 : 000000000000004e\n Call trace:\n swsusp_save+0x280/0x538\n swsusp_arch_suspend+0x148/0x190\n hibernation_snapshot+0x240/0x39c\n hibernate+0xc4/0x378\n state_store+0xf0/0x10c\n kobj_attr_store+0x14/0x24\n\nThe reason is swsusp_save() -> copy_data_pages() -> page_is_saveable()\n-> kernel_page_present() assuming that a page is always present when\ncan_set_direct_map() is false (all of rodata_full', '\ndebug_pagealloc_enabled() and arm64_kfence_can_set_direct_map() false)', '\nirrespective of the MEMBLOCK_NOMAP ranges. Such MEMBLOCK_NOMAP regions\nshould not be saved during hibernation.\n\nThis problem was introduced by changes to the pfn_valid() logic in\ncommit a7d9f306ba70 (""arm64: drop pfn_valid_within() and simplify\npfn_valid()"").\n\nSimilar to other architectures', ' drop the !can_set_direct_map() check in\nkernel_page_present() so that page_is_savable() skips such pages.\n\nFixes: a7d9f306ba70 (""arm64: drop pfn_valid_within() and simplify pfn_valid()"")\nCc: # 5.14.x\nSuggested-by: Mike Rapoport \nSuggested-by: Catalin Marinas \nCo-developed-by: xiongxin \nSigned-off-by: xiongxin \nSigned-off-by: Yaxiong Tian \nAcked-by: Mike Rapoport (IBM) \nLink: https://lore.kernel.org/r/20240417025248.386622-1-tianyaxiong@kylinos.cn\n[catalin.marinas@arm.com: rework commit message]\nSigned-off-by: Catalin Marinas \n', '']",Fix the translation fault in swsusp_save() for arm64 during hibernation.,"arm64, hibernate, translation",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +61ba075d9911d2a6db181fbb5602762a24d5d0a9,61ba075d9911d2a6db181fbb5602762a24d5d0a9,Arnaldo Carvalho de Melo,acme@redhat.com,1713474933,Arnaldo Carvalho de Melo,acme@redhat.com,1713489772,9e6930409badd1af421c60ad9cf3b8558710d61b,c15ed4442981ccf8e7e0d885f5cb500400dde9d7,"Revert ""tools headers: Remove almost unused copy of uapi/stat.h"," add few conditional defines"" + +This reverts commit a672af9139a843eb7a48fd7846bb6df8f81b5f86. + +By now it is not used for building tools/perf","[' but Stephen Rothwell\nreported that when building on a O= directory that had been built with\ntorvalds/master and this perf build command line:\n\n $ make -C tools/perf -f Makefile.perf -s -O -j60 O=/home/sfr/next/perf NO_BPF_SKEL=1\n\nIf we then merge perf-tools-next', ' as he did for linux-next', "" then we end\nup with a build failure for libbpf:\n\n PERF_VERSION = 6.9.rc3.g42c4635c8dee\n make[3]: *** No rule to make target '/home/sfr/next/next/tools/include/uapi/linux/stat.h'"", "" needed by '/home/sfr/next/perf/libbpf/staticobjs/libbpf.o'. Stop.\n make[2]: *** [Makefile:157: /home/sfr/next/perf/libbpf/staticobjs/libbpf-in.o] Error 2\n make[1]: *** [Makefile.perf:892: /home/sfr/next/perf/libbpf/libbpf.a] Error 2\n make[1]: *** Waiting for unfinished jobs....\n make: *** [Makefile.perf:264: sub-make] Error 2\n\nThis needs to be further investigated to figure out how to check if\nlibbpf really needs something that is in that\ntools/include/uapi/linux/stat.h file and if not to remove that file in a\nway that we don't break the build in any situation"", "" to avoid requiring\ndoing a 'make clean'.\n\nReported-by: Stephen Rothwell \nTested-by: Stephen Rothwell # PowerPC le incermental build\nCc: Namhyung Kim \nLink: https://lore.kernel.org/lkml/20240413124340.4d48c6d8@canb.auug.org.au\nSigned-off-by: Arnaldo Carvalho de Melo \n"", '']",This commit reverts a previous removal of a uapi/stat.h copy for building perf tools.,"revert, uapi/stat, tools",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +d9bd1d4264baddf7ab8baae86e91674d369f22de,d9bd1d4264baddf7ab8baae86e91674d369f22de,Ian Rogers,irogers@google.com,1713286814,Arnaldo Carvalho de Melo,acme@redhat.com,1713489771,55fac730e789a0ed1ede7a56eceea43442a8f388,eb4d27cf9aef3e6c9bcaf8fa1a1cadc2433d847b,"perf test bpf-counters: Add test for BPF event modifier + +Refactor test to better enable sharing of logic"," to give an idea of +progress and introduce test functions. Add test of measuring both +cycles and cycles:b simultaneously. + +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Athira Rajeev +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: Kan Liang +Cc: Mark Rutland +Cc: Namhyung Kim +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Song Liu +Cc: Thomas Richter +Link: https://lore.kernel.org/r/20240416170014.985191-2-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",[''],The commit refactors perf test to add BPF event modifier and improve test logic sharing.,"perf test, BPF event, refactor",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +eb4d27cf9aef3e6c9bcaf8fa1a1cadc2433d847b,eb4d27cf9aef3e6c9bcaf8fa1a1cadc2433d847b,Ian Rogers,irogers@google.com,1713286813,Arnaldo Carvalho de Melo,acme@redhat.com,1713489771,0cf341b78e2e5b0a37185d89649e8fe4a74fb11e,6b718ac6874c2233b8dec369a8a377d6c5b638e6,"perf docs: Document bpf event modifier + +Document that 'b' is used as a modifier to make an event use a BPF +counter. + +Fixes: 01bd8efcec444468 (""perf stat: Introduce ':b' modifier"") +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Athira Rajeev +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: Kan Liang +Cc: Mark Rutland +Cc: Namhyung Kim +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Song Liu +Cc: Thomas Richter +Link: https://lore.kernel.org/r/20240416170014.985191-1-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",,Document the 'b' modifier used in perf events for BPF counters.,"perf, BPF, event",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +462e5e2a5938d0241ad146d21dd0da1be8e7eaf0,462e5e2a5938d0241ad146d21dd0da1be8e7eaf0,Alexei Starovoitov,ast@kernel.org,1713390246,Andrii Nakryiko,andrii@kernel.org,1713456201,1c446c24e177d405d9aa60cb2c16c7ff271593e1,e739e01d8df8bf26dbc9dcaeaee3c8c55e8ffa71,"bpf: Fix JIT of is_mov_percpu_addr instruction. + +The codegen for is_mov_percpu_addr instruction works for rax/r8 registers +only. Fix it to generate proper x86 byte code for other registers. + +Fixes: 7bdbf7446305 (""bpf: add special internal-only MOV instruction to resolve per-CPU addrs"") +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240417214406.15788-1-alexei.starovoitov@gmail.com +",,Fix JIT to properly handle is_mov_percpu_addr instruction for x86 registers other than rax/r8.,"JIT, x86, percpu",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6fc6d7f59376c7cda4d866159b29fe96d96afe83,6fc6d7f59376c7cda4d866159b29fe96d96afe83,Jakub Kicinski,kuba@kernel.org,1712862334,Jakub Kicinski,kuba@kernel.org,1713403119,0f35dacc415ed7d9db743de4fee431c62adb7e6f,2bd99aef1b19e6da09eff692bc0a09d61d785782,"selftests: adopt BPF's approach to quieter builds + +selftest build is fairly noisy"," it's easy to miss warnings. +It's standard practice to add alternative messages in +the Makefile. I was grepping for existing solutions","['\nand found that bpf already has the right knobs.\n\nMove them to lib.mk and adopt in net.\nConvert the basic rules in lib.mk.\n\nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/r/20240411190534.444918-1-kuba@kernel.org\nSigned-off-by: Jakub Kicinski \n', '']",The commit reduces noise in selftest builds by adopting BPF's approach to quieter build outputs.,"selftests, quieter builds, Makefile",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +e739e01d8df8bf26dbc9dcaeaee3c8c55e8ffa71,e739e01d8df8bf26dbc9dcaeaee3c8c55e8ffa71,Quentin Deslandes,qde@naccy.de,1713042778,Daniel Borkmann,daniel@iogearbox.net,1713360242,08e655908b0931d387a2e3f9db063e6b32ae5da4,9213e52970a5997c9eb176c7afcc6ec67b1b1e6f,"libbpf: Fix dump of subsequent char arrays + +When dumping a character array"," libbpf will watch for a '\0' and set +is_array_terminated=true if found. This prevents libbpf from printing +the remaining characters of the array","[' treating it as a nul-terminated\nstring.\n\nHowever', ' once this flag is set', "" it's never reset"", "" leading to subsequent\ncharacters array not being printed properly:\n\n.str_multi = (__u8[2][16])[\n [\n 'H'"", ""\n 'e'"", ""\n 'l'"", '\n ]', '\n]', '\n\nThis patch saves the is_array_terminated flag and restores its\ndefault (false) value before looping over the elements of an array', '\nthen restores it afterward. This way', "" libbpf's behavior is unchanged\nwhen dumping the characters of an array"", "" but subsequent arrays are\nprinted properly:\n\n.str_multi = (__u8[2][16])[\n [\n 'H'"", ""\n 'e'"", ""\n 'l'"", '\n ]', ""\n [\n 'l'"", ""\n 'o'"", '\n ]', '\n]', '\n\nSigned-off-by: Quentin Deslandes \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240413211258.134421-3-qde@naccy.de\n', '']",Fixes libbpf to correctly handle termination of character arrays when dumping.,"libbpf, character, arrays",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9213e52970a5997c9eb176c7afcc6ec67b1b1e6f,9213e52970a5997c9eb176c7afcc6ec67b1b1e6f,Quentin Deslandes,qde@naccy.de,1713042777,Daniel Borkmann,daniel@iogearbox.net,1713360224,5df119d0d36dee376c9b85bc0791b43fc44bc3db,ad2d22b617b7c0ca2cff4da6dc063183822484bb,"libbpf: Fix misaligned array closing bracket + +In btf_dump_array_data()"," libbpf will call btf_dump_dump_type_data() for +each element. For an array of characters","[' each element will be\nprocessed the following way:\n\n- btf_dump_dump_type_data() is called to print the character\n- btf_dump_data_pfx() prefixes the current line with the proper number\n of indentations\n- btf_dump_int_data() is called to print the character\n- After the last character is printed', ' btf_dump_dump_type_data() calls\n btf_dump_data_pfx() before writing the closing bracket\n\nHowever', ' for an array containing characters', "" btf_dump_int_data() won't\nprint any '\\0' and subsequent characters. This leads to situations where\nthe line prefix is written"", ' no character is added', "" then the prefix is\nwritten again before adding the closing bracket:\n\n(struct sk_metadata){\n .str_array = (__u8[14])[\n 'H'"", ""\n 'e'"", ""\n 'l'"", ""\n 'l'"", ""\n 'o'"", '\n ]', ""\n\nThis change solves this issue by printing the '\\0' character"", "" which\nhas two benefits:\n\n- The bracket closing the array is properly aligned\n- It's clear from a user point of view that libbpf uses '\\0' as a\n terminator for arrays of characters.\n\nSigned-off-by: Quentin Deslandes \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240413211258.134421-2-qde@naccy.de\n"", '']",Fixes misaligned array closing bracket in libbpf's btf_dump_array_data function.,"libbpf, array, fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"[""It's not related to any of the above.""]" +fc29e04ae1ad4c99422c0b8ae4b43cfe99c70429,fc29e04ae1ad4c99422c0b8ae4b43cfe99c70429,Jesper Dangaard Brouer,hawk@kernel.org,1713289886,Tejun Heo,tj@kernel.org,1713305442,0e253e08ac5881d265f82bf64faa2c8c5c1b558e,15b8b9ab5081d8dce9aa27a594ba4db2c29cefc0,"cgroup/rstat: add cgroup_rstat_lock helpers and tracepoints + +This commit enhances the ability to troubleshoot the global +cgroup_rstat_lock by introducing wrapper helper functions for the lock +along with associated tracepoints. + +Although global"," the cgroup_rstat_lock helper APIs and tracepoints take +arguments such as cgroup pointer and cpu_in_loop variable. This +adjustment is made because flushing occurs per cgroup despite the lock +being global. Hence","[' when troubleshooting', "" it's important to identify the\nrelevant cgroup. The cpu_in_loop variable is necessary because the global\nlock may be released within the main flushing loop that traverses CPUs.\nIn the tracepoints"", ' the cpu_in_loop value is set to -1 when acquiring the\nmain lock; otherwise', ' it denotes the CPU number processed last.\n\nThe new feature in this patchset is detecting when lock is contended. The\ntracepoints are implemented with production in mind. For minimum overhead\nattach to cgroup:cgroup_rstat_lock_contended', ' which only gets activated\nwhen trylock detects lock is contended. A quick production check for\nissues could be done via this perf commands:\n\n perf record -g -e cgroup:cgroup_rstat_lock_contended\n\nNext natural question would be asking how long time do lock contenders\nwait for obtaining the lock. This can be answered by measuring the time\nbetween cgroup:cgroup_rstat_lock_contended and cgroup:cgroup_rstat_locked\nwhen args->contended is set. Like this bpftrace script:\n\n bpftrace -e \'\n tracepoint:cgroup:cgroup_rstat_lock_contended {@start[tid]=nsecs}\n tracepoint:cgroup:cgroup_rstat_locked {\n if (args->contended) {\n @wait_ns=hist(nsecs-@start[tid]); delete(@start[tid]);}}\n interval:s:1 {time(""%H:%M:%S ""); print(@wait_ns); }\'\n\nExtending with time spend holding the lock will be more expensive as this\nalso looks at all the non-contended cases.\nLike this bpftrace script:\n\n bpftrace -e \'\n tracepoint:cgroup:cgroup_rstat_lock_contended {@start[tid]=nsecs}\n tracepoint:cgroup:cgroup_rstat_locked { @locked[tid]=nsecs;\n if (args->contended) {\n @wait_ns=hist(nsecs-@start[tid]); delete(@start[tid]);}}\n tracepoint:cgroup:cgroup_rstat_unlock {\n @locked_ns=hist(nsecs-@locked[tid]); delete(@locked[tid]);}\n interval:s:1 {time(""%H:%M:%S ""); print(@wait_ns);print(@locked_ns); }\'\n\nSigned-off-by: Jesper Dangaard Brouer \nSigned-off-by: Tejun Heo \n', '']",The commit adds helper functions and tracepoints for better management and troubleshooting of cgroup_rstat_lock.,"cgroup,rstat,tracepoints",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['cgroup like programs'] +ad2d22b617b7c0ca2cff4da6dc063183822484bb,ad2d22b617b7c0ca2cff4da6dc063183822484bb,Quentin Monnet,qmo@kernel.org,1712970867,Daniel Borkmann,daniel@iogearbox.net,1713283105,84c66b43645315de17e0cde4ef7ac3bf93ad92e6,986e7663f98ec7441d9d948263ec0dda71e7479f,"bpftool: Address minor issues in bash completion + +This commit contains a series of clean-ups and fixes for bpftool's bash +completion file: + +- Make sure all local variables are declared as such. +- Make sure variables are initialised before being read. +- Update ELF section (""maps"" -> "".maps"") for looking up map names in + object files. +- Fix call to _init_completion. +- Move definition for MAP_TYPE and PROG_TYPE higher up in the scope to + avoid defining them multiple times"," reuse MAP_TYPE where relevant. +- Simplify completion for ""duration"" keyword in ""bpftool prog profile"". +- Fix completion for ""bpftool struct_ops register"" and ""bpftool link + (pin|detach)"" where we would repeatedly suggest file names instead of + suggesting just one name. +- Fix completion for ""bpftool iter pin ... map MAP"" to account for the + ""map"" keyword. +- Add missing ""detach"" suggestion for ""bpftool link"". + +Signed-off-by: Quentin Monnet +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240413011427.14402-3-qmo@kernel.org +",[''],"The commit fixes and refines bash completion in bpftool by addressing variable declarations, initialization, and improving command completion suggestions.","bash completion, bpftool, fixes",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +986e7663f98ec7441d9d948263ec0dda71e7479f,986e7663f98ec7441d9d948263ec0dda71e7479f,Quentin Monnet,qmo@kernel.org,1712970866,Daniel Borkmann,daniel@iogearbox.net,1713283105,cd7b8920e9940a6a8daec85ed3a3b050a63641af,1f586614f3ffa80fdf2116b2a1bebcdb5969cef8,"bpftool: Update documentation where progs/maps can be passed by name + +When using references to BPF programs"," bpftool supports passing programs +by name on the command line. The manual pages for ""bpftool prog"" and +""bpftool map"" (for prog_array updates) mention it","[' but we have a few\nadditional subcommands that support referencing programs by name but do\nnot mention it in their documentation. Let\'s update the pages for\nsubcommands ""btf""', ' ""cgroup""', ' and ""net"".\n\nSimilarly', ' we can reference maps by name when passing them to ""bpftool\nprog load""', ' so we update the page for ""bpftool prog"" as well.\n\nSigned-off-by: Quentin Monnet \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240413011427.14402-2-qmo@kernel.org\n', '']",Update bpftool documentation to include support for passing programs and maps by name on the command line.,"bpftool, documentation, command-line",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1f586614f3ffa80fdf2116b2a1bebcdb5969cef8,1f586614f3ffa80fdf2116b2a1bebcdb5969cef8,Harishankar Vishwanathan,harishankar.vishwanathan@gmail.com,1713268382,Daniel Borkmann,daniel@iogearbox.net,1713282927,7b5f4fa20fcbbdf316f4832c33d79dc8d4e8723d,dac045fc9fa653e250f991ea8350b32cfec690d2,"bpf: Harden and/or/xor value tracking in verifier + +This patch addresses a latent unsoundness issue in the +scalar(32)_min_max_and/or/xor functions. While it is not a bugfix"," +it ensures that the functions produce sound outputs for all inputs. + +The issue occurs in these functions when setting signed bounds. The +following example illustrates the issue for scalar_min_max_and()","['\nbut it applies to the other functions.\n\nIn scalar_min_max_and() the following clause is executed when ANDing\npositive numbers:\n\n /* ANDing two positives gives a positive', ' so safe to\n * cast result into s64.\n */\n dst_reg->smin_value = dst_reg->umin_value;\n dst_reg->smax_value = dst_reg->umax_value;\n\nHowever', ' if umin_value and umax_value of dst_reg cross the sign boundary\n(i.e.', ' if (s64)dst_reg->umin_value > (s64)dst_reg->umax_value)', ' then we\nwill end up with smin_value > smax_value', ' which is unsound.\n\nPrevious works [1', ' 2] have discovered and reported this issue. Our tool\nAgni [2', ' 3] consideres it a false positive. This is because', ' during the\nverification of the abstract operator scalar_min_max_and()', ' Agni restricts\nits inputs to those passing through reg_bounds_sync(). This mimics\nreal-world verifier behavior', ' as reg_bounds_sync() is invariably executed\nat the tail of every abstract operator. Therefore', ' such behavior is\nunlikely in an actual verifier execution.\n\nHowever', ' it is still unsound for an abstract operator to set signed bounds\nsuch that smin_value > smax_value. This patch fixes it', ' making the abstract\noperator sound for all (well-formed) inputs.\n\nIt is worth noting that while the previous code updated the signed bounds\n(using the output unsigned bounds) only when the *input signed* bounds\nwere positive', ' the new code updates them whenever the *output unsigned*\nbounds do not cross the sign boundary.\n\nAn alternative approach to fix this latent unsoundness would be to\nunconditionally set the signed bounds to unbounded [S64_MIN', ' S64_MAX]', ' and\nlet reg_bounds_sync() refine the signed bounds using the unsigned bounds\nand the tnum. We found that our approach produces more precise (tighter)\nbounds.\n\nFor example', ' consider these inputs to BPF_AND:\n\n /* dst_reg */\n var_off.value: 8608032320201083347\n var_off.mask: 615339716653692460\n smin_value: 8070450532247928832\n smax_value: 8070450532247928832\n umin_value: 13206380674380886586\n umax_value: 13206380674380886586\n s32_min_value: -2110561598\n s32_max_value: -133438816\n u32_min_value: 4135055354\n u32_max_value: 4135055354\n\n /* src_reg */\n var_off.value: 8584102546103074815\n var_off.mask: 9862641527606476800\n smin_value: 2920655011908158522\n smax_value: 7495731535348625717\n umin_value: 7001104867969363969\n umax_value: 8584102543730304042\n s32_min_value: -2097116671\n s32_max_value: 71704632\n u32_min_value: 1047457619\n u32_max_value: 4268683090\n\nAfter going through tnum_and() -> scalar32_min_max_and() ->\nscalar_min_max_and() -> reg_bounds_sync()', ' our patch produces the following\nbounds for s32:\n\n s32_min_value: -1263875629\n s32_max_value: -159911942\n\nWhereas', ' setting the signed bounds to unbounded in scalar_min_max_and()\nproduces:\n\n s32_min_value: -1263875629\n s32_max_value: -1\n\nAs observed', ' our patch produces a tighter s32 bound. We also confirmed\nusing Agni and SMT verification that our patch always produces signed\nbounds that are equal to or more precise than setting the signed bounds to\nunbounded in scalar_min_max_and().\n\n [1] https://sanjit-bhat.github.io/assets/pdf/ebpf-verifier-range-analysis22.pdf\n [2] https://link.springer.com/chapter/10.1007/978-3-031-37709-9_12\n [3] https://github.com/bpfverif/agni\n\nCo-developed-by: Matan Shachnai \nSigned-off-by: Matan Shachnai \nCo-developed-by: Srinivas Narayana \nSigned-off-by: Srinivas Narayana \nCo-developed-by: Santosh Nagarakatte \nSigned-off-by: Santosh Nagarakatte \nSigned-off-by: Harishankar Vishwanathan \nSigned-off-by: Daniel Borkmann \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240402212039.51815-1-harishankar.vishwanathan@gmail.com\nLink: https://lore.kernel.org/bpf/20240416115303.331688-1-harishankar.vishwanathan@gmail.com\n', '']",This commit hardens the and/or/xor value tracking in the eBPF verifier to address potential unsoundness.,"harden, verifier, tracking",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dac045fc9fa653e250f991ea8350b32cfec690d2,dac045fc9fa653e250f991ea8350b32cfec690d2,Chen Pei,cp0613@linux.alibaba.com,1713169168,Daniel Borkmann,daniel@iogearbox.net,1713280938,5d24b197f04fa291aa420db01770b791079e8a1c,fc5eb4a84e4c063e75a6a6e92308e9533c0f19b5,bpf," tests: Fix typos in comments + +Currently","[' there are two comments with same name ""64-bit ATOMIC magnitudes""', '\nthe second one should be ""32-bit ATOMIC magnitudes"" based on the context.\n\nSigned-off-by: Chen Pei \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240415081928.17440-1-cp0613@linux.alibaba.com\n', '']",Fix typographical errors in test comment documentation for clarity.,"typos,test,comments",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +10541b374aa05c8118cc6a529a615882e53f261b,10541b374aa05c8118cc6a529a615882e53f261b,Xu Kuohai,xukuohai@huawei.com,1713249728,Daniel Borkmann,daniel@iogearbox.net,1713280781,59373141f5538e6004c743c0a6c0493ce6b7ca79,dc7d7447b56bcc9cf79a9c22e4edad200a298e4c,riscv," bpf: Fix incorrect runtime stats + +When __bpf_prog_enter() returns zero","[' the s1 register is not set to zero', '\nresulting in incorrect runtime stats. Fix it by setting s1 immediately upon\nthe return of __bpf_prog_enter().\n\nFixes: 49b5e77ae3e2 (""riscv', ' bpf: Add bpf trampoline support for RV64"")\nSigned-off-by: Xu Kuohai \nSigned-off-by: Daniel Borkmann \nReviewed-by: Pu Lehui \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240416064208.2919073-3-xukuohai@huaweicloud.com\n', '']",Fixed incorrect runtime statistics when __bpf_prog_enter() returns zero for riscv architecture.,"runtime, stats, fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dc7d7447b56bcc9cf79a9c22e4edad200a298e4c,dc7d7447b56bcc9cf79a9c22e4edad200a298e4c,Xu Kuohai,xukuohai@huawei.com,1713249727,Daniel Borkmann,daniel@iogearbox.net,1713280770,584898bf8b410c67966a7586f587c09eeb7d0a5c,37eacb9f6e89fb399a79e952bc9c78eb3e16290e,bpf," arm64: Fix incorrect runtime stats + +When __bpf_prog_enter() returns zero","[' the arm64 register x20 that stores\nprog start time is not assigned to zero', ' causing incorrect runtime stats.\n\nTo fix it', ' assign the return value of bpf_prog_enter() to x20 register\nimmediately upon its return.\n\nFixes: efc9909fdce0 (""bpf', ' arm64: Add bpf trampoline for arm64"")\nReported-by: Ivan Babrou \nSigned-off-by: Xu Kuohai \nSigned-off-by: Daniel Borkmann \nTested-by: Ivan Babrou \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240416064208.2919073-2-xukuohai@huaweicloud.com\n', '']",Fix incorrect runtime statistics on ARM64 when __bpf_prog_enter() returns zero.,"ARM64, fix, runtime",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fc5eb4a84e4c063e75a6a6e92308e9533c0f19b5,fc5eb4a84e4c063e75a6a6e92308e9533c0f19b5,Ard Biesheuvel,ardb@kernel.org,1713198045,Daniel Borkmann,daniel@iogearbox.net,1713278113,a5e08b469477b03deed0c6a87e51ca925c53fc3c,4d4992ff587604455e8843a0e76dce0b99175319,"btf: Avoid weak external references + +If the BTF code is enabled in the build configuration"," the start/stop +BTF markers are guaranteed to exist. Only when CONFIG_DEBUG_INFO_BTF=n","['\nthe references in btf_parse_vmlinux() will remain unsatisfied', ' relying\non the weak linkage of the external references to avoid breaking the\nbuild.\n\nAvoid GOT based relocations to these markers in the final executable by\ndropping the weak attribute and instead', ' make btf_parse_vmlinux() return\nERR_PTR(-ENOENT) directly if CONFIG_DEBUG_INFO_BTF is not enabled to\nbegin with. The compiler will drop any subsequent references to\n__start_BTF and __stop_BTF in that case', ' allowing the link to succeed.\n\nNote that Clang will notice that taking the address of __start_BTF can\nno longer yield NULL', ' so testing for that condition becomes unnecessary.\n\nSigned-off-by: Ard Biesheuvel \nSigned-off-by: Daniel Borkmann \nAcked-by: Andrii Nakryiko \nAcked-by: Arnd Bergmann \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/bpf/20240415162041.2491523-8-ardb+git@google.com\n', '']",The commit modifies BTF code to avoid weak external references when CONFIG_DEBUG_INFO_BTF is not set.,"BTF, weak references, CONFIG_DEBUG_INFO_BTF",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +854dd99b5ddc9d90e31e5f112462a5994dd31810,854dd99b5ddc9d90e31e5f112462a5994dd31810,Ingo Molnar,mingo@kernel.org,1713126807,Ingo Molnar,mingo@kernel.org,1713126926,25cba84a41ae9d6cd5f38e26cc4dc42efe00422f,e224d1c1fb93f258030186b4878abe105c296ac1,"perf/bpf: Mark perf_event_set_bpf_handler() and perf_event_free_bpf_handler() as inline too + +They can be unused with certain Kconfig variations: + + kernel/events/core.c:9622:13: warning: ‘perf_event_free_bpf_handler’ defined but not used [-Wunused-function] + kernel/events/core.c:9586:12: warning: ‘perf_event_set_bpf_handler’ defined but not used [-Wunused-function] + +Since they are both single-use"," mark them inline. + +Signed-off-by: Ingo Molnar +Cc: linux-kernel@vger.kernel.org +Cc: Kyle Huey +",[''],Marking perf_event_set_bpf_handler and perf_event_free_bpf_handler as inline to avoid unused function warnings.,"inline, perf_event, unused",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +459fee7b508231cd4622b3bd94aaa85e8e16b888,459fee7b508231cd4622b3bd94aaa85e8e16b888,Ian Rogers,irogers@google.com,1712376550,Arnaldo Carvalho de Melo,acme@redhat.com,1712955242,12a520c6e1c1a20d144ae24139bb34e04e9dc831,2b8c43e7688fa61b842ea2b21d4159c67d6f2fd1,"perf bench uprobe: Remove lib64 from libc.so.6 binary path + +bpf_program__attach_uprobe_opts will search LD_LIBRARY_PATH and so +specifying `/lib64` is unnecessary and causes failures for libc.so.6 +paths like `/lib/x86_64-linux-gnu/libc.so.6`. + +Fixes: 7b47623b8cae8149 (""perf bench uprobe trace_printk: Add entry attaching an BPF program that does a trace_printk"") +Signed-off-by: Ian Rogers +Acked-by: Jiri Olsa +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Andrei Vagin +Cc: Ingo Molnar +Cc: Kan Liang +Cc: Kees Kook +Cc: Mark Rutland +Cc: Namhyung Kim +Cc: Peter Zijlstra +Link: https://lore.kernel.org/r/20240406040911.1603801-1-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",,Removed unnecessary /lib64 directory from libc.so.6 path to prevent failures in perf bench uprobe.,"libc.so.6, LD_LIBRARY_PATH, uprobe",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +37eacb9f6e89fb399a79e952bc9c78eb3e16290e,37eacb9f6e89fb399a79e952bc9c78eb3e16290e,Anton Protopopov,aspsk@isovalent.com,1712931060,Daniel Borkmann,daniel@iogearbox.net,1712939840,58df1bb3ed11511fa6c3fd8f7f56f9ff13b6e2d9,6648e613226e18897231ab5e42ffc29e63fa3365,"bpf: Fix a verifier verbose message + +Long ago a map file descriptor in a pseudo ldimm64 instruction could +only be present as an immediate value insn[0].imm"," and thus this value +was used in a verbose verifier message printed when the file descriptor +wasn't valid. Since addition of BPF_PSEUDO_MAP_IDX_VALUE/BPF_PSEUDO_MAP_IDX +the insn[0].imm field can also contain an index pointing to the file +descriptor in the attr.fd_array array. However","[' if the file descriptor\nis invalid', ' the verifier still prints the verbose message containing\nvalue of insn[0].imm. Patch the verifier message to always print the\nactual file descriptor value.\n\nFixes: 387544bfa291 (""bpf: Introduce fd_idx"")\nSigned-off-by: Anton Protopopov \nSigned-off-by: Daniel Borkmann \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240412141100.3562942-1-aspsk@isovalent.com\n', '']",Fixes a verbose message issue in the eBPF verifier for map descriptors.,"fix, verifier, message",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4d4992ff587604455e8843a0e76dce0b99175319,4d4992ff587604455e8843a0e76dce0b99175319,Jiri Olsa,jolsa@kernel.org,1712758192,Daniel Borkmann,daniel@iogearbox.net,1712939121,b6bc29b0220753ef4eaa63910d935df69e0373cd,23cc4fe44f1df5ccce088a7c9398f96794047c2a,"selftests/bpf: Add read_trace_pipe_iter function + +We have two printk tests reading trace_pipe in non blocking way"," +with the very same code. Moving that in new read_trace_pipe_iter +function. + +Current read_trace_pipe is used from samples/bpf and needs to +do blocking read and printf of the trace_pipe data","[' using new\nread_trace_pipe_iter to implement that.\n\nBoth printk tests do early checks for the number of found messages\nand can bail earlier', ' but I did not find any speed difference w/o\nthat condition', ' so I did not complicate the change more for that.\n\nSome of the samples/bpf programs use read_trace_pipe function', ""\nso I kept that interface untouched. I did not see any issues with\naffected samples/bpf programs other than there's slight change in\nread_trace_pipe output. The current code uses puts that adds new\nline after the printed string"", ' so we would occasionally see extra\nnew line. With this patch we read output per lines', "" so there's no\nneed to use puts and we can use just printf instead without extra\nnew line.\n\nSigned-off-by: Jiri Olsa \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240410140952.292261-1-jolsa@kernel.org\n"", '']",Refactor selftests/bpf to introduce a new non-blocking read_trace_pipe_iter function.,"read_trace_pipe_iter, selftests, non-blocking",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tracepoints like programs'] +23cc4fe44f1df5ccce088a7c9398f96794047c2a,23cc4fe44f1df5ccce088a7c9398f96794047c2a,Thorsten Blum,thorsten.blum@toblux.com,1712853780,Daniel Borkmann,daniel@iogearbox.net,1712938749,c9b26ebf897f7fc36b75b88405bb5df4a8a2cbd9,c53e853c2d8145859f57c63662030f7aaa61cfdc,"bpftool: Fix typo in error message + +s/at at/at a/ + +Signed-off-by: Thorsten Blum +Signed-off-by: Daniel Borkmann +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/bpf/20240411164258.533063-3-thorsten.blum@toblux.com +",,Fix a typo in the error message within bpftool utility.,"bpftool, typo, error message",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +93d3fde7fd19c2e2cde7220e7986f9a75e9c5680,93d3fde7fd19c2e2cde7220e7986f9a75e9c5680,Ingo Molnar,mingo@kernel.org,1712915700,Ingo Molnar,mingo@kernel.org,1712915760,ca51ab80642af28284795b90cb93235493e752cb,a265c9f6d52ac760e6e572bac73a11b60b998779,"perf/bpf: Change the !CONFIG_BPF_SYSCALL stubs to static inlines + +Otherwise the compiler will be unhappy if they go unused"," +which they do on allnoconfigs. + +Signed-off-by: Ingo Molnar +Cc: Kyle Huey +Link: https://lore.kernel.org/r/ZhkE9F4dyfR2dH2D@gmail.com +",[''],Change stubs to static inlines in perf/bpf to avoid compiler warnings with !CONFIG_BPF_SYSCALL.,"perf,bpf,stubs",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,"[""It's not related to any of the above.""]" +a265c9f6d52ac760e6e572bac73a11b60b998779,a265c9f6d52ac760e6e572bac73a11b60b998779,Kyle Huey,me@kylehuey.com,1712886619,Ingo Molnar,mingo@kernel.org,1712915391,ca0cdf253184f1af3a265b9e5a5e9aee67855988,c4fcc7d1f41532e878087c7c43f4cf247604d68b,"selftest/bpf: Test a perf BPF program that suppresses side effects + +The test sets a hardware breakpoint and uses a BPF program to suppress the +side effects of a perf event sample", including I/O availability signals,"['\nSIGTRAPs', ' and decrementing the event counter limit', ' if the IP matches the\nexpected value. Then the function with the breakpoint is executed multiple\ntimes to test that all effects behave as expected.\n\nSigned-off-by: Kyle Huey \nSigned-off-by: Ingo Molnar \nAcked-by: Song Liu \nAcked-by: Jiri Olsa \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240412015019.7060-8-khuey@kylehuey.com\n', '']",Add a selftest for perf BPF program to suppress side effects of perf event samples.,"selftest, perf, side-effects",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +c4fcc7d1f41532e878087c7c43f4cf247604d68b,c4fcc7d1f41532e878087c7c43f4cf247604d68b,Kyle Huey,me@kylehuey.com,1712886618,Ingo Molnar,mingo@kernel.org,1712915390,42d5d279844896a20d768199e71ca22cb84671a5,76f6d58845829e5d6ef55532e67a323e7d30c26e,"perf/bpf: Allow a BPF program to suppress all sample side effects + +Returning zero from a BPF program attached to a perf event already +suppresses any data output. Return early from __perf_event_overflow() in +this case so it will also suppress event_limit accounting"," SIGTRAP +generation","[' and F_ASYNC signalling.\n\nSigned-off-by: Kyle Huey \nSigned-off-by: Ingo Molnar \nAcked-by: Song Liu \nAcked-by: Jiri Olsa \nAcked-by: Namhyung Kim \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240412015019.7060-7-khuey@kylehuey.com\n', '']",The commit allows BPF programs to suppress all sample side effects by returning zero from __perf_event_overflow.,"BPF program, perf event, suppress",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'profile like programs']" +76f6d58845829e5d6ef55532e67a323e7d30c26e,76f6d58845829e5d6ef55532e67a323e7d30c26e,Kyle Huey,me@kylehuey.com,1712886617,Ingo Molnar,mingo@kernel.org,1712915390,515b94130689238f4a39e396f311d35c0870a7c2,f11f10bfa1ca23b32020b2073aa13131a27978fe,"perf/bpf: Remove unneeded uses_default_overflow_handler() + +Now that struct perf_event's orig_overflow_handler is gone"," there's no need +for the functions and macros to support looking past overflow_handler to +orig_overflow_handler. + +This patch is solely a refactoring and results in no behavior change. + +Signed-off-by: Kyle Huey +Signed-off-by: Ingo Molnar +Acked-by: Will Deacon +Acked-by: Song Liu +Acked-by: Jiri Olsa +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240412015019.7060-6-khuey@kylehuey.com +",[''],Remove unneeded functions in perf/bpf after orig_overflow_handler removal.,"refactoring, perf, overflow_handler",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +f11f10bfa1ca23b32020b2073aa13131a27978fe,f11f10bfa1ca23b32020b2073aa13131a27978fe,Kyle Huey,me@kylehuey.com,1712886616,Ingo Molnar,mingo@kernel.org,1712915389,1657fdb40278f77e27436ee5a56855a9983873c9,14e40a9578b70cc5323e55f61292a7e021f6037c,perf/bpf: Call BPF handler directly," not through overflow machinery + +To ultimately allow BPF programs attached to perf events to completely +suppress all of the effects of a perf event overflow (rather than just the +sample output","[' as they do today)', "" call bpf_overflow_handler() from\n__perf_event_overflow() directly rather than modifying struct perf_event's\noverflow_handler. Return the BPF program's return value from\nbpf_overflow_handler() so that __perf_event_overflow() knows how to\nproceed. Remove the now unnecessary orig_overflow_handler from struct\nperf_event.\n\nThis patch is solely a refactoring and results in no behavior change.\n\nSuggested-by: Namhyung Kim \nSigned-off-by: Kyle Huey \nSigned-off-by: Ingo Molnar \nAcked-by: Song Liu \nAcked-by: Jiri Olsa \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240412015019.7060-5-khuey@kylehuey.com\n"", '']",This commit allows BPF programs to suppress all effects of perf event overflow by calling the handler directly.,"BPF, perf, overflow",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +14e40a9578b70cc5323e55f61292a7e021f6037c,14e40a9578b70cc5323e55f61292a7e021f6037c,Kyle Huey,me@kylehuey.com,1712886615,Ingo Molnar,mingo@kernel.org,1712915389,7c86fb11ad61a5e7d6ada7248495da6409c72082,924d934393f98fa6a41d6ea27352faf79c2bbaf6,"perf/bpf: Remove #ifdef CONFIG_BPF_SYSCALL from struct perf_event members + +This will allow __perf_event_overflow() (which is independent of +CONFIG_BPF_SYSCALL) to use struct perf_event's prog to decide whether to +call bpf_overflow_handler(). + +Suggested-by: Ingo Molnar +Signed-off-by: Kyle Huey +Signed-off-by: Ingo Molnar +Link: https://lore.kernel.org/r/20240412015019.7060-4-khuey@kylehuey.com +",,Remove CONFIG_BPF_SYSCALL dependency from perf_event structure to enable independent functionality.,"perf_event,BPF_SYSCALL,bpf_overflow_handler",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +924d934393f98fa6a41d6ea27352faf79c2bbaf6,924d934393f98fa6a41d6ea27352faf79c2bbaf6,Kyle Huey,me@kylehuey.com,1712886614,Ingo Molnar,mingo@kernel.org,1712915388,451e56cb147c607c21f1f4542e895b84a1c6ae7d,4c03fe11b96bda60610aca77002e83f37b4a2242,"perf/bpf: Create bpf_overflow_handler() stub for !CONFIG_BPF_SYSCALL + +This will allow __perf_event_overflow() (which is independent of +CONFIG_BPF_SYSCALL) to call bpf_overflow_handler(). + +Signed-off-by: Kyle Huey +Signed-off-by: Ingo Molnar +Link: https://lore.kernel.org/r/20240412015019.7060-3-khuey@kylehuey.com +",,Create a bpf_overflow_handler stub for systems without CONFIG_BPF_SYSCALL.,"bpf_overflow_handler, CONFIG_BPF_SYSCALL, perf_event_overflow",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['other'] +4c03fe11b96bda60610aca77002e83f37b4a2242,4c03fe11b96bda60610aca77002e83f37b4a2242,Kyle Huey,me@kylehuey.com,1712886613,Ingo Molnar,mingo@kernel.org,1712915388,6e3d71e85c016b3a0b5d034b07d6bb51189f20fc,acf68d98cae8a60dc4af2e9feaaa799bf0aa5c04,"perf/bpf: Reorder bpf_overflow_handler() ahead of __perf_event_overflow() + +This will allow __perf_event_overflow() to call bpf_overflow_handler(). + +Signed-off-by: Kyle Huey +Signed-off-by: Ingo Molnar +Link: https://lore.kernel.org/r/20240412015019.7060-2-khuey@kylehuey.com +",,Reorders function definitions to allow __perf_event_overflow() to call bpf_overflow_handler().,bpf reordering overflow,It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1e52af7f023c44859868306fac1a4b6b556cf47b,1e52af7f023c44859868306fac1a4b6b556cf47b,Paul E. McKenney,paulmck@kernel.org,1709147848,Uladzislau Rezki (Sony),urezki@gmail.com,1712913805,8b987ba452c39fb944f4ee4d882b1ef079d86cab,02b3c5fcdfe46f9c9dd5d3fc199612b13bf47c06,"bpf: Choose RCU Tasks based on TASKS_RCU rather than PREEMPTION + +The advent of CONFIG_PREEMPT_AUTO", AKA lazy preemption,"[' will mean that\neven kernels built with CONFIG_PREEMPT_NONE or CONFIG_PREEMPT_VOLUNTARY\nmight see the occasional preemption', ' and that this preemption just might\nhappen within a trampoline.\n\nTherefore', ' update bpf_tramp_image_put() to choose call_rcu_tasks()\nbased on CONFIG_TASKS_RCU instead of CONFIG_PREEMPTION.\n\nThis change might enable further simplifications', ' but the goal of this\neffort is to make the code safe', ' not necessarily optimal.\n\nSigned-off-by: Paul E. McKenney \nCc: Alexei Starovoitov \nCc: Daniel Borkmann \nCc: John Fastabend \nCc: Andrii Nakryiko \nCc: Martin KaFai Lau \nCc: Song Liu \nCc: Yonghong Song \nCc: KP Singh \nCc: Stanislav Fomichev \nCc: Hao Luo \nCc: Jiri Olsa \nCc: Ankur Arora \nCc: Thomas Gleixner \nCc: \nSigned-off-by: Uladzislau Rezki (Sony) \n', '']",The commit updates eBPF RCU tasks selection to use TASKS_RCU instead of preemption settings.,"RCU,TASKS_RCU,PREEMPTION",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c53e853c2d8145859f57c63662030f7aaa61cfdc,c53e853c2d8145859f57c63662030f7aaa61cfdc,Martin KaFai Lau,martin.lau@kernel.org,1712859476,Martin KaFai Lau,martin.lau@kernel.org,1712862407,eee55c541945cc7bccee82edc0794d75e469637c,d75142dbeb2bd1587b9cc19f841578f541275a64 dc34e44ea6a1c11cc517adc6df527b457acb9eaf,"Merge branch 'export send_recv_data' + +Geliang Tang says: + +==================== +v5: + - address Martin's comments for v4 (thanks). + - update patch 2"," use 'return err' instead of 'return -1/0'. + - drop patch 3 in v4. + +v4: + - fix a bug in v3","["" it should be 'if (err)'"", ' not \'if (!err)\'.\n - move ""selftests/bpf: Use log_err in network_helpers"" out of this\n series.\n\nv3:\n - add two more patches.\n - use log_err instead of ASSERT in v3.\n - let send_recv_data return int as Martin suggested.\n\nv2:\n\nAddress Martin\'s comments for v1 (thanks.)\n - drop patch 1', ' ""export send_byte helper"".\n - drop ""WRITE_ONCE(arg.stop', ' 0)"".\n - rebased.\n\nsend_recv_data will be re-used in MPTCP bpf tests', ' but not included\nin this set because it depends on other patches that have not been\nin the bpf-next yet. It will be sent as another set soon.\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",The commit merges branch updates to export send and receive data functions with bug fixes and code improvements.,"merge, bugfix, export",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +dc34e44ea6a1c11cc517adc6df527b457acb9eaf,dc34e44ea6a1c11cc517adc6df527b457acb9eaf,Geliang Tang,tanggeliang@kylinos.cn,1712814192,Martin KaFai Lau,martin.lau@kernel.org,1712862402,eee55c541945cc7bccee82edc0794d75e469637c,68acca6e6f99b1f928a2c05b92bb1c272edb8ae7,"selftests/bpf: Export send_recv_data helper + +This patch extracts the code to send and receive data into a new +helper named send_recv_data() in network_helpers.c and export it +in network_helpers.h. + +This helper will be used for MPTCP BPF selftests. + +Signed-off-by: Geliang Tang +Link: https://lore.kernel.org/r/5231103be91fadcce3674a589542c63b6a5eedd4.1712813933.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",,Export send_recv_data helper for MPTCP BPF selftests in network_helpers files.,"send_recv_data,BPF,selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +68acca6e6f99b1f928a2c05b92bb1c272edb8ae7,68acca6e6f99b1f928a2c05b92bb1c272edb8ae7,Geliang Tang,tanggeliang@kylinos.cn,1712814191,Martin KaFai Lau,martin.lau@kernel.org,1712859476,3767bece7681558b7ac282a88a2cc74070123365,d75142dbeb2bd1587b9cc19f841578f541275a64,"selftests/bpf: Add struct send_recv_arg + +Avoid setting total_bytes and stop as global variables"," this patch adds +a new struct named send_recv_arg to pass arguments between threads. Put +these two variables together with fd into this struct and pass it to +server thread","[' so that server thread can access these two variables without\nsetting them as global ones.\n\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/ca1dd703b796f6810985418373e750f7068b4186.1712813933.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Add struct send_recv_arg to pass arguments between threads in selftests/bpf.,"selftests,bpf,struct",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f3408580bac8ce5cd76e7391e529c0a22e7c7eb2,f3408580bac8ce5cd76e7391e529c0a22e7c7eb2,Namhyung Kim,namhyung@kernel.org,1712703342,Namhyung Kim,namhyung@kernel.org,1712856606,49215554c047a3aed647c2c8b5da1217fe658ae3,2b8dbf69ec60faf6c7db49e57d7f316409ccec92,"perf lock contention: Add a missing NULL check + +I got a report for a failure in BPF verifier on a recent kernel with +perf lock contention command. It checks task->sighand->siglock without +checking if sighand is NULL or not. Let's add one. + + ; if (&curr->sighand->siglock == (void *)lock) + 265: (79) r1 = *(u64 *)(r0 +2624) ; frame1: R0_w=trusted_ptr_task_struct(off=0","imm=0) + ; R1_w=rcu_ptr_or_null_sighand_struct(off=0","['imm=0)\n 266: (b7) r2 = 0 ; frame1: R2_w=0\n 267: (0f) r1 += r2\n R1 pointer arithmetic on rcu_ptr_or_null_ prohibited', ' null-check it first\n processed 164 insns (limit 1000000) max_states_per_insn 1 total_states 15 peak_states 15 mark_read 5\n -- END PROG LOAD LOG --\n libbpf: prog \'contention_end\': failed to load: -13\n libbpf: failed to load object \'lock_contention_bpf\'\n libbpf: failed to load BPF skeleton \'lock_contention_bpf\': -13\n Failed to load lock-contention BPF skeleton\n lock contention BPF setup failed\n lock contention did not detect any lock contention\n\nFixes: 1811e82767dcc (""perf lock contention: Track and show siglock with address"")\nReviewed-by: Ian Rogers \nAcked-by: Arnaldo Carvalho de Melo \nCc: Song Liu \nCc: bpf@vger.kernel.org\nSigned-off-by: Namhyung Kim \nLink: https://lore.kernel.org/r/20240409225542.1870999-1-namhyung@kernel.org\n', '']",The commit adds a NULL check in the perf lock contention command for a potential BPF verifier failure.,"NULL check, BPF verifier, perf lock",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d75142dbeb2bd1587b9cc19f841578f541275a64,d75142dbeb2bd1587b9cc19f841578f541275a64,Geliang Tang,tanggeliang@kylinos.cn,1712639920,Martin KaFai Lau,martin.lau@kernel.org,1712856565,5590ecccac81480f8d3ec256d7d554e2055f30b5,ffa6b26b4d8a0520b78636ca9373ab842cb3b1a8,"selftests/bpf: Fix umount cgroup2 error in test_sockmap + +This patch fixes the following ""umount cgroup2"" error in test_sockmap.c: + + (cgroup_helpers.c:353: errno: Device or resource busy) umount cgroup2 + +Cgroup fd cg_fd should be closed before cleanup_cgroup_environment(). + +Fixes: 13a5f3ffd202 (""bpf: Selftests"," sockmap test prog run without setting cgroup"") +Signed-off-by: Geliang Tang +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/0399983bde729708773416b8488bac2cd5e022b8.1712639568.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",[''],The commit fixes an 'umount cgroup2' error in selftests related to BPF test_sockmap.,"fix,selftests,cgroup2",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['cgroup like programs'] +b912cf042072e12e93faa874265b30cc0aa521b9,b912cf042072e12e93faa874265b30cc0aa521b9,Benjamin Tissoires,bentiss@kernel.org,1712819156,Benjamin Tissoires,bentiss@kernel.org,1712844121,b747f244d5aa8f1fa8ce48ea505995ca2217b74b,685dadafbde29dc3d6b7a13be284d684b06d4d4f,"HID: bpf: fix hid_bpf_input_report() when hid-core is not ready + +Reported by linux-next: +After merging the hid tree"," today's linux-next build (x86_64 allmodconfig) +failed like this: + +x86_64-linux-gnu-ld: vmlinux.o: in function `hid_bpf_input_report': +(.text+0x1c75181): undefined reference to `hid_input_report' + +Caused by commit 9be50ac30a83 (""HID: bpf: allow to inject HID event +from BPF"") + +I just forgot to put the indirection in place. + +Link: https://lore.kernel.org/linux-kernel/20240411105131.7830f966@canb.auug.org.au/ +Fixes: 9be50ac30a83 (""HID: bpf: allow to inject HID event from BPF"") +Link: https://lore.kernel.org/r/20240411-fix-hid-bpf-v1-1-4ae913031a8c@kernel.org +Signed-off-by: Benjamin Tissoires +",[''],Fixes HID BPF input report handling by adding necessary indirection when hid-core is not ready.,"HID,BPF,fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['HID driver like programs'] +ffa6b26b4d8a0520b78636ca9373ab842cb3b1a8,ffa6b26b4d8a0520b78636ca9373ab842cb3b1a8,Yonghong Song,yonghong.song@linux.dev,1712763206,Alexei Starovoitov,ast@kernel.org,1712804335,122eb6935e01f480f3dffdbb92f6327024d56956,ded8c00990b9f84e4daf4b3f4c881bace6cc990e,"selftests/bpf: Enable tests for atomics with cpuv4 + +When looking at Alexei's patch ([1]) which added tests for atomics"," +I noticed that the tests will be skipped with cpuv4. For example","['\nwith latest llvm19', ' I see:\n [root@arch-fb-vm1 bpf]# ./test_progs -t arena_atomics\n #3/1 arena_atomics/add:OK\n ...\n #3/7 arena_atomics/xchg:OK\n #3 arena_atomics:OK\n Summary: 1/7 PASSED', ' 0 SKIPPED', ' 0 FAILED\n [root@arch-fb-vm1 bpf]# ./test_progs-cpuv4 -t arena_atomics\n #3 arena_atomics:SKIP\n Summary: 1/0 PASSED', ' 1 SKIPPED', ' 0 FAILED\n [root@arch-fb-vm1 bpf]#\n\nIt is perfectly fine to enable atomics-related tests for cpuv4.\nWith this patch', ' I have\n [root@arch-fb-vm1 bpf]# ./test_progs-cpuv4 -t arena_atomics\n #3/1 arena_atomics/add:OK\n ...\n #3/7 arena_atomics/xchg:OK\n #3 arena_atomics:OK\n Summary: 1/7 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\n [1] https://lore.kernel.org/r/20240405231134.17274-2-alexei.starovoitov@gmail.com\n\nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240410153326.1851055-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Enable selftests for atomic operations compatibility with cpuv4 in BPF.,"selftests, atomics, cpuv4",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ded8c00990b9f84e4daf4b3f4c881bace6cc990e,ded8c00990b9f84e4daf4b3f4c881bace6cc990e,Alexei Starovoitov,ast@kernel.org,1712803946,Alexei Starovoitov,ast@kernel.org,1712803946,c6b821d619c3bd94494c91cdca2e1fb4b7147eec,d0a2ba197bcbeaa795c5c961d927bcaf55964669 8ba218e625f0dfb3ef46fe0721dcdf565726ff76,"Merge branch 'bpf-add-bpf_link-support-for-sk_msg-and-sk_skb-progs' + +Yonghong Song says: + +==================== +bpf: Add bpf_link support for sk_msg and sk_skb progs + +One of our internal services started to use sk_msg program and currently +it used existing prog attach/detach2 as demonstrated in selftests. +But attach/detach of all other bpf programs are based on bpf_link. +Consistent attach/detach APIs for all programs will make things easy to +undersand and less error prone. So this patch added bpf_link +support for BPF_PROG_TYPE_SK_MSG. Based on comments from +previous RFC patch"," I added BPF_PROG_TYPE_SK_SKB support as well +as both program types have similar treatment w.r.t. bpf_link +handling. + +For the patch series","[' patch 1 added kernel support. Patch 2\nadded libbpf support. Patch 3 added bpftool support and\npatches 4/5 added some new tests.\n\nChangelogs:\n v6 -> v7:\n - fix an missing-mutex_unlock error.\n v5 -> v6:\n - resolve libbpf conflict due to recent upstream change.\n - add a bpf_link_create() test.\n - some code refactoring for better code quality.\n v4 -> v5:\n - increase scope of mutex protection in link_release.\n - remove previous-leftover entry in libbpf.map.\n - make some code changes for better understanding.\n v3 -> v4:\n - use a single mutex lock to protect both attach/detach/update\n and release/fill_info/show_fdinfo.\n - simplify code for sock_map_link_lookup().\n - fix a few bugs.\n - add more tests.\n v2 -> v3:\n - consolidate link types of sk_msg and sk_skb to\n a single link type BPF_PROG_TYPE_SOCKMAP.\n - fix bpf_link lifecycle issue. in v2', ' after bpf_link\n is attached', "" a subsequent prog_attach could change\n that bpf_link. this patch makes bpf_link having\n correct behavior such that it won't go away facing\n other prog/link attach for the same map and the same\n attach type.\n====================\n\nLink: https://lore.kernel.org/r/20240410043522.3736912-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n"", '']",Added bpf_link support for sk_msg and sk_skb programs for consistent API usage.,"bpf_link, sk_msg, sk_skb",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8ba218e625f0dfb3ef46fe0721dcdf565726ff76,8ba218e625f0dfb3ef46fe0721dcdf565726ff76,Yonghong Song,yonghong.song@linux.dev,1712723747,Alexei Starovoitov,ast@kernel.org,1712803945,c6b821d619c3bd94494c91cdca2e1fb4b7147eec,a15d58b2bc82abd8c4c994af158b0410424a18d3,"selftests/bpf: Add some tests with new bpf_program__attach_sockmap() APIs + +Add a few more tests in sockmap_basic.c and sockmap_listen.c to +test bpf_link based APIs for SK_MSG and SK_SKB programs. +Link attach/detach/update are all tested. + +All tests are passed. + +Acked-by: Eduard Zingerman +Reviewed-by: John Fastabend +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043547.3738448-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,Add new tests for bpf_program__attach_sockmap() APIs in the selftests suite.,"selftests, sockmap, APIs",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +a15d58b2bc82abd8c4c994af158b0410424a18d3,a15d58b2bc82abd8c4c994af158b0410424a18d3,Yonghong Song,yonghong.song@linux.dev,1712723742,Alexei Starovoitov,ast@kernel.org,1712803945,f5ccabb7cd293ca28b2663bed8ca11e0894ca8a6,1f3e2091d25b2b140967480177fcaee2f0eebfb1,"selftests/bpf: Refactor out helper functions for a few tests + +These helper functions will be used later new tests as well. +There are no functionality change. + +Acked-by: Eduard Zingerman +Reviewed-by: John Fastabend +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043542.3738166-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,Refactor test cases by extracting helper functions for reuse in future tests without changing functionality.,"selftests, refactor, helper",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +1f3e2091d25b2b140967480177fcaee2f0eebfb1,1f3e2091d25b2b140967480177fcaee2f0eebfb1,Yonghong Song,yonghong.song@linux.dev,1712723737,Alexei Starovoitov,ast@kernel.org,1712803945,9619179c3efcd122f536db43153b47fc5b03356b,849989af61added13b2a9005608b1cf46f36f88b,"bpftool: Add link dump support for BPF_LINK_TYPE_SOCKMAP + +An example output looks like: + $ bpftool link + 1776: sk_skb prog 49730 + map_id 0 attach_type sk_skb_verdict + pids test_progs(8424) + 1777: sk_skb prog 49755 + map_id 0 attach_type sk_skb_stream_verdict + pids test_progs(8424) + 1778: sk_msg prog 49770 + map_id 8208 attach_type sk_msg_verdict + pids test_progs(8424) + +Reviewed-by: John Fastabend +Reviewed-by: Quentin Monnet +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043537.3737928-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,This commit adds support for link dumping of BPF_LINK_TYPE_SOCKMAP to bpftool.,"bpftool, link dump, SOCKMAP",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +849989af61added13b2a9005608b1cf46f36f88b,849989af61added13b2a9005608b1cf46f36f88b,Yonghong Song,yonghong.song@linux.dev,1712723732,Alexei Starovoitov,ast@kernel.org,1712803945,23f4a8da6a053d120de73ac37f996fd3ac23d5b7,699c23f02c65cbfc3e638f14ce0d70c23a2e1f02,"libbpf: Add bpf_link support for BPF_PROG_TYPE_SOCKMAP + +Introduce a libbpf API function bpf_program__attach_sockmap() +which allow user to get a bpf_link for their corresponding programs. + +Acked-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Reviewed-by: John Fastabend +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043532.3737722-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,Introduces a new libbpf API function to attach BPF_PROG_TYPE_SOCKMAP using bpf_link.,"bpf_link, sockmap, libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,['socket like programs'] +699c23f02c65cbfc3e638f14ce0d70c23a2e1f02,699c23f02c65cbfc3e638f14ce0d70c23a2e1f02,Yonghong Song,yonghong.song@linux.dev,1712723727,Alexei Starovoitov,ast@kernel.org,1712803945,070b277b3ca08c33c240a73d794ce2226dd6a719,d0a2ba197bcbeaa795c5c961d927bcaf55964669,"bpf: Add bpf_link support for sk_msg and sk_skb progs + +Add bpf_link support for sk_msg and sk_skb programs. We have an +internal request to support bpf_link for sk_msg programs so user +space can have a uniform handling with bpf_link based libbpf +APIs. Using bpf_link based libbpf API also has a benefit which +makes system robust by decoupling prog life cycle and +attachment life cycle. + +Reviewed-by: John Fastabend +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240410043527.3737160-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,Add bpf_link support for sk_msg and sk_skb programs to enhance robustness and uniform handling with libbpf APIs.,"bpf_link, sk_msg, sk_skb",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['socket like programs'] +414e576fb08f108b061cbc1fb964e51ff3467985,414e576fb08f108b061cbc1fb964e51ff3467985,Jakub Kicinski,kuba@kernel.org,1712782994,Jakub Kicinski,kuba@kernel.org,1712782994,899e0e02adfddd8a8072e782c2a1c4e3dc7887b4,2ecd487b670fcbb1ad4893fff1af4aafdecb6023 6ce2b689932ba8288ceef9a82c1caf029b0b23f9,"Merge branch 'selftests-move-bpf-offload-test-from-bpf-to-net' + +Jakub Kicinski says: + +==================== +selftests: move bpf-offload test from bpf to net + +The test_offload.py test fits in networking and bpf equally +well. We started adding more Python tests in networking +and some of the code in test_offload.py can be reused"," +so move it to networking. Looks like it bit rotted over +time and some fixes are needed. + +Admittedly more code could be extracted but I only had +the time for a minor cleanup :( +==================== + +Link: https://lore.kernel.org/r/20240409031549.3531084-1-kuba@kernel.org +Signed-off-by: Jakub Kicinski +",[''],Move bpf-offload test from bpf to networking for better code reuse and minor cleanup.,"bpf-offload, test, networking",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6ce2b689932ba8288ceef9a82c1caf029b0b23f9,6ce2b689932ba8288ceef9a82c1caf029b0b23f9,Jakub Kicinski,kuba@kernel.org,1712632549,Jakub Kicinski,kuba@kernel.org,1712782992,899e0e02adfddd8a8072e782c2a1c4e3dc7887b4,b1c2ce11d42886d08cfa28e38ee07f2b606ced0b,"selftests: net: reuse common code in bpf_offload + +net/lib/py/nsim.py already contains the most useful parts +of the netdevsim wrapper classes. Reuse them. + +Acked-by: Stanislav Fomichev +Acked-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20240409031549.3531084-5-kuba@kernel.org +Signed-off-by: Jakub Kicinski +",,Refactor bpf_offload self-tests to reuse existing code from netdevsim wrapper classes.,"selftests, bpf_offload, netdevsim",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +b1c2ce11d42886d08cfa28e38ee07f2b606ced0b,b1c2ce11d42886d08cfa28e38ee07f2b606ced0b,Jakub Kicinski,kuba@kernel.org,1712632548,Jakub Kicinski,kuba@kernel.org,1712782992,9ef005b821557497573639effbb565b93958d101,fc50c698c28bcf307dfb14ba9d0b3cacb091c1cb,"selftests: net: declare section names for bpf_offload + +Non-ancient ip (iproute2-5.15.0"," libbpf 0.7.0) refuses to load +the sample with maps because we don't generate BTF: + + libbpf: BTF is required","["" but is missing or corrupted.\n ERROR: opening BPF object file failed\n\nEnable BTF by adding -g to clang flags. With that done\nneither of the programs load:\n\n libbpf: prog 'func': error relocating .BTF.ext function info: -22\n libbpf: prog 'func': failed to relocate calls: -22\n libbpf: failed to load object 'ksft-net-drv/net/sample_ret0.bpf.o'\n\nAndrii explains that this is because we don't specify\nsection names for the code. Add the section names"", ' too.\n\nAcked-by: Alexei Starovoitov \nAcked-by: Stanislav Fomichev \nAcked-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20240409031549.3531084-4-kuba@kernel.org\nSigned-off-by: Jakub Kicinski \n', '']",Declare section names for bpf_offload in selftests to ensure compatibility with newer iproute2 versions requiring BTF.,"selftests, bpf_offload, BTF",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fc50c698c28bcf307dfb14ba9d0b3cacb091c1cb,fc50c698c28bcf307dfb14ba9d0b3cacb091c1cb,Jakub Kicinski,kuba@kernel.org,1712632547,Jakub Kicinski,kuba@kernel.org,1712782992,3199f053af40b837c209b866d3777831b475ce62,e59f0e93e92e0ddfd17e3373d586218cf638571e,"selftests: net: bpf_offload: wait for maps + +Maps are removed asynchronously. Either there's a bigger delay +now or the test has always been flaky. Retry waiting in the loop. + +Acked-by: Stanislav Fomichev +Acked-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20240409031549.3531084-3-kuba@kernel.org +Signed-off-by: Jakub Kicinski +",,This commit modifies self-tests to add a wait loop for map removals due to asynchronous behavior.,"selftests, maps, asynchronous",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e59f0e93e92e0ddfd17e3373d586218cf638571e,e59f0e93e92e0ddfd17e3373d586218cf638571e,Jakub Kicinski,kuba@kernel.org,1712632546,Jakub Kicinski,kuba@kernel.org,1712782992,4d58b8dd5199a67c1d9d23c841e00c41f2b28e60,2ecd487b670fcbb1ad4893fff1af4aafdecb6023,"selftests: move bpf-offload test from bpf to net + +We're building more python tests on the netdev side"," and some +of the classes from the venerable BPF offload tests can be reused. + +Acked-by: Stanislav Fomichev +Acked-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20240409031549.3531084-2-kuba@kernel.org +Signed-off-by: Jakub Kicinski +",[''],This commit moves the bpf-offload test from bpf to net for improved reusability.,"selftests,bpf-offload,net",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +685dadafbde29dc3d6b7a13be284d684b06d4d4f,685dadafbde29dc3d6b7a13be284d684b06d4d4f,Benjamin Tissoires,bentiss@kernel.org,1710513884,Benjamin Tissoires,bentiss@kernel.org,1712759917,a3c3ea15f7998a7c241e8d8a8561e94f4e9a52bf,2c0e8ced7d4bf746923fc424415844d695f07808,"HID: bpf: allow to use bpf_timer_set_sleepable_cb() in tracing callbacks. + +Export the sleepable kfuncs we have on HID-BPF in tracing bpf programs"," +but with the condition of being used in a sleepable context. +This allows to use the bpf_timer when used in a sleepable context +through bpf_timer_set_sleepable_cb() and initiate work from a device event. + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-7-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires +",[''],Enable use of bpf_timer_set_sleepable_cb() in HID tracing bpf programs for sleepable contexts.,"HID,BPF,sleepable",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['HID driver like programs'] +2c0e8ced7d4bf746923fc424415844d695f07808,2c0e8ced7d4bf746923fc424415844d695f07808,Benjamin Tissoires,bentiss@kernel.org,1710513883,Benjamin Tissoires,bentiss@kernel.org,1712759917,1f66356c79242fa9b030d75c07f754e765b107bd,9be50ac30a83896a753ab9f64e941763bb7900be,"selftests/hid: add tests for hid_bpf_input_report + +Usual way of testing"," we call the function and ensures we receive +the event + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-6-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires +",[''],Add self-tests for the hid_bpf_input_report function in HID driver.,"selftests,hid_bpf_input_report,HID",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['HID driver like programs'] +9be50ac30a83896a753ab9f64e941763bb7900be,9be50ac30a83896a753ab9f64e941763bb7900be,Benjamin Tissoires,bentiss@kernel.org,1710513882,Benjamin Tissoires,bentiss@kernel.org,1712759891,be748108a980cf8f48685694d8b3ffee573c6ee5,db624e82c55f227b84ac9ebfa3de2f6f5fad666b,"HID: bpf: allow to inject HID event from BPF + +It can be interesting to inject events from BPF as if the event were +to come from the device. +For example"," some multitouch devices do not all the time send a proximity +out event","[' and we might want to send it for the physical device.\n\nCompared to uhid', ' we can now inject events on any physical device', ' not\njust uhid virtual ones.\n\nLink: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-5-079c282469d3@kernel.org\nSigned-off-by: Benjamin Tissoires \n', '']","Introduces the capability to inject HID events from eBPF, simulating device-originated events.","HID,BPF,event",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['HID driver like programs'] +db624e82c55f227b84ac9ebfa3de2f6f5fad666b,db624e82c55f227b84ac9ebfa3de2f6f5fad666b,Benjamin Tissoires,bentiss@kernel.org,1710513881,Benjamin Tissoires,bentiss@kernel.org,1712759843,1438da0dcbf4dd544aff72be81546e32a51d6257,c8a1495947ffcab18d9a85144ab4abc570720e65,"selftests/hid: Add test for hid_bpf_hw_output_report + +This time we need to ensure uhid receives it"," thus the new mutex and +condition. + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-4-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires +",[''],Added a selftest for HID to ensure uhid receives hid_bpf_hw_output_report correctly.,"selftests,HID,uhid",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['HID driver like programs'] +c8a1495947ffcab18d9a85144ab4abc570720e65,c8a1495947ffcab18d9a85144ab4abc570720e65,Benjamin Tissoires,bentiss@kernel.org,1710513880,Benjamin Tissoires,bentiss@kernel.org,1712759843,9040a86ccf2218135cf1b7ff1001c373ad7eac2e,5599f80196612efde96dbe6ef18f6ecc0cb4ba19,"selftests/hid: add KASAN to the VM tests + +It's always a good idea to have KASAN in tests. + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-3-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires +",,The commit adds KASAN to the selftests for HID drivers in virtual machines.,"KASAN,selftests,HID",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['HID driver like programs'] +5599f80196612efde96dbe6ef18f6ecc0cb4ba19,5599f80196612efde96dbe6ef18f6ecc0cb4ba19,Benjamin Tissoires,bentiss@kernel.org,1710513879,Benjamin Tissoires,bentiss@kernel.org,1712759834,0176fb7c39f14a4f325742deec12adcbf4c38892,4171954f56fb6da8cc8ceebf54b78b874278a198,"HID: bpf: export hid_hw_output_report as a BPF kfunc + +We currently only export hid_hw_raw_request() as a BPF kfunc. +However"," some devices require an explicit write on the Output Report +instead of the use of the control channel. + +So also export hid_hw_output_report to BPF + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-2-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires +",[''],Export hid_hw_output_report as a BPF kfunc for HID support in eBPF.,"HID,BPF,kfunc",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['HID driver like programs'] +4171954f56fb6da8cc8ceebf54b78b874278a198,4171954f56fb6da8cc8ceebf54b78b874278a198,Benjamin Tissoires,bentiss@kernel.org,1710513878,Benjamin Tissoires,bentiss@kernel.org,1712759725,337e7414ac51e42285843dd0d70727116d3d0ba8,3e78a6c0d3e02e4cf881dc84c5127e9990f939d6,"HID: bpf/dispatch: regroup kfuncs definitions + +No code change"," just move down the hid_bpf_get_data() kfunc definition +so we have only one block of __bpf_kfunc_start/end_defs() + +Link: https://lore.kernel.org/r/20240315-b4-hid-bpf-new-funcs-v4-1-079c282469d3@kernel.org +Signed-off-by: Benjamin Tissoires +",[''],The commit reorganizes HID BPF kfuncs definitions for cleaner code structure.,"HID,bpf,kfuncs",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['HID driver like programs'] +d0a2ba197bcbeaa795c5c961d927bcaf55964669,d0a2ba197bcbeaa795c5c961d927bcaf55964669,Alexei Starovoitov,ast@kernel.org,1712358694,Martin KaFai Lau,martin.lau@kernel.org,1712683466,e533f9b8283c71b56ea7aaa3ae83c2620d28d788,d503a04f8bc0c75dc9db9452d8cc79d748afb752,"selftests/bpf: Add tests for atomics in bpf_arena. + +Add selftests for atomic instructions in bpf_arena. + +Signed-off-by: Alexei Starovoitov +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240405231134.17274-2-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau +",,Add selftests for atomic instructions used within bpf_arena.,"selftests, atomics, bpf_arena",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d503a04f8bc0c75dc9db9452d8cc79d748afb752,d503a04f8bc0c75dc9db9452d8cc79d748afb752,Alexei Starovoitov,ast@kernel.org,1712358693,Martin KaFai Lau,martin.lau@kernel.org,1712683466,54f3e9a2c1954e9e916989a454233fe56ce5ba25,bb761fcb821738e8d3b720e1460d3783db74c68a,"bpf: Add support for certain atomics in bpf_arena to x86 JIT + +Support atomics in bpf_arena that can be JITed as a single x86 instruction. +Instructions that are JITed as loops are not supported at the moment"," +since they require more complex extable and loop logic. + +JITs can choose to do smarter things with bpf_jit_supports_insn(). +Like arm64 may decide to support all bpf atomics instructions +when emit_lse_atomic is available and none in ll_sc mode. + +bpf_jit_supports_percpu_insn()","[' bpf_jit_supports_ptr_xchg() and\nother such callbacks can be replaced with bpf_jit_supports_insn()\nin the future.\n\nSigned-off-by: Alexei Starovoitov \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240405231134.17274-1-alexei.starovoitov@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Add support for atomics in bpf_arena to x86 JIT for single instruction execution.,"atomics,JIT,bpf_arena",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b993115b44d769cb34b394d92658226df81a6c89,b993115b44d769cb34b394d92658226df81a6c89,Paul E. McKenney,paulmck@kernel.org,1708625777,Uladzislau Rezki (Sony),urezki@gmail.com,1712668385,d409e95f06f10e64cb436db1ba36bccab73ca5f2,179f4ce102eb62b4b8efbd8371ee7d25c1082467,"bpf: Select new NEED_TASKS_RCU Kconfig option + +Currently", if a Kconfig option depends on TASKS_RCU,"[' it conditionally does\n""select TASKS_RCU if PREEMPTION"". This works', ' but requires any change in\nthis enablement logic to be replicated across all such ""select"" clauses.\nA new NEED_TASKS_RCU Kconfig option has been created to allow this\nenablement logic to be in one place in kernel/rcu/Kconfig.\n\nTherefore', ' make BPF select the new NEED_TASKS_RCU Kconfig option.\n\nSigned-off-by: Paul E. McKenney \nCc: Alexei Starovoitov \nCc: Daniel Borkmann \nCc: Andrii Nakryiko \nCc: Martin KaFai Lau \nCc: Song Liu \nCc: Yonghong Song \nCc: John Fastabend \nCc: KP Singh \nCc: Stanislav Fomichev \nCc: Hao Luo \nCc: Jiri Olsa \nCc: \nCc: Ankur Arora \nCc: Thomas Gleixner \nCc: Steven Rostedt \nAcked-by: Mark Rutland \nSigned-off-by: Uladzislau Rezki (Sony) \n', '']",The commit selects the new Kconfig option NEED_TASKS_RCU for bpf.,"Kconfig, NEED_TASKS_RCU, bpf",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +bb761fcb821738e8d3b720e1460d3783db74c68a,bb761fcb821738e8d3b720e1460d3783db74c68a,Jason Xing,kernelxing@tencent.com,1712414773,Martin KaFai Lau,martin.lau@kernel.org,1712619078,0e5f7a99764b05e0ef868abce7a5f4889480abcd,50408d7abea68e2d1ae3a9328e1a468b7089b11c,"selftests/bpf: eliminate warning of get_cgroup_id_from_path() + +The output goes like this if I make samples/bpf: +...warning: no previous prototype for ‘get_cgroup_id_from_path’... + +Make this function static could solve the warning problem since +no one outside of the file calls it. + +Signed-off-by: Jason Xing +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240406144613.4434-1-kerneljasonxing@gmail.com +Signed-off-by: Martin KaFai Lau +",,The commit eliminates a prototype warning by making get_cgroup_id_from_path static in selftests/bpf.,"selftests,bpf,warning",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['cgroup like programs'] +6648e613226e18897231ab5e42ffc29e63fa3365,6648e613226e18897231ab5e42ffc29e63fa3365,Jason Xing,kernelxing@tencent.com,1712196601,Daniel Borkmann,daniel@iogearbox.net,1712560702,dc6a8373e176b33f6d3678272bd30a10293cc6ff,76cd338994778c552c51086fc056819b5cdda2e7,bpf," skmsg: Fix NULL pointer dereference in sk_psock_skb_ingress_enqueue + +Fix NULL pointer data-races in sk_psock_skb_ingress_enqueue() which +syzbot reported [1]. + +[1] +BUG: KCSAN: data-race in sk_psock_drop / sk_psock_skb_ingress_enqueue + +write to 0xffff88814b3278b8 of 8 bytes by task 10724 on cpu 1: + sk_psock_stop_verdict net/core/skmsg.c:1257 [inline] + sk_psock_drop+0x13e/0x1f0 net/core/skmsg.c:843 + sk_psock_put include/linux/skmsg.h:459 [inline] + sock_map_close+0x1a7/0x260 net/core/sock_map.c:1648 + unix_release+0x4b/0x80 net/unix/af_unix.c:1048 + __sock_release net/socket.c:659 [inline] + sock_close+0x68/0x150 net/socket.c:1421 + __fput+0x2c1/0x660 fs/file_table.c:422 + __fput_sync+0x44/0x60 fs/file_table.c:507 + __do_sys_close fs/open.c:1556 [inline] + __se_sys_close+0x101/0x1b0 fs/open.c:1541 + __x64_sys_close+0x1f/0x30 fs/open.c:1541 + do_syscall_64+0xd3/0x1d0 + entry_SYSCALL_64_after_hwframe+0x6d/0x75 + +read to 0xffff88814b3278b8 of 8 bytes by task 10713 on cpu 0: + sk_psock_data_ready include/linux/skmsg.h:464 [inline] + sk_psock_skb_ingress_enqueue+0x32d/0x390 net/core/skmsg.c:555 + sk_psock_skb_ingress_self+0x185/0x1e0 net/core/skmsg.c:606 + sk_psock_verdict_apply net/core/skmsg.c:1008 [inline] + sk_psock_verdict_recv+0x3e4/0x4a0 net/core/skmsg.c:1202 + unix_read_skb net/unix/af_unix.c:2546 [inline] + unix_stream_read_skb+0x9e/0xf0 net/unix/af_unix.c:2682 + sk_psock_verdict_data_ready+0x77/0x220 net/core/skmsg.c:1223 + unix_stream_sendmsg+0x527/0x860 net/unix/af_unix.c:2339 + sock_sendmsg_nosec net/socket.c:730 [inline] + __sock_sendmsg+0x140/0x180 net/socket.c:745 + ____sys_sendmsg+0x312/0x410 net/socket.c:2584 + ___sys_sendmsg net/socket.c:2638 [inline] + __sys_sendmsg+0x1e9/0x280 net/socket.c:2667 + __do_sys_sendmsg net/socket.c:2676 [inline] + __se_sys_sendmsg net/socket.c:2674 [inline] + __x64_sys_sendmsg+0x46/0x50 net/socket.c:2674 + do_syscall_64+0xd3/0x1d0 + entry_SYSCALL_64_after_hwframe+0x6d/0x75 + +value changed: 0xffffffff83d7feb0 -> 0x0000000000000000 + +Reported by Kernel Concurrency Sanitizer on: +CPU: 0 PID: 10713 Comm: syz-executor.4 Tainted: G W 6.8.0-syzkaller-08951-gfe46a7dd189e #0 +Hardware name: Google Google Compute Engine/Google Compute Engine","[' BIOS Google 02/29/2024\n\nPrior to this', ' commit 4cd12c6065df (""bpf', ' sockmap: Fix NULL pointer\ndereference in sk_psock_verdict_data_ready()"") fixed one NULL pointer\nsimilarly due to no protection of saved_data_ready. Here is another\ndifferent caller causing the same issue because of the same reason. So\nwe should protect it with sk_callback_lock read lock because the writer\nside in the sk_psock_drop() uses ""write_lock_bh(&sk->sk_callback_lock);"".\n\nTo avoid errors that could happen in future', ' I move those two pairs of\nlock into the sk_psock_data_ready()', ' which is suggested by John Fastabend.\n\nFixes: 604326b41a6f (""bpf', ' sockmap: convert to generic sk_msg interface"")\nReported-by: syzbot+aa8c8ec2538929f18f2d@syzkaller.appspotmail.com\nSigned-off-by: Jason Xing \nSigned-off-by: Daniel Borkmann \nReviewed-by: John Fastabend \nCloses: https://syzkaller.appspot.com/bug?extid=aa8c8ec2538929f18f2d\nLink: https://lore.kernel.org/all/20240329134037.92124-1-kerneljasonxing@gmail.com\nLink: https://lore.kernel.org/bpf/20240404021001.94815-1-kerneljasonxing@gmail.com\n', '']",Fixes data-race issues in sk_psock_skb_ingress_enqueue function to prevent NULL pointer dereference.,"data-race,NULL pointer,sk_psock",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +50408d7abea68e2d1ae3a9328e1a468b7089b11c,50408d7abea68e2d1ae3a9328e1a468b7089b11c,Andrii Nakryiko,andrii@kernel.org,1712419871,Andrii Nakryiko,andrii@kernel.org,1712423795,be1f6764f6ef5a655bb0d2e5d60bf7c99659a9ae,d564ffde5c832c46513e0189647abfde9833e590 4d22ea94ea33550538b3b14429d52cb9f96ad2c3,"Merge branch 'libbpf-api-to-partially-consume-items-from-ringbuffer' + +Andrea Righi says: + +==================== +libbpf: API to partially consume items from ringbuffer + +Introduce ring__consume_n() and ring_buffer__consume_n() API to +partially consume items from one (or more) ringbuffer(s). + +This can be useful", for example,"["" to consume just a single item or when\nwe need to copy multiple items to a limited user-space buffer from the\nringbuffer callback.\n\nPractical example (where this API can be used):\nhttps://github.com/sched-ext/scx/blob/b7c06b9ed9f72cad83c31e39e9c4e2cfd8683a55/rust/scx_rustland_core/src/bpf.rs#L217\n\nSee also:\nhttps://lore.kernel.org/lkml/20240310154726.734289-1-andrea.righi@canonical.com/T/#u\n\nv4:\n - open a new 1.5.0 cycle\n\nv3:\n - rename ring__consume_max() -> ring__consume_n() and\n ring_buffer__consume_max() -> ring_buffer__consume_n()\n - add new API to a new 1.5.0 cycle\n - fixed minor nits / comments\n\nv2:\n - introduce a new API instead of changing the callback's retcode\n behavior\n====================\n\nLink: https://lore.kernel.org/r/20240406092005.92399-1-andrea.righi@canonical.com\nSigned-off-by: Andrii Nakryiko \n"", '']",Introduce API to partially consume items from ringbuffer in libbpf.,"libbpf, API, ringbuffer",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4d22ea94ea33550538b3b14429d52cb9f96ad2c3,4d22ea94ea33550538b3b14429d52cb9f96ad2c3,Andrea Righi,andrea.righi@canonical.com,1712394943,Andrii Nakryiko,andrii@kernel.org,1712419915,be1f6764f6ef5a655bb0d2e5d60bf7c99659a9ae,13e8125a22763557d719db996f70c71f77c9509c,"libbpf: Add ring__consume_n / ring_buffer__consume_n + +Introduce a new API to consume items from a ring buffer"," limited to a +specified amount","[' and return to the caller the actual number of items\nconsumed.\n\nSigned-off-by: Andrea Righi \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/lkml/20240310154726.734289-1-andrea.righi@canonical.com/T\nLink: https://lore.kernel.org/bpf/20240406092005.92399-4-andrea.righi@canonical.com\n', '']",Introduces a new API to consume multiple items from a ring buffer in libbpf.,"libbpf,ring buffer,API",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +13e8125a22763557d719db996f70c71f77c9509c,13e8125a22763557d719db996f70c71f77c9509c,Andrea Righi,andrea.righi@canonical.com,1712394942,Andrii Nakryiko,andrii@kernel.org,1712419914,55cc123f3de1470b1741461a5812b14dba737031,5bd2ed658231b0698211e94efb06393836a4539d,"libbpf: ringbuf: Allow to consume up to a certain amount of items + +In some cases"," instead of always consuming all items from ring buffers +in a greedy way","[' we may want to consume up to a certain amount of items', '\nfor example when we need to copy items from the BPF ring buffer to a\nlimited user buffer.\n\nThis change allows to set an upper limit to the amount of items consumed\nfrom one or more ring buffers.\n\nSigned-off-by: Andrea Righi \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240406092005.92399-3-andrea.righi@canonical.com\n', '']",The commit adds an option to consume a specific number of items from libbpf ring buffers instead of all.,"libbpf, ringbuf, consume",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5bd2ed658231b0698211e94efb06393836a4539d,5bd2ed658231b0698211e94efb06393836a4539d,Andrea Righi,andrea.righi@canonical.com,1712394941,Andrii Nakryiko,andrii@kernel.org,1712419870,ee106da1a8ead37abe175b28b0cf64d9db2d7067,d564ffde5c832c46513e0189647abfde9833e590,"libbpf: Start v1.5 development cycle + +Bump libbpf.map to v1.5.0 to start a new libbpf version cycle. + +Signed-off-by: Andrea Righi +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240406092005.92399-2-andrea.righi@canonical.com +",,Bump libbpf.map to v1.5.0 to initiate the new development cycle for libbpf.,libbpf development cycle,It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +237f3cf13b20db183d3706d997eedc3c49eacd44,237f3cf13b20db183d3706d997eedc3c49eacd44,Eric Dumazet,edumazet@google.com,1712262458,Jakub Kicinski,kuba@kernel.org,1712382442,9ae99305c845c825f78e992d069b908033897b22,38a15d0a50e0a43778561a5861403851f0b0194c,"xsk: validate user input for XDP_{UMEM|COMPLETION}_FILL_RING + +syzbot reported an illegal copy in xsk_setsockopt() [1] + +Make sure to validate setsockopt() @optlen parameter. + +[1] + + BUG: KASAN: slab-out-of-bounds in copy_from_sockptr_offset include/linux/sockptr.h:49 [inline] + BUG: KASAN: slab-out-of-bounds in copy_from_sockptr include/linux/sockptr.h:55 [inline] + BUG: KASAN: slab-out-of-bounds in xsk_setsockopt+0x909/0xa40 net/xdp/xsk.c:1420 +Read of size 4 at addr ffff888028c6cde3 by task syz-executor.0/7549 + +CPU: 0 PID: 7549 Comm: syz-executor.0 Not tainted 6.8.0-syzkaller-08951-gfe46a7dd189e #0 +Hardware name: Google Google Compute Engine/Google Compute Engine"," BIOS Google 03/27/2024 +Call Trace: + + __dump_stack lib/dump_stack.c:88 [inline] + dump_stack_lvl+0x241/0x360 lib/dump_stack.c:114 + print_address_description mm/kasan/report.c:377 [inline] + print_report+0x169/0x550 mm/kasan/report.c:488 + kasan_report+0x143/0x180 mm/kasan/report.c:601 + copy_from_sockptr_offset include/linux/sockptr.h:49 [inline] + copy_from_sockptr include/linux/sockptr.h:55 [inline] + xsk_setsockopt+0x909/0xa40 net/xdp/xsk.c:1420 + do_sock_setsockopt+0x3af/0x720 net/socket.c:2311 + __sys_setsockopt+0x1ae/0x250 net/socket.c:2334 + __do_sys_setsockopt net/socket.c:2343 [inline] + __se_sys_setsockopt net/socket.c:2340 [inline] + __x64_sys_setsockopt+0xb5/0xd0 net/socket.c:2340 + do_syscall_64+0xfb/0x240 + entry_SYSCALL_64_after_hwframe+0x6d/0x75 +RIP: 0033:0x7fb40587de69 +Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48 +RSP: 002b:00007fb40665a0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000036 +RAX: ffffffffffffffda RBX: 00007fb4059abf80 RCX: 00007fb40587de69 +RDX: 0000000000000005 RSI: 000000000000011b RDI: 0000000000000006 +RBP: 00007fb4058ca47a R08: 0000000000000002 R09: 0000000000000000 +R10: 0000000020001980 R11: 0000000000000246 R12: 0000000000000000 +R13: 000000000000000b R14: 00007fb4059abf80 R15: 00007fff57ee4d08 + + +Allocated by task 7549: + kasan_save_stack mm/kasan/common.c:47 [inline] + kasan_save_track+0x3f/0x80 mm/kasan/common.c:68 + poison_kmalloc_redzone mm/kasan/common.c:370 [inline] + __kasan_kmalloc+0x98/0xb0 mm/kasan/common.c:387 + kasan_kmalloc include/linux/kasan.h:211 [inline] + __do_kmalloc_node mm/slub.c:3966 [inline] + __kmalloc+0x233/0x4a0 mm/slub.c:3979 + kmalloc include/linux/slab.h:632 [inline] + __cgroup_bpf_run_filter_setsockopt+0xd2f/0x1040 kernel/bpf/cgroup.c:1869 + do_sock_setsockopt+0x6b4/0x720 net/socket.c:2293 + __sys_setsockopt+0x1ae/0x250 net/socket.c:2334 + __do_sys_setsockopt net/socket.c:2343 [inline] + __se_sys_setsockopt net/socket.c:2340 [inline] + __x64_sys_setsockopt+0xb5/0xd0 net/socket.c:2340 + do_syscall_64+0xfb/0x240 + entry_SYSCALL_64_after_hwframe+0x6d/0x75 + +The buggy address belongs to the object at ffff888028c6cde0 + which belongs to the cache kmalloc-8 of size 8 +The buggy address is located 1 bytes to the right of + allocated 2-byte region [ffff888028c6cde0","[' ffff888028c6cde2)\n\nThe buggy address belongs to the physical page:\npage:ffffea0000a31b00 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888028c6c9c0 pfn:0x28c6c\nanon flags: 0xfff00000000800(slab|node=0|zone=1|lastcpupid=0x7ff)\npage_type: 0xffffffff()\nraw: 00fff00000000800 ffff888014c41280 0000000000000000 dead000000000001\nraw: ffff888028c6c9c0 0000000080800057 00000001ffffffff 0000000000000000\npage dumped because: kasan: bad access detected\npage_owner tracks the page as allocated\npage last allocated via order 0', ' migratetype Unmovable', ' gfp_mask 0x112cc0(GFP_USER|__GFP_NOWARN|__GFP_NORETRY)', ' pid 6648', ' tgid 6644 (syz-executor.0)', ' ts 133906047828', ' free_ts 133859922223\n set_page_owner include/linux/page_owner.h:31 [inline]\n post_alloc_hook+0x1ea/0x210 mm/page_alloc.c:1533\n prep_new_page mm/page_alloc.c:1540 [inline]\n get_page_from_freelist+0x33ea/0x3580 mm/page_alloc.c:3311\n __alloc_pages+0x256/0x680 mm/page_alloc.c:4569\n __alloc_pages_node include/linux/gfp.h:238 [inline]\n alloc_pages_node include/linux/gfp.h:261 [inline]\n alloc_slab_page+0x5f/0x160 mm/slub.c:2175\n allocate_slab mm/slub.c:2338 [inline]\n new_slab+0x84/0x2f0 mm/slub.c:2391\n ___slab_alloc+0xc73/0x1260 mm/slub.c:3525\n __slab_alloc mm/slub.c:3610 [inline]\n __slab_alloc_node mm/slub.c:3663 [inline]\n slab_alloc_node mm/slub.c:3835 [inline]\n __do_kmalloc_node mm/slub.c:3965 [inline]\n __kmalloc_node+0x2db/0x4e0 mm/slub.c:3973\n kmalloc_node include/linux/slab.h:648 [inline]\n __vmalloc_area_node mm/vmalloc.c:3197 [inline]\n __vmalloc_node_range+0x5f9/0x14a0 mm/vmalloc.c:3392\n __vmalloc_node mm/vmalloc.c:3457 [inline]\n vzalloc+0x79/0x90 mm/vmalloc.c:3530\n bpf_check+0x260/0x19010 kernel/bpf/verifier.c:21162\n bpf_prog_load+0x1667/0x20f0 kernel/bpf/syscall.c:2895\n __sys_bpf+0x4ee/0x810 kernel/bpf/syscall.c:5631\n __do_sys_bpf kernel/bpf/syscall.c:5738 [inline]\n __se_sys_bpf kernel/bpf/syscall.c:5736 [inline]\n __x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:5736\n do_syscall_64+0xfb/0x240\n entry_SYSCALL_64_after_hwframe+0x6d/0x75\npage last free pid 6650 tgid 6647 stack trace:\n reset_page_owner include/linux/page_owner.h:24 [inline]\n free_pages_prepare mm/page_alloc.c:1140 [inline]\n free_unref_page_prepare+0x95d/0xa80 mm/page_alloc.c:2346\n free_unref_page_list+0x5a3/0x850 mm/page_alloc.c:2532\n release_pages+0x2117/0x2400 mm/swap.c:1042\n tlb_batch_pages_flush mm/mmu_gather.c:98 [inline]\n tlb_flush_mmu_free mm/mmu_gather.c:293 [inline]\n tlb_flush_mmu+0x34d/0x4e0 mm/mmu_gather.c:300\n tlb_finish_mmu+0xd4/0x200 mm/mmu_gather.c:392\n exit_mmap+0x4b6/0xd40 mm/mmap.c:3300\n __mmput+0x115/0x3c0 kernel/fork.c:1345\n exit_mm+0x220/0x310 kernel/exit.c:569\n do_exit+0x99e/0x27e0 kernel/exit.c:865\n do_group_exit+0x207/0x2c0 kernel/exit.c:1027\n get_signal+0x176e/0x1850 kernel/signal.c:2907\n arch_do_signal_or_restart+0x96/0x860 arch/x86/kernel/signal.c:310\n exit_to_user_mode_loop kernel/entry/common.c:105 [inline]\n exit_to_user_mode_prepare include/linux/entry-common.h:328 [inline]\n __syscall_exit_to_user_mode_work kernel/entry/common.c:201 [inline]\n syscall_exit_to_user_mode+0xc9/0x360 kernel/entry/common.c:212\n do_syscall_64+0x10a/0x240 arch/x86/entry/common.c:89\n entry_SYSCALL_64_after_hwframe+0x6d/0x75\n\nMemory state around the buggy address:\n ffff888028c6cc80: fa fc fc fc fa fc fc fc fa fc fc fc fa fc fc fc\n ffff888028c6cd00: fa fc fc fc fa fc fc fc 00 fc fc fc 06 fc fc fc\n>ffff888028c6cd80: fa fc fc fc fa fc fc fc fa fc fc fc 02 fc fc fc\n ^\n ffff888028c6ce00: fa fc fc fc fa fc fc fc fa fc fc fc fa fc fc fc\n ffff888028c6ce80: fa fc fc fc fa fc fc fc fa fc fc fc fa fc fc fc\n\nFixes: 423f38329d26 (""xsk: add umem fill queue support and mmap"")\nReported-by: syzbot \nSigned-off-by: Eric Dumazet \nCc: ""Björn Töpel"" \nCc: Magnus Karlsson \nCc: Maciej Fijalkowski \nCc: Jonathan Lemon \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/r/20240404202738.3634547-1-edumazet@google.com\nSigned-off-by: Jakub Kicinski \n', '']",The commit fixes a bug by validating the optlen parameter in xsk_setsockopt to prevent slab-out-of-bounds errors.,"validation, bugfix, xsk_setsockopt",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,['xdp like programs'] +d564ffde5c832c46513e0189647abfde9833e590,d564ffde5c832c46513e0189647abfde9833e590,Andrii Nakryiko,andrii@kernel.org,1712339769,Andrii Nakryiko,andrii@kernel.org,1712339944,654f4867da71174bdb8586e55af19feae16fd6f8,00d5d22a5b42c3ffdfd1b29526885bbcec2d2231 1bc724af00cc48ef03e3fa6d7a2f6731ac915c37,"Merge branch 'bpf-allow-invoking-kfuncs-from-bpf_prog_type_syscall-progs' + +David Vernet says: + +==================== +bpf: Allow invoking kfuncs from BPF_PROG_TYPE_SYSCALL progs + +Currently", a set of core BPF kfuncs (e.g. bpf_task_*,"[' bpf_cgroup_*', '\nbpf_cpumask_*', ' etc) cannot be invoked from BPF_PROG_TYPE_SYSCALL\nprograms. The whitelist approach taken for enabling kfuncs makes sense:\nit not safe to call these kfuncs from every program type. For example', '\nit may not be safe to call bpf_task_acquire() in an fentry to\nfree_task().\n\nBPF_PROG_TYPE_SYSCALL', ' on the other hand', ' is a perfectly safe program\ntype from which to invoke these kfuncs', "" as it's a very controlled\nenvironment"", ' and we should never be able to run into any of the typical\nproblems such as recursive invoations', ' acquiring references on freeing\nkptrs', ' etc. Being able to invoke these kfuncs would be useful', ' as\nBPF_PROG_TYPE_SYSCALL can be invoked with BPF_PROG_RUN', ' and would\ntherefore enable user space programs to synchronously call into BPF to\nmanipulate these kptrs.\n---\n\nv1: https://lore.kernel.org/all/20240404010308.334604-1-void@manifault.com/\nv1 -> v2:\n\n- Create new verifier_kfunc_prog_types testcase meant to specifically\n validate calling core kfuncs from various program types. Remove the\n macros and testcases that had been added to the task', ' cgrp', ' and\n cpumask kfunc testcases (Andrii and Yonghong)\n====================\n\nLink: https://lore.kernel.org/r/20240405143041.632519-1-void@manifault.com\nSigned-off-by: Andrii Nakryiko \n', '']",The commit enables invoking kfuncs from BPF_PROG_TYPE_SYSCALL programs.,"kfuncs,BPF_PROG_TYPE_SYSCALL,invoke",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"[""It's not related to any of the above.""]" +1bc724af00cc48ef03e3fa6d7a2f6731ac915c37,1bc724af00cc48ef03e3fa6d7a2f6731ac915c37,David Vernet,void@manifault.com,1712327441,Andrii Nakryiko,andrii@kernel.org,1712339890,654f4867da71174bdb8586e55af19feae16fd6f8,a8e03b6bbb2cc7cf387d1ce335e4ce4c3bdfef9b,"selftests/bpf: Verify calling core kfuncs from BPF_PROG_TYPE_SYCALL + +Now that we can call some kfuncs from BPF_PROG_TYPE_SYSCALL progs"," let's +add some selftests that verify as much. As a bonus","["" let's also verify\nthat we can't call the progs from raw tracepoints. Do do this"", ' we add a\nnew selftest suite called verifier_kfunc_prog_types.\n\nSigned-off-by: David Vernet \nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240405143041.632519-3-void@manifault.com\n', '']",Add selftests to verify calling core kfuncs from BPF_PROG_TYPE_SYSCALL programs.,"selftests,kfuncs,BPF_PROG_TYPE_SYSCALL",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a8e03b6bbb2cc7cf387d1ce335e4ce4c3bdfef9b,a8e03b6bbb2cc7cf387d1ce335e4ce4c3bdfef9b,David Vernet,void@manifault.com,1712327440,Andrii Nakryiko,andrii@kernel.org,1712339769,b3cc4c808a9367175e898d47b876ed5bddfc0298,00d5d22a5b42c3ffdfd1b29526885bbcec2d2231,"bpf: Allow invoking kfuncs from BPF_PROG_TYPE_SYSCALL progs + +Currently", a set of core BPF kfuncs (e.g. bpf_task_*,"[' bpf_cgroup_*', '\nbpf_cpumask_*', ' etc) cannot be invoked from BPF_PROG_TYPE_SYSCALL\nprograms. The whitelist approach taken for enabling kfuncs makes sense:\nit not safe to call these kfuncs from every program type. For example', '\nit may not be safe to call bpf_task_acquire() in an fentry to\nfree_task().\n\nBPF_PROG_TYPE_SYSCALL', ' on the other hand', ' is a perfectly safe program\ntype from which to invoke these kfuncs', "" as it's a very controlled\nenvironment"", ' and we should never be able to run into any of the typical\nproblems such as recursive invoations', ' acquiring references on freeing\nkptrs', ' etc. Being able to invoke these kfuncs would be useful', ' as\nBPF_PROG_TYPE_SYSCALL can be invoked with BPF_PROG_RUN', ' and would\ntherefore enable user space programs to synchronously call into BPF to\nmanipulate these kptrs.\n\nThis patch therefore enables invoking the aforementioned core kfuncs\nfrom BPF_PROG_TYPE_SYSCALL progs.\n\nSigned-off-by: David Vernet \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240405143041.632519-2-void@manifault.com\n', '']",Enable kfunc invocation from BPF_PROG_TYPE_SYSCALL programs in eBPF.,"kfuncs, BPF_PROG_TYPE_SYSCALL, eBPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"[""It's not related to any of the above.""]" +00d5d22a5b42c3ffdfd1b29526885bbcec2d2231,00d5d22a5b42c3ffdfd1b29526885bbcec2d2231,Dave Thaler,dthaler1968@googlemail.com,1712332365,Alexei Starovoitov,ast@kernel.org,1712338950,e7b4bef37d5c3d66752111b1b90c7e9654084cd3,ba0cbe2bb4ab8aa266e48c6399bebf6e1217828a,bpf," docs: Editorial nits in instruction-set.rst + +This patch addresses a number of editorial nits including +spelling","[' punctuation', ' grammar', ' and wording consistency issues\nin instruction-set.rst.\n\nSigned-off-by: Dave Thaler \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240405155245.3618-1-dthaler1968@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit addresses editorial nits and spelling corrections in the instruction-set documentation.,"editorial, nits, spelling",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +76cd338994778c552c51086fc056819b5cdda2e7,76cd338994778c552c51086fc056819b5cdda2e7,Björn Töpel,bjorn@rivosinc.com,1712320431,Alexei Starovoitov,ast@kernel.org,1712338497,eed5d82cd53ab9f7f535d373b5d993ecdd5b942b,cfddb048040b598fa7df0e51ca361289fc7abf28,"MAINTAINERS: bpf: Add Lehui and Puranjay as riscv64 reviewers + +Lehui and Puranjay have been active RISC-V 64-bit BPF JIT +contributors/reviewers for a long time! + +Let's make it more official by adding them as reviewers in +MAINTAINERS. + +Thank you for your hard work! + +Signed-off-by: Björn Töpel +Link: https://lore.kernel.org/r/20240405123352.2852393-1-bjorn@kernel.org +Signed-off-by: Alexei Starovoitov +",,The commit adds Lehui and Puranjay as official reviewers for the riscv64 BPF JIT in the MAINTAINERS file.,"MAINTAINERS, riscv64, reviewers",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +ba0cbe2bb4ab8aa266e48c6399bebf6e1217828a,ba0cbe2bb4ab8aa266e48c6399bebf6e1217828a,Kui-Feng Lee,thinker.li@gmail.com,1712273022,Andrii Nakryiko,andrii@kernel.org,1712338398,318c36052520f655e96c0b6391e27c75b3be39f1,270954791c706b133a03b01e4b2d063dc870f704,"selftests/bpf: Make sure libbpf doesn't enforce the signature of a func pointer. + +The verifier in the kernel ensures that the struct_ops operators behave +correctly by checking that they access parameters and context +appropriately. The verifier will approve a program as long as it correctly +accesses the context/parameters"," regardless of its function signature. In +contrast","[' libbpf should not verify the signature of function pointers and\nfunctions to enable flexibility in loading various implementations of an\noperator even if the signature of the function pointer does not match those\nin the implementations or the kernel.\n\nWith this flexibility', ' user space applications can adapt to different\nkernel versions by loading a specific implementation of an operator based\non feature detection.\n\nThis is a follow-up of the commit c911fc61a7ce (""libbpf: Skip zeroed or\nnull fields if not found in the kernel type."")\n\nSigned-off-by: Kui-Feng Lee \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240404232342.991414-1-thinker.li@gmail.com\n', '']",The commit ensures libbpf does not enforce function pointer signatures in selftests.,"libbpf,verifier,signature",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +270954791c706b133a03b01e4b2d063dc870f704,270954791c706b133a03b01e4b2d063dc870f704,Alexei Starovoitov,ast@kernel.org,1712338278,Alexei Starovoitov,ast@kernel.org,1712338278,bcbe65991403b2834a860dd962a1a13083b06f75,58babe27180c8d4cb54d831589cf801bd9268876 fecb1597cc11a23f32faa90d70a199533871686a,"Merge branch 'bpf-allow-bpf_for_each_map_elem-helper-with-different-input-maps' + +Philo Lu says: + +==================== +bpf: allow bpf_for_each_map_elem() helper with different input maps + +Currently"," taking different maps within a single bpf_for_each_map_elem +call is not allowed. For example the following codes cannot pass the +verifier (with error ""tail_call abusing map_ptr""): +``` +static void test_by_pid(int pid) +{ + if (pid <= 100) + bpf_for_each_map_elem(&map1","[' map_elem_cb', ' NULL', ' 0);\n\telse\n\t\tbpf_for_each_map_elem(&map2', ' map_elem_cb', ' NULL', ' 0);\n}\n```\n\nThis is because during bpf_for_each_map_elem verifying', '\nbpf_insn_aux_data->map_ptr_state is expected as map_ptr (instead of poison\nstate)', ' which is then needed by set_map_elem_callback_state. However', ' as\nthere are two different map ptr input', ' map_ptr_state is marked as\nBPF_MAP_PTR_POISON', ' and thus the second map_ptr would be lost.\nBPF_MAP_PTR_POISON is also needed by bpf_for_each_map_elem to skip\nretpoline optimization in do_misc_fixups(). Therefore', ' map_ptr_state and\nmap_ptr are both needed for bpf_for_each_map_elem.\n\nThis patchset solves it by transform bpf_insn_aux_data->map_ptr_state as a\nnew struct', ' storing poison/unpriv state and map pointer together without\nadditional memory overhead. Then bpf_for_each_map_elem works well with\ndifferent input maps. It also makes map_ptr_state logic clearer.\n\nA test case is added to selftest', ' which would fail to load without this\npatchset.\n\nChangelogs\n-> v1:\n- PATCH 1/3:\n - make the commit log clearer\n - change poison and unpriv to bool in struct bpf_map_ptr_state', ' also the\n return value in bpf_map_ptr_poisoned() and bpf_map_ptr_unpriv()\n- PATCH 2/3:\n - change the comments in set_map_elem_callback_state()\n- PATCH 3/3:\n - remove the ""skipping the last element"" logic during map updating\n - change if() to ASSERT_OK()\n\nPlease review', ' thanks.\n====================\n\nLink: https://lore.kernel.org/r/20240405025536.18113-1-lulie@linux.alibaba.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit allows the use of bpf_for_each_map_elem() with different input maps in eBPF programs.,"bpf, helper, maps",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fecb1597cc11a23f32faa90d70a199533871686a,fecb1597cc11a23f32faa90d70a199533871686a,Philo Lu,lulie@linux.alibaba.com,1712285736,Alexei Starovoitov,ast@kernel.org,1712338278,bcbe65991403b2834a860dd962a1a13083b06f75,9d482da9e17a4ddd5563428f74302a36b2610306,"selftests/bpf: add test for bpf_for_each_map_elem() with different maps + +A test is added for bpf_for_each_map_elem() with either an arraymap or a +hashmap. +$ tools/testing/selftests/bpf/test_progs -t for_each + #93/1 for_each/hash_map:OK + #93/2 for_each/array_map:OK + #93/3 for_each/write_map_key:OK + #93/4 for_each/multi_maps:OK + #93 for_each:OK +Summary: 1/4 PASSED", 0 SKIPPED,"[' 0 FAILED\n\nSigned-off-by: Philo Lu \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240405025536.18113-4-lulie@linux.alibaba.com\nSigned-off-by: Alexei Starovoitov \n', '']",Added selftests for bpf_for_each_map_elem() using arraymap and hashmap.,"selftests,arraymap,hashmap",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9d482da9e17a4ddd5563428f74302a36b2610306,9d482da9e17a4ddd5563428f74302a36b2610306,Philo Lu,lulie@linux.alibaba.com,1712285735,Alexei Starovoitov,ast@kernel.org,1712338277,daa373372a1c4edf856de49c047898273a7141f5,0a525621b7e5b49202b19d8f75382c6778fdd0c1,"bpf: allow invoking bpf_for_each_map_elem with different maps + +Taking different maps within a single bpf_for_each_map_elem call is not +allowed before", because from the second map,"['\nbpf_insn_aux_data->map_ptr_state will be marked as *poison*. In fact\nboth map_ptr and state are needed to support this use case: map_ptr is\nused by set_map_elem_callback_state() while poison state is needed to\ndetermine whether to use direct call.\n\nSigned-off-by: Philo Lu \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240405025536.18113-3-lulie@linux.alibaba.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit allows invoking bpf_for_each_map_elem with different maps within a single use.,"bpf,map,elements",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0a525621b7e5b49202b19d8f75382c6778fdd0c1,0a525621b7e5b49202b19d8f75382c6778fdd0c1,Philo Lu,lulie@linux.alibaba.com,1712285734,Alexei Starovoitov,ast@kernel.org,1712338277,15aca0b681bfa152ff7768390965942dcbe6026b,58babe27180c8d4cb54d831589cf801bd9268876,"bpf: store both map ptr and state in bpf_insn_aux_data + +Currently"," bpf_insn_aux_data->map_ptr_state is used to store either +map_ptr or its poison state (i.e.","[' BPF_MAP_PTR_POISON). Thus\nBPF_MAP_PTR_POISON must be checked before reading map_ptr. In certain\ncases', "" we may need valid map_ptr even in case of poison state.\nThis will be explained in next patch with bpf_for_each_map_elem()\nhelper.\n\nThis patch changes map_ptr_state into a new struct including both map\npointer and its state (poison/unpriv). It's in the same union with\nstruct bpf_loop_inline_state"", ' so there is no extra memory overhead.\nBesides', ' macros BPF_MAP_PTR_UNPRIV/BPF_MAP_PTR_POISON/BPF_MAP_PTR are no\nlonger needed.\n\nThis patch does not change any existing functionality.\n\nSigned-off-by: Philo Lu \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240405025536.18113-2-lulie@linux.alibaba.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit modifies bpf_insn_aux_data to store both map pointer and state.,"bpf, map_ptr, state",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +58babe27180c8d4cb54d831589cf801bd9268876,58babe27180c8d4cb54d831589cf801bd9268876,Arnd Bergmann,arnd@arndb.de,1712327185,Alexei Starovoitov,ast@kernel.org,1712331555,12f127e841b9ec5ed30394da5376a8952c08c489,343ca8131c35ba132d200fd9752b60e65357924d,"bpf: fix perf_snapshot_branch_stack link failure + +The newly added code to handle bpf_get_branch_snapshot fails to link when +CONFIG_PERF_EVENTS is disabled: + +aarch64-linux-ld: kernel/bpf/verifier.o: in function `do_misc_fixups': +verifier.c:(.text+0x1090c): undefined reference to `__SCK__perf_snapshot_branch_stack' + +Add a build-time check for that Kconfig symbol around the code to +remove the link time dependency. + +Fixes: 314a53623cd4 (""bpf: inline bpf_get_branch_snapshot() helper"") +Signed-off-by: Arnd Bergmann +Link: https://lore.kernel.org/r/20240405142637.577046-1-arnd@kernel.org +Signed-off-by: Alexei Starovoitov +",,Fixes a linking error for bpf_get_branch_snapshot when CONFIG_PERF_EVENTS is disabled by adding a build-time check.,"linking error, CONFIG_PERF_EVENTS, bpf_get_branch_snapshot",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cfddb048040b598fa7df0e51ca361289fc7abf28,cfddb048040b598fa7df0e51ca361289fc7abf28,Puranjay Mohan,puranjay@kernel.org,1712323417,Daniel Borkmann,daniel@iogearbox.net,1712324760,41e719e8b2ddcf955a0f2437001fdc0447975b3b,229087f6f1dc2d0c38feba805770f28529980ec0,"MAINTAINERS: Update email address for Puranjay Mohan + +I would like to use the kernel.org address for kernel development from +now on. + +Signed-off-by: Puranjay Mohan +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240405132337.71950-1-puranjay@kernel.org +",,Update email address for Puranjay Mohan in the MAINTAINERS file.,MAINTAINERS update email,It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +229087f6f1dc2d0c38feba805770f28529980ec0,229087f6f1dc2d0c38feba805770f28529980ec0,Andrii Nakryiko,andrii@kernel.org,1712268224,Daniel Borkmann,daniel@iogearbox.net,1712322767,a3b0f78be6342fe4393e4d345cbb0a2d282ead46,c88b9b4cde17aec34fb9bfaf69f9f72a1c44f511,bpf," kconfig: Fix DEBUG_INFO_BTF_MODULES Kconfig definition + +Turns out that due to CONFIG_DEBUG_INFO_BTF_MODULES not having an +explicitly specified ""menu item name"" in Kconfig","["" it's basically\nimpossible to turn it off (see [0]).\n\nThis patch fixes the issue by defining menu name for\nCONFIG_DEBUG_INFO_BTF_MODULES"", ' which makes it actually adjustable\nand independent of CONFIG_DEBUG_INFO_BTF', ' in the sense that one can\nhave DEBUG_INFO_BTF=y and DEBUG_INFO_BTF_MODULES=n.\n\nWe still keep it as defaulting to Y', ' of course.\n\nFixes: 5f9ae91f7c0d (""kbuild: Build kernel module BTFs if BTF is enabled and pahole supports it"")\nReported-by: Vincent Li \nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/CAK3+h2xiFfzQ9UXf56nrRRP=p1+iUxGoEP5B+aq9MDT5jLXDSg@mail.gmail.com [0]\nLink: https://lore.kernel.org/bpf/20240404220344.3879270-1-andrii@kernel.org\n', '']",Fixed the Kconfig definition by specifying the menu item name for CONFIG_DEBUG_INFO_BTF_MODULES.,"Kconfig, DEBUG_INFO_BTF_MODULES, fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"[""It's not related to any of the above.""]" +343ca8131c35ba132d200fd9752b60e65357924d,343ca8131c35ba132d200fd9752b60e65357924d,Andrii Nakryiko,andrii@kernel.org,1712267136,Alexei Starovoitov,ast@kernel.org,1712280668,46767f1cae8d92aea0b1492ceb2777d42fc872d9,1f2a74b41ea8b902687eb97c4e7e3f558801865b,"selftests/bpf: add fp-leaking precise subprog result tests + +Add selftests validating that BPF verifier handles precision marking +for SCALAR registers derived from r10 (fp) register correctly. + +Given `r0 = (s8)r10;` syntax is not supported by older Clang compilers"," +use the raw BPF instruction syntax to maximize compatibility. + +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240404214536.3551295-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add selftests to ensure BPF verifier handles precision for SCALAR registers from r10 correctly.,"selftests,BPF verifier,precision",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1f2a74b41ea8b902687eb97c4e7e3f558801865b,1f2a74b41ea8b902687eb97c4e7e3f558801865b,Andrii Nakryiko,andrii@kernel.org,1712267135,Alexei Starovoitov,ast@kernel.org,1712280668,118282cc4c739cc119bf3428482f8433f9b72317,f91717007217d975aa975ddabd91ae1a107b9bff,"bpf: prevent r10 register from being marked as precise + +r10 is a special register that is not under BPF program's control and is +always effectively precise. The rest of precision logic assumes that +only r0-r9 SCALAR registers are marked as precise"," so prevent r10 from +being marked precise. + +This can happen due to signed cast instruction allowing to do something +like `r0 = (s8)r10;`","[' which later', ' if r0 needs to be precise', ' would lead\nto an attempt to mark r10 as precise.\n\nPrevent this with an extra check during instruction backtracking.\n\nFixes: 8100928c8814 (""bpf: Support new sign-extension mov insns"")\nReported-by: syzbot+148110ee7cf72f39f33e@syzkaller.appspotmail.com\nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240404214536.3551295-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Prevent r10 register from being incorrectly marked as precise in BPF programs.,"r10, register, precise",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f91717007217d975aa975ddabd91ae1a107b9bff,f91717007217d975aa975ddabd91ae1a107b9bff,Anton Protopopov,aspsk@isovalent.com,1712147583,Andrii Nakryiko,andrii@kernel.org,1712271152,156eb293afe40bf820c53c5e9222db5a0f38844a,478a535ae54ad3831371904d93b5dfc403222e17,"bpf: Pack struct bpf_fib_lookup + +The struct bpf_fib_lookup is supposed to be of size 64. A recent commit +59b418c7063d (""bpf: Add a check for struct bpf_fib_lookup size"") added +a static assertion to check this property so that future changes to the +structure will not accidentally break this assumption. + +As it immediately turned out", on some 32-bit arm systems,"[' when AEABI=n', '\nthe total size of the structure was equal to 68', ' see [1]. This happened\nbecause the bpf_fib_lookup structure contains a union of two 16-bit\nfields:\n\n union {\n __u16 tot_len;\n __u16 mtu_result;\n };\n\nwhich was supposed to compile to a 16-bit-aligned 16-bit field. On the\naforementioned setups it was instead both aligned and padded to 32-bits.\n\nDeclare this inner union as __attribute__((packed', ' aligned(2))) such\nthat it always is of size 2 and is aligned to 16 bits.\n\n [1] https://lore.kernel.org/all/CA+G9fYtsoP51f-oP_Sp5MOq-Ffv8La2RztNpwvE6+R1VtFiLrw@mail.gmail.com/#t\n\nReported-by: Naresh Kamboju \nFixes: e1850ea9bd9e (""bpf: bpf_fib_lookup return MTU value as output when looked up"")\nSigned-off-by: Anton Protopopov \nSigned-off-by: Andrii Nakryiko \nReviewed-by: Alexander Lobakin \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240403123303.1452184-1-aspsk@isovalent.com\n', '']",The commit ensures that struct bpf_fib_lookup remains size 64 by packing it for compatibility with 32-bit systems.,"struct bpf_fib_lookup, size 64, pack",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['tc/netfilter like programs'] +478a535ae54ad3831371904d93b5dfc403222e17,478a535ae54ad3831371904d93b5dfc403222e17,Sahil Siddiq,icegambit91@gmail.com,1712258539,Andrii Nakryiko,andrii@kernel.org,1712270232,73d246fb5bb29edc494e747072af4ce36a4e22ff,d82c045f9dfde6b9ea220d7f8310c98210dfc8cb,"bpftool: Mount bpffs on provided dir instead of parent dir + +When pinning programs/objects under PATH (eg: during ""bpftool prog +loadall"") the bpffs is mounted on the parent dir of PATH in the +following situations: +- the given dir exists but it is not bpffs. +- the given dir doesn't exist and the parent dir is not bpffs. + +Mounting on the parent dir can also have the unintentional side- +effect of hiding other files located under the parent dir. + +If the given dir exists but is not bpffs"," then the bpffs should +be mounted on the given dir and not its parent dir. + +Similarly","["" if the given dir doesn't exist and its parent dir is not\nbpffs"", ' then the given dir should be created and the bpffs should be\nmounted on this new dir.\n\nFixes: 2a36c26fe3b8 (""bpftool: Support bpffs mountpoint as pin path for prog loadall"")\nSigned-off-by: Sahil Siddiq \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/2da44d24-74ae-a564-1764-afccf395eeec@isovalent.com/T/#t\nLink: https://lore.kernel.org/bpf/20240404192219.52373-1-icegambit91@gmail.com\n\nCloses: https://github.com/libbpf/bpftool/issues/100\n\nChanges since v1:\n - Split ""mount_bpffs_for_pin"" into two functions.\n This is done to improve maintainability and readability.\n\nChanges since v2:\n- mount_bpffs_for_pin: rename to ""create_and_mount_bpffs_dir"".\n- mount_bpffs_given_file: rename to ""mount_bpffs_given_file"".\n- create_and_mount_bpffs_dir:\n - introduce ""dir_exists"" boolean.\n - remove new dir if ""mnt_fs"" fails.\n- improve error handling and error messages.\n\nChanges since v3:\n- Rectify function name.\n- Improve error messages and formatting.\n- mount_bpffs_for_file:\n - Check if dir exists before block_mount check.\n\nChanges since v4:\n- Use strdup instead of strcpy.\n- create_and_mount_bpffs_dir:\n - Use S_IRWXU instead of 0700.\n- Improve error handling and formatting.\n', '']",Modified bpftool to mount bpffs on the provided directory instead of the parent directory when pinning programs.,"bpftool, mount, bpffs",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"['xdp like programs', 'socket like programs', 'cgroup like programs']" +c88b9b4cde17aec34fb9bfaf69f9f72a1c44f511,c88b9b4cde17aec34fb9bfaf69f9f72a1c44f511,Linus Torvalds,torvalds@linux-foundation.org,1712267350,Linus Torvalds,torvalds@linux-foundation.org,1712267350,fd9527e34d0243438825ab67116b33bdbf0f8ca2,ec25bd8d981d910cdcc84914bf57e2cff9e7d63b 1cfa2f10f4e90a353c3ee2150866b4cf72579153,"Merge tag 'net-6.9-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + ""Including fixes from netfilter"," bluetooth and bpf. + + Fairly usual collection of driver and core fixes. The large selftest + accompanying one of the fixes is also becoming a common occurrence. + + Current release - regressions: + + - ipv6: fix infinite recursion in fib6_dump_done() + + - net/rds: fix possible null-deref in newly added error path + + Current release - new code bugs: + + - net: do not consume a full cacheline for system_page_pool + + - bpf: fix bpf_arena-related file descriptor leaks in the verifier + + - drv: ice: fix freeing uninitialized pointers","[' fixing misuse of the\n newfangled __free() auto-cleanup\n\n Previous releases - regressions:\n\n - x86/bpf: fixes the BPF JIT with retbleed=stuff\n\n - xen-netfront: add missing skb_mark_for_recycle', ' fix page pool\n accounting leaks', ' revealed by recently added explicit warning\n\n - tcp: fix bind() regression for v6-only wildcard and v4-mapped-v6\n non-wildcard addresses\n\n - Bluetooth:\n - replace ""hci_qca: Set BDA quirk bit if fwnode exists in DT"" with\n better workarounds to un-break some buggy Qualcomm devices\n - set conn encrypted before conn establishes', "" fix re-connecting to\n some headsets which use slightly unusual sequence of msgs\n\n - mptcp:\n - prevent BPF accessing lowat from a subflow socket\n - don't account accept() of non-MPC client as fallback to TCP\n\n - drv: mana: fix Rx DMA datasize and skb_over_panic\n\n - drv: i40e: fix VF MAC filter removal\n\n Previous releases - always broken:\n\n - gro: various fixes related to UDP tunnels - netns crossing\n problems"", ' incorrect checksum conversions', ' and incorrect packet\n transformations which may lead to panics\n\n - bpf: support deferring bpf_link dealloc to after RCU grace period\n\n - nf_tables:\n - release batch on table validation from abort path\n - release mutex after nft_gc_seq_end from abort path\n - flush pending destroy work before exit_net release\n\n - drv: r8169: skip DASH fw status checks when DASH is disabled""\n\n* tag \'net-6.9-rc3\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (81 commits)\n netfilter: validate user input for expected length\n net/sched: act_skbmod: prevent kernel-infoleak\n net: usb: ax88179_178a: avoid the interface always configured as random address\n net: dsa: sja1105: Fix parameters order in sja1110_pcs_mdio_write_c45()\n net: ravb: Always update error counters\n net: ravb: Always process TX descriptor ring\n netfilter: nf_tables: discard table flag update with pending basechain deletion\n netfilter: nf_tables: Fix potential data-race in __nft_flowtable_type_get()\n netfilter: nf_tables: reject new basechain after table flag update\n netfilter: nf_tables: flush pending destroy work before exit_net release\n netfilter: nf_tables: release mutex after nft_gc_seq_end from abort path\n netfilter: nf_tables: release batch on table validation from abort path\n Revert ""tg3: Remove residual error handling in tg3_suspend""\n tg3: Remove residual error handling in tg3_suspend\n net: mana: Fix Rx DMA datasize and skb_over_panic\n net/sched: fix lockdep splat in qdisc_tree_reduce_backlog()\n net: phy: micrel: lan8814: Fix when enabling/disabling 1-step timestamping\n net: stmmac: fix rx queue priority assignment\n net: txgbe: fix i2c dev name cannot match clkdev\n net: fec: Set mac_managed_pm during probe\n ...\n', '']","Merge networking fixes including netfilter and driver core issues for ipv6, net, bpf, and ice.","networking, netfilter, bpf",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d82c045f9dfde6b9ea220d7f8310c98210dfc8cb,d82c045f9dfde6b9ea220d7f8310c98210dfc8cb,Alexei Starovoitov,ast@kernel.org,1712261281,Alexei Starovoitov,ast@kernel.org,1712261281,05376a14c790f914df2197a0431c3608ac025e66,21ab0b6d0cfcb8aa98e33baa83f933f963514027 314a53623cd4e62e1b88126e5ed2bc87073d90ee,"Merge branch 'inline-bpf_get_branch_snapshot-bpf-helper' + +Andrii Nakryiko says: + +==================== +Inline bpf_get_branch_snapshot() BPF helper + +Implement inlining of bpf_get_branch_snapshot() BPF helper using generic BPF +assembly approach. This allows to reduce LBR record usage right before LBR +records are captured from inside BPF program. + +See v1 cover letter ([0]) for some visual examples. I dropped them from v2 +because there are multiple independent changes landing and being reviewed"," all +of which remove different parts of LBR record waste","[' so presenting final state\nof LBR ""waste"" gets more complicated until all of the pieces land.\n\n [0] https://lore.kernel.org/bpf/20240321180501.734779-1-andrii@kernel.org/\n\nv2->v3:\n - fix BPF_MUL instruction definition;\nv1->v2:\n - inlining of bpf_get_smp_processor_id() split out into a separate patch set\n implementing internal per-CPU BPF instruction;\n - add efficient divide-by-24 through multiplication logic', ' and leave\n comments to explain the idea behind it; this way inlined version of\n bpf_get_branch_snapshot() has no compromises compared to non-inlined\n version of the helper (Alexei).\n====================\n\nLink: https://lore.kernel.org/r/20240404002640.1774210-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit merges inline implementation of bpf_get_branch_snapshot BPF helper to optimize LBR record usage in BPF programs.,"inline, BPF helper, LBR",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +314a53623cd4e62e1b88126e5ed2bc87073d90ee,314a53623cd4e62e1b88126e5ed2bc87073d90ee,Andrii Nakryiko,andrii@kernel.org,1712190400,Alexei Starovoitov,ast@kernel.org,1712261281,05376a14c790f914df2197a0431c3608ac025e66,5e6a3c1ee693da1793739bb378b224bcf33d7f14,"bpf: inline bpf_get_branch_snapshot() helper + +Inline bpf_get_branch_snapshot() helper using architecture-agnostic +inline BPF code which calls directly into underlying callback of +perf_snapshot_branch_stack static call. This callback is set early +during kernel initialization and is never updated or reset"," so it's ok +to fetch actual implementation using static_call_query() and call +directly into it. + +This change eliminates a full function call and saves one LBR entry +in PERF_SAMPLE_BRANCH_ANY LBR mode. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240404002640.1774210-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Inline bpf_get_branch_snapshot() helper to improve performance by reducing function calls and saving LBR entries.,inline helper performance,It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', ""It's not related to any of the above.""]" +5e6a3c1ee693da1793739bb378b224bcf33d7f14,5e6a3c1ee693da1793739bb378b224bcf33d7f14,Andrii Nakryiko,andrii@kernel.org,1712190399,Alexei Starovoitov,ast@kernel.org,1712261281,5d002e2fc869c08b88a93da73a604dbab6907ef1,21ab0b6d0cfcb8aa98e33baa83f933f963514027,"bpf: make bpf_get_branch_snapshot() architecture-agnostic + +perf_snapshot_branch_stack is set up in an architecture-agnostic way"," so +there is no reason for BPF subsystem to keep track of which +architectures do support LBR or not. E.g.","[' it looks like ARM64 might soon\nget support for BRBE ([0])', ' which (with proper integration) should be\npossible to utilize using this BPF helper.\n\nperf_snapshot_branch_stack static call will point to\n__static_call_return0() by default', ' which just returns zero', ' which will\nlead to -ENOENT', ' as expected. So no need to guard anything here.\n\n [0] https://lore.kernel.org/linux-arm-kernel/20240125094119.2542332-1-anshuman.khandual@arm.com/\n\nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240404002640.1774210-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']","The commit refactors bpf_get_branch_snapshot to be architecture-agnostic, eliminating architecture-specific tracking for LBR support.","architecture-agnostic, bpf_get_branch_snapshot, LBR",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1cfa2f10f4e90a353c3ee2150866b4cf72579153,1cfa2f10f4e90a353c3ee2150866b4cf72579153,Jakub Kicinski,kuba@kernel.org,1712255859,Jakub Kicinski,kuba@kernel.org,1712255859,387d095e70156ded683464f08e33c7c0f8f876d8,0c83842df40f86e529db6842231154772c20edcc ff91059932401894e6c86341915615c5eb0eca48,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-04-04 + +We've added 7 non-merge commits during the last 5 day(s) which contain +a total of 9 files changed", 75 insertions(+),"[' 24 deletions(-).\n\nThe main changes are:\n\n1) Fix x86 BPF JIT under retbleed=stuff which causes kernel panics due to\n incorrect destination IP calculation and incorrect IP for relocations', '\n from Uros Bizjak and Joan Bruguera Micó.\n\n2) Fix BPF arena file descriptor leaks in the verifier', '\n from Anton Protopopov.\n\n3) Defer bpf_link deallocation to after RCU grace period as currently\n running multi-{kprobes', 'uprobes} programs might still access cookie\n information from the link', ' from Andrii Nakryiko.\n\n4) Fix a BPF sockmap lock inversion deadlock in map_delete_elem reported\n by syzkaller', ' from Jakub Sitnicki.\n\n5) Fix resolve_btfids build with musl libc due to missing linux/types.h\n include', "" from Natanael Copa.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n bpf"", "" sockmap: Prevent lock inversion deadlock in map delete elem\n x86/bpf: Fix IP for relocating call depth accounting\n x86/bpf: Fix IP after emitting call depth accounting\n bpf: fix possible file descriptor leaks in verifier\n tools/resolve_btfids: fix build with musl libc\n bpf: support deferring bpf_link dealloc to after RCU grace period\n bpf: put uprobe link's path and task in release callback\n====================\n\nLink: https://lore.kernel.org/r/20240404183258.4401-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n"", '']",This commit merges the 'for-netdev' branch from the BPF repository into the mainline.,"merge, netdev, bpf",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0c83842df40f86e529db6842231154772c20edcc,0c83842df40f86e529db6842231154772c20edcc,Eric Dumazet,edumazet@google.com,1712233251,Jakub Kicinski,kuba@kernel.org,1712248792,48a6e18f96fa362df778181e8ba0258bb1df5663,d432f7bdc1cddd37e73dbe6b53b48785ab789e92,"netfilter: validate user input for expected length + +I got multiple syzbot reports showing old bugs exposed +by BPF after commit 20f2505fb436 (""bpf: Try to avoid kzalloc +in cgroup/{s","g}etsockopt"") + +setsockopt() @optlen argument should be taken into account +before copying data. + + BUG: KASAN: slab-out-of-bounds in copy_from_sockptr_offset include/linux/sockptr.h:49 [inline] + BUG: KASAN: slab-out-of-bounds in copy_from_sockptr include/linux/sockptr.h:55 [inline] + BUG: KASAN: slab-out-of-bounds in do_replace net/ipv4/netfilter/ip_tables.c:1111 [inline] + BUG: KASAN: slab-out-of-bounds in do_ipt_set_ctl+0x902/0x3dd0 net/ipv4/netfilter/ip_tables.c:1627 +Read of size 96 at addr ffff88802cd73da0 by task syz-executor.4/7238 + +CPU: 1 PID: 7238 Comm: syz-executor.4 Not tainted 6.9.0-rc2-next-20240403-syzkaller #0 +Hardware name: Google Google Compute Engine/Google Compute Engine","[' BIOS Google 03/27/2024\nCall Trace:\n \n __dump_stack lib/dump_stack.c:88 [inline]\n dump_stack_lvl+0x241/0x360 lib/dump_stack.c:114\n print_address_description mm/kasan/report.c:377 [inline]\n print_report+0x169/0x550 mm/kasan/report.c:488\n kasan_report+0x143/0x180 mm/kasan/report.c:601\n kasan_check_range+0x282/0x290 mm/kasan/generic.c:189\n __asan_memcpy+0x29/0x70 mm/kasan/shadow.c:105\n copy_from_sockptr_offset include/linux/sockptr.h:49 [inline]\n copy_from_sockptr include/linux/sockptr.h:55 [inline]\n do_replace net/ipv4/netfilter/ip_tables.c:1111 [inline]\n do_ipt_set_ctl+0x902/0x3dd0 net/ipv4/netfilter/ip_tables.c:1627\n nf_setsockopt+0x295/0x2c0 net/netfilter/nf_sockopt.c:101\n do_sock_setsockopt+0x3af/0x720 net/socket.c:2311\n __sys_setsockopt+0x1ae/0x250 net/socket.c:2334\n __do_sys_setsockopt net/socket.c:2343 [inline]\n __se_sys_setsockopt net/socket.c:2340 [inline]\n __x64_sys_setsockopt+0xb5/0xd0 net/socket.c:2340\n do_syscall_64+0xfb/0x240\n entry_SYSCALL_64_after_hwframe+0x72/0x7a\nRIP: 0033:0x7fd22067dde9\nCode: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48\nRSP: 002b:00007fd21f9ff0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000036\nRAX: ffffffffffffffda RBX: 00007fd2207abf80 RCX: 00007fd22067dde9\nRDX: 0000000000000040 RSI: 0000000000000000 RDI: 0000000000000003\nRBP: 00007fd2206ca47a R08: 0000000000000001 R09: 0000000000000000\nR10: 0000000020000880 R11: 0000000000000246 R12: 0000000000000000\nR13: 000000000000000b R14: 00007fd2207abf80 R15: 00007ffd2d0170d8\n \n\nAllocated by task 7238:\n kasan_save_stack mm/kasan/common.c:47 [inline]\n kasan_save_track+0x3f/0x80 mm/kasan/common.c:68\n poison_kmalloc_redzone mm/kasan/common.c:370 [inline]\n __kasan_kmalloc+0x98/0xb0 mm/kasan/common.c:387\n kasan_kmalloc include/linux/kasan.h:211 [inline]\n __do_kmalloc_node mm/slub.c:4069 [inline]\n __kmalloc_noprof+0x200/0x410 mm/slub.c:4082\n kmalloc_noprof include/linux/slab.h:664 [inline]\n __cgroup_bpf_run_filter_setsockopt+0xd47/0x1050 kernel/bpf/cgroup.c:1869\n do_sock_setsockopt+0x6b4/0x720 net/socket.c:2293\n __sys_setsockopt+0x1ae/0x250 net/socket.c:2334\n __do_sys_setsockopt net/socket.c:2343 [inline]\n __se_sys_setsockopt net/socket.c:2340 [inline]\n __x64_sys_setsockopt+0xb5/0xd0 net/socket.c:2340\n do_syscall_64+0xfb/0x240\n entry_SYSCALL_64_after_hwframe+0x72/0x7a\n\nThe buggy address belongs to the object at ffff88802cd73da0\n which belongs to the cache kmalloc-8 of size 8\nThe buggy address is located 0 bytes inside of\n allocated 1-byte region [ffff88802cd73da0', ' ffff88802cd73da1)\n\nThe buggy address belongs to the physical page:\npage: refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff88802cd73020 pfn:0x2cd73\nflags: 0xfff80000000000(node=0|zone=1|lastcpupid=0xfff)\npage_type: 0xffffefff(slab)\nraw: 00fff80000000000 ffff888015041280 dead000000000100 dead000000000122\nraw: ffff88802cd73020 000000008080007f 00000001ffffefff 0000000000000000\npage dumped because: kasan: bad access detected\npage_owner tracks the page as allocated\npage last allocated via order 0', ' migratetype Unmovable', ' gfp_mask 0x12cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY)', ' pid 5103', ' tgid 2119833701 (syz-executor.4)', ' ts 5103', ' free_ts 70804600828\n set_page_owner include/linux/page_owner.h:32 [inline]\n post_alloc_hook+0x1f3/0x230 mm/page_alloc.c:1490\n prep_new_page mm/page_alloc.c:1498 [inline]\n get_page_from_freelist+0x2e7e/0x2f40 mm/page_alloc.c:3454\n __alloc_pages_noprof+0x256/0x6c0 mm/page_alloc.c:4712\n __alloc_pages_node_noprof include/linux/gfp.h:244 [inline]\n alloc_pages_node_noprof include/linux/gfp.h:271 [inline]\n alloc_slab_page+0x5f/0x120 mm/slub.c:2249\n allocate_slab+0x5a/0x2e0 mm/slub.c:2412\n new_slab mm/slub.c:2465 [inline]\n ___slab_alloc+0xcd1/0x14b0 mm/slub.c:3615\n __slab_alloc+0x58/0xa0 mm/slub.c:3705\n __slab_alloc_node mm/slub.c:3758 [inline]\n slab_alloc_node mm/slub.c:3936 [inline]\n __do_kmalloc_node mm/slub.c:4068 [inline]\n kmalloc_node_track_caller_noprof+0x286/0x450 mm/slub.c:4089\n kstrdup+0x3a/0x80 mm/util.c:62\n device_rename+0xb5/0x1b0 drivers/base/core.c:4558\n dev_change_name+0x275/0x860 net/core/dev.c:1232\n do_setlink+0xa4b/0x41f0 net/core/rtnetlink.c:2864\n __rtnl_newlink net/core/rtnetlink.c:3680 [inline]\n rtnl_newlink+0x180b/0x20a0 net/core/rtnetlink.c:3727\n rtnetlink_rcv_msg+0x89b/0x10d0 net/core/rtnetlink.c:6594\n netlink_rcv_skb+0x1e3/0x430 net/netlink/af_netlink.c:2559\n netlink_unicast_kernel net/netlink/af_netlink.c:1335 [inline]\n netlink_unicast+0x7ea/0x980 net/netlink/af_netlink.c:1361\npage last free pid 5146 tgid 5146 stack trace:\n reset_page_owner include/linux/page_owner.h:25 [inline]\n free_pages_prepare mm/page_alloc.c:1110 [inline]\n free_unref_page+0xd3c/0xec0 mm/page_alloc.c:2617\n discard_slab mm/slub.c:2511 [inline]\n __put_partials+0xeb/0x130 mm/slub.c:2980\n put_cpu_partial+0x17c/0x250 mm/slub.c:3055\n __slab_free+0x2ea/0x3d0 mm/slub.c:4254\n qlink_free mm/kasan/quarantine.c:163 [inline]\n qlist_free_all+0x9e/0x140 mm/kasan/quarantine.c:179\n kasan_quarantine_reduce+0x14f/0x170 mm/kasan/quarantine.c:286\n __kasan_slab_alloc+0x23/0x80 mm/kasan/common.c:322\n kasan_slab_alloc include/linux/kasan.h:201 [inline]\n slab_post_alloc_hook mm/slub.c:3888 [inline]\n slab_alloc_node mm/slub.c:3948 [inline]\n __do_kmalloc_node mm/slub.c:4068 [inline]\n __kmalloc_node_noprof+0x1d7/0x450 mm/slub.c:4076\n kmalloc_node_noprof include/linux/slab.h:681 [inline]\n kvmalloc_node_noprof+0x72/0x190 mm/util.c:634\n bucket_table_alloc lib/rhashtable.c:186 [inline]\n rhashtable_rehash_alloc+0x9e/0x290 lib/rhashtable.c:367\n rht_deferred_worker+0x4e1/0x2440 lib/rhashtable.c:427\n process_one_work kernel/workqueue.c:3218 [inline]\n process_scheduled_works+0xa2c/0x1830 kernel/workqueue.c:3299\n worker_thread+0x86d/0xd70 kernel/workqueue.c:3380\n kthread+0x2f0/0x390 kernel/kthread.c:388\n ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147\n ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:243\n\nMemory state around the buggy address:\n ffff88802cd73c80: 07 fc fc fc 05 fc fc fc 05 fc fc fc fa fc fc fc\n ffff88802cd73d00: fa fc fc fc fa fc fc fc fa fc fc fc fa fc fc fc\n>ffff88802cd73d80: fa fc fc fc 01 fc fc fc fa fc fc fc fa fc fc fc\n ^\n ffff88802cd73e00: fa fc fc fc fa fc fc fc 05 fc fc fc 07 fc fc fc\n ffff88802cd73e80: 07 fc fc fc 07 fc fc fc 07 fc fc fc 07 fc fc fc\n\nFixes: 1da177e4c3f4 (""Linux-2.6.12-rc2"")\nReported-by: syzbot \nSigned-off-by: Eric Dumazet \nReviewed-by: Pablo Neira Ayuso \nLink: https://lore.kernel.org/r/20240404122051.2303764-1-edumazet@google.com\nSigned-off-by: Jakub Kicinski \n', '']",This commit adds validation for user input length in the netfilter to prevent buffer overflows.,"netfilter,validation,buffer overflow",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.",['other'] +21ab0b6d0cfcb8aa98e33baa83f933f963514027,21ab0b6d0cfcb8aa98e33baa83f933f963514027,Puranjay Mohan,puranjay12@gmail.com,1712230923,Daniel Borkmann,daniel@iogearbox.net,1712242122,95efbd4fc58efc0831780ed0dd79305f136e4375,633a6e01d1a20b24a16899094c249a8cb2aad4b2,bpf," riscv: Implement bpf_addr_space_cast instruction + +LLVM generates bpf_addr_space_cast instruction while translating +pointers between native (zero) address space and +__attribute__((address_space(N))). The addr_space=0 is reserved as +bpf_arena address space. + +rY = addr_space_cast(rX","[' 0', ' 1) is processed by the verifier and\nconverted to normal 32-bit move: wX = wY\n\nrY = addr_space_cast(rX', ' 1', ' 0) has to be converted by JIT.\n\nSigned-off-by: Puranjay Mohan \nSigned-off-by: Daniel Borkmann \nTested-by: Björn Töpel \nTested-by: Pu Lehui \nReviewed-by: Pu Lehui \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240404114203.105970-3-puranjay12@gmail.com\n', '']",Implement bpf_addr_space_cast instruction for RISC-V in LLVM for handling address space translations.,"bpf, addr_space_cast, RISC-V",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +633a6e01d1a20b24a16899094c249a8cb2aad4b2,633a6e01d1a20b24a16899094c249a8cb2aad4b2,Puranjay Mohan,puranjay12@gmail.com,1712230922,Daniel Borkmann,daniel@iogearbox.net,1712242090,8dee43335ab942606e838b9e70beb506ec85ace1,af682b767a41772499f8e54ca7d7e1deb3395f44,bpf," riscv: Implement PROBE_MEM32 pseudo instructions + +Add support for [LDX | STX | ST]","[' PROBE_MEM32', ' [B | H | W | DW]\ninstructions. They are similar to PROBE_MEM instructions with the\nfollowing differences:\n\n- PROBE_MEM32 supports store.\n- PROBE_MEM32 relies on the verifier to clear upper 32-bit of the\n src/dst register\n- PROBE_MEM32 adds 64-bit kern_vm_start address (which is stored in S7\n in the prologue). Due to bpf_arena constructions such S7 + reg +\n off16 access is guaranteed to be within arena virtual range', ' so no\n address check at run-time.\n- S11 is a free callee-saved register', ' so it is used to store kern_vm_start\n- PROBE_MEM32 allows STX and ST. If they fault the store is a nop. When\n LDX faults the destination register is zeroed.\n\nTo support these on riscv', ' we do tmp = S7 + src/dst reg and then use\ntmp2 as the new src/dst register. This allows us to reuse most of the\ncode for normal [LDX | STX | ST].\n\nSigned-off-by: Puranjay Mohan \nSigned-off-by: Daniel Borkmann \nTested-by: Björn Töpel \nTested-by: Pu Lehui \nReviewed-by: Pu Lehui \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240404114203.105970-2-puranjay12@gmail.com\n', '']",Implement PROBE_MEM32 pseudo instructions for riscv architecture in bpf.,"riscv, PROBE_MEM32, pseudo",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +af682b767a41772499f8e54ca7d7e1deb3395f44,af682b767a41772499f8e54ca7d7e1deb3395f44,Alexei Starovoitov,ast@kernel.org,1712014680,Daniel Borkmann,daniel@iogearbox.net,1712240006,6d1b833f7a32bae58032ff46b09ffea035ef5147,1e9e0b85255e6eca6036b59d8a5fbca6501905ac,"bpf: Optimize emit_mov_imm64(). + +Turned out that bpf prog callback addresses"," bpf prog addresses +used in bpf_trampoline","[' and in other cases the 64-bit address\ncan be represented as sign extended 32-bit value.\n\nAccording to https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82339\n""Skylake has 0.64c throughput for mov r64', ' imm64', ' vs. 0.25 for mov r32', ' imm32.""\nSo use shorter encoding and faster instruction when possible.\n\nSpecial care is needed in jit_subprogs()', ' since bpf_pseudo_func()\ninstruction cannot change its size during the last step of JIT.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/CAADnVQKFfpY-QZBrOU2CG8v2du8Lgyb7MNVmOZVK_yTyOdNbBA@mail.gmail.com\nLink: https://lore.kernel.org/bpf/20240401233800.42737-1-alexei.starovoitov@gmail.com\n', '']",Optimize bpf_trampoline by improving emit_mov_imm64 function for bpf prog callback addresses.,"Optimize, emit_mov_imm64, bpf_trampoline",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1e9e0b85255e6eca6036b59d8a5fbca6501905ac,1e9e0b85255e6eca6036b59d8a5fbca6501905ac,Andrii Nakryiko,andrii@kernel.org,1712202446,Alexei Starovoitov,ast@kernel.org,1712205395,0b90da08e9a36a61517c7e31b761e140234e82b7,519e1de94b719f741e0de42b085b9a4551c5b15c,"bpf: handle CONFIG_SMP=n configuration in x86 BPF JIT + +On non-SMP systems"," there is no ""per-CPU"" data","[' it\'s just global data.\nSo in such case just don\'t do this_cpu_off-based per-CPU address adjustment.\n\nReported-by: kernel test robot \nCloses: https://lore.kernel.org/oe-kbuild-all/202404040951.d4CUx5S6-lkp@intel.com/\nFixes: 7bdbf7446305 (""bpf: add special internal-only MOV instruction to resolve per-CPU addrs"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240404034726.2766740-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fix handling of per-CPU data in the x86 BPF JIT for non-SMP systems.,"x86, BPF JIT, non-SMP",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4793cb599b1bdc3d356f0374c2c99ffe890ae876,4793cb599b1bdc3d356f0374c2c99ffe890ae876,Tianchen Ding,dtcccc@linux.alibaba.com,1711507477,Tejun Heo,tj@kernel.org,1712173333,9c3e0e58082806555b2a4cf7afa69cdaaa5f825e,20d46283f5d679338ec2bbd734f46f900557fb97,"selftests: cgroup: skip test_cgcore_lesser_ns_open when cgroup2 mounted without nsdelegate + +The test case test_cgcore_lesser_ns_open only tasks effect when cgroup2 +is mounted with ""nsdelegate"" mount option. If it misses this option"," or +is remounted without ""nsdelegate""","[' the test case will fail. For example', '\nrunning bpf/test_cgroup_storage first', ' and then run cgroup/test_core will\nfail on test_cgcore_lesser_ns_open. Skip it if ""nsdelegate"" is not\ndetected in cgroup2 mount options.\n\nFixes: bf35a7879f1d (""selftests: cgroup: Test open-time cgroup namespace usage for migration checks"")\nSigned-off-by: Tianchen Ding \nReviewed-by: Muhammad Usama Anjum \nSigned-off-by: Tejun Heo \n', '']",Skip test_cgcore_lesser_ns_open if cgroup2 is mounted without nsdelegate.,"skip,cgroup2,nsdelegate",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['cgroup like programs'] +519e1de94b719f741e0de42b085b9a4551c5b15c,519e1de94b719f741e0de42b085b9a4551c5b15c,Alexei Starovoitov,ast@kernel.org,1712165396,Alexei Starovoitov,ast@kernel.org,1712165413,d854878120567fc94dbc26d31c8238caffe88c2a,2e114248e086fb376405ed3f89b220f8586a2541 0b56e637f705836b9aa51e2b1058c3c814c121a8,"Merge branch 'add-internal-only-bpf-per-cpu-instruction' + +Andrii Nakryiko says: + +==================== +Add internal-only BPF per-CPU instruction + +Add a new BPF instruction for resolving per-CPU memory addresses. + +New instruction is a special form of BPF_ALU64 | BPF_MOV | BPF_X"," with +insns->off set to BPF_ADDR_PERCPU (== -1). It resolves provided per-CPU offset +to an absolute address where per-CPU data resides for ""this"" CPU. + +This patch set implements support for it in x86-64 BPF JIT only. + +Using the new instruction","[' we also implement inlining for three cases:\n - bpf_get_smp_processor_id()', ' which allows to avoid unnecessary trivial\n function call', "" saving a bit of performance and also not polluting LBR\n records with unnecessary function call/return records;\n - PERCPU_ARRAY's bpf_map_lookup_elem() is completely inlined"", ' bringing its\n performance to implementing per-CPU data structures using global variables\n in BPF (which is an awesome improvement', "" see benchmarks below);\n - PERCPU_HASH's bpf_map_lookup_elem() is partially inlined"", ' just like the\n same for non-PERCPU HASH map; this still saves a bit of overhead.\n\nTo validate performance benefits', ' I hacked together a tiny benchmark doing\nonly bpf_map_lookup_elem() and incrementing the value by 1 for PERCPU_ARRAY\n(arr-inc benchmark below) and PERCPU_HASH (hash-inc benchmark below) maps. To\nestablish a baseline', ' I also implemented logic similar to PERCPU_ARRAY based\non global variable array using bpf_get_smp_processor_id() to index array for\ncurrent CPU (glob-arr-inc benchmark below).\n\nBEFORE\n======\nglob-arr-inc : 163.685 ± 0.092M/s\narr-inc : 138.096 ± 0.160M/s\nhash-inc : 66.855 ± 0.123M/s\n\nAFTER\n=====\nglob-arr-inc : 173.921 ± 0.039M/s (+6%)\narr-inc : 170.729 ± 0.210M/s (+23.7%)\nhash-inc : 68.673 ± 0.070M/s (+2.7%)\n\nAs can be seen', ' PERCPU_HASH gets a modest +2.7% improvement', "" while global\narray-based gets a nice +6% due to inlining of bpf_get_smp_processor_id().\n\nBut what's really important is that arr-inc benchmark basically catches up\nwith glob-arr-inc"", "" resulting in +23.7% improvement. This means that in\npractice it won't be necessary to avoid PERCPU_ARRAY anymore if performance is\ncritical (e.g."", ' high-frequent stats collection', ' which is often a practical use\nfor PERCPU_ARRAY today).\n\nv1->v2:\n - use BPF_ALU64 | BPF_MOV instruction instead of LDX (Alexei);\n - dropped the direct per-CPU memory read instruction', ' it can always be added\n back', ' if necessary;\n - guarded bpf_get_smp_processor_id() behind x86-64 check (Alexei);\n - switched all per-cpu addr casts to (unsigned long) to avoid sparse\n warnings.\n====================\n\nLink: https://lore.kernel.org/r/20240402021307.1012571-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added an internal-only BPF instruction for resolving per-CPU memory addresses in x86-64 BPF JIT.,"BPF instruction, per-CPU address, x86-64 JIT",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0b56e637f705836b9aa51e2b1058c3c814c121a8,0b56e637f705836b9aa51e2b1058c3c814c121a8,Andrii Nakryiko,andrii@kernel.org,1712023985,Alexei Starovoitov,ast@kernel.org,1712165396,d854878120567fc94dbc26d31c8238caffe88c2a,db69718b8efac802c7cc20d5a6c7dfc913f99c43,"bpf: inline bpf_map_lookup_elem() helper for PERCPU_HASH map + +Using new per-CPU BPF instruction"," partially inline +bpf_map_lookup_elem() helper for per-CPU hashmap BPF map. Just like for +normal HASH map","[' we still generate a call into __htab_map_lookup_elem()', '\nbut after that we resolve per-CPU element address using a new\ninstruction', ' saving on extra functions calls.\n\nSigned-off-by: Andrii Nakryiko \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/r/20240402021307.1012571-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Inline the bpf_map_lookup_elem() helper for per-CPU HASH maps using a new BPF instruction.,"inline, per-CPU, BPF map",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +db69718b8efac802c7cc20d5a6c7dfc913f99c43,db69718b8efac802c7cc20d5a6c7dfc913f99c43,Andrii Nakryiko,andrii@kernel.org,1712023984,Alexei Starovoitov,ast@kernel.org,1712165396,9ba96e9d3e65a2d0731b14e6bfb5525de3102ecd,1ae6921009e5d72787e07ccc04754514ccf6bc99,"bpf: inline bpf_map_lookup_elem() for PERCPU_ARRAY maps + +Using new per-CPU BPF instruction implement inlining for per-CPU ARRAY +map lookup helper"," if BPF JIT support is present. + +Signed-off-by: Andrii Nakryiko +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240402021307.1012571-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Implemented inlining of bpf_map_lookup_elem() for PERCPU_ARRAY maps using new per-CPU BPF instruction.,"inline,elements,PERCPU_ARRAY",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1ae6921009e5d72787e07ccc04754514ccf6bc99,1ae6921009e5d72787e07ccc04754514ccf6bc99,Andrii Nakryiko,andrii@kernel.org,1712023983,Alexei Starovoitov,ast@kernel.org,1712165396,1ef59b0a783c0ac47d1ba63d5aaa3c932ec9dcd5,7bdbf7446305cb65c510c16d57cde82bc76b234a,"bpf: inline bpf_get_smp_processor_id() helper + +If BPF JIT supports per-CPU MOV instruction"," inline bpf_get_smp_processor_id() +to eliminate unnecessary function calls. + +Signed-off-by: Andrii Nakryiko +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240402021307.1012571-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Inlined bpf_get_smp_processor_id() helper in BPF for efficiency if JIT supports per-CPU MOV instruction.,"BPF, inline, efficiency",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7bdbf7446305cb65c510c16d57cde82bc76b234a,7bdbf7446305cb65c510c16d57cde82bc76b234a,Andrii Nakryiko,andrii@kernel.org,1712023982,Alexei Starovoitov,ast@kernel.org,1712165395,76980484fb19439a158181f99fa1f29f553ab189,2e114248e086fb376405ed3f89b220f8586a2541,"bpf: add special internal-only MOV instruction to resolve per-CPU addrs + +Add a new BPF instruction for resolving absolute addresses of per-CPU +data from their per-CPU offsets. This instruction is internal-only and +users are not allowed to use them directly. They will only be used for +internal inlining optimizations for now between BPF verifier and BPF JITs. + +We use a special BPF_MOV | BPF_ALU64 | BPF_X form with insn->off field +set to BPF_ADDR_PERCPU = -1. I used negative offset value to distinguish +them from positive ones used by user-exposed instructions. + +Such instruction performs a resolution of a per-CPU offset stored in +a register to a valid kernel address which can be dereferenced. It is +useful in any use case where absolute address of a per-CPU data has to +be resolved (e.g."," in inlining bpf_map_lookup_elem()). + +BPF disassembler is also taught to recognize them to support dumping +final BPF assembly code (non-JIT'ed version). + +Add arch-specific way for BPF JITs to mark support for this instructions. + +This patch also adds support for these instructions in x86-64 BPF JIT. + +Signed-off-by: Andrii Nakryiko +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240402021307.1012571-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],This commit adds a special internal-only MOV instruction for per-CPU address resolution in eBPF.,"BPF instruction, per-CPU, MOV",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2e114248e086fb376405ed3f89b220f8586a2541,2e114248e086fb376405ed3f89b220f8586a2541,Justin Stitt,justinstitt@google.com,1712101970,Daniel Borkmann,daniel@iogearbox.net,1712156261,3cbcfd5ea628f560c4d4156051ea34fa00509a76,c53908b254fcf25b05bcdf6634adb36eaccac111,"bpf: Replace deprecated strncpy with strscpy + +strncpy() is deprecated for use on NUL-terminated destination strings +[1] and as such we should prefer more robust and less ambiguous string +interfaces. + +bpf sym names get looked up and compared/cleaned with various string +apis. This suggests they need to be NUL-terminated (strncpy() suggests +this but does not guarantee it). + +| static int compare_symbol_name(const char *name"," char *namebuf) +| { +| cleanup_symbol_name(namebuf); +| return strcmp(name","[' namebuf);\n|\t}\n\n|\tstatic void cleanup_symbol_name(char *s)\n|\t{\n|\t\t...\n|\t\tres = strstr(s', ' "".llvm."");\n|\t\t...\n|\t}\n\nUse strscpy() as this method guarantees NUL-termination on the\ndestination buffer.\n\nThis patch also replaces two uses of strncpy() used in log.c. These are\nsimple replacements as postfix has been zero-initialized on the stack\nand has source arguments with a size less than the destination\'s size.\n\nNote that this patch uses the new 2-argument version of strscpy\nintroduced in commit e6584c3964f2f (""string: Allow 2-argument strscpy()"").\n\nSigned-off-by: Justin Stitt \nSigned-off-by: Daniel Borkmann \nAcked-by: Daniel Borkmann \nLink: https://www.kernel.org/doc/html/latest/process/deprecated.html#strncpy-on-nul-terminated-strings [1]\nLink: https://manpages.debian.org/testing/linux-manual-4.8/strscpy.9.en.html [2]\nLink: https://github.com/KSPP/linux/issues/90\nLink: https://lore.kernel.org/bpf/20240402-strncpy-kernel-bpf-core-c-v1-1-7cb07a426e78@google.com\n', '']",Replaced deprecated strncpy with strscpy for safer string handling in bpf symbol names.,"deprecated, strncpy, strscpy",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +98f69a573c668a18cfda41b3976118e04521a196,98f69a573c668a18cfda41b3976118e04521a196,Namhyung Kim,namhyung@kernel.org,1711749490,Arnaldo Carvalho de Melo,acme@redhat.com,1712155737,b4bd68a7eaecf2a677bd0d64fa3fd46b1614ebce,10adbf777622e22323abbf9f7861c26deb373199,"perf annotate: Split out util/disasm.c + +The util/annotate.c code has both disassembly and sample annotation +related codes. Factor out the disasm part so that it can be handled +more easily. + +No functional changes intended. + +Committer notes: + +Add missing include env.h", util.h,"[' bpf-event.h and bpf-util.h to\ndisasm.c', ' to fix things like:\n\n util/disasm.c: In function ‘symbol__disassemble_bpf’:\n util/disasm.c:1203:9: error: implicit declaration of function ‘perf_exe’ [-Werror=implicit-function-declaration]\n 1203 | perf_exe(tpath', ' sizeof(tpath));\n | ^~~~~~~~\n\nSigned-off-by: Namhyung Kim \nTested-by: Ian Rogers \nCc: Adrian Hunter \nCc: Ingo Molnar \nCc: Jiri Olsa \nCc: Kan Liang \nCc: Peter Zijlstra \nLink: https://lore.kernel.org/r/20240329215812.537846-4-namhyung@kernel.org\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",The commit refactors the code by splitting disassembly logic from util/annotate.c into util/disasm.c for better maintainability.,"refactor, disassembly, annotate",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +09d2056efe0c02b7a589915c004c6e925735d081,09d2056efe0c02b7a589915c004c6e925735d081,Yang Jihong,yangjihong@bytedance.com,1711952844,Arnaldo Carvalho de Melo,acme@redhat.com,1712155736,502d6ae05ac14c9da2391f6c0b609b713e34e08d,6e4b398770d5023eb6383da9360a23bd537c155b,"perf evsel: Use evsel__name_is() helper + +Code cleanup", replace strcmp(evsel__name(evsel,"[' {NAME})) with\nevsel__name_is() helper.\n\nNo functional change.\n\nCommitter notes:\n\nFix this build error:\n\n trace.syscalls.events.bpf_output = evlist__last(trace.evlist);\n - assert(evsel__name_is(trace.syscalls.events.bpf_output)', ' ""__augmented_syscalls__"");\n + assert(evsel__name_is(trace.syscalls.events.bpf_output', ' ""__augmented_syscalls__""));\n\nReviewed-by: Ian Rogers \nSigned-off-by: Yang Jihong \nCc: Adrian Hunter \nCc: Alexander Shishkin \nCc: Ingo Molnar \nCc: James Clark \nCc: Jiri Olsa \nCc: Kan Liang \nCc: Mark Rutland \nCc: Namhyung Kim \nCc: Peter Zijlstra \nLink: https://lore.kernel.org/r/20240401062724.1006010-3-yangjihong@bytedance.com\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",The commit refactors code by replacing `strcmp` with the `evsel__name_is()` helper for improved code readability.,"perf, evsel, helper",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The JIT compiler,"[""It's not related to any of the above.""]" +c53908b254fcf25b05bcdf6634adb36eaccac111,c53908b254fcf25b05bcdf6634adb36eaccac111,Tushar Vyavahare,tushar.vyavahare@intel.com,1712058329,Daniel Borkmann,daniel@iogearbox.net,1712153054,a122671ae8298b2f23d3f86ebd86a878260648ff,c4f960539fae6f04617d3909cc0dfdb88e7d197b,"selftests/xsk: Add new test case for AF_XDP under max ring sizes + +Introduce a test case to evaluate AF_XDP's robustness by pushing hardware +and software ring sizes to their limits. This test ensures AF_XDP's +reliability amidst potential producer/consumer throttling due to maximum +ring utilization. The testing strategy includes: + +1. Configuring rings to their maximum allowable sizes. +2. Executing a series of tests across diverse batch sizes to assess + system's behavior under different configurations. + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-8-tushar.vyavahare@intel.com +",,A new test case evaluates AF_XDP's robustness under maximum ring sizes in selftests.,"AF_XDP, test case, ring sizes",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +c4f960539fae6f04617d3909cc0dfdb88e7d197b,c4f960539fae6f04617d3909cc0dfdb88e7d197b,Tushar Vyavahare,tushar.vyavahare@intel.com,1712058328,Daniel Borkmann,daniel@iogearbox.net,1712153045,95210b92842cde8f016bb3c017ffe0ed546dc1da,776021e07fd0d7592c767e60929b954e82676186,"selftests/xsk: Test AF_XDP functionality under minimal ring configurations + +Add a new test case that stresses AF_XDP and the driver by configuring +small hardware and software ring sizes. This verifies that AF_XDP continues +to function properly even with insufficient ring space that could lead +to frequent producer/consumer throttling. The test procedure involves: + +1. Set the minimum possible ring configuration(tx 64 and rx 128). +2. Run tests with various batch sizes(1 and 63) to validate the system's + behavior under different configurations. + +Update Makefile to include network_helpers.o in the build process for +xskxceiver. + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-7-tushar.vyavahare@intel.com +",,Adds a test for AF_XDP functionality under minimal ring configurations by updating Makefile and testing with various batch sizes.,"AF_XDP,minimal ring,test case",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +776021e07fd0d7592c767e60929b954e82676186,776021e07fd0d7592c767e60929b954e82676186,Tushar Vyavahare,tushar.vyavahare@intel.com,1712058327,Daniel Borkmann,daniel@iogearbox.net,1712153037,cf116fab1b4f5ca6f3aa7e25c7b2fae5c8c6c592,bee3a7b07624223526c1fea465557068546d3b3c,"selftests/xsk: Introduce set_ring_size function with a retry mechanism for handling AF_XDP socket closures + +Introduce a new function", set_ring_size(),"[' to manage asynchronous AF_XDP\nsocket closure. Retry set_hw_ring_size up to SOCK_RECONF_CTR times if it\nfails due to an active AF_XDP socket. Return an error immediately for\nnon-EBUSY errors. This enhances robustness against asynchronous AF_XDP\nsocket closures during ring size changes.\n\nSigned-off-by: Tushar Vyavahare \nSigned-off-by: Daniel Borkmann \nAcked-by: Magnus Karlsson \nLink: https://lore.kernel.org/bpf/20240402114529.545475-6-tushar.vyavahare@intel.com\n', '']",Introduce a set_ring_size function with retry mechanism for AF_XDP socket closures in selftests.,"set_ring_size,retry mechanism,AF_XDP",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +bee3a7b07624223526c1fea465557068546d3b3c,bee3a7b07624223526c1fea465557068546d3b3c,Tushar Vyavahare,tushar.vyavahare@intel.com,1712058326,Daniel Borkmann,daniel@iogearbox.net,1712153033,6b531c2c32d8b9a061a3f071eddf24f810c05287,90a695c3d31e1c9f0adb8c4c80028ed4ea7ed5ab,"selftests/bpf: Implement set_hw_ring_size function to configure interface ring size + +Introduce a new function called set_hw_ring_size that allows for the +dynamic configuration of the ring size within the interface. + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-5-tushar.vyavahare@intel.com +",,Implement set_hw_ring_size function to adjust interface ring size dynamically.,"set_hw_ring_size, interface, ring size",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +90a695c3d31e1c9f0adb8c4c80028ed4ea7ed5ab,90a695c3d31e1c9f0adb8c4c80028ed4ea7ed5ab,Tushar Vyavahare,tushar.vyavahare@intel.com,1712058325,Daniel Borkmann,daniel@iogearbox.net,1712153017,40812917dd304d100179d6e8e8b63f292ed5d0c4,c3bd015090f24dcd2e839db1401e948ad95ce803,"selftests/bpf: Implement get_hw_ring_size function to retrieve current and max interface size + +Introduce a new function called get_hw_size that retrieves both the +current and maximum size of the interface and stores this information +in the 'ethtool_ringparam' structure. + +Remove ethtool_channels struct from xdp_hw_metadata.c due to redefinition +error. Remove unused linux/if.h include from flow_dissector BPF test to +address CI pipeline failure. + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-4-tushar.vyavahare@intel.com +",,Implemented get_hw_ring_size function in BPF selftests to manage interface size configurations and resolved CI-related issues.,"get_hw_ring_size, ethtool_ringparam, selftests",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['xdp like programs', 'tc/netfilter like programs']" +c3bd015090f24dcd2e839db1401e948ad95ce803,c3bd015090f24dcd2e839db1401e948ad95ce803,Tushar Vyavahare,tushar.vyavahare@intel.com,1712058324,Daniel Borkmann,daniel@iogearbox.net,1712152857,778b04e30d8b6a1e4f71f4a5bb13fd811b567dcc,7effe3fdc049a34c56a68671100b5570e53e8f0a,"selftests/xsk: Make batch size variable + +Convert the constant BATCH_SIZE into a variable named batch_size to allow +dynamic modification at runtime. This is required for the forthcoming +changes to support testing different hardware ring sizes. + +While running these tests"," a bug was identified when the batch size is +roughly the same as the NIC ring size. This has now been addressed by +Maciej's fix in commit 913eda2b08cc (""i40e: xsk: remove count_mask""). + +Signed-off-by: Tushar Vyavahare +Signed-off-by: Daniel Borkmann +Acked-by: Magnus Karlsson +Link: https://lore.kernel.org/bpf/20240402114529.545475-3-tushar.vyavahare@intel.com +",[''],This commit changes the BATCH_SIZE constant to a variable to support dynamic modification for testing different hardware ring sizes.,"batch_size,dynamic,testing",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +7effe3fdc049a34c56a68671100b5570e53e8f0a,7effe3fdc049a34c56a68671100b5570e53e8f0a,Tushar Vyavahare,tushar.vyavahare@intel.com,1712058323,Daniel Borkmann,daniel@iogearbox.net,1712152814,779ab1f73061340d368ae8a95eaf7a8f45227b01,49b73fa623c47302befecba0c2c310739ed0a088,"tools: Add ethtool.h header to tooling infra + +This commit duplicates the ethtool.h file from the include/uapi/linux +directory in the kernel source to the tools/include/uapi/linux directory. + +This action ensures that the ethtool.h file used in the tools directory +is in sync with the kernel's version"," maintaining consistency across the +codebase. + +There are some checkpatch warnings in this file that could be cleaned up","['\nbut I preferred to move it over as-is for now to avoid disrupting the code.\n\nSigned-off-by: Tushar Vyavahare \nSigned-off-by: Daniel Borkmann \nAcked-by: Magnus Karlsson \nLink: https://lore.kernel.org/bpf/20240402114529.545475-2-tushar.vyavahare@intel.com\n', '']",Duplicate ethtool.h header to sync tools with kernel version.,"ethtool,sync,header",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +49b73fa623c47302befecba0c2c310739ed0a088,49b73fa623c47302befecba0c2c310739ed0a088,Alexei Starovoitov,ast@kernel.org,1712112350,Alexei Starovoitov,ast@kernel.org,1712112351,a4016b11eba0c4d9f47f5ad4e3a0c327a50d0b66,c07b4bcd5163c2929d8bfc55140325fc15afb4eb 4dd31243e30843d5f63bccfb0369146e4de1a130,"Merge branch 'bpf-arm64-add-support-for-bpf-arena' + +Puranjay Mohan says: + +==================== +bpf","arm64: Add support for BPF Arena + +Changes in V4 +V3: https://lore.kernel.org/bpf/20240323103057.26499-1-puranjay12@gmail.com/ +- Use more descriptive variable names. +- Use insn_is_cast_user() helper. + +Changes in V3 +V2: https://lore.kernel.org/bpf/20240321153102.103832-1-puranjay12@gmail.com/ +- Optimize bpf_addr_space_cast as suggested by Xu Kuohai + +Changes in V2 +V1: https://lore.kernel.org/bpf/20240314150003.123020-1-puranjay12@gmail.com/ +- Fix build warnings by using 5 in place of 32 as DONT_CLEAR marker. + R5 is not mapped to any BPF register so it can safely be used here. + +This series adds the support for PROBE_MEM32 and bpf_addr_space_cast +instructions to the ARM64 BPF JIT. These two instructions allow the +enablement of BPF Arena. + +All arena related selftests are passing. + + [root@ip-172-31-6-62 bpf]# ./test_progs -a ""*arena*"" + #3/1 arena_htab/arena_htab_llvm:OK + #3/2 arena_htab/arena_htab_asm:OK + #3 arena_htab:OK + #4/1 arena_list/arena_list_1:OK + #4/2 arena_list/arena_list_1000:OK + #4 arena_list:OK + #434/1 verifier_arena/basic_alloc1:OK + #434/2 verifier_arena/basic_alloc2:OK + #434/3 verifier_arena/basic_alloc3:OK + #434/4 verifier_arena/iter_maps1:OK + #434/5 verifier_arena/iter_maps2:OK + #434/6 verifier_arena/iter_maps3:OK + #434 verifier_arena:OK + Summary: 3/10 PASSED","[' 0 SKIPPED', ' 0 FAILED\n\nThis will need the patch [1] that introduced insn_is_cast_user() helper to\nbuild.\n\nThe verifier_arena selftest could fail in the CI because the following\ncommit[2] is missing from bpf-next:\n\n[1] https://lore.kernel.org/bpf/20240324183226.29674-1-puranjay12@gmail.com/\n[2] https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git/commit/?id=fa3550dca8f02ec312727653a94115ef3ab68445\n\nHere is a CI run with all dependencies added: https://github.com/kernel-patches/bpf/pull/6641\n====================\n\nLink: https://lore.kernel.org/r/20240325150716.4387-1-puranjay12@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit merges support for BPF Arena into the ARM64 BPF JIT with successful selftests.,"BPF Arena, ARM64, JIT",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4dd31243e30843d5f63bccfb0369146e4de1a130,4dd31243e30843d5f63bccfb0369146e4de1a130,Puranjay Mohan,puranjay12@gmail.com,1711379236,Alexei Starovoitov,ast@kernel.org,1712112350,a4016b11eba0c4d9f47f5ad4e3a0c327a50d0b66,339af577ec05c8fc0b96f23579614ae853d913ab,"bpf: Add arm64 JIT support for bpf_addr_space_cast instruction. + +LLVM generates bpf_addr_space_cast instruction while translating +pointers between native (zero) address space and +__attribute__((address_space(N))). The addr_space=0 is reserved as +bpf_arena address space. + +rY = addr_space_cast(rX", 0,"[' 1) is processed by the verifier and\nconverted to normal 32-bit move: wX = wY.\n\nrY = addr_space_cast(rX', ' 1', ' 0) : used to convert a bpf arena pointer to\na pointer in the userspace vma. This has to be converted by the JIT.\n\nSigned-off-by: Puranjay Mohan \nLink: https://lore.kernel.org/r/20240325150716.4387-3-puranjay12@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add ARM64 JIT support for the bpf_addr_space_cast instruction.,"ARM64,JIT,bpf_addr_space_cast",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +339af577ec05c8fc0b96f23579614ae853d913ab,339af577ec05c8fc0b96f23579614ae853d913ab,Puranjay Mohan,puranjay12@gmail.com,1711379235,Alexei Starovoitov,ast@kernel.org,1712112350,55a6bd47a5ec69990897fd482941a0a27b2cb78a,c07b4bcd5163c2929d8bfc55140325fc15afb4eb,"bpf: Add arm64 JIT support for PROBE_MEM32 pseudo instructions. + +Add support for [LDX | STX | ST]", PROBE_MEM32,"[' [B | H | W | DW]\ninstructions. They are similar to PROBE_MEM instructions with the\nfollowing differences:\n- PROBE_MEM32 supports store.\n- PROBE_MEM32 relies on the verifier to clear upper 32-bit of the\n src/dst register\n- PROBE_MEM32 adds 64-bit kern_vm_start address (which is stored in R28\n in the prologue). Due to bpf_arena constructions such R28 + reg +\n off16 access is guaranteed to be within arena virtual range', ' so no\n address check at run-time.\n- PROBE_MEM32 allows STX and ST. If they fault the store is a nop. When\n LDX faults the destination register is zeroed.\n\nTo support these on arm64', ' we do tmp2 = R28 + src/dst reg and then use\ntmp2 as the new src/dst register. This allows us to reuse most of the\ncode for normal [LDX | STX | ST].\n\nSigned-off-by: Puranjay Mohan \nLink: https://lore.kernel.org/r/20240325150716.4387-2-puranjay12@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Added support for arm64 JIT for PROBE_MEM32 pseudo instructions in eBPF.,"arm64,JIT,PROBE_MEM32",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c07b4bcd5163c2929d8bfc55140325fc15afb4eb,c07b4bcd5163c2929d8bfc55140325fc15afb4eb,Geliang Tang,tanggeliang@kylinos.cn,1712055021,Andrii Nakryiko,andrii@kernel.org,1712077549,44f98f800a59f3e4ac212a4041c41e7204a4fd82,15ea39ad7e83af16480bbf20144fcc6edf4757f9,"selftests/bpf: Add pid limit for mptcpify prog + +In order to prevent mptcpify prog from affecting the running results +of other BPF tests"," a pid limit was added to restrict it from only +modifying its own program. + +Suggested-by: Martin KaFai Lau +Signed-off-by: Geliang Tang +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/8987e2938e15e8ec390b85b5dcbee704751359dc.1712054986.git.tanggeliang@kylinos.cn +",[''],Added a pid limit to mptcpify program to prevent interference with other BPF tests.,"pid limit, mptcpify, selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +15ea39ad7e83af16480bbf20144fcc6edf4757f9,15ea39ad7e83af16480bbf20144fcc6edf4757f9,Tobias Böhm,tobias@aibor.de,1712070652,Andrii Nakryiko,andrii@kernel.org,1712075314,15c6baaf38cce92073869dad56108d7a1255a2e1,ce09cbdd988887662546a1175bcfdfc6c8fdd150,"libbpf: Use local bpf_helpers.h include + +Commit 20d59ee55172fdf6 (""libbpf: add bpf_core_cast() macro"") added a +bpf_helpers include in bpf_core_read.h as a system include. Usually"," the +includes are local","[' though', ' like in bpf_tracing.h. This commit adjusts\nthe include to be local as well.\n\nSigned-off-by: Tobias Böhm \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/q5d5bgc6vty2fmaazd5e73efd6f5bhiru2le6fxn43vkw45bls@fhlw2s5ootdb\n', '']",Change the inclusion of bpf_helpers.h to a local include in libbpf.,"local, bpf_helpers, include",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ce09cbdd988887662546a1175bcfdfc6c8fdd150,ce09cbdd988887662546a1175bcfdfc6c8fdd150,Jose Fernandez,josef@netflix.com,1712029210,Daniel Borkmann,daniel@iogearbox.net,1712069475,13d5602cfc7f3f1463cb88f05adbecd2a6709b3c,c186ed12a8ec498532d13de43094bdec9ac6f121,"bpf: Improve program stats run-time calculation + +This patch improves the run-time calculation for program stats by +capturing the duration as soon as possible after the program returns. + +Previously"," the duration included u64_stats_t operations. While the +instrumentation overhead is part of the total time spent when stats are +enabled","["" distinguishing between the program's native execution time and\nthe time spent due to instrumentation is crucial for accurate\nperformance analysis.\n\nBy making this change"", ' the patch facilitates more precise optimization\nof BPF programs', ' enabling users to understand their performance in\nenvironments without stats enabled.\n\nI used a virtualized environment to measure the run-time over one minute\nfor a basic raw_tracepoint/sys_enter program', ' which just increments a\nlocal counter. Although the virtualization introduced some performance\ndegradation that could affect the results', ' I observed approximately a\n16% decrease in average run-time reported by stats with this change\n(310 -> 260 nsec).\n\nSigned-off-by: Jose Fernandez \nSigned-off-by: Daniel Borkmann \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240402034010.25060-1-josef@netflix.com\n', '']",Improve run-time calculation by capturing program stats duration earlier.,"run-time,program,stats",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ff91059932401894e6c86341915615c5eb0eca48,ff91059932401894e6c86341915615c5eb0eca48,Jakub Sitnicki,jakub@cloudflare.com,1712054781,Daniel Borkmann,daniel@iogearbox.net,1712068265,2a7b401e3f18c6df1de80a3833228250aaaa9211,8c3fe029d79ada599fa558fdf3da0322fc38de36,bpf," sockmap: Prevent lock inversion deadlock in map delete elem + +syzkaller started using corpuses where a BPF tracing program deletes +elements from a sockmap/sockhash map. Because BPF tracing programs can be +invoked from any interrupt context","[' locks taken during a map_delete_elem\noperation must be hardirq-safe. Otherwise a deadlock due to lock inversion\nis possible', ' as reported by lockdep:\n\n CPU0 CPU1\n ---- ----\n lock(&htab->buckets[i].lock);\n local_irq_disable();\n lock(&host->lock);\n lock(&htab->buckets[i].lock);\n \n lock(&host->lock);\n\nLocks in sockmap are hardirq-unsafe by design. We expects elements to be\ndeleted from sockmap/sockhash only in task (normal) context with interrupts\nenabled', ' or in softirq context.\n\nDetect when map_delete_elem operation is invoked from a context which is\n_not_ hardirq-unsafe', ' that is interrupts are disabled', ' and bail out with an\nerror.\n\nNote that map updates are not affected by this issue. BPF verifier does not\nallow updating sockmap/sockhash from a BPF tracing program today.\n\nFixes: 604326b41a6f (""bpf', ' sockmap: convert to generic sk_msg interface"")\nReported-by: xingwei lee \nReported-by: yue sun \nReported-by: syzbot+bc922f476bd65abbd466@syzkaller.appspotmail.com\nReported-by: syzbot+d4066896495db380182e@syzkaller.appspotmail.com\nSigned-off-by: Jakub Sitnicki \nSigned-off-by: Daniel Borkmann \nTested-by: syzbot+d4066896495db380182e@syzkaller.appspotmail.com\nAcked-by: John Fastabend \nCloses: https://syzkaller.appspot.com/bug?extid=d4066896495db380182e\nCloses: https://syzkaller.appspot.com/bug?extid=bc922f476bd65abbd466\nLink: https://lore.kernel.org/bpf/20240402104621.1050319-1-jakub@cloudflare.com\n', '']",Prevent lock inversion deadlock in sockmap/sockhash map element deletion by BPF tracing programs.,"lock inversion, deadlock, sockmap",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c186ed12a8ec498532d13de43094bdec9ac6f121,c186ed12a8ec498532d13de43094bdec9ac6f121,Pu Lehui,pulehui@huawei.com,1712043029,Daniel Borkmann,daniel@iogearbox.net,1712068168,cd4e4d266cd85e9425e0b06d47598187f30bbc1c,2a24e2485722b0e12e17a2bd473bd15c9e420bdb,"selftests/bpf: Skip test when perf_event_open returns EOPNOTSUPP + +When testing send_signal and stacktrace_build_id_nmi using the riscv sbi +pmu driver without the sscofpmf extension or the riscv legacy pmu driver"," +then failures as follows are encountered: + + test_send_signal_common:FAIL:perf_event_open unexpected perf_event_open: actual -1 < expected 0 + #272/3 send_signal/send_signal_nmi:FAIL + + test_stacktrace_build_id_nmi:FAIL:perf_event_open err -1 errno 95 + #304 stacktrace_build_id_nmi:FAIL + +The reason is that the above pmu driver or hardware does not support +sampling events","[' that is', ' PERF_PMU_CAP_NO_INTERRUPT is set to pmu\ncapabilities', ' and then perf_event_open returns EOPNOTSUPP. Since\nPERF_PMU_CAP_NO_INTERRUPT is not only set in the riscv-related pmu driver', '\nit is better to skip testing when this capability is set.\n\nSigned-off-by: Pu Lehui \nSigned-off-by: Daniel Borkmann \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240402073029.1299085-1-pulehui@huaweicloud.com\n', '']",The commit modifies test scripts to skip tests when perf_event_open returns EOPNOTSUPP due to unsupported sampling events in certain RISC-V configurations.,"selftests,bpf,EOPNOTSUPP",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +2a24e2485722b0e12e17a2bd473bd15c9e420bdb,2a24e2485722b0e12e17a2bd473bd15c9e420bdb,Andrii Nakryiko,andrii@kernel.org,1711991233,Daniel Borkmann,daniel@iogearbox.net,1712067649,16ee10833bd56cd22649735060b9f810510a5526,965c6167c93f3fac53e25807f83c07e87b3c085a,"bpftool: Use __typeof__() instead of typeof() in BPF skeleton + +When generated BPF skeleton header is included in C++ code base"," some +compiler setups will emit warning about using language extensions due to +typeof() usage","[' resulting in something like:\n\n error: extension used [-Werror', '-Wlanguage-extension-token]\n obj->struct_ops.empty_tcp_ca = (typeof(obj->struct_ops.empty_tcp_ca))\n ^\n\nIt looks like __typeof__() is a preferred way to do typeof() with better\nC++ compatibility behavior', ' so switch to that. With __typeof__() we get\nno such warning.\n\nFixes: c2a0257c1edf (""bpftool: Cast pointers for shadow types explicitly."")\nFixes: 00389c58ffe9 (""bpftool: Add support for subskeletons"")\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Kui-Feng Lee \nAcked-by: Quentin Monnet \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/bpf/20240401170713.2081368-1-andrii@kernel.org\n', '']",Replaces typeof() with __typeof__() in BPF skeleton to avoid compiler warnings in C++ code.,"bpftool, compiler, BPF",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +965c6167c93f3fac53e25807f83c07e87b3c085a,965c6167c93f3fac53e25807f83c07e87b3c085a,Yonghong Song,yonghong.song@linux.dev,1712026486,Daniel Borkmann,daniel@iogearbox.net,1712067240,611ec4261565516c148aa485c4517b7af8c179fe,9dc182c58b5f5d4ac125ac85ad553f7142aa08d4,"selftests/bpf: Using llvm may_goto inline asm for cond_break macro + +Currently"," cond_break macro uses bytes to encode the may_goto insn. +Patch [1] in llvm implemented may_goto insn in BPF backend. +Replace byte-level encoding with llvm inline asm for better usability. +Using llvm may_goto insn is controlled by macro __BPF_FEATURE_MAY_GOTO. + + [1] https://github.com/llvm/llvm-project/commit/0e0bfacff71859d1f9212205f8f873d47029d3fb + +Signed-off-by: Yonghong Song +Signed-off-by: Daniel Borkmann +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240402025446.3215182-1-yonghong.song@linux.dev +",[''],The commit updates the cond_break macro to use llvm inline assembly for better usability.,"llvm, inline asm, may_goto",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +9dc182c58b5f5d4ac125ac85ad553f7142aa08d4,9dc182c58b5f5d4ac125ac85ad553f7142aa08d4,Anton Protopopov,aspsk@isovalent.com,1712043227,Daniel Borkmann,daniel@iogearbox.net,1712067120,71232931a9632e6e627d99f63d2b54e19fcabc69,ca4ddc26f8acaa9cb451fcb20f7ab0f02e4970cb,"bpf: Add a verbose message if map limit is reached + +When more than 64 maps are used by a program and its subprograms the +verifier returns -E2BIG. Add a verbose message which highlights the +source of the error and also print the actual limit. + +Signed-off-by: Anton Protopopov +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240402073347.195920-1-aspsk@isovalent.com +",,Adds a verbose message for map limit exceeded errors in the bpf verifier.,"verbose, verifier, maps",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ca4ddc26f8acaa9cb451fcb20f7ab0f02e4970cb,ca4ddc26f8acaa9cb451fcb20f7ab0f02e4970cb,David Lechner,dlechner@baylibre.com,1711726126,Daniel Borkmann,daniel@iogearbox.net,1712066674,0dbbbebbd2e666ccda3a868dc15c52d3e70282a7,a70f5d840a56a82c576385ca79ee55c1598f1bc3,"bpf: Fix typo in uapi doc comments + +In a few places in the bpf uapi headers"," EOPNOTSUPP is missing a ""P"" in +the doc comments. This adds the missing ""P"". + +Signed-off-by: David Lechner +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240329152900.398260-2-dlechner@baylibre.com +",[''],"Fixed a typo in the bpf uapi doc comments by adding a missing ""P"".","bpf, typo, doc comments",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,"[""It's not related to any of the above.""]" +a70f5d840a56a82c576385ca79ee55c1598f1bc3,a70f5d840a56a82c576385ca79ee55c1598f1bc3,Rameez Rehman,rameezrehman408@hotmail.com,1711915426,Daniel Borkmann,daniel@iogearbox.net,1712065823,88b41a8bc9a8f29aec36b5efb160603e5cec0a01,ea379b3ccc2e4dff9c3d616f0611b5312fe389ad,bpftool: Clean-up typos, punctuation,"[' list formatting in docs\n\nImprove the formatting of the attach flags for cgroup programs in the\nrelevant man page', ' and fix typos (""can be on of""', ' ""an userspace inet\nsocket"") when introducing that list. Also fix a couple of other trivial\nissues in docs.\n\n[ Quentin: Fixed trival issues in bpftool-gen.rst and bpftool-iter.rst ]\n\nSigned-off-by: Rameez Rehman \nSigned-off-by: Quentin Monnet \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240331200346.29118-4-qmo@kernel.org\n', '']",The commit cleans up typographical errors in the bpftool utility.,"bpftool,cleanup,typos",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +ea379b3ccc2e4dff9c3d616f0611b5312fe389ad,ea379b3ccc2e4dff9c3d616f0611b5312fe389ad,Rameez Rehman,rameezrehman408@hotmail.com,1711915425,Daniel Borkmann,daniel@iogearbox.net,1712065823,8c6af315030eb6a793a2cb362711322c14a05f35,f7b68543642136164ce7348945d3ada707c4e635,"bpftool: Remove useless emphasis on command description in man pages + +As it turns out"," the terms in definition lists in the rST file are +already rendered with bold-ish formatting when generating the man pages; +all double-star sequences we have in the commands for the command +description are unnecessary","["" and can be removed to make the\ndocumentation easier to read.\n\nThe rST files were automatically processed with:\n\n sed -i '/DESCRIPTION/"", ""/OPTIONS/ { /^\\*/ s/\\*\\*//g }' b*.rst\n\nSigned-off-by: Rameez Rehman \nSigned-off-by: Quentin Monnet \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240331200346.29118-3-qmo@kernel.org\n"", '']",This commit removes unnecessary bold formatting from command descriptions in bpftool man pages.,"bpftool,man pages,formatting",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +f7b68543642136164ce7348945d3ada707c4e635,f7b68543642136164ce7348945d3ada707c4e635,Rameez Rehman,rameezrehman408@hotmail.com,1711915424,Daniel Borkmann,daniel@iogearbox.net,1712065823,2505ca965a9fed991aacf0086b220d3d41d15825,623bdd58be3727318d374f0052f9dfff1e87b854,"bpftool: Use simpler indentation in source rST for documentation + +The rST manual pages for bpftool would use a mix of tabs and spaces for +indentation. While this is the norm in C code"," this is rather unusual +for rST documents","["" and over time we've seen many contributors use a\nwrong level of indentation for documentation update.\n\nLet's fix bpftool's indentation in docs once and for all:\n\n- Let's use spaces"", ' that are more common in rST files.\n- Remove one level of indentation for the synopsis', ' the command\n description', ' and the ""see also"" section. As a result', ' all sections\n start with the same indentation level in the generated man page.\n- Rewrap the paragraphs after the changes.\n\nThere is no content change in this patch', ' only indentation and\nrewrapping changes. The wrapping in the generated source files for the\nmanual pages is changed', ' but the pages displayed with ""man"" remain the\nsame', ' apart from the adjusted indentation level on relevant sections.\n\n[ Quentin: rebased on bpf-next', ' removed indent level for command\n description and options', ' updated synopsis', ' command summary', ' and ""see\n also"" sections. ]\n\nSigned-off-by: Rameez Rehman \nSigned-off-by: Quentin Monnet \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240331200346.29118-2-qmo@kernel.org\n', '']",Simplified indentation in bpftool's rST documentation by standardizing to spaces.,"bpftool, rST, indentation",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +fcf4692fa39e86a590c14a4af2de704e1d20a3b5,fcf4692fa39e86a590c14a4af2de704e1d20a3b5,Paolo Abeni,pabeni@redhat.com,1711738236,Jakub Kicinski,kuba@kernel.org,1712029404,b8333ea8be6d6127cc159ac2d89e1ef979ccf2d7,31974122cfdeaf56abc18d8ab740d580d9833e90,"mptcp: prevent BPF accessing lowat from a subflow socket. + +Alexei reported the following splat: + + WARNING: CPU: 32 PID: 3276 at net/mptcp/subflow.c:1430 subflow_data_ready+0x147/0x1c0 + Modules linked in: dummy bpf_testmod(O) [last unloaded: bpf_test_no_cfi(O)] + CPU: 32 PID: 3276 Comm: test_progs Tainted: GO 6.8.0-12873-g2c43c33bfd23 + Call Trace: + + mptcp_set_rcvlowat+0x79/0x1d0 + sk_setsockopt+0x6c0/0x1540 + __bpf_setsockopt+0x6f/0x90 + bpf_sock_ops_setsockopt+0x3c/0x90 + bpf_prog_509ce5db2c7f9981_bpf_test_sockopt_int+0xb4/0x11b + bpf_prog_dce07e362d941d2b_bpf_test_socket_sockopt+0x12b/0x132 + bpf_prog_348c9b5faaf10092_skops_sockopt+0x954/0xe86 + __cgroup_bpf_run_filter_sock_ops+0xbc/0x250 + tcp_connect+0x879/0x1160 + tcp_v6_connect+0x50c/0x870 + mptcp_connect+0x129/0x280 + __inet_stream_connect+0xce/0x370 + inet_stream_connect+0x36/0x50 + bpf_trampoline_6442491565+0x49/0xef + inet_stream_connect+0x5/0x50 + __sys_connect+0x63/0x90 + __x64_sys_connect+0x14/0x20 + +The root cause of the issue is that bpf allows accessing mptcp-level +proto_ops from a tcp subflow scope. + +Fix the issue detecting the problematic call and preventing any action. + +Reported-by: Alexei Starovoitov +Closes: https://github.com/multipath-tcp/mptcp_net-next/issues/482 +Fixes: 5684ab1a0eff (""mptcp: give rcvlowat some love"") +Signed-off-by: Paolo Abeni +Reviewed-by: Mat Martineau +Reviewed-by: Matthieu Baerts (NGI0) +Link: https://lore.kernel.org/r/d8cb7d8476d66cb0812a6e29cd1e626869d9d53e.1711738080.git.pabeni@redhat.com +Signed-off-by: Jakub Kicinski +",,Fix to prevent BPF from accessing lowat from a subflow socket in MPTCP.,"MPTCP,BPF,lowat",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['socket like programs'] +8c3fe029d79ada599fa558fdf3da0322fc38de36,8c3fe029d79ada599fa558fdf3da0322fc38de36,Alexei Starovoitov,ast@kernel.org,1712029076,Alexei Starovoitov,ast@kernel.org,1712029077,69ebdb5ddaa504511a9b2f1e327246b1591ba08e,6dae957c8eef6eae5b386462767de97303235d5c 6a537453000a916392fcac1acb96c1d9d1e05b74,"Merge branch 'x86-bpf-fixes-for-the-bpf-jit-with-retbleed-stuff' + +Joan Bruguera Micó says: + +==================== +x86/bpf: Fixes for the BPF JIT with retbleed=stuff + +From: Joan Bruguera Micó + +Fixes two issues that cause kernels panic when using the BPF JIT with +the call depth tracking / stuffing mitigation for Skylake processors +(`retbleed=stuff`). Both issues can be triggered by running simple +BPF programs (e.g. running the test suite should trigger both). + +The first (resubmit) fixes a trivial issue related to calculating the +destination IP for call instructions with call depth tracking. + +The second is related to using the correct IP for relocations"," related +to the recently introduced %rip-relative addressing for PER_CPU_VAR. + +Cc: Alexei Starovoitov +Cc: Daniel Borkmann +--- +v2: + Simplify calculation of ""ip"". + Add more details to the commit message. + +Joan Bruguera Micó (1): + x86/bpf: Fix IP for relocating call depth accounting +==================== + +Link: https://lore.kernel.org/r/20240401185821.224068-1-ubizjak@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Fixes issues causing kernel crashes when using BPF JIT with retbleed mitigation on Skylake processors.,"BPF JIT, retbleed, Skylake",It's a bug fix.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6a537453000a916392fcac1acb96c1d9d1e05b74,6a537453000a916392fcac1acb96c1d9d1e05b74,Joan Bruguera Micó,joanbrugueram@gmail.com,1711997730,Alexei Starovoitov,ast@kernel.org,1712029076,69ebdb5ddaa504511a9b2f1e327246b1591ba08e,9d98aa088386aee3db1b7b60b800c0fde0654a4a,"x86/bpf: Fix IP for relocating call depth accounting + +The commit: + + 59bec00ace28 (""x86/percpu: Introduce %rip-relative addressing to PER_CPU_VAR()"") + +made PER_CPU_VAR() to use rip-relative addressing"," hence +INCREMENT_CALL_DEPTH macro and skl_call_thunk_template got rip-relative +asm code inside of it. A follow up commit: + + 17bce3b2ae2d (""x86/callthunks: Handle %rip-relative relocations in call thunk template"") + +changed x86_call_depth_emit_accounting() to use apply_relocation()","['\nbut mistakenly assumed that the code is being patched in-place (where\nthe destination of the relocation matches the address of the code)', '\nusing *pprog as the destination ip. This is not true for the call depth\naccounting', ' emitted by the BPF JIT', ' so the calculated address was wrong', '\nJIT-ed BPF progs on kernels with call depth tracking got broken and\nusually caused a page fault.\n\nPass the destination IP when the BPF JIT emits call depth accounting.\n\nFixes: 17bce3b2ae2d (""x86/callthunks: Handle %rip-relative relocations in call thunk template"")\nSigned-off-by: Joan Bruguera Micó \nReviewed-by: Uros Bizjak \nAcked-by: Ingo Molnar \nCc: Alexei Starovoitov \nCc: Daniel Borkmann \nLink: https://lore.kernel.org/r/20240401185821.224068-3-ubizjak@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix IP alignment in x86 BPF by handling RIP-relative relocations in call depth accounting.,"x86, BPF, relocation",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9d98aa088386aee3db1b7b60b800c0fde0654a4a,9d98aa088386aee3db1b7b60b800c0fde0654a4a,Uros Bizjak,ubizjak@gmail.com,1711997729,Alexei Starovoitov,ast@kernel.org,1712029076,e5317af7b7e8a7384b76a071b5996c98c568e6db,6dae957c8eef6eae5b386462767de97303235d5c,"x86/bpf: Fix IP after emitting call depth accounting + +Adjust the IP passed to `emit_patch` so it calculates the correct offset +for the CALL instruction if `x86_call_depth_emit_accounting` emits code. +Otherwise we will skip some instructions and most likely crash. + +Fixes: b2e9dfe54be4 (""x86/bpf: Emit call depth accounting if required"") +Link: https://lore.kernel.org/lkml/20230105214922.250473-1-joanbrugueram@gmail.com/ +Co-developed-by: Joan Bruguera Micó +Signed-off-by: Joan Bruguera Micó +Signed-off-by: Uros Bizjak +Cc: Alexei Starovoitov +Cc: Daniel Borkmann +Link: https://lore.kernel.org/r/20240401185821.224068-2-ubizjak@gmail.com +Signed-off-by: Alexei Starovoitov +",,Fixes instruction pointer offset calculation for x86 BPF call depth accounting.,"IP,call depth,x86",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,['tracepoints like programs'] +d29a8134c78232213fb88f20d7ae865ec364e367,d29a8134c78232213fb88f20d7ae865ec364e367,Michal Schmidt,mschmidt@redhat.com,1711408838,Tony Nguyen,anthony.l.nguyen@intel.com,1711987089,290f1daf4c297a3cd23d6a76ca298ea600e8ab5a,0e2bddf9e5f926ce32ed635012d0f8a0b54075d5,"ice: avoid the PTP hardware semaphore in gettimex64 path + +The PTP hardware semaphore (PFTSYN_SEM) is used to synchronize +operations that program the PTP timers. The operations involve issuing +commands to the sideband queue. The E810 does not have a hardware +sideband queue"," so the admin queue is used. The admin queue is slow. +I have observed delays in hundreds of milliseconds waiting for +ice_sq_done. + +When phc2sys reads the time from the ice PTP clock and PFTSYN_SEM is +held by a task performing one of the slow operations","[' ice_ptp_lock can\neasily time out. phc2sys gets -EBUSY and the kernel prints:\n ice 0000:XX:YY.0: PTP failed to get time\nThese messages appear once every few seconds', "" causing log spam.\n\nThe E810 datasheet recommends an algorithm for reading the upper 64 bits\nof the GLTSYN_TIME register. It matches what's implemented in\nice_ptp_read_src_clk_reg. It is robust against wrap-around"", ' but not\nnecessarily against the concurrent setting of the register (with\nGLTSYN_CMD_{INIT', 'ADJ}_TIME commands). Perhaps that\'s why\nice_ptp_gettimex64 also takes PFTSYN_SEM.\n\nThe race with time setters can be prevented without relying on the PTP\nhardware semaphore. Using the ""ice_adapter"" from the previous patch', '\nwe can have a common spinlock for the PFs that share the clock hardware.\nIt will protect the reading and writing to the GLTSYN_TIME register.\nThe writing is performed indirectly', ' by the hardware', "" as a result of\nthe driver writing GLTSYN_CMD_SYNC in ice_ptp_exec_tmr_cmd. I wasn't\nsure if the ice_flush there is enough to make sure GLTSYN_TIME has been\nupdated"", ' but it works well in my testing.\n\nMy test code can be seen here:\nhttps://gitlab.com/mschmidt2/linux/-/commits/ice-ptp-host-side-lock-10\nIt consists of:\n - kernel threads reading the time in a busy loop and looking at the\n deltas between consecutive values', ' reporting new maxima.\n - a shell script that sets the time repeatedly;\n - a bpftrace probe to produce a histogram of the measured deltas.\nWithout the spinlock ptp_gltsyn_time_lock', ' it is easy to see tearing.\nDeltas in the [2G', ' 4G) range appear in the histograms.\nWith the spinlock added', ' there is no tearing and the biggest delta I saw\nwas in the range [1M', ' 2M)', ' that is under 2 ms.\n\nReviewed-by: Jacob Keller \nReviewed-by: Przemek Kitszel \nSigned-off-by: Michal Schmidt \nTested-by: Pucha Himasekhar Reddy (A Contingent worker at Intel)\nSigned-off-by: Tony Nguyen \n', '']",Improve gettimex64 path by avoiding PTP hardware semaphore in ice driver to reduce delays.,"PTP hardware, ice driver, semaphore",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +623bdd58be3727318d374f0052f9dfff1e87b854,623bdd58be3727318d374f0052f9dfff1e87b854,Andrii Nakryiko,andrii@kernel.org,1711739050,Alexei Starovoitov,ast@kernel.org,1711757910,4fa897fca4d3678d7fe97924daa9a2c7d1f3ff73,59f2f841179aa6a0899cb9cf53659149a35749b7,"selftests/bpf: make multi-uprobe tests work in RELEASE=1 mode + +When BPF selftests are built in RELEASE=1 mode with -O2 optimization +level", uprobe_multi binary,"[' called from multi-uprobe tests is optimized\nto the point that all the thousands of target uprobe_multi_func_XXX\nfunctions are eliminated', ' breaking tests.\n\nSo ensure they are preserved by using weak attribute.\n\nBut', ' actually', ' compiling uprobe_multi binary with -O2 takes a really\nlong time', "" and is quite useless (it's not a benchmark). So in addition\nto ensuring that uprobe_multi_func_XXX functions are preserved"", ' opt-out\nof -O2 explicitly in Makefile and stick to -O0. This saves a lot of\ncompilation time.\n\nWith -O2', ' just recompiling uprobe_multi:\n\n $ touch uprobe_multi.c\n $ time make RELEASE=1 -j90\n make RELEASE=1 -j90 291.66s user 2.54s system 99% cpu 4:55.52 total\n\nWith -O0:\n $ touch uprobe_multi.c\n $ time make RELEASE=1 -j90\n make RELEASE=1 -j90 22.40s user 1.91s system 99% cpu 24.355 total\n\n5 minutes vs (still slow', ' but...) 24 seconds.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240329190410.4191353-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Improve multi-uprobe tests compatibility with RELEASE=1 optimization mode.,"selftests,uprobe,RELEASE",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +59f2f841179aa6a0899cb9cf53659149a35749b7,59f2f841179aa6a0899cb9cf53659149a35749b7,Alexei Starovoitov,ast@kernel.org,1711732479,Andrii Nakryiko,andrii@kernel.org,1711735841,6062529deb60350ea15098e82d721feda3661b6a,201874fc064ef14c26ea87a890b3f58296750d2d,"bpf: Avoid kfree_rcu() under lock in bpf_lpm_trie. + +syzbot reported the following lock sequence: +cpu 2: + grabs timer_base lock + spins on bpf_lpm lock + +cpu 1: + grab rcu krcp lock + spins on timer_base lock + +cpu 0: + grab bpf_lpm lock + spins on rcu krcp lock + +bpf_lpm lock can be the same. +timer_base lock can also be the same due to timer migration. +but rcu krcp lock is always per-cpu"," so it cannot be the same lock. +Hence it's a false positive. +To avoid lockdep complaining move kfree_rcu() after spin_unlock. + +Reported-by: syzbot+1fa663a2100308ab6eab@syzkaller.appspotmail.com +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240329171439.37813-1-alexei.starovoitov@gmail.com +",[''],The commit fixes a lock ordering issue by moving kfree_rcu() outside of the spinlock in bpf_lpm_trie.,"bpf_lpm_trie, lock, kfree_rcu",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['other'] +6dae957c8eef6eae5b386462767de97303235d5c,6dae957c8eef6eae5b386462767de97303235d5c,Anton Protopopov,aspsk@isovalent.com,1711696266,Alexei Starovoitov,ast@kernel.org,1711729195,8f4fc7437c90ad0f729dee0bbeb214ccea6d794e,62248b22d01e96a4d669cde0d7005bd51ebf9e76,"bpf: fix possible file descriptor leaks in verifier + +The resolve_pseudo_ldimm64() function might have leaked file +descriptors when BPF_MAP_TYPE_ARENA was used in a program (some +error paths missed a corresponding fdput). Add missing fdputs. + +v2: + remove unrelated changes from the fix + +Fixes: 6082b6c328b5 (""bpf: Recognize addr_space_cast instruction in the verifier."") +Signed-off-by: Anton Protopopov +Acked-by: Yonghong Song +Acked-by: Shung-Hsi Yu +Link: https://lore.kernel.org/r/20240329071106.67968-1-aspsk@isovalent.com +Signed-off-by: Alexei Starovoitov +",,Fixes file descriptor leaks in verifier for BPF_MAP_TYPE_ARENA programs.,"verifier, file descriptors, BPF_MAP_TYPE_ARENA",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +201874fc064ef14c26ea87a890b3f58296750d2d,201874fc064ef14c26ea87a890b3f58296750d2d,Martin KaFai Lau,martin.lau@kernel.org,1711677865,Martin KaFai Lau,martin.lau@kernel.org,1711678335,b1eea389e165399816ff726962efc56e875459ca,e8742081db7d01f980c6161ae1e8a1dbc1e30979 426670929fda4485a23094e03cea5d9b3ca918aa,"Merge branch 'Use start_server and connect_fd_to_fd' + +Geliang Tang says: + +==================== +Simplify bpf_tcp_ca test by using connect_fd_to_fd and start_server +helpers. + +v4: + - Matt reminded me that I shouldn't send a square-to patch to BPF (thanks)"," + so I update them into two patches in v4. + +v3: + - split v2 as two patches as Daniel suggested. + - The patch ""selftests/bpf: Use start_server in bpf_tcp_ca"" is merged + by Daniel (thanks)","["" but I forgot to drop 'settimeo(lfd"", "" 0)' in it"", ' so\n I send a squash-to patch to fix this.\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",Simplify bpf_tcp_ca test using connect_fd_to_fd and start_server helpers.,"simplify, bpf_tcp_ca, helpers",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tc/netfilter like programs'] +426670929fda4485a23094e03cea5d9b3ca918aa,426670929fda4485a23094e03cea5d9b3ca918aa,Geliang Tang,tanggeliang@kylinos.cn,1711447419,Martin KaFai Lau,martin.lau@kernel.org,1711678335,b1eea389e165399816ff726962efc56e875459ca,e5e1a3aa56773d55dfb71c4d58176bc19ecfa739,"selftests/bpf: Drop settimeo in do_test + +settimeo is invoked in start_server() and in connect_fd_to_fd() already"," +no need to invoke settimeo(lfd","[' 0) and settimeo(fd', ' 0) in do_test()\nanymore. This patch drops them.\n\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/dbc3613bee3b1c78f95ac9ff468bf47c92f106ea.1711447102.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Remove unnecessary settimeo invocation from selftests in BPF test suite.,"settimeo,test,removal",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +e5e1a3aa56773d55dfb71c4d58176bc19ecfa739,e5e1a3aa56773d55dfb71c4d58176bc19ecfa739,Geliang Tang,tanggeliang@kylinos.cn,1711447418,Martin KaFai Lau,martin.lau@kernel.org,1711678334,54393377c996ac3fece9b20b2d9cc5c008fac3db,e8742081db7d01f980c6161ae1e8a1dbc1e30979,"selftests/bpf: Use connect_fd_to_fd in bpf_tcp_ca + +To simplify the code"," use BPF selftests helper connect_fd_to_fd() in +bpf_tcp_ca.c instead of open-coding it. This helper is defined in +network_helpers.c","[' and exported in network_helpers.h', ' which is already\nincluded in bpf_tcp_ca.c.\n\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/e105d1f225c643bee838409378dd90fd9aabb6dc.1711447102.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Simplifies bpf_tcp_ca selftest by using connect_fd_to_fd helper from network_helpers.,"selftests, connect_fd_to_fd, simplify",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e8742081db7d01f980c6161ae1e8a1dbc1e30979,e8742081db7d01f980c6161ae1e8a1dbc1e30979,Martin KaFai Lau,martin.lau@kernel.org,1711652281,Alexei Starovoitov,ast@kernel.org,1711677659,452aea3442eddfe5248914ebd4680a45759104c2,e478cf26c556e4ab572ab0ab2306c986901dcd61,"bpf: Mark bpf prog stack with kmsan_unposion_memory in interpreter mode + +syzbot reported uninit memory usages during map_{lookup","delete}_elem. + +========== +BUG: KMSAN: uninit-value in __dev_map_lookup_elem kernel/bpf/devmap.c:441 [inline] +BUG: KMSAN: uninit-value in dev_map_lookup_elem+0xf3/0x170 kernel/bpf/devmap.c:796 +__dev_map_lookup_elem kernel/bpf/devmap.c:441 [inline] +dev_map_lookup_elem+0xf3/0x170 kernel/bpf/devmap.c:796 +____bpf_map_lookup_elem kernel/bpf/helpers.c:42 [inline] +bpf_map_lookup_elem+0x5c/0x80 kernel/bpf/helpers.c:38 +___bpf_prog_run+0x13fe/0xe0f0 kernel/bpf/core.c:1997 +__bpf_prog_run256+0xb5/0xe0 kernel/bpf/core.c:2237 +========== + +The reproducer should be in the interpreter mode. + +The C reproducer is trying to run the following bpf prog: + + 0: (18) r0 = 0x0 + 2: (18) r1 = map[id:49] + 4: (b7) r8 = 16777216 + 5: (7b) *(u64 *)(r10 -8) = r8 + 6: (bf) r2 = r10 + 7: (07) r2 += -229 + ^^^^^^^^^^ + + 8: (b7) r3 = 8 + 9: (b7) r4 = 0 + 10: (85) call dev_map_lookup_elem#1543472 + 11: (95) exit + +It is due to the ""void *key"" (r2) passed to the helper. bpf allows uninit +stack memory access for bpf prog with the right privileges. This patch +uses kmsan_unpoison_memory() to mark the stack as initialized. + +This should address different syzbot reports on the uninit ""void *key"" +argument during map_{lookup","['delete}_elem.\n\nReported-by: syzbot+603bcd9b0bf1d94dbb9b@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/000000000000f9ce6d061494e694@google.com/\nReported-by: syzbot+eb02dc7f03dce0ef39f3@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/000000000000a5c69c06147c2238@google.com/\nReported-by: syzbot+b4e65ca24fd4d0c734c3@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/000000000000ac56fb06143b6cfa@google.com/\nReported-by: syzbot+d2b113dc9fea5e1d2848@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/0000000000000d69b206142d1ff7@google.com/\nReported-by: syzbot+1a3cf6f08d68868f9db3@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/0000000000006f876b061478e878@google.com/\nTested-by: syzbot+1a3cf6f08d68868f9db3@syzkaller.appspotmail.com\nSuggested-by: Yonghong Song \nSuggested-by: Alexei Starovoitov \nSigned-off-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20240328185801.1843078-1-martin.lau@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",The commit marks BPF program stack with kmsan_unpoison_memory in interpreter mode to address uninitialized memory usage during map lookups.,"kmsan_unpoison_memory, uninit-memory, interpreter",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1a80dbcb2dbaf6e4c216e62e30fa7d3daa8001ce,1a80dbcb2dbaf6e4c216e62e30fa7d3daa8001ce,Andrii Nakryiko,andrii@kernel.org,1711603466,Alexei Starovoitov,ast@kernel.org,1711676865,7276f8f65e83ccafdc154e29f5db8bc9821272f1,e9c856cabefb71d47b2eeb197f72c9c88e9b45b0,"bpf: support deferring bpf_link dealloc to after RCU grace period + +BPF link for some program types is passed as a ""context"" which can be +used by those BPF programs to look up additional information. E.g."," for +multi-kprobes and multi-uprobes","[' link is used to fetch BPF cookie values.\n\nBecause of this runtime dependency', ' when bpf_link refcnt drops to zero\nthere could still be active BPF programs running accessing link data.\n\nThis patch adds generic support to defer bpf_link dealloc callback to\nafter RCU GP', ' if requested. This is done by exposing two different\ndeallocation callbacks', ' one synchronous and one deferred. If deferred\none is provided', ' bpf_link_free() will schedule dealloc_deferred()\ncallback to happen after RCU GP.\n\nBPF is using two flavors of RCU: ""classic"" non-sleepable one and RCU\ntasks trace one. The latter is used when sleepable BPF programs are\nused. bpf_link_free() accommodates that by checking underlying BPF\nprogram\'s sleepable flag', ' and goes either through normal RCU GP only for\nnon-sleepable', ' or through RCU tasks trace GP *and* then normal RCU GP\n(taking into account rcu_trace_implies_rcu_gp() optimization)', ' if BPF\nprogram is sleepable.\n\nWe use this for multi-kprobe and multi-uprobe links', ' which dereference\nlink during program run. We also preventively switch raw_tp link to use\ndeferred dealloc callback', ' as upcoming changes in bpf-next tree expose\nraw_tp link data (specifically', ' cookie value) to BPF program at runtime\nas well.\n\nFixes: 0dcac2725406 (""bpf: Add multi kprobe link"")\nFixes: 89ae89f53d20 (""bpf: Add multi uprobe link"")\nReported-by: syzbot+981935d9485a560bfbcb@syzkaller.appspotmail.com\nReported-by: syzbot+2cb5a6c573e98db598cc@syzkaller.appspotmail.com\nReported-by: syzbot+62d8b26793e8a2bd0516@syzkaller.appspotmail.com\nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/r/20240328052426.3042617-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Support added for deferring bpf_link deallocation to post RCU grace period in eBPF.,"bpf_link, RCU, deallocation",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +e9c856cabefb71d47b2eeb197f72c9c88e9b45b0,e9c856cabefb71d47b2eeb197f72c9c88e9b45b0,Andrii Nakryiko,andrii@kernel.org,1711603465,Alexei Starovoitov,ast@kernel.org,1711676865,29cf5df350ae5d3441fc6dcd010bc06e21509659,037965402a010898d34f4e35327d22c0a95cd51f,"bpf: put uprobe link's path and task in release callback + +There is no need to delay putting either path or task to deallocation +step. It can be done right after bpf_uprobe_unregister. Between release +and dealloc", there could be still some running BPF programs,"["" but they\ndon't access either task or path"", ' only data in link->uprobes', ' so it is\nsafe to do.\n\nOn the other hand', "" doing path_put() in dealloc callback makes this\ndealloc sleepable because path_put() itself might sleep. Which is\nproblematic due to the need to call uprobe's dealloc through call_rcu()"", '\nwhich is what is done in the next bug fix patch. So solve the problem by\nreleasing these resources early.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240328052426.3042617-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Optimize allocation timing for uprobe link's path and task in BPF.,"uprobe,release,deallocation",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +e478cf26c556e4ab572ab0ab2306c986901dcd61,e478cf26c556e4ab572ab0ab2306c986901dcd61,Alexei Starovoitov,ast@kernel.org,1711590829,Alexei Starovoitov,ast@kernel.org,1711675901,a9404bc5f4df93821255a1867c7365b5ddae9d1e,5da7fb04902b0f0fcd13bc5ef216e232fa971efa 6302bdeb91df9b4484b9d537c29f8b6117f3f73d,"Merge branch 'bpf-fix-a-couple-of-test-failures-with-lto-kernel' + +Yonghong Song says: + +==================== +bpf: Fix a couple of test failures with LTO kernel + +With a LTO kernel built with clang", with one of earlier version of kernel,"['\nI encountered two test failures', ' ksyms and kprobe_multi_bench_attach/kernel.\nNow with latest bpf-next', ' only kprobe_multi_bench_attach/kernel failed.\nBut it is possible in the future ksyms selftest may fail again.\n\nBoth test failures are due to static variable/function renaming\ndue to cross-file inlining. For Ksyms failure', ' the solution is\nto strip .llvm. suffixes for symbols in /proc/kallsyms before\ncomparing against the ksym in bpf program.\nFor kprobe_multi_bench_attach/kernel failure', ' the solution is\nto either provide names in /proc/kallsyms to the kernel or\nignore those names who have .llvm. suffix since the kernel\nsym name comparison is against /proc/kallsyms.\n\nPlease see each individual patches for details.\n\nChangelogs:\n v2 -> v3:\n - no need to check config file', "" directly so strstr with '.llvm.'.\n - for kprobe_multi_bench with syms"", ' instead of skipping the syms', '\n consult /proc/kallyms to find corresponding names.\n - add a test with populating addrs to the kernel for kprobe\n multi attach.\n v1 -> v2:\n - Let libbpf handle .llvm.\n', '']",Fix test failures in BPF with LTO kernel built using clang.,"fix, LTO, test failures",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6302bdeb91df9b4484b9d537c29f8b6117f3f73d,6302bdeb91df9b4484b9d537c29f8b6117f3f73d,Yonghong Song,yonghong.song@linux.dev,1711426523,Alexei Starovoitov,ast@kernel.org,1711675901,a9404bc5f4df93821255a1867c7365b5ddae9d1e,9edaafadc2c50f2af99ee5b3bad6831e1b6ad54f,"selftests/bpf: Add a kprobe_multi subtest to use addrs instead of syms + +Get addrs directly from available_filter_functions_addrs and +send to the kernel during kprobe_multi_attach. This avoids +consultation of /proc/kallsyms. But available_filter_functions_addrs +is introduced in 6.5", i.e.,"[' it is introduced recently', '\nso I skip the test if the kernel does not support it.\n\nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240326041523.1200301-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Added a subtest for kprobe_multi using direct addresses instead of symbols in selftests/bpf.,"kprobe_multi, addresses, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +9edaafadc2c50f2af99ee5b3bad6831e1b6ad54f,9edaafadc2c50f2af99ee5b3bad6831e1b6ad54f,Yonghong Song,yonghong.song@linux.dev,1711426518,Alexei Starovoitov,ast@kernel.org,1711675901,cb8822b47b8f6f1ceb2d377089538dcbaf3fdff0,d1f02581059e42d8daf944aae2a296254cc7a5d5,"selftests/bpf: Fix kprobe_multi_bench_attach test failure with LTO kernel + +In my locally build clang LTO kernel (enabling CONFIG_LTO and +CONFIG_LTO_CLANG_THIN)"," kprobe_multi_bench_attach/kernel subtest +failed like: + test_kprobe_multi_bench_attach:PASS:get_syms 0 nsec + test_kprobe_multi_bench_attach:PASS:kprobe_multi_empty__open_and_load 0 nsec + libbpf: prog 'test_kprobe_empty': failed to attach: No such process + test_kprobe_multi_bench_attach:FAIL:bpf_program__attach_kprobe_multi_opts unexpected error: -3 + #117/1 kprobe_multi_bench_attach/kernel:FAIL + +There are multiple symbols in /sys/kernel/debug/tracing/available_filter_functions +are renamed in /proc/kallsyms due to cross file inlining. One example is for + static function __access_remote_vm in mm/memory.c. +In a non-LTO kernel","[' we have the following call stack:\n ptrace_access_vm (global', ' kernel/ptrace.c)\n access_remote_vm (global', ' mm/memory.c)\n __access_remote_vm (static', ' mm/memory.c)\n\nWith LTO kernel', ' it is possible that access_remote_vm() is inlined by\nptrace_access_vm(). So we end up with the following call stack:\n ptrace_access_vm (global', ' kernel/ptrace.c)\n __access_remote_vm (static', ' mm/memory.c)\nThe compiler renames __access_remote_vm to __access_remote_vm.llvm.\nto prevent potential name collision.\n\nThe kernel bpf_kprobe_multi_link_attach() and ftrace_lookup_symbols() try\nto find addresses based on /proc/kallsyms', ' hence the current test failed\nwith LTO kenrel.\n\nThis patch consulted /proc/kallsyms to find the corresponding entries\nfor the ksym and this solved the issue.\n\nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240326041518.1199758-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes test failure in kprobe_multi_bench_attach due to symbol renaming in LTO kernels.,"kprobe_multi,LTO,fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +d1f02581059e42d8daf944aae2a296254cc7a5d5,d1f02581059e42d8daf944aae2a296254cc7a5d5,Yonghong Song,yonghong.song@linux.dev,1711426513,Alexei Starovoitov,ast@kernel.org,1711675901,f922a82d4fd55aca85b68c3b69c53468a05221a3,9475dacb75e0b5efae086dc904f4d27c31f15157,selftests/bpf: Add {load,"search}_kallsyms_custom_local() + +These two functions allow selftests to do loading/searching +kallsyms based on their specific compare functions. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041513.1199440-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",[''],New functions added for loading and searching kallsyms for selftests in the BPF subsystem.,"selftests, kallsyms, functions",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9475dacb75e0b5efae086dc904f4d27c31f15157,9475dacb75e0b5efae086dc904f4d27c31f15157,Yonghong Song,yonghong.song@linux.dev,1711426508,Alexei Starovoitov,ast@kernel.org,1711675901,134bb369d3b7db7ce1d8b226a2fdee42a09d21b3,d1320649346c36c5ba7b579533bf518960ef71e1,"selftests/bpf: Refactor trace helper func load_kallsyms_local() + +Refactor trace helper function load_kallsyms_local() such that +it invokes a common function with a compare function as input. +The common function will be used later for other local functions. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041508.1199239-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,Refactor trace helper function to use a common function with a comparison input for future usage.,"refactor, trace, helper",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +d1320649346c36c5ba7b579533bf518960ef71e1,d1320649346c36c5ba7b579533bf518960ef71e1,Yonghong Song,yonghong.song@linux.dev,1711426503,Alexei Starovoitov,ast@kernel.org,1711675901,6bd684eab2b47aa198dae507140d52e72ac3231d,c56e59776f46d77984329488878a52baf4969457,"selftests/bpf: Refactor some functions for kprobe_multi_test + +Refactor some functions in kprobe_multi_test.c to extract +some helper functions who will be used in later patches +to avoid code duplication. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041503.1198982-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,"Refactor functions in kprobe_multi_test.c to create reusable helpers for future patches, reducing code duplication.","refactor, kprobe, helper",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +c56e59776f46d77984329488878a52baf4969457,c56e59776f46d77984329488878a52baf4969457,Yonghong Song,yonghong.song@linux.dev,1711426498,Alexei Starovoitov,ast@kernel.org,1711675901,be758cc08439721f96824d76eec134e6c89ac741,ad2b05286e94485070475e473963724fa657491c,"libbpf: Handle .llvm. symbol properly + +With CONFIG_LTO_CLANG_THIN enabled"," with some of previous +version of kernel code base ([1])","["" I hit the following\nerror:\n test_ksyms:PASS:kallsyms_fopen 0 nsec\n test_ksyms:FAIL:ksym_find symbol 'bpf_link_fops' not found\n #118 ksyms:FAIL\n\nThe reason is that 'bpf_link_fops' is renamed to\n bpf_link_fops.llvm.8325593422554671469\nDue to cross-file inlining"", "" the static variable 'bpf_link_fops'\nin syscall.c is used by a function in another file. To avoid\npotential duplicated names"", "" the llvm added suffix\n'.llvm.' ([2]) to 'bpf_link_fops' variable.\nSuch renaming caused a problem in libbpf if 'bpf_link_fops'\nis used in bpf prog as a ksym but 'bpf_link_fops' does not\nmatch any symbol in /proc/kallsyms.\n\nTo fix this issue"", "" libbpf needs to understand that suffix '.llvm.'\nis caused by clang lto kernel and to process such symbols properly.\n\nWith latest bpf-next code base built with CONFIG_LTO_CLANG_THIN"", '\nI cannot reproduce the above failure any more. But such an issue\ncould happen with other symbols or in the future for bpf_link_fops symbol.\n\nFor example', ' with my current kernel', ' I got the following from\n/proc/kallsyms:\n ffffffff84782154 d __func__.net_ratelimit.llvm.6135436931166841955\n ffffffff85f0a500 d tk_core.llvm.726630847145216431\n ffffffff85fdb960 d __fs_reclaim_map.llvm.10487989720912350772\n ffffffff864c7300 d fake_dst_ops.llvm.54750082607048300\n\nI could not easily create a selftest to test newly-added\nlibbpf functionality with a static C test since I do not know\nwhich symbol is cross-file inlined. But based on my particular kernel', '\nthe following test change can run successfully.\n\n> diff --git a/tools/testing/selftests/bpf/prog_tests/ksyms.c b/tools/testing/selftests/bpf/prog_tests/ksyms.c\n> index 6a86d1f07800..904a103f7b1d 100644\n> --- a/tools/testing/selftests/bpf/prog_tests/ksyms.c\n> +++ b/tools/testing/selftests/bpf/prog_tests/ksyms.c\n> @@ -42', '6 +42', '7 @@ void test_ksyms(void)\n> ASSERT_EQ(data->out__bpf_link_fops', ' link_fops_addr', ' ""bpf_link_fops"");\n> ASSERT_EQ(data->out__bpf_link_fops1', ' 0', ' ""bpf_link_fops1"");\n> ASSERT_EQ(data->out__btf_size', ' btf_size', ' ""btf_size"");\n> + ASSERT_NEQ(data->out__fake_dst_ops', ' 0', ' ""fake_dst_ops"");\n> ASSERT_EQ(data->out__per_cpu_start', ' per_cpu_start_addr', ' ""__per_cpu_start"");\n>\n> cleanup:\n> diff --git a/tools/testing/selftests/bpf/progs/test_ksyms.c b/tools/testing/selftests/bpf/progs/test_ksyms.c\n> index 6c9cbb5a3bdf..fe91eef54b66 100644\n> --- a/tools/testing/selftests/bpf/progs/test_ksyms.c\n> +++ b/tools/testing/selftests/bpf/progs/test_ksyms.c\n> @@ -9', '11 +9', '13 @@ __u64 out__bpf_link_fops = -1;\n> __u64 out__bpf_link_fops1 = -1;\n> __u64 out__btf_size = -1;\n> __u64 out__per_cpu_start = -1;\n> +__u64 out__fake_dst_ops = -1;\n>\n> extern const void bpf_link_fops __ksym;\n> extern const void __start_BTF __ksym;\n> extern const void __stop_BTF __ksym;\n> extern const void __per_cpu_start __ksym;\n> +extern const void fake_dst_ops __ksym;\n> /* non-existing symbol', ' weak', ' default to zero */\n> extern const void bpf_link_fops1 __ksym __weak;\n>\n> @@ -23', '6 +25', ""7 @@ int handler(const void *ctx)\n> out__bpf_link_fops = (__u64)&bpf_link_fops;\n> out__btf_size = (__u64)(&__stop_BTF - &__start_BTF);\n> out__per_cpu_start = (__u64)&__per_cpu_start;\n> + out__fake_dst_ops = (__u64)&fake_dst_ops;\n>\n> out__bpf_link_fops1 = (__u64)&bpf_link_fops1;\n\nThis patch fixed the issue in libbpf such that\nthe suffix '.llvm.' will be ignored during comparison of\nbpf prog ksym vs. symbols in /proc/kallsyms"", ' this resolved the issue.\nCurrently', "" only static variables in /proc/kallsyms are checked\nwith '.llvm.' suffix since in bpf programs function ksyms\nwith '.llvm.' suffix are most likely kfunc's and unlikely\nto be cross-file inlined.\n\nNote that currently kernel does not support gcc build with lto.\n\n [1] https://lore.kernel.org/bpf/20240302165017.1627295-1-yonghong.song@linux.dev/\n [2] https://github.com/llvm/llvm-project/blob/release/18.x/llvm/include/llvm/IR/ModuleSummaryIndex.h#L1714-L1719\n\nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240326041458.1198161-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n"", '']",Handles the .llvm. symbol properly in libbpf with CONFIG_LTO_CLANG_THIN enabled.,libbpf symbol handling,It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ad2b05286e94485070475e473963724fa657491c,ad2b05286e94485070475e473963724fa657491c,Yonghong Song,yonghong.song@linux.dev,1711426493,Alexei Starovoitov,ast@kernel.org,1711675901,68d8f28e5f7d7dbf306cc20d2961125248372bbe,cdfd9cc3ba147ceea650afa6b7031e31a98d500e,"libbpf: Mark libbpf_kallsyms_parse static function + +Currently libbpf_kallsyms_parse() function is declared as a global +function but actually it is not a API and there is no external +users in bpftool/bpf-selftests. So let us mark the function as +static. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041453.1197949-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,The commit marks libbpf_kallsyms_parse function as static since it is not used externally.,"libbpf,static,function",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cdfd9cc3ba147ceea650afa6b7031e31a98d500e,cdfd9cc3ba147ceea650afa6b7031e31a98d500e,Yonghong Song,yonghong.song@linux.dev,1711426488,Alexei Starovoitov,ast@kernel.org,1711675901,88e523f9118aefb1d02fc15de5a794d14e670d6a,5da7fb04902b0f0fcd13bc5ef216e232fa971efa,"selftests/bpf: Replace CHECK with ASSERT macros for ksyms test + +Replace CHECK with ASSERT macros for ksyms tests. +This test failed earlier with clang lto kernel"," but the +issue is gone with latest code base. But replacing +CHECK with ASSERT still improves code as ASSERT is +preferred in selftests. + +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240326041448.1197812-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",[''],Replaced CHECK with ASSERT macros in ksyms test for improved code quality in selftests.,"ASSERT, ksyms, selftests",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +5da7fb04902b0f0fcd13bc5ef216e232fa971efa,5da7fb04902b0f0fcd13bc5ef216e232fa971efa,Martin KaFai Lau,martin.lau@kernel.org,1711134873,Alexei Starovoitov,ast@kernel.org,1711675900,6e4de114a369c8e76c53496249cf16f07682d4db,42e4ebd390be8e0090d64d58433b6cba45d919e9,"selftests/bpf: Test loading bpf-tcp-cc prog calling the kernel tcp-cc kfuncs + +This patch adds a test to ensure all static tcp-cc kfuncs is visible to +the struct_ops bpf programs. It is checked by successfully loading +the struct_ops programs calling these tcp-cc kfuncs. + +This patch needs to enable the CONFIG_TCP_CONG_DCTCP and +the CONFIG_TCP_CONG_BBR. + +Signed-off-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20240322191433.4133280-2-martin.lau@linux.dev +Signed-off-by: Alexei Starovoitov +",,Add test for bpf-tcp-cc programs using kernel tcp-cc kfuncs.,"bpf-tcp-cc,kfuncs,struct_ops",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tc/netfilter like programs'] +42e4ebd390be8e0090d64d58433b6cba45d919e9,42e4ebd390be8e0090d64d58433b6cba45d919e9,Martin KaFai Lau,martin.lau@kernel.org,1711134872,Alexei Starovoitov,ast@kernel.org,1711675900,0fc02fbb41ee2a8833f9f4fe12c16b43e5e08942,ee3bad033d01066348913f3220ea81987721ed53,"bpf: Remove CONFIG_X86 and CONFIG_DYNAMIC_FTRACE guard from the tcp-cc kfuncs + +The commit 7aae231ac93b (""bpf: tcp: Limit calling some tcp cc functions to CONFIG_DYNAMIC_FTRACE"") +added CONFIG_DYNAMIC_FTRACE guard because pahole was only generating +btf for ftrace-able functions. The ftrace filter had already been +removed from pahole"," so the CONFIG_DYNAMIC_FTRACE guard can be +removed. + +The commit 569c484f9995 (""bpf: Limit static tcp-cc functions in the .BTF_ids list to x86"") +has added CONFIG_X86 guard because it failed the powerpc arch which +prepended a ""."" to the local static function","[' so ""cubictcp_init"" becomes\n"".cubictcp_init"". ""__bpf_kfunc"" has been added to kfunc\nsince then and it uses the __unused compiler attribute.\nThere is an existing\n""__bpf_kfunc static u32 bpf_kfunc_call_test_static_unused_arg(u32 arg', ' u32 unused)""\ntest in bpf_testmod.c to cover the static kfunc case.\n\ncross compile on ppc64 with CONFIG_DYNAMIC_FTRACE disabled:\n> readelf -s vmlinux | grep cubictcp_\n56938: c00000000144fd00 184 FUNC LOCAL DEFAULT 2 cubictcp_cwnd_event \t [: 8]\n56939: c00000000144fdb8 200 FUNC LOCAL DEFAULT 2 cubictcp_recalc_[...] [: 8]\n56940: c00000000144fe80 296 FUNC LOCAL DEFAULT 2 cubictcp_init \t [: 8]\n56941: c00000000144ffa8 228 FUNC LOCAL DEFAULT 2 cubictcp_state \t [: 8]\n56942: c00000000145008c 1908 FUNC LOCAL DEFAULT 2 cubictcp_cong_avoid [: 8]\n56943: c000000001450800 1644 FUNC LOCAL DEFAULT 2 cubictcp_acked \t [: 8]\n\n> bpftool btf dump file vmlinux | grep cubictcp_\n[51540] FUNC \'cubictcp_acked\' type_id=38137 linkage=static\n[51541] FUNC \'cubictcp_cong_avoid\' type_id=38122 linkage=static\n[51543] FUNC \'cubictcp_cwnd_event\' type_id=51542 linkage=static\n[51544] FUNC \'cubictcp_init\' type_id=9186 linkage=static\n[51545] FUNC \'cubictcp_recalc_ssthresh\' type_id=35021 linkage=static\n[51547] FUNC \'cubictcp_state\' type_id=38141 linkage=static\n\nThe patch removed both config guards.\n\nCc: Jiri Olsa \nSigned-off-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20240322191433.4133280-1-martin.lau@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",This commit removes configuration guards from tcp-cc kfuncs due to changes in ftrace requirements.,"CONFIG_X86,CONFIG_DYNAMIC_FTRACE,kfuncs",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['tc/netfilter like programs'] +ee3bad033d01066348913f3220ea81987721ed53,ee3bad033d01066348913f3220ea81987721ed53,Yafang Shao,laoar.shao@gmail.com,1711509622,Alexei Starovoitov,ast@kernel.org,1711675900,1a48e38c1129daf5ac5a5a62a61a04016db06dcf,a461a51e519aedee8aff518167451b250ce913b3,"bpf: Mitigate latency spikes associated with freeing non-preallocated htab + +Following the recent upgrade of one of our BPF programs"," we encountered +significant latency spikes affecting other applications running on the same +host. After thorough investigation","[' we identified that these spikes were\nprimarily caused by the prolonged duration required to free a\nnon-preallocated htab with approximately 2 million keys.\n\nNotably', ' our kernel configuration lacks the presence of CONFIG_PREEMPT. In\nscenarios where kernel execution extends excessively', ' other threads might\nbe starved of CPU time', ' resulting in latency issues across the system. To\nmitigate this', "" we've adopted a proactive approach by incorporating\ncond_resched() calls within the kernel code. This ensures that during\nlengthy kernel operations"", ' the scheduler is invoked periodically to provide\nopportunities for other threads to execute.\n\nSigned-off-by: Yafang Shao \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240327032022.78391-1-laoar.shao@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Mitigate latency spikes when freeing non-preallocated htab in a BPF program.,"latency, spikes, htab",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +985d0681b46be7db5ccc330d9a7f318b96ce0029,985d0681b46be7db5ccc330d9a7f318b96ce0029,Andrii Nakryiko,andrii@kernel.org,1711470111,Alexei Starovoitov,ast@kernel.org,1711675900,9930d2880ee3a9d0acc2575b52f6a868992b99e6,3124591f686115aca25d772c2ccb7b1e202c3197,"selftests/bpf: add batched tp/raw_tp/fmodret tests + +Utilize bpf_modify_return_test_tp() kfunc to have a fast way to trigger +tp/raw_tp/fmodret programs from another BPF program"," which gives us +comparable batched benchmarks to (batched) kprobe/fentry benchmarks. + +We don't switch kprobe/fentry batched benchmarks to this kfunc to make +bench tool usable on older kernels as well. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240326162151.3981687-7-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Added batched tests for tp/raw_tp/fmodret programs using bpf_modify_return_test_tp() kfunc.,"batched tests,kfunc,tp programs",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3124591f686115aca25d772c2ccb7b1e202c3197,3124591f686115aca25d772c2ccb7b1e202c3197,Andrii Nakryiko,andrii@kernel.org,1711470110,Alexei Starovoitov,ast@kernel.org,1711675900,e761705a15312f4cf7423a40035c3e78bb8e4901,b4ccf9158f5893dedb898687272fabfe80f58907,"bpf: add bpf_modify_return_test_tp() kfunc triggering tracepoint + +Add a simple bpf_modify_return_test_tp() kfunc"," available to all program +types","[' that is useful for various testing and benchmarking scenarios', ' as\nit allows to trigger most tracing BPF program types from BPF side', '\nallowing to do complex testing and benchmarking scenarios.\n\nIt is also attachable to for fmod_ret programs', ' making it a good and\nsimple way to trigger fmod_ret program under test/benchmark.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240326162151.3981687-6-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added new kfunc bpf_modify_return_test_tp() for triggering tracepoints in eBPF.,"bpf,kfunc,tracepoint",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['tracepoints like programs'] +b4ccf9158f5893dedb898687272fabfe80f58907,b4ccf9158f5893dedb898687272fabfe80f58907,Andrii Nakryiko,andrii@kernel.org,1711470109,Alexei Starovoitov,ast@kernel.org,1711675900,83864944c3c44f20a8e26b779ea7bb7b10f4e57b,208c4391204d25d9178fbc87f216daffad00cd15,"selftests/bpf: lazy-load trigger bench BPF programs + +Instead of front-loading all possible benchmarking BPF programs for +trigger benchmarks"," explicitly specify which BPF programs are used by +specific benchmark and load only it. + +This allows to be more flexible in supporting older kernels","[' where some\nprogram types might not be possible to load (e.g.', ' those that rely on\nnewly added kfunc).\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240326162151.3981687-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Implemented lazy-loading mechanism for BPF programs in selftests to support trigger benchmarks on older kernels.,"selftests, lazy-load, benchmarks",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +208c4391204d25d9178fbc87f216daffad00cd15,208c4391204d25d9178fbc87f216daffad00cd15,Andrii Nakryiko,andrii@kernel.org,1711470108,Alexei Starovoitov,ast@kernel.org,1711675900,a0eec206f8fb9c15dec0c1fbdc4b1a25b30f94e3,7df4e597ea2cfd677e65730948153d5544986a10,selftests/bpf: remove syscall-driven benchs," keep syscall-count only + +Remove ""legacy"" benchmarks triggered by syscalls in favor of newly added +in-kernel/batched benchmarks. Drop -batched suffix now as well. +Next patch will restore ""feature parity"" by adding back +tp/raw_tp/fmodret benchmarks based on in-kernel kfunc approach. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240326162151.3981687-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Removed syscall-driven benchmarks in favor of in-kernel batched benchmarks in selftests for BPF.,"benchmarks, syscall, batched",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7df4e597ea2cfd677e65730948153d5544986a10,7df4e597ea2cfd677e65730948153d5544986a10,Andrii Nakryiko,andrii@kernel.org,1711470107,Alexei Starovoitov,ast@kernel.org,1711675900,d1e7e35d4fd5d276b2a207a6eca1b39ae11a6a8f,1175f8dea349e5999d99727346db24f38306a793,selftests/bpf: add batched," mostly in-kernel BPF triggering benchmarks + +Existing kprobe/fentry triggering benchmarks have 1-to-1 mapping between +one syscall execution and BPF program run. While we use a fast +get_pgid() syscall","[' syscall overhead can still be non-trivial.\n\nThis patch adds kprobe/fentry set of benchmarks significantly amortizing\nthe cost of syscall vs actual BPF triggering overhead. We do this by\nemploying BPF_PROG_TEST_RUN command to trigger ""driver"" raw_tp program\nwhich does a tight parameterized loop calling cheap BPF helper\n(bpf_get_numa_node_id())', ' to which kprobe/fentry programs are\nattached for benchmarking.\n\nThis way 1 bpf() syscall causes N executions of BPF program being\nbenchmarked. N defaults to 100', ' but can be adjusted with\n--trig-batch-iters CLI argument.\n\nFor comparison we also implement a new baseline program that instead of\ntriggering another BPF program just does N atomic per-CPU counter\nincrements', ' establishing the limit for all other types of program within\nthis batched benchmarking setup.\n\nTaking the final set of benchmarks added in this patch set (including\ntp/raw_tp/fmodret', ' added in later patch)', ' and keeping for now ""legacy""\nsyscall-driven benchmarks', ' we can capture all triggering benchmarks in\none place for comparison', ' before we remove the legacy ones (and rename\nxxx-batched into just xxx).\n\n$ benchs/run_bench_trigger.sh\nusermode-count : 79.500 ± 0.024M/s\nkernel-count : 49.949 ± 0.081M/s\nsyscall-count : 9.009 ± 0.007M/s\n\nfentry-batch : 31.002 ± 0.015M/s\nfexit-batch : 20.372 ± 0.028M/s\nfmodret-batch : 21.651 ± 0.659M/s\nrawtp-batch : 36.775 ± 0.264M/s\ntp-batch : 19.411 ± 0.248M/s\nkprobe-batch : 12.949 ± 0.220M/s\nkprobe-multi-batch : 15.400 ± 0.007M/s\nkretprobe-batch : 5.559 ± 0.011M/s\nkretprobe-multi-batch: 5.861 ± 0.003M/s\n\nfentry-legacy : 8.329 ± 0.004M/s\nfexit-legacy : 6.239 ± 0.003M/s\nfmodret-legacy : 6.595 ± 0.001M/s\nrawtp-legacy : 8.305 ± 0.004M/s\ntp-legacy : 6.382 ± 0.001M/s\nkprobe-legacy : 5.528 ± 0.003M/s\nkprobe-multi-legacy : 5.864 ± 0.022M/s\nkretprobe-legacy : 3.081 ± 0.001M/s\nkretprobe-multi-legacy: 3.193 ± 0.001M/s\n\nNote how xxx-batch variants are measured with significantly higher\nthroughput', "" even though it's exactly the same in-kernel overhead. As\nsuch"", ' results can be compared only between benchmarks of the same kind\n(syscall vs batched):\n\nfentry-legacy : 8.329 ± 0.004M/s\nfentry-batch : 31.002 ± 0.015M/s\n\nkprobe-multi-legacy : 5.864 ± 0.022M/s\nkprobe-multi-batch : 15.400 ± 0.007M/s\n\nNote also that syscall-count is setting a theoretical limit for\nsyscall-triggered benchmarks', ' while kernel-count is setting similar\nlimits for batch variants. usermode-count is a happy and unachievable\ncase of user space counting without doing any syscalls', ' and is mostly\nthe measure of CPU speed for such a trivial benchmark.\n\nAs was mentioned', ' tp/raw_tp/fmodret require kernel-side kfunc to produce\nsimilar benchmark', ' which we address in a separate patch.\n\nNote that run_bench_trigger.sh allows to override a list of benchmarks\nto run', ' which is very useful for performance work.\n\nCc: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240326162151.3981687-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add batched benchmarks for selftests/bpf focusing on kprobe/fentry with faster syscall execution.,"batched, benchmarks, kprobe",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +1175f8dea349e5999d99727346db24f38306a793,1175f8dea349e5999d99727346db24f38306a793,Andrii Nakryiko,andrii@kernel.org,1711470106,Alexei Starovoitov,ast@kernel.org,1711675899,761ac31c678a6740f3912f08c6e514ee4fd5a559,55fc888ded83ed542f3de3e51bae03936a998349,"selftests/bpf: rename and clean up userspace-triggered benchmarks + +Rename uprobe-base to more precise usermode-count (it will match other +baseline-like benchmarks"," kernel-count and syscall-count). Also use +BENCH_TRIG_USERMODE() macro to define all usermode-based triggering +benchmarks","[' which include usermode-count and uprobe/uretprobe benchmarks.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240326162151.3981687-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Rename and clean up userspace-triggered benchmarks in selftests/bpf and use BENCH_TRIG_USERMODE macro.,"selftests, benchmarks, rename",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +55fc888ded83ed542f3de3e51bae03936a998349,55fc888ded83ed542f3de3e51bae03936a998349,Haiyue Wang,haiyue.wang@intel.com,1711522409,Alexei Starovoitov,ast@kernel.org,1711675896,bb602f9e29f284dcfb6a789e1d99624cb3810fc9,786bf0e7e2ec90b349a7bab6e97947982ab31f2c,bpf,"arena: Use helper sizeof_field in struct accessors + +Use the well defined helper sizeof_field() to calculate the size of a +struct member","[' instead of doing custom calculations.\n\nSigned-off-by: Haiyue Wang \nLink: https://lore.kernel.org/r/20240327065334.8140-1-haiyue.wang@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Use the sizeof_field helper for calculating struct member size within the arena.,"helper, struct, sizeof_field",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +786bf0e7e2ec90b349a7bab6e97947982ab31f2c,786bf0e7e2ec90b349a7bab6e97947982ab31f2c,Mykyta Yatsenko,yatsenko@meta.com,1711380130,Alexei Starovoitov,ast@kernel.org,1711675853,06035090d80edace56555e7454bc414989f07903,59b418c7063d30e0a3e1f592d47df096db83185c,"bpf: improve error message for unsupported helper + +BPF verifier emits ""unknown func"" message when given BPF program type +does not support BPF helper. This message may be confusing for users"," as +important context that helper is unknown only to current program type is +not provided. + +This patch changes message to ""program of this type cannot use helper "" +and aligns dependent code in libbpf and tests. Any suggestions on +improving/changing this message are welcome. + +Signed-off-by: Mykyta Yatsenko +Acked-by: Andrii Nakryiko +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/r/20240325152210.377548-1-yatsenko@meta.com +Signed-off-by: Alexei Starovoitov +",[''],Improves error message clarity in BPF verifier when unsupported helpers are used by certain BPF program types.,"error message, BPF verifier, helper",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +59b418c7063d30e0a3e1f592d47df096db83185c,59b418c7063d30e0a3e1f592d47df096db83185c,Anton Protopopov,aspsk@isovalent.com,1711448262,Alexei Starovoitov,ast@kernel.org,1711675853,43e256562b0e3e39ddc2f7acc35f44903dde0295,6efec2cb06411a577125b5f531a852c08ead1209,"bpf: Add a check for struct bpf_fib_lookup size + +The struct bpf_fib_lookup should not grow outside of its 64 bytes. +Add a static assert to validate this. + +Suggested-by: David Ahern +Signed-off-by: Anton Protopopov +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240326101742.17421-4-aspsk@isovalent.com +Signed-off-by: Alexei Starovoitov +",,Add a static check to ensure struct bpf_fib_lookup size remains 64 bytes.,"bpf_fib_lookup, static_assert, size_check",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6efec2cb06411a577125b5f531a852c08ead1209,6efec2cb06411a577125b5f531a852c08ead1209,Anton Protopopov,aspsk@isovalent.com,1711448261,Alexei Starovoitov,ast@kernel.org,1711675853,e9fff17ce16562758b4d40486ce3a96ee5b78431,5311591fbb349fe9f5c555dcba3b13a5831aa72d,"selftests/bpf: Add BPF_FIB_LOOKUP_MARK tests + +This patch extends the fib_lookup test suite by adding a few test +cases for each IP family to test the new BPF_FIB_LOOKUP_MARK flag +to the bpf_fib_lookup: + + * Test destination IP address selection with and without a mark + and/or the BPF_FIB_LOOKUP_MARK flag set + +Signed-off-by: Anton Protopopov +Signed-off-by: Daniel Borkmann +Acked-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240326101742.17421-3-aspsk@isovalent.com +Signed-off-by: Alexei Starovoitov +",,Extend the fib_lookup test suite with new test cases for BPF_FIB_LOOKUP_MARK flag.,"fib_lookup, BPF_FIB_LOOKUP_MARK, tests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tc/netfilter like programs'] +5311591fbb349fe9f5c555dcba3b13a5831aa72d,5311591fbb349fe9f5c555dcba3b13a5831aa72d,Anton Protopopov,aspsk@isovalent.com,1711448260,Alexei Starovoitov,ast@kernel.org,1711675852,a6cbe52ccc21dc1c9abb12eb64a9494e69ffcd0d,c602f4ca13a529b45692de4fdec96b4cdec866da,"bpf: Add support for passing mark with bpf_fib_lookup + +Extend the bpf_fib_lookup() helper by making it to utilize mark if +the BPF_FIB_LOOKUP_MARK flag is set. In order to pass the mark the +four bytes of struct bpf_fib_lookup are used"," shared with the +output-only smac/dmac fields. + +Signed-off-by: Anton Protopopov +Signed-off-by: Daniel Borkmann +Reviewed-by: David Ahern +Acked-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240326101742.17421-2-aspsk@isovalent.com +Signed-off-by: Alexei Starovoitov +",[''],Add support for passing mark with bpf_fib_lookup helper using BPF_FIB_LOOKUP_MARK flag.,"bpf_fib_lookup, mark, helper",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['tc/netfilter like programs'] +50108c352db70405b3d71d8099d0b3adc3b3352c,50108c352db70405b3d71d8099d0b3adc3b3352c,Linus Torvalds,torvalds@linux-foundation.org,1711656577,Linus Torvalds,torvalds@linux-foundation.org,1711656577,61ae73b4f540704f9727b6c24ef306de6a7da5fd,8d025e2092e29bfd13e56c78e22af25fac83c8ec 18685451fc4e546fc0e718580d32df3c0e5c8272,"Merge tag 'net-6.9-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + ""Including fixes from bpf"," WiFi and netfilter. + + Current release - regressions: + + - ipv6: fix address dump when IPv6 is disabled on an interface + + Current release - new code bugs: + + - bpf: temporarily disable atomic operations in BPF arena + + - nexthop: fix uninitialized variable in nla_put_nh_group_stats() + + Previous releases - regressions: + + - bpf: protect against int overflow for stack access size + + - hsr: fix the promiscuous mode in offload mode + + - wifi: don't always use FW dump trig + + - tls: adjust recv return with async crypto and failed copy to + userspace + + - tcp: properly terminate timers for kernel sockets + + - ice: fix memory corruption bug with suspend and rebuild + + - at803x: fix kernel panic with at8031_probe + + - qeth: handle deferred cc1 + + Previous releases - always broken: + + - bpf: fix bug in BPF_LDX_MEMSX + + - netfilter: reject table flag and netdev basechain updates + + - inet_defrag: prevent sk release while still in use + + - wifi: pick the version of SESSION_PROTECTION_NOTIF + + - wwan: t7xx: split 64bit accesses to fix alignment issues + + - mlxbf_gige: call request_irq() after NAPI initialized + + - hns3: fix kernel crash when devlink reload during pf + initialization"" + +* tag 'net-6.9-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (81 commits) + inet: inet_defrag: prevent sk release while still in use + Octeontx2-af: fix pause frame configuration in GMP mode + net: lan743x: Add set RFE read fifo threshold for PCI1x1x chips + net: bcmasp: Remove phy_{suspend/resume} + net: bcmasp: Bring up unimac after PHY link up + net: phy: qcom: at803x: fix kernel panic with at8031_probe + netfilter: arptables: Select NETFILTER_FAMILY_ARP when building arp_tables.c + netfilter: nf_tables: skip netdev hook unregistration if table is dormant + netfilter: nf_tables: reject table flag and netdev basechain updates + netfilter: nf_tables: reject destroy command to remove basechain hooks + bpf: update BPF LSM designated reviewer list + bpf: Protect against int overflow for stack access size + bpf: Check bloom filter map value size + bpf: fix warning for crash_kexec + selftests: netdevsim: set test timeout to 10 minutes + net: wan: framer: Add missing static inline qualifiers + mlxbf_gige: call request_irq() after NAPI initialized + tls: get psock ref after taking rxlock to avoid leak + selftests: tls: add test with a partially invalid iov + tls: adjust recv return with async crypto and failed copy to userspace + ... +",[''],Merge networking fixes including BPF and various bug resolutions for the 6.9-rc2 release.,"networking, BPF, fixes",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['tc/netfilter like programs', 'LSM like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7e6f4b2af5b8cfe028386bc439c9bad1eddff9a6,7e6f4b2af5b8cfe028386bc439c9bad1eddff9a6,Paolo Abeni,pabeni@redhat.com,1711616879,Paolo Abeni,pabeni@redhat.com,1711616880,50e1f79928073c9b2a70881a01f0a2eaf4367281,56d2f48ed8f857f2765575a6a25b9655765edd41 4dd651076ef0e5f09940f763a1b4e8a209dab7ab,"Merge tag 'for-net' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Alexei Starovoitov says: + +==================== +pull-request: bpf 2024-03-27 + +The following pull-request contains BPF updates for your *net* tree. + +We've added 4 non-merge commits during the last 1 day(s) which contain +a total of 5 files changed", 26 insertions(+),"[' 3 deletions(-).\n\nThe main changes are:\n\n1) Fix bloom filter value size validation and protect the verifier\n against such mistakes', ' from Andrei.\n\n2) Fix build due to CONFIG_KEXEC_CORE/CRASH_DUMP split', ' from Hari.\n\n3) Update bpf_lsm maintainers entry', "" from Matt.\n\n* tag 'for-net' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n bpf: update BPF LSM designated reviewer list\n bpf: Protect against int overflow for stack access size\n bpf: Check bloom filter map value size\n bpf: fix warning for crash_kexec\n====================\n\nLink: https://lore.kernel.org/r/20240328012938.24249-1-alexei.starovoitov@gmail.com\nSigned-off-by: Paolo Abeni \n"", '']",Merge BPF updates for net tree with 4 non-merge commits affecting 5 files.,"BPF, net, updates",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4dd651076ef0e5f09940f763a1b4e8a209dab7ab,4dd651076ef0e5f09940f763a1b4e8a209dab7ab,Matt Bobrowski,mattbobrowski@google.com,1711482619,Alexei Starovoitov,ast@kernel.org,1711563036,3ef103c9a06584bfc4293df39e189aa3e294eedf,a4e02d6b91c5e57f820032ec6ad794694c86f327,"bpf: update BPF LSM designated reviewer list + +Adding myself in place of both Brendan and Florent as both have since +moved on from working on the BPF LSM and will no longer be devoting +their time to maintaining the BPF LSM. + +Signed-off-by: Matt Bobrowski +Acked-by: KP Singh +Link: https://lore.kernel.org/r/ZgMhWF_egdYF8t4D@google.com +Signed-off-by: Alexei Starovoitov +",,Added Matt Bobrowski to BPF LSM designated reviewer list replacing Brendan and Florent.,"BPF, LSM, reviewer",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['LSM like programs'] +ecc6a2101840177e57c925c102d2d29f260d37c8,ecc6a2101840177e57c925c102d2d29f260d37c8,Andrei Matei,andreimatei1@gmail.com,1711507365,Alexei Starovoitov,ast@kernel.org,1711558596,bf6977a9ab0b8a0c54accee088371e52c6d6d08d,a8d89feba7e54e691ca7c4efc2a6264fa83f3687,"bpf: Protect against int overflow for stack access size + +This patch re-introduces protection against the size of access to stack +memory being negative; the access size can appear negative as a result +of overflowing its signed int representation. This should not actually +happen", as there are other protections along the way,"[' but we should\nprotect against it anyway. One code path was missing such protections\n(fixed in the previous patch in the series)', ' causing out-of-bounds array\naccesses in check_stack_range_initialized(). This patch causes the\nverification of a program with such a non-sensical access size to fail.\n\nThis check used to exist in a more indirect way', ' but was inadvertendly\nremoved in a833a17aeac7.\n\nFixes: a833a17aeac7 (""bpf: Fix verification of indirect var-off stack access"")\nReported-by: syzbot+33f4297b5f927648741a@syzkaller.appspotmail.com\nReported-by: syzbot+aafd0513053a1cbf52ef@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/CAADnVQLORV5PT0iTAhRER+iLBTkByCYNBYyvBSgjN1T31K+gOw@mail.gmail.com/\nAcked-by: Andrii Nakryiko \nSigned-off-by: Andrei Matei \nLink: https://lore.kernel.org/r/20240327024245.318299-3-andreimatei1@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit reintroduces protection against int overflow for stack access size in the eBPF subsystem.,"int overflow,stack access,protection",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a8d89feba7e54e691ca7c4efc2a6264fa83f3687,a8d89feba7e54e691ca7c4efc2a6264fa83f3687,Andrei Matei,andreimatei1@gmail.com,1711507364,Alexei Starovoitov,ast@kernel.org,1711558577,087d15f18cc99fa5355fe72cb0b91188b6c1d858,96b98a6552a90690d7bc18dd71b66312c9ded1fb,"bpf: Check bloom filter map value size + +This patch adds a missing check to bloom filter creating"," rejecting +values above KMALLOC_MAX_SIZE. This brings the bloom map in line with +many other map types. + +The lack of this protection can cause kernel crashes for value sizes +that overflow int's. Such a crash was caught by syzkaller. The next +patch adds more guard-rails at a lower level. + +Signed-off-by: Andrei Matei +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240327024245.318299-2-andreimatei1@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],This commit adds a check to prevent kernel crashes by ensuring bloom filter map values don't exceed KMALLOC_MAX_SIZE.,"bloom filter, kernel crash, KMALLOC_MAX_SIZE",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +96b98a6552a90690d7bc18dd71b66312c9ded1fb,96b98a6552a90690d7bc18dd71b66312c9ded1fb,Hari Bathini,hbathini@linux.ibm.com,1710835312,Alexei Starovoitov,ast@kernel.org,1711554744,8cca34488bc16a09f87a152a384eea495be68483,afbf75e8da8ce8a0698212953d350697bb4355a6,"bpf: fix warning for crash_kexec + +With [1]"," crash dump specific code is moved out of CONFIG_KEXEC_CORE +and placed under CONFIG_CRASH_DUMP","[' where it is more appropriate.\nAnd since CONFIG_KEXEC & !CONFIG_CRASH_DUMP build option is supported\nwith that', ' it led to the below warning:\n\n ""WARN: resolve_btfids: unresolved symbol crash_kexec""\n\nFix it by using the appropriate #ifdef.\n\n[1] https://lore.kernel.org/all/20240124051254.67105-1-bhe@redhat.com/\n\nAcked-by: Baoquan He \nFixes: 02aff8480533 (""crash: split crash dumping code out from kexec_core.c"")\nAcked-by: Jiri Olsa \nAcked-by: Stanislav Fomichev \nSigned-off-by: Hari Bathini \nLink: https://lore.kernel.org/r/20240319080152.36987-1-hbathini@linux.ibm.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix warning by moving crash dump specific code to CONFIG_CRASH_DUMP for proper configuration linkage.,"fix, warning, crash",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +2a702c2e57908e7bb5c814afeac577a14815c2f2,2a702c2e57908e7bb5c814afeac577a14815c2f2,Jakub Kicinski,kuba@kernel.org,1711551154,Jakub Kicinski,kuba@kernel.org,1711551154,7e6dfd1d0022eb8c3282bc652f450e51abfca630,ee36b1e93b11b980e0156bd07cbb9866b7d3e29e 14bb1e8c8d4ad5d9d2febb7d19c70a3cf536e1e5,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-03-25 + +We've added 38 non-merge commits during the last 13 day(s) which contain +a total of 50 files changed", 867 insertions(+),"[' 274 deletions(-).\n\nThe main changes are:\n\n1) Add the ability to specify and retrieve BPF cookie also for raw\n tracepoint programs in order to ease migration from classic to raw\n tracepoints', ' from Andrii Nakryiko.\n\n2) Allow the use of bpf_get_{ns_', '}current_pid_tgid() helper for all\n program types and add additional BPF selftests', ' from Yonghong Song.\n\n3) Several improvements to bpftool and its build', ' for example', ' enabling\n libbpf logs when loading pid_iter in debug mode', ' from Quentin Monnet.\n\n4) Check the return code of all BPF-related set_memory_*() functions during\n load and bail out in case they fail', "" from Christophe Leroy.\n\n5) Avoid a goto in regs_refine_cond_op() such that the verifier can\n be better integrated into Agni tool which doesn't support backedges\n yet"", ' from Harishankar Vishwanathan.\n\n6) Add a small BPF trie perf improvement by always inlining\n longest_prefix_match', ' from Jesper Dangaard Brouer.\n\n7) Small BPF selftest refactor in bpf_tcp_ca.c to utilize start_server()\n helper instead of open-coding it', ' from Geliang Tang.\n\n8) Improve test_tc_tunnel.sh BPF selftest to prevent client connect\n before the server bind', ' from Alessandro Carminati.\n\n9) Fix BPF selftest benchmark for older glibc and use syscall(SYS_gettid)\n instead of gettid()', ' from Alan Maguire.\n\n10) Implement a backward-compatible method for struct_ops types with\n additional fields which are not present in older kernels', '\n from Kui-Feng Lee.\n\n11) Add a small helper to check if an instruction is addr_space_cast\n from as(0) to as(1) and utilize it in x86-64 JIT', ' from Puranjay Mohan.\n\n12) Small cleanup to remove unnecessary error check in\n bpf_struct_ops_map_update_elem', ' from Martin KaFai Lau.\n\n13) Improvements to libbpf fd validity checks for BPF map/programs', '\n from Mykyta Yatsenko.\n\n* tag \'for-netdev\' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (38 commits)\n selftests/bpf: Fix flaky test btf_map_in_map/lookup_update\n bpf: implement insn_is_cast_user() helper for JITs\n bpf: Avoid get_kernel_nofault() to fetch kprobe entry IP\n selftests/bpf: Use start_server in bpf_tcp_ca\n bpf: Sync uapi bpf.h to tools directory\n libbpf: Add new sec_def ""sk_skb/verdict""\n selftests/bpf: Mark uprobe trigger functions with nocf_check attribute\n selftests/bpf: Use syscall(SYS_gettid) instead of gettid() wrapper in bench\n bpf-next: Avoid goto in regs_refine_cond_op()\n bpftool: Clean up HOST_CFLAGS', ' HOST_LDFLAGS for bootstrap bpftool\n selftests/bpf: scale benchmark counting by using per-CPU counters\n bpftool: Remove unnecessary source files from bootstrap version\n bpftool: Enable libbpf logs when loading pid_iter in debug mode\n selftests/bpf: add raw_tp/tp_btf BPF cookie subtests\n libbpf: add support for BPF cookie for raw_tp/tp_btf programs\n bpf: support BPF cookie in raw tracepoint (raw_tp', ' tp_btf) programs\n bpf: pass whole link instead of prog when triggering raw tracepoint\n bpf: flatten bpf_probe_register call chain\n selftests/bpf: Prevent client connect before server bind in test_tc_tunnel.sh\n selftests/bpf: Add a sk_msg prog bpf_get_ns_current_pid_tgid() test\n ...\n====================\n\nLink: https://lore.kernel.org/r/20240325233940.7154-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merge pull request for bpf-next with 38 non-merge commits and 50 files changed.,"merge,pull request,bpf-next",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +ea6873118493019474abbf57d5a800da365734df,ea6873118493019474abbf57d5a800da365734df,Pu Lehui,pulehui@huawei.com,1710206453,Palmer Dabbelt,palmer@rivosinc.com,1711487358,e9f7091a893941b07b47c536ff37bcc58a43ce1a,4b0bf9a0127029054c2fa18ba5b3f3ddc45f54ed,"drivers/perf: riscv: Disable PERF_SAMPLE_BRANCH_* while not supported + +RISC-V perf driver does not yet support branch sampling. Although the +specification is in the works [0]"," it is best to disable such events +until support is available","[' otherwise we will get unexpected results.\nDue to this reason', ' two riscv bpf testcases get_branch_snapshot and\nperf_branches/perf_branches_hw fail.\n\nLink: https://github.com/riscv/riscv-control-transfer-records [0]\nFixes: f5bfa23f576f (""RISC-V: Add a perf core library for pmu drivers"")\nSigned-off-by: Pu Lehui \nReviewed-by: Atish Patra \nReviewed-by: Conor Dooley \nLink: https://lore.kernel.org/r/20240312012053.1178140-1-pulehui@huaweicloud.com\nSigned-off-by: Palmer Dabbelt \n', '']",Disable unsupported branch sampling in RISC-V perf driver.,"Disable, RISC-V, branch sampling",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +37ccdf7f11b12f987c5d9ff99e67104264016c8d,37ccdf7f11b12f987c5d9ff99e67104264016c8d,Paolo Abeni,pabeni@redhat.com,1711454118,Paolo Abeni,pabeni@redhat.com,1711454118,d31b9789f55c6e186e14e10e2f72671e0d623863,f1425529c33def8b46faae4400dd9e2bbaf16a05 443574b033876c85a35de4c65c14f7fe092222b2,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-03-25 + +The following pull-request contains BPF updates for your *net* tree. + +We've added 17 non-merge commits during the last 12 day(s) which contain +a total of 19 files changed", 184 insertions(+),"["" 61 deletions(-).\n\nThe main changes are:\n\n1) Fix an arm64 BPF JIT bug in BPF_LDX_MEMSX implementation's offset handling\n found via test_bpf module"", ' from Puranjay Mohan.\n\n2) Various fixups to the BPF arena code in particular in the BPF verifier and\n around BPF selftests to match latest corresponding LLVM implementation', '\n from Puranjay Mohan and Alexei Starovoitov.\n\n3) Fix xsk to not assume that metadata is always requested in TX completion', ""\n from Stanislav Fomichev.\n\n4) Fix riscv BPF JIT's kfunc parameter incompatibility between BPF and the riscv\n ABI which requires sign-extension on int/uint"", "" from Pu Lehui.\n\n5) Fix s390x BPF JIT's bpf_plt pointer arithmetic which triggered a crash when\n testing struct_ops"", "" from Ilya Leoshkevich.\n\n6) Fix libbpf's arena mmap handling which had incorrect u64-to-pointer cast on\n 32-bit architectures"", ' from Andrii Nakryiko.\n\n7) Fix libbpf to define MFD_CLOEXEC when not available', ' from Arnaldo Carvalho de Melo.\n\n8) Fix arm64 BPF JIT implementation for 32bit unconditional bswap which\n resulted in an incorrect swap as indicated by test_bpf', ' from Artem Savkov.\n\n9) Fix BPF man page build script to use silent mode', "" from Hangbin Liu.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n riscv"", ' bpf: Fix kfunc parameters incompatibility between bpf and riscv abi\n bpf: verifier: reject addr_space_cast insn without arena\n selftests/bpf: verifier_arena: fix mmap address for arm64\n bpf: verifier: fix addr_space_cast from as(1) to as(0)\n libbpf: Define MFD_CLOEXEC if not available\n arm64: bpf: fix 32bit unconditional bswap\n bpf', "" arm64: fix bug in BPF_LDX_MEMSX\n libbpf: fix u64-to-pointer cast on 32-bit arches\n s390/bpf: Fix bpf_plt pointer arithmetic\n xsk: Don't assume metadata is always requested in TX completion\n selftests/bpf: Add arena test case for 4Gbyte corner case\n selftests/bpf: Remove hard coded PAGE_SIZE macro.\n libbpf"", ' selftests/bpf: Adjust libbpf', ' bpftool', ' selftests to match LLVM\n bpf: Clarify bpf_arena comments.\n MAINTAINERS: Update email address for Quentin Monnet\n scripts/bpf_doc: Use silent mode when exec make cmd\n bpf: Temporarily disable atomic operations in BPF arena\n====================\n\nLink: https://lore.kernel.org/r/20240325213520.26688-1-daniel@iogearbox.net\nSigned-off-by: Paolo Abeni \n', '']",Merges updates for BPF in linux net tree with 17 non-merge commits and 184 insertions.,"BPF updates, net tree, merge",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +151c9c724d05d5b0dd8acd3e11cb69ef1f2dbada,151c9c724d05d5b0dd8acd3e11cb69ef1f2dbada,Eric Dumazet,edumazet@google.com,1711115852,Jakub Kicinski,kuba@kernel.org,1711421517,2898f08d52d867b9e185380de9ce66d961469058,b11c81731c810efe592e510bb0110e0db6877419,"tcp: properly terminate timers for kernel sockets + +We had various syzbot reports about tcp timers firing after +the corresponding netns has been dismantled. + +Fortunately Josef Bacik could trigger the issue more often"," +and could test a patch I wrote two years ago. + +When TCP sockets are closed","["" we call inet_csk_clear_xmit_timers()\nto 'stop' the timers.\n\ninet_csk_clear_xmit_timers() can be called from any context"", '\nincluding when socket lock is held.\nThis is the reason it uses sk_stop_timer()', ' aka del_timer().\nThis means that ongoing timers might finish much later.\n\nFor user sockets', ' this is fine because each running timer\nholds a reference on the socket', ' and the user socket holds\na reference on the netns.\n\nFor kernel sockets', ' we risk that the netns is freed before\ntimer can complete', ' because kernel sockets do not hold\nreference on the netns.\n\nThis patch adds inet_csk_clear_xmit_timers_sync() function\nthat using sk_stop_timer_sync() to make sure all timers\nare terminated before the kernel socket is released.\nModules using kernel sockets close them in their netns exit()\nhandler.\n\nAlso add sock_not_owned_by_me() helper to get LOCKDEP\nsupport : inet_csk_clear_xmit_timers_sync() must not be called\nwhile socket lock is held.\n\nIt is very possible we can revert in the future commit\n3a58f13a881e (""net: rds: acquire refcount on TCP sockets"")\nwhich attempted to solve the issue in rds only.\n(net/smc/af_smc.c and net/mptcp/subflow.c have similar code)\n\nWe probably can remove the check_net() tests from\ntcp_out_of_resources() and __tcp_close() in the future.\n\nReported-by: Josef Bacik \nCloses: https://lore.kernel.org/netdev/20240314210740.GA2823176@perftesting/\nFixes: 26abe14379f8 (""net: Modify sk_alloc to not reference count the netns of kernel sockets."")\nFixes: 8a68173691f0 (""net: sk_clone_lock() should only do get_net() if the parent is not a kernel socket"")\nLink: https://lore.kernel.org/bpf/CANn89i+484ffqb93aQm1N-tjxxvb3WDKX0EbD7318RwRgsatjw@mail.gmail.com/\nSigned-off-by: Eric Dumazet \nTested-by: Josef Bacik \nCc: Tetsuo Handa \nLink: https://lore.kernel.org/r/20240322135732.1535772-1-edumazet@google.com\nSigned-off-by: Jakub Kicinski \n', '']",Fix termination of TCP timers in kernel sockets after netns dismantling.,"TCP, timers, netns",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', ""It's not related to any of the above.""]" +443574b033876c85a35de4c65c14f7fe092222b2,443574b033876c85a35de4c65c14f7fe092222b2,Pu Lehui,pulehui@huawei.com,1711276386,Alexei Starovoitov,ast@kernel.org,1711391971,6f8415231e5bb5407d6bc803e8f846c9d6379d04,122fdbd2a030a95128737fc77e47df15a8f170c3,riscv," bpf: Fix kfunc parameters incompatibility between bpf and riscv abi + +We encountered a failing case when running selftest in no_alu32 mode: + +The failure case is `kfunc_call/kfunc_call_test4` and its source code is +like bellow: +``` +long bpf_kfunc_call_test4(signed char a","[' short b', ' int c', ' long d) __ksym;\nint kfunc_call_test4(struct __sk_buff *skb)\n{\n\t...\n\ttmp = bpf_kfunc_call_test4(-3', ' -30', ' -200', ' -1000);\n\t...\n}\n```\n\nAnd its corresponding asm code is:\n```\n0: r1 = -3\n1: r2 = -30\n2: r3 = 0xffffff38 # opcode: 18 03 00 00 38 ff ff ff 00 00 00 00 00 00 00 00\n4: r4 = -1000\n5: call bpf_kfunc_call_test4\n```\n\ninsn 2 is parsed to ld_imm64 insn to emit 0x00000000ffffff38 imm', ' and\nconverted to int type and then send to bpf_kfunc_call_test4. But since\nit is zero-extended in the bpf calling convention', ' riscv jit will\ndirectly treat it as an unsigned 32-bit int value', ' and then fails with\nthe message ""actual 4294966063 != expected -1234"".\n\nThe reason is the incompatibility between bpf and riscv abi', ' that is', '\nbpf will do zero-extension on uint', ' but riscv64 requires sign-extension\non int or uint. We can solve this problem by sign extending the 32-bit\nparameters in kfunc.\n\nThe issue is related to [0]', ' and thanks to Yonghong and Alexei.\n\nLink: https://github.com/llvm/llvm-project/pull/84874 [0]\nFixes: d40c3847b485 (""riscv', ' bpf: Add kfunc support for RV64"")\nSigned-off-by: Pu Lehui \nTested-by: Puranjay Mohan \nReviewed-by: Puranjay Mohan \nLink: https://lore.kernel.org/r/20240324103306.2202954-1-pulehui@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix incompatibility of kfunc parameters between bpf and riscv ABI.,"kfunc, incompatibility, riscv",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +14bb1e8c8d4ad5d9d2febb7d19c70a3cf536e1e5,14bb1e8c8d4ad5d9d2febb7d19c70a3cf536e1e5,Yonghong Song,yonghong.song@linux.dev,1711088033,Daniel Borkmann,daniel@iogearbox.net,1711383954,5beab7217bc5c3bfadba05c5aff751e20450502f,770546ae9f4c1ae1ebcaf0874f0dd9631d77ec97,"selftests/bpf: Fix flaky test btf_map_in_map/lookup_update + +Recently"," I frequently hit the following test failure: + + [root@arch-fb-vm1 bpf]# ./test_progs -n 33/1 + test_lookup_update:PASS:skel_open 0 nsec + [...] + test_lookup_update:PASS:sync_rcu 0 nsec + test_lookup_update:FAIL:map1_leak inner_map1 leaked! + #33/1 btf_map_in_map/lookup_update:FAIL + #33 btf_map_in_map:FAIL + +In the test","[' after map is closed and then after two rcu grace periods', '\nit is assumed that map_id is not available to user space.\n\nBut the above assumption cannot be guaranteed. After zero or one\nor two rcu grace periods in different siturations', ' the actual\nfreeing-map-work is put into a workqueue. Later on', ' when the work\nis dequeued', ' the map will be actually freed.\nSee bpf_map_put() in kernel/bpf/syscall.c.\n\nBy using workqueue', ' there is no ganrantee that map will be actually\nfreed after a couple of rcu grace periods. This patch removed\nsuch map leak detection and then the test can pass consistently.\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240322061353.632136-1-yonghong.song@linux.dev\n', '']",Fixes a flaky test in the bpf selftests related to btf_map_in_map and lookup_update.,"flaky,test,fix",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +770546ae9f4c1ae1ebcaf0874f0dd9631d77ec97,770546ae9f4c1ae1ebcaf0874f0dd9631d77ec97,Puranjay Mohan,puranjay12@gmail.com,1711305146,Alexei Starovoitov,ast@kernel.org,1711383051,3a7bbdf305e2c5ab7154fdd2c40216f17f3e4e69,a8497506cd2c0fc90a64f6f5d2744a0ddb2c81eb,"bpf: implement insn_is_cast_user() helper for JITs + +Implement a helper function to check if an instruction is +addr_space_cast from as(0) to as(1). Use this helper in the x86 JIT. + +Other JITs can use this helper when they add support for this instruction. + +Signed-off-by: Puranjay Mohan +Link: https://lore.kernel.org/r/20240324183226.29674-1-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov +",,"Add a helper function insn_is_cast_user() for checking address space casts, integrated into x86 JIT.","helper,function,JIT",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a8497506cd2c0fc90a64f6f5d2744a0ddb2c81eb,a8497506cd2c0fc90a64f6f5d2744a0ddb2c81eb,Andrii Nakryiko,andrii@kernel.org,1710883213,Daniel Borkmann,daniel@iogearbox.net,1711382748,8f76c6f63acd573e2bf281accc765b100e06f5ef,c29083f3f5069d811b3f3c7592a0dc45ec42960c,"bpf: Avoid get_kernel_nofault() to fetch kprobe entry IP + +get_kernel_nofault() (or", rather,"["" underlying copy_from_kernel_nofault())\nis not free and it does pop up in performance profiles when\nkprobes are heavily utilized with CONFIG_X86_KERNEL_IBT=y config.\n\nLet's avoid using it if we know that fentry_ip - 4 can't cross page\nboundary. We do that by masking lowest 12 bits and checking if they are\n\nAnother benefit (and actually what caused a closer look at this part of\ncode) is that now LBR record is (typically) not wasted on\ncopy_from_kernel_nofault() call and code"", ' which helps tools like\nretsnoop that grab LBR records from inside BPF code in kretprobes.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Jiri Olsa \nAcked-by: Masami Hiramatsu (Google) \nLink: https://lore.kernel.org/bpf/20240319212013.1046779-1-andrii@kernel.org\n', '']",Avoid using get_kernel_nofault() to fetch kprobe entry IP for eBPF programs.,"get_kernel_nofault,kprobe,eBPF",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +c29083f3f5069d811b3f3c7592a0dc45ec42960c,c29083f3f5069d811b3f3c7592a0dc45ec42960c,Geliang Tang,tanggeliang@kylinos.cn,1711331775,Daniel Borkmann,daniel@iogearbox.net,1711381793,8d7e988c66625e2a057a2ce58c57fcf3d6e351c4,476a5e929119725fbfcf1307cc8517d9dd2a014d,"selftests/bpf: Use start_server in bpf_tcp_ca + +To simplify the code"," use BPF selftests helper start_server() in +bpf_tcp_ca.c instead of open-coding it. This helper is defined in +network_helpers.c","[' and exported in network_helpers.h', ' which is already\nincluded in bpf_tcp_ca.c.\n\nSigned-off-by: Geliang Tang \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/9926a79118db27dd6d91c4854db011c599cabd0e.1711331517.git.tanggeliang@kylinos.cn\n', '']",Refactor bpf_tcp_ca.c to use start_server from network_helpers.c for simplicity.,"selftests,bpf_tcp_ca,refactor",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tc/netfilter like programs'] +476a5e929119725fbfcf1307cc8517d9dd2a014d,476a5e929119725fbfcf1307cc8517d9dd2a014d,Yonghong Song,yonghong.song@linux.dev,1711337922,Daniel Borkmann,daniel@iogearbox.net,1711381016,129c86adeef179db6b02f6e9ff58f925677b9dc8,61df575632d6b39213f47810c441bddbd87c3606,"bpf: Sync uapi bpf.h to tools directory + +There is a difference between kernel uapi bpf.h and tools +uapi bpf.h. There is no functionality difference"," but let +us sync properly to make it easy for later bpf.h update. + +Signed-off-by: Yonghong Song +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240325033842.1693553-1-yonghong.song@linux.dev +",[''],The commit synchronizes the uapi bpf.h between the kernel and tools directory.,"sync,uapi,tools",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +122fdbd2a030a95128737fc77e47df15a8f170c3,122fdbd2a030a95128737fc77e47df15a8f170c3,Puranjay Mohan,puranjay12@gmail.com,1711121718,Alexei Starovoitov,ast@kernel.org,1711165449,1fe529947757590ccdc1537f14cb712f054b5141,fa3550dca8f02ec312727653a94115ef3ab68445,"bpf: verifier: reject addr_space_cast insn without arena + +The verifier allows using the addr_space_cast instruction in a program +that doesn't have an associated arena. This was caught in the form an +invalid memory access in do_misc_fixups() when while converting +addr_space_cast to a normal 32-bit mov"," env->prog->aux->arena was +dereferenced to check for BPF_F_NO_USER_CONV flag. + +Reject programs that include the addr_space_cast instruction but don't +have an associated arena. + +root@rv-tester:~# ./reproducer + Unable to handle kernel access to user memory without uaccess routines at virtual address 0000000000000030 + Oops [#1] + [] do_misc_fixups+0x43c/0x1168 + [] bpf_check+0xda8/0x22b6 + [] bpf_prog_load+0x486/0x8dc + [] __sys_bpf+0xbd8/0x214e + [] __riscv_sys_bpf+0x22/0x2a + [] do_trap_ecall_u+0x102/0x17c + [] ret_from_exception+0x0/0x64 + +Fixes: 6082b6c328b5 (""bpf: Recognize addr_space_cast instruction in the verifier."") +Reported-by: xingwei lee +Reported-by: yue sun +Closes: https://lore.kernel.org/bpf/CABOYnLz09O1+2gGVJuCxd_24a-7UueXzV-Ff+Fr+h5EKFDiYCQ@mail.gmail.com/ +Signed-off-by: Puranjay Mohan +Link: https://lore.kernel.org/r/20240322153518.11555-1-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],The commit fixes a memory access issue by rejecting programs using addr_space_cast without an associated arena.,"verifier, addr_space_cast, arena",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fa3550dca8f02ec312727653a94115ef3ab68445,fa3550dca8f02ec312727653a94115ef3ab68445,Puranjay Mohan,puranjay12@gmail.com,1711114552,Alexei Starovoitov,ast@kernel.org,1711165059,1fb389cc55b931a0899ff34b0aa8ab8c35c9128b,f7f5d1808b1b66935a24dd796dd1a0612ca9c147,"selftests/bpf: verifier_arena: fix mmap address for arm64 + +The arena_list selftest uses (1ull << 32) in the mmap address +computation for arm64. Use the same in the verifier_arena selftest. + +This makes the selftest pass for arm64 on the CI[1]. + +[1] https://github.com/kernel-patches/bpf/pull/6622 + +Signed-off-by: Puranjay Mohan +Link: https://lore.kernel.org/r/20240322133552.70681-1-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov +",,Fixes mmap address computation for arm64 in the bpf selftest verifier_arena.,"mmap,arm64,selftest",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f7f5d1808b1b66935a24dd796dd1a0612ca9c147,f7f5d1808b1b66935a24dd796dd1a0612ca9c147,Puranjay Mohan,puranjay12@gmail.com,1711035579,Alexei Starovoitov,ast@kernel.org,1711164996,620605b401cc5a3c90e78fe3620ab2a1c8d72c29,ddb2ffdc474a3000887dc776b971d04bde29decc,"bpf: verifier: fix addr_space_cast from as(1) to as(0) + +The verifier currently converts addr_space_cast from as(1) to as(0) that +is: BPF_ALU64 | BPF_MOV | BPF_X with off=1 and imm=1 +to +BPF_ALU | BPF_MOV | BPF_X with imm=1 (32-bit mov) + +Because of this imm=1", the JITs that have bpf_jit_needs_zext() == true,"['\ninterpret the converted instruction as BPF_ZEXT_REG(DST) which is a\nspecial form of mov32', ' used for doing explicit zero extension on dst.\nThese JITs will just zero extend the dst reg and will not move the src to\ndst before the zext.\n\nFix do_misc_fixups() to set imm=0 when converting addr_space_cast to a\nnormal mov32.\n\nThe JITs that have bpf_jit_needs_zext() == true rely on the verifier to\nemit zext instructions. Mark dst_reg as subreg when doing cast from\nas(1) to as(0) so the verifier emits a zext instruction after the mov.\n\nFixes: 6082b6c328b5 (""bpf: Recognize addr_space_cast instruction in the verifier."")\nSigned-off-by: Puranjay Mohan \nLink: https://lore.kernel.org/r/20240321153939.113996-1-puranjay12@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit fixes the address space cast issue in eBPF verifier from as(1) to as(0).,"verifier, addr_space_cast, fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +61df575632d6b39213f47810c441bddbd87c3606,61df575632d6b39213f47810c441bddbd87c3606,Yonghong Song,yonghong.song@linux.dev,1710870852,Andrii Nakryiko,andrii@kernel.org,1711143429,3e333b6d1428fde18b8b7e7ca9e4acf77e3769a3,af8d27bf15c8d68c60d830552055fcdba5b5f045,"libbpf: Add new sec_def ""sk_skb/verdict"" + +The new sec_def specifies sk_skb program type with +BPF_SK_SKB_VERDICT attachment type. This way"," libbpf +will set expected_attach_type properly for the program. + +Signed-off-by: Yonghong Song +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240319175412.2941149-1-yonghong.song@linux.dev +",[''],The commit adds a new sec_def specifying sk_skb program type with BPF_SK_SKB_VERDICT to set expected_attach_type in libbpf.,"sec_def, sk_skb, libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,['socket like programs'] +af8d27bf15c8d68c60d830552055fcdba5b5f045,af8d27bf15c8d68c60d830552055fcdba5b5f045,Jiri Olsa,jolsa@kernel.org,1711115376,Andrii Nakryiko,andrii@kernel.org,1711126877,1cf13aac3cf073e16278b5a97614019bca93123e,1684d6eb99e480ff653af60e20ff5e7e55e69ccd,"selftests/bpf: Mark uprobe trigger functions with nocf_check attribute + +Some distros seem to enable the -fcf-protection=branch by default"," +which breaks our setup on first instruction of uprobe trigger +functions and place there endbr64 instruction. + +Marking them with nocf_check attribute to skip that. + +Ignoring unknown attribute warning in gcc for bench objects","[' because\nnocf_check can be used only when -fcf-protection=branch is enabled', '\notherwise we get a warning and break compilation.\n\nSigned-off-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240322134936.1075395-1-jolsa@kernel.org\n', '']",Mark uprobe trigger functions with nocf_check attribute to avoid branch protection conflicts.,"uprobe,nocf_check,protection",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +1684d6eb99e480ff653af60e20ff5e7e55e69ccd,1684d6eb99e480ff653af60e20ff5e7e55e69ccd,Alan Maguire,alan.maguire@oracle.com,1711101448,Andrii Nakryiko,andrii@kernel.org,1711126817,9a1d84164c898b093754a35a9740d3fd0fba6bc5,4c2a26fc80bcb851dc630590f2eec157991eccbf,"selftests/bpf: Use syscall(SYS_gettid) instead of gettid() wrapper in bench + +With glibc 2.28"," selftests compilation fails for benchs/bench_trigger.c: + +benchs/bench_trigger.c: In function ‘inc_counter’: +benchs/bench_trigger.c:25:23: error: implicit declaration of function ‘gettid’; did you mean ‘getgid’? [-Werror=implicit-function-declaration] + 25 | tid = gettid(); + | ^~~~~~ + | getgid +cc1: all warnings being treated as errors + +It appears support for the gettid() wrapper is variable across glibc +versions","[' so may be safer to use syscall(SYS_gettid) instead.\n\nFixes: 520fad2e3206 (""selftests/bpf: scale benchmark counting by using per-CPU counters"")\nSigned-off-by: Alan Maguire \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240322095728.95671-1-alan.maguire@oracle.com\n', '']",Replace gettid() with syscall(SYS_gettid) for compatibility in bench_trigger selftest.,"gettid,system call,selftests",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['other'] +b3ad832d8da583ff4237b04a1ba23cdbf8918907,b3ad832d8da583ff4237b04a1ba23cdbf8918907,Ian Rogers,irogers@google.com,1711036968,Arnaldo Carvalho de Melo,acme@redhat.com,1711064675,0963f923ffcf17fed09b08440cf6af094c2f260c,2a5049b75d22c971e73501784f10548c1d69c407,"perf dso: Reorder members to save space in 'struct dso' + +Save 40 bytes and move from 8 to 7 cache lines. Make member dwfl +dependent on being a powerpc build. Squeeze bits of int/enum types +when appropriate. Remove holes/padding by reordering variables. + +Before: + + struct dso { + struct mutex lock; /* 0 40 */ + struct list_head node; /* 40 16 */ + struct rb_node rb_node __attribute__((__aligned__(8))); /* 56 24 */ + /* --- cacheline 1 boundary (64 bytes) was 16 bytes ago --- */ + struct rb_root * root; /* 80 8 */ + struct rb_root_cached symbols; /* 88 16 */ + struct symbol * * symbol_names; /* 104 8 */ + size_t symbol_names_len; /* 112 8 */ + struct rb_root_cached inlined_nodes; /* 120 16 */ + /* --- cacheline 2 boundary (128 bytes) was 8 bytes ago --- */ + struct rb_root_cached srclines; /* 136 16 */ + struct { + u64 addr; /* 152 8 */ + struct symbol * symbol; /* 160 8 */ + } last_find_result; /* 152 16 */ + void * a2l; /* 168 8 */ + char * symsrc_filename; /* 176 8 */ + unsigned int a2l_fails; /* 184 4 */ + enum dso_space_type kernel; /* 188 4 */ + /* --- cacheline 3 boundary (192 bytes) --- */ + _Bool is_kmod; /* 192 1 */ + + /* XXX 3 bytes hole"," try to pack */ + + enum dso_swap_type needs_swap; /* 196 4 */ + enum dso_binary_type symtab_type; /* 200 4 */ + enum dso_binary_type binary_type; /* 204 4 */ + enum dso_load_errno load_errno; /* 208 4 */ + u8 adjust_symbols:1; /* 212: 0 1 */ + u8 has_build_id:1; /* 212: 1 1 */ + u8 header_build_id:1; /* 212: 2 1 */ + u8 has_srcline:1; /* 212: 3 1 */ + u8 hit:1; /* 212: 4 1 */ + u8 annotate_warned:1; /* 212: 5 1 */ + u8 auxtrace_warned:1; /* 212: 6 1 */ + u8 short_name_allocated:1; /* 212: 7 1 */ + u8 long_name_allocated:1; /* 213: 0 1 */ + u8 is_64_bit:1; /* 213: 1 1 */ + + /* XXX 6 bits hole","[' try to pack */\n\n _Bool sorted_by_name; /* 214 1 */\n _Bool loaded; /* 215 1 */\n u8 rel; /* 216 1 */\n\n /* XXX 7 bytes hole', ' try to pack */\n\n struct build_id bid; /* 224 32 */\n /* --- cacheline 4 boundary (256 bytes) --- */\n u64 text_offset; /* 256 8 */\n u64 text_end; /* 264 8 */\n const char * short_name; /* 272 8 */\n const char * long_name; /* 280 8 */\n u16 long_name_len; /* 288 2 */\n u16 short_name_len; /* 290 2 */\n\n /* XXX 4 bytes hole', ' try to pack */\n\n void * dwfl; /* 296 8 */\n struct auxtrace_cache * auxtrace_cache; /* 304 8 */\n int comp; /* 312 4 */\n\n /* XXX 4 bytes hole', ' try to pack */\n\n /* --- cacheline 5 boundary (320 bytes) --- */\n struct {\n struct rb_root cache; /* 320 8 */\n int fd; /* 328 4 */\n int status; /* 332 4 */\n u32 status_seen; /* 336 4 */\n\n /* XXX 4 bytes hole', ' try to pack */\n\n u64 file_size; /* 344 8 */\n struct list_head open_entry; /* 352 16 */\n u64 elf_base_addr; /* 368 8 */\n u64 debug_frame_offset; /* 376 8 */\n /* --- cacheline 6 boundary (384 bytes) --- */\n u64 eh_frame_hdr_addr; /* 384 8 */\n u64 eh_frame_hdr_offset; /* 392 8 */\n } data; /* 320 80 */\n struct {\n u32 id; /* 400 4 */\n u32 sub_id; /* 404 4 */\n struct perf_env * env; /* 408 8 */\n } bpf_prog; /* 400 16 */\n union {\n void * priv; /* 416 8 */\n u64 db_id; /* 416 8 */\n }; /* 416 8 */\n struct nsinfo * nsinfo; /* 424 8 */\n struct dso_id id; /* 432 24 */\n /* --- cacheline 7 boundary (448 bytes) was 8 bytes ago --- */\n refcount_t refcnt; /* 456 4 */\n char name[]; /* 460 0 */\n\n /* size: 464', ' cachelines: 8', ' members: 49 */\n /* sum members: 440', ' holes: 4', ' sum holes: 18 */\n /* sum bitfield members: 10 bits', ' bit holes: 1', ' sum bit holes: 6 bits */\n /* padding: 4 */\n /* forced alignments: 1 */\n /* last cacheline: 16 bytes */\n } __attribute__((__aligned__(8)));\n\nAfter:\n\n struct dso {\n struct mutex lock; /* 0 40 */\n struct list_head node; /* 40 16 */\n struct rb_node rb_node __attribute__((__aligned__(8))); /* 56 24 */\n /* --- cacheline 1 boundary (64 bytes) was 16 bytes ago --- */\n struct rb_root * root; /* 80 8 */\n struct rb_root_cached symbols; /* 88 16 */\n struct symbol * * symbol_names; /* 104 8 */\n size_t symbol_names_len; /* 112 8 */\n struct rb_root_cached inlined_nodes; /* 120 16 */\n /* --- cacheline 2 boundary (128 bytes) was 8 bytes ago --- */\n struct rb_root_cached srclines; /* 136 16 */\n struct {\n u64 addr; /* 152 8 */\n struct symbol * symbol; /* 160 8 */\n } last_find_result; /* 152 16 */\n struct build_id bid; /* 168 32 */\n /* --- cacheline 3 boundary (192 bytes) was 8 bytes ago --- */\n u64 text_offset; /* 200 8 */\n u64 text_end; /* 208 8 */\n const char * short_name; /* 216 8 */\n const char * long_name; /* 224 8 */\n void * a2l; /* 232 8 */\n char * symsrc_filename; /* 240 8 */\n struct nsinfo * nsinfo; /* 248 8 */\n /* --- cacheline 4 boundary (256 bytes) --- */\n struct auxtrace_cache * auxtrace_cache; /* 256 8 */\n union {\n void * priv; /* 264 8 */\n u64 db_id; /* 264 8 */\n }; /* 264 8 */\n struct {\n struct perf_env * env; /* 272 8 */\n u32 id; /* 280 4 */\n u32 sub_id; /* 284 4 */\n } bpf_prog; /* 272 16 */\n struct {\n struct rb_root cache; /* 288 8 */\n struct list_head open_entry; /* 296 16 */\n u64 file_size; /* 312 8 */\n /* --- cacheline 5 boundary (320 bytes) --- */\n u64 elf_base_addr; /* 320 8 */\n u64 debug_frame_offset; /* 328 8 */\n u64 eh_frame_hdr_addr; /* 336 8 */\n u64 eh_frame_hdr_offset; /* 344 8 */\n int fd; /* 352 4 */\n int status; /* 356 4 */\n u32 status_seen; /* 360 4 */\n } data; /* 288 80 */\n\n /* XXX last struct has 4 bytes of padding */\n\n struct dso_id id; /* 368 24 */\n /* --- cacheline 6 boundary (384 bytes) was 8 bytes ago --- */\n unsigned int a2l_fails; /* 392 4 */\n int comp; /* 396 4 */\n refcount_t refcnt; /* 400 4 */\n enum dso_load_errno load_errno; /* 404 4 */\n u16 long_name_len; /* 408 2 */\n u16 short_name_len; /* 410 2 */\n enum dso_binary_type symtab_type:8; /* 412: 0 4 */\n enum dso_binary_type binary_type:8; /* 412: 8 4 */\n enum dso_space_type kernel:2; /* 412:16 4 */\n enum dso_swap_type needs_swap:2; /* 412:18 4 */\n\n /* Bitfield combined with next fields */\n\n _Bool is_kmod:1; /* 414: 4 1 */\n u8 adjust_symbols:1; /* 414: 5 1 */\n u8 has_build_id:1; /* 414: 6 1 */\n u8 header_build_id:1; /* 414: 7 1 */\n u8 has_srcline:1; /* 415: 0 1 */\n u8 hit:1; /* 415: 1 1 */\n u8 annotate_warned:1; /* 415: 2 1 */\n u8 auxtrace_warned:1; /* 415: 3 1 */\n u8 short_name_allocated:1; /* 415: 4 1 */\n u8 long_name_allocated:1; /* 415: 5 1 */\n u8 is_64_bit:1; /* 415: 6 1 */\n\n /* XXX 1 bit hole', ' try to pack */\n\n _Bool sorted_by_name; /* 416 1 */\n _Bool loaded; /* 417 1 */\n u8 rel; /* 418 1 */\n char name[]; /* 419 0 */\n\n /* size: 424', ' cachelines: 7', ' members: 48 */\n /* sum members: 415 */\n /* sum bitfield members: 31 bits', ' bit holes: 1', ' sum bit holes: 1 bits */\n /* padding: 5 */\n /* paddings: 1', ' sum paddings: 4 */\n /* forced alignments: 1 */\n /* last cacheline: 40 bytes */\n } __attribute__((__aligned__(8)));\n\nSigned-off-by: Ian Rogers \nCc: Adrian Hunter \nCc: Ahelenia Ziemiańska \nCc: Alexander Shishkin \nCc: Andi Kleen \nCc: Athira Rajeev \nCc: Ben Gainey \nCc: Changbin Du \nCc: Chengen Du \nCc: Colin Ian King \nCc: Ilkka Koskinen \nCc: Ingo Molnar \nCc: James Clark \nCc: Jiri Olsa \nCc: K Prateek Nayak \nCc: Kan Liang \nCc: Leo Yan \nCc: Li Dong \nCc: Liam Howlett \nCc: Mark Rutland \nCc: Markus Elfring \nCc: Masami Hiramatsu \nCc: Miguel Ojeda \nCc: Namhyung Kim \nCc: Paran Lee \nCc: Peter Zijlstra \nCc: Ravi Bangoria \nCc: Song Liu \nCc: Sun Haiyong \nCc: Yanteng Si \nCc: zhaimingbing \nLink: https://lore.kernel.org/r/20240321160300.1635121-2-irogers@google.com\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",Optimize 'struct dso' in perf tool by reordering members to reduce cache lines and save space.,"optimize, reorder, struct",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['other'] +cba9ffdb9913dfe6be29f049ce920ce451ce7cc4,cba9ffdb9913dfe6be29f049ce920ce451ce7cc4,Linus Torvalds,torvalds@linux-foundation.org,1711057839,Linus Torvalds,torvalds@linux-foundation.org,1711057839,7b4a85ce028c0911bd7d2a69a8801af537dca41f,1d35aae78ffe739bf46c2bf9dea7b51a4eebfbe0 f99c5f563c174a49ea1cbf4754539b05cfde40c4,"Merge tag 'net-6.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + ""Including fixes from CAN", netfilter,"["" wireguard and IPsec.\n\n I'd like to highlight [ lowlight? - Linus ] Florian W stepping down as\n a netfilter maintainer due to constant stream of bug reports. Not sure\n what we can do but IIUC this is not the first such case.\n\n Current release - regressions:\n\n - rxrpc: fix use of page_frag_alloc_align()"", ' it changed semantics and\n we added a new caller in a different subtree\n\n - xfrm: allow UDP encapsulation only in offload modes\n\n Current release - new code bugs:\n\n - tcp: fix refcnt handling in __inet_hash_connect()\n\n - Revert ""net: Re-use and set mono_delivery_time bit for userspace\n tstamp packets""', ' conflicted with some expectations in BPF uAPI\n\n Previous releases - regressions:\n\n - ipv4: raw: fix sending packets from raw sockets via IPsec tunnels\n\n - devlink: fix devlink\'s parallel command processing\n\n - veth: do not manipulate GRO when using XDP\n\n - esp: fix bad handling of pages from page_pool\n\n Previous releases - always broken:\n\n - report RCU QS for busy network kthreads (with Paul McK\'s blessing)\n\n - tcp/rds: fix use-after-free on netns with kernel TCP reqsk\n\n - virt: vmxnet3: fix missing reserved tailroom with XDP\n\n Misc:\n\n - couple of build fixes for Documentation""\n\n* tag \'net-6.9-rc1\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (59 commits)\n selftests: forwarding: Fix ping failure due to short timeout\n MAINTAINERS: step down as netfilter maintainer\n netfilter: nf_tables: Fix a memory leak in nf_tables_updchain\n net: dsa: mt7530: fix handling of all link-local frames\n net: dsa: mt7530: fix link-local frames that ingress vlan filtering ports\n bpf: report RCU QS in cpumap kthread\n net: report RCU QS on threaded NAPI repolling\n rcu: add a helper to report consolidated flavor QS\n ionic: update documentation for XDP support\n lib/bitmap: Fix bitmap_scatter() and bitmap_gather() kernel doc\n netfilter: nf_tables: do not compare internal table flags on updates\n netfilter: nft_set_pipapo: release elements in clone only from destroy path\n octeontx2-af: Use separate handlers for interrupts\n octeontx2-pf: Send UP messages to VF only when VF is up.\n octeontx2-pf: Use default max_active works instead of one\n octeontx2-pf: Wait till detach_resources msg is complete\n octeontx2: Detect the mbox up or down message via register\n devlink: fix port new reply cmd type\n tcp: Clear req->syncookie in reqsk_alloc().\n net/bnx2x: Prevent access to a freed page in page_pool\n ...\n', '']","Merge network fixes from net-6.9-rc1 tag, includes CAN related corrections.","merge, networking, fixes",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +4c2a26fc80bcb851dc630590f2eec157991eccbf,4c2a26fc80bcb851dc630590f2eec157991eccbf,Harishankar Vishwanathan,harishankar.vishwanathan@gmail.com,1710980994,Andrii Nakryiko,andrii@kernel.org,1711047386,7285a497ce184df14a8c17f2d33b44ba09c6e1d0,cc9b22dfa735800980e7362f02aff6f1c2280996,"bpf-next: Avoid goto in regs_refine_cond_op() + +In case of GE/GT/SGE/JST instructions"," regs_refine_cond_op() +reuses the logic that does analysis of LE/LT/SLE/SLT instructions. +This commit avoids the use of a goto to perform the reuse. + +Signed-off-by: Harishankar Vishwanathan +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240321002955.808604-1-harishankar.vishwanathan@gmail.com +",[''],The commit refactors the logic in regs_refine_cond_op to eliminate the use of a goto statement.,"regs_refine_cond_op, refactor, goto",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ddb2ffdc474a3000887dc776b971d04bde29decc,ddb2ffdc474a3000887dc776b971d04bde29decc,Arnaldo Carvalho de Melo,acme@kernel.org,1711036918,Andrii Nakryiko,andrii@kernel.org,1711045637,b19420fdd37dc8a46668e115ed24ee50310c000d,a51cd6bf8e10793103c5870ff9e4db295a843604,"libbpf: Define MFD_CLOEXEC if not available + +Since its going directly to the syscall to avoid not having +memfd_create() available in some systems"," do the same for its +MFD_CLOEXEC flags","[' defining it if not available.\n\nThis fixes the build in those systems', ' noticed while building perf on a\nset of build containers.\n\nFixes: 9fa5e1a180aa639f (""libbpf: Call memfd_create() syscall directly"")\nSigned-off-by: Arnaldo Carvalho de Melo \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/ZfxZ9nCyKvwmpKkE@x1\n', '']",Defines MFD_CLOEXEC flag in libbpf for systems missing memfd_create support.,"libbpf, MFD_CLOEXEC, memfd_create",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +88ce0106a1f603bf360cb397e8fe293f8298fabb,88ce0106a1f603bf360cb397e8fe293f8298fabb,Ian Rogers,irogers@google.com,1709279196,Arnaldo Carvalho de Melo,acme@redhat.com,1711040079,0fb9cd8f38d482c33a1f2ca78029ad052b2ecb30,67ee8e71daabb8632931b7559e5c8a4b69a427f8,"perf record: Delete session after stopping sideband thread + +The session has a header in it which contains a perf env with +bpf_progs. The bpf_progs are accessed by the sideband thread and so +the sideband thread must be stopped before the session is deleted"," to +avoid a use after free. This error was detected by AddressSanitizer +in the following: + + ==2054673==ERROR: AddressSanitizer: heap-use-after-free on address 0x61d000161e00 at pc 0x55769289de54 bp 0x7f9df36d4ab0 sp 0x7f9df36d4aa8 + READ of size 8 at 0x61d000161e00 thread T1 + #0 0x55769289de53 in __perf_env__insert_bpf_prog_info util/env.c:42 + #1 0x55769289dbb1 in perf_env__insert_bpf_prog_info util/env.c:29 + #2 0x557692bbae29 in perf_env__add_bpf_info util/bpf-event.c:483 + #3 0x557692bbb01a in bpf_event__sb_cb util/bpf-event.c:512 + #4 0x5576928b75f4 in perf_evlist__poll_thread util/sideband_evlist.c:68 + #5 0x7f9df96a63eb in start_thread nptl/pthread_create.c:444 + #6 0x7f9df9726a4b in clone3 ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81 + + 0x61d000161e00 is located 384 bytes inside of 2136-byte region [0x61d000161c80","['0x61d0001624d8)\n freed by thread T0 here:\n #0 0x7f9dfa6d7288 in __interceptor_free libsanitizer/asan/asan_malloc_linux.cpp:52\n #1 0x557692978d50 in perf_session__delete util/session.c:319\n #2 0x557692673959 in __cmd_record tools/perf/builtin-record.c:2884\n #3 0x55769267a9f0 in cmd_record tools/perf/builtin-record.c:4259\n #4 0x55769286710c in run_builtin tools/perf/perf.c:349\n #5 0x557692867678 in handle_internal_command tools/perf/perf.c:402\n #6 0x557692867a40 in run_argv tools/perf/perf.c:446\n #7 0x557692867fae in main tools/perf/perf.c:562\n #8 0x7f9df96456c9 in __libc_start_call_main ../sysdeps/nptl/libc_start_call_main.h:58\n\nFixes: 657ee5531903339b (""perf evlist: Introduce side band thread"")\nSigned-off-by: Ian Rogers \nCc: Adrian Hunter \nCc: Alexander Shishkin \nCc: Athira Rajeev \nCc: Christian Brauner \nCc: Disha Goel \nCc: Ingo Molnar \nCc: James Clark \nCc: Jiri Olsa \nCc: Kajol Jain \nCc: Kan Liang \nCc: K Prateek Nayak \nCc: Mark Rutland \nCc: Namhyung Kim \nCc: Peter Zijlstra \nCc: Song Liu \nCc: Tim Chen \nCc: Yicong Yang \nLink: https://lore.kernel.org/r/20240301074639.2260708-1-irogers@google.com\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",Fixes a use-after-free error by ensuring the sideband thread stops before deleting the session in perf record.,"use-after-free, sideband thread, perf record",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +a51cd6bf8e10793103c5870ff9e4db295a843604,a51cd6bf8e10793103c5870ff9e4db295a843604,Artem Savkov,asavkov@redhat.com,1711009089,Alexei Starovoitov,ast@kernel.org,1711018745,b43ed013baaf135044a4b751e52cfca9749c872a,114b5b3b4bde7358624437be2f12cde1b265224e,"arm64: bpf: fix 32bit unconditional bswap + +In case when is64 == 1 in emit(A64_REV32(is64", dst,"[' dst)', ' ctx) the\ngenerated insn reverses byte order for both high and low 32-bit words', '\nresuling in an incorrect swap as indicated by the jit test:\n\n[ 9757.262607] test_bpf: #312 BSWAP 16: 0x0123456789abcdef -> 0xefcd jited:1 8 PASS\n[ 9757.264435] test_bpf: #313 BSWAP 32: 0x0123456789abcdef -> 0xefcdab89 jited:1 ret 1460850314 != -271733879 (0x5712ce8a != 0xefcdab89)FAIL (1 times)\n[ 9757.266260] test_bpf: #314 BSWAP 64: 0x0123456789abcdef -> 0x67452301 jited:1 8 PASS\n[ 9757.268000] test_bpf: #315 BSWAP 64: 0x0123456789abcdef >> 32 -> 0xefcdab89 jited:1 8 PASS\n[ 9757.269686] test_bpf: #316 BSWAP 16: 0xfedcba9876543210 -> 0x1032 jited:1 8 PASS\n[ 9757.271380] test_bpf: #317 BSWAP 32: 0xfedcba9876543210 -> 0x10325476 jited:1 ret -1460850316 != 271733878 (0xa8ed3174 != 0x10325476)FAIL (1 times)\n[ 9757.273022] test_bpf: #318 BSWAP 64: 0xfedcba9876543210 -> 0x98badcfe jited:1 7 PASS\n[ 9757.274721] test_bpf: #319 BSWAP 64: 0xfedcba9876543210 >> 32 -> 0x10325476 jited:1 9 PASS\n\nFix this by forcing 32bit variant of rev32.\n\nFixes: 1104247f3f979 (""bpf', ' arm64: Support unconditional bswap"")\nSigned-off-by: Artem Savkov \nTested-by: Puranjay Mohan \nAcked-by: Puranjay Mohan \nAcked-by: Xu Kuohai \nMessage-ID: <20240321081809.158803-1-asavkov@redhat.com>\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes an issue with 32-bit unconditional byte swap in ARM64 BPF code.,"ARM64, BPF, fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cc9b22dfa735800980e7362f02aff6f1c2280996,cc9b22dfa735800980e7362f02aff6f1c2280996,Quentin Monnet,qmo@kernel.org,1710898863,Alexei Starovoitov,ast@kernel.org,1711002829,3203601a079fc7f6bfa75424390e5c8c908315fe,520fad2e3206b2476f201a283ecf096cfb671902,bpftool: Clean up HOST_CFLAGS," HOST_LDFLAGS for bootstrap bpftool + +Bpftool's Makefile uses $(HOST_CFLAGS) to build the bootstrap version of +bpftool","[' in order to pick the flags for the host (where we run the\nbootstrap version) and not for the target system (where we plan to run\nthe full bpftool binary). But we pass too much information through this\nvariable.\n\nIn particular', ' we set HOST_CFLAGS by copying most of the $(CFLAGS); but\nwe do this after the feature detection for bpftool', ' which means that\n$(CFLAGS)', ' hence $(HOST_CFLAGS)', ' contain all macro definitions for using\nthe different optional features. For example', ' -DHAVE_LLVM_SUPPORT may be\npassed to the $(HOST_CFLAGS)', ' even though the LLVM disassembler is not\nused in the bootstrap version', ' and the related library may even be\nmissing for the host architecture.\n\nA similar thing happens with the $(LDFLAGS)', ' that we use unchanged for\nlinking the bootstrap version even though they may contains flags to\nlink against additional libraries.\n\nTo address the $(HOST_CFLAGS) issue', ' we move the definition of\n$(HOST_CFLAGS) earlier in the Makefile', ' before the $(CFLAGS) update\nresulting from the feature probing - none of which being relevant to the\nbootstrap version. To clean up the $(LDFLAGS) for the bootstrap version', '\nwe introduce a dedicated $(HOST_LDFLAGS) variable that we base on\n$(LDFLAGS)', ' before the feature probing as well.\n\nOn my setup', ' the following macro and libraries are removed from the\ncompiler invocation to build bpftool after this patch:\n\n -DUSE_LIBCAP\n -DHAVE_LLVM_SUPPORT\n -I/usr/lib/llvm-17/include\n -D_GNU_SOURCE\n -D__STDC_CONSTANT_MACROS\n -D__STDC_FORMAT_MACROS\n -D__STDC_LIMIT_MACROS\n -lLLVM-17\n -L/usr/lib/llvm-17/lib\n\nAnother advantage of cleaning up these flags is that displaying\navailable features with ""bpftool version"" becomes more accurate for the\nbootstrap bpftool', ' and no longer reflects the features detected (and\navailable only) for the final binary.\n\nCc: Jean-Philippe Brucker \nSigned-off-by: Quentin Monnet \nAcked-by: Jiri Olsa \nMessage-ID: <20240320014103.45641-1-qmo@kernel.org>\nSigned-off-by: Alexei Starovoitov \n', '']",Clean up HOST_CFLAGS usage in bpftool's Makefile for bootstrap build.,"bpftool, Makefile, HOST_CFLAGS",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,['other'] +3201de46a2013293abe28caa46aa0387864d7cf7,3201de46a2013293abe28caa46aa0387864d7cf7,Jakub Kicinski,kuba@kernel.org,1710993944,Jakub Kicinski,kuba@kernel.org,1710993945,bb54c5de6214b985d103ec0d400e6b8d9527e10f,f7bf0ec1e73d43a347489e958b42841b111d63d6 00bf63122459e87193ee7f1bc6161c83a525569f,"Merge branch 'report-rcu-qs-for-busy-network-kthreads' + +Yan Zhai says: + +==================== +Report RCU QS for busy network kthreads + +This changeset fixes a common problem for busy networking kthreads. +These threads", e.g. NAPI threads,"[' typically will do:\n\n* polling a batch of packets\n* if there are more work', ' call cond_resched() to allow scheduling\n* continue to poll more packets when rx queue is not empty\n\nWe observed this being a problem in production', ' since it can block RCU\ntasks from making progress under heavy load. Investigation indicates\nthat just calling cond_resched() is insufficient for RCU tasks to reach\nquiescent states. This also has the side effect of frequently clearing\nthe TIF_NEED_RESCHED flag on voluntary preempt kernels. As a result', '\nschedule() will not be called in these circumstances', ' despite schedule()\nin fact provides required quiescent states. This at least affects NAPI\nthreads', ' napi_busy_loop', ' and also cpumap kthread.\n\nBy reporting RCU QSes in these kthreads periodically before cond_resched', ' the\nblocked RCU waiters can correctly progress. Instead of just reporting QS for\nRCU tasks', ' these code share the same concern as noted in the commit\nd28139c4e967 (""rcu: Apply RCU-bh QSes to RCU-sched and RCU-preempt when safe"").\nSo report a consolidated QS for safety.\n\nIt is worth noting that', ' although this problem is reproducible in\nnapi_busy_loop', ' it only shows up when setting the polling interval to as high\nas 2ms', ' which is far larger than recommended 50us-100us in the documentation.\nSo napi_busy_loop is left untouched.\n\nLastly', ' this does not affect RT kernels', ' which does not enter the scheduler\nthrough cond_resched(). Without the mentioned side effect', ' schedule() will\nbe called time by time', ' and clear the RCU task holdouts.\n\nV4: https://lore.kernel.org/bpf/cover.1710525524.git.yan@cloudflare.com/\nV3: https://lore.kernel.org/lkml/20240314145459.7b3aedf1@kernel.org/t/\nV2: https://lore.kernel.org/bpf/ZeFPz4D121TgvCje@debian.debian/\nV1: https://lore.kernel.org/lkml/Zd4DXTyCf17lcTfq@debian.debian/#t\n====================\n\nLink: https://lore.kernel.org/r/cover.1710877680.git.yan@cloudflare.com\nSigned-off-by: Jakub Kicinski \n', '']",Fixes RCU quiescent state reporting for busy network kernel threads.,"RCU,kthreads,networking",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +00bf63122459e87193ee7f1bc6161c83a525569f,00bf63122459e87193ee7f1bc6161c83a525569f,Yan Zhai,yan@cloudflare.com,1710881080,Jakub Kicinski,kuba@kernel.org,1710993943,bb54c5de6214b985d103ec0d400e6b8d9527e10f,d6dbbb11247c71203785a2c9da474c36f4b19eae,"bpf: report RCU QS in cpumap kthread + +When there are heavy load"," cpumap kernel threads can be busy polling +packets from redirect queues and block out RCU tasks from reaching +quiescent states. It is insufficient to just call cond_resched() in such +context. Periodically raise a consolidated RCU QS before cond_resched +fixes the problem. + +Fixes: 6710e1126934 (""bpf: introduce new bpf cpu map type BPF_MAP_TYPE_CPUMAP"") +Reviewed-by: Jesper Dangaard Brouer +Signed-off-by: Yan Zhai +Acked-by: Paul E. McKenney +Acked-by: Jesper Dangaard Brouer +Link: https://lore.kernel.org/r/c17b9f1517e19d813da3ede5ed33ee18496bb5d8.1710877680.git.yan@cloudflare.com +Signed-off-by: Jakub Kicinski +",[''],The commit adds periodic RCU quiescent state reporting in cpumap kthreads to prevent blocking RCU tasks.,"RCU, cpumap, kthread",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d6dbbb11247c71203785a2c9da474c36f4b19eae,d6dbbb11247c71203785a2c9da474c36f4b19eae,Yan Zhai,yan@cloudflare.com,1710881077,Jakub Kicinski,kuba@kernel.org,1710993942,01b60754e953d9a3c3d5109a37a25112fd374362,1a77557d48cff187a169c2aec01c0dd78a5e7e50,"net: report RCU QS on threaded NAPI repolling + +NAPI threads can keep polling packets under load. Currently it is only +calling cond_resched() before repolling"," but it is not sufficient to +clear out the holdout of RCU tasks","[' which prevent BPF tracing programs\nfrom detaching for long period. This can be reproduced easily with\nfollowing set up:\n\nip netns add test1\nip netns add test2\n\nip -n test1 link add veth1 type veth peer name veth2 netns test2\n\nip -n test1 link set veth1 up\nip -n test1 link set lo up\nip -n test2 link set veth2 up\nip -n test2 link set lo up\n\nip -n test1 addr add 192.168.1.2/31 dev veth1\nip -n test1 addr add 1.1.1.1/32 dev lo\nip -n test2 addr add 192.168.1.3/31 dev veth2\nip -n test2 addr add 2.2.2.2/31 dev lo\n\nip -n test1 route add default via 192.168.1.3\nip -n test2 route add default via 192.168.1.2\n\nfor i in `seq 10 210`; do\n for j in `seq 10 210`; do\n ip netns exec test2 iptables -I INPUT -s 3.3.$i.$j -p udp --dport 5201\n done\ndone\n\nip netns exec test2 ethtool -K veth2 gro on\nip netns exec test2 bash -c \'echo 1 > /sys/class/net/veth2/threaded\'\nip netns exec test1 ethtool -K veth1 tso off\n\nThen run an iperf3 client/server and a bpftrace script can trigger it:\n\nip netns exec test2 iperf3 -s -B 2.2.2.2 >/dev/null&\nip netns exec test1 iperf3 -c 2.2.2.2 -B 1.1.1.1 -u -l 1500 -b 3g -t 100 >/dev/null&\nbpftrace -e \'kfunc:__napi_poll{@=count();} interval:s:1{exit();}\'\n\nReport RCU quiescent states periodically will resolve the issue.\n\nFixes: 29863d41bb6e (""net: implement threaded-able napi poll loop support"")\nReviewed-by: Jesper Dangaard Brouer \nSigned-off-by: Yan Zhai \nAcked-by: Paul E. McKenney \nAcked-by: Jesper Dangaard Brouer \nLink: https://lore.kernel.org/r/4c3b0d3f32d3b18949d75b18e5e1d9f13a24f025.1710877680.git.yan@cloudflare.com\nSigned-off-by: Jakub Kicinski \n', '']",Improve RCU task handling during threaded NAPI repolling to optimize network packet processing.,"RCU, NAPI, repolling",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +520fad2e3206b2476f201a283ecf096cfb671902,520fad2e3206b2476f201a283ecf096cfb671902,Andrii Nakryiko,andrii@kernel.org,1710538409,Alexei Starovoitov,ast@kernel.org,1710916895,e4fee37094eff46816887a0f211fe37972ce71f5,e9a826dd145bf2c19888aee1b974214cefc74a2e,"selftests/bpf: scale benchmark counting by using per-CPU counters + +When benchmarking with multiple threads (-pN", where N>1),"[' we start\ncontending on single atomic counter that both BPF trigger benchmarks are\nusing', ' as well as ""baseline"" tests in user space (trig-base and\ntrig-uprobe-base benchmarks). As such', ' we start bottlenecking on\nsomething completely irrelevant to benchmark at hand.\n\nScale counting up by using per-CPU counters on BPF side. On use space\nside we do the next best thing: hash thread ID to approximate per-CPU\nbehavior. It seems to work quite well in practice.\n\nTo demonstrate the difference', ' I ran three benchmarks with 1', ' 2', ' 4', ' 8', '\n16', ' and 32 threads:\n - trig-uprobe-base (no syscalls', ' pure tight counting loop in user-space);\n - trig-base (get_pgid() syscall', ' atomic counter in user-space);\n - trig-fentry (syscall to trigger fentry program', ' atomic uncontended per-CPU\n counter on BPF side).\n\nCommand used:\n\n for b in uprobe-base base fentry; do \\\n for p in 1 2 4 8 16 32; do \\\n printf ""%-11s %2d: %s\\n"" $b $p \\\n ""$(sudo ./bench -w2 -d5 -a -p$p trig-$b | tail -n1 | cut -d\'(\' -f1 | cut -d\' \' -f3-)""; \\\n done; \\\n done\n\nBefore these changes', "" aggregate throughput across all threads doesn't\nscale well with number of threads"", ' it actually even falls sharply for\nuprobe-base due to a very high contention:\n\n uprobe-base 1: 138.998 ± 0.650M/s\n uprobe-base 2: 70.526 ± 1.147M/s\n uprobe-base 4: 63.114 ± 0.302M/s\n uprobe-base 8: 54.177 ± 0.138M/s\n uprobe-base 16: 45.439 ± 0.057M/s\n uprobe-base 32: 37.163 ± 0.242M/s\n base 1: 16.940 ± 0.182M/s\n base 2: 19.231 ± 0.105M/s\n base 4: 21.479 ± 0.038M/s\n base 8: 23.030 ± 0.037M/s\n base 16: 22.034 ± 0.004M/s\n base 32: 18.152 ± 0.013M/s\n fentry 1: 14.794 ± 0.054M/s\n fentry 2: 17.341 ± 0.055M/s\n fentry 4: 23.792 ± 0.024M/s\n fentry 8: 21.557 ± 0.047M/s\n fentry 16: 21.121 ± 0.004M/s\n fentry 32: 17.067 ± 0.023M/s\n\nAfter these changes', ' we see almost perfect linear scaling', ' as expected.\nThe sub-linear scaling when going from 8 to 16 threads is interesting\nand consistent on my test machine', "" but I haven't investigated what is\ncausing it this peculiar slowdown (across all benchmarks"", ' could be due\nto hyperthreading effects', ' not sure).\n\n uprobe-base 1: 139.980 ± 0.648M/s\n uprobe-base 2: 270.244 ± 0.379M/s\n uprobe-base 4: 532.044 ± 1.519M/s\n uprobe-base 8: 1004.571 ± 3.174M/s\n uprobe-base 16: 1720.098 ± 0.744M/s\n uprobe-base 32: 3506.659 ± 8.549M/s\n base 1: 16.869 ± 0.071M/s\n base 2: 33.007 ± 0.092M/s\n base 4: 64.670 ± 0.203M/s\n base 8: 121.969 ± 0.210M/s\n base 16: 207.832 ± 0.112M/s\n base 32: 424.227 ± 1.477M/s\n fentry 1: 14.777 ± 0.087M/s\n fentry 2: 28.575 ± 0.146M/s\n fentry 4: 56.234 ± 0.176M/s\n fentry 8: 106.095 ± 0.385M/s\n fentry 16: 181.440 ± 0.032M/s\n fentry 32: 369.131 ± 0.693M/s\n\nSigned-off-by: Andrii Nakryiko \nMessage-ID: <20240315213329.1161589-1-andrii@kernel.org>\nSigned-off-by: Alexei Starovoitov \n', '']",Enhance benchmark accuracy by implementing per-CPU counters in selftests for multi-threaded environments.,"benchmark, per-CPU, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +e9a826dd145bf2c19888aee1b974214cefc74a2e,e9a826dd145bf2c19888aee1b974214cefc74a2e,Quentin Monnet,qmo@kernel.org,1710898497,Alexei Starovoitov,ast@kernel.org,1710915475,0fa8f3b9dfbc7abc770a626991f7405497945790,be24a895149b6df4c474848e3928c237ad10fdc4,"bpftool: Remove unnecessary source files from bootstrap version + +Commit d510296d331a (""bpftool: Use syscall/loader program in ""prog load"" +and ""gen skeleton"" command."") added new files to the list of objects to +compile in order to build the bootstrap version of bpftool. As far as I +can tell"," these objects are unnecessary and were added by mistake; maybe +a draft version intended to add support for loading loader programs from +the bootstrap version. Anyway","[' we can remove these object files from the\nlist to make the bootstrap bpftool binary a tad smaller and faster to\nbuild.\n\nFixes: d510296d331a (""bpftool: Use syscall/loader program in ""prog load"" and ""gen skeleton"" command."")\nSigned-off-by: Quentin Monnet \nMessage-ID: <20240320013457.44808-1-qmo@kernel.org>\nSigned-off-by: Alexei Starovoitov \n', '']",Remove unnecessary source files from bpftool's bootstrap version due to mistaken inclusion.,"bpftool, bootstrap, unnecessary",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +be24a895149b6df4c474848e3928c237ad10fdc4,be24a895149b6df4c474848e3928c237ad10fdc4,Quentin Monnet,qmo@kernel.org,1710897761,Alexei Starovoitov,ast@kernel.org,1710915142,43ff9022833899117df1e0abacc2f6a807abfdba,2e244a72cd489e9b8d4c779c0674c80cf92b6aab,"bpftool: Enable libbpf logs when loading pid_iter in debug mode + +When trying to load the pid_iter BPF program used to iterate over the +PIDs of the processes holding file descriptors to BPF links"," we would +unconditionally silence libbpf in order to keep the output clean if the +kernel does not support iterators and loading fails. + +Although this is the desirable behaviour in most cases","[' this may hide\nbugs in the pid_iter program that prevent it from loading', ' and it makes\nit hard to debug such load failures', ' even in ""debug"" mode. Instead', "" it\nmakes more sense to print libbpf's logs when we pass the -d|--debug flag\nto bpftool"", "" so that users get the logs to investigate failures without\nhaving to edit bpftool's source code.\n\nSigned-off-by: Quentin Monnet \nMessage-ID: <20240320012241.42991-1-qmo@kernel.org>\nSigned-off-by: Alexei Starovoitov \n"", '']",Enable libbpf logs for pid_iter BPF program in debug mode in bpftool.,"libbpf, pid_iter, debug",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,['tracepoints like programs'] +2e244a72cd489e9b8d4c779c0674c80cf92b6aab,2e244a72cd489e9b8d4c779c0674c80cf92b6aab,Alexei Starovoitov,ast@kernel.org,1710914734,Alexei Starovoitov,ast@kernel.org,1710914734,53411f9aa32fbcae919dc97e705a7598893d5156,f803bcf9208a2540acb4c32bdc3616673169f490 51146ff0fae309a558bc8ab6cbf6cfda17356993,"Merge branch 'bpf-raw-tracepoint-support-for-bpf-cookie' + +Andrii Nakryiko says: + +==================== +BPF raw tracepoint support for BPF cookie + +Add ability to specify and retrieve BPF cookie for raw tracepoint programs. +Both BTF-aware (SEC(""tp_btf"")) and non-BTF-aware (SEC(""raw_tp"")) are +supported"," as they are exactly the same at runtime. + +This issue recently came up in production use cases","[' where custom tried to\nswitch from slower classic tracepoints to raw tracepoints and ran into this\nlimitation. Luckily', "" it's not that hard to support this for raw_tp programs.\n\nv2->v3:\n - s/bpf_raw_tp_open/bpf_raw_tracepoint_open_opts/ (Alexei"", ' Eduard);\nv1->v2:\n - fixed type definition for stubs of bpf_probe_{register', ""unregister};\n - added __u32 :u32 and aligned raw_tp fields (Jiri);\n - added Stanislav's ack.\n====================\n\nLink: https://lore.kernel.org/r/20240319233852.1977493-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']","Add support for specifying and retrieving BPF cookies in raw tracepoint programs, including BTF-aware and non-BTF-aware implementations.","BPF cookie,raw tracepoint,support",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +51146ff0fae309a558bc8ab6cbf6cfda17356993,51146ff0fae309a558bc8ab6cbf6cfda17356993,Andrii Nakryiko,andrii@kernel.org,1710891532,Alexei Starovoitov,ast@kernel.org,1710914734,53411f9aa32fbcae919dc97e705a7598893d5156,36ffb2023e3703a64266ca5fed30f710b1263c70,"selftests/bpf: add raw_tp/tp_btf BPF cookie subtests + +Add test validating BPF cookie can be passed during raw_tp/tp_btf +attachment and can be retried at runtime with bpf_get_attach_cookie() +helper. + +Acked-by: Stanislav Fomichev +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319233852.1977493-6-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov +",,Add subtests for validating BPF cookie during raw_tp/tp_btf attachment using bpf_get_attach_cookie() helper.,"BPF cookie,raw_tp,tp_btf",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +36ffb2023e3703a64266ca5fed30f710b1263c70,36ffb2023e3703a64266ca5fed30f710b1263c70,Andrii Nakryiko,andrii@kernel.org,1710891531,Alexei Starovoitov,ast@kernel.org,1710914734,fb05c40a43afcd3f237b38c253256379c0a23a09,68ca5d4eebb8c4de246ee5f634eee26bc689562d,"libbpf: add support for BPF cookie for raw_tp/tp_btf programs + +Wire up BPF cookie passing or raw_tp and tp_btf programs"," both in +low-level and high-level APIs. + +Acked-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319233852.1977493-5-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov +",[''],Added support for BPF cookie in libbpf for raw_tp and tp_btf programs.,"BPF cookie, raw_tp, tp_btf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +68ca5d4eebb8c4de246ee5f634eee26bc689562d,68ca5d4eebb8c4de246ee5f634eee26bc689562d,Andrii Nakryiko,andrii@kernel.org,1710891530,Alexei Starovoitov,ast@kernel.org,1710914734,bca6f6bf993364106eab3d99e79796e4ca01685e,d4dfc5700e867b22ab94f960f9a9972696a637d5,bpf: support BPF cookie in raw tracepoint (raw_tp," tp_btf) programs + +Wire up BPF cookie for raw tracepoint programs (both BTF and non-BTF +aware variants). This brings them up to part w.r.t. BPF cookie usage +with classic tracepoint and fentry/fexit programs. + +Acked-by: Stanislav Fomichev +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319233852.1977493-4-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov +",[''],Wire up BPF cookie support for raw tracepoint programs in both BTF and non-BTF variants.,"BPF cookie, raw tracepoint, BTF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +d4dfc5700e867b22ab94f960f9a9972696a637d5,d4dfc5700e867b22ab94f960f9a9972696a637d5,Andrii Nakryiko,andrii@kernel.org,1710891529,Alexei Starovoitov,ast@kernel.org,1710914733,fa2c0c39612987fdcab3cd17e8f34b5908fe7d31,6b9c2950c912780ce113079c9c52041b1e2a611a,"bpf: pass whole link instead of prog when triggering raw tracepoint + +Instead of passing prog as an argument to bpf_trace_runX() helpers"," that +are called from tracepoint triggering calls","[' store BPF link itself\n(struct bpf_raw_tp_link for raw tracepoints). This will allow to pass\nextra information like BPF cookie into raw tracepoint registration.\n\nInstead of replacing `struct bpf_prog *prog = __data;` with\ncorresponding `struct bpf_raw_tp_link *link = __data;` assignment in\n`__bpf_trace_##call` I just passed `__data` through into underlying\nbpf_trace_runX() call. This works well because we implicitly cast `void *`', '\nand it also avoids naming clashes with arguments coming from\ntracepoint\'s ""proto"" list. We could have run into the same problem with\n""prog""', ' we just happened to not have a tracepoint that has ""prog"" input\nargument. We are less lucky with ""link""', ' as there are tracepoints using\n""link"" argument name already. So instead of trying to avoid naming\nconflicts', "" let's just remove intermediate local variable. It doesn't\nhurt readibility"", "" it's either way a bit of a maze of calls and macros"", '\nthat requires careful reading.\n\nAcked-by: Stanislav Fomichev \nSigned-off-by: Andrii Nakryiko \nMessage-ID: <20240319233852.1977493-3-andrii@kernel.org>\nSigned-off-by: Alexei Starovoitov \n', '']",The commit changes the argument to bpf_trace_runX() helpers from prog to the whole link for triggering raw tracepoints.,"bpf, tracepoints, link",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +6b9c2950c912780ce113079c9c52041b1e2a611a,6b9c2950c912780ce113079c9c52041b1e2a611a,Andrii Nakryiko,andrii@kernel.org,1710891528,Alexei Starovoitov,ast@kernel.org,1710914733,bb5b88cda791dce09c4065b1ee1c20a985d2f623,f803bcf9208a2540acb4c32bdc3616673169f490,"bpf: flatten bpf_probe_register call chain + +bpf_probe_register() and __bpf_probe_register() have identical +signatures and bpf_probe_register() just redirect to +__bpf_probe_register(). So get rid of this extra function call step to +simplify following the source code. + +It has no difference at runtime due to inlining"," of course. + +Acked-by: Stanislav Fomichev +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319233852.1977493-2-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov +",[''],The commit simplifies the source code by removing an unnecessary function call step in bpf_probe_register.,"simplify,function,call",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +114b5b3b4bde7358624437be2f12cde1b265224e,114b5b3b4bde7358624437be2f12cde1b265224e,Puranjay Mohan,puranjay12@gmail.com,1710287957,Alexei Starovoitov,ast@kernel.org,1710914119,939f3098ea73a57a4752cced16f8e3e97f2c7c28,5ab8cb89dbb6f3e111c8b0a9a86496da23c94439,bpf," arm64: fix bug in BPF_LDX_MEMSX + +A64_LDRSW() takes three registers: Xt","[' Xn', ' Xm as arguments and it loads\nand sign extends the value at address Xn + Xm into register Xt.\n\nCurrently', ' the offset is being directly used in place of the tmp\nregister which has the offset already loaded by the last emitted\ninstruction.\n\nThis will cause JIT failures. The easiest way to reproduce this is to\ntest the following code through test_bpf module:\n\n{\n\t""BPF_LDX_MEMSX | BPF_W""', '\n\t.u.insns_int = {\n\t\tBPF_LD_IMM64(R1', ' 0x00000000deadbeefULL)', '\n\t\tBPF_LD_IMM64(R2', ' 0xffffffffdeadbeefULL)', '\n\t\tBPF_STX_MEM(BPF_DW', ' R10', ' R1', ' -7)', '\n\t\tBPF_LDX_MEMSX(BPF_W', ' R0', ' R10', ' -7)', '\n\t\tBPF_JMP_REG(BPF_JNE', ' R0', ' R2', ' 1)', '\n\t\tBPF_ALU64_IMM(BPF_MOV', ' R0', ' 0)', '\n\t\tBPF_EXIT_INSN()', '\n\t}', '\n\tINTERNAL', '\n\t{ }', '\n\t{ { 0', ' 0 } }', '\n\t.stack_depth = 7', '\n}', '\n\nWe need to use the offset as -7 to trigger this code path', ' there could\nbe other valid ways to trigger this from proper BPF programs as well.\n\nThis code is rejected by the JIT because -7 is passed to A64_LDRSW() but\nit expects a valid register (0 - 31).\n\n roott@pjy:~# modprobe test_bpf test_name=""BPF_LDX_MEMSX | BPF_W""\n [11300.490371] test_bpf: test_bpf: set \'test_bpf\' as the default test_suite.\n [11300.491750] test_bpf: #345 BPF_LDX_MEMSX | BPF_W\n [11300.493179] aarch64_insn_encode_register: unknown register encoding -7\n [11300.494133] aarch64_insn_encode_register: unknown register encoding -7\n [11300.495292] FAIL to select_runtime err=-524\n [11300.496804] test_bpf: Summary: 0 PASSED', ' 1 FAILED', ' [0/0 JIT\'ed]\n modprobe: ERROR: could not insert \'test_bpf\': Invalid argument\n\nApplying this patch fixes the issue.\n\n root@pjy:~# modprobe test_bpf test_name=""BPF_LDX_MEMSX | BPF_W""\n [ 292.837436] test_bpf: test_bpf: set \'test_bpf\' as the default test_suite.\n [ 292.839416] test_bpf: #345 BPF_LDX_MEMSX | BPF_W jited:1 156 PASS\n [ 292.844794] test_bpf: Summary: 1 PASSED', ' 0 FAILED', ' [1/1 JIT\'ed]\n\nFixes: cc88f540da52 (""bpf', ' arm64: Support sign-extension load instructions"")\nSigned-off-by: Puranjay Mohan \nMessage-ID: <20240312235917.103626-1-puranjay12@gmail.com>\nSigned-off-by: Alexei Starovoitov \n', '']",Fix a bug related to the BPF_LDX_MEMSX instruction on arm64.,"bug, BPF_LDX_MEMSX, arm64",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5ab8cb89dbb6f3e111c8b0a9a86496da23c94439,5ab8cb89dbb6f3e111c8b0a9a86496da23c94439,Andrii Nakryiko,andrii@kernel.org,1710885103,Alexei Starovoitov,ast@kernel.org,1710914044,e39824b931c665dba7872599e8d7a3982292e036,7ded842b356d151ece8ac4985940438e6d3998bb,"libbpf: fix u64-to-pointer cast on 32-bit arches + +It's been reported that (void *)map->map_extra is causing compilation +warnings on 32-bit architectures. It's easy enough to fix this by +casting to long first. + +Fixes: 79ff13e99169 (""libbpf: Add support for bpf_arena."") +Reported-by: Ryan Eatmon +Signed-off-by: Andrii Nakryiko +Message-ID: <20240319215143.1279312-1-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov +",,Fix compilation warning on 32-bit architectures by adjusting u64-to-pointer casting in libbpf.,"libbpf,cast,32-bit",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"[""It's not related to any of the above.""]" +7ded842b356d151ece8ac4985940438e6d3998bb,7ded842b356d151ece8ac4985940438e6d3998bb,Ilya Leoshkevich,iii@linux.ibm.com,1710899652,Alexei Starovoitov,ast@kernel.org,1710913963,f3232760a376c683a629c6c47e9ac4a9500967d1,f6e922365faf4cd576bd1cf3e64b58c8a32e1856,"s390/bpf: Fix bpf_plt pointer arithmetic + +Kui-Feng Lee reported a crash on s390x triggered by the +dummy_st_ops/dummy_init_ptr_arg test [1]: + + [<0000000000000002>] 0x2 + [<00000000009d5cde>] bpf_struct_ops_test_run+0x156/0x250 + [<000000000033145a>] __sys_bpf+0xa1a/0xd00 + [<00000000003319dc>] __s390x_sys_bpf+0x44/0x50 + [<0000000000c4382c>] __do_syscall+0x244/0x300 + [<0000000000c59a40>] system_call+0x70/0x98 + +This is caused by GCC moving memcpy() after assignments in +bpf_jit_plt()"," resulting in NULL pointers being written instead of +the return and the target addresses. + +Looking at the GCC internals","["" the reordering is allowed because the\nalias analysis thinks that the memcpy() destination and the assignments'\nleft-hand-sides are based on different objects: new_plt and\nbpf_plt_ret/bpf_plt_target respectively"", ' and therefore they cannot\nalias.\n\nThis is in turn due to a violation of the C standard:\n\n When two pointers are subtracted', ' both shall point to elements of the\n same array object', "" or one past the last element of the array object\n ...\n\nFrom the C's perspective"", ' bpf_plt_ret and bpf_plt are distinct objects\nand cannot be subtracted. In the practical terms', "" doing so confuses the\nGCC's alias analysis.\n\nThe code was written this way in order to let the C side know a few\noffsets defined in the assembly. While nice"", ' this is by no means\nnecessary. Fix the noncompliance by hardcoding these offsets.\n\n[1] https://lore.kernel.org/bpf/c9923c1d-971d-4022-8dc8-1364e929d34c@gmail.com/\n\nFixes: f1d5df84cd8c (""s390/bpf: Implement bpf_arch_text_poke()"")\nSigned-off-by: Ilya Leoshkevich \nMessage-ID: <20240320015515.11883-1-iii@linux.ibm.com>\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes pointer arithmetic bug in s390 BPF leading to crashes during tests.,"pointer, bug, arithmetic",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +956c0d6191075f0592367512bf07aede458f0151,956c0d6191075f0592367512bf07aede458f0151,Kuniyuki Iwashima,kuniyu@amazon.com,1710542830,Jakub Kicinski,kuba@kernel.org,1710902159,3c27f57f732e6d4ce846b1f802098350a2a0441c,d27e2da94a42655861ca4baea30c8cd65546f25d,"tcp: Clear req->syncookie in reqsk_alloc(). + +syzkaller reported a read of uninit req->syncookie. [0] + +Originally"," req->syncookie was used only in tcp_conn_request() +to indicate if we need to encode SYN cookie in SYN+ACK","[' so the\nfield remains uninitialised in other places.\n\nThe commit 695751e31a63 (""bpf: tcp: Handle BPF SYN Cookie in\ncookie_v[46]_check()."") added another meaning in ACK path;\nreq->syncookie is set true if SYN cookie is validated by BPF\nkfunc.\n\nAfter the change', ' cookie_v[46]_check() always read req->syncookie', ""\nbut it is not initialised in the normal SYN cookie case as reported\nby KMSAN.\n\nLet's make sure we always initialise req->syncookie in reqsk_alloc().\n\n[0]:\nBUG: KMSAN: uninit-value in cookie_v4_check+0x22b7/0x29e0\n net/ipv4/syncookies.c:477\n cookie_v4_check+0x22b7/0x29e0 net/ipv4/syncookies.c:477\n tcp_v4_cookie_check net/ipv4/tcp_ipv4.c:1855 [inline]\n tcp_v4_do_rcv+0xb17/0x10b0 net/ipv4/tcp_ipv4.c:1914\n tcp_v4_rcv+0x4ce4/0x5420 net/ipv4/tcp_ipv4.c:2322\n ip_protocol_deliver_rcu+0x2a3/0x13d0 net/ipv4/ip_input.c:205\n ip_local_deliver_finish+0x332/0x500 net/ipv4/ip_input.c:233\n NF_HOOK include/linux/netfilter.h:314 [inline]\n ip_local_deliver+0x21f/0x490 net/ipv4/ip_input.c:254\n dst_input include/net/dst.h:460 [inline]\n ip_rcv_finish+0x4a2/0x520 net/ipv4/ip_input.c:449\n NF_HOOK include/linux/netfilter.h:314 [inline]\n ip_rcv+0xcd/0x380 net/ipv4/ip_input.c:569\n __netif_receive_skb_one_core net/core/dev.c:5538 [inline]\n __netif_receive_skb+0x319/0x9e0 net/core/dev.c:5652\n process_backlog+0x480/0x8b0 net/core/dev.c:5981\n __napi_poll+0xe7/0x980 net/core/dev.c:6632\n napi_poll net/core/dev.c:6701 [inline]\n net_rx_action+0x89d/0x1820 net/core/dev.c:6813\n __do_softirq+0x1c0/0x7d7 kernel/softirq.c:554\n do_softirq+0x9a/0x100 kernel/softirq.c:455\n __local_bh_enable_ip+0x9f/0xb0 kernel/softirq.c:382\n local_bh_enable include/linux/bottom_half.h:33 [inline]\n rcu_read_unlock_bh include/linux/rcupdate.h:820 [inline]\n __dev_queue_xmit+0x2776/0x52c0 net/core/dev.c:4362\n dev_queue_xmit include/linux/netdevice.h:3091 [inline]\n neigh_hh_output include/net/neighbour.h:526 [inline]\n neigh_output include/net/neighbour.h:540 [inline]\n ip_finish_output2+0x187a/0x1b70 net/ipv4/ip_output.c:235\n __ip_finish_output+0x287/0x810\n ip_finish_output+0x4b/0x550 net/ipv4/ip_output.c:323\n NF_HOOK_COND include/linux/netfilter.h:303 [inline]\n ip_output+0x15f/0x3f0 net/ipv4/ip_output.c:433\n dst_output include/net/dst.h:450 [inline]\n ip_local_out net/ipv4/ip_output.c:129 [inline]\n __ip_queue_xmit+0x1e93/0x2030 net/ipv4/ip_output.c:535\n ip_queue_xmit+0x60/0x80 net/ipv4/ip_output.c:549\n __tcp_transmit_skb+0x3c70/0x4890 net/ipv4/tcp_output.c:1462\n tcp_transmit_skb net/ipv4/tcp_output.c:1480 [inline]\n tcp_write_xmit+0x3ee1/0x8900 net/ipv4/tcp_output.c:2792\n __tcp_push_pending_frames net/ipv4/tcp_output.c:2977 [inline]\n tcp_send_fin+0xa90/0x12e0 net/ipv4/tcp_output.c:3578\n tcp_shutdown+0x198/0x1f0 net/ipv4/tcp.c:2716\n inet_shutdown+0x33f/0x5b0 net/ipv4/af_inet.c:923\n __sys_shutdown_sock net/socket.c:2425 [inline]\n __sys_shutdown net/socket.c:2437 [inline]\n __do_sys_shutdown net/socket.c:2445 [inline]\n __se_sys_shutdown+0x2a4/0x440 net/socket.c:2443\n __x64_sys_shutdown+0x6c/0xa0 net/socket.c:2443\n do_syscall_64+0xd5/0x1f0\n entry_SYSCALL_64_after_hwframe+0x6d/0x75\n\nUninit was stored to memory at:\n reqsk_alloc include/net/request_sock.h:148 [inline]\n inet_reqsk_alloc+0x651/0x7a0 net/ipv4/tcp_input.c:6978\n cookie_tcp_reqsk_alloc+0xd4/0x900 net/ipv4/syncookies.c:328\n cookie_tcp_check net/ipv4/syncookies.c:388 [inline]\n cookie_v4_check+0x289f/0x29e0 net/ipv4/syncookies.c:420\n tcp_v4_cookie_check net/ipv4/tcp_ipv4.c:1855 [inline]\n tcp_v4_do_rcv+0xb17/0x10b0 net/ipv4/tcp_ipv4.c:1914\n tcp_v4_rcv+0x4ce4/0x5420 net/ipv4/tcp_ipv4.c:2322\n ip_protocol_deliver_rcu+0x2a3/0x13d0 net/ipv4/ip_input.c:205\n ip_local_deliver_finish+0x332/0x500 net/ipv4/ip_input.c:233\n NF_HOOK include/linux/netfilter.h:314 [inline]\n ip_local_deliver+0x21f/0x490 net/ipv4/ip_input.c:254\n dst_input include/net/dst.h:460 [inline]\n ip_rcv_finish+0x4a2/0x520 net/ipv4/ip_input.c:449\n NF_HOOK include/linux/netfilter.h:314 [inline]\n ip_rcv+0xcd/0x380 net/ipv4/ip_input.c:569\n __netif_receive_skb_one_core net/core/dev.c:5538 [inline]\n __netif_receive_skb+0x319/0x9e0 net/core/dev.c:5652\n process_backlog+0x480/0x8b0 net/core/dev.c:5981\n __napi_poll+0xe7/0x980 net/core/dev.c:6632\n napi_poll net/core/dev.c:6701 [inline]\n net_rx_action+0x89d/0x1820 net/core/dev.c:6813\n __do_softirq+0x1c0/0x7d7 kernel/softirq.c:554\n\nUninit was created at:\n __alloc_pages+0x9a7/0xe00 mm/page_alloc.c:4592\n __alloc_pages_node include/linux/gfp.h:238 [inline]\n alloc_pages_node include/linux/gfp.h:261 [inline]\n alloc_slab_page mm/slub.c:2175 [inline]\n allocate_slab mm/slub.c:2338 [inline]\n new_slab+0x2de/0x1400 mm/slub.c:2391\n ___slab_alloc+0x1184/0x33d0 mm/slub.c:3525\n __slab_alloc mm/slub.c:3610 [inline]\n __slab_alloc_node mm/slub.c:3663 [inline]\n slab_alloc_node mm/slub.c:3835 [inline]\n kmem_cache_alloc+0x6d3/0xbe0 mm/slub.c:3852\n reqsk_alloc include/net/request_sock.h:131 [inline]\n inet_reqsk_alloc+0x66/0x7a0 net/ipv4/tcp_input.c:6978\n tcp_conn_request+0x484/0x44e0 net/ipv4/tcp_input.c:7135\n tcp_v4_conn_request+0x16f/0x1d0 net/ipv4/tcp_ipv4.c:1716\n tcp_rcv_state_process+0x2e5/0x4bb0 net/ipv4/tcp_input.c:6655\n tcp_v4_do_rcv+0xbfd/0x10b0 net/ipv4/tcp_ipv4.c:1929\n tcp_v4_rcv+0x4ce4/0x5420 net/ipv4/tcp_ipv4.c:2322\n ip_protocol_deliver_rcu+0x2a3/0x13d0 net/ipv4/ip_input.c:205\n ip_local_deliver_finish+0x332/0x500 net/ipv4/ip_input.c:233\n NF_HOOK include/linux/netfilter.h:314 [inline]\n ip_local_deliver+0x21f/0x490 net/ipv4/ip_input.c:254\n dst_input include/net/dst.h:460 [inline]\n ip_sublist_rcv_finish net/ipv4/ip_input.c:580 [inline]\n ip_list_rcv_finish net/ipv4/ip_input.c:631 [inline]\n ip_sublist_rcv+0x15f3/0x17f0 net/ipv4/ip_input.c:639\n ip_list_rcv+0x9ef/0xa40 net/ipv4/ip_input.c:674\n __netif_receive_skb_list_ptype net/core/dev.c:5581 [inline]\n __netif_receive_skb_list_core+0x15c5/0x1670 net/core/dev.c:5629\n __netif_receive_skb_list net/core/dev.c:5681 [inline]\n netif_receive_skb_list_internal+0x106c/0x16f0 net/core/dev.c:5773\n gro_normal_list include/net/gro.h:438 [inline]\n napi_complete_done+0x425/0x880 net/core/dev.c:6113\n virtqueue_napi_complete drivers/net/virtio_net.c:465 [inline]\n virtnet_poll+0x149d/0x2240 drivers/net/virtio_net.c:2211\n __napi_poll+0xe7/0x980 net/core/dev.c:6632\n napi_poll net/core/dev.c:6701 [inline]\n net_rx_action+0x89d/0x1820 net/core/dev.c:6813\n __do_softirq+0x1c0/0x7d7 kernel/softirq.c:554\n\nCPU: 0 PID: 16792 Comm: syz-executor.2 Not tainted 6.8.0-syzkaller-05562-g61387b8dcf1d #0\nHardware name: Google Google Compute Engine/Google Compute Engine"", ' BIOS Google 02/29/2024\n\nFixes: 695751e31a63 (""bpf: tcp: Handle BPF SYN Cookie in cookie_v[46]_check()."")\nReported-by: syzkaller \nReported-by: Eric Dumazet \nCloses: https://lore.kernel.org/bpf/CANn89iKdN9c+C_2JAUbc+VY3DDQjAQukMtiBbormAmAk9CdvQA@mail.gmail.com/\nSigned-off-by: Kuniyuki Iwashima \nReviewed-by: Eric Dumazet \nAcked-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20240315224710.55209-1-kuniyu@amazon.com\nSigned-off-by: Jakub Kicinski \n', '']",Fix uninitialized req->syncookie issue in reqsk_alloc() in TCP connection handling.,"tcp, syncookie, syzkaller",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +f803bcf9208a2540acb4c32bdc3616673169f490,f803bcf9208a2540acb4c32bdc3616673169f490,Alessandro Carminati (Red Hat),alessandro.carminati@gmail.com,1710413951,Andrii Nakryiko,andrii@kernel.org,1710890169,a90cb445d6fa8d01e4d2e739c5d7d48a78a33a29,437ffcb0bf97361e5c4062043309832f4724d1a8,"selftests/bpf: Prevent client connect before server bind in test_tc_tunnel.sh + +In some systems"," the netcat server can incur in delay to start listening. +When this happens","[' the test can randomly fail in various points.\nThis is an example error message:\n\n # ip gre none gso\n # encap 192.168.1.1 to 192.168.1.2', ' type gre', ' mac none len 2000\n # test basic connectivity\n # Ncat: Connection refused.\n\nThe issue stems from a race condition between the netcat client and server.\nThe test author had addressed this problem by implementing a sleep', ' which\nI have removed in this patch.\nThis patch introduces a function capable of sleeping for up to two seconds.\nHowever', ' it can terminate the waiting period early if the port is reported\nto be listening.\n\nSigned-off-by: Alessandro Carminati (Red Hat) \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240314105911.213411-1-alessandro.carminati@gmail.com\n', '']",Fix race condition by ensuring server is ready before the client connects in test_tc_tunnel.sh.,"selftests,bpf,connect",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tc/netfilter like programs'] +437ffcb0bf97361e5c4062043309832f4724d1a8,437ffcb0bf97361e5c4062043309832f4724d1a8,Andrii Nakryiko,andrii@kernel.org,1710883315,Andrii Nakryiko,andrii@kernel.org,1710883621,334907acabeb9fe6a105708b078f8b54f68f9e6e,1a4a0cb7985f921548f1a7ac17686afbefe67f87 4c195ee4865d57786b3a63018d489b8a07877354,"Merge branch 'current_pid_tgid-for-all-prog-types' + +Yonghong Song says: + +==================== +current_pid_tgid() for all prog types + +Currently bpf_get_current_pid_tgid() is allowed in tracing"," cgroup +and sk_msg progs while bpf_get_ns_current_pid_tgid() is only allowed +in tracing progs. + +We have an internal use case where for an application running +in a container (with pid namespace)","[' user wants to get\nthe pid associated with the pid namespace in a cgroup bpf\nprogram. Besides cgroup', ' the only prog type', ' supporting\nbpf_get_current_pid_tgid() but not bpf_get_ns_current_pid_tgid()', '\nis sk_msg.\n\nBut actually both bpf_get_current_pid_tgid() and\nbpf_get_ns_current_pid_tgid() helpers do not reveal kernel internal\ndata and there is no reason that they cannot be used in other\nprogram types. This patch just did this and enabled these\ntwo helpers for all program types.\n\nPatch 1 added the kernel support and patches 2-5 added\nthe test for cgroup and sk_msg.\n\nChange logs:\n v1 -> v2:\n - allow bpf_get_[ns_]current_pid_tgid() for all prog types.\n - for network related selftests', ' using netns.\n====================\n\nLink: https://lore.kernel.org/r/20240315184849.2974556-1-yonghong.song@linux.dev\nSigned-off-by: Andrii Nakryiko \n', '']","Extend support for bpf_get_current_pid_tgid() to all eBPF program types, improving container namespace compatibility.","bpf_get_current_pid_tgid,prog types,container",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4c195ee4865d57786b3a63018d489b8a07877354,4c195ee4865d57786b3a63018d489b8a07877354,Yonghong Song,yonghong.song@linux.dev,1710528555,Andrii Nakryiko,andrii@kernel.org,1710883620,334907acabeb9fe6a105708b078f8b54f68f9e6e,87ade6cd859ea9dbde6e80b3fcf717ed9a73b4a9,"selftests/bpf: Add a sk_msg prog bpf_get_ns_current_pid_tgid() test + +Add a sk_msg bpf program test where the program is running in a pid +namespace. The test is successful: + #165/4 ns_current_pid_tgid/new_ns_sk_msg:OK + +Signed-off-by: Yonghong Song +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240315184915.2976718-1-yonghong.song@linux.dev +",,Add a selftest for sk_msg program using bpf_get_ns_current_pid_tgid().,"selftest, sk_msg, bpf_get_ns_current_pid_tgid",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +87ade6cd859ea9dbde6e80b3fcf717ed9a73b4a9,87ade6cd859ea9dbde6e80b3fcf717ed9a73b4a9,Yonghong Song,yonghong.song@linux.dev,1710528550,Andrii Nakryiko,andrii@kernel.org,1710883619,97a9efc82b398905fbf299a093d751180ef9f358,4d4bd29e363c467752536f874a2cba10a5923c59,"selftests/bpf: Add a cgroup prog bpf_get_ns_current_pid_tgid() test + +Add a cgroup bpf program test where the bpf program is running +in a pid namespace. The test is successfully: + #165/3 ns_current_pid_tgid/new_ns_cgrp:OK + +Signed-off-by: Yonghong Song +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240315184910.2976522-1-yonghong.song@linux.dev +",,Add a test for cgroup BPF programs using bpf_get_ns_current_pid_tgid in a PID namespace.,"cgroup, test, pid namespace",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['cgroup like programs'] +4d4bd29e363c467752536f874a2cba10a5923c59,4d4bd29e363c467752536f874a2cba10a5923c59,Yonghong Song,yonghong.song@linux.dev,1710528544,Andrii Nakryiko,andrii@kernel.org,1710883618,bd42079c998c577d894c1bd3fcdf27e6396dd2c5,84239a24d10174fcfc7d6760cb120435a6ff69af,"selftests/bpf: Refactor out some functions in ns_current_pid_tgid test + +Refactor some functions in both user space code and bpf program +as these functions are used by later cgroup/sk_msg tests. +Another change is to mark tp program optional loading as later +patches will use optional loading as well since they have quite +different attachment and testing logic. + +There is no functionality change. + +Signed-off-by: Yonghong Song +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240315184904.2976123-1-yonghong.song@linux.dev +",,Refactor functions in the ns_current_pid_tgid test for future use in cgroup/sk_msg selftests without changing functionality.,"refactor, selftests, optional loading",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['cgroup like programs', 'tracepoints like programs']" +84239a24d10174fcfc7d6760cb120435a6ff69af,84239a24d10174fcfc7d6760cb120435a6ff69af,Yonghong Song,yonghong.song@linux.dev,1710528539,Andrii Nakryiko,andrii@kernel.org,1710883477,9590038ef860dc7d5a538b15bbd15d30144dcd16,eb166e522c77699fc19bfa705652327a1e51a117,"selftests/bpf: Replace CHECK with ASSERT_* in ns_current_pid_tgid test + +Replace CHECK in selftest ns_current_pid_tgid with recommended ASSERT_* style. +I also shortened subtest name as the prefix of subtest name is covered +by the test name already. + +This patch does fix a testing issue. Currently even if bss->user_{pid","tgid} +is not correct","[' the test still passed since the clone func returns 0.\nI fixed it to return a non-zero value if bss->user_{pid', 'tgid} is incorrect.\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/bpf/20240315184859.2975543-1-yonghong.song@linux.dev\n', '']",Replaced CHECK with ASSERT_* in the ns_current_pid_tgid selftest for better clarity and error handling.,"CHECK, ASSERT, selftest",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +eb166e522c77699fc19bfa705652327a1e51a117,eb166e522c77699fc19bfa705652327a1e51a117,Yonghong Song,yonghong.song@linux.dev,1710528534,Andrii Nakryiko,andrii@kernel.org,1710883447,868016438479325a893aa55572834edc674f267d,1a4a0cb7985f921548f1a7ac17686afbefe67f87,"bpf: Allow helper bpf_get_[ns_]current_pid_tgid() for all prog types + +Currently bpf_get_current_pid_tgid() is allowed in tracing"," cgroup +and sk_msg progs while bpf_get_ns_current_pid_tgid() is only allowed +in tracing progs. + +We have an internal use case where for an application running +in a container (with pid namespace)","[' user wants to get\nthe pid associated with the pid namespace in a cgroup bpf\nprogram. Currently', ' cgroup bpf progs already allow\nbpf_get_current_pid_tgid(). Let us allow bpf_get_ns_current_pid_tgid()\nas well.\n\nWith auditing the code', ' bpf_get_current_pid_tgid() is also used\nby sk_msg prog. But there are no side effect to expose these two\nhelpers to all prog types since they do not reveal any kernel specific\ndata. The detailed discussion is in [1].\n\nSo with this patch', ' both bpf_get_current_pid_tgid() and bpf_get_ns_current_pid_tgid()\nare put in bpf_base_func_proto()', ' making them available to all\nprogram types.\n\n [1] https://lore.kernel.org/bpf/20240307232659.1115872-1-yonghong.song@linux.dev/\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/bpf/20240315184854.2975190-1-yonghong.song@linux.dev\n', '']",The commit allows bpf_get_[ns_]current_pid_tgid() helper function for all eBPF program types.,"helper, prog types, pid tgid",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f6e922365faf4cd576bd1cf3e64b58c8a32e1856,f6e922365faf4cd576bd1cf3e64b58c8a32e1856,Stanislav Fomichev,sdf@google.com,1710780867,Daniel Borkmann,daniel@iogearbox.net,1710852449,c372a3f31a8e6f41af1bcd51c6187805f8da8503,0740b6427e90ef03177888c50dc1c78ca6e0f7f0,"xsk: Don't assume metadata is always requested in TX completion + +`compl->tx_timestam != NULL` means that the user has explicitly +requested the metadata via XDP_TX_METADATA+XDP_TX_METADATA_TIMESTAMP. + +Fixes: 48eb03dd2630 (""xsk: Add TX timestamp and TX checksum offload support"") +Reported-by: Daniele Salvatore Albano +Signed-off-by: Stanislav Fomichev +Signed-off-by: Daniel Borkmann +Tested-by: Daniele Salvatore Albano +Link: https://lore.kernel.org/bpf/20240318165427.1403313-1-sdf@google.com +",,Fixes assumption about metadata request in TX completion for xsk.,"xsk,metadata,TX completion",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['xdp like programs', 'socket like programs']" +1a4a0cb7985f921548f1a7ac17686afbefe67f87,1a4a0cb7985f921548f1a7ac17686afbefe67f87,Jesper Dangaard Brouer,hawk@kernel.org,1710768326,Daniel Borkmann,daniel@iogearbox.net,1710852363,c42fe60b18d5a8d0c9432082ab2a121d2cf192fb,c733239f8f530872a1f80d8c45dcafbaff368737,"bpf/lpm_trie: Inline longest_prefix_match for fastpath + +The BPF map type LPM (Longest Prefix Match) is used heavily +in production by multiple products that have BPF components. +Perf data shows trie_lookup_elem() and longest_prefix_match() +being part of kernels perf top. + +For every level in the LPM tree trie_lookup_elem() calls out +to longest_prefix_match(). The compiler is free to inline this +call", but chooses not to inline,"[' because other slowpath callers\n(that can be invoked via syscall) exists like trie_update_elem()', ""\ntrie_delete_elem() or trie_get_next_key().\n\n bcc/tools/funccount -Ti 1 'trie_lookup_elem|longest_prefix_match.isra.0'\n FUNC COUNT\n trie_lookup_elem 664945\n longest_prefix_match.isra.0 8101507\n\nObservation on a single random machine shows a factor 12 between\nthe two functions. Given an average of 12 levels in the trie being\nsearched.\n\nThis patch force inlining longest_prefix_match()"", ' but only for\nthe lookup fastpath to balance object instruction size.\n\nIn production with AMD CPUs', "" measuring the function latency of\n'trie_lookup_elem' (bcc/tools/funclatency) we are seeing an improvement\nfunction latency reduction 7-8% with this patch applied (to production\nkernels 6.6 and 6.1). Analyzing perf data"", ' we can explain this rather\nlarge improvement due to reducing the overhead for AMD side-channel\nmitigation SRSO (Speculative Return Stack Overflow).\n\nFixes: fb3bd914b3ec (""x86/srso: Add a Speculative RAS Overflow mitigation"")\nSigned-off-by: Jesper Dangaard Brouer \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/171076828575.2141737.18370644069389889027.stgit@firesoul\n', '']",The commit inlines the longest_prefix_match function for performance improvements in the LPM trie BPF map.,"inline, LPM trie, performance",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,['tc/netfilter like programs'] +c733239f8f530872a1f80d8c45dcafbaff368737,c733239f8f530872a1f80d8c45dcafbaff368737,Christophe Leroy,christophe.leroy@csgroup.eu,1710574541,Martin KaFai Lau,martin.lau@kernel.org,1710796727,bd2fb53ca8a95c663a415f5b8a5479b338cfa7fd,e3362acd796789dc0562eb1a3937007b0beb0c5b,"bpf: Check return from set_memory_rox() + +arch_protect_bpf_trampoline() and alloc_new_pack() call +set_memory_rox() which can fail"," leading to unprotected memory. + +Take into account return from set_memory_rox() function and add +__must_check flag to arch_protect_bpf_trampoline(). + +Signed-off-by: Christophe Leroy +Reviewed-by: Kees Cook +Link: https://lore.kernel.org/r/fe1c163c83767fde5cab31d209a4a6be3ddb3a73.1710574353.git.christophe.leroy@csgroup.eu +Signed-off-by: Martin KaFai Lau +",[''],The commit ensures proper handling of set_memory_rox() return by using __must_check in arch_protect_bpf_trampoline().,"set_memory_rox, arch_protect_bpf_trampoline, __must_check",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +e3362acd796789dc0562eb1a3937007b0beb0c5b,e3362acd796789dc0562eb1a3937007b0beb0c5b,Christophe Leroy,christophe.leroy@csgroup.eu,1710574540,Martin KaFai Lau,martin.lau@kernel.org,1710796727,60fdaf720eaf3b7e5b6367504c99d880b92e953e,7b30c296af6525571fc967f6a8661f6e1127369e,"bpf: Remove arch_unprotect_bpf_trampoline() + +Last user of arch_unprotect_bpf_trampoline() was removed by +commit 187e2af05abe (""bpf: struct_ops supports more than one page for +trampolines."") + +Remove arch_unprotect_bpf_trampoline() + +Reported-by: Daniel Borkmann +Fixes: 187e2af05abe (""bpf: struct_ops supports more than one page for trampolines."") +Signed-off-by: Christophe Leroy +Link: https://lore.kernel.org/r/42c635bb54d3af91db0f9b85d724c7c290069f67.1710574353.git.christophe.leroy@csgroup.eu +Signed-off-by: Martin KaFai Lau +",,The commit removes the unused arch_unprotect_bpf_trampoline function after its last user was removed.,"remove,arch_unprotect_bpf_trampoline,trampolines",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7b30c296af6525571fc967f6a8661f6e1127369e,7b30c296af6525571fc967f6a8661f6e1127369e,Mykyta Yatsenko,yatsenko@meta.com,1710767888,Andrii Nakryiko,andrii@kernel.org,1710794711,ac27064d83f809fbec1e63ec44e67167d2622d5b,7f3edd0c72c3f7214f8f28495f2e6466348eb128,"libbpbpf: Check bpf_map/bpf_program fd validity + +libbpf creates bpf_program/bpf_map structs for each program/map that +user defines"," but it allows to disable creating/loading those objects in +kernel","["" in that case they won't have associated file descriptor\n(fd < 0). Such functionality is used for backward compatibility\nwith some older kernels.\n\nNothing prevents users from passing these maps or programs with no\nkernel counterpart to libbpf APIs. This change introduces explicit\nchecks for kernel objects existence"", ' aiming to improve visibility of\nthose edge cases and provide meaningful warnings to users.\n\nSigned-off-by: Mykyta Yatsenko \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240318131808.95959-1-yatsenko@meta.com\n', '']",This commit adds a check for the validity of bpf_map and bpf_program file descriptors in libbpf.,"libbpf, validity check, bpf_program",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7f3edd0c72c3f7214f8f28495f2e6466348eb128,7f3edd0c72c3f7214f8f28495f2e6466348eb128,Martin KaFai Lau,martin.lau@kernel.org,1710530472,Andrii Nakryiko,andrii@kernel.org,1710791290,a53d58eb46894feba698e54bbb36eb1a5371512f,4c8644f86c854c214aaabbcc24a27fa4c7e6a951,"bpf: Remove unnecessary err < 0 check in bpf_struct_ops_map_update_elem + +There is a ""if (err)"" check earlier"," so the ""if (err < 0)"" +check that this patch removing is unnecessary. It was my overlook +when making adjustments to the bpf_struct_ops_prepare_trampoline() +such that the caller does not have to worry about the new page when +the function returns error. + +Fixes: 187e2af05abe (""bpf: struct_ops supports more than one page for trampolines."") +Signed-off-by: Martin KaFai Lau +Signed-off-by: Andrii Nakryiko +Acked-by: Stanislav Fomichev +Link: https://lore.kernel.org/bpf/20240315192112.2825039-1-martin.lau@linux.dev +",[''],Remove redundant error check in bpf_struct_ops_map_update_elem function.,"error check, redundant, bpf_struct_ops",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +35c3e27917568192927c785fc380f139255468b4,35c3e27917568192927c785fc380f139255468b4,Abhishek Chauhan,quic_abchauha@quicinc.com,1710444244,David S. Miller,davem@davemloft.net,1710764993,cea90dc6e4c3226ed8f9a5c6c11bdf9971cba4f7,f490c492e946d8ffbe65ad4efc66de3c5ede30a4,"Revert ""net: Re-use and set mono_delivery_time bit for userspace tstamp packets"" + +This reverts commit 885c36e59f46375c138de18ff1692f18eff67b7f. + +The patch currently broke the bpf selftest test_tc_dtime because +uapi field __sk_buff->tstamp_type depends on skb->mono_delivery_time which +does not necessarily mean mono with the original fix as the bit was re-used +for userspace timestamp as well to avoid tstamp reset in the forwarding +path. To solve this we need to keep mono_delivery_time as is and +introduce another bit called user_delivery_time and fall back to the +initial proposal of setting the user_delivery_time bit based on +sk_clockid set from userspace. + +Fixes: 885c36e59f46 (""net: Re-use and set mono_delivery_time bit for userspace tstamp packets"") +Link: https://lore.kernel.org/netdev/bc037db4-58bb-4861-ac31-a361a93841d3@linux.dev/ +Signed-off-by: Abhishek Chauhan +Acked-by: Daniel Borkmann +Acked-by: Martin KaFai Lau +Signed-off-by: David S. Miller +",,This commit reverts a patch due to a selftest failure related to reuse of mono_delivery_time bit.,"reverts, mono_delivery_time, selftest",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0740b6427e90ef03177888c50dc1c78ca6e0f7f0,0740b6427e90ef03177888c50dc1c78ca6e0f7f0,Andrii Nakryiko,andrii@kernel.org,1710536945,Andrii Nakryiko,andrii@kernel.org,1710537850,b97a172c0443649cceb63e430623d10f69b1a105,aae08491b9438347e9656c44021824ad236052b4 a90c5845db958701ddc7659bc4f6db6fa647e449,"Merge branch 'bpf-arena-followups' + +Alexei Starovoitov says: + +==================== +bpf: arena followups. + +From: Alexei Starovoitov + +A set of follow ups to clean up bpf_arena and adjust to the latest LLVM. +==================== + +Link: https://lore.kernel.org/r/20240315021834.62988-1-alexei.starovoitov@gmail.com +Signed-off-by: Andrii Nakryiko +",,Clean up bpf_arena and adapt to latest LLVM updates.,"bpf_arena, followups, LLVM",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +a90c5845db958701ddc7659bc4f6db6fa647e449,a90c5845db958701ddc7659bc4f6db6fa647e449,Alexei Starovoitov,ast@kernel.org,1710469114,Andrii Nakryiko,andrii@kernel.org,1710537846,b97a172c0443649cceb63e430623d10f69b1a105,9a2d5a966b47e5657b22dfa257365b7ef2abc3c0,"selftests/bpf: Add arena test case for 4Gbyte corner case + +Check that 4Gbyte arena can be allocated and overflow/underflow access in +the first and the last page behaves as expected. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Stanislav Fomichev +Link: https://lore.kernel.org/bpf/20240315021834.62988-5-alexei.starovoitov@gmail.com +",,Add a selftest for 4Gbyte allocation and access behavior in bpf arena.,"4Gbyte,arena,test",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9a2d5a966b47e5657b22dfa257365b7ef2abc3c0,9a2d5a966b47e5657b22dfa257365b7ef2abc3c0,Alexei Starovoitov,ast@kernel.org,1710469113,Andrii Nakryiko,andrii@kernel.org,1710537843,091be020ed052c2d6ab1a421391e4af201406b89,10ebe835c937a11870690aa44c7c970fe906ff54,"selftests/bpf: Remove hard coded PAGE_SIZE macro. + +Remove hard coded PAGE_SIZE. +Add #include instead (that works on x86-64 and s390) +and fallback to slow getpagesize() for aarch64. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Stanislav Fomichev +Link: https://lore.kernel.org/bpf/20240315021834.62988-4-alexei.starovoitov@gmail.com +",,The commit removes hard coded PAGE_SIZE and introduces new includes for compatibility.,"PAGE_SIZE, compatibility, selftests",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +10ebe835c937a11870690aa44c7c970fe906ff54,10ebe835c937a11870690aa44c7c970fe906ff54,Alexei Starovoitov,ast@kernel.org,1710469112,Andrii Nakryiko,andrii@kernel.org,1710537840,f790b75713a6d9845bf8e2cb9c6d4e489a794264,ee498a38f3177d9ee0213839d3a05b94272aa48c,libbpf, selftests/bpf: Adjust libbpf,"[' bpftool', ' selftests to match LLVM\n\nThe selftests use\nto tell LLVM about special pointers. For LLVM there is nothing ""arena""\nabout them. They are simply pointers in a different address space.\nHence LLVM diff https://github.com/llvm/llvm-project/pull/85161 renamed:\n. macro __BPF_FEATURE_ARENA_CAST -> __BPF_FEATURE_ADDR_SPACE_CAST\n. global variables in __attribute__((address_space(N))) are now\n placed in section named "".addr_space.N"" instead of "".arena.N"".\n\nAdjust libbpf', ' bpftool', ' and selftests to match LLVM.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Stanislav Fomichev \nLink: https://lore.kernel.org/bpf/20240315021834.62988-3-alexei.starovoitov@gmail.com\n', '']",Adjustments made to libbpf in the selftests for bpf.,"libbpf, selftests, bpf",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ee498a38f3177d9ee0213839d3a05b94272aa48c,ee498a38f3177d9ee0213839d3a05b94272aa48c,Alexei Starovoitov,ast@kernel.org,1710469111,Andrii Nakryiko,andrii@kernel.org,1710537825,458a921bce8d3a8e3719f05fbb8d1abe5b7a4462,aae08491b9438347e9656c44021824ad236052b4,"bpf: Clarify bpf_arena comments. + +Clarify two bpf_arena comments", use existing SZ_4G #define,"['\nimprove page_cnt check.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Stanislav Fomichev \nLink: https://lore.kernel.org/bpf/20240315021834.62988-2-alexei.starovoitov@gmail.com\n', '']",This commit clarifies comments in the bpf_arena code section.,"bpf, arena, comments",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +4c8644f86c854c214aaabbcc24a27fa4c7e6a951,4c8644f86c854c214aaabbcc24a27fa4c7e6a951,Colin Ian King,colin.i.king@gmail.com,1710494814,Daniel Borkmann,daniel@iogearbox.net,1710510836,d812af3794ce521c8ae6e8094b01411f7d6f23c8,e60adf513275c3a38e5cb67f7fd12387e43a3ff5,"selftests/bpf: Remove second semicolon + +There are statements with two semicolons. Remove the second one"," it +is redundant. + +Signed-off-by: Colin Ian King +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240315092654.2431062-1-colin.i.king@gmail.com +",[''],Remove redundant second semicolon in selftests for BPF.,"selftests,semicolon,BPF",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5384cc0d1a88c27448a6a4e65b8abe6486de8012,5384cc0d1a88c27448a6a4e65b8abe6486de8012,Hangbin Liu,liuhangbin@gmail.com,1710470083,Daniel Borkmann,daniel@iogearbox.net,1710510391,dfdacc7b2a061c0559f54c538ee6b8ce23e3811f,44d79142ede8162fd67bf8ca4ddbda1fbcfa94f1,"scripts/bpf_doc: Use silent mode when exec make cmd + +When getting kernel version via make"," the result may be polluted by other +output","[' like directory change info. e.g.\n\n $ export MAKEFLAGS=""-w""\n $ make kernelversion\n make: Entering directory \'/home/net\'\n 6.8.0\n make: Leaving directory \'/home/net\'\n\nThis will distort the reStructuredText output and make latter rst2man\nfailed like:\n\n [...]\n bpf-helpers.rst:20: (WARNING/2) Field list ends without a blank line; unexpected unindent.\n [...]\n\nUsing silent mode would help. e.g.\n\n $ make -s --no-print-directory kernelversion\n 6.8.0\n\nFixes: fd0a38f9c37d (""scripts/bpf: Set version attribute for bpf-helpers(7) man page"")\nSigned-off-by: Michael Hofmann \nSigned-off-by: Hangbin Liu \nSigned-off-by: Daniel Borkmann \nReviewed-by: Quentin Monnet \nAcked-by: Alejandro Colomar \nLink: https://lore.kernel.org/bpf/20240315023443.2364442-1-liuhangbin@gmail.com\n', '']",The commit changes the bpf_doc script to use silent mode for make commands to avoid output pollution.,"bpf_doc,silent mode,make",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['other'] +e60adf513275c3a38e5cb67f7fd12387e43a3ff5,e60adf513275c3a38e5cb67f7fd12387e43a3ff5,Christophe Leroy,christophe.leroy@csgroup.eu,1709876288,Alexei Starovoitov,ast@kernel.org,1710469732,f154a2a436cb986c45b30f5090aca12218d43a2c,7d2cc63eca0c993c99d18893214abf8f85d566d8,"bpf: Take return from set_memory_rox() into account with bpf_jit_binary_lock_ro() + +set_memory_rox() can fail"," leaving memory unprotected. + +Check return and bail out when bpf_jit_binary_lock_ro() returns +an error. + +Link: https://github.com/KSPP/linux/issues/7 +Signed-off-by: Christophe Leroy +Cc: linux-hardening@vger.kernel.org +Reviewed-by: Kees Cook +Reviewed-by: Puranjay Mohan +Reviewed-by: Ilya Leoshkevich # s390x +Acked-by: Tiezhu Yang # LoongArch +Reviewed-by: Johan Almbladh # MIPS Part +Message-ID: <036b6393f23a2032ce75a1c92220b2afcb798d5d.1709850515.git.christophe.leroy@csgroup.eu> +Signed-off-by: Alexei Starovoitov +",[''],Fix check return handling in bpf_jit_binary_lock_ro() for set_memory_rox() failures.,"bpf, jit, memory",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7d2cc63eca0c993c99d18893214abf8f85d566d8,7d2cc63eca0c993c99d18893214abf8f85d566d8,Christophe Leroy,christophe.leroy@csgroup.eu,1709876287,Alexei Starovoitov,ast@kernel.org,1710469732,f76363657d57f38f950856a1c399dad1ad31780b,4d8926a0407cff0c864b759b59104f4fb6f8efab,"bpf: Take return from set_memory_ro() into account with bpf_prog_lock_ro() + +set_memory_ro() can fail"," leaving memory unprotected. + +Check its return and take it into account as an error. + +Link: https://github.com/KSPP/linux/issues/7 +Signed-off-by: Christophe Leroy +Cc: linux-hardening@vger.kernel.org +Reviewed-by: Kees Cook +Message-ID: <286def78955e04382b227cb3e4b6ba272a7442e3.1709850515.git.christophe.leroy@csgroup.eu> +Signed-off-by: Alexei Starovoitov +",[''],The commit handles failures from the set_memory_ro() function within bpf_prog_lock_ro().,"bpf, set_memory_ro, error-handling",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4d8926a0407cff0c864b759b59104f4fb6f8efab,4d8926a0407cff0c864b759b59104f4fb6f8efab,Andrii Nakryiko,andrii@kernel.org,1710374487,Alexei Starovoitov,ast@kernel.org,1710469696,de80ba0b517f082bf17cd397cdedfb63b606b1cf,6cda7e17392e0eca9fcafcb9b1d269c31fd737b7,"bpf: preserve sleepable bit in subprog info + +Copy over main program's sleepable bit into subprog's info. This might +be important for", e.g.,"[' freplace cases.\n\nSuggested-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Stanislav Fomichev \nMessage-ID: <20240314000127.3881569-1-andrii@kernel.org>\nSigned-off-by: Alexei Starovoitov \n', '']",Preserve the sleepable bit in subprograms' info for eBPF programs.,"sleepable, subprog, info",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6cda7e17392e0eca9fcafcb9b1d269c31fd737b7,6cda7e17392e0eca9fcafcb9b1d269c31fd737b7,Andrii Nakryiko,andrii@kernel.org,1710449225,Andrii Nakryiko,andrii@kernel.org,1710449683,23b3d167b14c63d771404758606aebfb8aaaa812,9bf48fa19a4b1d186e08b20bf7e5de26a15644fb 26a7cf2bbea656837583f9a1a0f9390db63d6cc3,"Merge branch 'ignore-additional-fields-in-the-struct_ops-maps-in-an-updated-version' + +Kui-Feng Lee says: + +==================== +Ignore additional fields in the struct_ops maps in an updated version. + +According to an offline discussion"," it would be beneficial to +implement a backward-compatible method for struct_ops types with +additional fields that are not present in older kernels. + +This patchset accepts additional fields of a struct_ops map with all +zero values even if these fields are not in the corresponding type in +the kernel. This provides a way to be backward compatible. User space +programs can use the same map on a machine running an old kernel by +clearing fields that do not exist in the kernel. + +For example","[' in a test case', ' it adds an additional field ""zeroed"" that\ndoesn\'t exist in struct bpf_testmod_ops of the kernel.\n\n struct bpf_testmod_ops___zeroed {\n \tint (*test_1)(void);\n \tvoid (*test_2)(int a', ' int b);\n \tint (*test_maybe_null)(int dummy', ' struct task_struct *task);\n \tint zeroed;\n };\n\n SEC("".struct_ops.link"")\n struct bpf_testmod_ops___zeroed testmod_zeroed = {\n \t.test_1 = (void *)test_1', '\n \t.test_2 = (void *)test_2_v2', '\n };\n\nHere', ' it doesn\'t assign a value to ""zeroed"" of testmod_zeroed', ' and by\ndefault the value of this field will be zero. So', ' the map will be\naccepted by libbpf', ' but libbpf will skip the ""zeroed"" field. However', '\nif the ""zeroed"" field is assigned to any value other than ""0""', ' libbpf\nwill reject to load this map.\n---\nChanges from v1:\n\n - Fix the issue about function pointer fields.\n\n - Change a warning message', ' and add an info message for skipping\n fields.\n\n - Add a small demo of additional arguments that are not in the\n function pointer prototype in the kernel.\n\nv1: https://lore.kernel.org/all/20240312183245.341141-1-thinker.li@gmail.com/\n\nKui-Feng Lee (3):\n libbpf: Skip zeroed or null fields if not found in the kernel type.\n selftests/bpf: Ensure libbpf skip all-zeros fields of struct_ops maps.\n selftests/bpf: Accept extra arguments if they are not used.\n\n tools/lib/bpf/libbpf.c | 24 +++-\n .../bpf/prog_tests/test_struct_ops_module.c | 103 ++++++++++++++++++\n .../bpf/progs/struct_ops_extra_arg.c | 49 +++++++++\n .../selftests/bpf/progs/struct_ops_module.c | 16 ++-\n 4 files changed', ' 186 insertions(+)', ' 6 deletions(-)\n create mode 100644 tools/testing/selftests/bpf/progs/struct_ops_extra_arg.c\n====================\n\nLink: https://lore.kernel.org/r/20240313214139.685112-1-thinker.li@gmail.com\nSigned-off-by: Andrii Nakryiko \n', '']",Implemented backward-compatible handling for additional fields in struct_ops maps for older kernels.,"backward-compatible, struct_ops, maps",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +26a7cf2bbea656837583f9a1a0f9390db63d6cc3,26a7cf2bbea656837583f9a1a0f9390db63d6cc3,Kui-Feng Lee,thinker.li@gmail.com,1710366098,Andrii Nakryiko,andrii@kernel.org,1710449225,23b3d167b14c63d771404758606aebfb8aaaa812,c911fc61a7ce367f9ea48e457f31bb171e80ca4d,"selftests/bpf: Ensure libbpf skip all-zeros fields of struct_ops maps. + +A new version of a type may have additional fields that do not exist in +older versions. Previously"," libbpf would reject struct_ops maps with a new +version containing extra fields when running on a machine with an old +kernel. However","[' we have updated libbpf to ignore these fields if their\nvalues are all zeros or null in order to provide backward compatibility.\n\nSigned-off-by: Kui-Feng Lee \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240313214139.685112-3-thinker.li@gmail.com\n', '']",Ensure libbpf skips all-zero fields in struct_ops maps for compatibility with older kernels.,"libbpf, struct_ops, compatibility",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c911fc61a7ce367f9ea48e457f31bb171e80ca4d,c911fc61a7ce367f9ea48e457f31bb171e80ca4d,Kui-Feng Lee,thinker.li@gmail.com,1710366097,Andrii Nakryiko,andrii@kernel.org,1710449225,80958ee01093375725f14731119423303eee93b0,9bf48fa19a4b1d186e08b20bf7e5de26a15644fb,"libbpf: Skip zeroed or null fields if not found in the kernel type. + +Accept additional fields of a struct_ops type with all zero values even if +these fields are not in the corresponding type in the kernel. This provides +a way to be backward compatible. User space programs can use the same map +on a machine running an old kernel by clearing fields that do not exist in +the kernel. + +Signed-off-by: Kui-Feng Lee +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240313214139.685112-2-thinker.li@gmail.com +",,libbpf update to skip zeroed fields for backward compatibility with older kernels.,"libbpf,backward compatibility,zeroed fields",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9bf48fa19a4b1d186e08b20bf7e5de26a15644fb,9bf48fa19a4b1d186e08b20bf7e5de26a15644fb,Quentin Monnet,qmo@kernel.org,1710428678,Andrii Nakryiko,andrii@kernel.org,1710448877,1fcbb6ba740bcc479893149a2ad3f1dc2f83db8d,fe879bb42f8a6513ed18e9d22efb99cb35590201,"libbpf: Prevent null-pointer dereference when prog to load has no BTF + +In bpf_objec_load_prog()"," there's no guarantee that obj->btf is non-NULL +when passing it to btf__fd()","[' and this function does not perform any\ncheck before dereferencing its argument (as bpf_object__btf_fd() used to\ndo). As a consequence', ' we get segmentation fault errors in bpftool (for\nexample) when trying to load programs that come without BTF information.\n\nv2: Keep btf__fd() in the fix instead of reverting to bpf_object__btf_fd().\n\nFixes: df7c3f7d3a3d (""libbpf: make uniform use of btf__fd() accessor inside libbpf"")\nSuggested-by: Andrii Nakryiko \nSigned-off-by: Quentin Monnet \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240314150438.232462-1-qmo@kernel.org\n', '']",Fix a null-pointer dereference in libbpf when the program to load has no BTF.,"null-pointer,libbpf,BTF",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fe879bb42f8a6513ed18e9d22efb99cb35590201,fe879bb42f8a6513ed18e9d22efb99cb35590201,Yonghong Song,yonghong.song@linux.dev,1710210769,Andrii Nakryiko,andrii@kernel.org,1710448663,949cc3dd9c47df524cefd04ba20aeb104b0902e4,c2a0257c1edf16c6acd2afac7572d7e9043b6577,"bpftool: Fix missing pids during link show + +Current 'bpftool link' command does not show pids", e.g.,"['\n $ tools/build/bpftool/bpftool link\n ...\n 4: tracing prog 23\n prog_type lsm attach_type lsm_mac\n target_obj_id 1 target_btf_id 31320\n\nHack the following change to enable normal libbpf debug output', '\n --- a/tools/bpf/bpftool/pids.c\n +++ b/tools/bpf/bpftool/pids.c\n @@ -121', '9 +121', '9 @@ int build_obj_refs_table(struct hashmap **map', "" enum bpf_obj_type type)\n /* we don't want output polluted with libbpf errors if bpf_iter is not\n * supported\n */\n - default_print = libbpf_set_print(libbpf_print_none);\n + /* default_print = libbpf_set_print(libbpf_print_none); */\n err = pid_iter_bpf__load(skel);\n - libbpf_set_print(default_print);\n + /* libbpf_set_print(default_print); */\n\nRerun the above bpftool command:\n $ tools/build/bpftool/bpftool link\n libbpf: prog 'iter': BPF program load failed: Permission denied\n libbpf: prog 'iter': -- BEGIN PROG LOAD LOG --\n 0: R1=ctx() R10=fp0\n ; struct task_struct *task = ctx->task; @ pid_iter.bpf.c:69\n 0: (79) r6 = *(u64 *)(r1 +8) ; R1=ctx() R6_w=ptr_or_null_task_struct(id=1)\n ; struct file *file = ctx->file; @ pid_iter.bpf.c:68\n ...\n ; struct bpf_link *link = (struct bpf_link *) file->private_data; @ pid_iter.bpf.c:103\n 80: (79) r3 = *(u64 *)(r8 +432) ; R3_w=scalar() R8=ptr_file()\n ; if (link->type == bpf_core_enum_value(enum bpf_link_type___local"", "" @ pid_iter.bpf.c:105\n 81: (61) r1 = *(u32 *)(r3 +12)\n R3 invalid mem access 'scalar'\n processed 39 insns (limit 1000000) max_states_per_insn 0 total_states 3 peak_states 3 mark_read 2\n -- END PROG LOAD LOG --\n libbpf: prog 'iter': failed to load: -13\n ...\n\nThe 'file->private_data' returns a 'void' type and this caused subsequent 'link->type'\n(insn #81) failed in verification.\n\nTo fix the issue"", ' restore the previous BPF_CORE_READ so old kernels can also work.\nWith this patch', ' the \'bpftool link\' runs successfully with \'pids\'.\n $ tools/build/bpftool/bpftool link\n ...\n 4: tracing prog 23\n prog_type lsm attach_type lsm_mac\n target_obj_id 1 target_btf_id 31320\n pids systemd(1)\n\nFixes: 44ba7b30e84f (""bpftool: Use a local copy of BPF_LINK_TYPE_PERF_EVENT in pid_iter.bpf.c"")\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nTested-by: Quentin Monnet \nReviewed-by: Quentin Monnet \nLink: https://lore.kernel.org/bpf/20240312023249.3776718-1-yonghong.song@linux.dev\n', '']",Fixes missing process IDs in link information shown by bpftool command.,"bpftool, pids, link",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c2a0257c1edf16c6acd2afac7572d7e9043b6577,c2a0257c1edf16c6acd2afac7572d7e9043b6577,Kui-Feng Lee,thinker.li@gmail.com,1710207446,Andrii Nakryiko,andrii@kernel.org,1710448461,d68b6bd0f77702745446b0b6e15ce5558efb5d7a,9187210eee7d87eea37b45ea93454a88681894a4,"bpftool: Cast pointers for shadow types explicitly. + +According to a report"," skeletons fail to assign shadow pointers when being +compiled with C++ programs. Unlike C doing implicit casting for void +pointers","[' C++ requires an explicit casting.\n\nTo support C++', ' we do explicit casting for each shadow pointer.\n\nAlso add struct_ops_module.skel.h to test_cpp to validate C++\ncompilation as part of BPF selftests.\n\nSigned-off-by: Kui-Feng Lee \nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nAcked-by: Quentin Monnet \nLink: https://lore.kernel.org/bpf/20240312013726.1780720-1-thinker.li@gmail.com\n', '']",The commit explicitly casts pointers for shadow types in bpftool to address compilation issues with C++.,"bpftool, pointers, shadow",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"[""It's not related to any of the above.""]" +44d79142ede8162fd67bf8ca4ddbda1fbcfa94f1,44d79142ede8162fd67bf8ca4ddbda1fbcfa94f1,Puranjay Mohan,puranjay12@gmail.com,1710438571,Alexei Starovoitov,ast@kernel.org,1710443085,ea5ef659bcaa1dc72bb8258baa47b3a9e59fd2db,e30cef001da259e8df354b813015d0e5acc08740,"bpf: Temporarily disable atomic operations in BPF arena + +Currently"," the x86 JIT handling PROBE_MEM32 tagged accesses is not +equipped to handle atomic accesses into PTR_TO_ARENA","[' as no PROBE_MEM32\ntagging is performed and no handling is enabled for them.\n\nThis will lead to unsafety as the offset into arena will dereferenced\ndirectly without turning it into a base + offset access into the arena\nregion.\n\nSince the changes to the x86 JIT will be fairly involved', ' for now', '\ntemporarily disallow use of PTR_TO_ARENA as the destination operand for\natomics until support is added to the JIT backend.\n\nFixes: 2fe99eb0ccf2 (""bpf: Add x86-64 JIT support for PROBE_MEM32 pseudo instructions."")\nReported-by: Kumar Kartikeya Dwivedi \nSigned-off-by: Puranjay Mohan \nAcked-by: Kumar Kartikeya Dwivedi \nMessage-ID: <20240314174931.98702-1-puranjay12@gmail.com>\nSigned-off-by: Alexei Starovoitov \n', '']",The commit temporarily disables atomic operations in the BPF arena due to limitations in x86 JIT handling.,"atomic, JIT, PTR_TO_ARENA",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3e78a6c0d3e02e4cf881dc84c5127e9990f939d6,3e78a6c0d3e02e4cf881dc84c5127e9990f939d6,Linus Torvalds,torvalds@linux-foundation.org,1710435375,Linus Torvalds,torvalds@linux-foundation.org,1710435375,a23819b38950e840438a2bda77485d6361706966,b345ff698ec7ed52d90bd5603ec8fc1802f40110 0db18cd824f781584a880653e65a0cfd38f060ee,"Merge tag 'hid-for-linus-2024031301' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid + +Pull HID updates from Jiri Kosina: + + - support for the following Bluetooth devices from Samsung: Samsung + wireless {Keyboard", GamePad,"[' Action Mouse', ' Book Cover', ' Universal\n Keyboard', ' HOGP Keyboard} (Sandeep C S)\n\n - second version of code for applying proper quirk depending on\n firmware version for lenovo/cptkbd (Mikhail Khvainitski)\n\n - lenovo/cptkbd firmware-dependent quirk (Mikhail Khvainitski)\n\n - assorted fixes and optimizations for amd-sfh (Basavaraj Natikar)\n\n - dead code and dead data structures removal (Jiri Slaby', "" Jiapeng\n Chong)\n\n* tag 'hid-for-linus-2024031301' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid: (25 commits)\n HID: amd_sfh: Set the AMD SFH driver to depend on x86\n HID: input: avoid polling stylus battery on Chromebook Pompom\n HID: amd_sfh: Extend MP2 register access to SFH\n HID: amd_sfh: Improve boot time when SFH is available\n HID: amd_sfh: Avoid disabling the interrupt\n HID: amd_sfh: Update HPD sensor structure elements\n HID: amd_sfh: Increase sensor command timeout\n HID: intel-ish-hid: ipc: Add Arrow Lake PCI device ID\n HID: nintendo: Remove some unused functions\n HID: hid-prodikeys: remove struct pk_device\n HID: hid-prodikeys: remove unused struct pcmidi_snd members\n HID: hid-multitouch: remove unused mt_application::dev_time\n HID: hid-lg3ff: remove unused struct lg3ff_device\n HID: protect hid_device::bpf by CONFIG_HID_BPF\n HID: wacom: remove unused hid_data::pressure\n HID: apple: remove unused members from struct apple_sc_backlight\n HID: wacom: Clean up use of struct->wacom_wac\n HID: samsung: Add Samsung wireless bookcover and universal keyboard support\n HID: samsung: Add Samsung wireless action mouse support\n HID: samsung: Add Samsung wireless gamepad support\n ...\n"", '']",Merge HID subsystem updates for support of Samsung Bluetooth devices.,"Merge,HID,Samsung",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['HID driver like programs'] +9187210eee7d87eea37b45ea93454a88681894a4,9187210eee7d87eea37b45ea93454a88681894a4,Linus Torvalds,torvalds@linux-foundation.org,1710290648,Linus Torvalds,torvalds@linux-foundation.org,1710290648,31b4610e62cdd5e1dfb700014aa619e41145d7d3,1f440397665f4241346e4cc6d93f8b73880815d1 ed1f164038b50c5864aa85389f3ffd456f050cca,"Merge tag 'net-next-6.9' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next + +Pull networking updates from Jakub Kicinski: + ""Core & protocols: + + - Large effort by Eric to lower rtnl_lock pressure and remove locks: + + - Make commonly used parts of rtnetlink (address"," route dumps + etc) lockless","[' protected by RCU instead of rtnl_lock.\n\n - Add a netns exit callback which already holds rtnl_lock', '\n allowing netns exit to take rtnl_lock once in the core instead\n of once for each driver / callback.\n\n - Remove locks / serialization in the socket diag interface.\n\n - Remove 6 calls to synchronize_rcu() while holding rtnl_lock.\n\n - Remove the dev_base_lock', ' depend on RCU where necessary.\n\n - Support busy polling on a per-epoll context basis. Poll length and\n budget parameters can be set independently of system defaults.\n\n - Introduce struct net_hotdata', "" to make sure read-mostly global\n config variables fit in as few cache lines as possible.\n\n - Add optional per-nexthop statistics to ease monitoring / debug of\n ECMP imbalance problems.\n\n - Support TCP_NOTSENT_LOWAT in MPTCP.\n\n - Ensure that IPv6 temporary addresses' preferred lifetimes are long\n enough"", ' compared to other configured lifetimes', ' and at least 2 sec.\n\n - Support forwarding of ICMP Error messages in IPSec', ' per RFC 4301.\n\n - Add support for the independent control state machine for bonding\n per IEEE 802.1AX-2008 5.4.15 in addition to the existing coupled\n control state machine.\n\n - Add ""network ID"" to MCTP socket APIs to support hosts with multiple\n disjoint MCTP networks.\n\n - Re-use the mono_delivery_time skbuff bit for packets which user\n space wants to be sent at a specified time. Maintain the timing\n information while traversing veth links', ' bridge etc.\n\n - Take advantage of MSG_SPLICE_PAGES for RxRPC DATA and ACK packets.\n\n - Simplify many places iterating over netdevs by using an xarray\n instead of a hash table walk (hash table remains in place', ' for use\n on fastpaths).\n\n - Speed up scanning for expired routes by keeping a dedicated list.\n\n - Speed up ""generic"" XDP by trying harder to avoid large allocations.\n\n - Support attaching arbitrary metadata to netconsole messages.\n\n Things we sprinkled into general kernel code:\n\n - Enforce VM_IOREMAP flag and range in ioremap_page_range and\n introduce VM_SPARSE kind and vm_area_[un]map_pages (used by\n bpf_arena).\n\n - Rework selftest harness to enable the use of the full range of ksft\n exit code (pass', ' fail', ' skip', ' xfail', "" xpass).\n\n Netfilter:\n\n - Allow userspace to define a table that is exclusively owned by a\n daemon (via netlink socket aliveness) without auto-removing this\n table when the userspace program exits. Such table gets marked as\n orphaned and a restarting management daemon can re-attach/regain\n ownership.\n\n - Speed up element insertions to nftables' concatenated-ranges set\n type. Compact a few related data structures.\n\n BPF:\n\n - Add BPF token support for delegating a subset of BPF subsystem\n functionality from privileged system-wide daemons such as systemd\n through special mount options for userns-bound BPF fs to a trusted\n & unprivileged application.\n\n - Introduce bpf_arena which is sparse shared memory region between\n BPF program and user space where structures inside the arena can\n have pointers to other areas of the arena"", "" and pointers work\n seamlessly for both user-space programs and BPF programs.\n\n - Introduce may_goto instruction that is a contract between the\n verifier and the program. The verifier allows the program to loop\n assuming it's behaving well"", ' but reserves the right to terminate\n it.\n\n - Extend the BPF verifier to enable static subprog calls in spin lock\n critical sections.\n\n - Support registration of struct_ops types from modules which helps\n projects like fuse-bpf that seeks to implement a new struct_ops\n type.\n\n - Add support for retrieval of cookies for perf/kprobe multi links.\n\n - Support arbitrary TCP SYN cookie generation / validation in the TC\n layer with BPF to allow creating SYN flood handling in BPF\n firewalls.\n\n - Add code generation to inline the bpf_kptr_xchg() helper which\n improves performance when stashing/popping the allocated BPF\n objects.\n\n Wireless:\n\n - Add SPP (signaling and payload protected) AMSDU support.\n\n - Support wider bandwidth OFDMA', ' as required for EHT operation.\n\n Driver API:\n\n - Major overhaul of the Energy Efficient Ethernet internals to\n support new link modes (2.5GE', ' 5GE)', ' share more code between\n drivers (especially those using phylib)', ' and encourage more\n uniform behavior. Convert and clean up drivers.\n\n - Define an API for querying per netdev queue statistics from\n drivers.\n\n - IPSec: account in global stats for fully offloaded sessions.\n\n - Create a concept of Ethernet PHY Packages at the Device Tree level', '\n to allow parameterizing the existing PHY package code.\n\n - Enable Rx hashing (RSS) on GTP protocol fields.\n\n Misc:\n\n - Improvements and refactoring all over networking selftests.\n\n - Create uniform module aliases for TC classifiers', ' actions', ' and\n packet schedulers to simplify creating modprobe policies.\n\n - Address all missing MODULE_DESCRIPTION() warnings in networking.\n\n - Extend the Netlink descriptions in YAML to cover message\n encapsulation or ""Netlink polymorphism""', ' where interpretation of\n nested attributes depends on link type', ' classifier type or some\n other ""class type"".\n\n Drivers:\n\n - Ethernet high-speed NICs:\n - Add a new driver for Marvell\'s Octeon PCI Endpoint NIC VF.\n - Intel (100G', ' ice', "" idpf):\n - support E825-C devices\n - nVidia/Mellanox:\n - support devices with one port and multiple PCIe links\n - Broadcom (bnxt):\n - support n-tuple filters\n - support configuring the RSS key\n - Wangxun (ngbe/txgbe):\n - implement irq_domain for TXGBE's sub-interrupts\n - Pensando/AMD:\n - support XDP\n - optimize queue submission and wakeup handling (+17% bps)\n - optimize struct layout"", ' saving 28% of memory on queues\n\n - Ethernet NICs embedded and virtual:\n - Google cloud vNIC:\n - refactor driver to perform memory allocations for new queue\n config before stopping and freeing the old queue memory\n - Synopsys (stmmac):\n - obey queueMaxSDU and implement counters required by 802.1Qbv\n - Renesas (ravb):\n - support packet checksum offload\n - suspend to RAM and runtime PM support\n\n - Ethernet switches:\n - nVidia/Mellanox:\n - support for nexthop group statistics\n - Microchip:\n - ksz8: implement PHY loopback\n - add support for KSZ8567', ' a 7-port 10/100Mbps switch\n\n - PTP:\n - New driver for RENESAS FemtoClock3 Wireless clock generator.\n - Support OCP PTP cards designed and built by Adva.\n\n - CAN:\n - Support recvmsg() flags for own', ' local and remote traffic on CAN\n BCM sockets.\n - Support for esd GmbH PCIe/402 CAN device family.\n - m_can:\n - Rx/Tx submission coalescing\n - wake on frame Rx\n\n - WiFi:\n - Intel (iwlwifi):\n - enable signaling and payload protected A-MSDUs\n - support wider-bandwidth OFDMA\n - support for new devices\n - bump FW API to 89 for AX devices; 90 for BZ/SC devices\n - MediaTek (mt76):\n - mt7915: newer ADIE version support\n - mt7925: radio temperature sensor support\n - Qualcomm (ath11k):\n - support 6 GHz station power modes: Low Power Indoor (LPI)', '\n Standard Power) SP and Very Low Power (VLP)\n - QCA6390 & WCN6855: support 2 concurrent station interfaces\n - QCA2066 support\n - Qualcomm (ath12k):\n - refactoring in preparation for Multi-Link Operation (MLO)\n support\n - 1024 Block Ack window size support\n - firmware-2.bin support\n - support having multiple identical PCI devices (firmware needs\n to have ATH12K_FW_FEATURE_MULTI_QRTR_ID)\n - QCN9274: support split-PHY devices\n - WCN7850: enable Power Save Mode in station mode\n - WCN7850: P2P support\n - RealTek:\n - rtw88: support for more rtw8811cu and rtw8821cu devices\n - rtw89: support SCAN_RANDOM_SN and SET_SCAN_DWELL\n - rtlwifi: speed up USB firmware initialization\n - rtwl8xxxu:\n - RTL8188F: concurrent interface support\n - Channel Switch Announcement (CSA) support in AP mode\n - Broadcom (brcmfmac):\n - per-vendor feature support\n - per-vendor SAE password setup\n - DMI nvram filename quirk for ACEPC W5 Pro""\n\n* tag \'net-next-6.9\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next: (2255 commits)\n nexthop: Fix splat with CONFIG_DEBUG_PREEMPT=y\n nexthop: Fix out-of-bounds access during attribute validation\n nexthop: Only parse NHA_OP_FLAGS for dump messages that require it\n nexthop: Only parse NHA_OP_FLAGS for get messages that require it\n bpf: move sleepable flag from bpf_prog_aux to bpf_prog\n bpf: hardcode BPF_PROG_PACK_SIZE to 2MB * num_possible_nodes()\n selftests/bpf: Add kprobe multi triggering benchmarks\n ptp: Move from simple ida to xarray\n vxlan: Remove generic .ndo_get_stats64\n vxlan: Do not alloc tstats manually\n devlink: Add comments to use netlink gen tool\n nfp: flower: handle acti_netdevs allocation failure\n net/packet: Add getsockopt support for PACKET_COPY_THRESH\n net/netlink: Add getsockopt support for NETLINK_LISTEN_ALL_NSID\n selftests/bpf: Add bpf_arena_htab test.\n selftests/bpf: Add bpf_arena_list test.\n selftests/bpf: Add unit tests for bpf_arena_alloc/free_pages\n bpf: Add helper macro bpf_addr_space_cast()\n libbpf: Recognize __arena global variables.\n bpftool: Recognize arena map type\n ...\n', '']","Merging networking updates, focusing on reducing rtnl_lock pressure and achieving lockless operations in rtnetlink.","networking,rtnl_lock,rtnetlink",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5f20e6ab1f65aaaaae248e6946d5cb6d039e7de8,5f20e6ab1f65aaaaae248e6946d5cb6d039e7de8,Jakub Kicinski,kuba@kernel.org,1710205564,Jakub Kicinski,kuba@kernel.org,1710205564,826f8a879f1d954b00e4b07a8afe271aed02992e,f095fefacdd35b4ea97dc6d88d054f2749a73d07 66c8473135c62f478301a0e5b3012f203562dfa6,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Alexei Starovoitov says: + +==================== +pull-request: bpf-next 2024-03-11 + +We've added 59 non-merge commits during the last 9 day(s) which contain +a total of 88 files changed", 4181 insertions(+),"[' 590 deletions(-).\n\nThe main changes are:\n\n1) Enforce VM_IOREMAP flag and range in ioremap_page_range and introduce\n VM_SPARSE kind and vm_area_[un]map_pages to be used in bpf_arena', '\n from Alexei.\n\n2) Introduce bpf_arena which is sparse shared memory region between bpf\n program and user space where structures inside the arena can have\n pointers to other areas of the arena', ' and pointers work seamlessly for\n both user-space programs and bpf programs', "" from Alexei and Andrii.\n\n3) Introduce may_goto instruction that is a contract between the verifier\n and the program. The verifier allows the program to loop assuming it's\n behaving well"", ' but reserves the right to terminate it', ' from Alexei.\n\n4) Use IETF format for field definitions in the BPF standard\n document', ' from Dave.\n\n5) Extend struct_ops libbpf APIs to allow specify version suffixes for\n stuct_ops map types', ' share the same BPF program between several map\n definitions', ' and other improvements', ' from Eduard.\n\n6) Enable struct_ops support for more than one page in trampolines', '\n from Kui-Feng.\n\n7) Support kCFI + BPF on riscv64', ' from Puranjay.\n\n8) Use bpf_prog_pack for arm64 bpf trampoline', ' from Puranjay.\n\n9) Fix roundup_pow_of_two undefined behavior on 32-bit archs', ' from Toke.\n====================\n\nLink: https://lore.kernel.org/r/20240312003646.8692-1-alexei.starovoitov@gmail.com\nSigned-off-by: Jakub Kicinski \n', '']",Merged changes from 'bpf-next' branch into the main network development branch.,"merge,bpf-next,network",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +66c8473135c62f478301a0e5b3012f203562dfa6,66c8473135c62f478301a0e5b3012f203562dfa6,Andrii Nakryiko,andrii@kernel.org,1709945259,Alexei Starovoitov,ast@kernel.org,1710200485,38552c4bba5b6de12904aa40539c2d14950c17a8,d6170e4aaf86424c24ce06e355b4573daa891b17,"bpf: move sleepable flag from bpf_prog_aux to bpf_prog + +prog->aux->sleepable is checked very frequently as part of (some) BPF +program run hot paths. So this extra aux indirection seems wasteful and +on busy systems might cause unnecessary memory cache misses. + +Let's move sleepable flag into prog itself to eliminate unnecessary +pointer dereference. + +Signed-off-by: Andrii Nakryiko +Acked-by: Jiri Olsa +Message-ID: <20240309004739.2961431-1-andrii@kernel.org> +Signed-off-by: Alexei Starovoitov +",,Moved sleepable flag from bpf_prog_aux to bpf_prog for performance optimization.,"sleepable,performance,flag",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d6170e4aaf86424c24ce06e355b4573daa891b17,d6170e4aaf86424c24ce06e355b4573daa891b17,Puranjay Mohan,puranjay12@gmail.com,1710160042,Alexei Starovoitov,ast@kernel.org,1710200010,3ea4c2d6d52315f79d58cbd825edbabffb4f2999,379b97bbf02feecae5ce870bc0c67e3d723e30f5,"bpf: hardcode BPF_PROG_PACK_SIZE to 2MB * num_possible_nodes() + +On some architectures like ARM64"," PMD_SIZE can be really large in some +configurations. Like with CONFIG_ARM64_64K_PAGES=y the PMD_SIZE is +512MB. + +Use 2MB * num_possible_nodes() as the size for allocations done through +the prog pack allocator. On most architectures","[' PMD_SIZE will be equal\nto 2MB in case of 4KB pages and will be greater than 2MB for bigger page\nsizes.\n\nFixes: ea2babac63d4 (""bpf: Simplify bpf_prog_pack_[size|mask]"")\nReported-by: ""kernelci.org bot"" \nCloses: https://lore.kernel.org/all/7e216c88-77ee-47b8-becc-a0f780868d3c@sirena.org.uk/\nReported-by: kernel test robot \nCloses: https://lore.kernel.org/oe-kbuild-all/202403092219.dhgcuz2G-lkp@intel.com/\nSuggested-by: Song Liu \nSigned-off-by: Puranjay Mohan \nMessage-ID: <20240311122722.86232-1-puranjay12@gmail.com>\nSigned-off-by: Alexei Starovoitov \n', '']",Hardcode BPF_PROG_PACK_SIZE to 2MB times num_possible_nodes across various architectures.,"BPF, allocation, ARM64",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +379b97bbf02feecae5ce870bc0c67e3d723e30f5,379b97bbf02feecae5ce870bc0c67e3d723e30f5,Jiri Olsa,jolsa@kernel.org,1710191423,Andrii Nakryiko,andrii@kernel.org,1710198408,8f109e164d4cfa7ab1c1f451603de1730830d133,08701e306e480c56b68c1fa35f2c5b27204083e2,"selftests/bpf: Add kprobe multi triggering benchmarks + +Adding kprobe multi triggering benchmarks. It's useful now to bench +new fprobe implementation and might be useful later as well. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240311211023.590321-1-jolsa@kernel.org +",,The commit adds kprobe multi-triggering benchmarks for evaluating the new fprobe implementation.,"kprobe, benchmarks, fprobe",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +08701e306e480c56b68c1fa35f2c5b27204083e2,08701e306e480c56b68c1fa35f2c5b27204083e2,Andrii Nakryiko,andrii@kernel.org,1710196646,Andrii Nakryiko,andrii@kernel.org,1710197023,0adc349c9b30acf84420c5e52584264a0b048f4f,365c2b32792e692bad6e3761ad19ac3f8f52c0fe 8df839ae23b8c581bdac4b6970d029d65a415852,"Merge branch 'bpf-introduce-bpf-arena' + +Alexei Starovoitov says: + +==================== +bpf: Introduce BPF arena. + +From: Alexei Starovoitov + +v2->v3: +- contains bpf bits only"," but cc-ing past audience for continuity +- since prerequisite patches landed","["" this series focus on the main\n functionality of bpf_arena.\n- adopted Andrii's approach to support arena in libbpf.\n- simplified LLVM support. Instead of two instructions it's now only one.\n- switched to cond_break (instead of open coded iters) in selftests\n- implemented several follow-ups that will be sent after this set\n . remember first IP and bpf insn that faulted in arena.\n report to user space via bpftool\n . copy paste and tweak glob_match() aka mini-regex as a selftests/bpf\n- see patch 1 for detailed description of bpf_arena\n\nv1->v2:\n- Improved commit log with reasons for using vmap_pages_range() in arena.\n Thanks to Johannes\n- Added support for __arena global variables in bpf programs\n- Fixed race conditions spotted by Barret\n- Fixed wrap32 issue spotted by Barret\n- Fixed bpf_map_mmap_sz() the way Andrii suggested\n\nThe work on bpf_arena was inspired by Barret's work:\nhttps://github.com/google/ghost-userspace/blob/main/lib/queue.bpf.h\nthat implements queues"", ' lists and AVL trees completely as bpf programs\nusing giant bpf array map and integer indices instead of pointers.\nbpf_arena is a sparse array that allows to use normal C pointers to\nbuild such data structures. Last few patches implement page_frag\nallocator', ' link list and hash table as bpf programs.\n\nv1:\nbpf programs have multiple options to communicate with user space:\n- Various ring buffers (perf', ' ftrace', ' bpf): The data is streamed\n unidirectionally from bpf to user space.\n- Hash map: The bpf program populates elements', "" and user space consumes\n them via bpf syscall.\n- mmap()-ed array map: Libbpf creates an array map that is directly\n accessed by the bpf program and mmap-ed to user space. It's the fastest\n way. Its disadvantage is that memory for the whole array is reserved at\n the start.\n====================\n\nLink: https://lore.kernel.org/r/20240308010812.89848-1-alexei.starovoitov@gmail.com\nSigned-off-by: Andrii Nakryiko \n"", '']",Introduces BPF arena to improve eBPF memory management.,"BPF, arena, memory",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8df839ae23b8c581bdac4b6970d029d65a415852,8df839ae23b8c581bdac4b6970d029d65a415852,Alexei Starovoitov,ast@kernel.org,1709860092,Andrii Nakryiko,andrii@kernel.org,1710197023,0adc349c9b30acf84420c5e52584264a0b048f4f,9f2c156f90a422b4897a8c2831076a96a31413d1,"selftests/bpf: Add bpf_arena_htab test. + +bpf_arena_htab.h - hash table implemented as bpf program + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240308010812.89848-15-alexei.starovoitov@gmail.com +",,Add a test for bpf_arena_htab implemented as a BPF program.,"test,bpf,hastable",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9f2c156f90a422b4897a8c2831076a96a31413d1,9f2c156f90a422b4897a8c2831076a96a31413d1,Alexei Starovoitov,ast@kernel.org,1709860091,Andrii Nakryiko,andrii@kernel.org,1710197023,5d4844a16170e216e023889c56d88b22e87cf67a,80a4129fcf20da3c6941411155a9b3b45caa5b8d,"selftests/bpf: Add bpf_arena_list test. + +bpf_arena_alloc.h - implements page_frag allocator as a bpf program. +bpf_arena_list.h - doubly linked link list as a bpf program. + +Compiled as a bpf program and as native C code. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240308010812.89848-14-alexei.starovoitov@gmail.com +",,Add selftests for bpf_arena_list and page_frag allocator as bpf programs.,"selftests,bpf_arena_list,page_frag",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +80a4129fcf20da3c6941411155a9b3b45caa5b8d,80a4129fcf20da3c6941411155a9b3b45caa5b8d,Alexei Starovoitov,ast@kernel.org,1709860090,Andrii Nakryiko,andrii@kernel.org,1710197023,e044153bc798df2cec3cce5030f788c6c4023e15,204c628730c62de5a0b593008549a9b95aa96b01,"selftests/bpf: Add unit tests for bpf_arena_alloc/free_pages + +Add unit tests for bpf_arena_alloc/free_pages() functionality +and bpf_arena_common.h with a set of common helpers and macros that +is used in this test and the following patches. + +Also modify test_loader that didn't support running bpf_prog_type_syscall +programs. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240308010812.89848-13-alexei.starovoitov@gmail.com +",,Add unit tests for bpf_arena_alloc/free_pages and update test_loader for syscall programs.,"unit tests,bpf_arena_alloc,syscall",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +204c628730c62de5a0b593008549a9b95aa96b01,204c628730c62de5a0b593008549a9b95aa96b01,Alexei Starovoitov,ast@kernel.org,1709860089,Andrii Nakryiko,andrii@kernel.org,1710197022,0b9cd27de01c10719f2b7c49b07660652df3d9d9,2e7ba4f8fd1fa879b37db0b738c23ba2af8292ee,"bpf: Add helper macro bpf_addr_space_cast() + +Introduce helper macro bpf_addr_space_cast() that emits: +rX = rX +instruction with off = BPF_ADDR_SPACE_CAST +and encodes dest and src address_space-s into imm32. + +It's useful with older LLVM that doesn't emit this insn automatically. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/bpf/20240308010812.89848-12-alexei.starovoitov@gmail.com +",,Add helper macro bpf_addr_space_cast for older LLVM compatibility in eBPF.,"helper macro, bpf_addr_space_cast, LLVM",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2e7ba4f8fd1fa879b37db0b738c23ba2af8292ee,2e7ba4f8fd1fa879b37db0b738c23ba2af8292ee,Andrii Nakryiko,andrii@kernel.org,1709860088,Andrii Nakryiko,andrii@kernel.org,1710197015,1bfe5765d6f39dbdf850102d379085140cf65e1f,eed512e8ac64339cfc69da1a6a4b60982cb502ca,"libbpf: Recognize __arena global variables. + +LLVM automatically places __arena variables into "".arena.1"" ELF section. +In order to use such global variables bpf program must include definition +of arena map in "".maps"" section"," like: +struct { + __uint(type","[' BPF_MAP_TYPE_ARENA);\n __uint(map_flags', ' BPF_F_MMAPABLE);\n __uint(max_entries', ' 1000); /* number of pages */\n __ulong(map_extra', ' 2ull << 44); /* start of mmap() region */\n} arena SEC("".maps"");\n\nlibbpf recognizes both uses of arena and creates single `struct bpf_map *`\ninstance in libbpf APIs.\n"".arena.1"" ELF section data is used as initial data image', ' which is exposed\nthrough skeleton and bpf_map__initial_value() to the user', ' if they need to tune\nit before the load phase. During load phase', "" this initial image is copied over\ninto mmap()'ed region corresponding to arena"", ' and discarded.\n\nFew small checks here and there had to be added to make sure this\napproach works with bpf_map__initial_value()', "" mostly due to hard-coded\nassumption that map->mmaped is set up with mmap() syscall and should be\nmunmap()'ed. For arena"", ' .arena.1 can be (much) smaller than maximum\narena size', ' so this smaller data size has to be tracked separately.\nGiven it is enforced that there is only one arena for entire bpf_object\ninstance', ' we just keep it in a separate field. This can be generalized\nif necessary later.\n\nAll global variables from "".arena.1"" section are accessible from user space\nvia skel->arena->name_of_var.\n\nFor bss/data/rodata the skeleton/libbpf perform the following sequence:\n1. addr = mmap(MAP_ANONYMOUS)\n2. user space optionally modifies global vars\n3. map_fd = bpf_create_map()\n4. bpf_update_map_elem(map_fd', ' addr) // to store values into the kernel\n5. mmap(addr', ' MAP_FIXED', ' map_fd)\nafter step 5 user spaces see the values it wrote at step 2 at the same addresses\n\narena doesn\'t support update_map_elem. Hence skeleton/libbpf do:\n1. addr = malloc(sizeof SEC "".arena.1"")\n2. user space optionally modifies global vars\n3. map_fd = bpf_create_map(MAP_TYPE_ARENA)\n4. real_addr = mmap(map->map_extra', ' MAP_SHARED | MAP_FIXED', ' map_fd)\n5. memcpy(real_addr', ' addr) // this will fault-in and allocate pages\n\nAt the end look and feel of global data vs __arena global data is the same from\nbpf prog pov.\n\nAnother complication is:\nstruct {\n __uint(type', ' BPF_MAP_TYPE_ARENA);\n} arena SEC("".maps"");\n\nint __arena foo;\nint bar;\n\n ptr1 = &foo; // relocation against "".arena.1"" section\n ptr2 = &arena; // relocation against "".maps"" section\n ptr3 = &bar; // relocation against "".bss"" section\n\nFo the kernel ptr1 and ptr2 has point to the same arena\'s map_fd\nwhile ptr3 points to a different global array\'s map_fd.\nFor the verifier:\nptr1->type == unknown_scalar\nptr2->type == const_ptr_to_map\nptr3->type == ptr_to_map_value\n\nAfter verification', ' from JIT pov all 3 ptr-s are normal ld_imm64 insns.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Quentin Monnet \nLink: https://lore.kernel.org/bpf/20240308010812.89848-11-alexei.starovoitov@gmail.com\n', '']",This commit updates libbpf to support __arena global variables in bpf programs.,"libbpf,global variables,__arena",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +eed512e8ac64339cfc69da1a6a4b60982cb502ca,eed512e8ac64339cfc69da1a6a4b60982cb502ca,Alexei Starovoitov,ast@kernel.org,1709860087,Andrii Nakryiko,andrii@kernel.org,1710196644,98a2347bd01b204c478c3d9215b0c94822cc6a74,79ff13e99169ddb0e2277e046dbfb112f77dfac5,"bpftool: Recognize arena map type + +Teach bpftool to recognize arena map type. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/bpf/20240308010812.89848-10-alexei.starovoitov@gmail.com +",,The commit adds support for recognizing arena map type in bpftool.,"bpftool, arena, map type",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +79ff13e99169ddb0e2277e046dbfb112f77dfac5,79ff13e99169ddb0e2277e046dbfb112f77dfac5,Alexei Starovoitov,ast@kernel.org,1709860086,Andrii Nakryiko,andrii@kernel.org,1710196644,4ebc8420dd502d99d541e538ec00c80e6e4b2b15,4d2b56081c32cb33364745da434b88eeaa9d8d8d,"libbpf: Add support for bpf_arena. + +mmap() bpf_arena right after creation"," since the kernel needs to +remember the address returned from mmap. This is user_vm_start. +LLVM will generate bpf_arena_cast_user() instructions where +necessary and JIT will add upper 32-bit of user_vm_start +to such pointers. + +Fix up bpf_map_mmap_sz() to compute mmap size as +map->value_size * map->max_entries for arrays and +PAGE_SIZE * map->max_entries for arena. + +Don't set BTF at arena creation time","["" since it doesn't support it.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240308010812.89848-9-alexei.starovoitov@gmail.com\n"", '']","The commit adds support for bpf_arena in libbpf, enhancing mmap handling and pointer management.","libbpf,bpf_arena,mmap",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4d2b56081c32cb33364745da434b88eeaa9d8d8d,4d2b56081c32cb33364745da434b88eeaa9d8d8d,Alexei Starovoitov,ast@kernel.org,1709860085,Andrii Nakryiko,andrii@kernel.org,1710196644,9c134f6f121825010e07adba5b56109c95779606,2edc3de6fb650924a87fffebebc3b7572cbf6e38,"libbpf: Add __arg_arena to bpf_helpers.h + +Add __arg_arena to bpf_helpers.h + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Kumar Kartikeya Dwivedi +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240308010812.89848-8-alexei.starovoitov@gmail.com +",,Add __arg_arena to enhance functionality in bpf_helpers.h for libbpf.,"libbpf,arg_arena,bpf_helpers",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2edc3de6fb650924a87fffebebc3b7572cbf6e38,2edc3de6fb650924a87fffebebc3b7572cbf6e38,Alexei Starovoitov,ast@kernel.org,1709860084,Andrii Nakryiko,andrii@kernel.org,1710196644,507c3f99582f9326e792ab0a5078e424f1902520,6082b6c328b5486da2b356eae94b8b83c98b5565,"bpf: Recognize btf_decl_tag(""arg: Arena"") as PTR_TO_ARENA. + +In global bpf functions recognize btf_decl_tag(""arg:arena"") as PTR_TO_ARENA. + +Note"," when the verifier sees: + +__weak void foo(struct bar *p) + +it recognizes 'p' as PTR_TO_MEM and 'struct bar' has to be a struct with scalars. +Hence the only way to use arena pointers in global functions is to tag them with ""arg:arena"". + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Kumar Kartikeya Dwivedi +Link: https://lore.kernel.org/bpf/20240308010812.89848-7-alexei.starovoitov@gmail.com +",[''],"This commit enables BPF functions to recognize arena pointers tagged with ""arg:arena"" as PTR_TO_ARENA in global functions.","btf_decl_tag,PTR_TO_ARENA,arena",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6082b6c328b5486da2b356eae94b8b83c98b5565,6082b6c328b5486da2b356eae94b8b83c98b5565,Alexei Starovoitov,ast@kernel.org,1709860083,Andrii Nakryiko,andrii@kernel.org,1710196644,c61b1d28d56273bc3b459f87167423a55b989675,142fd4d2dcf58b1720a6af644f31de1a5551f219,"bpf: Recognize addr_space_cast instruction in the verifier. + +rY = addr_space_cast(rX", 0,"[' 1) tells the verifier that rY->type = PTR_TO_ARENA.\nAny further operations on PTR_TO_ARENA register have to be in 32-bit domain.\n\nThe verifier will mark load/store through PTR_TO_ARENA with PROBE_MEM32.\nJIT will generate them as kern_vm_start + 32bit_addr memory accesses.\n\nrY = addr_space_cast(rX', ' 1', ' 0) tells the verifier that rY->type = unknown scalar.\nIf arena->map_flags has BPF_F_NO_USER_CONV set then convert cast_user to mov32 as well.\nOtherwise JIT will convert it to:\n rY = (u32)rX;\n if (rY)\n rY |= arena->user_vm_start & ~(u64)~0U;\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240308010812.89848-6-alexei.starovoitov@gmail.com\n', '']",The commit adds recognition of addr_space_cast instruction to the eBPF verifier.,"addr_space_cast, verifier, bpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +142fd4d2dcf58b1720a6af644f31de1a5551f219,142fd4d2dcf58b1720a6af644f31de1a5551f219,Alexei Starovoitov,ast@kernel.org,1709860082,Andrii Nakryiko,andrii@kernel.org,1710196644,aefa22cd078872844283df5ae8aa9f64e1614fa9,2fe99eb0ccf2bb73df65ebcbbf2f2ff70e63547b,"bpf: Add x86-64 JIT support for bpf_addr_space_cast instruction. + +LLVM generates bpf_addr_space_cast instruction while translating +pointers between native (zero) address space and +__attribute__((address_space(N))). +The addr_space=1 is reserved as bpf_arena address space. + +rY = addr_space_cast(rX", 0,"[' 1) is processed by the verifier and\nconverted to normal 32-bit move: wX = wY\n\nrY = addr_space_cast(rX', ' 1', ' 0) has to be converted by JIT:\n\naux_reg = upper_32_bits of arena->user_vm_start\naux_reg <<= 32\nwX = wY // clear upper 32 bits of dst register\nif (wX) // if not zero add upper bits of user_vm_start\n wX |= aux_reg\n\nJIT can do it more efficiently:\n\nmov dst_reg32', ' src_reg32 // 32-bit move\nshl dst_reg', ' 32\nor dst_reg', ' user_vm_start\nrol dst_reg', ' 32\nxor r11', ' r11\ntest dst_reg32', ' dst_reg32 // check if lower 32-bit are zero\ncmove r11', ' dst_reg\t // if so', ' set dst_reg to zero\n\t\t\t // Intel swapped src/dst register encoding in CMOVcc\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20240308010812.89848-5-alexei.starovoitov@gmail.com\n', '']",Add x86-64 JIT support for bpf_addr_space_cast instruction to enhance pointer address space conversion.,"x86-64 JIT, bpf_addr_space_cast, pointer conversion",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2fe99eb0ccf2bb73df65ebcbbf2f2ff70e63547b,2fe99eb0ccf2bb73df65ebcbbf2f2ff70e63547b,Alexei Starovoitov,ast@kernel.org,1709860081,Andrii Nakryiko,andrii@kernel.org,1710196644,9bc8df3820cfa576dfbff871acff07e3145e1e1d,667a86ad9b71d934c444eec193cf3508016f35c5,"bpf: Add x86-64 JIT support for PROBE_MEM32 pseudo instructions. + +Add support for [LDX | STX | ST]", PROBE_MEM32,"["" [B | H | W | DW] instructions.\nThey are similar to PROBE_MEM instructions with the following differences:\n- PROBE_MEM has to check that the address is in the kernel range with\n src_reg + insn->off >= TASK_SIZE_MAX + PAGE_SIZE check\n- PROBE_MEM doesn't support store\n- PROBE_MEM32 relies on the verifier to clear upper 32-bit in the register\n- PROBE_MEM32 adds 64-bit kern_vm_start address (which is stored in %r12 in the prologue)\n Due to bpf_arena constructions such %r12 + %reg + off16 access is guaranteed\n to be within arena virtual range"", ' so no address check at run-time.\n- PROBE_MEM32 allows STX and ST. If they fault the store is a nop.\n When LDX faults the destination register is zeroed.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/bpf/20240308010812.89848-4-alexei.starovoitov@gmail.com\n', '']",Support added for x86-64 JIT handling of PROBE_MEM32 pseudo instructions in eBPF.,"x86-64, JIT, PROBE_MEM32",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +667a86ad9b71d934c444eec193cf3508016f35c5,667a86ad9b71d934c444eec193cf3508016f35c5,Alexei Starovoitov,ast@kernel.org,1709860080,Andrii Nakryiko,andrii@kernel.org,1710196644,1517fb859cd443cd74b02dbf3d3684cb29a40f40,317460317a02a1af512697e6e964298dedd8a163,"bpf: Disasm support for addr_space_cast instruction. + +LLVM generates rX = addr_space_cast(rY", dst_addr_space,"[' src_addr_space)\ninstruction when pointers in non-zero address space are used by the bpf\nprogram. Recognize this insn in uapi and in bpf disassembler.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/bpf/20240308010812.89848-3-alexei.starovoitov@gmail.com\n', '']",Added disassembly support for addr_space_cast instruction in bpf.,"disassembly, addr_space_cast, instruction",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +317460317a02a1af512697e6e964298dedd8a163,317460317a02a1af512697e6e964298dedd8a163,Alexei Starovoitov,ast@kernel.org,1709860079,Andrii Nakryiko,andrii@kernel.org,1710196643,4c3766d365686326053292a860fde3f8ced2c087,365c2b32792e692bad6e3761ad19ac3f8f52c0fe,"bpf: Introduce bpf_arena. + +Introduce bpf_arena"," which is a sparse shared memory region between the bpf +program and user space. + +Use cases: +1. User space mmap-s bpf_arena and uses it as a traditional mmap-ed + anonymous region","[' like memcached or any key/value storage. The bpf\n program implements an in-kernel accelerator. XDP prog can search for\n a key in bpf_arena and return a value without going to user space.\n2. The bpf program builds arbitrary data structures in bpf_arena (hash\n tables', ' rb-trees', ' sparse arrays)', ' while user space consumes it.\n3. bpf_arena is a ""heap"" of memory from the bpf program\'s point of view.\n The user space may mmap it', ' but bpf program will not convert pointers\n to user base at run-time to improve bpf program speed.\n\nInitially', ' the kernel vm_area and user vma are not populated. User space\ncan fault in pages within the range. While servicing a page fault', '\nbpf_arena logic will insert a new page into the kernel and user vmas. The\nbpf program can allocate pages from that region via\nbpf_arena_alloc_pages(). This kernel function will insert pages into the\nkernel vm_area. The subsequent fault-in from user space will populate that\npage into the user vma. The BPF_F_SEGV_ON_FAULT flag at arena creation time\ncan be used to prevent fault-in from user space. In such a case', ' if a page\nis not allocated by the bpf program and not present in the kernel vm_area', '\nthe user process will segfault. This is useful for use cases 2 and 3 above.\n\nbpf_arena_alloc_pages() is similar to user space mmap(). It allocates pages\neither at a specific address within the arena or allocates a range with the\nmaple tree. bpf_arena_free_pages() is analogous to munmap()', ' which frees\npages and removes the range from the kernel vm_area and from user process\nvmas.\n\nbpf_arena can be used as a bpf program ""heap"" of up to 4GB. The speed of\nbpf program is more important than ease of sharing with user space. This is\nuse case 3. In such a case', ' the BPF_F_NO_USER_CONV flag is recommended.\nIt will tell the verifier to treat the rX = bpf_arena_cast_user(rY)\ninstruction as a 32-bit move wX = wY', ' which will improve bpf prog\nperformance. Otherwise', ' bpf_arena_cast_user is translated by JIT to\nconditionally add the upper 32 bits of user vm_start (if the pointer is not\nNULL) to arena pointers before they are stored into memory. This way', ' user\nspace sees them as valid 64-bit pointers.\n\nDiff https://github.com/llvm/llvm-project/pull/84410 enables LLVM BPF\nbackend generate the bpf_addr_space_cast() instruction to cast pointers\nbetween address_space(1) which is reserved for bpf_arena pointers and\ndefault address space zero. All arena pointers in a bpf program written in\nC language are tagged as __attribute__((address_space(1))). Hence', ' clang\nprovides helpful diagnostics when pointers cross address space. Libbpf and\nthe kernel support only address_space == 1. All other address space\nidentifiers are reserved.\n\nrX = bpf_addr_space_cast(rY', ' /* dst_as */ 1', ' /* src_as */ 0) tells the\nverifier that rX->type = PTR_TO_ARENA. Any further operations on\nPTR_TO_ARENA register have to be in the 32-bit domain. The verifier will\nmark load/store through PTR_TO_ARENA with PROBE_MEM32. JIT will generate\nthem as kern_vm_start + 32bit_addr memory accesses. The behavior is similar\nto copy_from_kernel_nofault() except that no address checks are necessary.\nThe address is guaranteed to be in the 4GB range. If the page is not\npresent', ' the destination register is zeroed on read', ' and the operation is\nignored on write.\n\nrX = bpf_addr_space_cast(rY', ' 0', ' 1) tells the verifier that rX->type =\nunknown scalar. If arena->map_flags has BPF_F_NO_USER_CONV set', ' then the\nverifier converts such cast instructions to mov32. Otherwise', ' JIT will emit\nnative code equivalent to:\nrX = (u32)rY;\nif (rY)\n rX |= clear_lo32_bits(arena->user_vm_start); /* replace hi32 bits in rX */\n\nAfter such conversion', ' the pointer becomes a valid user pointer within\nbpf_arena range. The user process can access data structures created in\nbpf_arena without any additional computations. For example', ' a linked list\nbuilt by a bpf program can be walked natively by user space.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nReviewed-by: Barret Rhoden \nLink: https://lore.kernel.org/bpf/20240308010812.89848-2-alexei.starovoitov@gmail.com\n', '']",Introduce bpf_arena for sparse shared memory usage between eBPF program and user space.,"bpf_arena,sparse,memory",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +365c2b32792e692bad6e3761ad19ac3f8f52c0fe,365c2b32792e692bad6e3761ad19ac3f8f52c0fe,Andrii Nakryiko,andrii@kernel.org,1709945484,Daniel Borkmann,daniel@iogearbox.net,1710172800,6de4e5a10f581e5c26cdf855c6e8602ed6a5fe32,d7bca9199a27b8690ae1c71dc11f825154af7234,"selftests/bpf: Add fexit and kretprobe triggering benchmarks + +We already have kprobe and fentry benchmarks. Let's add kretprobe and +fexit ones for completeness. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/bpf/20240309005124.3004446-1-andrii@kernel.org +",,Added benchmarks for fexit and kretprobe in selftests/bpf.,"fexit,kretprobe,benchmarks",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +d7bca9199a27b8690ae1c71dc11f825154af7234,d7bca9199a27b8690ae1c71dc11f825154af7234,Alexei Starovoitov,ast@kernel.org,1709917974,Daniel Borkmann,daniel@iogearbox.net,1710172690,bab755c8891d6e8c5868a571a3270cc98c00b99f,96b0f5addc7a0d9ed1f4969ca85ed7513cb1ed25,"mm: Introduce vmap_page_range() to map pages in PCI address space + +ioremap_page_range() should be used for ranges within vmalloc range only. +The vmalloc ranges are allocated by get_vm_area(). PCI has ""resource"" +allocator that manages PCI_IOBASE", IO_SPACE_LIMIT address range,"[' hence\nintroduce vmap_page_range() to be used exclusively to map pages\nin PCI address space.\n\nFixes: 3e49a866c9dc (""mm: Enforce VM_IOREMAP flag and range in ioremap_page_range."")\nReported-by: Miguel Ojeda \nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Daniel Borkmann \nReviewed-by: Christoph Hellwig \nTested-by: Miguel Ojeda \nLink: https://lore.kernel.org/bpf/CANiq72ka4rir+RTN2FQoT=Vvprp_Ao-CvoYEkSNqtSY+RZj+AA@mail.gmail.com\n', '']","Introduce vmap_page_range() for mapping pages in PCI address space, distinct from ioremap_page_range().","vmap_page_range, PCI, ioremap",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +08842c43d0165b0ed78907fd8cc92ce17d857913,08842c43d0165b0ed78907fd8cc92ce17d857913,Eric Dumazet,edumazet@google.com,1709848816,David S. Miller,davem@davemloft.net,1710150963,160989a2a4c9aac50ed9694d32d0dea8912ca5a0,e996401e06a5232f61b4906e2eea643fffa88396,"udp: no longer touch sk->sk_refcnt in early demux + +After commits ca065d0cf80f (""udp: no longer use SLAB_DESTROY_BY_RCU"") +and 7ae215d23c12 (""bpf: Don't refcount LISTEN sockets in sk_assign()"") +UDP early demux no longer need to grab a refcount on the UDP socket. + +This save two atomic operations per incoming packet for connected +sockets. + +Signed-off-by: Eric Dumazet +Cc: Martin KaFai Lau +Cc: Joe Stringer +Cc: Alexei Starovoitov +Cc: Willem de Bruijn +Cc: Kuniyuki Iwashima +Acked-by: Paolo Abeni +Signed-off-by: David S. Miller +",,The commit removes the need to modify sk_refcnt in UDP early demux for improved performance.,"UDP, refcount, demux",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['socket like programs'] +96d9cbe2f2ff7abde021bac75eafaceabe9a51fa,96d9cbe2f2ff7abde021bac75eafaceabe9a51fa,Manjunath Patil,manjunath.b.patil@oracle.com,1709966003,Leon Romanovsky,leon@kernel.org,1710069474,06f5ce1c681da5d07cdbd2f0e22dbdb8b5c4067d,2d5c00815778ec4f4e0a84e405e3e157b7815db1,"RDMA/cm: add timeout to cm_destroy_id wait + +Add timeout to cm_destroy_id"," so that userspace can trigger any data +collection that would help in analyzing the cause of delay in destroying +the cm_id. + +New noinline function helps dtrace/ebpf programs to hook on to it. +Existing functionality isn't changed except triggering a probe-able new +function at every timeout interval. + +We have seen cases where CM messages stuck with MAD layer (either due to +software bug or faulty HCA)","[' leading to cm_id getting stuck in the\nfollowing call stack. This patch helps in resolving such issues faster.\n\nkernel: ... INFO: task XXXX:56778 blocked for more than 120 seconds.\n...\n\tCall Trace:\n\t__schedule+0x2bc/0x895\n\tschedule+0x36/0x7c\n\tschedule_timeout+0x1f6/0x31f\n \t? __slab_free+0x19c/0x2ba\n\twait_for_completion+0x12b/0x18a\n\t? wake_up_q+0x80/0x73\n\tcm_destroy_id+0x345/0x610 [ib_cm]\n\tib_destroy_cm_id+0x10/0x20 [ib_cm]\n\trdma_destroy_id+0xa8/0x300 [rdma_cm]\n\tucma_destroy_id+0x13e/0x190 [rdma_ucm]\n\tucma_write+0xe0/0x160 [rdma_ucm]\n\t__vfs_write+0x3a/0x16d\n\tvfs_write+0xb2/0x1a1\n\t? syscall_trace_enter+0x1ce/0x2b8\n\tSyS_write+0x5c/0xd3\n\tdo_syscall_64+0x79/0x1b9\n\tentry_SYSCALL_64_after_hwframe+0x16d/0x0\n\nSigned-off-by: Manjunath Patil \nLink: https://lore.kernel.org/r/20240309063323.458102-1-manjunath.b.patil@oracle.com\nSigned-off-by: Leon Romanovsky \n', '']",The commit adds a timeout to the cm_destroy_id wait for improved data collection during delays.,"timeout,cm_destroy_id,dtrace",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +96b0f5addc7a0d9ed1f4969ca85ed7513cb1ed25,96b0f5addc7a0d9ed1f4969ca85ed7513cb1ed25,Puranjay Mohan,puranjay12@gmail.com,1709584083,Alexei Starovoitov,ast@kernel.org,1710002395,0f7bb0775e388cb9a2ae69a818d5c938c0ca2d33,a27e89673abf1623c298ea84eaa03f4c57aeca1b,arm64," bpf: Use bpf_prog_pack for arm64 bpf trampoline + +We used bpf_prog_pack to aggregate bpf programs into huge page to +relieve the iTLB pressure on the system. This was merged for ARM64[1] +We can apply it to bpf trampoline as well. This would increase the +preformance of fentry and struct_ops programs. + +[1] https://lore.kernel.org/bpf/20240228141824.119877-1-puranjay12@gmail.com/ + +Signed-off-by: Puranjay Mohan +Reviewed-by: Pu Lehui +Message-ID: <20240304202803.31400-1-puranjay12@gmail.com> +Signed-off-by: Alexei Starovoitov +",[''],"The commit uses bpf_prog_pack to optimize bpf trampoline performance on ARM64, reducing iTLB pressure and enhancing fentry and struct_ops programs.","bpf_prog_pack,ARM64,iTLB",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'kprobe/uprobe/ftrace like programs']" +caabd859c41b50a571cfdf7747de9f245c5d531b,caabd859c41b50a571cfdf7747de9f245c5d531b,fuyuanli,fuyuanli@didiglobal.com,1709607857,David S. Miller,davem@davemloft.net,1709893547,29348feae2058257acf7bafa281bb5b6a3741fec,6025b9135f7a8b46826a5fcf947259da43bac281,"tcp: Add skb addr and sock addr to arguments of tracepoint tcp_probe. + +It is useful to expose skb addr and sock addr to user in tracepoint +tcp_probe"," so that we can get more information while monitoring +receiving of tcp data","[' by ebpf or other ways.\n\nFor example', ' we need to identify a packet by seq and end_seq when\ncalculate transmit latency between layer 2 and layer 4 by ebpf', ' but which is\nnot available in tcp_probe', ' so we can only use kprobe hooking\ntcp_rcv_established to get them. But we can use tcp_probe directly if skb\naddr and sock addr are available', ' which is more efficient.\n\nSigned-off-by: fuyuanli \nReviewed-by: Jason Xing \nSigned-off-by: David S. Miller \n', '']",The commit adds skb and sock addresses as arguments to the tcp_probe tracepoint for enhanced monitoring of TCP data reception.,"tcp_probe, skb addr, sock addr",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +a27e89673abf1623c298ea84eaa03f4c57aeca1b,a27e89673abf1623c298ea84eaa03f4c57aeca1b,Alexei Starovoitov,ast@kernel.org,1709870559,Alexei Starovoitov,ast@kernel.org,1709870792,055be779382b86723c540e8c180876dd163b4826,c7d4274e90a1e7aa43d11d2a16066cbbe610070e 7a4b21250bf79eef26543d35bd390448646c536b,"Merge branch 'fix-hash-bucket-overflow-checks-for-32-bit-arches' + +Toke Høiland-Jørgensen says: + +==================== +Fix hash bucket overflow checks for 32-bit arches + +Syzbot managed to trigger a crash by creating a DEVMAP_HASH map with a +large number of buckets because the overflow check relies on +well-defined behaviour that is only correct on 64-bit arches. + +Fix the overflow checks to happen before values are rounded up in all +the affected map types. + +v3: +- Keep the htab->n_buckets > U32_MAX / sizeof(struct bucket) check +- Use 1UL << 31 instead of U32_MAX / 2 + 1 as the constant to check + against +- Add patch to fix stackmap.c +v2: +- Fix off-by-one error in overflow check +- Apply the same fix to hashtab"," where the devmap_hash code was copied + from (John) + +Toke Høiland-Jørgensen (3): + bpf: Fix DEVMAP_HASH overflow check on 32-bit arches + bpf: Fix hashtab overflow check on 32-bit arches + bpf: Fix stackmap overflow check on 32-bit arches + + kernel/bpf/devmap.c | 11 ++++++----- + kernel/bpf/hashtab.c | 14 +++++++++----- + kernel/bpf/stackmap.c | 9 ++++++--- + 3 files changed","[' 21 insertions(+)', ' 13 deletions(-)\n====================\n\nLink: https://lore.kernel.org/r/20240307120340.99577-1-toke@redhat.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix overflow checks in hash buckets for 32-bit architectures in eBPF.,"overflow, 32-bit, hash",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7a4b21250bf79eef26543d35bd390448646c536b,7a4b21250bf79eef26543d35bd390448646c536b,Toke Høiland-Jørgensen,toke@redhat.com,1709813017,Alexei Starovoitov,ast@kernel.org,1709870785,055be779382b86723c540e8c180876dd163b4826,6787d916c2cf9850c97a0a3f73e08c43e7d973b1,"bpf: Fix stackmap overflow check on 32-bit arches + +The stackmap code relies on roundup_pow_of_two() to compute the number +of hash buckets"," and contains an overflow check by checking if the +resulting value is 0. However","[' on 32-bit arches', ' the roundup code itself\ncan overflow by doing a 32-bit left-shift of an unsigned long value', '\nwhich is undefined behaviour', ' so it is not guaranteed to truncate\nneatly. This was triggered by syzbot on the DEVMAP_HASH type', ' which\ncontains the same check', ' copied from the hashtab code.\n\nThe commit in the fixes tag actually attempted to fix this', ' but the fix\ndid not account for the UB', ' so the fix only works on CPUs where an\noverflow does result in a neat truncation to zero', ' which is not\nguaranteed. Checking the value before rounding does not have this\nproblem.\n\nFixes: 6183f4d3a0a2 (""bpf: Check for integer overflow when using roundup_pow_of_two()"")\nSigned-off-by: Toke Høiland-Jørgensen \nReviewed-by: Bui Quang Minh \nMessage-ID: <20240307120340.99577-4-toke@redhat.com>\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes stackmap overflow check issue on 32-bit architectures in BPF.,"stackmap, overflow, 32-bit",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6787d916c2cf9850c97a0a3f73e08c43e7d973b1,6787d916c2cf9850c97a0a3f73e08c43e7d973b1,Toke Høiland-Jørgensen,toke@redhat.com,1709813016,Alexei Starovoitov,ast@kernel.org,1709870756,4507c251124f0b366db3aeaa34baa51fac562d67,281d464a34f540de166cee74b723e97ac2515ec3,"bpf: Fix hashtab overflow check on 32-bit arches + +The hashtab code relies on roundup_pow_of_two() to compute the number of +hash buckets"," and contains an overflow check by checking if the +resulting value is 0. However","[' on 32-bit arches', ' the roundup code itself\ncan overflow by doing a 32-bit left-shift of an unsigned long value', '\nwhich is undefined behaviour', ' so it is not guaranteed to truncate\nneatly. This was triggered by syzbot on the DEVMAP_HASH type', ' which\ncontains the same check', ' copied from the hashtab code. So apply the same\nfix to hashtab', ' by moving the overflow check to before the roundup.\n\nFixes: daaf427c6ab3 (""bpf: fix arraymap NULL deref and missing overflow and zero size checks"")\nSigned-off-by: Toke Høiland-Jørgensen \nMessage-ID: <20240307120340.99577-3-toke@redhat.com>\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes overflow issue in hashtab code for 32-bit architectures.,"hashtab,overflow,32-bit",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +281d464a34f540de166cee74b723e97ac2515ec3,281d464a34f540de166cee74b723e97ac2515ec3,Toke Høiland-Jørgensen,toke@redhat.com,1709813015,Alexei Starovoitov,ast@kernel.org,1709870558,507887987fc4b8cd45838464e2ceda8cfd5951d6,c7d4274e90a1e7aa43d11d2a16066cbbe610070e,"bpf: Fix DEVMAP_HASH overflow check on 32-bit arches + +The devmap code allocates a number hash buckets equal to the next power +of two of the max_entries value provided when creating the map. When +rounding up to the next power of two"," the 32-bit variable storing the +number of buckets can overflow","[' and the code checks for overflow by\nchecking if the truncated 32-bit value is equal to 0. However', ' on 32-bit\narches the rounding up itself can overflow mid-way through', ' because it\nends up doing a left-shift of 32 bits on an unsigned long value. If the\nsize of an unsigned long is four bytes', ' this is undefined behaviour', ' so\nthere is no guarantee that we\'ll end up with a nice and tidy 0-value at\nthe end.\n\nSyzbot managed to turn this into a crash on arm32 by creating a\nDEVMAP_HASH with max_entries > 0x80000000 and then trying to update it.\nFix this by moving the overflow check to before the rounding up\noperation.\n\nFixes: 6f9d451ab1a3 (""xdp: Add devmap_hash map type for looking up devices by hashed index"")\nLink: https://lore.kernel.org/r/000000000000ed666a0611af6818@google.com\nReported-and-tested-by: syzbot+8cd36f6b65f3cafd400a@syzkaller.appspotmail.com\nSigned-off-by: Toke Høiland-Jørgensen \nMessage-ID: <20240307120340.99577-2-toke@redhat.com>\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes DEVMAP_HASH overflow issue on 32-bit architectures in the eBPF subsystem.,"DEVMAP_HASH, overflow, 32-bit",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c7d4274e90a1e7aa43d11d2a16066cbbe610070e,c7d4274e90a1e7aa43d11d2a16066cbbe610070e,Martin KaFai Lau,martin.lau@kernel.org,1709852329,Martin KaFai Lau,martin.lau@kernel.org,1709852517,afd0ca6870d3abf41b811e706c3f788057183e9b,e63985ecd22681c7f5975f2e8637187a326b6791 fe5064158c561b807af5708c868f6c7cb5144e01,"Merge branch 'bpf: arena prerequisites' + +Alexei Starovoitov says: + +==================== +These are bpf_arena prerequisite patches. +Useful on its own. + +Alexei Starovoitov (5): + bpf: Allow kfuncs return 'void *' + bpf: Recognize '__map' suffix in kfunc arguments + bpf: Plumb get_unmapped_area() callback into bpf_map_ops + libbpf: Allow specifying 64-bit integers in map BTF. + bpf: Tell bpf programs kernel's PAGE_SIZE +==================== + +Signed-off-by: Martin KaFai Lau +",,This commit merges prerequisites for bpf_arena to enhance BPF functionalities including kfunc improvements and map operations.,"bpf_arena, kfuncs, map_ops",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fe5064158c561b807af5708c868f6c7cb5144e01,fe5064158c561b807af5708c868f6c7cb5144e01,Alexei Starovoitov,ast@kernel.org,1709781148,Martin KaFai Lau,martin.lau@kernel.org,1709852328,afd0ca6870d3abf41b811e706c3f788057183e9b,1576b07961971d4eeb0e269c7133e9a6d430daf8,"bpf: Tell bpf programs kernel's PAGE_SIZE + +vmlinux BTF includes all kernel enums. +Add __PAGE_SIZE = PAGE_SIZE enum"," so that bpf programs +that include vmlinux.h can easily access it. + +Acked-by: Kumar Kartikeya Dwivedi +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/r/20240307031228.42896-7-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],The commit introduces a kernel enum for PAGE_SIZE to make it accessible to bpf programs using vmlinux.h.,"PAGE_SIZE, bpf, vmlinux",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1576b07961971d4eeb0e269c7133e9a6d430daf8,1576b07961971d4eeb0e269c7133e9a6d430daf8,Andrii Nakryiko,andrii@kernel.org,1709781147,Martin KaFai Lau,martin.lau@kernel.org,1709852328,17697edda374b0ce33105ea003e5201d602890a7,d147357e2e5977c5fe9218457a1e359fd1d36609,"bpftool: rename is_internal_mmapable_map into is_mmapable_map + +It's not restricted to working with ""internal"" maps"," it cares about any +map that can be mmap'ed. Reflect that in more succinct and generic name. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/r/20240307031228.42896-6-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],"Renamed function to reflect usage with any mmap'able map, not just internal ones.","rename, mmapable, bpftool",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d147357e2e5977c5fe9218457a1e359fd1d36609,d147357e2e5977c5fe9218457a1e359fd1d36609,Alexei Starovoitov,ast@kernel.org,1709781146,Martin KaFai Lau,martin.lau@kernel.org,1709852328,3460c738a1dd66aeab815a4e10efee871376909a,cf2c2e4a3d910270903d50462aaa75140cdb2c96,"libbpf: Allow specifying 64-bit integers in map BTF. + +__uint() macro that is used to specify map attributes like: + __uint(type"," BPF_MAP_TYPE_ARRAY); + __uint(map_flags","[' BPF_F_MMAPABLE);\nIt is limited to 32-bit', ' since BTF_KIND_ARRAY has u32 ""number of elements""\nfield in ""struct btf_array"".\n\nIntroduce __ulong() macro that allows specifying values bigger than 32-bit.\nIn map definition ""map_extra"" is the only u64 field', ' so far.\n\nSigned-off-by: Alexei Starovoitov \nLink: https://lore.kernel.org/r/20240307031228.42896-5-alexei.starovoitov@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",This commit enables specifying 64-bit integers in map BTF using libbpf.,"libbpf, 64-bit integers, map BTF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cf2c2e4a3d910270903d50462aaa75140cdb2c96,cf2c2e4a3d910270903d50462aaa75140cdb2c96,Alexei Starovoitov,ast@kernel.org,1709781145,Martin KaFai Lau,martin.lau@kernel.org,1709852328,af6f493a310ee8317f38abc0ec963a5fc33637af,8d94f1357c00d7706c1f3d0bb568e054cef6aea1,"bpf: Plumb get_unmapped_area() callback into bpf_map_ops + +Subsequent patches introduce bpf_arena that imposes special alignment +requirements on address selection. + +Acked-by: Kumar Kartikeya Dwivedi +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/r/20240307031228.42896-4-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau +",,Plumbs get_unmapped_area() callback into bpf_map_ops to support special alignment requirements.,"get_unmapped_area, bpf_map_ops, alignment",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8d94f1357c00d7706c1f3d0bb568e054cef6aea1,8d94f1357c00d7706c1f3d0bb568e054cef6aea1,Alexei Starovoitov,ast@kernel.org,1709781144,Martin KaFai Lau,martin.lau@kernel.org,1709852328,862e04056270e16af686d28debe629be4daeba1b,88d1d4a7eebea2836859246d91fe9d141789dfc3,"bpf: Recognize '__map' suffix in kfunc arguments + +Recognize 'void *p__map' kfunc argument as 'struct bpf_map *p__map'. +It allows kfunc to have 'void *' argument for maps"," since bpf progs +will call them as: +struct { + __uint(type","[' BPF_MAP_TYPE_ARENA);\n\t...\n} arena SEC("".maps"");\n\nbpf_kfunc_with_map(... &arena ...);\n\nUnderneath libbpf will load CONST_PTR_TO_MAP into the register via ld_imm64\ninsn. If kfunc was defined with \'struct bpf_map *\' it would pass the\nverifier as well', ' but bpf prog would need to type cast the argument\n(void *)&arena', ' which is not clean.\n\nAcked-by: Kumar Kartikeya Dwivedi \nSigned-off-by: Alexei Starovoitov \nLink: https://lore.kernel.org/r/20240307031228.42896-3-alexei.starovoitov@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",The commit allows kfunc arguments with a '__map' suffix to be recognized as 'struct bpf_map'.,"kfunc, argument, map",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +88d1d4a7eebea2836859246d91fe9d141789dfc3,88d1d4a7eebea2836859246d91fe9d141789dfc3,Alexei Starovoitov,ast@kernel.org,1709781143,Martin KaFai Lau,martin.lau@kernel.org,1709852328,265870b328e4ba8fd92373cca74fb1f12b849c84,e63985ecd22681c7f5975f2e8637187a326b6791,"bpf: Allow kfuncs return 'void *' + +Recognize return of 'void *' from kfunc as returning unknown scalar. + +Acked-by: Andrii Nakryiko +Acked-by: Kumar Kartikeya Dwivedi +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/r/20240307031228.42896-2-alexei.starovoitov@gmail.com +Signed-off-by: Martin KaFai Lau +",,"The commit allows kfuncs to return 'void *', treating it as unknown scalar.","kfuncs, void, scalar",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +df4793505abd5df399bc6d9a4d8fe81761f557cd,df4793505abd5df399bc6d9a4d8fe81761f557cd,Linus Torvalds,torvalds@linux-foundation.org,1709832213,Linus Torvalds,torvalds@linux-foundation.org,1709832213,71bcf8836d374b96b163ae50d7dbd7976189acc1,67be068d31d423b857ffd8c34dbcc093f8dfff76 ba18deddd6d502da71fd6b6143c53042271b82bd,"Merge tag 'net-6.8-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + ""Including fixes from bpf"," ipsec and netfilter. + + No solution yet for the stmmac issue mentioned in the last PR","[' but it\n proved to be a lockdep false positive', ' not a blocker.\n\n Current release - regressions:\n\n - dpll: move all dpll<>netdev helpers to dpll code', ' fix build\n regression with old compilers\n\n Current release - new code bugs:\n\n - page_pool: fix netlink dump stop/resume\n\n Previous releases - regressions:\n\n - bpf: fix verifier to check bpf_func_state->callback_depth when\n pruning states as otherwise unsafe programs could get accepted\n\n - ipv6: avoid possible UAF in ip6_route_mpath_notify()\n\n - ice: reconfig host after changing MSI-X on VF\n\n - mlx5:\n - e-switch', ' change flow rule destination checking\n - add a memory barrier to prevent a possible null-ptr-deref\n - switch to using _bh variant of of spinlock where needed\n\n Previous releases - always broken:\n\n - netfilter: nf_conntrack_h323: add protection for bmp length out of\n range\n\n - bpf: fix to zero-initialise xdp_rxq_info struct before running XDP\n program in CPU map which led to random xdp_md fields\n\n - xfrm: fix UDP encapsulation in TX packet offload\n\n - netrom: fix data-races around sysctls\n\n - ice:\n - fix potential NULL pointer dereference in ice_bridge_setlink()\n - fix uninitialized dplls mutex usage\n\n - igc: avoid returning frame twice in XDP_REDIRECT\n\n - i40e: disable NAPI right after disabling irqs when handling\n xsk_pool\n\n - geneve: make sure to pull inner header in geneve_rx()\n\n - sparx5: fix use after free inside sparx5_del_mact_entry\n\n - dsa: microchip: fix register write order in ksz8_ind_write8()\n\n Misc:\n\n - selftests: mptcp: fixes for diag.sh""\n\n* tag \'net-6.8-rc8\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (63 commits)\n net: pds_core: Fix possible double free in error handling path\n netrom: Fix data-races around sysctl_net_busy_read\n netrom: Fix a data-race around sysctl_netrom_link_fails_count\n netrom: Fix a data-race around sysctl_netrom_routing_control\n netrom: Fix a data-race around sysctl_netrom_transport_no_activity_timeout\n netrom: Fix a data-race around sysctl_netrom_transport_requested_window_size\n netrom: Fix a data-race around sysctl_netrom_transport_busy_delay\n netrom: Fix a data-race around sysctl_netrom_transport_acknowledge_delay\n netrom: Fix a data-race around sysctl_netrom_transport_maximum_tries\n netrom: Fix a data-race around sysctl_netrom_transport_timeout\n netrom: Fix data-races around sysctl_netrom_network_ttl_initialiser\n netrom: Fix a data-race around sysctl_netrom_obsolescence_count_initialiser\n netrom: Fix a data-race around sysctl_netrom_default_path_quality\n netfilter: nf_conntrack_h323: Add protection for bmp length out of range\n netfilter: nf_tables: mark set as dead when unbinding anonymous set with timeout\n netfilter: nft_ct: fix l3num expectations with inet pseudo family\n netfilter: nf_tables: reject constant set with timeout\n netfilter: nf_tables: disallow anonymous set with timeout flag\n net/rds: fix WARNING in rds_conn_connect_if_down\n net: dsa: microchip: fix register write order in ksz8_ind_write8()\n ...\n', '']",Merge networking fixes including bpf from net-6.8-rc8 by Paolo Abeni.,"networking,bpf,fixes",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['tracepoints like programs', ""It's not related to any of the above."", 'other']" +d3eee81fd6111eb404318ddbaded3f86c7f21d70,d3eee81fd6111eb404318ddbaded3f86c7f21d70,Jakub Kicinski,kuba@kernel.org,1709785261,Jakub Kicinski,kuba@kernel.org,1709785261,d4af1ea22ca7522e93c41a18e9b30ce5cd4c2c4e,c055fc00c07be1f0df7375ab0036cebd1106ed38 2487007aa3b9fafbd2cb14068f49791ce1d7ede5,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-03-06 + +We've added 5 non-merge commits during the last 1 day(s) which contain +a total of 5 files changed", 77 insertions(+),"[' 4 deletions(-).\n\nThe main changes are:\n\n1) Fix BPF verifier to check bpf_func_state->callback_depth when pruning\n states as otherwise unsafe programs could get accepted', '\n from Eduard Zingerman.\n\n2) Fix to zero-initialise xdp_rxq_info struct before running XDP program in\n CPU map which led to random xdp_md fields', ' from Toke Høiland-Jørgensen.\n\n3) Fix bonding XDP feature flags calculation when bonding device has no\n slave devices anymore', "" from Daniel Borkmann.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n cpumap: Zero-initialise xdp_rxq_info struct before running XDP program\n selftests/bpf: Fix up xdp bonding test wrt feature flags\n xdp"", ' bonding: Fix feature flags when there are no slave devs anymore\n selftests/bpf: test case for callback_depth states pruning logic\n bpf: check bpf_func_state->callback_depth when pruning states\n====================\n\nLink: https://lore.kernel.org/r/20240306220309.13534-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']","Merge tag 'for-netdev' with 5 non-merge commits affecting 5 files, totaling 77 insertions.","merge,netdev,commits",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e63985ecd22681c7f5975f2e8637187a326b6791,e63985ecd22681c7f5975f2e8637187a326b6791,Puranjay Mohan,puranjay12@gmail.com,1709485327,Andrii Nakryiko,andrii@kernel.org,1709767096,acb127a58be4cbad6faf591ede9e9aa00573d4bf,516fca5a7516cde7a9968f84179ed20ffb438885,bpf," riscv64/cfi: Support kCFI + BPF on riscv64 + +The riscv BPF JIT doesn't emit proper kCFI prologues for BPF programs +and struct_ops trampolines when CONFIG_CFI_CLANG is enabled. + +This causes CFI failures when calling BPF programs and can even crash +the kernel due to invalid memory accesses. + +Example crash: + +root@rv-selftester:~/bpf# ./test_progs -a dummy_st_ops + + Unable to handle kernel paging request at virtual address ffffffff78204ffc + Oops [#1] + Modules linked in: bpf_testmod(OE) [....] + CPU: 3 PID: 356 Comm: test_progs Tainted: P OE 6.8.0-rc1 #1 + Hardware name: riscv-virtio","['qemu (DT)\n epc : bpf_struct_ops_test_run+0x28c/0x5fc\n ra : bpf_struct_ops_test_run+0x26c/0x5fc\n epc : ffffffff82958010 ra : ffffffff82957ff0 sp : ff200000007abc80\n gp : ffffffff868d6218 tp : ff6000008d87b840 t0 : 000000000000000f\n t1 : 0000000000000000 t2 : 000000002005793e s0 : ff200000007abcf0\n s1 : ff6000008a90fee0 a0 : 0000000000000000 a1 : 0000000000000000\n a2 : 0000000000000000 a3 : 0000000000000000 a4 : 0000000000000000\n a5 : ffffffff868dba26 a6 : 0000000000000001 a7 : 0000000052464e43\n s2 : 00007ffffc0a95f0 s3 : ff6000008a90fe80 s4 : ff60000084c24c00\n s5 : ffffffff78205000 s6 : ff60000088750648 s7 : ff20000000035008\n s8 : fffffffffffffff4 s9 : ffffffff86200610 s10: 0000000000000000\n s11: 0000000000000000 t3 : ffffffff8483dc30 t4 : ffffffff8483dc10\n t5 : ffffffff8483dbf0 t6 : ffffffff8483dbd0\n status: 0000000200000120 badaddr: ffffffff78204ffc cause: 000000000000000d\n [] bpf_struct_ops_test_run+0x28c/0x5fc\n [] bpf_prog_test_run+0x170/0x548\n [] __sys_bpf+0x2d2/0x378\n [] __riscv_sys_bpf+0x5c/0x120\n [] syscall_handler+0x62/0xe4\n [] do_trap_ecall_u+0xc6/0x27c\n [] ret_from_exception+0x0/0x64\n Code: b603 0109 b683 0189 b703 0209 8493 0609 157d 8d65 (a303) ffca\n ---[ end trace 0000000000000000 ]---\n Kernel panic - not syncing: Fatal exception\n SMP: stopping secondary CPUs\n\nImplement proper kCFI prologues for the BPF programs and callbacks and\ndrop __nocfi for riscv64. Fix the trampoline generation code to emit kCFI\nprologue when a struct_ops trampoline is being prepared.\n\nSigned-off-by: Puranjay Mohan \nSigned-off-by: Daniel Borkmann \nSigned-off-by: Andrii Nakryiko \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240303170207.82201-2-puranjay12@gmail.com\n', '']",Fix riscv BPF JIT to emit correct kCFI prologues for BPF programs with CONFIG_CFI_CLANG enabled.,"riscv, JIT, kCFI",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +516fca5a7516cde7a9968f84179ed20ffb438885,516fca5a7516cde7a9968f84179ed20ffb438885,Andrii Nakryiko,andrii@kernel.org,1709752802,Andrii Nakryiko,andrii@kernel.org,1709767096,06fb0432340f8ae5ca35102e7250a394274051c4,0f79bb8987a5c483362dc12d58b221a1a1c45578 5208930a909ad618363471e2872d79abef103626,"Merge branch 'libbpf-type-suffixes-and-autocreate-flag-for-struct_ops-maps' + +Eduard Zingerman says: + +==================== +libbpf: type suffixes and autocreate flag for struct_ops maps + +Tweak struct_ops related APIs to allow the following features: +- specify version suffixes for stuct_ops map types; +- share same BPF program between several map definitions with + different local BTF types"," assuming only maps with same + kernel BTF type would be selected for load; +- toggle autocreate flag for struct_ops maps; +- automatically toggle autoload for struct_ops programs referenced + from struct_ops maps","[' depending on autocreate status of the\n corresponding map;\n- use SEC(""?.struct_ops"") and SEC(""?.struct_ops.link"")\n to define struct_ops maps with autocreate == false after object open.\n\nThis would allow loading programs like below:\n\n SEC(""struct_ops/foo"") int BPF_PROG(foo) { ... }\n SEC(""struct_ops/bar"") int BPF_PROG(bar) { ... }\n\n struct bpf_testmod_ops___v1 {\n int (*foo)(void);\n };\n\n struct bpf_testmod_ops___v2 {\n int (*foo)(void);\n int (*bar)(void);\n };\n\n /* Assume kernel type name to be \'test_ops\' */\n SEC("".struct_ops.link"")\n struct test_ops___v1 map_v1 = {\n /* Program \'foo\' shared by maps with\n * different local BTF type\n */\n .foo = (void *)foo\n };\n\n SEC("".struct_ops.link"")\n struct test_ops___v2 map_v2 = {\n .foo = (void *)foo', '\n .bar = (void *)bar\n };\n\nAssuming the following tweaks are done before loading:\n\n /* to load v1 */\n bpf_map__set_autocreate(skel->maps.map_v1', ' true);\n bpf_map__set_autocreate(skel->maps.map_v2', ' false);\n\n /* to load v2 */\n bpf_map__set_autocreate(skel->maps.map_v1', ' false);\n bpf_map__set_autocreate(skel->maps.map_v2', ' true);\n\nPatch #8 ties autocreate and autoload flags for struct_ops maps and\nprograms.\n\nChangelog:\n- v3 [3] -> v4:\n - changes for multiple styling suggestions from Andrii;\n - patch #5: libbpf log capture now happens for LIBBPF_INFO and\n LIBBPF_WARN messages and does not depend on verbosity flags\n (Andrii);\n - patch #6: fixed runtime crash caused by conflict with newly added\n test case struct_ops_multi_pages;\n - patch #7: fixed free of possibly uninitialized pointer (Daniel)\n - patch #8: simpler algorithm to detect which programs to autoload\n (Andrii);\n - patch #9: added assertions for autoload flag after object load\n (Andrii);\n - patch #12: DATASEC name rewrite in libbpf is now done inplace', ' no\n new strings added to BTF (Andrii);\n - patch #14: allow any printable characters in DATASEC names when\n kernel validates BTF (Andrii)\n- v2 [2] -> v3:\n - moved patch #8 logic to be fully done on load\n (requested by Andrii in offlist discussion);\n - in patch #9 added test case for shadow vars and\n autocreate/autoload interaction.\n- v1 [1] -> v2:\n - fixed memory leak in patch #1 (Kui-Feng);\n - improved error messages in patch #2 (Martin', ' Andrii);\n - in bad_struct_ops selftest from patch #6 added .test_2\n map member setup (David);\n - added utility functions to capture libbpf log from selftests (David)\n - in selftests replaced usage of ...__open_and_load by separate\n calls to ..._open() and ..._load() (Andrii);\n - removed serial_... in selftest definitions (Andrii);\n - improved comments in selftest struct_ops_autocreate\n from patch #7 (David);\n - removed autoload toggling logic incompatible with shadow variables\n from bpf_map__set_autocreate()', ' instead struct_ops programs\n autoload property is computed at struct_ops maps load phase', '\n see patch #8 (Kui-Feng', ' Martin', ' Andrii);\n - added support for SEC(""?.struct_ops"") and SEC(""?.struct_ops.link"")\n (Andrii).\n\n[1] https://lore.kernel.org/bpf/20240227204556.17524-1-eddyz87@gmail.com/\n[2] https://lore.kernel.org/bpf/20240302011920.15302-1-eddyz87@gmail.com/\n[3] https://lore.kernel.org/bpf/20240304225156.24765-1-eddyz87@gmail.com/\n====================\n\nLink: https://lore.kernel.org/r/20240306104529.6453-1-eddyz87@gmail.com\nSigned-off-by: Andrii Nakryiko \n', '']","Enhance struct_ops maps in libbpf with type suffixes, autocreate flag, and autoload toggle features.","struct_ops, type suffixes, autocreate",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5208930a909ad618363471e2872d79abef103626,5208930a909ad618363471e2872d79abef103626,Eduard Zingerman,eddyz87@gmail.com,1709721929,Andrii Nakryiko,andrii@kernel.org,1709767096,06fb0432340f8ae5ca35102e7250a394274051c4,bd70a8fb7ca4fcb078086f4d96b048aaf1aa4786,"selftests/bpf: Test cases for '?' in BTF names + +Two test cases to verify that '?' and other printable characters are +allowed in BTF DATASEC names: +- DATASEC with name ""?.foo bar:buz"" should be accepted; +- type with name ""?foo"" should be rejected. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-16-eddyz87@gmail.com +",,Add test cases to verify BTF names with '?' and other characters in eBPF.,"test cases,BTF names,selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +bd70a8fb7ca4fcb078086f4d96b048aaf1aa4786,bd70a8fb7ca4fcb078086f4d96b048aaf1aa4786,Eduard Zingerman,eddyz87@gmail.com,1709721928,Andrii Nakryiko,andrii@kernel.org,1709767096,5e508f79182e882a923a5f2986a0e9fcaa53334f,733e5e875444fc5afc9b72714f0ecaca629ccf8a,"bpf: Allow all printable characters in BTF DATASEC names + +The intent is to allow libbpf to use SEC(""?.struct_ops"") to identify +struct_ops maps that are optional"," e.g. like in the following BPF code: + + SEC(""?.struct_ops"") + struct test_ops optional_map = { ... }; + +Which yields the following BTF: + + ... + [13] DATASEC '?.struct_ops' size=0 vlen=... + ... + +To load such BTF libbpf rewrites DATASEC name before load. +After this patch the rewrite won't be necessary. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-15-eddyz87@gmail.com +",[''],The commit allows all printable characters in BTF DATASEC names for struct_ops maps.,"BTF, struct_ops, libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"[""It's not related to any of the above.""]" +733e5e875444fc5afc9b72714f0ecaca629ccf8a,733e5e875444fc5afc9b72714f0ecaca629ccf8a,Eduard Zingerman,eddyz87@gmail.com,1709721927,Andrii Nakryiko,andrii@kernel.org,1709767096,2024cbc2e714c16921db1db347d02f151bcd2ca4,6ebaa3fb88bbe4c33a0e01ce27007e1dd4fd133c,"selftests/bpf: Test case for SEC(""?.struct_ops"") + +Check that ""?.struct_ops"" and ""?.struct_ops.link"" section names define +struct_ops maps with autocreate == false after open. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-14-eddyz87@gmail.com +",,Add test case for struct_ops map sections with autocreate set to false.,selftests struct_ops autocreate,It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6ebaa3fb88bbe4c33a0e01ce27007e1dd4fd133c,6ebaa3fb88bbe4c33a0e01ce27007e1dd4fd133c,Eduard Zingerman,eddyz87@gmail.com,1709721926,Andrii Nakryiko,andrii@kernel.org,1709767096,a57dae4f7884140f99d6b78f9a461b2b16f9f30d,5ad0ecbe056a4ea5ffaa73e58503a2f87b119a59,"libbpf: Rewrite btf datasec names starting from '?' + +Optional struct_ops maps are defined using question mark at the start +of the section name"," e.g.: + + SEC(""?.struct_ops"") + struct test_ops optional_map = { ... }; + +This commit teaches libbpf to detect if kernel allows '?' prefix +in datasec names","["" and if it doesn't then to rewrite such names\nby replacing '?' with '_'"", ' e.g.:\n\n DATASEC ?.struct_ops -> DATASEC _.struct_ops\n\nSigned-off-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240306104529.6453-13-eddyz87@gmail.com\n', '']",This commit updates libbpf to support datasec names starting with '?' for optional struct_ops maps.,"libbpf, datasec, struct_ops",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,['other'] +5ad0ecbe056a4ea5ffaa73e58503a2f87b119a59,5ad0ecbe056a4ea5ffaa73e58503a2f87b119a59,Eduard Zingerman,eddyz87@gmail.com,1709721925,Andrii Nakryiko,andrii@kernel.org,1709767096,0ec07c636e02a90443c866021c0ebfa1e457c9ef,240bf8a5162e8c43cf368909582a01082d494d79,"libbpf: Struct_ops in SEC(""?.struct_ops"") / SEC(""?.struct_ops.link"") + +Allow using two new section names for struct_ops maps: +- SEC(""?.struct_ops"") +- SEC(""?.struct_ops.link"") + +To specify maps that have bpf_map->autocreate == false after open. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-12-eddyz87@gmail.com +",,This commit introduces new section names for struct_ops maps in libbpf to specify autocreate flag as false.,"struct_ops,section names,libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +240bf8a5162e8c43cf368909582a01082d494d79,240bf8a5162e8c43cf368909582a01082d494d79,Eduard Zingerman,eddyz87@gmail.com,1709721924,Andrii Nakryiko,andrii@kernel.org,1709767095,cdaac97bf8b0e3bc431f47562503e871a1c88500,651d49f15b2a84b3bcfe950fa99c3672b9619dbd,"libbpf: Replace elf_state->st_ops_* fields with SEC_ST_OPS sec_type + +The next patch would add two new section names for struct_ops maps. +To make working with multiple struct_ops sections more convenient: +- remove fields like elf_state->st_ops_{shndx","link_shndx}; +- mark section descriptions hosting struct_ops as + elf_sec_desc->sec_type == SEC_ST_OPS; + +After these changes struct_ops sections could be processed uniformly +by iterating bpf_object->efile.secs entries. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-11-eddyz87@gmail.com +",[''],This commit refactors libbpf to enhance handling of struct_ops sections by consolidating section descriptors.,"libbpf, struct_ops, elf_state",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +651d49f15b2a84b3bcfe950fa99c3672b9619dbd,651d49f15b2a84b3bcfe950fa99c3672b9619dbd,Eduard Zingerman,eddyz87@gmail.com,1709721923,Andrii Nakryiko,andrii@kernel.org,1709767095,eea5bdf4b6fe6d7b31445339fba8e799bf8ad623,fe9d049c3da06373a1a35914b7f695509e4cb1fe,"selftests/bpf: Verify struct_ops autoload/autocreate sync + +Check that autocreate flags of struct_ops map cause autoload of +struct_ops corresponding programs: +- when struct_ops program is referenced only from a map for which + autocreate is set to false"," that program should not be loaded; +- when struct_ops program with autoload == false is set to be used + from a map with autocreate == true using shadow var","['\n that program should be loaded;\n- when struct_ops program is not referenced from any map object load\n should fail.\n\nSigned-off-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240306104529.6453-10-eddyz87@gmail.com\n', '']",Enhances selftests to verify struct_ops map autocreate and autoload synchronization behavior.,"selftests,bpf,struct_ops",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fe9d049c3da06373a1a35914b7f695509e4cb1fe,fe9d049c3da06373a1a35914b7f695509e4cb1fe,Eduard Zingerman,eddyz87@gmail.com,1709721922,Andrii Nakryiko,andrii@kernel.org,1709767095,6c12581c804da865f4d0f7bf2b224e1d0543f90a,1863acccdf936c6917398165ca97e252d02fa6dd,"libbpf: Sync progs autoload with maps autocreate for struct_ops maps + +Automatically select which struct_ops programs to load depending on +which struct_ops maps are selected for automatic creation. +E.g. for the BPF code below: + + SEC(""struct_ops/test_1"") int BPF_PROG(foo) { ... } + SEC(""struct_ops/test_2"") int BPF_PROG(bar) { ... } + + SEC("".struct_ops.link"") + struct test_ops___v1 A = { + .foo = (void *)foo + }; + + SEC("".struct_ops.link"") + struct test_ops___v2 B = { + .foo = (void *)foo"," + .bar = (void *)bar","['\n };\n\nAnd the following libbpf API calls:\n\n bpf_map__set_autocreate(skel->maps.A', ' true);\n bpf_map__set_autocreate(skel->maps.B', "" false);\n\nThe autoload would be enabled for program 'foo' and disabled for\nprogram 'bar'.\n\nDuring load"", ' for each struct_ops program P', "" referenced from some\nstruct_ops map M:\n- set P.autoload = true if M.autocreate is true for some M;\n- set P.autoload = false if M.autocreate is false for all M;\n- don't change P.autoload"", ' if P is not referenced from any map.\n\nDo this after bpf_object__init_kern_struct_ops_maps()\nto make sure that shadow vars assignment is done.\n\nSigned-off-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240306104529.6453-9-eddyz87@gmail.com\n', '']",Sync program autoload with automatic map creation for struct_ops maps in libbpf.,"libbpf, struct_ops, autoload",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1863acccdf936c6917398165ca97e252d02fa6dd,1863acccdf936c6917398165ca97e252d02fa6dd,Eduard Zingerman,eddyz87@gmail.com,1709721921,Andrii Nakryiko,andrii@kernel.org,1709767095,38f5eee7c613edbace508dea7f294c3357faf3d2,c1b93c07b3ac3204c6a42a7f7b6217e36f44df4f,"selftests/bpf: Test autocreate behavior for struct_ops maps + +Check that bpf_map__set_autocreate() can be used to disable automatic +creation for struct_ops maps. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-8-eddyz87@gmail.com +",,Test added for autocreate behavior of struct_ops maps in selftests/bpf.,"selftests,bpf,struct_ops",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c1b93c07b3ac3204c6a42a7f7b6217e36f44df4f,c1b93c07b3ac3204c6a42a7f7b6217e36f44df4f,Eduard Zingerman,eddyz87@gmail.com,1709721920,Andrii Nakryiko,andrii@kernel.org,1709767095,bc5013bfc1d6b5f26f1a7cf9796c0f11b7639022,c8617e8bcf8d1ef357fadf5c96bd86b9952fb93f,"selftests/bpf: Bad_struct_ops test + +When loading struct_ops programs kernel requires BTF id of the +struct_ops type and member index for attachment point inside that +type. This makes impossible to use same BPF program in several +struct_ops maps that have different struct_ops type. +Check if libbpf rejects such BPF objects files. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-7-eddyz87@gmail.com +",,Adds a selftest in BPF to verify libbpf rejection of BPF objects with mismatched struct_ops types and indices.,"selftests, struct_ops, libbpf",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c8617e8bcf8d1ef357fadf5c96bd86b9952fb93f,c8617e8bcf8d1ef357fadf5c96bd86b9952fb93f,Eduard Zingerman,eddyz87@gmail.com,1709721919,Andrii Nakryiko,andrii@kernel.org,1709767095,98d73393511d70d2f7712f98ae0ace043330d0bc,5bab7a277ca8d4ef377a50a6678577b5bd7f74d8,"selftests/bpf: Utility functions to capture libbpf log in test_progs + +Several test_progs tests already capture libbpf log in order to check +for some expected output", e.g bpf_tcp_ca.c,"[' kfunc_dynptr_param.c', '\nlog_buf.c and a few others.\n\nThis commit provides a', ' hopefully', ' simple API to capture libbpf log\nw/o necessity to define new print callback in each test:\n\n /* Creates a global memstream capturing INFO and WARN level output\n * passed to libbpf_print_fn.\n * Returns 0 on success', ' negative value on failure.\n * On failure the description is printed using PRINT_FAIL and\n * current test case is marked as fail.\n */\n int start_libbpf_log_capture(void)\n\n /* Destroys global memstream created by start_libbpf_log_capture().\n * Returns a pointer to captured data which has to be freed.\n * Returned buffer is null terminated.\n */\n char *stop_libbpf_log_capture(void)\n\nThe intended usage is as follows:\n\n if (start_libbpf_log_capture())\n return;\n use_libbpf();\n char *log = stop_libbpf_log_capture();\n ASSERT_HAS_SUBSTR(log', ' ""... expected ...""', ' ""expected some message"");\n free(log);\n\nAs a safety measure', ' free(start_libbpf_log_capture()) is invoked in the\nepilogue of the test_progs.c:run_one_test().\n\nSigned-off-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240306104529.6453-6-eddyz87@gmail.com\n', '']",Add utility functions for capturing libbpf log in test_progs selftests.,"utility functions, libbpf log, test_progs",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5bab7a277ca8d4ef377a50a6678577b5bd7f74d8,5bab7a277ca8d4ef377a50a6678577b5bd7f74d8,Eduard Zingerman,eddyz87@gmail.com,1709721918,Andrii Nakryiko,andrii@kernel.org,1709767095,1548d99624590adc3fb77a35942e00b65577a1c1,8db052615a9780b45e26d6afabc7abefe1ba20ac,"selftests/bpf: Test struct_ops map definition with type suffix + +Extend struct_ops_module test case to check if it is possible to use +'___' suffixes for struct_ops type specification. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: David Vernet +Link: https://lore.kernel.org/bpf/20240306104529.6453-5-eddyz87@gmail.com +",,Extend struct_ops_module test case to verify struct_ops type specification with '___' suffixes.,"selftests,bpf,struct_ops",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8db052615a9780b45e26d6afabc7abefe1ba20ac,8db052615a9780b45e26d6afabc7abefe1ba20ac,Eduard Zingerman,eddyz87@gmail.com,1709721917,Andrii Nakryiko,andrii@kernel.org,1709767095,0be700562e5dd26252c1f41e1d3dbc45445dec06,d9ab2f76ef5abb76190ffb42d83bdc6caede807e,"libbpf: Honor autocreate flag for struct_ops maps + +Skip load steps for struct_ops maps not marked for automatic creation. +This should allow to load bpf object in situations like below: + + SEC(""struct_ops/foo"") int BPF_PROG(foo) { ... } + SEC(""struct_ops/bar"") int BPF_PROG(bar) { ... } + + struct test_ops___v1 { + int (*foo)(void); + }; + + struct test_ops___v2 { + int (*foo)(void); + int (*does_not_exist)(void); + }; + + SEC("".struct_ops.link"") + struct test_ops___v1 map_for_old = { + .test_1 = (void *)foo + }; + + SEC("".struct_ops.link"") + struct test_ops___v2 map_for_new = { + .test_1 = (void *)foo"," + .does_not_exist = (void *)bar + }; + +Suppose program is loaded on old kernel that does not have definition +for 'does_not_exist' struct_ops member. After this commit it would be +possible to load such object file after the following tweaks: + + bpf_program__set_autoload(skel->progs.bar","[' false);\n bpf_map__set_autocreate(skel->maps.map_for_new', ' false);\n\nSigned-off-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nAcked-by: David Vernet \nLink: https://lore.kernel.org/bpf/20240306104529.6453-4-eddyz87@gmail.com\n', '']",Skip loading steps for struct_ops maps not marked for automatic creation in libbpf.,"libbpf,struct_ops,autocreate",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d9ab2f76ef5abb76190ffb42d83bdc6caede807e,d9ab2f76ef5abb76190ffb42d83bdc6caede807e,Eduard Zingerman,eddyz87@gmail.com,1709721916,Andrii Nakryiko,andrii@kernel.org,1709767095,ea29a8f148822b4c4874a56cd456bd2435f81980,a2a5172cf1eb39472bd2038079f65c6f676906a5,libbpf: Tie struct_ops programs to kernel BTF ids," not to local ids + +Enforce the following existing limitation on struct_ops programs based +on kernel BTF id instead of program-local BTF id: + + struct_ops BPF prog can be re-used between multiple .struct_ops & + .struct_ops.link as long as it's the same struct_ops struct + definition and the same function pointer field + +This allows reusing same BPF program for versioned struct_ops map +definitions","[' e.g.:\n\n SEC(""struct_ops/test"")\n int BPF_PROG(foo) { ... }\n\n struct some_ops___v1 { int (*test)(void); };\n struct some_ops___v2 { int (*test)(void); };\n\n SEC("".struct_ops.link"") struct some_ops___v1 a = { .test = foo }\n SEC("".struct_ops.link"") struct some_ops___v2 b = { .test = foo }\n\nSigned-off-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240306104529.6453-3-eddyz87@gmail.com\n', '']",The commit ties struct_ops programs to kernel BTF ids for reuse across multiple struct_ops definitions.,"struct_ops,kernel BTF,reuse",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a2a5172cf1eb39472bd2038079f65c6f676906a5,a2a5172cf1eb39472bd2038079f65c6f676906a5,Eduard Zingerman,eddyz87@gmail.com,1709721915,Andrii Nakryiko,andrii@kernel.org,1709767095,8fa10eaa502c527a8572b6c89958e9e06d1fd0e9,0f79bb8987a5c483362dc12d58b221a1a1c45578,"libbpf: Allow version suffixes (___smth) for struct_ops types + +E.g. allow the following struct_ops definitions: + + struct bpf_testmod_ops___v1 { int (*test)(void); }; + struct bpf_testmod_ops___v2 { int (*test)(void); }; + + SEC("".struct_ops.link"") + struct bpf_testmod_ops___v1 a = { .test = ... } + SEC("".struct_ops.link"") + struct bpf_testmod_ops___v2 b = { .test = ... } + +Where both bpf_testmod_ops__v1 and bpf_testmod_ops__v2 would be +resolved as 'struct bpf_testmod_ops' from kernel BTF. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: David Vernet +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240306104529.6453-2-eddyz87@gmail.com +",,Enable version suffixes for struct_ops types in the libbpf library to support multiple versions.,"libbpf,struct_ops,BTF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0f79bb8987a5c483362dc12d58b221a1a1c45578,0f79bb8987a5c483362dc12d58b221a1a1c45578,Andrii Nakryiko,andrii@kernel.org,1709750478,Andrii Nakryiko,andrii@kernel.org,1709767094,cd7ae2ef290324dcc66110f84aec4ad01fd94a85,9a9d1d36050e486822dc54990c896761b04e7446 0c8bbf990bddef1a4f32889b18a4a016d9bd2cfd,"Merge branch 'bpf-introduce-may_goto-and-cond_break' + +Alexei Starovoitov says: + +==================== +bpf: Introduce may_goto and cond_break + +From: Alexei Starovoitov + +v5 -> v6: +- Rename BPF_JMA to BPF_JCOND +- Addressed Andrii's review comments + +v4 -> v5: +- rewrote patch 1 to avoid fake may_goto_reg and use 'u32 may_goto_cnt' instead. + This way may_goto handling is similar to bpf_loop() processing. +- fixed bug in patch 2 that RANGE_WITHIN should not use + rold->type == NOT_INIT as a safe signal. +- patch 3 fixed negative offset computation in cond_break macro +- using bpf_arena and cond_break recompiled lib/glob.c as bpf prog + and it works! It will be added as a selftest to arena series. + +v3 -> v4: +- fix drained issue reported by John. + may_goto insn could be implemented with sticky state (once + reaches 0 it stays 0)"," but the verifier shouldn't assume that. + It has to explore both branches. + Arguably drained iterator state shouldn't be there at all. + bpf_iter_css_next() is not sticky. Can be fixed","["" but auditing all\n iterators for stickiness. That's an orthogonal discussion.\n- explained JMA name reasons in patch 1\n- fixed test_progs-no_alu32 issue and added another test\n\nv2 -> v3: Major change\n- drop bpf_can_loop() kfunc and introduce may_goto instruction instead\n kfunc is a function call while may_goto doesn't consume any registers\n and LLVM can produce much better code due to less register pressure.\n- instead of counting from zero to BPF_MAX_LOOPS start from it instead\n and break out of the loop when count reaches zero\n- use may_goto instruction in cond_break macro\n- recognize that 'exact' state comparison doesn't need to be truly exact.\n regsafe() should ignore precision and liveness marks"", ' but range_within\n logic is safe to use while evaluating open coded iterators.\n====================\n\nLink: https://lore.kernel.org/r/20240306031929.42666-1-alexei.starovoitov@gmail.com\nSigned-off-by: Andrii Nakryiko \n', '']",The commit introduces may_goto and cond_break constructs in the eBPF verifier.,"may_goto, cond_break, eBPF",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0c8bbf990bddef1a4f32889b18a4a016d9bd2cfd,0c8bbf990bddef1a4f32889b18a4a016d9bd2cfd,Alexei Starovoitov,ast@kernel.org,1709695169,Andrii Nakryiko,andrii@kernel.org,1709767090,cd7ae2ef290324dcc66110f84aec4ad01fd94a85,06375801525717173aee790310b7d959bb77879b,"selftests/bpf: Test may_goto + +Add tests for may_goto instruction via cond_break macro. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: John Fastabend +Tested-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240306031929.42666-5-alexei.starovoitov@gmail.com +",,Add selftests for the may_goto instruction using the cond_break macro in BPF.,"selftests,BPF,may_goto",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +06375801525717173aee790310b7d959bb77879b,06375801525717173aee790310b7d959bb77879b,Alexei Starovoitov,ast@kernel.org,1709695168,Andrii Nakryiko,andrii@kernel.org,1709767084,56f571c37744c55fbab9eb4952875c1725e968e7,4f81c16f50baf6d5d8bfa6eef3250dcfa22cbc08,"bpf: Add cond_break macro + +Use may_goto instruction to implement cond_break macro. +Ideally the macro should be written as: + asm volatile goto("".byte 0xe5; + .byte 0; + .short %l[l_break] ... + .long 0; +but LLVM doesn't recognize fixup of 2 byte PC relative yet. +Hence use + asm volatile goto("".byte 0xe5; + .byte 0; + .long %l[l_break] ... + .short 0; +that produces correct asm on little endian. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Acked-by: John Fastabend +Tested-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240306031929.42666-4-alexei.starovoitov@gmail.com +",,Add cond_break macro using may_goto instruction for better assembly compatibility with little endian systems.,"cond_break, macro, may_goto",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4f81c16f50baf6d5d8bfa6eef3250dcfa22cbc08,4f81c16f50baf6d5d8bfa6eef3250dcfa22cbc08,Alexei Starovoitov,ast@kernel.org,1709695167,Andrii Nakryiko,andrii@kernel.org,1709767080,9d0f0fd22a3c61db123c1e02ca4874ec34ad8f96,011832b97b311bb9e3c27945bc0d1089a14209c9,"bpf: Recognize that two registers are safe when their ranges match + +When open code iterators"," bpf_loop or may_goto are used the following two +states are equivalent and safe to prune the search: + +cur state: fp-8_w=scalar(id=3","['smin=umin=smin32=umin32=2', 'smax=umax=smax32=umax32=11', 'var_off=(0x0; 0xf))\nold state: fp-8_rw=scalar(id=2', 'smin=umin=smin32=umin32=1', 'smax=umax=smax32=umax32=11', 'var_off=(0x0; 0xf))\n\nIn other words ""exact"" state match should ignore liveness and precision\nmarks', "" since open coded iterator logic didn't complete their propagation"", '\nreg_old->type == NOT_INIT && reg_cur->type != NOT_INIT is also not safe to\nprune while looping', ' but range_within logic that applies to scalars', '\nptr_to_mem', ' map_value', ' pkt_ptr is safe to rely on.\n\nAvoid doing such comparison when regular infinite loop detection logic is\nused', ' otherwise bounded loop logic will declare such ""infinite loop"" as\nfalse positive. Such example is in progs/verifier_loops1.c\nnot_an_inifinite_loop().\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nAcked-by: John Fastabend \nTested-by: John Fastabend \nLink: https://lore.kernel.org/bpf/20240306031929.42666-3-alexei.starovoitov@gmail.com\n', '']",The commit optimizes register safety recognition by matching their ranges for bpf open code iterators.,"registers,safe,ranges",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +011832b97b311bb9e3c27945bc0d1089a14209c9,011832b97b311bb9e3c27945bc0d1089a14209c9,Alexei Starovoitov,ast@kernel.org,1709695166,Andrii Nakryiko,andrii@kernel.org,1709767051,895a1b974a1b6edcd101286dcf3436fffad046b2,9a9d1d36050e486822dc54990c896761b04e7446,"bpf: Introduce may_goto instruction + +Introduce may_goto instruction that from the verifier pov is similar to +open coded iterators bpf_for()/bpf_repeat() and bpf_loop() helper"," but it +doesn't iterate any objects. +In assembly 'may_goto' is a nop most of the time until bpf runtime has to +terminate the program for whatever reason. In the current implementation +may_goto has a hidden counter","[' but other mechanisms can be used.\nFor programs written in C the later patch introduces \'cond_break\' macro\nthat combines \'may_goto\' with \'break\' statement and has similar semantics:\ncond_break is a nop until bpf runtime has to break out of this loop.\nIt can be used in any normal ""for"" or ""while"" loop', ' like\n\n for (i = zero; i < cnt; cond_break', ' i++) {\n\nThe verifier recognizes that may_goto is used in the program', ' reserves\nadditional 8 bytes of stack', ' initializes them in subprog prologue', ' and\nreplaces may_goto instruction with:\naux_reg = *(u64 *)(fp - 40)\nif aux_reg == 0 goto pc+off\naux_reg -= 1\n*(u64 *)(fp - 40) = aux_reg\n\nmay_goto instruction can be used by LLVM to implement __builtin_memcpy', ""\n__builtin_strcmp.\n\nmay_goto is not a full substitute for bpf_for() macro.\nbpf_for() doesn't have induction variable that verifiers sees"", ""\nso 'i' in bpf_for(i"", ' 0', ' 100) is seen as imprecise and bounded.\n\nBut when the code is written as:\nfor (i = 0; i < 100; cond_break', "" i++)\nthe verifier see 'i' as precise constant zero"", ""\nhence cond_break (aka may_goto) doesn't help to converge the loop.\nA static or global variable can be used as a workaround:\nstatic int zero = 0;\nfor (i = zero; i < 100; cond_break"", "" i++) // works!\n\nmay_goto works well with arena pointers that don't need to be bounds\nchecked on access. Load/store from arena returns imprecise unbounded\nscalar and loops with may_goto pass the verifier.\n\nReserve new opcode BPF_JMP | BPF_JCOND for may_goto insn.\nJCOND stands for conditional pseudo jump.\nSince goto_or_nop insn was proposed"", ' it may use the same opcode.\nmay_goto vs goto_or_nop can be distinguished by src_reg:\ncode = BPF_JMP | BPF_JCOND\nsrc_reg = 0 - may_goto\nsrc_reg = 1 - goto_or_nop\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nAcked-by: John Fastabend \nTested-by: John Fastabend \nLink: https://lore.kernel.org/bpf/20240306031929.42666-2-alexei.starovoitov@gmail.com\n', '']",Introduce may_goto instruction that acts as a conditional program termination point in BPF verifier.,"may_goto,instruction,verifier",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e6f798225a31485e47a6e4f6aa07ee9fdf80c2cb,e6f798225a31485e47a6e4f6aa07ee9fdf80c2cb,Alexei Starovoitov,ast@kernel.org,1709607916,Andrii Nakryiko,andrii@kernel.org,1709767042,97b3ec52194dd1296d16edda6288460a32cd2ef8,3e49a866c9dcbd8173e4f3e491293619a9e81fa4,"mm: Introduce VM_SPARSE kind and vm_area_[un]map_pages(). + +vmap/vmalloc APIs are used to map a set of pages into contiguous kernel +virtual space. + +get_vm_area() with appropriate flag is used to request an area of kernel +address range. It's used for vmalloc", vmap,"[' ioremap', ' xen use cases.\n- vmalloc use case dominates the usage. Such vm areas have VM_ALLOC flag.\n- the areas created by vmap() function should be tagged with VM_MAP.\n- ioremap areas are tagged with VM_IOREMAP.\n\nBPF would like to extend the vmap API to implement a lazily-populated\nsparse', ' yet contiguous kernel virtual space. Introduce VM_SPARSE flag\nand vm_area_map_pages(area', ' start_addr', ' count', ' pages) API to map a set\nof pages within a given area.\nIt has the same sanity checks as vmap() does.\nIt also checks that get_vm_area() was created with VM_SPARSE flag\nwhich identifies such areas in /proc/vmallocinfo\nand returns zero pages on read through /proc/kcore.\n\nThe next commits will introduce bpf_arena which is a sparsely populated\nshared memory region between bpf program and user space process. It will\nmap privately-managed pages into a sparse vm area with the following steps:\n\n // request virtual memory region during bpf prog verification\n area = get_vm_area(area_size', ' VM_SPARSE);\n\n // on demand\n vm_area_map_pages(area', ' kaddr', ' kend', ' pages);\n vm_area_unmap_pages(area', ' kaddr', ' kend);\n\n // after bpf program is detached and unloaded\n free_vm_area(area);\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nReviewed-by: Christoph Hellwig \nReviewed-by: Pasha Tatashin \nLink: https://lore.kernel.org/bpf/20240305030516.41519-3-alexei.starovoitov@gmail.com\n', '']",Introduces VM_SPARSE kind and vm_area_[un]map_pages() functionality to handle kernel virtual space mapping.,"VM_SPARSE, vmap, vmalloc",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +3e49a866c9dcbd8173e4f3e491293619a9e81fa4,3e49a866c9dcbd8173e4f3e491293619a9e81fa4,Alexei Starovoitov,ast@kernel.org,1709607915,Andrii Nakryiko,andrii@kernel.org,1709749144,5ed90ad44657e757261e3c827c3a87dd67df8b3e,8f50d5c423551bfa259af792647a2f4799780ac5,"mm: Enforce VM_IOREMAP flag and range in ioremap_page_range. + +There are various users of get_vm_area() + ioremap_page_range() APIs. +Enforce that get_vm_area() was requested as VM_IOREMAP type and range +passed to ioremap_page_range() matches created vm_area to avoid +accidentally ioremap-ing into wrong address range. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Reviewed-by: Christoph Hellwig +Link: https://lore.kernel.org/bpf/20240305030516.41519-2-alexei.starovoitov@gmail.com +",,Enforce VM_IOREMAP flag and range in ioremap_page_range to prevent incorrect ioremap usage.,"VM_IOREMAP,enforce,ioremap",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +2487007aa3b9fafbd2cb14068f49791ce1d7ede5,2487007aa3b9fafbd2cb14068f49791ce1d7ede5,Toke Høiland-Jørgensen,toke@redhat.com,1709674292,Martin KaFai Lau,martin.lau@kernel.org,1709686133,b3ecf09e17cc47833c8e8a196655e3924bbd911c,0bfc0336e1348883fdab4689f0c8c56458f36dd8,"cpumap: Zero-initialise xdp_rxq_info struct before running XDP program + +When running an XDP program that is attached to a cpumap entry"," we don't +initialise the xdp_rxq_info data structure being used in the xdp_buff +that backs the XDP program invocation. Tobias noticed that this leads to +random values being returned as the xdp_md->rx_queue_index value for XDP +programs running in a cpumap. + +This means we're basically returning the contents of the uninitialised +memory","[' which is bad. Fix this by zero-initialising the rxq data\nstructure before running the XDP program.\n\nFixes: 9216477449f3 (""bpf: cpumap: Add the possibility to attach an eBPF program to cpumap"")\nReported-by: Tobias Böhm \nSigned-off-by: Toke Høiland-Jørgensen \nLink: https://lore.kernel.org/r/20240305213132.11955-1-toke@redhat.com\nSigned-off-by: Martin KaFai Lau \n', '']",This commit zero-initializes the xdp_rxq_info structure to prevent random values in xdp_md->rx_queue_index for cpumap entries.,"zero-initialize,xdp_rxq_info,cpumap",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['xdp like programs'] +0bfc0336e1348883fdab4689f0c8c56458f36dd8,0bfc0336e1348883fdab4689f0c8c56458f36dd8,Daniel Borkmann,daniel@iogearbox.net,1709629709,Alexei Starovoitov,ast@kernel.org,1709684382,5f00303a03b043fcd0cb03d674c27cbca91660ab,f267f262815033452195f46c43b572159262f533,"selftests/bpf: Fix up xdp bonding test wrt feature flags + +Adjust the XDP feature flags for the bond device when no bond slave +devices are attached. After 9b0ed890ac2a (""bonding: do not report +NETDEV_XDP_ACT_XSK_ZEROCOPY"")"," the empty bond device must report 0 +as flags instead of NETDEV_XDP_ACT_MASK. + + # ./vmtest.sh -- ./test_progs -t xdp_bond + [...] + [ 3.983311] bond1 (unregistering): (slave veth1_1): Releasing backup interface + [ 3.995434] bond1 (unregistering): Released all slaves + [ 4.022311] bond2: (slave veth2_1): Releasing backup interface + #507/1 xdp_bonding/xdp_bonding_attach:OK + #507/2 xdp_bonding/xdp_bonding_nested:OK + #507/3 xdp_bonding/xdp_bonding_features:OK + #507/4 xdp_bonding/xdp_bonding_roundrobin:OK + #507/5 xdp_bonding/xdp_bonding_activebackup:OK + #507/6 xdp_bonding/xdp_bonding_xor_layer2:OK + #507/7 xdp_bonding/xdp_bonding_xor_layer23:OK + #507/8 xdp_bonding/xdp_bonding_xor_layer34:OK + #507/9 xdp_bonding/xdp_bonding_redirect_multi:OK + #507 xdp_bonding:OK + Summary: 1/9 PASSED","[' 0 SKIPPED', ' 0 FAILED\n [ 4.185255] bond2 (unregistering): Released all slaves\n [...]\n\nFixes: 9b0ed890ac2a (""bonding: do not report NETDEV_XDP_ACT_XSK_ZEROCOPY"")\nSigned-off-by: Daniel Borkmann \nReviewed-by: Toke Høiland-Jørgensen \nMessage-ID: <20240305090829.17131-2-daniel@iogearbox.net>\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes XDP feature flags for bond devices when no slave devices are attached in selftests.,"XDP,bonding,feature",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['xdp like programs'] +399eca1bd4fc14645dcdf19ee10adf5cde85aecf,399eca1bd4fc14645dcdf19ee10adf5cde85aecf,Alexei Starovoitov,ast@kernel.org,1708620887,Alexei Starovoitov,ast@kernel.org,1709684157,9679deaf78e877789d754ee7f82f9d1b874e64fa,685f7d531264599b3f167f1e94bbd22f120e5fab 5c2bc5e2f81d3344095ae241032dde20a4ea2b48,"Merge branch 'check-bpf_func_state-callback_depth-when-pruning-states' + +Eduard Zingerman says: + +==================== +check bpf_func_state->callback_depth when pruning states + +This patch-set fixes bug in states pruning logic hit in mailing list +discussion [0]. The details of the fix are in patch #1. + +The main idea for the fix belongs to Yonghong Song"," +mine contribution is merely in review and test cases. + +There are some changes in verification performance: + +File Program Insns (DIFF) States (DIFF) +------------------------- ------------- --------------- -------------- +pyperf600_bpf_loop.bpf.o on_event +15 (+0.42%) +0 (+0.00%) +strobemeta_bpf_loop.bpf.o on_event +857 (+37.95%) +60 (+38.96%) +xdp_synproxy_kern.bpf.o syncookie_tc +2892 (+30.39%) +109 (+36.33%) +xdp_synproxy_kern.bpf.o syncookie_xdp +2892 (+30.01%) +109 (+36.09%) + +(when tested on a subset of selftests identified by + selftests/bpf/veristat.cfg and Cilium bpf object files from [4]) + +Changelog: +v2 [2] -> v3: +- fixes for verifier.c commit message as suggested by Yonghong; +- patch-set re-rerouted to 'bpf' tree as suggested in [2]; +- patch for test_tcp_custom_syncookie is sent separately to 'bpf-next' [3]. +- veristat results updated using 'bpf' tree as baseline and clang 16. + +v1 [1] -> v2: +- patch #2 commit message updated to better reflect verifier behavior + with regards to checkpoints tree (suggested by Yonghong); +- veristat results added (suggested by Andrii). + +[0] https://lore.kernel.org/bpf/9b251840-7cb8-4d17-bd23-1fc8071d8eef@linux.dev/ +[1] https://lore.kernel.org/bpf/20240212143832.28838-1-eddyz87@gmail.com/ +[2] https://lore.kernel.org/bpf/20240216150334.31937-1-eddyz87@gmail.com/ +[3] https://lore.kernel.org/bpf/20240222150300.14909-1-eddyz87@gmail.com/ +[4] https://github.com/anakryiko/cilium +==================== + +Link: https://lore.kernel.org/r/20240222154121.6991-1-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Fixes a bug in eBPF verifier state pruning logic related to callback depth.,"bugfix, pruning, verifier",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5c2bc5e2f81d3344095ae241032dde20a4ea2b48,5c2bc5e2f81d3344095ae241032dde20a4ea2b48,Eduard Zingerman,eddyz87@gmail.com,1708616481,Alexei Starovoitov,ast@kernel.org,1709684156,9679deaf78e877789d754ee7f82f9d1b874e64fa,e9a8e5a587ca55fec6c58e4881742705d45bee54,"selftests/bpf: test case for callback_depth states pruning logic + +The test case was minimized from mailing list discussion [0]. +It is equivalent to the following C program: + + struct iter_limit_bug_ctx { __u64 a; __u64 b; __u64 c; }; + + static __naked void iter_limit_bug_cb(void) + { + switch (bpf_get_prandom_u32()) { + case 1: ctx->a = 42; break; + case 2: ctx->b = 42; break; + default: ctx->c = 42; break; + } + } + + int iter_limit_bug(struct __sk_buff *skb) + { + struct iter_limit_bug_ctx ctx = { 7", 7,"[' 7 };\n\n \tbpf_loop(2', ' iter_limit_bug_cb', ' &ctx', ' 0);\n \tif (ctx.a == 42 && ctx.b == 42 && ctx.c == 7)\n \t asm volatile(""r1 /= 0;"":::""r1"");\n \treturn 0;\n }\n\nThe main idea is that each loop iteration changes one of the state\nvariables in a non-deterministic manner. Hence it is premature to\nprune the states that have two iterations left comparing them to\nstates with one iteration left.\nE.g. {{7', '7', '7}', ' callback_depth=0} can reach state {42', '42', '7}', '\nwhile {{7', '7', '7}', "" callback_depth=1} can't.\n\n[0] https://lore.kernel.org/bpf/9b251840-7cb8-4d17-bd23-1fc8071d8eef@linux.dev/\n\nAcked-by: Yonghong Song \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240222154121.6991-3-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n"", '']",Add test case for callback_depth states pruning logic in BPF selftests.,"test case,callback_depth,pruning",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e9a8e5a587ca55fec6c58e4881742705d45bee54,e9a8e5a587ca55fec6c58e4881742705d45bee54,Eduard Zingerman,eddyz87@gmail.com,1708616480,Alexei Starovoitov,ast@kernel.org,1709684156,98218bc1166ae5b153e46acb518eafe1d8d15c9d,685f7d531264599b3f167f1e94bbd22f120e5fab,"bpf: check bpf_func_state->callback_depth when pruning states + +When comparing current and cached states verifier should consider +bpf_func_state->callback_depth. Current state cannot be pruned against +cached state"," when current states has more iterations left compared to +cached state. Current state has more iterations left when it's +callback_depth is smaller. + +Below is an example illustrating this bug","[' minimized from mailing list\ndiscussion [0] (assume that BPF_F_TEST_STATE_FREQ is set).\nThe example is not a safe program: if loop_cb point (1) is followed by\nloop_cb point (2)', ' then division by zero is possible at point (4).\n\n struct ctx {\n \t__u64 a;\n \t__u64 b;\n \t__u64 c;\n };\n\n static void loop_cb(int i', ' struct ctx *ctx)\n {\n \t/* assume that generated code is ""fallthrough-first"":\n \t * if ... == 1 goto\n \t * if ... == 2 goto\n \t * \n \t */\n \tswitch (bpf_get_prandom_u32()) {\n \tcase 1: /* 1 */ ctx->a = 42; return 0; break;\n \tcase 2: /* 2 */ ctx->b = 42; return 0; break;\n \tdefault: /* 3 */ ctx->c = 42; return 0; break;\n \t}\n }\n\n SEC(""tc"")\n __failure\n __flag(BPF_F_TEST_STATE_FREQ)\n int test(struct __sk_buff *skb)\n {\n \tstruct ctx ctx = { 7', ' 7', ' 7 };\n\n \tbpf_loop(2', ' loop_cb', ' &ctx', ' 0); /* 0 */\n \t/* assume generated checks are in-order: .a first */\n \tif (ctx.a == 42 && ctx.b == 42 && ctx.c == 7)\n \t\tasm volatile(""r0 /= 0;"":::""r0""); /* 4 */\n \treturn 0;\n }\n\nPrior to this commit verifier built the following checkpoint tree for\nthis example:\n\n .------------------------------------- Checkpoint / State name\n | .-------------------------------- Code point number\n | | .---------------------------- Stack state {ctx.a', 'ctx.b', 'ctx.c}\n | | | .------------------- Callback depth in frame #0\n v v v v\n - (0) {7P', '7P', '7}', 'depth=0\n - (3) {7P', '7P', '7}', 'depth=1\n - (0) {7P', '7P', '42}', 'depth=1\n - (3) {7P', '7', '42}', 'depth=2\n - (0) {7P', '7', '42}', 'depth=2 loop terminates because of depth limit\n - (4) {7P', '7', '42}', 'depth=0 predicted false', ' ctx.a marked precise\n - (6) exit\n(a) - (2) {7P', '7', '42}', 'depth=2\n - (0) {7P', '42', '42}', 'depth=2 loop terminates because of depth limit\n - (4) {7P', '42', '42}', 'depth=0 predicted false', ' ctx.a marked precise\n - (6) exit\n(b) - (1) {7P', '7P', '42}', 'depth=2\n - (0) {42P', '7P', '42}', 'depth=2 loop terminates because of depth limit\n - (4) {42P', '7P', '42}', 'depth=0 predicted false', ' ctx.{a', 'b} marked precise\n - (6) exit\n - (2) {7P', '7', '7}', 'depth=1 considered safe', ' pruned using checkpoint (a)\n(c) - (1) {7P', '7P', '7}', 'depth=1 considered safe', ' pruned using checkpoint (b)\n\nHere checkpoint (b) has callback_depth of 2', ' meaning that it would\nnever reach state {42', '42', '7}.\nWhile checkpoint (c) has callback_depth of 1', ' and thus\ncould yet explore the state {42', '42', '7} if not pruned prematurely.\nThis commit makes forbids such premature pruning', '\nallowing verifier to explore states sub-tree starting at (c):\n\n(c) - (1) {7', '7', '7P}', 'depth=1\n - (0) {42P', '7', '7P}', 'depth=1\n ...\n - (2) {42', '7', '7}', 'depth=2\n - (0) {42', '42', '7}', 'depth=2 loop terminates because of depth limit\n - (4) {42', '42', '7}', 'depth=0 predicted true', ' ctx.{a', 'b', 'c} marked precise\n - (5) division by zero\n\n[0] https://lore.kernel.org/bpf/9b251840-7cb8-4d17-bd23-1fc8071d8eef@linux.dev/\n\nFixes: bb124da69c47 (""bpf: keep track of max number of bpf_loop callback iterations"")\nSuggested-by: Yonghong Song \nSigned-off-by: Eduard Zingerman \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240222154121.6991-2-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix the pruning logic in the eBPF verifier by considering callback_depth in function states.,"bpf,func_state,callback_depth",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ef27f655b438bed4c83680e4f01e1cde2739854b,ef27f655b438bed4c83680e4f01e1cde2739854b,Florian Kauer,florian.kauer@linutronix.de,1708333723,Tony Nguyen,anthony.l.nguyen@intel.com,1709661033,b4cfcb66fc2d5f1e8b495ab50e1bcb6ce22dbd79,36c824ca3e4fa8d1224c2dcdeaca39d2ca86a42f,"igc: avoid returning frame twice in XDP_REDIRECT + +When a frame can not be transmitted in XDP_REDIRECT +(e.g. due to a full queue)"," it is necessary to free +it by calling xdp_return_frame_rx_napi. + +However","[' this is the responsibility of the caller of\nthe ndo_xdp_xmit (see for example bq_xmit_all in\nkernel/bpf/devmap.c) and thus calling it inside\nigc_xdp_xmit (which is the ndo_xdp_xmit of the igc\ndriver) as well will lead to memory corruption.\n\nIn fact', ' bq_xmit_all expects that it can return all\nframes after the last successfully transmitted one.\nTherefore', ' break for the first not transmitted frame', '\nbut do not call xdp_return_frame_rx_napi in igc_xdp_xmit.\nThis is equally implemented in other Intel drivers\nsuch as the igb.\n\nThere are two alternatives to this that were rejected:\n1. Return num_frames as all the frames would have been\n transmitted and release them inside igc_xdp_xmit.\n While it might work technically', ' it is not what\n the return value is meant to represent (i.e. the\n number of SUCCESSFULLY transmitted packets).\n2. Rework kernel/bpf/devmap.c and all drivers to\n support non-consecutively dropped packets.\n Besides being complex', ' it likely has a negative\n performance impact without a significant gain\n since it is anyway unlikely that the next frame\n can be transmitted if the previous one was dropped.\n\nThe memory corruption can be reproduced with\nthe following script which leads to a kernel panic\nafter a few seconds. It basically generates more\ntraffic than a i225 NIC can transmit and pushes it\nvia XDP_REDIRECT from a virtual interface to the\nphysical interface where frames get dropped.\n\n #!/bin/bash\n INTERFACE=enp4s0\n INTERFACE_IDX=`cat /sys/class/net/$INTERFACE/ifindex`\n\n sudo ip link add dev veth1 type veth peer name veth2\n sudo ip link set up $INTERFACE\n sudo ip link set up veth1\n sudo ip link set up veth2\n\n cat << EOF > redirect.bpf.c\n\n SEC(""prog"")\n int redirect(struct xdp_md *ctx)\n {\n return bpf_redirect($INTERFACE_IDX', ' 0);\n }\n\n char _license[] SEC(""license"") = ""GPL"";\n EOF\n clang -O2 -g -Wall -target bpf -c redirect.bpf.c -o redirect.bpf.o\n sudo ip link set veth2 xdp obj redirect.bpf.o\n\n cat << EOF > pass.bpf.c\n\n SEC(""prog"")\n int pass(struct xdp_md *ctx)\n {\n return XDP_PASS;\n }\n\n char _license[] SEC(""license"") = ""GPL"";\n EOF\n clang -O2 -g -Wall -target bpf -c pass.bpf.c -o pass.bpf.o\n sudo ip link set $INTERFACE xdp obj pass.bpf.o\n\n cat << EOF > trafgen.cfg\n\n {\n /* Ethernet Header */\n 0xe8', ' 0x6a', ' 0x64', ' 0x41', ' 0xbf', ' 0x46', '\n 0xFF', ' 0xFF', ' 0xFF', ' 0xFF', ' 0xFF', ' 0xFF', '\n const16(ETH_P_IP)', '\n\n /* IPv4 Header */\n 0b01000101', ' 0', ' # IPv4 version', ' IHL', ' TOS\n const16(1028)', ' # IPv4 total length (UDP length + 20 bytes (IP header))\n const16(2)', ' # IPv4 ident\n 0b01000000', ' 0', ' # IPv4 flags', ' fragmentation off\n 64', ' # IPv4 TTL\n 17', ' # Protocol UDP\n csumip(14', ' 33)', ' # IPv4 checksum\n\n /* UDP Header */\n 10', ' 0', ' 1', ' 1', ' # IP Src - adapt as needed\n 10', ' 0', ' 1', ' 2', ' # IP Dest - adapt as needed\n const16(6666)', ' # UDP Src Port\n const16(6666)', ' # UDP Dest Port\n const16(1008)', ' # UDP length (UDP header 8 bytes + payload length)\n csumudp(14', ' 34)', "" # UDP checksum\n\n /* Payload */\n fill('W'"", ' 1000)', '\n }\n EOF\n\n sudo trafgen -i trafgen.cfg -b3000MB -o veth1 --cpp\n\nFixes: 4ff320361092 (""igc: Add support for XDP_REDIRECT action"")\nSigned-off-by: Florian Kauer \nReviewed-by: Maciej Fijalkowski \nTested-by: Naama Meir \nSigned-off-by: Tony Nguyen \n', '']",Fix to prevent returning frame twice in XDP_REDIRECT when the transmission queue is full.,"XDP_REDIRECT,frame,transmit",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['xdp like programs'] +8f50d5c423551bfa259af792647a2f4799780ac5,8f50d5c423551bfa259af792647a2f4799780ac5,Martin KaFai Lau,martin.lau@kernel.org,1709248992,Martin KaFai Lau,martin.lau@kernel.org,1709590164,c3e977ac6a70cf40b315f9d84c42ad51b5d35799,01031fd473059bf69bb6edc6d51d4bd58ad92e50 93bc28d859e57f1a654d3b63600d14c85c5630a4,"Merge branch 'Allow struct_ops maps with a large number of programs' + +Kui-Feng Lee says: + +==================== +The BPF struct_ops previously only allowed for one page to be used for +the trampolines of all links in a map. However"," we have recently run +out of space due to the large number of BPF program links. By +allocating additional pages when we exhaust an existing page","[' we can\naccommodate more links in a single map.\n\nThe variable st_map->image has been changed to st_map->image_pages', '\nand its type has been changed to an array of pointers to buffers of\nPAGE_SIZE. Additional pages are allocated when all existing pages are\nexhausted.\n\nThe test case loads a struct_ops maps having 40 programs. Their\ntrampolines takes about 6.6k+ bytes over 1.5 pages on x86.\n---\nMajor differences from v3:\n\n - Refactor buffer allocations to bpf_struct_ops_tramp_buf_alloc() and\n bpf_struct_ops_tramp_buf_free().\n\nMajor differences from v2:\n\n - Move image buffer allocation to bpf_struct_ops_prepare_trampoline().\n\nMajor differences from v1:\n\n - Always free pages if failing to update.\n\n - Allocate 8 pages at most.\n\nv3: https://lore.kernel.org/all/20240224030302.1500343-1-thinker.li@gmail.com/\nv2: https://lore.kernel.org/all/20240221225911.757861-1-thinker.li@gmail.com/\nv1: https://lore.kernel.org/all/20240216182828.201727-1-thinker.li@gmail.com/\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",The commit allows struct_ops maps to support a larger number of BPF program links by allocating additional pages for trampolines.,"struct_ops maps, trampolines, BPF programs",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +93bc28d859e57f1a654d3b63600d14c85c5630a4,93bc28d859e57f1a654d3b63600d14c85c5630a4,Kui-Feng Lee,thinker.li@gmail.com,1708814058,Martin KaFai Lau,martin.lau@kernel.org,1709590164,c3e977ac6a70cf40b315f9d84c42ad51b5d35799,187e2af05abe6bf80581490239c449456627d17a,"selftests/bpf: Test struct_ops maps with a large number of struct_ops program. + +Create and load a struct_ops map with a large number of struct_ops +programs to generate trampolines taking a size over multiple pages. The +map includes 40 programs. Their trampolines takes 6.6k+"," more than 1.5 +pages","[' on x86.\n\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240224223418.526631-4-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",The commit tests struct_ops maps with many struct_ops programs generating large trampolines spanning multiple pages in selftests.,"struct_ops, trampolines, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +187e2af05abe6bf80581490239c449456627d17a,187e2af05abe6bf80581490239c449456627d17a,Kui-Feng Lee,thinker.li@gmail.com,1708814057,Martin KaFai Lau,martin.lau@kernel.org,1709590160,573c922b888bd957230d958b50a0756ce457262b,73e4f9e615d7b99f39663d4722dc73e8fa5db5f9,"bpf: struct_ops supports more than one page for trampolines. + +The BPF struct_ops previously only allowed one page of trampolines. +Each function pointer of a struct_ops is implemented by a struct_ops +bpf program. Each struct_ops bpf program requires a trampoline. +The following selftest patch shows each page can hold a little more +than 20 trampolines. + +While one page is more than enough for the tcp-cc usecase"," +the sched_ext use case shows that one page is not always enough and hits +the one page limit. This patch overcomes the one page limit by allocating +another page when needed and it is limited to a total of +MAX_IMAGE_PAGES (8) pages which is more than enough for +reasonable usages. + +The variable st_map->image has been changed to st_map->image_pages","[' and\nits type has been changed to an array of pointers to pages.\n\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240224223418.526631-3-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Increase the support for multiple pages in struct_ops trampolines to accommodate higher requirements.,"struct_ops,trampolines,pages",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +73e4f9e615d7b99f39663d4722dc73e8fa5db5f9,73e4f9e615d7b99f39663d4722dc73e8fa5db5f9,Kui-Feng Lee,thinker.li@gmail.com,1708814056,Martin KaFai Lau,martin.lau@kernel.org,1709575437,af6063b8367fde8327b948b44be205ca7817c50d,01031fd473059bf69bb6edc6d51d4bd58ad92e50,bpf," net: validate struct_ops when updating value. + +Perform all validations when updating values of struct_ops maps. Doing +validation in st_ops->reg() and st_ops->update() is not necessary anymore. +However","[' tcp_register_congestion_control() has been called in various\nplaces. It still needs to do validations.\n\nCc: netdev@vger.kernel.org\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240224223418.526631-2-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Perform validation of struct_ops maps on value updates instead of in reg and update functions.,"validate, struct_ops, update",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +01031fd473059bf69bb6edc6d51d4bd58ad92e50,01031fd473059bf69bb6edc6d51d4bd58ad92e50,Song Yoong Siang,yoong.siang.song@intel.com,1709454744,Daniel Borkmann,daniel@iogearbox.net,1709560919,05d146fce3abfe4cbf39785303e10518b4fd12e5,8f79870ec8a9409983ad5981e1b7d599cbf047bd,"selftests/bpf: xdp_hw_metadata reduce sleep interval + +In current ping-pong design"," xdp_hw_metadata will wait until the packet +transmission completely done","[' then only start to receive the next packet.\n\nThe current sleep interval is 10ms', ' which is unnecessary large. Typically', '\na NIC does not need such a long time to transmit a packet. Furthermore', '\nduring this 10ms sleep time', ' the app is unable to receive incoming packets.\n\nTherefore', ' this commit reduce sleep interval to 10us', ' so that\nxdp_hw_metadata is able to support periodic packets with shorter interval.\n10us * 500 = 5ms should be enough for packet transmission and status\nretrieval.\n\nSigned-off-by: Song Yoong Siang \nSigned-off-by: Daniel Borkmann \nAcked-by: John Fastabend \nAcked-by: Stanislav Fomichev \nLink: https://lore.kernel.org/bpf/20240303083225.1184165-2-yoong.siang.song@intel.com\n', '']",Reduce sleep interval in xdp_hw_metadata test to improve efficiency.,"xdp_hw_metadata,sleep,interval",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['xdp like programs'] +8f79870ec8a9409983ad5981e1b7d599cbf047bd,8f79870ec8a9409983ad5981e1b7d599cbf047bd,Andrii Nakryiko,andrii@kernel.org,1709329551,Daniel Borkmann,daniel@iogearbox.net,1709559624,70171da4dbc7892c20cf522a471ae8fe8baa156f,25703adf45f8430ec59effa20920c80139d13cdc,"selftests/bpf: Extend uprobe/uretprobe triggering benchmarks + +Settle on three ""flavors"" of uprobe/uretprobe"," installed on different +kinds of instruction: nop","[' push', ' and ret. All three are testing\ndifferent internal code paths emulating or single-stepping instructions', ""\nso are interesting to compare and benchmark separately.\n\nTo ensure `push rbp` instruction we ensure that uprobe_target_push() is\nnot a leaf function by calling (global __weak) noop function and\nreturning something afterwards (if we don't do that"", ' compiler will just\ndo a tail call optimization).\n\nAlso', "" we need to make sure that compiler isn't skipping frame pointer\ngeneration"", "" so let's add `-fno-omit-frame-pointers` to Makefile.\n\nJust to give an idea of where we currently stand in terms of relative\nperformance of different uprobe/uretprobe cases vs a cheap syscall\n(getpgid()) baseline"", ' here are results from my local machine:\n\n$ benchs/run_bench_uprobes.sh\nbase : 1.561 ± 0.020M/s\nuprobe-nop : 0.947 ± 0.007M/s\nuprobe-push : 0.951 ± 0.004M/s\nuprobe-ret : 0.443 ± 0.007M/s\nuretprobe-nop : 0.471 ± 0.013M/s\nuretprobe-push : 0.483 ± 0.004M/s\nuretprobe-ret : 0.306 ± 0.007M/s\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240301214551.1686095-1-andrii@kernel.org\n', '']",Extend uprobe/uretprobe benchmarks with different instruction types in selftests for BPF.,"uprobe, uretprobe, benchmarks",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +25703adf45f8430ec59effa20920c80139d13cdc,25703adf45f8430ec59effa20920c80139d13cdc,Chen Shen,peterchenshen@gmail.com,1709360538,Daniel Borkmann,daniel@iogearbox.net,1709559231,8f10e46244d15818ccb3a8159c91d7a9528419ee,0ef05e258b5e15c254534d9dd382ad4c3173dce0,"libbpf: Correct debug message in btf__load_vmlinux_btf + +In the function btf__load_vmlinux_btf"," the debug message incorrectly +refers to 'path' instead of 'sysfs_btf_path'. + +Signed-off-by: Chen Shen +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240302062218.3587-1-peterchenshen@gmail.com +",[''],Corrected debug message in btf__load_vmlinux_btf function to use correct path reference.,"libbpf,debug path,correction",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0ef05e258b5e15c254534d9dd382ad4c3173dce0,0ef05e258b5e15c254534d9dd382ad4c3173dce0,Dave Thaler,dthaler1968@googlemail.com,1709342549,Daniel Borkmann,daniel@iogearbox.net,1709559066,9684a0bf6aa2df7ff3a0d5fbe4607781282c9349,4e73e1bc1abf3181d57d6b8f1ab2a9f62a6a1a52,bpf," docs: Rename legacy conformance group to packet + +There could be other legacy conformance groups in the future","['\nso use a more descriptive name. The status of the conformance\ngroup in the IANA registry is what designates it as legacy', '\nnot the name of the group.\n\nSigned-off-by: Dave Thaler \nLink: https://lore.kernel.org/r/20240302012229.16452-1-dthaler1968@gmail.com\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Daniel Borkmann \n', '']",Renames legacy conformance group to packet in documentation.,"rename, conformance, packet",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +4e73e1bc1abf3181d57d6b8f1ab2a9f62a6a1a52,4e73e1bc1abf3181d57d6b8f1ab2a9f62a6a1a52,Dave Thaler,dthaler1968@googlemail.com,1709331817,Alexei Starovoitov,ast@kernel.org,1709444414,1cd1b5245f658de089a618834103c3340ab7e247,4b2765ae410abf01154cf97876384d8a58c43953,bpf," docs: Use IETF format for field definitions in instruction-set.rst + +In preparation for publication as an IETF RFC","[' the WG chairs asked me\nto convert the document to use IETF packet format for field layout', ' so\nthis patch attempts to make it consistent with other IETF documents.\n\nSome fields that are not byte aligned were previously inconsistent\nin how values were defined. Some were defined as the value of the\nbyte containing the field (like 0x20 for a field holding the high\nfour bits of the byte)', ' and others were defined as the value of the\nfield itself (like 0x2). This PR makes them be consistent in using\njust the values of the field itself', ' which is IETF convention.\n\nAs a result', ' some of the defines that used BPF_* would no longer\nmatch the value in the spec', ' and so this patch also drops the BPF_*\nprefix to avoid confusion with the defines that are the full-byte\nequivalent values. For consistency', ' BPF_* is then dropped from\nother fields too. BPF_ is thus the Linux implementation-specific\ndefine for as it appears in the BPF ISA specification.\n\nThe syntax BPF_ADD | BPF_X | BPF_ALU only worked for full-byte\nvalues so the convention {ADD', ' X', ' ALU} is proposed for referring\nto field values instead.\n\nAlso replace the redundant ""LSB bits"" with ""least significant bits"".\n\nA preview of what the resulting Internet Draft would look like can\nbe seen at:\nhttps://htmlpreview.github.io/?https://raw.githubusercontent.com/dthaler/ebp\nf-docs-1/format/draft-ietf-bpf-isa.html\n\nv1->v2: Fix sphinx issue as recommended by David Vernet\n\nSigned-off-by: Dave Thaler \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240301222337.15931-1-dthaler1968@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Updated instruction-set documentation to use IETF format for field definitions.,"documentation,IETF,RFC",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +4b2765ae410abf01154cf97876384d8a58c43953,4b2765ae410abf01154cf97876384d8a58c43953,Jakub Kicinski,kuba@kernel.org,1709441459,Jakub Kicinski,kuba@kernel.org,1709441459,6f5cdb7a5085b67c90244b2cbaeaa96bf401e17c,e960825709330cb199d209740326cec37e8c419d 0270d69121ba7fbc449a386f989b9b7b5eaebde3,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-02-29 + +We've added 119 non-merge commits during the last 32 day(s) which contain +a total of 150 files changed", 3589 insertions(+),"[' 995 deletions(-).\n\nThe main changes are:\n\n1) Extend the BPF verifier to enable static subprog calls in spin lock\n critical sections', ' from Kumar Kartikeya Dwivedi.\n\n2) Fix confusing and incorrect inference of PTR_TO_CTX argument type\n in BPF global subprogs', ' from Andrii Nakryiko.\n\n3) Larger batch of riscv BPF JIT improvements and enabling inlining\n of the bpf_kptr_xchg() for RV64', ' from Pu Lehui.\n\n4) Allow skeleton users to change the values of the fields in struct_ops\n maps at runtime', "" from Kui-Feng Lee.\n\n5) Extend the verifier's capabilities of tracking scalars when they\n are spilled to stack"", ' especially when the spill or fill is narrowing', '\n from Maxim Mikityanskiy & Eduard Zingerman.\n\n6) Various BPF selftest improvements to fix errors under gcc BPF backend', '\n from Jose E. Marchesi.\n\n7) Avoid module loading failure when the module trying to register\n a struct_ops has its BTF section stripped', ' from Geliang Tang.\n\n8) Annotate all kfuncs in .BTF_ids section which eventually allows\n for automatic kfunc prototype generation from bpftool', ' from Daniel Xu.\n\n9) Several updates to the instruction-set.rst IETF standardization\n document', ' from Dave Thaler.\n\n10) Shrink the size of struct bpf_map resp. bpf_array', '\n from Alexei Starovoitov.\n\n11) Initial small subset of BPF verifier prepwork for sleepable bpf_timer', ""\n from Benjamin Tissoires.\n\n12) Fix bpftool to be more portable to musl libc by using POSIX's\n basename()"", ' from Arnaldo Carvalho de Melo.\n\n13) Add libbpf support to gcc in CORE macro definitions', '\n from Cupertino Miranda.\n\n14) Remove a duplicate type check in perf_event_bpf_event', '\n from Florian Lehner.\n\n15) Fix bpf_spin_{un', '}lock BPF helpers to actually annotate them\n with notrace correctly', ' from Yonghong Song.\n\n16) Replace the deprecated bpf_lpm_trie_key 0-length array with flexible\n array to fix build warnings', ' from Kees Cook.\n\n17) Fix resolve_btfids cross-compilation to non host-native endianness', ""\n from Viktor Malik.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (119 commits)\n selftests/bpf: Test if shadow types work correctly.\n bpftool: Add an example for struct_ops map and shadow type.\n bpftool: Generated shadow variables for struct_ops maps.\n libbpf: Convert st_ops->data to shadow type.\n libbpf: Set btf_value_type_id of struct bpf_map for struct_ops.\n bpf: Replace bpf_lpm_trie_key 0-length array with flexible array\n bpf"", ' arm64: use bpf_prog_pack for memory management\n arm64: patching: implement text_poke API\n bpf', ' arm64: support exceptions\n arm64: stacktrace: Implement arch_bpf_stack_walk() for the BPF JIT\n bpf: add is_async_callback_calling_insn() helper\n bpf: introduce in_sleepable() helper\n bpf: allow more maps in sleepable bpf programs\n selftests/bpf: Test case for lacking CFI stub functions.\n bpf: Check cfi_stubs before registering a struct_ops type.\n bpf: Clarify batch lookup/lookup_and_delete semantics\n bpf', ' docs: specify which BPF_ABS and BPF_IND fields were zero\n bpf', ' docs: Fix typos in instruction-set.rst\n selftests/bpf: update tcp_custom_syncookie to use scalar packet offset\n bpf: Shrink size of struct bpf_map/bpf_array.\n ...\n====================\n\nLink: https://lore.kernel.org/r/20240301001625.8800-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merge various updates from the bpf-next branch affecting multiple files in the Linux kernel repository.,"merge, bpf-next, updates",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dd267d056fed323f1684fa52d2a864fc93ca3be0,dd267d056fed323f1684fa52d2a864fc93ca3be0,Ian Rogers,irogers@google.com,1709139929,Namhyung Kim,namhyung@kernel.org,1709258893,6e8213cf5cc7a7b670ed242b515c692ea9931c39,ec42d3d56819688537ec7ee37ce97f695fb8e6d7,"perf vendor events intel: Add umasks/occ_sel to PCU events. + +UMasks were being dropped leading to all PCU +UNC_P_POWER_STATE_OCCUPANCY events having the same encoding. Don't +drop the umask trying to be consistent with other sources of events +like libpfm4 [1]. Older models need to use occ_sel rather than umask"," +correct these values too. This applies the change from [2]. + +[1] https://sourceforge.net/p/perfmon2/libpfm4/ci/master/tree/lib/events/intel_skx_unc_pcu_events.h#l30 +[2] https://github.com/captain5050/perfmon/commit/cbd4aee81023e5bfa09677b1ce170ff69e9c423d + +Signed-off-by: Ian Rogers +Reviewed-by: Kan Liang +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240228170529.4035675-1-irogers@google.com +",[''],Fix PCU event encoding by adding umasks/occ_sel for better consistency in perf vendor events on Intel.,"PCU,umasks,events",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +0270d69121ba7fbc449a386f989b9b7b5eaebde3,0270d69121ba7fbc449a386f989b9b7b5eaebde3,Andrii Nakryiko,andrii@kernel.org,1709243646,Andrii Nakryiko,andrii@kernel.org,1709245447,524cfad5f7755ea83210ec355b43fa650219b237,896880ff30866f386ebed14ab81ce1ad3710cfc4 0623e73317940d052216fb6eef4efd55a0a7f602,"Merge branch 'create-shadow-types-for-struct_ops-maps-in-skeletons' + +Kui-Feng Lee says: + +==================== +Create shadow types for struct_ops maps in skeletons + +This patchset allows skeleton users to change the values of the fields +in struct_ops maps at runtime. It will create a shadow type pointer in +a skeleton for each struct_ops map"," allowing users to access the +values of fields through these pointers. For instance","[' if there is an\ninteger field named ""FOO"" in a struct_ops map called ""testmap""', ' you\ncan access the value of ""FOO"" in this way.\n\n skel->struct_ops.testmap->FOO = 13;\n\nWith this feature', ' the users can pass flags or other data along with\nthe map from the user space to the kernel without creating separate\nstruct_ops map for different values in BPF.\n\n== Shadow Type ==\n\nThe shadow type of a struct_ops map is a variant of the original\nstruct type of the map. The code generator translates each field in\nthe original struct type to a field in the shadow type. The type of a\nfield in the shadow type may not be the same as the corresponding\nfield in the original struct type. For example', ' modifiers like\nvolatile', ' const', ' etc.', ' are removed from the fields in a shadow\ntype. Function pointers are translated to pointers of struct\nbpf_program.\n\nCurrently', ' only scalar types and function pointers are\nsupported. Fields belonging to structs', ' unions', ' non-function pointers', '\narrays', ' or other types are not supported. For those unsupported\nfields', ' they are converted to arrays of characters to preserve their\nspace within the original struct type.\n\nThe padding between consecutive fields is handled by padding fields\n(__padding_*). This helps to maintain the memory layout consistent\nwith the original struct_type.\n\nHere is an example of shadow types.\nThe origin struct type of a struct_ops map is\n\n struct bpf_testmod_ops {\n \tint (*test_1)(void);\n \tvoid (*test_2)(int a', ' int b);\n \t/* Used to test nullable arguments. */\n \tint (*test_maybe_null)(int dummy', ' struct task_struct *task);\n\n \t/* The following fields are used to test shadow copies. */\n \tchar onebyte;\n \tstruct {\n \t\tint a;\n \t\tint b;\n \t} unsupported;\n \tint data;\n };\n\nThe struct_ops map', ' named testmod_1', ' of this type will be translated\nto a pointer in the shadow type.\n\n struct {\n \tstruct my_skel__testmod_1__bpf_testmod_ops {\n \t\tconst struct bpf_program *test_1;\n \t\tconst struct bpf_program *test_2;\n \t\tconst struct bpf_program *test_maybe_null;\n \t\tchar onebyte;\n \t\tchar __padding_4[3];\n \t\tchar __unsupported_4[8];\n \t\tint data;\n \t} *testmod_1;\n } struct_ops;\n\n== Convert st_ops->data to Shadow Type ==\n\nlibbpf converts st_ops->data to the format of the shadow type for each\nstruct_ops map. This means that the bytes where function pointers are\nlocated are converted to the values of the pointers of struct\nbpf_program. The fields of other types are kept as they were.\n\nLibbpf will synchronize the pointers of struct bpf_program with\nst_ops->progs[] so that users can change function pointers\n(bpf_program) before loading the map.\n---\nChanges from v5:\n\n - Generate names for shadow types.\n\n - Check btf and the number of struct_ops maps in gen_st_ops_shadow()\n and gen_st_ops_shadow_init() instead of do_skeleton() and\n do_subskeleton().\n\n - Name unsupported fields in the pattern __unsupported_*.\n\n - Have a padding field for a unsupported fields as well if necessary.\n\n - Implement resolve_func_ptr() in gen.c instead of reusing the one in\n libbpf. (Remove the part 1 in v4.)\n\n - Fix stylistic issues.\n\nChanges from v4:\n\n - Convert function pointers to the pointers to struct bpf_program in\n bpf_object__collect_st_ops_relos().\n\nChanges from v3:\n\n - Add comment to avoid people from removing resolve_func_ptr() from\n libbpf_internal.h\n\n - Fix commit logs and comments.\n\n - Add an example about using the pointers of shadow types\n for struct_ops maps to bpftool-gen.8.\n\nv5: https://lore.kernel.org/all/20240227010432.714127-1-thinker.li@gmail.com/\nv4: https://lore.kernel.org/all/20240222222624.1163754-1-thinker.li@gmail.com/\nv3: https://lore.kernel.org/all/20240221012329.1387275-1-thinker.li@gmail.com/\nv2: https://lore.kernel.org/all/20240214020836.1845354-1-thinker.li@gmail.com/\nv1: https://lore.kernel.org/all/20240124224130.859921-1-thinker.li@gmail.com/\n\nKui-Feng Lee (5):\n libbpf: set btf_value_type_id of struct bpf_map for struct_ops.\n libbpf: Convert st_ops->data to shadow type.\n bpftool: generated shadow variables for struct_ops maps.\n bpftool: Add an example for struct_ops map and shadow type.\n selftests/bpf: Test if shadow types work correctly.\n\n .../bpf/bpftool/Documentation/bpftool-gen.rst | 58 ++++-\n tools/bpf/bpftool/gen.c | 237 +++++++++++++++++-\n tools/lib/bpf/libbpf.c | 50 +++-\n .../selftests/bpf/bpf_testmod/bpf_testmod.c | 11 +-\n .../selftests/bpf/bpf_testmod/bpf_testmod.h | 8 +\n .../bpf/prog_tests/test_struct_ops_module.c | 19 +-\n .../selftests/bpf/progs/struct_ops_module.c | 8 +\n 7 files changed', ' 377 insertions(+)', ' 14 deletions(-)\n====================\n\nLink: https://lore.kernel.org/r/20240229064523.2091270-1-thinker.li@gmail.com\nSigned-off-by: Andrii Nakryiko \n', '']",The commit introduces shadow types for struct_ops maps to allow runtime modifications in skeletons.,"shadow types, struct_ops, skeletons",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0623e73317940d052216fb6eef4efd55a0a7f602,0623e73317940d052216fb6eef4efd55a0a7f602,Kui-Feng Lee,thinker.li@gmail.com,1709189123,Andrii Nakryiko,andrii@kernel.org,1709245433,524cfad5f7755ea83210ec355b43fa650219b237,f2e81192e07e87897ff1296c96775eceea8f582a,"selftests/bpf: Test if shadow types work correctly. + +Change the values of fields", including scalar types and function pointers,"['\nand check if the struct_ops map works as expected.\n\nThe test changes the field ""test_2"" of ""testmod_1"" from the pointer to\ntest_2() to pointer to test_3() and the field ""data"" to 13. The function\ntest_2() and test_3() both compute a new value for ""test_2_result""', ' but in\ndifferent way. By checking the value of ""test_2_result""', ' it ensures the\nstruct_ops map works as expected with changes through shadow types.\n\nSigned-off-by: Kui-Feng Lee \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240229064523.2091270-6-thinker.li@gmail.com\n', '']",The commit adds selftests for verifying the correct functionality of shadow types in BPF programs.,"selftests, shadow types, BPF",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f2e81192e07e87897ff1296c96775eceea8f582a,f2e81192e07e87897ff1296c96775eceea8f582a,Kui-Feng Lee,thinker.li@gmail.com,1709189122,Andrii Nakryiko,andrii@kernel.org,1709245433,39d67b886bcd562accc2b99f99d9c9c5f85e5855,a7b0fa352eafef95bd0d736ca94965d3f884ad18,"bpftool: Add an example for struct_ops map and shadow type. + +The example in bpftool-gen.8 explains how to use the pointer of the shadow +type to change the value of a field of a struct_ops map. + +Signed-off-by: Kui-Feng Lee +Signed-off-by: Andrii Nakryiko +Reviewed-by: Quentin Monnet +Link: https://lore.kernel.org/bpf/20240229064523.2091270-5-thinker.li@gmail.com +",,The commit adds an example in bpftool-gen for using the shadow type in struct_ops maps.,"bpftool, struct_ops, shadow type",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a7b0fa352eafef95bd0d736ca94965d3f884ad18,a7b0fa352eafef95bd0d736ca94965d3f884ad18,Kui-Feng Lee,thinker.li@gmail.com,1709189121,Andrii Nakryiko,andrii@kernel.org,1709245433,ed6217fb23ed793a284adf35e6b749505e0acdea,69e4a9d2b3f5adf5af4feeab0a9f505da971265a,"bpftool: Generated shadow variables for struct_ops maps. + +Declares and defines a pointer of the shadow type for each struct_ops map. + +The code generator will create an anonymous struct type as the shadow type +for each struct_ops map. The shadow type is translated from the original +struct type of the map. The user of the skeleton use pointers of them to +access the values of struct_ops maps. + +However", shadow types only supports certain types of fields,"[' including\nscalar types and function pointers. Any fields of unsupported types are\ntranslated into an array of characters to occupy the space of the original\nfield. Function pointers are translated into pointers of the struct\nbpf_program. Additionally', ' padding fields are generated to occupy the space\nbetween two consecutive fields.\n\nThe pointers of shadow types of struct_osp maps are initialized when\n*__open_opts() in skeletons are called. For a map called FOO', ' the user can\naccess it through the pointer at skel->struct_ops.FOO.\n\nSigned-off-by: Kui-Feng Lee \nSigned-off-by: Andrii Nakryiko \nReviewed-by: Quentin Monnet \nLink: https://lore.kernel.org/bpf/20240229064523.2091270-4-thinker.li@gmail.com\n', '']",Introduced shadow variable generation for struct_ops maps in bpftool.,"shadow, struct_ops, bpftool",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +69e4a9d2b3f5adf5af4feeab0a9f505da971265a,69e4a9d2b3f5adf5af4feeab0a9f505da971265a,Kui-Feng Lee,thinker.li@gmail.com,1709189120,Andrii Nakryiko,andrii@kernel.org,1709245432,0b044a41286a8648b98c65ca50b1ccb20b9dadb9,3644d285462a60c80ac225d508fcfe705640d2b4,"libbpf: Convert st_ops->data to shadow type. + +Convert st_ops->data to the shadow type of the struct_ops map. The shadow +type of a struct_ops type is a variant of the original struct type +providing a way to access/change the values in the maps of the struct_ops +type. + +bpf_map__initial_value() will return st_ops->data for struct_ops types. The +skeleton is going to use it as the pointer to the shadow type of the +original struct type. + +One of the main differences between the original struct type and the shadow +type is that all function pointers of the shadow type are converted to +pointers of struct bpf_program. Users can replace these bpf_program +pointers with other BPF programs. The st_ops->progs[] will be updated +before updating the value of a map to reflect the changes made by users. + +Signed-off-by: Kui-Feng Lee +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240229064523.2091270-3-thinker.li@gmail.com +",,Convert struct_ops data to a shadow type allowing modified program pointers in libbpf.,"libbpf,shadow,struct_ops",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3644d285462a60c80ac225d508fcfe705640d2b4,3644d285462a60c80ac225d508fcfe705640d2b4,Kui-Feng Lee,thinker.li@gmail.com,1709189119,Andrii Nakryiko,andrii@kernel.org,1709245432,1c08efa523718f023f462628a0aeb61797e007e4,896880ff30866f386ebed14ab81ce1ad3710cfc4,"libbpf: Set btf_value_type_id of struct bpf_map for struct_ops. + +For a struct_ops map"," btf_value_type_id is the type ID of it's struct +type. This value is required by bpftool to generate skeleton including +pointers of shadow types. The code generator gets the type ID from +bpf_map__btf_value_type_id() in order to get the type information of the +struct type of a map. + +Signed-off-by: Kui-Feng Lee +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240229064523.2091270-2-thinker.li@gmail.com +",[''],Set btf_value_type_id for struct_ops in bpf_map to enable bpftool skeleton generation.,"libbpf,bpf_map,btf_value_type_id",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"[""It's not related to any of the above.""]" +b44d66536859393772c67cb1da65345127f692e0,b44d66536859393772c67cb1da65345127f692e0,Namhyung Kim,namhyung@kernel.org,1709098415,Namhyung Kim,namhyung@kernel.org,1709243636,4b0a7da48fdc47ae727eeef00f83bf2a7509dd18,97b6b4ac1c5dd42a473a4f8e775d97476c5da038,"perf lock contention: Account contending locks too + +Currently it accounts the contention using delta between timestamps in +lock:contention_begin and lock:contention_end tracepoints. But it means +the lock should see the both events during the monitoring period. + +Actually there are 4 cases that happen with the monitoring: + + monitoring period + / \ + | | + 1: B------+-----------------------+--------E + 2: B----+-------------E | + 3: | B-----------+----E + 4: | B-------------E | + | | + t0 t1 + +where B and E mean contention BEGIN and END"," respectively. So it only +accounts the case 4 for now. It seems there's no way to handle the case +1. The case 2 might be handled if it saved the timestamp (t0)","[' but it\nlacks the information from the B notably the flags which shows the lock\ntypes. Also it could be a nested lock which it currently ignores. So\nI think we should ignore the case 2.\n\nHowever we can handle the case 3 if we save the timestamp (t1) at the\nend of the period. And then it can iterate the map entries in the\nuserspace and update the lock stat accordinly.\n\nSigned-off-by: Namhyung Kim \nReviewed-by: Ian Rogers \nReviwed-by: Arnaldo Carvalho de Melo \nCc: Song Liu \nCc: bpf@vger.kernel.org\nLink: https://lore.kernel.org/r/20240228053335.312776-1-namhyung@kernel.org\n', '']",Enhance lock contention accounting by handling additional cases in the monitoring period.,"lock,contention,accounting",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +896880ff30866f386ebed14ab81ce1ad3710cfc4,896880ff30866f386ebed14ab81ce1ad3710cfc4,Kees Cook,keescook@chromium.org,1708617375,Daniel Borkmann,daniel@iogearbox.net,1709243563,376f9437aae34eb8c1216a1d22c576cda2eabbec,b9a62998482fa1488123f690bcacc26fd2351a18,"bpf: Replace bpf_lpm_trie_key 0-length array with flexible array + +Replace deprecated 0-length array in struct bpf_lpm_trie_key with +flexible array. Found with GCC 13: + +../kernel/bpf/lpm_trie.c:207:51: warning: array subscript i is outside array bounds of 'const __u8[0]' {aka 'const unsigned char[]'} [-Warray-bounds=] + 207 | *(__be16 *)&key->data[i]); + | ^~~~~~~~~~~~~ +../include/uapi/linux/swab.h:102:54: note: in definition of macro '__swab16' + 102 | #define __swab16(x) (__u16)__builtin_bswap16((__u16)(x)) + | ^ +../include/linux/byteorder/generic.h:97:21: note: in expansion of macro '__be16_to_cpu' + 97 | #define be16_to_cpu __be16_to_cpu + | ^~~~~~~~~~~~~ +../kernel/bpf/lpm_trie.c:206:28: note: in expansion of macro 'be16_to_cpu' + 206 | u16 diff = be16_to_cpu(*(__be16 *)&node->data[i] +^ + | ^~~~~~~~~~~ +In file included from ../include/linux/bpf.h:7: +../include/uapi/linux/bpf.h:82:17: note: while referencing 'data' + 82 | __u8 data[0]; /* Arbitrary size */ + | ^~~~ + +And found at run-time under CONFIG_FORTIFY_SOURCE: + + UBSAN: array-index-out-of-bounds in kernel/bpf/lpm_trie.c:218:49 + index 0 is out of range for type '__u8 [*]' + +Changing struct bpf_lpm_trie_key is difficult since has been used by +userspace. For example"," in Cilium: + + struct egress_gw_policy_key { + struct bpf_lpm_trie_key lpm_key; + __u32 saddr; + __u32 daddr; + }; + +While direct references to the ""data"" member haven't been found","[' there\nare static initializers what include the final member. For example', '\nthe ""{}"" here:\n\n struct egress_gw_policy_key in_key = {\n .lpm_key = { 32 + 24', ' {} }', '\n .saddr = CLIENT_IP', '\n .daddr = EXTERNAL_SVC_IP & 0Xffffff', '\n };\n\nTo avoid the build time and run time warnings seen with a 0-sized\ntrailing array for struct bpf_lpm_trie_key', ' introduce a new struct\nthat correctly uses a flexible array for the trailing bytes', '\nstruct bpf_lpm_trie_key_u8. As part of this', ' include the ""header""\nportion (which is just the ""prefixlen"" member)', "" so it can be used\nby anything building a bpf_lpr_trie_key that has trailing members that\naren't a u8 flexible array (like the self-test[1])"", ' which is named\nstruct bpf_lpm_trie_key_hdr.\n\nUnfortunately', ' C++ refuses to parse the __struct_group() helper', ' so\nit is not possible to define struct bpf_lpm_trie_key_hdr directly in\nstruct bpf_lpm_trie_key_u8', ' so we must open-code the union directly.\n\nAdjust the kernel code to use struct bpf_lpm_trie_key_u8 through-out', '\nand for the selftest to use struct bpf_lpm_trie_key_hdr. Add a comment\nto the UAPI header directing folks to the two new options.\n\nReported-by: Mark Rutland \nSigned-off-by: Kees Cook \nSigned-off-by: Daniel Borkmann \nAcked-by: Gustavo A. R. Silva \nCloses: https://paste.debian.net/hidden/ca500597/\nLink: https://lore.kernel.org/all/202206281009.4332AA33@keescook/ [1]\nLink: https://lore.kernel.org/bpf/20240222155612.it.533-kees@kernel.org\n', '']",Replaced deprecated 0-length array with a flexible array in bpf_lpm_trie_key to address GCC warnings and runtime issues.,"flexible array, 0-length array, bpf_lpm_trie_key",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8f5afe41148ce6a719864e23c2bf776c88e9212f,8f5afe41148ce6a719864e23c2bf776c88e9212f,Jakub Kicinski,kuba@kernel.org,1709226438,Jakub Kicinski,kuba@kernel.org,1709226439,edca5dcec127fc1268a474167cafa13303931f9e,616d82c3cfa2a2146dd7e3ae47bda7e877ee549e 13114dc5543069f7b97991e3b79937b6da05f5b0,"Merge branch 'tls-a-few-more-fixes-for-async-decrypt' + +Sabrina Dubroca says: + +==================== +tls: a few more fixes for async decrypt + +The previous patchset [1] took care of ""full async"". This adds a few +fixes for cases where only part of the crypto operations go the async +route"," found by extending my previous debug patch [2] to do N +synchronous operations followed by M asynchronous ops (with N and M +configurable). + +[1] https://patchwork.kernel.org/project/netdevbpf/list/?series=823784&state=* +[2] https://lore.kernel.org/all/9d664093b1bf7f47497b2c40b3a085b45f3274a2.1694021240.git.sd@queasysnail.net/ +==================== + +Link: https://lore.kernel.org/r/cover.1709132643.git.sd@queasysnail.net +Signed-off-by: Jakub Kicinski +",[''],This commit merges several bug fixes for TLS asynchronous decryption pathways.,"TLS, async, decrypt",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +616d82c3cfa2a2146dd7e3ae47bda7e877ee549e,616d82c3cfa2a2146dd7e3ae47bda7e877ee549e,Alexander Ofitserov,oficerovas@altlinux.org,1709120823,Paolo Abeni,pabeni@redhat.com,1709212458,e4bbcfe533367900aeee0d8677d88362a2e4e2c6,b611b776a9c89a86e57ea6dbf8adfc99c6e8a62e,"gtp: fix use-after-free and null-ptr-deref in gtp_newlink() + +The gtp_link_ops operations structure for the subsystem must be +registered after registering the gtp_net_ops pernet operations structure. + +Syzkaller hit 'general protection fault in gtp_genl_dump_pdp' bug: + +[ 1010.702740] gtp: GTP module unloaded +[ 1010.715877] general protection fault"," probably for non-canonical address 0xdffffc0000000001: 0000 [#1] SMP KASAN NOPTI +[ 1010.715888] KASAN: null-ptr-deref in range [0x0000000000000008-0x000000000000000f] +[ 1010.715895] CPU: 1 PID: 128616 Comm: a.out Not tainted 6.8.0-rc6-std-def-alt1 #1 +[ 1010.715899] Hardware name: QEMU Standard PC (Q35 + ICH9","[' 2009)', ' BIOS 1.16.0-alt1 04/01/2014\n[ 1010.715908] RIP: 0010:gtp_newlink+0x4d7/0x9c0 [gtp]\n[ 1010.715915] Code: 80 3c 02 00 0f 85 41 04 00 00 48 8b bb d8 05 00 00 e8 ed f6 ff ff 48 89 c2 48 89 c5 48 b8 00 00 00 00 00 fc ff df 48 c1 ea 03 <80> 3c 02 00 0f 85 4f 04 00 00 4c 89 e2 4c 8b 6d 00 48 b8 00 00 00\n[ 1010.715920] RSP: 0018:ffff888020fbf180 EFLAGS: 00010203\n[ 1010.715929] RAX: dffffc0000000000 RBX: ffff88800399c000 RCX: 0000000000000000\n[ 1010.715933] RDX: 0000000000000001 RSI: ffffffff84805280 RDI: 0000000000000282\n[ 1010.715938] RBP: 000000000000000d R08: 0000000000000001 R09: 0000000000000000\n[ 1010.715942] R10: 0000000000000001 R11: 0000000000000001 R12: ffff88800399cc80\n[ 1010.715947] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000400\n[ 1010.715953] FS: 00007fd1509ab5c0(0000) GS:ffff88805b300000(0000) knlGS:0000000000000000\n[ 1010.715958] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033\n[ 1010.715962] CR2: 0000000000000000 CR3: 000000001c07a000 CR4: 0000000000750ee0\n[ 1010.715968] PKRU: 55555554\n[ 1010.715972] Call Trace:\n[ 1010.715985] ? __die_body.cold+0x1a/0x1f\n[ 1010.715995] ? die_addr+0x43/0x70\n[ 1010.716002] ? exc_general_protection+0x199/0x2f0\n[ 1010.716016] ? asm_exc_general_protection+0x1e/0x30\n[ 1010.716026] ? gtp_newlink+0x4d7/0x9c0 [gtp]\n[ 1010.716034] ? gtp_net_exit+0x150/0x150 [gtp]\n[ 1010.716042] __rtnl_newlink+0x1063/0x1700\n[ 1010.716051] ? rtnl_setlink+0x3c0/0x3c0\n[ 1010.716063] ? is_bpf_text_address+0xc0/0x1f0\n[ 1010.716070] ? kernel_text_address.part.0+0xbb/0xd0\n[ 1010.716076] ? __kernel_text_address+0x56/0xa0\n[ 1010.716084] ? unwind_get_return_address+0x5a/0xa0\n[ 1010.716091] ? create_prof_cpu_mask+0x30/0x30\n[ 1010.716098] ? arch_stack_walk+0x9e/0xf0\n[ 1010.716106] ? stack_trace_save+0x91/0xd0\n[ 1010.716113] ? stack_trace_consume_entry+0x170/0x170\n[ 1010.716121] ? __lock_acquire+0x15c5/0x5380\n[ 1010.716139] ? mark_held_locks+0x9e/0xe0\n[ 1010.716148] ? kmem_cache_alloc_trace+0x35f/0x3c0\n[ 1010.716155] ? __rtnl_newlink+0x1700/0x1700\n[ 1010.716160] rtnl_newlink+0x69/0xa0\n[ 1010.716166] rtnetlink_rcv_msg+0x43b/0xc50\n[ 1010.716172] ? rtnl_fdb_dump+0x9f0/0x9f0\n[ 1010.716179] ? lock_acquire+0x1fe/0x560\n[ 1010.716188] ? netlink_deliver_tap+0x12f/0xd50\n[ 1010.716196] netlink_rcv_skb+0x14d/0x440\n[ 1010.716202] ? rtnl_fdb_dump+0x9f0/0x9f0\n[ 1010.716208] ? netlink_ack+0xab0/0xab0\n[ 1010.716213] ? netlink_deliver_tap+0x202/0xd50\n[ 1010.716220] ? netlink_deliver_tap+0x218/0xd50\n[ 1010.716226] ? __virt_addr_valid+0x30b/0x590\n[ 1010.716233] netlink_unicast+0x54b/0x800\n[ 1010.716240] ? netlink_attachskb+0x870/0x870\n[ 1010.716248] ? __check_object_size+0x2de/0x3b0\n[ 1010.716254] netlink_sendmsg+0x938/0xe40\n[ 1010.716261] ? netlink_unicast+0x800/0x800\n[ 1010.716269] ? __import_iovec+0x292/0x510\n[ 1010.716276] ? netlink_unicast+0x800/0x800\n[ 1010.716284] __sock_sendmsg+0x159/0x190\n[ 1010.716290] ____sys_sendmsg+0x712/0x880\n[ 1010.716297] ? sock_write_iter+0x3d0/0x3d0\n[ 1010.716304] ? __ia32_sys_recvmmsg+0x270/0x270\n[ 1010.716309] ? lock_acquire+0x1fe/0x560\n[ 1010.716315] ? drain_array_locked+0x90/0x90\n[ 1010.716324] ___sys_sendmsg+0xf8/0x170\n[ 1010.716331] ? sendmsg_copy_msghdr+0x170/0x170\n[ 1010.716337] ? lockdep_init_map_type+0x2c7/0x860\n[ 1010.716343] ? lockdep_hardirqs_on_prepare+0x430/0x430\n[ 1010.716350] ? debug_mutex_init+0x33/0x70\n[ 1010.716360] ? percpu_counter_add_batch+0x8b/0x140\n[ 1010.716367] ? lock_acquire+0x1fe/0x560\n[ 1010.716373] ? find_held_lock+0x2c/0x110\n[ 1010.716384] ? __fd_install+0x1b6/0x6f0\n[ 1010.716389] ? lock_downgrade+0x810/0x810\n[ 1010.716396] ? __fget_light+0x222/0x290\n[ 1010.716403] __sys_sendmsg+0xea/0x1b0\n[ 1010.716409] ? __sys_sendmsg_sock+0x40/0x40\n[ 1010.716419] ? lockdep_hardirqs_on_prepare+0x2b3/0x430\n[ 1010.716425] ? syscall_enter_from_user_mode+0x1d/0x60\n[ 1010.716432] do_syscall_64+0x30/0x40\n[ 1010.716438] entry_SYSCALL_64_after_hwframe+0x62/0xc7\n[ 1010.716444] RIP: 0033:0x7fd1508cbd49\n[ 1010.716452] Code: 00 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d ef 70 0d 00 f7 d8 64 89 01 48\n[ 1010.716456] RSP: 002b:00007fff18872348 EFLAGS: 00000202 ORIG_RAX: 000000000000002e\n[ 1010.716463] RAX: ffffffffffffffda RBX: 000055f72bf0eac0 RCX: 00007fd1508cbd49\n[ 1010.716468] RDX: 0000000000000000 RSI: 0000000020000280 RDI: 0000000000000006\n[ 1010.716473] RBP: 00007fff18872360 R08: 00007fff18872360 R09: 00007fff18872360\n[ 1010.716478] R10: 00007fff18872360 R11: 0000000000000202 R12: 000055f72bf0e1b0\n[ 1010.716482] R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000\n[ 1010.716491] Modules linked in: gtp(+) udp_tunnel ib_core uinput af_packet rfkill qrtr joydev hid_generic usbhid hid kvm_intel iTCO_wdt intel_pmc_bxt iTCO_vendor_support kvm snd_hda_codec_generic ledtrig_audio irqbypass crct10dif_pclmul crc32_pclmul crc32c_intel ghash_clmulni_intel snd_hda_intel nls_utf8 snd_intel_dspcfg nls_cp866 psmouse aesni_intel vfat crypto_simd fat cryptd glue_helper snd_hda_codec pcspkr snd_hda_core i2c_i801 snd_hwdep i2c_smbus xhci_pci snd_pcm lpc_ich xhci_pci_renesas xhci_hcd qemu_fw_cfg tiny_power_button button sch_fq_codel vboxvideo drm_vram_helper drm_ttm_helper ttm vboxsf vboxguest snd_seq_midi snd_seq_midi_event snd_seq snd_rawmidi snd_seq_device snd_timer snd soundcore msr fuse efi_pstore dm_mod ip_tables x_tables autofs4 virtio_gpu virtio_dma_buf drm_kms_helper cec rc_core drm virtio_rng virtio_scsi rng_core virtio_balloon virtio_blk virtio_net virtio_console net_failover failover ahci libahci libata evdev scsi_mod input_leds serio_raw virtio_pci intel_agp\n[ 1010.716674] virtio_ring intel_gtt virtio [last unloaded: gtp]\n[ 1010.716693] ---[ end trace 04990a4ce61e174b ]---\n\nCc: stable@vger.kernel.org\nSigned-off-by: Alexander Ofitserov \nFixes: 459aa660eb1d (""gtp: add initial driver for datapath of GPRS Tunneling Protocol (GTP-U)"")\nReviewed-by: Jiri Pirko \nLink: https://lore.kernel.org/r/20240228114703.465107-1-oficerovas@altlinux.org\nSigned-off-by: Paolo Abeni \n', '']",Fix use-after-free and null-pointer dereference in gtp_newlink function registration sequence.,"gtp, use-after-free, null-ptr-deref",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +7e0f122c65912740327e4c54472acaa5f85868cb,7e0f122c65912740327e4c54472acaa5f85868cb,Ignat Korchagin,ignat@cloudflare.com,1708597988,Pablo Neira Ayuso,pablo@netfilter.org,1709160775,140f28e24c7fc3a0fc090e356c0bb6054d3288de,359e54a93ab43d32ee1bff3c2f9f10cb9f6b6e79,"netfilter: nf_tables: allow NFPROTO_INET in nft_(match/target)_validate() + +Commit d0009effa886 (""netfilter: nf_tables: validate NFPROTO_* family"") added +some validation of NFPROTO_* families in the nft_compat module"," but it broke +the ability to use legacy iptables modules in dual-stack nftables. + +While with legacy iptables one had to independently manage IPv4 and IPv6 +tables","[' with nftables it is possible to have dual-stack tables sharing the\nrules. Moreover', ' it was possible to use rules based on legacy iptables\nmatch/target modules in dual-stack nftables.\n\nAs an example', ' the program from [2] creates an INET dual-stack family table\nusing an xt_bpf based rule', ' which looks like the following (the actual output\nwas generated with a patched nft tool as the current nft tool does not parse\ndual stack tables with legacy match rules', ' so consider it for illustrative\npurposes only):\n\ntable inet testfw {\n chain input {\n type filter hook prerouting priority filter; policy accept;\n bytecode counter packets 0 bytes 0 accept\n }\n}\n\nAfter d0009effa886 (""netfilter: nf_tables: validate NFPROTO_* family"") we get\nEOPNOTSUPP for the above program.\n\nFix this by allowing NFPROTO_INET for nft_(match/target)_validate()', ' but also\nrestrict the functions to classic iptables hooks.\n\nChanges in v3:\n * clarify that upstream nft will not display such configuration properly and\n that the output was generated with a patched nft tool\n * remove example program from commit description and link to it instead\n * no code changes otherwise\n\nChanges in v2:\n * restrict nft_(match/target)_validate() to classic iptables hooks\n * rewrite example program to use unmodified libnftnl\n\nFixes: d0009effa886 (""netfilter: nf_tables: validate NFPROTO_* family"")\nLink: https://lore.kernel.org/all/Zc1PfoWN38UuFJRI@calendula/T/#mc947262582c90fec044c7a3398cc92fac7afea72 [1]\nLink: https://lore.kernel.org/all/20240220145509.53357-1-ignat@cloudflare.com/ [2]\nReported-by: Jordan Griege \nSigned-off-by: Ignat Korchagin \nSigned-off-by: Pablo Neira Ayuso \n', '']",Fix allows NFPROTO_INET use in nft_(match/target)_validate to support dual-stack nftables.,"NFPROTO_INET, dual-stack, nftables",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['tc/netfilter like programs'] +b9a62998482fa1488123f690bcacc26fd2351a18,b9a62998482fa1488123f690bcacc26fd2351a18,Alexei Starovoitov,ast@kernel.org,1709156688,Alexei Starovoitov,ast@kernel.org,1709156688,5811a3a6deb3825618a7d1a0577df5170871de2a,e59997d9052599feb17419289f2a57ed300e1dfa 1dad391daef129e01e28206b8d586608ff026548,"Merge branch 'bpf-arm64-use-bpf-prog-pack-allocator-in-bpf-jit' + +Puranjay Mohan says: + +==================== +bpf"," arm64: use BPF prog pack allocator in BPF JIT + +Changes in V8 => V9: +V8: https://lore.kernel.org/bpf/20240221145106.105995-1-puranjay12@gmail.com/ +1. Rebased on bpf-next/master +2. Added Acked-by: Catalin Marinas + +Changes in V7 => V8: +V7: https://lore.kernel.org/bpf/20240125133159.85086-1-puranjay12@gmail.com/ +1. Rebase on bpf-next/master +2. Fix __text_poke() by removing usage of 'ret' that was never set. + +Changes in V6 => V7: +V6: https://lore.kernel.org/all/20240124164917.119997-1-puranjay12@gmail.com/ +1. Rebase on bpf-next/master. + +Changes in V5 => V6: +V5: https://lore.kernel.org/all/20230908144320.2474-1-puranjay12@gmail.com/ +1. Implement a text poke api to reduce code repeatition. +2. Use flush_icache_range() in place of caches_clean_inval_pou() in the + functions that modify code. +3. Optimize the bpf_jit_free() by not copying the all instructions on + the rw image to the ro_image + +Changes in V4 => v5: +1. Remove the patch for making prog pack allocator portable as it will come + through the RISCV tree[1]. + +2. Add a new function aarch64_insn_set() to be used in + bpf_arch_text_invalidate() for putting illegal instructions after a + program is removed. The earlier implementation of bpf_arch_text_invalidate() + was calling aarch64_insn_patch_text_nosync() in a loop and making it slow + because each call invalidated the cache. + + Here is test_tag now: + [root@ip-172-31-6-176 bpf]# time ./test_tag + test_tag: OK (40945 tests) + + real 0m19.695s + user 0m1.514s + sys 0m17.841s + + test_tag without these patches: + [root@ip-172-31-6-176 bpf]# time ./test_tag + test_tag: OK (40945 tests) + + real 0m21.487s + user 0m1.647s + sys 0m19.106s + + test_tag in the previous version was really slow > 2 minutes. see [2] + +3. Add cache invalidation in aarch64_insn_copy() so other users can call the + function without worrying about the cache. Currently only bpf_arch_text_copy() + is using it","[' but there might be more users in the future.\n\nChanes in V3 => V4: Changes only in 3rd patch\n1. Fix the I-cache maintenance: Clean the data cache and invalidate the i-Cache\n only *after* the instructions have been copied to the ROX region.\n\nChanes in V2 => V3: Changes only in 3rd patch\n1. Set prog = orig_prog; in the failure path of bpf_jit_binary_pack_finalize()\ncall.\n2. Add comments explaining the usage of the offsets in the exception table.\n\nChanges in v1 => v2:\n1. Make the naming consistent in the 3rd patch:\n ro_image and image\n ro_header and header\n ro_image_ptr and image_ptr\n2. Use names dst/src in place of addr/opcode in second patch.\n3. Add Acked-by: Song Liu in 1st and 2nd patch.\n\nBPF programs currently consume a page each on ARM64. For systems with many BPF\nprograms', ' this adds significant pressure to instruction TLB. High iTLB pressure\nusually causes slow down for the whole system.\n\nSong Liu introduced the BPF prog pack allocator[3] to mitigate the above issue.\nIt packs multiple BPF programs into a single huge page. It is currently only\nenabled for the x86_64 BPF JIT.\n\nThis patch series enables the BPF prog pack allocator for the ARM64 BPF JIT.\n\n====================================================\nPerformance Analysis of prog pack allocator on ARM64\n====================================================\n\nTo test the performance of the BPF prog pack allocator on ARM64', ' a stresser\ntool[4] was built. This tool loads 8 BPF programs on the system and triggers\n5 of them in an infinite loop by doing system calls.\n\nThe runner script starts 20 instances of the above which loads 8*20=160 BPF\nprograms on the system', ' 5*20=100 of which are being constantly triggered.\n\nIn the above environment we try to build Python-3.8.4 and try to find different\niTLB metrics for the compilation done by gcc-12.2.0.\n\nThe source code[5] is configured with the following command:\n./configure --enable-optimizations --with-ensurepip=install\n\nThen the runner script is executed with the following command:\n./run.sh ""perf stat -e ITLB_WALK', 'L1I_TLB', 'INST_RETIRED', 'iTLB-load-misses -a make -j32""\n\nThis builds Python while 160 BPF programs are loaded and 100 are being constantly\ntriggered and measures iTLB related metrics.\n\nThe output of the above command is discussed below before and after enabling the\nBPF prog pack allocator.\n\nThe tests were run on qemu-system-aarch64 with 32 cpus', ' 4G memory', ' -machine virt', '\n-cpu host', "" and -enable-kvm.\n\nResults\n-------\n\nBefore enabling prog pack allocator:\n------------------------------------\n\nPerformance counter stats for 'system wide':\n\n 333278635 ITLB_WALK\n 6762692976558 L1I_TLB\n 25359571423901 INST_RETIRED\n 15824054789 iTLB-load-misses\n\n 189.029769053 seconds time elapsed\n\nAfter enabling prog pack allocator:\n-----------------------------------\n\nPerformance counter stats for 'system wide':\n\n 190333544 ITLB_WALK\n 6712712386528 L1I_TLB\n 25278233304411 INST_RETIRED\n 5716757866 iTLB-load-misses\n\n 185.392650561 seconds time elapsed\n\nImprovements in metrics\n-----------------------\n\nCompilation time ---> 1.92% faster\niTLB-load-misses/Sec (Less is better) ---> 63.16% decrease\nITLB_WALK/1000 INST_RETIRED (Less is better) ---> 42.71% decrease\nITLB_Walk/L1I_TLB (Less is better) ---> 42.47% decrease\n\n[1] https://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git/commit/?h=for-next&id=20e490adea279d49d57b800475938f5b67926d98\n[2] https://lore.kernel.org/all/CANk7y0gcP3dF2mESLp5JN1+9iDfgtiWRFGqLkCgZD6wby1kQOw@mail.gmail.com/\n[3] https://lore.kernel.org/bpf/20220204185742.271030-1-song@kernel.org/\n[4] https://github.com/puranjaymohan/BPF-Allocator-Bench\n[5] https://www.python.org/ftp/python/3.8.4/Python-3.8.4.tgz\n====================\n\nLink: https://lore.kernel.org/r/20240228141824.119877-1-puranjay12@gmail.com\nSigned-off-by: Alexei Starovoitov \n"", '']",The commit integrates BPF prog pack allocator into BPF JIT for arm64 to improve performance.,"BPF JIT, allocator, arm64",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1dad391daef129e01e28206b8d586608ff026548,1dad391daef129e01e28206b8d586608ff026548,Puranjay Mohan,puranjay12@gmail.com,1709129904,Alexei Starovoitov,ast@kernel.org,1709156687,5811a3a6deb3825618a7d1a0577df5170871de2a,451c3cab9a65e656c3b3d106831fc02d56b8c34a,bpf," arm64: use bpf_prog_pack for memory management + +Use bpf_jit_binary_pack_alloc for memory management of JIT binaries in +ARM64 BPF JIT. The bpf_jit_binary_pack_alloc creates a pair of RW and RX +buffers. The JIT writes the program into the RW buffer. When the JIT is +done","[' the program is copied to the final RX buffer\nwith bpf_jit_binary_pack_finalize.\n\nImplement bpf_arch_text_copy() and bpf_arch_text_invalidate() for ARM64\nJIT as these functions are required by bpf_jit_binary_pack allocator.\n\nSigned-off-by: Puranjay Mohan \nAcked-by: Song Liu \nAcked-by: Catalin Marinas \nLink: https://lore.kernel.org/r/20240228141824.119877-3-puranjay12@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Introduces bpf_prog_pack for efficient memory management of JIT binaries in ARM64 BPF JIT.,"bpf_prog_pack,JIT,ARM64",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e59997d9052599feb17419289f2a57ed300e1dfa,e59997d9052599feb17419289f2a57ed300e1dfa,Alexei Starovoitov,ast@kernel.org,1709070858,Alexei Starovoitov,ast@kernel.org,1709070858,4a75076e5895a08e735de95e9e5c0ba31d21f4c9,2ab256e93249f5ac1da665861aa0f03fb4208d9c 22fc0e80aeb5c0c1377e6c02d7248f8fbf5df7fc,"Merge branch 'bpf-arm64-support-exceptions' + +Puranjay Mohan says: + +==================== +bpf"," arm64: Support Exceptions + +Changes in V2->V3: +V2: https://lore.kernel.org/all/20230917000045.56377-1-puranjay12@gmail.com/ +- Use unwinder from stacktrace.c rather than open coding the unwind logic. +- Fix a bug in the prologue related to BPF_FP (Xu Kuohai) + +Changes in V1->V2: +V1: https://lore.kernel.org/all/20230912233942.6734-1-puranjay12@gmail.com/ +- Remove exceptions from DENYLIST.aarch64 as they are supported now. + +The base support for exceptions was merged with [1] and it was enabled for +x86-64. + +This patch set enables the support on ARM64","[' all sefltests are passing:\n\n# ./test_progs -a exceptions\n#74/1 exceptions/exception_throw_always_1:OK\n#74/2 exceptions/exception_throw_always_2:OK\n#74/3 exceptions/exception_throw_unwind_1:OK\n#74/4 exceptions/exception_throw_unwind_2:OK\n#74/5 exceptions/exception_throw_default:OK\n#74/6 exceptions/exception_throw_default_value:OK\n#74/7 exceptions/exception_tail_call:OK\n#74/8 exceptions/exception_ext:OK\n#74/9 exceptions/exception_ext_mod_cb_runtime:OK\n#74/10 exceptions/exception_throw_subprog:OK\n#74/11 exceptions/exception_assert_nz_gfunc:OK\n#74/12 exceptions/exception_assert_zero_gfunc:OK\n#74/13 exceptions/exception_assert_neg_gfunc:OK\n#74/14 exceptions/exception_assert_pos_gfunc:OK\n#74/15 exceptions/exception_assert_negeq_gfunc:OK\n#74/16 exceptions/exception_assert_poseq_gfunc:OK\n#74/17 exceptions/exception_assert_nz_gfunc_with:OK\n#74/18 exceptions/exception_assert_zero_gfunc_with:OK\n#74/19 exceptions/exception_assert_neg_gfunc_with:OK\n#74/20 exceptions/exception_assert_pos_gfunc_with:OK\n#74/21 exceptions/exception_assert_negeq_gfunc_with:OK\n#74/22 exceptions/exception_assert_poseq_gfunc_with:OK\n#74/23 exceptions/exception_bad_assert_nz_gfunc:OK\n#74/24 exceptions/exception_bad_assert_zero_gfunc:OK\n#74/25 exceptions/exception_bad_assert_neg_gfunc:OK\n#74/26 exceptions/exception_bad_assert_pos_gfunc:OK\n#74/27 exceptions/exception_bad_assert_negeq_gfunc:OK\n#74/28 exceptions/exception_bad_assert_poseq_gfunc:OK\n#74/29 exceptions/exception_bad_assert_nz_gfunc_with:OK\n#74/30 exceptions/exception_bad_assert_zero_gfunc_with:OK\n#74/31 exceptions/exception_bad_assert_neg_gfunc_with:OK\n#74/32 exceptions/exception_bad_assert_pos_gfunc_with:OK\n#74/33 exceptions/exception_bad_assert_negeq_gfunc_with:OK\n#74/34 exceptions/exception_bad_assert_poseq_gfunc_with:OK\n#74/35 exceptions/exception_assert_range:OK\n#74/36 exceptions/exception_assert_range_with:OK\n#74/37 exceptions/exception_bad_assert_range:OK\n#74/38 exceptions/exception_bad_assert_range_with:OK\n#74/39 exceptions/non-throwing fentry -> exception_cb:OK\n#74/40 exceptions/throwing fentry -> exception_cb:OK\n#74/41 exceptions/non-throwing fexit -> exception_cb:OK\n#74/42 exceptions/throwing fexit -> exception_cb:OK\n#74/43 exceptions/throwing extension (with custom cb) -> exception_cb:OK\n#74/44 exceptions/throwing extension -> global func in exception_cb:OK\n#74/45 exceptions/exception_ext_mod_cb_runtime:OK\n#74/46 exceptions/throwing extension (with custom cb) -> global func in exception_cb:OK\n#74/47 exceptions/exception_ext:OK\n#74/48 exceptions/non-throwing fentry -> non-throwing subprog:OK\n#74/49 exceptions/throwing fentry -> non-throwing subprog:OK\n#74/50 exceptions/non-throwing fentry -> throwing subprog:OK\n#74/51 exceptions/throwing fentry -> throwing subprog:OK\n#74/52 exceptions/non-throwing fexit -> non-throwing subprog:OK\n#74/53 exceptions/throwing fexit -> non-throwing subprog:OK\n#74/54 exceptions/non-throwing fexit -> throwing subprog:OK\n#74/55 exceptions/throwing fexit -> throwing subprog:OK\n#74/56 exceptions/non-throwing fmod_ret -> non-throwing subprog:OK\n#74/57 exceptions/non-throwing fmod_ret -> non-throwing global subprog:OK\n#74/58 exceptions/non-throwing extension -> non-throwing subprog:OK\n#74/59 exceptions/non-throwing extension -> throwing subprog:OK\n#74/60 exceptions/non-throwing extension -> non-throwing subprog:OK\n#74/61 exceptions/non-throwing extension -> throwing global subprog:OK\n#74/62 exceptions/throwing extension -> throwing global subprog:OK\n#74/63 exceptions/throwing extension -> non-throwing global subprog:OK\n#74/64 exceptions/non-throwing extension -> main subprog:OK\n#74/65 exceptions/throwing extension -> main subprog:OK\n#74/66 exceptions/reject_exception_cb_type_1:OK\n#74/67 exceptions/reject_exception_cb_type_2:OK\n#74/68 exceptions/reject_exception_cb_type_3:OK\n#74/69 exceptions/reject_exception_cb_type_4:OK\n#74/70 exceptions/reject_async_callback_throw:OK\n#74/71 exceptions/reject_with_lock:OK\n#74/72 exceptions/reject_subprog_with_lock:OK\n#74/73 exceptions/reject_with_rcu_read_lock:OK\n#74/74 exceptions/reject_subprog_with_rcu_read_lock:OK\n#74/75 exceptions/reject_with_rbtree_add_throw:OK\n#74/76 exceptions/reject_with_reference:OK\n#74/77 exceptions/reject_with_cb_reference:OK\n#74/78 exceptions/reject_with_cb:OK\n#74/79 exceptions/reject_with_subprog_reference:OK\n#74/80 exceptions/reject_throwing_exception_cb:OK\n#74/81 exceptions/reject_exception_cb_call_global_func:OK\n#74/82 exceptions/reject_exception_cb_call_static_func:OK\n#74/83 exceptions/reject_multiple_exception_cb:OK\n#74/84 exceptions/reject_exception_throw_cb:OK\n#74/85 exceptions/reject_exception_throw_cb_diff:OK\n#74/86 exceptions/reject_set_exception_cb_bad_ret1:OK\n#74/87 exceptions/reject_set_exception_cb_bad_ret2:OK\n#74/88 exceptions/check_assert_eq_int_min:OK\n#74/89 exceptions/check_assert_eq_int_max:OK\n#74/90 exceptions/check_assert_eq_zero:OK\n#74/91 exceptions/check_assert_eq_llong_min:OK\n#74/92 exceptions/check_assert_eq_llong_max:OK\n#74/93 exceptions/check_assert_lt_pos:OK\n#74/94 exceptions/check_assert_lt_zero:OK\n#74/95 exceptions/check_assert_lt_neg:OK\n#74/96 exceptions/check_assert_le_pos:OK\n#74/97 exceptions/check_assert_le_zero:OK\n#74/98 exceptions/check_assert_le_neg:OK\n#74/99 exceptions/check_assert_gt_pos:OK\n#74/100 exceptions/check_assert_gt_zero:OK\n#74/101 exceptions/check_assert_gt_neg:OK\n#74/102 exceptions/check_assert_ge_pos:OK\n#74/103 exceptions/check_assert_ge_zero:OK\n#74/104 exceptions/check_assert_ge_neg:OK\n#74/105 exceptions/check_assert_range_s64:OK\n#74/106 exceptions/check_assert_range_u64:OK\n#74/107 exceptions/check_assert_single_range_s64:OK\n#74/108 exceptions/check_assert_single_range_u64:OK\n#74/109 exceptions/check_assert_generic:OK\n#74/110 exceptions/check_assert_with_return:OK\n#74 exceptions:OK\nSummary: 1/110 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\n[1] https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git/commit/?h=for-next&id=ec6f1b4db95b7eedb3fe85f4f14e08fa0e9281c3\n====================\n\nLink: https://lore.kernel.org/r/20240201125225.72796-1-puranjay12@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Enable exception support for eBPF on ARM64 architecture.,"ARM64, exceptions, support",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +22fc0e80aeb5c0c1377e6c02d7248f8fbf5df7fc,22fc0e80aeb5c0c1377e6c02d7248f8fbf5df7fc,Puranjay Mohan,puranjay12@gmail.com,1706791945,Alexei Starovoitov,ast@kernel.org,1709070857,4a75076e5895a08e735de95e9e5c0ba31d21f4c9,e74cb1b422131615a0fe3bedd4ab2e38b7442d10,bpf," arm64: support exceptions + +The prologue generation code has been modified to make the callback +program use the stack of the program marked as exception boundary where +callee-saved registers are already pushed. + +As the bpf_throw function never returns","[' if it clobbers any callee-saved\nregisters', ' they would remain clobbered. So', ' the prologue of the\nexception-boundary program is modified to push R23 and R24 as well', '\nwhich the callback will then recover in its epilogue.\n\nThe Procedure Call Standard for the Arm 64-bit Architecture[1] states\nthat registers r19 to r28 should be saved by the callee. BPF programs on\nARM64 already save all callee-saved registers except r23 and r24. This\npatch adds an instruction in prologue of the program to save these\ntwo registers and another instruction in the epilogue to recover them.\n\nThese extra instructions are only added if bpf_throw() is used. Otherwise\nthe emitted prologue/epilogue remains unchanged.\n\n[1] https://github.com/ARM-software/abi-aa/blob/main/aapcs64/aapcs64.rst\n\nSigned-off-by: Puranjay Mohan \nLink: https://lore.kernel.org/r/20240201125225.72796-3-puranjay12@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Modified prologue generation code to use stack of exception boundary programs for callbacks.,"prologue,stack,exception",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e74cb1b422131615a0fe3bedd4ab2e38b7442d10,e74cb1b422131615a0fe3bedd4ab2e38b7442d10,Puranjay Mohan,puranjay12@gmail.com,1706791944,Alexei Starovoitov,ast@kernel.org,1709070857,1ff1bbf0dfae6441b61ff0cdae9f70f2cb1de7fa,2ab256e93249f5ac1da665861aa0f03fb4208d9c,"arm64: stacktrace: Implement arch_bpf_stack_walk() for the BPF JIT + +This will be used by bpf_throw() to unwind till the program marked as +exception boundary and run the callback with the stack of the main +program. + +This is required for supporting BPF exceptions on ARM64. + +Signed-off-by: Puranjay Mohan +Acked-by: Catalin Marinas +Link: https://lore.kernel.org/r/20240201125225.72796-2-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov +",,Implement arch_bpf_stack_walk for ARM64 BPF JIT to support BPF exceptions.,"ARM64,BPF JIT,stacktrace",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +529d5818a3bb0272ced031e022e4b41d6410a4da,529d5818a3bb0272ced031e022e4b41d6410a4da,Arnaldo Carvalho de Melo,acme@kernel.org,1708789677,Namhyung Kim,namhyung@kernel.org,1708964168,2e2e0dc4452314f1e01524139e58907db983573a,c2bd08ba20a57e0ed55777a9d1724647a0f53e88,"perf bpf: Check that the minimal vmlinux.h installed is the latest one + +When building BPF skels perf will", by default,"[' install a minimalistic\nvmlinux.h file with the types needed by the BPF skels in\ntools/perf/util/bpf_skel/ in its build directory.\n\nWhen 29d16de26df17e94 (""perf augmented_raw_syscalls.bpf: Move \'struct\ntimespec64\' to vmlinux.h"") was added', ' a type used in the augmented_raw_syscalls\nBPF skel', "" 'struct timespec64' was not found when building from a pre-existing\nbuild directory"", "" because the vmlinux.h there didn't contain that type"", '\nending up with this error', "" spotted in linux-next:\n\n CLANG /tmp/build/perf-tools-next/util/bpf_skel/.tmp/augmented_raw_syscalls.bpf.o\n util/bpf_skel/augmented_raw_syscalls.bpf.c:329:15: error: invalid application of 'sizeof' to an incomplete type 'struct timespec64'\n 329 | __u32 size = sizeof(struct timespec64);\n | ^ ~~~~~~~~~~~~~~~~~~~\n util/bpf_skel/augmented_raw_syscalls.bpf.c:329:29: note: forward declaration of 'struct timespec64'\n 329 | __u32 size = sizeof(struct timespec64);\n | ^\n util/bpf_skel/augmented_raw_syscalls.bpf.c:350:15: error: invalid application of 'sizeof' to an incomplete type 'struct timespec64'\n 350 | __u32 size = sizeof(struct timespec64);\n | ^ ~~~~~~~~~~~~~~~~~~~\n util/bpf_skel/augmented_raw_syscalls.bpf.c:350:29: note: forward declaration of 'struct timespec64'\n 350 | __u32 size = sizeof(struct timespec64);\n | ^\n 2 errors generated.\n make[2]: *** [Makefile.perf:1158: /tmp/build/perf-tools-next/util/bpf_skel/.tmp/augmented_raw_syscalls.bpf.o] Error 1\n make[2]: *** Waiting for unfinished jobs....\n make[1]: *** [Makefile.perf:261: sub-make] Error 2\n make: *** [Makefile:113: install-bin] Error 2\n make: Leaving directory '/home/acme/git/perf-tools-next/tools/perf'\n\nSo add a Makefile dependency (Namhyung's suggestion) to make sure that\nthe new tools/perf/util/bpf_skel/vmlinux/vmlinux.h minimal vmlinux is\nupdated in the build directory"", ' providing the moved \'struct timespec64\'\ntype.\n\nFixes: 29d16de26df17e94 (""perf augmented_raw_syscalls.bpf: Move \'struct timespec64\' to vmlinux.h"")\nReported-by: Stephen Rothwell \nReviewed-by: Ian Rogers \nSuggested-by: Namhyung Kim \nSigned-off-by: Arnaldo Carvalho de Melo \nSigned-off-by: Namhyung Kim \nLink: https://lore.kernel.org/r/ZdoPrWg-qYFpBJbz@x1\n', '']",Ensure the latest minimal vmlinux.h is checked when building BPF skeletons in perf.,"perf,vmlinux,BPF",It's a build system or CI/CD change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2ab256e93249f5ac1da665861aa0f03fb4208d9c,2ab256e93249f5ac1da665861aa0f03fb4208d9c,Benjamin Tissoires,bentiss@kernel.org,1708532719,Alexei Starovoitov,ast@kernel.org,1708652933,8eabe7f48f894fd2af17dadebbe9eacad98ebfa5,dfe6625df48ec54c6dc9b86d361f26962d09de88,"bpf: add is_async_callback_calling_insn() helper + +Currently we have a special case for BPF_FUNC_timer_set_callback"," +let's introduce a helper we can extend for the kfunc that will come in +a later patch + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240221-hid-bpf-sleepable-v3-3-1fb378ca6301@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add is_async_callback_calling_insn() helper to extend functionality for future kfuncs.,"helper, kfunc, async",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dfe6625df48ec54c6dc9b86d361f26962d09de88,dfe6625df48ec54c6dc9b86d361f26962d09de88,Benjamin Tissoires,bentiss@kernel.org,1708532718,Alexei Starovoitov,ast@kernel.org,1708652835,999be8e21d533dc7a8dc5d7c39a142a4ff392d3e,55bad79e33aeb670317290158a4b2ff71cdc8380,"bpf: introduce in_sleepable() helper + +No code change"," but it'll allow to have only one place to change +everything when we add in_sleepable in cur_state. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240221-hid-bpf-sleepable-v3-2-1fb378ca6301@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Introduces the in_sleepable() helper function for eBPF.,"in_sleepable, helper, eBPF",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +55bad79e33aeb670317290158a4b2ff71cdc8380,55bad79e33aeb670317290158a4b2ff71cdc8380,Benjamin Tissoires,bentiss@kernel.org,1708532717,Alexei Starovoitov,ast@kernel.org,1708652543,57e5032537f1bcceb4e98608df9ac6dee06f19a6,63c7049ef9d642ab60bb1eccf75b29dc40277664,"bpf: allow more maps in sleepable bpf programs + +These 2 maps types are required for HID-BPF when a user wants to do +IO with a device from a sleepable tracing point. + +Allowing BPF_MAP_TYPE_QUEUE (and therefore BPF_MAP_TYPE_STACK) allows +for a BPF program to prepare from an IRQ the list of HID commands to send +back to the device and then these commands can be retrieved from the +sleepable trace point. + +Signed-off-by: Benjamin Tissoires +Link: https://lore.kernel.org/r/20240221-hid-bpf-sleepable-v3-1-1fb378ca6301@kernel.org +Signed-off-by: Alexei Starovoitov +",,Enable additional map types in sleepable BPF programs for HID interaction.,"sleepable,HID,MAP_TYPE_QUEUE",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['tracepoints like programs', 'HID driver like programs']" +63c7049ef9d642ab60bb1eccf75b29dc40277664,63c7049ef9d642ab60bb1eccf75b29dc40277664,Martin KaFai Lau,martin.lau@kernel.org,1708629580,Martin KaFai Lau,martin.lau@kernel.org,1708633602,5c5951094ff327b9e52343e25707d5cc944f2fdb,58fd62e0aa50fdd20bc41a01e787001f3af8a925 e9bbda13a7b876451285ab15fb600b809e5e2290,"Merge branch 'Check cfi_stubs before registering a struct_ops type.' + +Kui-Feng Lee says: + +==================== +Recently", st_ops->cfi_stubs was introduced. However,"[' the upcoming new\nstruct_ops support (e.g. sched_ext) is not aware of this and does not\nprovide its own cfi_stubs. The kernel ends up NULL dereferencing the\nst_ops->cfi_stubs.\n\nConsidering struct_ops supports kernel module now', ' this NULL check\nis necessary. This patch set is to reject struct_ops registration\nthat does not provide a cfi_stubs.\n\nChanges from v4:\n\n - Remove changes of check_member.\n\n - Remove checks of the pointers in cfi_stubs[].\n\nChanges from v3:\n\n - Remove CFI stub function for get_info.\n\n - Allow passing NULL prog arg to check_member of struct\n bpf_struct_ops type.\n\n - Call check_member to determines if a CFI stub function should be\n defined for an operator.\n\nChanges from v2:\n\n - Add a stub function for get_info of struct tcp_congestion_ops.\n\nChanges from v1:\n\n - Check *(void **)(cfi_stubs + moff) to make sure stub functions are\n provided for every operator.\n\n - Add a test case to ensure that struct_ops rejects incomplete\n cfi_stub.\n\nv4: https://lore.kernel.org/all/20240221075213.2071454-1-thinker.li@gmail.com/\nv3: https://lore.kernel.org/all/20240216193434.735874-1-thinker.li@gmail.com/\nv2: https://lore.kernel.org/all/20240216020350.2061373-1-thinker.li@gmail.com/\nv1: https://lore.kernel.org/all/20240215022401.1882010-1-thinker.li@gmail.com/\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",This commit merges changes to check cfi_stubs before registering a struct_ops type.,"cfi_stubs, struct_ops, merge",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +e9bbda13a7b876451285ab15fb600b809e5e2290,e9bbda13a7b876451285ab15fb600b809e5e2290,Kui-Feng Lee,thinker.li@gmail.com,1708567865,Martin KaFai Lau,martin.lau@kernel.org,1708633601,5c5951094ff327b9e52343e25707d5cc944f2fdb,3e0008336ae3153fb89b1a15bb877ddd38680fe6,"selftests/bpf: Test case for lacking CFI stub functions. + +Ensure struct_ops rejects the registration of struct_ops types without +proper CFI stub functions. + +bpf_test_no_cfi.ko is a module that attempts to register a struct_ops type +called ""bpf_test_no_cfi_ops"" with cfi_stubs of NULL and non-NULL value. +The NULL one should fail"," and the non-NULL one should succeed. The module +can only be loaded successfully if these registrations yield the expected +results. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240222021105.1180475-3-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Add a test case for struct_ops registration with CFI stub function validation in selftests/bpf.,"test case, struct_ops, CFI",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3e0008336ae3153fb89b1a15bb877ddd38680fe6,3e0008336ae3153fb89b1a15bb877ddd38680fe6,Kui-Feng Lee,thinker.li@gmail.com,1708567864,Martin KaFai Lau,martin.lau@kernel.org,1708633600,8c45e2221acca5756299cd79561305fa71569755,58fd62e0aa50fdd20bc41a01e787001f3af8a925,"bpf: Check cfi_stubs before registering a struct_ops type. + +Recently", st_ops->cfi_stubs was introduced. However,"[' the upcoming new\nstruct_ops support (e.g. sched_ext) is not aware of this and does not\nprovide its own cfi_stubs. The kernel ends up NULL dereferencing the\nst_ops->cfi_stubs.\n\nConsidering struct_ops supports kernel module now', ' this NULL check\nis necessary. This patch is to reject struct_ops registration\nthat does not provide a cfi_stubs.\n\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240222021105.1180475-2-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",The commit ensures cfi_stubs are checked before registering a struct_ops type in the BPF subsystem.,"cfi_stubs, struct_ops, register",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0827a1fb143fae588cb6f5b9a97c405d6c2ddec9,0827a1fb143fae588cb6f5b9a97c405d6c2ddec9,Chengming Zhou,zhouchengming@bytedance.com,1707015960,Andrew Morton,akpm@linux-foundation.org,1708626294,76de3ff51d3ad34fbc26d8743134ce1b383d4fd9,f9c0f1c32cb568e16ef0676d8e7827a3ad443742,"mm/zswap: invalidate zswap entry when swap entry free + +During testing I found there are some times the zswap_writeback_entry() +return -ENOMEM"," which is not we expected: + +bpftrace -e 'kr:zswap_writeback_entry {@[(int32)retval]=count()}' +@[-12]: 1563 +@[0]: 277221 + +The reason is that __read_swap_cache_async() return NULL because +swapcache_prepare() failed. The reason is that we won't invalidate zswap +entry when swap entry freed to the per-cpu pool","[' these zswap entries are\nstill on the zswap tree and lru list.\n\nThis patch moves the invalidation ahead to when swap entry freed to the\nper-cpu pool', "" since there is no any benefit to leave trashy zswap entry on\nthe tree and lru list.\n\nWith this patch:\nbpftrace -e 'kr:zswap_writeback_entry {@[(int32)retval]=count()}'\n@[0]: 259744\n\nNote: large folio can't have zswap entry for now"", "" so don't bother\nto add zswap entry invalidation in the large folio swap free path.\n\nLink: https://lkml.kernel.org/r/20240201-b4-zswap-invalidate-entry-v2-2-99d4084260a0@bytedance.com\nSigned-off-by: Chengming Zhou \nReviewed-by: Nhat Pham \nAcked-by: Johannes Weiner \nAcked-by: Yosry Ahmed \nSigned-off-by: Andrew Morton \n"", '']",The commit fixes an issue where zswap entries are not invalidated when swap entries are freed.,"zswap, invalidate, swap",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +f9c0f1c32cb568e16ef0676d8e7827a3ad443742,f9c0f1c32cb568e16ef0676d8e7827a3ad443742,Chengming Zhou,zhouchengming@bytedance.com,1707015959,Andrew Morton,akpm@linux-foundation.org,1708626294,885052a9087ad575d314c256f8c262d2bdf8cca5,e374ae2be2f7cb4aad46e17e3fa5da7bbb0d2a09,"mm/zswap: add more comments in shrink_memcg_cb() + +Patch series ""mm/zswap: optimize zswap lru list"""," v2. + +This series is motivated when observe the zswap lru list shrinking","["" noted\nthere are some unexpected cases in zswap_writeback_entry().\n\nbpftrace -e 'kr:zswap_writeback_entry {@[(int32)retval]=count()}'\n\nThere are some -ENOMEM because when the swap entry is freed to per-cpu\nswap pool"", "" it doesn't invalidate/drop zswap entry. Then the shrinker\nencounter these trashy zswap entries"", "" it can't be reclaimed and return\n-ENOMEM.\n\nSo move the invalidation ahead to when swap entry freed to the per-cpu\nswap pool"", ' since there is no any benefit to leave trashy zswap entries on\nthe zswap tree and lru list.\n\nAnother case is -EEXIST', ' which is seen more in the case of\n!zswap_exclusive_loads_enabled', "" in which case the swapin folio will leave\ncompressed copy on the tree and lru list. And it can't be reclaimed until\nthe folio is removed from swapcache.\n\nChanging to zswap_exclusive_loads_enabled mode will invalidate when folio\nswapin"", ' which has its own drawback if that folio is still clean in\nswapcache and swapout again', ' we need to compress it again. Please see the\ncommit for details on why we choose exclusive load as the default for\nzswap.\n\nAnother optimization for -EEXIST is that we add LRU_STOP to support\nterminating the shrinking process to avoid evicting warmer region.\n\nTesting using kernel build in tmpfs', ' one 50GB swapfile and\nzswap shrinker_enabled', ' with memory.max set to 2GB.\n\n mm-unstable zswap-optimize\nreal 63.90s 63.25s\nuser 1064.05s 1063.40s\nsys 292.32s 270.94s\n\nThe main optimization is in sys cpu', ' about 7% improvement.\n\n\nThis patch (of 6):\n\nAdd more comments in shrink_memcg_cb() to describe the deref dance which\nis implemented to fix race problem between lru writeback and swapoff', ' and\nthe reason why we rotate the entry at the beginning.\n\nAlso fix the stale comments in zswap_writeback_entry()', ' and add more\ncomments to state that we only deref the tree after we get the swapcache\nreference.\n\nLink: https://lkml.kernel.org/r/20240201-b4-zswap-invalidate-entry-v2-0-99d4084260a0@bytedance.com\nLink: https://lkml.kernel.org/r/20240201-b4-zswap-invalidate-entry-v2-1-99d4084260a0@bytedance.com\nSigned-off-by: Johannes Weiner \nSigned-off-by: Chengming Zhou \nSuggested-by: Yosry Ahmed \nSuggested-by: Johannes Weiner \nAcked-by: Yosry Ahmed \nReviewed-by: Nhat Pham \nSigned-off-by: Andrew Morton \n', '']",Added comments in shrink_memcg_cb() function related to zswap lru list.,"comments, zswap, lru",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +58fd62e0aa50fdd20bc41a01e787001f3af8a925,58fd62e0aa50fdd20bc41a01e787001f3af8a925,Martin Kelly,martin.kelly@crowdstrike.com,1708550318,Martin KaFai Lau,martin.lau@kernel.org,1708626278,1fb68a2bc562186287c461a7c1382697e8e19b69,89ee838130f470afcd02b30ca868f236a3f3b1d2,"bpf: Clarify batch lookup/lookup_and_delete semantics + +The batch lookup and lookup_and_delete APIs have two parameters"," +in_batch and out_batch","[' to facilitate iterative\nlookup/lookup_and_deletion operations for supported maps. Except NULL\nfor in_batch at the start of these two batch operations', ' both parameters\nneed to point to memory equal or larger than the respective map key\nsize', ' except for various hashmaps (hash', ' percpu_hash', ' lru_hash', '\nlru_percpu_hash) where the in_batch/out_batch memory size should be\nat least 4 bytes.\n\nDocument these semantics to clarify the API.\n\nSigned-off-by: Martin Kelly \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240221211838.1241578-1-martin.kelly@crowdstrike.com\nSigned-off-by: Martin KaFai Lau \n', '']",The commit clarifies the semantics of batch lookup and lookup_and_delete APIs in eBPF.,"batch,lookup,APIs",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6714ebb922ab15a209dfc3c1ed29d4bb0abc9f02,6714ebb922ab15a209dfc3c1ed29d4bb0abc9f02,Linus Torvalds,torvalds@linux-foundation.org,1708624678,Linus Torvalds,torvalds@linux-foundation.org,1708624678,4c8c92b7a4ded99e9ad8f66c2d369032825d81ee,efa80dcbb7a3ecc4a1b2f54624c49b5a612f92b3 359e54a93ab43d32ee1bff3c2f9f10cb9f6b6e79,"Merge tag 'net-6.8.0-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + ""Including fixes from bpf and netfilter. + + Current release - regressions: + + - af_unix: fix another unix GC hangup + + Previous releases - regressions: + + - core: fix a possible AF_UNIX deadlock + + - bpf: fix NULL pointer dereference in sk_psock_verdict_data_ready() + + - netfilter: nft_flow_offload: release dst in case direct xmit path + is used + + - bridge: switchdev: ensure MDB events are delivered exactly once + + - l2tp: pass correct message length to ip6_append_data + + - dccp/tcp: unhash sk from ehash for tb2 alloc failure after + check_estalblished() + + - tls: fixes for record type handling with PEEK + + - devlink: fix possible use-after-free and memory leaks in + devlink_init() + + Previous releases - always broken: + + - bpf: fix an oops when attempting to read the vsyscall page through + bpf_probe_read_kernel + + - sched: act_mirred: use the backlog for mirred ingress + + - netfilter: nft_flow_offload: fix dst refcount underflow + + - ipv6: sr: fix possible use-after-free and null-ptr-deref + + - mptcp: fix several data races + + - phonet: take correct lock to peek at the RX queue + + Misc: + + - handful of fixes and reliability improvements for selftests"" + +* tag 'net-6.8.0-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (72 commits) + l2tp: pass correct message length to ip6_append_data + net: phy: realtek: Fix rtl8211f_config_init() for RTL8211F(D)(I)-VD-CG PHY + selftests: ioam: refactoring to align with the fix + Fix write to cloned skb in ipv6_hop_ioam() + phonet/pep: fix racy skb_queue_empty() use + phonet: take correct lock to peek at the RX queue + net: sparx5: Add spinlock for frame transmission from CPU + net/sched: flower: Add lock protection when remove filter handle + devlink: fix port dump cmd type + net: stmmac: Fix EST offset for dwmac 5.10 + tools: ynl: don't leak mcast_groups on init error + tools: ynl: make sure we always pass yarg to mnl_cb_run + net: mctp: put sock on tag allocation failure + netfilter: nf_tables: use kzalloc for hook allocation + netfilter: nf_tables: register hooks last when adding new chain/flowtable + netfilter: nft_flow_offload: release dst in case direct xmit path is used + netfilter: nft_flow_offload: reset dst in route object after setting up flow + netfilter: nf_tables: set dormant flag on hook register failure + selftests: tls: add test for peeking past a record of a different type + selftests: tls: add test for merging of same-type control messages + ... +",,Merge various networking and BPF-related fixes for current and previous Linux kernel releases.,"networking,fixed,regressions",It's a bug fix.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +89ee838130f470afcd02b30ca868f236a3f3b1d2,89ee838130f470afcd02b30ca868f236a3f3b1d2,Dave Thaler,dthaler1968@googlemail.com,1708538059,Alexei Starovoitov,ast@kernel.org,1708621909,601d5b8af76dcb769c9a5331cf35231d458422d3,c1bb68f6b2f6be5297c5fbad5caebf67d0dd3034,bpf," docs: specify which BPF_ABS and BPF_IND fields were zero + +Specifying which fields were unused allows IANA to only list as deprecated +instructions that were actually used","[' leaving the rest as unassigned and\npossibly available for future use for something else.\n\nSigned-off-by: Dave Thaler \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240221175419.16843-1-dthaler1968@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit specifies unused BPF_ABS and BPF_IND fields allowing IANA to list deprecated instructions accurately.,"BPF_ABS,BPF_IND,deprecated",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"[""It's not related to any of the above.""]" +c1bb68f6b2f6be5297c5fbad5caebf67d0dd3034,c1bb68f6b2f6be5297c5fbad5caebf67d0dd3034,Dave Thaler,dthaler1968@googlemail.com,1708536935,Alexei Starovoitov,ast@kernel.org,1708621657,35984a7f955038cff0e43701f069beb5a5adeb19,8425b6eb51460ef429920b2ee7e2b0881d4e23c5,bpf," docs: Fix typos in instruction-set.rst + +* ""BPF ADD"" should be ""BPF_ADD"". +* ""src"" should be ""src_reg"" in several places. The latter is the field name + in the instruction. The former refers to the value of the register","["" or the\n immediate.\n* Add '' around field names in one sentence"", ' for consistency with the rest\n of the document.\n\nSigned-off-by: Dave Thaler \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240221173535.16601-1-dthaler1968@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix typos in the eBPF instruction-set documentation regarding field names.,"BPF_ADD,src_reg,typos",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8425b6eb51460ef429920b2ee7e2b0881d4e23c5,8425b6eb51460ef429920b2ee7e2b0881d4e23c5,Alexei Starovoitov,ast@kernel.org,1708620375,Alexei Starovoitov,ast@kernel.org,1708620375,d550154aa14ebbfe7ad0b361f808c2366fbdd9a3,a3c70a3cf11eb4b6409afc2cce1a3747e1dfe96f b546b57526953be2981113171ed586c4c50b1b0a,"Merge branch 'selftests-bpf-reduce-tcp_custom_syncookie-verification-complexity' + +Eduard Zingerman says: + +==================== +selftests/bpf: reduce tcp_custom_syncookie verification complexity + +Thread [0] discusses a fix for bpf_loop() handling bug. +That change makes tcp_custom_syncookie test too complex to verify. +The fix discussed in [0] would be sent via 'bpf' tree"," +tcp_custom_syncookie test is not in 'bpf' tree yet. +As agreed in [0] I'm sending syncookie test update separately. + +[0] https://lore.kernel.org/bpf/20240216150334.31937-1-eddyz87@gmail.com/ +==================== + +Link: https://lore.kernel.org/r/20240222150300.14909-1-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Optimize the tcp_custom_syncookie test in selftests/bpf by reducing its verification complexity.,"tcp_custom_syncookie, selftests, complexity",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +b546b57526953be2981113171ed586c4c50b1b0a,b546b57526953be2981113171ed586c4c50b1b0a,Eduard Zingerman,eddyz87@gmail.com,1708614180,Alexei Starovoitov,ast@kernel.org,1708620375,d550154aa14ebbfe7ad0b361f808c2366fbdd9a3,a3c70a3cf11eb4b6409afc2cce1a3747e1dfe96f,"selftests/bpf: update tcp_custom_syncookie to use scalar packet offset + +This commit updates tcp_custom_syncookie.c:tcp_parse_option() to use +explicit packet offset (ctx->off) for packet access instead of ever +moving pointer (ctx->ptr)"," this reduces verification complexity: +- the tcp_parse_option() is passed as a callback to bpf_loop(); +- suppose a checkpoint is created each time at function entry; +- the ctx->ptr is tracked by verifier as PTR_TO_PACKET; +- the ctx->ptr is incremented in tcp_parse_option()","[""\n thus umax_value field tracked for it is incremented as well;\n- on each next iteration of tcp_parse_option()\n checkpoint from a previous iteration can't be reused\n for state pruning"", ' because PTR_TO_PACKET registers are\n considered equivalent only if old->umax_value >= cur->umax_value;\n- on the other hand', ' the ctx->off is a SCALAR', '\n subject to widen_imprecise_scalars();\n- it\'s exact bounds are eventually forgotten and it is tracked as\n unknown scalar at entry to tcp_parse_option();\n- hence checkpoints created at the start of the function eventually\n converge.\n\nThe change is similar to one applied in [0] to xdp_synproxy_kern.c.\n\nComparing before and after with veristat yields following results:\n\nFile Insns (A) Insns (B) Insns (DIFF)\n------------------------------- --------- --------- -----------------\ntest_tcp_custom_syncookie.bpf.o 466657 12423 -454234 (-97.34%)\n\n[0] commit 977bc146d4eb (""selftests/bpf: track tcp payload offset as scalar in xdp_synproxy"")\n\nAcked-by: Yonghong Song \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240222150300.14909-2-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit updates tcp_custom_syncookie to use scalar packet offset in tcp_parse_option for better verification.,"selftests,bpf,offset",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tc/netfilter like programs'] +fdcd4467ba154465402432888f9ba9ad2122a37a,fdcd4467ba154465402432888f9ba9ad2122a37a,Paolo Abeni,pabeni@redhat.com,1708592686,Paolo Abeni,pabeni@redhat.com,1708592687,0298a166b0c60212e58c72a5351a6fd1e58d1474,3489182b11d35f1944c1245fc9c4867cf622c50f 4cd12c6065dfcdeba10f49949bffcf383b3952d8,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-02-22 + +The following pull-request contains BPF updates for your *net* tree. + +We've added 11 non-merge commits during the last 24 day(s) which contain +a total of 15 files changed", 217 insertions(+),"[' 17 deletions(-).\n\nThe main changes are:\n\n1) Fix a syzkaller-triggered oops when attempting to read the vsyscall\n page through bpf_probe_read_kernel and friends', ' from Hou Tao.\n\n2) Fix a kernel panic due to uninitialized iter position pointer in\n bpf_iter_task', ' from Yafang Shao.\n\n3) Fix a race between bpf_timer_cancel_and_free and bpf_timer_cancel', '\n from Martin KaFai Lau.\n\n4) Fix a xsk warning in skb_add_rx_frag() (under CONFIG_DEBUG_NET)\n due to incorrect truesize accounting', ' from Sebastian Andrzej Siewior.\n\n5) Fix a NULL pointer dereference in sk_psock_verdict_data_ready', '\n from Shigeru Yoshida.\n\n6) Fix a resolve_btfids warning when bpf_cpumask symbol cannot be\n resolved', "" from Hari Bathini.\n\nbpf-for-netdev\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n bpf"", ' sockmap: Fix NULL pointer dereference in sk_psock_verdict_data_ready()\n selftests/bpf: Add negtive test cases for task iter\n bpf: Fix an issue due to uninitialized bpf_iter_task\n selftests/bpf: Test racing between bpf_timer_cancel_and_free and bpf_timer_cancel\n bpf: Fix racing between bpf_timer_cancel_and_free and bpf_timer_cancel\n selftest/bpf: Test the read of vsyscall page under x86-64\n x86/mm: Disallow vsyscall page read for copy_from_kernel_nofault()\n x86/mm: Move is_vsyscall_vaddr() into asm/vsyscall.h\n bpf', ' scripts: Correct GPL license name\n xsk: Add truesize to skb_add_rx_frag().\n bpf: Fix warning for bpf_cpumask in verifier\n====================\n\nLink: https://lore.kernel.org/r/20240221231826.1404-1-daniel@iogearbox.net\nSigned-off-by: Paolo Abeni \n', '']",Merge of BPF updates into the net tree with changes across 15 files and 217 insertions.,"BPF, netdev, updates",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a3c70a3cf11eb4b6409afc2cce1a3747e1dfe96f,a3c70a3cf11eb4b6409afc2cce1a3747e1dfe96f,Alexei Starovoitov,ast@kernel.org,1708473001,Alexei Starovoitov,ast@kernel.org,1708552154,5fe7b4c3fc67c958714897ade529227918b1282c,01dbd7d8720a0cc97dad5e70ec674dacdc66cf3c,"bpf: Shrink size of struct bpf_map/bpf_array. + +Back in 2018 the commit be95a845cc44 (""bpf: avoid false sharing of map refcount +with max_entries"") added ____cacheline_aligned to ""struct bpf_map"" to make sure +that fields like refcnt don't share a cache line with max_entries that is used +to bounds check map access. That was done to make spectre style attacks harder. +The main mitigation is done via code similar to array_index_nospec()"," of course. +This was an additional precaution. + +It increased the size of ""struct bpf_map"" a little","["" but it's affect on all\nother maps (like array) is significant"", ' since ""struct bpf_map"" is typically\nthe first member in other map types.\n\nUndo this ____cacheline_aligned tag. Instead move freeze_mutex field around', ' so\nthat refcnt and max_entries are still in different cache lines.\n\nThe main effect is seen in sizeof(struct bpf_array) that reduces from 320\nto 248 bytes.\n\nBEFORE:\n\nstruct bpf_map {\n\tconst struct bpf_map_ops * ops; /* 0 8 */\n\t...\n\tchar name[16]; /* 96 16 */\n\n\t/* XXX 16 bytes hole', ' try to pack */\n\n\t/* --- cacheline 2 boundary (128 bytes) --- */\n\tatomic64_t refcnt __attribute__((__aligned__(64))); /* 128 8 */\n\t...\n\t/* size: 256', ' cachelines: 4', ' members: 30 */\n\t/* sum members: 232', ' holes: 1', ' sum holes: 16 */\n\t/* padding: 8 */\n\t/* paddings: 1', ' sum paddings: 2 */\n} __attribute__((__aligned__(64)));\n\nstruct bpf_array {\n\tstruct bpf_map map; /* 0 256 */\n\t...\n\t/* size: 320', ' cachelines: 5', ' members: 5 */\n\t/* padding: 48 */\n\t/* paddings: 1', ' sum paddings: 8 */\n} __attribute__((__aligned__(64)));\n\nAFTER:\n\nstruct bpf_map {\n\t/* size: 232', ' cachelines: 4', ' members: 30 */\n\t/* paddings: 1', ' sum paddings: 2 */\n\t/* last cacheline: 40 bytes */\n};\nstruct bpf_array {\n\t/* size: 248', ' cachelines: 4', ' members: 5 */\n\t/* last cacheline: 56 bytes */\n};\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240220235001.57411-1-alexei.starovoitov@gmail.com\n', '']",The commit reduces the size of struct bpf_map and struct bpf_array to improve efficiency.,"bpf_map,bpf_array,shrinking",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +01dbd7d8720a0cc97dad5e70ec674dacdc66cf3c,01dbd7d8720a0cc97dad5e70ec674dacdc66cf3c,Alexei Starovoitov,ast@kernel.org,1708470662,Alexei Starovoitov,ast@kernel.org,1708552154,81b0943a028be74b939afd8fb83dacdd6c3ee738,7648f0c91eaa3598add9e91991a5483b29da32ee,"selftests/bpf: Remove intermediate test files. + +The test of linking process creates several intermediate files. +Remove them once the build is over. + +This reduces the number of files in selftests/bpf/ directory +from ~4400 to ~2600. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240220231102.49090-1-alexei.starovoitov@gmail.com +",,The commit removes intermediate test files in selftests/bpf to reduce directory clutter.,"selftests, intermediate, files",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +4cd12c6065dfcdeba10f49949bffcf383b3952d8,4cd12c6065dfcdeba10f49949bffcf383b3952d8,Shigeru Yoshida,syoshida@redhat.com,1708268973,Daniel Borkmann,daniel@iogearbox.net,1708532123,5636131fbde49ba080526f386b244e72cbcbace1,5c138a8a4abe152fcbef1ed40a6a4b5727b2991b,bpf," sockmap: Fix NULL pointer dereference in sk_psock_verdict_data_ready() + +syzbot reported the following NULL pointer dereference issue [1]: + + BUG: kernel NULL pointer dereference","[' address: 0000000000000000\n [...]\n RIP: 0010:0x0\n [...]\n Call Trace:\n \n sk_psock_verdict_data_ready+0x232/0x340 net/core/skmsg.c:1230\n unix_stream_sendmsg+0x9b4/0x1230 net/unix/af_unix.c:2293\n sock_sendmsg_nosec net/socket.c:730 [inline]\n __sock_sendmsg+0x221/0x270 net/socket.c:745\n ____sys_sendmsg+0x525/0x7d0 net/socket.c:2584\n ___sys_sendmsg net/socket.c:2638 [inline]\n __sys_sendmsg+0x2b0/0x3a0 net/socket.c:2667\n do_syscall_64+0xf9/0x240\n entry_SYSCALL_64_after_hwframe+0x6f/0x77\n\nIf sk_psock_verdict_data_ready() and sk_psock_stop_verdict() are called\nconcurrently', ' psock->saved_data_ready can be NULL', ' causing the above issue.\n\nThis patch fixes this issue by calling the appropriate data ready function\nusing the sk_psock_data_ready() helper and protecting it from concurrency\nwith sk->sk_callback_lock.\n\nFixes: 6df7f764cd3c (""bpf', ' sockmap: Wake up polling after data copy"")\nReported-by: syzbot+fd7b34375c1c8ce29c93@syzkaller.appspotmail.com\nSigned-off-by: Shigeru Yoshida \nSigned-off-by: Daniel Borkmann \nTested-by: syzbot+fd7b34375c1c8ce29c93@syzkaller.appspotmail.com\nAcked-by: John Fastabend \nCloses: https://syzkaller.appspot.com/bug?extid=fd7b34375c1c8ce29c93 [1]\nLink: https://lore.kernel.org/bpf/20240218150933.6004-1-syoshida@redhat.com\n', '']",Fixes a NULL pointer dereference issue in sk_psock_verdict_data_ready().,"NULL, pointer, dereference",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,['socket like programs'] +56667da7399eb19af857e30f41bea89aa6fa812c,56667da7399eb19af857e30f41bea89aa6fa812c,Eric Dumazet,edumazet@google.com,1708351940,David S. Miller,davem@davemloft.net,1708514660,f3d61fc0ba42af287720204d892fbc0e1268669f,3b1ae9b71c2a97f848b00fb085a2bd29bddbe8d9,"net: implement lockless setsockopt(SO_PEEK_OFF) + +syzbot reported a lockdep violation [1] involving af_unix +support of SO_PEEK_OFF. + +Since SO_PEEK_OFF is inherently not thread safe (it uses a per-socket +sk_peek_off field)"," there is really no point to enforce a pointless +thread safety in the kernel. + +After this patch : + +- setsockopt(SO_PEEK_OFF) no longer acquires the socket lock. + +- skb_consume_udp() no longer has to acquire the socket lock. + +- af_unix no longer needs a special version of sk_set_peek_off()","['\n because it does not lock u->iolock anymore.\n\nAs a followup', ' we could replace prot->set_peek_off to be a boolean\nand avoid an indirect call', ' since we always use sk_set_peek_off().\n\n[1]\n\nWARNING: possible circular locking dependency detected\n6.8.0-rc4-syzkaller-00267-g0f1dd5e91e2b #0 Not tainted\n\nsyz-executor.2/30025 is trying to acquire lock:\n ffff8880765e7d80 (&u->iolock){+.+.}-{3:3}', ' at: unix_set_peek_off+0x26/0xa0 net/unix/af_unix.c:789\n\nbut task is already holding lock:\n ffff8880765e7930 (sk_lock-AF_UNIX){+.+.}-{0:0}', ' at: lock_sock include/net/sock.h:1691 [inline]\n ffff8880765e7930 (sk_lock-AF_UNIX){+.+.}-{0:0}', ' at: sockopt_lock_sock net/core/sock.c:1060 [inline]\n ffff8880765e7930 (sk_lock-AF_UNIX){+.+.}-{0:0}', ' at: sk_setsockopt+0xe52/0x3360 net/core/sock.c:1193\n\nwhich lock already depends on the new lock.\n\nthe existing dependency chain (in reverse order) is:\n\n-> #1 (sk_lock-AF_UNIX){+.+.}-{0:0}:\n lock_acquire+0x1e3/0x530 kernel/locking/lockdep.c:5754\n lock_sock_nested+0x48/0x100 net/core/sock.c:3524\n lock_sock include/net/sock.h:1691 [inline]\n __unix_dgram_recvmsg+0x1275/0x12c0 net/unix/af_unix.c:2415\n sock_recvmsg_nosec+0x18e/0x1d0 net/socket.c:1046\n ____sys_recvmsg+0x3c0/0x470 net/socket.c:2801\n ___sys_recvmsg net/socket.c:2845 [inline]\n do_recvmmsg+0x474/0xae0 net/socket.c:2939\n __sys_recvmmsg net/socket.c:3018 [inline]\n __do_sys_recvmmsg net/socket.c:3041 [inline]\n __se_sys_recvmmsg net/socket.c:3034 [inline]\n __x64_sys_recvmmsg+0x199/0x250 net/socket.c:3034\n do_syscall_64+0xf9/0x240\n entry_SYSCALL_64_after_hwframe+0x6f/0x77\n\n-> #0 (&u->iolock){+.+.}-{3:3}:\n check_prev_add kernel/locking/lockdep.c:3134 [inline]\n check_prevs_add kernel/locking/lockdep.c:3253 [inline]\n validate_chain+0x18ca/0x58e0 kernel/locking/lockdep.c:3869\n __lock_acquire+0x1345/0x1fd0 kernel/locking/lockdep.c:5137\n lock_acquire+0x1e3/0x530 kernel/locking/lockdep.c:5754\n __mutex_lock_common kernel/locking/mutex.c:608 [inline]\n __mutex_lock+0x136/0xd70 kernel/locking/mutex.c:752\n unix_set_peek_off+0x26/0xa0 net/unix/af_unix.c:789\n sk_setsockopt+0x207e/0x3360\n do_sock_setsockopt+0x2fb/0x720 net/socket.c:2307\n __sys_setsockopt+0x1ad/0x250 net/socket.c:2334\n __do_sys_setsockopt net/socket.c:2343 [inline]\n __se_sys_setsockopt net/socket.c:2340 [inline]\n __x64_sys_setsockopt+0xb5/0xd0 net/socket.c:2340\n do_syscall_64+0xf9/0x240\n entry_SYSCALL_64_after_hwframe+0x6f/0x77\n\nother info that might help us debug this:\n\n Possible unsafe locking scenario:\n\n CPU0 CPU1\n ---- ----\n lock(sk_lock-AF_UNIX);\n lock(&u->iolock);\n lock(sk_lock-AF_UNIX);\n lock(&u->iolock);\n\n *** DEADLOCK ***\n\n1 lock held by syz-executor.2/30025:\n #0: ffff8880765e7930 (sk_lock-AF_UNIX){+.+.}-{0:0}', ' at: lock_sock include/net/sock.h:1691 [inline]\n #0: ffff8880765e7930 (sk_lock-AF_UNIX){+.+.}-{0:0}', ' at: sockopt_lock_sock net/core/sock.c:1060 [inline]\n #0: ffff8880765e7930 (sk_lock-AF_UNIX){+.+.}-{0:0}', ' at: sk_setsockopt+0xe52/0x3360 net/core/sock.c:1193\n\nstack backtrace:\nCPU: 0 PID: 30025 Comm: syz-executor.2 Not tainted 6.8.0-rc4-syzkaller-00267-g0f1dd5e91e2b #0\nHardware name: Google Google Compute Engine/Google Compute Engine', ' BIOS Google 01/25/2024\nCall Trace:\n \n __dump_stack lib/dump_stack.c:88 [inline]\n dump_stack_lvl+0x1e7/0x2e0 lib/dump_stack.c:106\n check_noncircular+0x36a/0x4a0 kernel/locking/lockdep.c:2187\n check_prev_add kernel/locking/lockdep.c:3134 [inline]\n check_prevs_add kernel/locking/lockdep.c:3253 [inline]\n validate_chain+0x18ca/0x58e0 kernel/locking/lockdep.c:3869\n __lock_acquire+0x1345/0x1fd0 kernel/locking/lockdep.c:5137\n lock_acquire+0x1e3/0x530 kernel/locking/lockdep.c:5754\n __mutex_lock_common kernel/locking/mutex.c:608 [inline]\n __mutex_lock+0x136/0xd70 kernel/locking/mutex.c:752\n unix_set_peek_off+0x26/0xa0 net/unix/af_unix.c:789\n sk_setsockopt+0x207e/0x3360\n do_sock_setsockopt+0x2fb/0x720 net/socket.c:2307\n __sys_setsockopt+0x1ad/0x250 net/socket.c:2334\n __do_sys_setsockopt net/socket.c:2343 [inline]\n __se_sys_setsockopt net/socket.c:2340 [inline]\n __x64_sys_setsockopt+0xb5/0xd0 net/socket.c:2340\n do_syscall_64+0xf9/0x240\n entry_SYSCALL_64_after_hwframe+0x6f/0x77\nRIP: 0033:0x7f78a1c7dda9\nCode: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48\nRSP: 002b:00007f78a0fde0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000036\nRAX: ffffffffffffffda RBX: 00007f78a1dac050 RCX: 00007f78a1c7dda9\nRDX: 000000000000002a RSI: 0000000000000001 RDI: 0000000000000006\nRBP: 00007f78a1cca47a R08: 0000000000000004 R09: 0000000000000000\nR10: 0000000020000180 R11: 0000000000000246 R12: 0000000000000000\nR13: 000000000000006e R14: 00007f78a1dac050 R15: 00007ffe5cd81ae8\n\nFixes: 859051dd165e (""bpf: Implement cgroup sockaddr hooks for unix sockets"")\nSigned-off-by: Eric Dumazet \nCc: Willem de Bruijn \nCc: Daan De Meyer \nCc: Kuniyuki Iwashima \nCc: Martin KaFai Lau \nCc: David Ahern \nReviewed-by: Willem de Bruijn \nReviewed-by: Kuniyuki Iwashima \nSigned-off-by: David S. Miller \n', '']",Implemented a lockless version of setsockopt for SO_PEEK_OFF to prevent a lockdep violation in af_unix.,"lockless,setsockopt,SO_PEEK_OFF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,"['socket like programs', 'other']" +5d4cc87414c5d11345c4b11d61377d351b5c28a2,5d4cc87414c5d11345c4b11d61377d351b5c28a2,Eric Dumazet,edumazet@google.com,1708100406,Paolo Abeni,pabeni@redhat.com,1708426905,1ae0e74ca86ec95d5e670634a404043f4212a20a,465c1abcb64426f0ff39e80e508e2432672c2dae,"net: reorganize ""struct sock"" fields + +Last major reorg happened in commit 9115e8cd2a0c (""net: reorganize +struct sock for better data locality"") + +Since then"," many changes have been done. + +Before SO_PEEK_OFF support is added to TCP","[' we need\nto move sk_peek_off to a better location.\n\nIt is time to make another pass', ' and add six groups', '\nwithout explicit alignment.\n\n- sock_write_rx (following sk_refcnt) read-write fields in rx path.\n- sock_read_rx read-mostly fields in rx path.\n- sock_read_rxtx read-mostly fields in both rx and tx paths.\n- sock_write_rxtx read-write fields in both rx and tx paths.\n- sock_write_tx read-write fields in tx paths.\n- sock_read_tx read-mostly fields in tx paths.\n\nResults on TCP_RR benchmarks seem to show a gain (4 to 5 %).\n\nIt is possible UDP needs a change', ' because sk_peek_off\nshares a cache line with sk_receive_queue.\nIf this the case', ' we can exchange roles of sk->sk_receive\nand up->reader_queue queues.\n\nAfter this change', ' we have the following layout:\n\nstruct sock {\n\tstruct sock_common __sk_common; /* 0 0x88 */\n\t/* --- cacheline 2 boundary (128 bytes) was 8 bytes ago --- */\n\t__u8 __cacheline_group_begin__sock_write_rx[0]; /* 0x88 0 */\n\tatomic_t sk_drops; /* 0x88 0x4 */\n\t__s32 sk_peek_off; /* 0x8c 0x4 */\n\tstruct sk_buff_head sk_error_queue; /* 0x90 0x18 */\n\tstruct sk_buff_head sk_receive_queue; /* 0xa8 0x18 */\n\t/* --- cacheline 3 boundary (192 bytes) --- */\n\tstruct {\n\t\tatomic_t rmem_alloc; /* 0xc0 0x4 */\n\t\tint len; /* 0xc4 0x4 */\n\t\tstruct sk_buff * head; /* 0xc8 0x8 */\n\t\tstruct sk_buff * tail; /* 0xd0 0x8 */\n\t} sk_backlog; /* 0xc0 0x18 */\n\tstruct {\n\t\tatomic_t rmem_alloc; /* 0 0x4 */\n\t\tint len; /* 0x4 0x4 */\n\t\tstruct sk_buff * head; /* 0x8 0x8 */\n\t\tstruct sk_buff * tail; /* 0x10 0x8 */\n\n\t\t/* size: 24', ' cachelines: 1', ' members: 4 */\n\t\t/* last cacheline: 24 bytes */\n\t};\n\n\t__u8 __cacheline_group_end__sock_write_rx[0]; /* 0xd8 0 */\n\t__u8 __cacheline_group_begin__sock_read_rx[0]; /* 0xd8 0 */\n\trcu * sk_rx_dst; /* 0xd8 0x8 */\n\tint sk_rx_dst_ifindex; /* 0xe0 0x4 */\n\tu32 sk_rx_dst_cookie; /* 0xe4 0x4 */\n\tunsigned int sk_ll_usec; /* 0xe8 0x4 */\n\tunsigned int sk_napi_id; /* 0xec 0x4 */\n\tu16 sk_busy_poll_budget; /* 0xf0 0x2 */\n\tu8 sk_prefer_busy_poll; /* 0xf2 0x1 */\n\tu8 sk_userlocks; /* 0xf3 0x1 */\n\tint sk_rcvbuf; /* 0xf4 0x4 */\n\trcu * sk_filter; /* 0xf8 0x8 */\n\t/* --- cacheline 4 boundary (256 bytes) --- */\n\tunion {\n\t\trcu * sk_wq; /* 0x100 0x8 */\n\t\tstruct socket_wq * sk_wq_raw; /* 0x100 0x8 */\n\t}; /* 0x100 0x8 */\n\tunion {\n\t\trcu * sk_wq; /* 0 0x8 */\n\t\tstruct socket_wq * sk_wq_raw; /* 0 0x8 */\n\t};\n\n\tvoid (*sk_data_ready)(struct sock *); /* 0x108 0x8 */\n\tlong sk_rcvtimeo; /* 0x110 0x8 */\n\tint sk_rcvlowat; /* 0x118 0x4 */\n\t__u8 __cacheline_group_end__sock_read_rx[0]; /* 0x11c 0 */\n\t__u8 __cacheline_group_begin__sock_read_rxtx[0]; /* 0x11c 0 */\n\tint sk_err; /* 0x11c 0x4 */\n\tstruct socket * sk_socket; /* 0x120 0x8 */\n\tstruct mem_cgroup * sk_memcg; /* 0x128 0x8 */\n\trcu * sk_policy[2]; /* 0x130 0x10 */\n\t/* --- cacheline 5 boundary (320 bytes) --- */\n\t__u8 __cacheline_group_end__sock_read_rxtx[0]; /* 0x140 0 */\n\t__u8 __cacheline_group_begin__sock_write_rxtx[0]; /* 0x140 0 */\n\tsocket_lock_t sk_lock; /* 0x140 0x20 */\n\tu32 sk_reserved_mem; /* 0x160 0x4 */\n\tint sk_forward_alloc; /* 0x164 0x4 */\n\tu32 sk_tsflags; /* 0x168 0x4 */\n\t__u8 __cacheline_group_end__sock_write_rxtx[0]; /* 0x16c 0 */\n\t__u8 __cacheline_group_begin__sock_write_tx[0]; /* 0x16c 0 */\n\tint sk_write_pending; /* 0x16c 0x4 */\n\tatomic_t sk_omem_alloc; /* 0x170 0x4 */\n\tint sk_sndbuf; /* 0x174 0x4 */\n\tint sk_wmem_queued; /* 0x178 0x4 */\n\trefcount_t sk_wmem_alloc; /* 0x17c 0x4 */\n\t/* --- cacheline 6 boundary (384 bytes) --- */\n\tunsigned long sk_tsq_flags; /* 0x180 0x8 */\n\tunion {\n\t\tstruct sk_buff * sk_send_head; /* 0x188 0x8 */\n\t\tstruct rb_root tcp_rtx_queue; /* 0x188 0x8 */\n\t}; /* 0x188 0x8 */\n\tunion {\n\t\tstruct sk_buff * sk_send_head; /* 0 0x8 */\n\t\tstruct rb_root tcp_rtx_queue; /* 0 0x8 */\n\t};\n\n\tstruct sk_buff_head sk_write_queue; /* 0x190 0x18 */\n\tu32 sk_dst_pending_confirm; /* 0x1a8 0x4 */\n\tu32 sk_pacing_status; /* 0x1ac 0x4 */\n\tstruct page_frag sk_frag; /* 0x1b0 0x10 */\n\t/* --- cacheline 7 boundary (448 bytes) --- */\n\tstruct timer_list sk_timer; /* 0x1c0 0x28 */\n\n\t/* XXX last struct has 4 bytes of padding */\n\n\tunsigned long sk_pacing_rate; /* 0x1e8 0x8 */\n\tatomic_t sk_zckey; /* 0x1f0 0x4 */\n\tatomic_t sk_tskey; /* 0x1f4 0x4 */\n\t__u8 __cacheline_group_end__sock_write_tx[0]; /* 0x1f8 0 */\n\t__u8 __cacheline_group_begin__sock_read_tx[0]; /* 0x1f8 0 */\n\tunsigned long sk_max_pacing_rate; /* 0x1f8 0x8 */\n\t/* --- cacheline 8 boundary (512 bytes) --- */\n\tlong sk_sndtimeo; /* 0x200 0x8 */\n\tu32 sk_priority; /* 0x208 0x4 */\n\tu32 sk_mark; /* 0x20c 0x4 */\n\trcu * sk_dst_cache; /* 0x210 0x8 */\n\tnetdev_features_t sk_route_caps; /* 0x218 0x8 */\n\tu16 sk_gso_type; /* 0x220 0x2 */\n\tu16 sk_gso_max_segs; /* 0x222 0x2 */\n\tunsigned int sk_gso_max_size; /* 0x224 0x4 */\n\tgfp_t sk_allocation; /* 0x228 0x4 */\n\tu32 sk_txhash; /* 0x22c 0x4 */\n\tu8 sk_pacing_shift; /* 0x230 0x1 */\n\tbool sk_use_task_frag; /* 0x231 0x1 */\n\t__u8 __cacheline_group_end__sock_read_tx[0]; /* 0x232 0 */\n\tu8 sk_gso_disabled:1; /* 0x232: 0 0x1 */\n\tu8 sk_kern_sock:1; /* 0x232:0x1 0x1 */\n\tu8 sk_no_check_tx:1; /* 0x232:0x2 0x1 */\n\tu8 sk_no_check_rx:1; /* 0x232:0x3 0x1 */\n\n\t/* XXX 4 bits hole', ' try to pack */\n\n\tu8 sk_shutdown; /* 0x233 0x1 */\n\tu16 sk_type; /* 0x234 0x2 */\n\tu16 sk_protocol; /* 0x236 0x2 */\n\tunsigned long sk_lingertime; /* 0x238 0x8 */\n\t/* --- cacheline 9 boundary (576 bytes) --- */\n\tstruct proto * sk_prot_creator; /* 0x240 0x8 */\n\trwlock_t sk_callback_lock; /* 0x248 0x8 */\n\tint sk_err_soft; /* 0x250 0x4 */\n\tu32 sk_ack_backlog; /* 0x254 0x4 */\n\tu32 sk_max_ack_backlog; /* 0x258 0x4 */\n\tkuid_t sk_uid; /* 0x25c 0x4 */\n\tspinlock_t sk_peer_lock; /* 0x260 0x4 */\n\tint sk_bind_phc; /* 0x264 0x4 */\n\tstruct pid * sk_peer_pid; /* 0x268 0x8 */\n\tconst struct cred * sk_peer_cred; /* 0x270 0x8 */\n\tktime_t sk_stamp; /* 0x278 0x8 */\n\t/* --- cacheline 10 boundary (640 bytes) --- */\n\tint sk_disconnects; /* 0x280 0x4 */\n\tu8 sk_txrehash; /* 0x284 0x1 */\n\tu8 sk_clockid; /* 0x285 0x1 */\n\tu8 sk_txtime_deadline_mode:1; /* 0x286: 0 0x1 */\n\tu8 sk_txtime_report_errors:1; /* 0x286:0x1 0x1 */\n\tu8 sk_txtime_unused:6; /* 0x286:0x2 0x1 */\n\n\t/* XXX 1 byte hole', ' try to pack */\n\n\tvoid * sk_user_data; /* 0x288 0x8 */\n\tvoid * sk_security; /* 0x290 0x8 */\n\tstruct sock_cgroup_data sk_cgrp_data; /* 0x298 0x8 */\n\tvoid (*sk_state_change)(struct sock *); /* 0x2a0 0x8 */\n\tvoid (*sk_write_space)(struct sock *); /* 0x2a8 0x8 */\n\tvoid (*sk_error_report)(struct sock *); /* 0x2b0 0x8 */\n\tint (*sk_backlog_rcv)(struct sock *', ' struct sk_buff *); /* 0x2b8 0x8 */\n\t/* --- cacheline 11 boundary (704 bytes) --- */\n\tvoid (*sk_destruct)(struct sock *); /* 0x2c0 0x8 */\n\trcu * sk_reuseport_cb; /* 0x2c8 0x8 */\n\trcu * sk_bpf_storage; /* 0x2d0 0x8 */\n\tstruct callback_head sk_rcu __attribute__((__aligned__(8))); /* 0x2d8 0x10 */\n\tnetns_tracker ns_tracker; /* 0x2e8 0x8 */\n\n\t/* size: 752', ' cachelines: 12', ' members: 105 */\n\t/* sum members: 749', ' holes: 1', ' sum holes: 1 */\n\t/* sum bitfield members: 12 bits', ' bit holes: 1', ' sum bit holes: 4 bits */\n\t/* paddings: 1', ' sum paddings: 4 */\n\t/* forced alignments: 1 */\n\t/* last cacheline: 48 bytes */\n};\n\nSigned-off-by: Eric Dumazet \nAcked-by: Paolo Abeni \nLink: https://lore.kernel.org/r/20240216162006.2342759-1-edumazet@google.com\nSigned-off-by: Paolo Abeni \n', '']",Reorganize struct sock fields for better data locality.,"reorganize, struct sock, data locality",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +5c138a8a4abe152fcbef1ed40a6a4b5727b2991b,5c138a8a4abe152fcbef1ed40a6a4b5727b2991b,Yafang Shao,laoar.shao@gmail.com,1708170112,Daniel Borkmann,daniel@iogearbox.net,1708342095,c9aee41673c07d98b333e9ab9e87d7b0535bb9bd,5f2ae606cb5a90839a9be9d22388c4200f820e75,"selftests/bpf: Add negtive test cases for task iter + +Incorporate a test case to assess the handling of invalid flags or +task__nullable parameters passed to bpf_iter_task_new(). Prior to the +preceding commit"," this scenario could potentially trigger a kernel panic. +However","[' with the previous commit', ' this test case is expected to function\ncorrectly.\n\nSigned-off-by: Yafang Shao \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240217114152.1623-3-laoar.shao@gmail.com\n', '']",Add negative test cases to bpf_iter_task_new to prevent kernel panics with invalid inputs.,"negtive,test cases,task iter",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5f2ae606cb5a90839a9be9d22388c4200f820e75,5f2ae606cb5a90839a9be9d22388c4200f820e75,Yafang Shao,laoar.shao@gmail.com,1708170111,Daniel Borkmann,daniel@iogearbox.net,1708342095,95d2c6a9b5d7acb4ea4d1581f15b7e5dc3aa480d,3f00e4a9c96f4488a924aff4e35b77c8eced897e,"bpf: Fix an issue due to uninitialized bpf_iter_task + +Failure to initialize it->pos"," coupled with the presence of an invalid +value in the flags variable","[' can lead to it->pos referencing an invalid\ntask', ' potentially resulting in a kernel panic. To mitigate this risk', ' it\'s\ncrucial to ensure proper initialization of it->pos to NULL.\n\nFixes: ac8148d957f5 (""bpf: bpf_iter_task_next: use next_task(kit->task) rather than next_task(kit->pos)"")\nSigned-off-by: Yafang Shao \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nAcked-by: Oleg Nesterov \nLink: https://lore.kernel.org/bpf/20240217114152.1623-2-laoar.shao@gmail.com\n', '']",Fixes an issue with uninitialized bpf_iter_task causing invalid values in flags.,"bpf_iter_task,uninitialized,fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3f00e4a9c96f4488a924aff4e35b77c8eced897e,3f00e4a9c96f4488a924aff4e35b77c8eced897e,Martin KaFai Lau,martin.lau@kernel.org,1708031538,Daniel Borkmann,daniel@iogearbox.net,1708342006,f715138a7e72079c5e8608da6113196f1ac19f5d,0281b919e175bb9c3128bd3872ac2903e9436e3f,"selftests/bpf: Test racing between bpf_timer_cancel_and_free and bpf_timer_cancel + +This selftest is based on a Alexei's test adopted from an internal +user to troubleshoot another bug. During this exercise"," a separate +racing bug was discovered between bpf_timer_cancel_and_free +and bpf_timer_cancel. The details can be found in the previous +patch. + +This patch is to add a selftest that can trigger the bug. +I can trigger the UAF everytime in my qemu setup with KASAN. The idea +is to have multiple user space threads running in a tight loop to exercise +both bpf_map_update_elem (which calls into bpf_timer_cancel_and_free) +and bpf_timer_cancel. + +Signed-off-by: Martin KaFai Lau +Signed-off-by: Daniel Borkmann +Acked-by: Hou Tao +Link: https://lore.kernel.org/bpf/20240215211218.990808-2-martin.lau@linux.dev +",[''],Add a selftest to detect race conditions between bpf_timer_cancel_and_free and bpf_timer_cancel.,"selftest,race,bug",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0281b919e175bb9c3128bd3872ac2903e9436e3f,0281b919e175bb9c3128bd3872ac2903e9436e3f,Martin KaFai Lau,martin.lau@kernel.org,1708031537,Daniel Borkmann,daniel@iogearbox.net,1708342006,015d5f0db53ce3761fab03b8173edb45ee9126cf,54d46c9f581d16ac6adad3c3e61766e02bbfcb60,"bpf: Fix racing between bpf_timer_cancel_and_free and bpf_timer_cancel + +The following race is possible between bpf_timer_cancel_and_free +and bpf_timer_cancel. It will lead a UAF on the timer->timer. + +bpf_timer_cancel(); + spin_lock(); + t = timer->time; + spin_unlock(); + + bpf_timer_cancel_and_free(); + spin_lock(); + t = timer->timer; + timer->timer = NULL; + spin_unlock(); + hrtimer_cancel(&t->timer); + kfree(t); + + /* UAF on t */ + hrtimer_cancel(&t->timer); + +In bpf_timer_cancel_and_free"," this patch frees the timer->timer +after a rcu grace period. This requires a rcu_head addition +to the ""struct bpf_hrtimer"". Another kfree(t) happens in bpf_timer_init","['\nthis does not need a kfree_rcu because it is still under the\nspin_lock and timer->timer has not been visible by others yet.\n\nIn bpf_timer_cancel', ' rcu_read_lock() is added because this helper\ncan be used in a non rcu critical section context (e.g. from\na sleepable bpf prog). Other timer->timer usages in helpers.c\nhave been audited', ' bpf_timer_cancel() is the only place where\ntimer->timer is used outside of the spin_lock.\n\nAnother solution considered is to mark a t->flag in bpf_timer_cancel\nand clear it after hrtimer_cancel() is done. In bpf_timer_cancel_and_free', '\nit busy waits for the flag to be cleared before kfree(t). This patch\ngoes with a straight forward solution and frees timer->timer after\na rcu grace period.\n\nFixes: b00628b1c7d5 (""bpf: Introduce bpf timers."")\nSuggested-by: Alexei Starovoitov \nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Daniel Borkmann \nAcked-by: Hou Tao \nLink: https://lore.kernel.org/bpf/20240215211218.990808-1-martin.lau@linux.dev\n', '']",Fix race condition in bpf_timer_cancel_and_free leading to use-after-free on timers.,"bpf_timer,race condition,use-after-free",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.",['kprobe/uprobe/ftrace like programs'] +ac00b6546d390bc12d1d2824c2b5d95046097eb2,ac00b6546d390bc12d1d2824c2b5d95046097eb2,Linus Torvalds,torvalds@linux-foundation.org,1708186412,Linus Torvalds,torvalds@linux-foundation.org,1708186412,1e71beb5f40035be915687abb55db633583bc03f,4a7571485c467b76cc19fae304452fd56921c789 346c84e281a963437b9fe9dfcd92c531630289de,"Merge tag 'media/v6.8-4' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media + +Pull media fixes from Mauro Carvalho Chehab: + + - regression fix for rkisp1 shared IRQ logic + + - fix atomisp breakage due to a kAPI change + + - permission fix for remote controller BPF support + + - memleak fix in ir_toy driver + + - Kconfig dependency fix for pwm-ir-rx + +* tag 'media/v6.8-4' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: + media: pwm-ir-tx: Depend on CONFIG_HIGH_RES_TIMERS + media: ir_toy: fix a memleak in irtoy_tx + media: rc: bpf attach/detach requires write permission + media: atomisp: Adjust for v4l2_subdev_state handling changes in 6.8 + media: rkisp1: Fix IRQ handling due to shared interrupts + media: Revert ""media: rkisp1: Drop IRQF_SHARED"" +",,"Merge media fixes including IRQ logic, kAPI changes, and memory leak corrections.","media, fixes, IRQ",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +bacefe0c7b77b7527a613e053b6d378412a8a779,bacefe0c7b77b7527a613e053b6d378412a8a779,Namhyung Kim,namhyung@kernel.org,1707780802,Namhyung Kim,namhyung@kernel.org,1708128448,db162f3ec5e37f61b6acc4708ff902d9e811d539,6f146b249b3ada0082209b34abf01c90c702a96b,"perf tools: Fixup module symbol end address properly + +I got a strange error on ARM to fail on processing FINISHED_ROUND +record. It turned out that it was failing in symbol__alloc_hist() +because the symbol size is too big. + +When a sample is captured on a specific BPF program"," it failed. I've +added a debug code and found the end address of the symbol is from +the next module which is placed far way. + + ffff800008795778-ffff80000879d6d8: bpf_prog_1bac53b8aac4bc58_netcg_sock [bpf] + ffff80000879d6d8-ffff80000ad656b4: bpf_prog_76867454b5944e15_netcg_getsockopt [bpf] + ffff80000ad656b4-ffffd69b7af74048: bpf_prog_1d50286d2eb1be85_hn_egress [bpf] <---------- here + ffffd69b7af74048-ffffd69b7af74048: $x.5 [sha3_generic] + ffffd69b7af74048-ffffd69b7af740b8: crypto_sha3_init [sha3_generic] + ffffd69b7af740b8-ffffd69b7af741e0: crypto_sha3_update [sha3_generic] + +The logic in symbols__fixup_end() just uses curr->start to update the +prev->end. But in this case","["" it won't work as it's too different.\n\nI think ARM has a different kernel memory layout for modules and BPF\nthan on x86. Actually there's a logic to handle kernel and module\nboundary. Let's do the same for symbols between different modules.\n\nSigned-off-by: Namhyung Kim \nReviewed-by: Leo Yan \nCc: Will Deacon \nCc: Mike Leach \nCc: John Garry \nLink: https://lore.kernel.org/r/20240212233322.1855161-1-namhyung@kernel.org\n"", '']",Fixes end address calculation for module symbols in perf tools on ARM.,"perf tools, symbol, ARM",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +29d16de26df17e94dd0310dc83c37f82b48a59cf,29d16de26df17e94dd0310dc83c37f82b48a59cf,Arnaldo Carvalho de Melo,acme@kernel.org,1708122023,Namhyung Kim,namhyung@kernel.org,1708125597,a343299a1911d83be2f4eeab8ea8822c1127d4ae,f512e08fd0940fcd811d24e2cfd95683fe8042c3,"perf augmented_raw_syscalls.bpf: Move 'struct timespec64' to vmlinux.h + +If we instead decide to generate vmlinux.h from BTF info"," it will be +there: + + $ pahole timespec64 + struct timespec64 { + time64_t tv_sec; /* 0 8 */ + long int tv_nsec; /* 8 8 */ + + /* size: 16","[' cachelines: 1', ' members: 2 */\n \t/* last cacheline: 16 bytes */\n };\n\n $\n\npahole manages to find it from /sys/kernel/btf/vmlinux', "" that is\ngenerated from the kernel types.\n\nWith this linux/bpf.h doesn't need to be included"", ' as its already in the\nminimalistic tools/perf/util/bpf_skel/vmlinux/vmlinux.h file or what we\nneed comes when generating a vmlinux.h file from BTF info', ' i.e. when\nusing GEN_VMLINUX_H=1', ' as noticed by Namyung in a build break before\nremoving linux/bpf.h.\n\nSigned-off-by: Arnaldo Carvalho de Melo \nSigned-off-by: Namhyung Kim \nLink: https://lore.kernel.org/r/Zc_fp6CgDClPhS_O@x1\n', '']",Moved 'struct timespec64' definition to vmlinux.h in perf augmented_raw_syscalls.bpf.,"timespec64,vmlinux.h,perf",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),['tracepoints like programs'] +7648f0c91eaa3598add9e91991a5483b29da32ee,7648f0c91eaa3598add9e91991a5483b29da32ee,Marcos Paulo de Souza,mpdesouza@suse.com,1708087365,Daniel Borkmann,daniel@iogearbox.net,1708103306,6b92bed7c484661dd0b66c422490693bdb835ae2,682158ab532a5bd24399fec25b65fec561f0f6e9,"selftests/bpf: Remove empty TEST_CUSTOM_PROGS + +Commit f04a32b2c5b5 (""selftests/bpf: Do not use sign-file as testcase"") +removed the TEST_CUSTOM_PROGS assignment"," and removed it from being used +on TEST_GEN_FILES. Remove two leftovers from that cleanup. Found by +inspection. + +Signed-off-by: Marcos Paulo de Souza +Signed-off-by: Daniel Borkmann +Cc: Alexey Gladkov +Link: https://lore.kernel.org/bpf/20240216-bpf-selftests-custom-progs-v1-1-f7cf281a1fda@suse.com +",[''],The commit removes leftover entries relating to TEST_CUSTOM_PROGS in selftests for BPF.,"selftests,bpf,cleanup",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +54d46c9f581d16ac6adad3c3e61766e02bbfcb60,54d46c9f581d16ac6adad3c3e61766e02bbfcb60,Alexei Starovoitov,ast@kernel.org,1708053699,Alexei Starovoitov,ast@kernel.org,1708053699,28462df0448f891d561b5d843fea7360145e8aa5,e37243b65d528a8a9f8b9a57a43885f8e8dfc15c be66d79189ec8a1006ec6ec302bb27b160b3e6ce,"Merge branch 'fix-the-read-of-vsyscall-page-through-bpf' + +Hou Tao says: + +==================== +Fix the read of vsyscall page through bpf + +From: Hou Tao + +Hi"," + +As reported by syzboot [1] and [2]","[' when trying to read vsyscall page\nby using bpf_probe_read_kernel() or bpf_probe_read()', ' oops may happen.\n\nThomas Gleixner had proposed a test patch [3]', ' but it seems that no\nformal patch is posted after about one month [4]', ' so I post it instead\nand add an Originally-by tag in patch #2.\n\nPatch #1 makes is_vsyscall_vaddr() being a common helper. Patch #2 fixes\nthe problem by disallowing vsyscall page read for\ncopy_from_kernel_nofault(). Patch #3 adds one test case to ensure the\nread of vsyscall page through bpf is rejected. Please see individual\npatches for more details.\n\nComments are always welcome.\n\n[1]: https://lore.kernel.org/bpf/CAG48ez06TZft=ATH1qh2c5mpS5BT8UakwNkzi6nvK5_djC-4Nw@mail.gmail.com/\n[2]: https://lore.kernel.org/bpf/CABOYnLynjBoFZOf3Z4BhaZkc5hx_kHfsjiW+UWLoB=w33LvScw@mail.gmail.com/\n[3]: https://lore.kernel.org/bpf/87r0jwquhv.ffs@tglx/\n[4]: https://lore.kernel.org/bpf/e24b125c-8ff4-9031-6c53-67ff2e01f316@huaweicloud.com/\n\nChange Log:\nv3:\n * rephrase commit message for patch #1 & #2 (Sohil)\n * reword comments in copy_from_kernel_nofault_allowed() (Sohil)\n * add Rvb tag for patch #1 and Acked-by tag for patch #3 (Sohil', ' Yonghong)\n\nv2: https://lore.kernel.org/bpf/20240126115423.3943360-1-houtao@huaweicloud.com/\n * move is_vsyscall_vaddr to asm/vsyscall.h instead (Sohil)\n * elaborate on the reason for disallowing of vsyscall page read in\n copy_from_kernel_nofault_allowed() (Sohil)\n * update the commit message of patch #2 to more clearly explain how\n the oops occurs. (Sohil)\n * update the commit message of patch #3 to explain the expected return\n values of various bpf helpers (Yonghong)\n\nv1: https://lore.kernel.org/bpf/20240119073019.1528573-1-houtao@huaweicloud.com/\n====================\n\nLink: https://lore.kernel.org/r/20240202103935.3154011-1-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes issue with reading the vsyscall page through BPF.,"vsyscall, BPF, fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +be66d79189ec8a1006ec6ec302bb27b160b3e6ce,be66d79189ec8a1006ec6ec302bb27b160b3e6ce,Hou Tao,houtao1@huawei.com,1706870375,Alexei Starovoitov,ast@kernel.org,1708053699,28462df0448f891d561b5d843fea7360145e8aa5,32019c659ecfe1d92e3bf9fcdfbb11a7c70acd58,"selftest/bpf: Test the read of vsyscall page under x86-64 + +Under x86-64"," when using bpf_probe_read_kernel{_str}() or +bpf_probe_read{_str}() to read vsyscall page","[' the read may trigger oops', '\nso add one test case to ensure that the problem is fixed. Beside those\nfour bpf helpers mentioned above', ' testing the read of vsyscall page by\nusing bpf_probe_read_user{_str} and bpf_copy_from_user{_task}() as well.\n\nThe test case passes the address of vsyscall page to these six helpers\nand checks whether the returned values are expected:\n\n1) For bpf_probe_read_kernel{_str}()/bpf_probe_read{_str}()', ' the\n expected return value is -ERANGE as shown below:\n\nbpf_probe_read_kernel_common\n copy_from_kernel_nofault\n // false', ' return -ERANGE\n copy_from_kernel_nofault_allowed\n\n2) For bpf_probe_read_user{_str}()', ' the expected return value is -EFAULT\n as show below:\n\nbpf_probe_read_user_common\n copy_from_user_nofault\n // false', ' return -EFAULT\n __access_ok\n\n3) For bpf_copy_from_user()', ' the expected return value is -EFAULT:\n\n// return -EFAULT\nbpf_copy_from_user\n copy_from_user\n _copy_from_user\n // return false\n access_ok\n\n4) For bpf_copy_from_user_task()', ' the expected return value is -EFAULT:\n\n// return -EFAULT\nbpf_copy_from_user_task\n access_process_vm\n // return 0\n vma_lookup()\n // return 0\n expand_stack()\n\nThe occurrence of oops depends on the availability of CPU SMAP [1]\nfeature and there are three possible configurations of vsyscall page in\nthe boot cmd-line: vsyscall={xonly|none|emulate}', ' so there are a total\nof six possible combinations. Under all these combinations', ' the test\ncase runs successfully.\n\n[1]: https://en.wikipedia.org/wiki/Supervisor_Mode_Access_Prevention\n\nAcked-by: Yonghong Song \nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20240202103935.3154011-4-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftest for reading vsyscall page using bpf_probe_read functions under x86-64 architecture.,"selftest, vsyscall, bpf_probe_read",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +32019c659ecfe1d92e3bf9fcdfbb11a7c70acd58,32019c659ecfe1d92e3bf9fcdfbb11a7c70acd58,Hou Tao,houtao1@huawei.com,1706870374,Alexei Starovoitov,ast@kernel.org,1708053699,7651eed33fc33fba0bbfe0bf408b89a02be420f8,ee0e39a63b78849f8abbef268b13e4838569f646,"x86/mm: Disallow vsyscall page read for copy_from_kernel_nofault() + +When trying to use copy_from_kernel_nofault() to read vsyscall page +through a bpf program"," the following oops was reported: + + BUG: unable to handle page fault for address: ffffffffff600000 + #PF: supervisor read access in kernel mode + #PF: error_code(0x0000) - not-present page + PGD 3231067 P4D 3231067 PUD 3233067 PMD 3235067 PTE 0 + Oops: 0000 [#1] PREEMPT SMP PTI + CPU: 1 PID: 20390 Comm: test_progs ...... 6.7.0+ #58 + Hardware name: QEMU Standard PC (i440FX + PIIX","[' 1996) ......\n RIP: 0010:copy_from_kernel_nofault+0x6f/0x110\n ......\n Call Trace:\n \n ? copy_from_kernel_nofault+0x6f/0x110\n bpf_probe_read_kernel+0x1d/0x50\n bpf_prog_2061065e56845f08_do_probe_read+0x51/0x8d\n trace_call_bpf+0xc5/0x1c0\n perf_call_bpf_enter.isra.0+0x69/0xb0\n perf_syscall_enter+0x13e/0x200\n syscall_trace_enter+0x188/0x1c0\n do_syscall_64+0xb5/0xe0\n entry_SYSCALL_64_after_hwframe+0x6e/0x76\n \n ......\n ---[ end trace 0000000000000000 ]---\n\nThe oops is triggered when:\n\n1) A bpf program uses bpf_probe_read_kernel() to read from the vsyscall\npage and invokes copy_from_kernel_nofault() which in turn calls\n__get_user_asm().\n\n2) Because the vsyscall page address is not readable from kernel space', '\na page fault exception is triggered accordingly.\n\n3) handle_page_fault() considers the vsyscall page address as a user\nspace address instead of a kernel space address. This results in the\nfix-up setup by bpf not being applied and a page_fault_oops() is invoked\ndue to SMAP.\n\nConsidering handle_page_fault() has already considered the vsyscall page\naddress as a userspace address', ' fix the problem by disallowing vsyscall\npage read for copy_from_kernel_nofault().\n\nOriginally-by: Thomas Gleixner \nReported-by: syzbot+72aa0161922eba61b50e@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/CAG48ez06TZft=ATH1qh2c5mpS5BT8UakwNkzi6nvK5_djC-4Nw@mail.gmail.com\nReported-by: xingwei lee \nCloses: https://lore.kernel.org/bpf/CABOYnLynjBoFZOf3Z4BhaZkc5hx_kHfsjiW+UWLoB=w33LvScw@mail.gmail.com\nSigned-off-by: Hou Tao \nReviewed-by: Sohil Mehta \nAcked-by: Thomas Gleixner \nLink: https://lore.kernel.org/r/20240202103935.3154011-3-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit disallows reading the vsyscall page through copy_from_kernel_nofault() in x86/mm for bpf programs.,"vsyscall,copy_from_kernel_nofault,page fault",It's a security fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +682158ab532a5bd24399fec25b65fec561f0f6e9,682158ab532a5bd24399fec25b65fec561f0f6e9,Yonghong Song,yonghong.song@linux.dev,1707953391,Alexei Starovoitov,ast@kernel.org,1708033527,b181de0ece77b7575285af9c77080738c22eee7a,57354f5fdee8017783b5cc2e53b263641b6862e9,"bpf: Fix test verif_scale_strobemeta_subprogs failure due to llvm19 + +With latest llvm19"," I hit the following selftest failures with + + $ ./test_progs -j + libbpf: prog 'on_event': BPF program load failed: Permission denied + libbpf: prog 'on_event': -- BEGIN PROG LOAD LOG -- + combined stack size of 4 calls is 544. Too large + verification time 1344153 usec + stack depth 24+440+0+32 + processed 51008 insns (limit 1000000) max_states_per_insn 19 total_states 1467 peak_states 303 mark_read 146 + -- END PROG LOAD LOG -- + libbpf: prog 'on_event': failed to load: -13 + libbpf: failed to load object 'strobemeta_subprogs.bpf.o' + scale_test:FAIL:expect_success unexpected error: -13 (errno 13) + #498 verif_scale_strobemeta_subprogs:FAIL + +The verifier complains too big of the combined stack size (544 bytes) which +exceeds the maximum stack limit 512. This is a regression from llvm19 ([1]). + +In the above error log","["" the original stack depth is 24+440+0+32.\nTo satisfy interpreter's need"", ' in verifier the stack depth is adjusted to\n32+448+32+32=544 which exceeds 512', ' hence the error. The same adjusted\nstack size is also used for jit case.\n\nBut the jitted codes could use smaller stack size.\n\n $ egrep -r stack_depth | grep round_up\n arm64/net/bpf_jit_comp.c: ctx->stack_size = round_up(prog->aux->stack_depth', ' 16);\n loongarch/net/bpf_jit.c: bpf_stack_adjust = round_up(ctx->prog->aux->stack_depth', ' 16);\n powerpc/net/bpf_jit_comp.c: cgctx.stack_size = round_up(fp->aux->stack_depth', ' 16);\n riscv/net/bpf_jit_comp32.c: round_up(ctx->prog->aux->stack_depth', ' STACK_ALIGN);\n riscv/net/bpf_jit_comp64.c: bpf_stack_adjust = round_up(ctx->prog->aux->stack_depth', ' 16);\n s390/net/bpf_jit_comp.c: u32 stack_depth = round_up(fp->aux->stack_depth', ' 8);\n sparc/net/bpf_jit_comp_64.c: stack_needed += round_up(stack_depth', ' 16);\n x86/net/bpf_jit_comp.c: EMIT3_off32(0x48', ' 0x81', ' 0xEC', ' round_up(stack_depth', ' 8));\n x86/net/bpf_jit_comp.c: int tcc_off = -4 - round_up(stack_depth', ' 8);\n x86/net/bpf_jit_comp.c: round_up(stack_depth', ' 8));\n x86/net/bpf_jit_comp.c: int tcc_off = -4 - round_up(stack_depth', ' 8);\n x86/net/bpf_jit_comp.c: EMIT3_off32(0x48', ' 0x81', ' 0xC4', ' round_up(stack_depth', ' 8));\n\nIn the above', ' STACK_ALIGN in riscv/net/bpf_jit_comp32.c is defined as 16.\nSo stack is aligned in either 8 or 16', ' x86/s390 having 8-byte stack alignment and\nthe rest having 16-byte alignment.\n\nThis patch calculates total stack depth based on 16-byte alignment if jit is requested.\nFor the above failing case', ' the new stack size will be 32+448+0+32=512 and no verification\nfailure. llvm19 regression will be discussed separately in llvm upstream.\n\nThe verifier change caused three test failures as these tests compared messages\nwith stack size. More specifically', '\n - test_global_funcs/global_func1: fail with interpreter mode and success with jit mode.\n Adjusted stack sizes so both jit and interpreter modes will fail.\n - async_stack_depth/{pseudo_call_check', ' async_call_root_check}: since jit and interpreter\n will calculate different stack sizes', ' the failure msg is adjusted to omit those\n specific stack size numbers.\n\n [1] https://lore.kernel.org/bpf/32bde0f0-1881-46c9-931a-673be566c61d@linux.dev/\n\nSuggested-by: Alexei Starovoitov \nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240214232951.4113094-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",The commit fixes a test failure caused by exceeding stack size limit due to llvm19 regression.,"fix, verifier, llvm19",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +57354f5fdee8017783b5cc2e53b263641b6862e9,57354f5fdee8017783b5cc2e53b263641b6862e9,Andrii Nakryiko,andrii@kernel.org,1707932460,Alexei Starovoitov,ast@kernel.org,1708030848,a02fe1abc888edac813b20bc648e475333d8c989,a4561f5afef8a8ff25a2cfd46d587f65869494f2,"bpf: improve duplicate source code line detection + +Verifier log avoids printing the same source code line multiple times +when a consecutive block of BPF assembly instructions are covered by the +same original (C) source code line. This greatly improves verifier log +legibility. + +Unfortunately"," this check is imperfect and in production applications it +quite often happens that verifier log will have multiple duplicated +source lines emitted","[' for no apparently good reason. E.g.', ' this is\nexcerpt from a real-world BPF application (with register states omitted\nfor clarity):\n\nBEFORE\n======\n; for (int i = 0; i < STROBE_MAX_MAP_ENTRIES; ++i) { @ strobemeta_probe.bpf.c:394\n5369: (07) r8 += 2 ;\n5370: (07) r7 += 16 ;\n; for (int i = 0; i < STROBE_MAX_MAP_ENTRIES; ++i) { @ strobemeta_probe.bpf.c:394\n5371: (07) r9 += 1 ;\n5372: (79) r4 = *(u64 *)(r10 -32) ;\n; for (int i = 0; i < STROBE_MAX_MAP_ENTRIES; ++i) { @ strobemeta_probe.bpf.c:394\n5373: (55) if r9 != 0xf goto pc+2\n; if (i >= map->cnt) @ strobemeta_probe.bpf.c:396\n5376: (79) r1 = *(u64 *)(r10 -40) ;\n5377: (79) r1 = *(u64 *)(r1 +8) ;\n; if (i >= map->cnt) @ strobemeta_probe.bpf.c:396\n5378: (dd) if r1 s<= r9 goto pc-5 ;\n; descr->key_lens[i] = 0; @ strobemeta_probe.bpf.c:398\n5379: (b4) w1 = 0 ;\n5380: (6b) *(u16 *)(r8 -30) = r1 ;\n; task', ' data', ' off', ' STROBE_MAX_STR_LEN', ' map->entries[i].key); @ strobemeta_probe.bpf.c:400\n5381: (79) r3 = *(u64 *)(r7 -8) ;\n5382: (7b) *(u64 *)(r10 -24) = r6 ;\n; task', ' data', ' off', ' STROBE_MAX_STR_LEN', ' map->entries[i].key); @ strobemeta_probe.bpf.c:400\n5383: (bc) w6 = w6 ;\n; barrier_var(payload_off); @ strobemeta_probe.bpf.c:280\n5384: (bf) r2 = r6 ;\n5385: (bf) r1 = r4 ;\n\nAs can be seen', ' line 394 is emitted thrice', ' 396 is emitted twice', ' and\nline 400 is duplicated as well. Note that there are no intermingling\nother lines of source code in between these duplicates', "" so the issue is\nnot compiler reordering assembly instruction such that multiple original\nsource code lines are in effect.\n\nIt becomes more obvious what's going on if we look at *full* original line info\ninformation (using btfdump for this"", ' [0]):\n\n #2764: line: insn #5363 --> 394:3 @ ./././strobemeta_probe.bpf.c\n for (int i = 0; i < STROBE_MAX_MAP_ENTRIES; ++i) {\n #2765: line: insn #5373 --> 394:21 @ ./././strobemeta_probe.bpf.c\n for (int i = 0; i < STROBE_MAX_MAP_ENTRIES; ++i) {\n #2766: line: insn #5375 --> 394:47 @ ./././strobemeta_probe.bpf.c\n for (int i = 0; i < STROBE_MAX_MAP_ENTRIES; ++i) {\n #2767: line: insn #5377 --> 394:3 @ ./././strobemeta_probe.bpf.c\n for (int i = 0; i < STROBE_MAX_MAP_ENTRIES; ++i) {\n #2768: line: insn #5378 --> 414:10 @ ./././strobemeta_probe.bpf.c\n return off;\n\nWe can see that there are four line info records covering\ninstructions #5363 through #5377 (instruction indices are shifted due to\nsubprog instruction being appended to main program)', ' all of them are\npointing to the same C source code line #394. But each of them points to\na different part of that line', ' which is denoted by differing column\nnumbers (3', ' 21', ' 47', "" 3).\n\nBut verifier log doesn't distinguish between parts of the same source code line\nand doesn't emit this column number information"", "" so for end user it's just a\nrepetitive visual noise. So let's improve the detection of repeated source code\nline and avoid this.\n\nWith the changes in this patch"", ' we get this output for the same piece of BPF\nprogram log:\n\nAFTER\n=====\n; for (int i = 0; i < STROBE_MAX_MAP_ENTRIES; ++i) { @ strobemeta_probe.bpf.c:394\n5369: (07) r8 += 2 ;\n5370: (07) r7 += 16 ;\n5371: (07) r9 += 1 ;\n5372: (79) r4 = *(u64 *)(r10 -32) ;\n5373: (55) if r9 != 0xf goto pc+2\n; if (i >= map->cnt) @ strobemeta_probe.bpf.c:396\n5376: (79) r1 = *(u64 *)(r10 -40) ;\n5377: (79) r1 = *(u64 *)(r1 +8) ;\n5378: (dd) if r1 s<= r9 goto pc-5 ;\n; descr->key_lens[i] = 0; @ strobemeta_probe.bpf.c:398\n5379: (b4) w1 = 0 ;\n5380: (6b) *(u16 *)(r8 -30) = r1 ;\n; task', ' data', ' off', ' STROBE_MAX_STR_LEN', ' map->entries[i].key); @ strobemeta_probe.bpf.c:400\n5381: (79) r3 = *(u64 *)(r7 -8) ;\n5382: (7b) *(u64 *)(r10 -24) = r6 ;\n5383: (bc) w6 = w6 ;\n; barrier_var(payload_off); @ strobemeta_probe.bpf.c:280\n5384: (bf) r2 = r6 ;\n5385: (bf) r1 = r4 ;\n\nAll the duplication is gone and the log is cleaner and less distracting.\n\n [0] https://github.com/anakryiko/btfdump\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240214174100.2847419-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Improves detection of duplicate source code lines in eBPF verifier logs for better legibility.,duplicate detection logs,It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a4561f5afef8a8ff25a2cfd46d587f65869494f2,a4561f5afef8a8ff25a2cfd46d587f65869494f2,Andrii Nakryiko,andrii@kernel.org,1707870191,Daniel Borkmann,daniel@iogearbox.net,1707951222,d0fae642023a578a86c291fb3f1282aed287b4cc,1159d27852207e8efb8d6ef2dae5aaa87ec4e225,"bpf: Use O(log(N)) binary search to find line info record + +Real-world BPF applications keep growing in size. Medium-sized production +application can easily have 50K+ verified instructions"," and its line +info section in .BTF.ext has more than 3K entries. + +When verifier emits log with log_level>=1","[' it annotates assembly code\nwith matched original C source code. Currently it uses linear search\nover line info records to find a match. As complexity of BPF\napplications grows', ' this O(K * N) approach scales poorly.\n\nSo', "" let's instead of linear O(N) search for line info record use faster\nequivalent O(log(N)) binary search algorithm. It's not a plain binary\nsearch"", "" as we don't look for exact match. It's an upper bound search\nvariant"", ' looking for rightmost line info record that starts at or before\ngiven insn_off.\n\nSome unscientific measurements were done before and after this change.\nThey were done in VM and fluctuate a bit', "" but overall the speed up is\nundeniable.\n\nBASELINE\n========\nFile Program Duration (us) Insns\n-------------------------------- ---------------- ------------- ------\nkatran.bpf.o balancer_ingress 2497130 343552\npyperf600.bpf.linked3.o on_event 12389611 627288\nstrobelight_pyperf_libbpf.o on_py_event 387399 52445\n-------------------------------- ---------------- ------------- ------\n\nBINARY SEARCH\n=============\n\nFile Program Duration (us) Insns\n-------------------------------- ---------------- ------------- ------\nkatran.bpf.o balancer_ingress 2339312 343552\npyperf600.bpf.linked3.o on_event 5602203 627288\nstrobelight_pyperf_libbpf.o on_py_event 294761 52445\n-------------------------------- ---------------- ------------- ------\n\nWhile Katran's speed up is pretty modest (about 105ms"", ' or 6%)', "" for\nproduction pyperf BPF program (on_py_event) it's much greater already"", ""\ngoing from 387ms down to 295ms (23% improvement).\n\nLooking at BPF selftests's biggest pyperf example"", ' we can see even more\ndramatic improvement', ' shaving more than 50% of time', ' going from 12.3s\ndown to 5.6s.\n\nDifferent amount of improvement is the function of overall amount of BPF\nassembly instructions in .bpf.o files (which contributes to how much\nline info records there will be and thus', ' on average', ' how much time linear\nsearch will take)', ' among other things:\n\n$ llvm-objdump -d katran.bpf.o | wc -l\n3863\n$ llvm-objdump -d strobelight_pyperf_libbpf.o | wc -l\n6997\n$ llvm-objdump -d pyperf600.bpf.linked3.o | wc -l\n87854\n\nGranted', ' this only applies to debugging cases (e.g.', ' using veristat', ' or\nfailing verification in production)', ' but seems worth doing to improve\noverall developer experience anyways.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/bpf/20240214002311.2197116-1-andrii@kernel.org\n', '']",The commit optimizes line info record lookup in bpf by implementing a binary search to improve performance.,"binary search, line info, performance",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e3a9ee963ad8ba677ca925149812c5932b49af69,e3a9ee963ad8ba677ca925149812c5932b49af69,Nathan Chancellor,nathan@kernel.org,1707789910,Masahiro Yamada,masahiroy@kernel.org,1707947800,135acef85d1618fde9c263fb295e633637baad58,6388cfd0e69b56ca640610f1bf29334619d18142,"kbuild: Fix changing ELF file type for output of gen_btf for big endian + +Commit 90ceddcb4950 (""bpf: Support llvm-objcopy for vmlinux BTF"") +changed the ELF type of .btf.vmlinux.bin.o to ET_REL via dd"," which works +fine for little endian platforms: + + 00000000 7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00 |.ELF............| + -00000010 03 00 b7 00 01 00 00 00 00 00 00 80 00 80 ff ff |................| + +00000010 01 00 b7 00 01 00 00 00 00 00 00 80 00 80 ff ff |................| + +However","[' for big endian platforms', ' it changes the wrong byte', ' resulting\nin an invalid ELF file type', ' which ld.lld rejects:\n\n 00000000 7f 45 4c 46 02 02 01 00 00 00 00 00 00 00 00 00 |.ELF............|\n -00000010 00 03 00 16 00 00 00 01 00 00 00 00 00 10 00 00 |................|\n +00000010 01 03 00 16 00 00 00 01 00 00 00 00 00 10 00 00 |................|\n\n Type: : 103\n\n ld.lld: error: .btf.vmlinux.bin.o: unknown file type\n\nFix this by updating the entire 16-bit e_type field rather than just a\nsingle byte', ' so that everything works correctly for all platforms and\nlinkers.\n\n 00000000 7f 45 4c 46 02 02 01 00 00 00 00 00 00 00 00 00 |.ELF............|\n -00000010 00 03 00 16 00 00 00 01 00 00 00 00 00 10 00 00 |................|\n +00000010 00 01 00 16 00 00 00 01 00 00 00 00 00 10 00 00 |................|\n\n Type: REL (Relocatable file)\n\nWhile in the area', "" update the comment to mention that binutils 2.35+\nmatches LLD's behavior of rejecting an ET_EXEC input"", ' which occurred\nafter the comment was added.\n\nCc: stable@vger.kernel.org\nFixes: 90ceddcb4950 (""bpf: Support llvm-objcopy for vmlinux BTF"")\nLink: https://github.com/llvm/llvm-project/pull/75643\nSuggested-by: Masahiro Yamada \nSigned-off-by: Nathan Chancellor \nReviewed-by: Fangrui Song \nReviewed-by: Nicolas Schier \nReviewed-by: Kees Cook \nReviewed-by: Justin Stitt \nSigned-off-by: Masahiro Yamada \n', '']",Fixes an ELF file type change issue for big endian platforms in gen_btf output.,"big endian, ELF file, gen_btf",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1159d27852207e8efb8d6ef2dae5aaa87ec4e225,1159d27852207e8efb8d6ef2dae5aaa87ec4e225,Matt Bobrowski,mattbobrowski@google.com,1707902063,Andrii Nakryiko,andrii@kernel.org,1707932926,b95004b53f9c6ea8b5bd0c9570668b1807933317,7cc13adbd057f1905564ec2a254883d7fd407deb,"libbpf: Make remark about zero-initializing bpf_*_info structs + +In some situations"," if you fail to zero-initialize the +bpf_{prog","['map', 'btf', 'link}_info structs supplied to the set of LIBBPF\nhelpers bpf_{prog', 'map', 'btf', 'link}_get_info_by_fd()', "" you can expect the\nhelper to return an error. This can possibly leave people in a\nsituation where they're scratching their heads for an unnnecessary\namount of time. Make an explicit remark about the requirement of\nzero-initializing the supplied bpf_{prog"", 'map', 'btf', 'link}_info structs\nfor the respective LIBBPF helpers.\n\nInternally', ' LIBBPF helpers bpf_{prog', 'map', 'btf', 'link}_get_info_by_fd()\ncall into bpf_obj_get_info_by_fd() where the bpf(2)\nBPF_OBJ_GET_INFO_BY_FD command is used. This specific command is\neffectively backed by restrictions enforced by the\nbpf_check_uarg_tail_zero() helper. This function ensures that if the\nsize of the supplied bpf_{prog', 'map', 'btf', 'link}_info structs are larger\nthan what the kernel can handle', "" trailing bits are zeroed. This can be\na problem when compiling against UAPI headers that don't necessarily\nmatch the sizes of the same underlying types known to the kernel.\n\nSigned-off-by: Matt Bobrowski \nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/bpf/ZcyEb8x4VbhieWsL@google.com\n"", '']",The commit addresses the necessity of zero-initializing bpf_info structs in the libbpf library.,"zero-initializing,bpf_info,libbpf",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e37243b65d528a8a9f8b9a57a43885f8e8dfc15c,e37243b65d528a8a9f8b9a57a43885f8e8dfc15c,Gianmarco Lusvardi,glusvardi@posteo.net,1707865546,Daniel Borkmann,daniel@iogearbox.net,1707927048,8adfff45546c2e37126ea53c33157429df6edb6c,2127c604383666675789fd4a5fc2aead46c73aad,bpf," scripts: Correct GPL license name + +The bpf_doc script refers to the GPL as the ""GNU Privacy License"". +I strongly suspect that the author wanted to refer to the GNU General +Public License","[' under which the Linux kernel is released', ' as', ' to the\nbest of my knowledge', ' there is no license named ""GNU Privacy License"".\nThis patch corrects the license name in the script accordingly.\n\nFixes: 56a092c89505 (""bpf: add script and prepare bpf.h for new helpers documentation"")\nSigned-off-by: Gianmarco Lusvardi \nSigned-off-by: Daniel Borkmann \nReviewed-by: Quentin Monnet \nLink: https://lore.kernel.org/bpf/20240213230544.930018-3-glusvardi@posteo.net\n', '']",Fix typo in bpf_doc script by correcting 'GNU Privacy License' to 'GNU General Public License'.,"typo, GPL, correction",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +7cc13adbd057f1905564ec2a254883d7fd407deb,7cc13adbd057f1905564ec2a254883d7fd407deb,Andrii Nakryiko,andrii@kernel.org,1707782384,Alexei Starovoitov,ast@kernel.org,1707879092,8bca01f6d20b084b75c77f1a00bb1694fb50e29b,96adbf7125e49687e5c1dbd8a241c68e2441da98,"bpf: emit source code file name and line number in verifier log + +As BPF applications grow in size and complexity and are separated into +multiple .bpf.c files that are statically linked together"," it becomes +harder and harder to match verifier's BPF assembly level output to +original C code. While often annotated C source code is unique enough to +be able to identify the file it belongs to","[' quite often this is actually\nproblematic as parts of source code can be quite generic.\n\nLong story short', ' it is very useful to see source code file name and\nline number information along with the original C code. Verifier already\nknows this information', ' we just need to output it.\n\nThis patch extends verifier log with file name and line number\ninformation', ' emitted next to original (presumably C) source code', '\nannotating BPF assembly output', ' like so:\n\n ; @ .bpf.c:\n\nIf file name has directory names in it', ' they are stripped away. This\nshould be fine in practice as file names tend to be pretty unique with\nC code anyways', ' and keeping log size smaller is always good.\n\nIn practice this might look something like below', ' where some code is\ncoming from application files', "" while others are from libbpf's usdt.bpf.h\nheader file:\n\n ; if (STROBEMETA_READ( @ strobemeta_probe.bpf.c:534\n 5592: (79) r1 = *(u64 *)(r10 -56) ; R1_w=mem_or_null(id=1589"", 'sz=7680) R10=fp0\n 5593: (7b) *(u64 *)(r10 -56) = r1 ; R1_w=mem_or_null(id=1589', 'sz=7680) R10=fp0\n 5594: (79) r3 = *(u64 *)(r10 -8) ; R3_w=scalar() R10=fp0 fp-8=mmmmmmmm\n\n ...\n\n 170: (71) r1 = *(u8 *)(r8 +15) ; frame1: R1_w=scalar(...) R8_w=map_value(map=__bpf_usdt_spec', 'ks=4', 'vs=208)\n 171: (67) r1 <<= 56 ; frame1: R1_w=scalar(...)\n 172: (c7) r1 s>>= 56 ; frame1: R1_w=scalar(smin=smin32=-128', 'smax=smax32=127)\n ; val <<= arg_spec->arg_bitshift; @ usdt.bpf.h:183\n 173: (67) r1 <<= 32 ; frame1: R1_w=scalar(...)\n 174: (77) r1 >>= 32 ; frame1: R1_w=scalar(smin=0', 'smax=umax=0xffffffff', 'var_off=(0x0; 0xffffffff))\n 175: (79) r2 = *(u64 *)(r10 -8) ; frame1: R2_w=scalar() R10=fp0 fp-8=mmmmmmmm\n 176: (6f) r2 <<= r1 ; frame1: R1_w=scalar(smin=0', 'smax=umax=0xffffffff', 'var_off=(0x0; 0xffffffff)) R2_w=scalar()\n 177: (7b) *(u64 *)(r10 -8) = r2 ; frame1: R2_w=scalar(id=61) R10=fp0 fp-8_w=scalar(id=61)\n ; if (arg_spec->arg_signed) @ usdt.bpf.h:184\n 178: (bf) r3 = r2 ; frame1: R2_w=scalar(id=61) R3_w=scalar(id=61)\n 179: (7f) r3 >>= r1 ; frame1: R1_w=scalar(smin=0', 'smax=umax=0xffffffff', 'var_off=(0x0; 0xffffffff)) R3_w=scalar()\n ; if (arg_spec->arg_signed) @ usdt.bpf.h:184\n 180: (71) r4 = *(u8 *)(r8 +14)\n 181: safe\n\nlog_fixup tests needed a minor adjustment as verifier log output\nincreased a bit and that test is quite sensitive to such changes.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240212235944.2816107-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhance verifier log with source file and line number for better code traceability in BPF applications.,"verifier, source code, log",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +96adbf7125e49687e5c1dbd8a241c68e2441da98,96adbf7125e49687e5c1dbd8a241c68e2441da98,Alexei Starovoitov,ast@kernel.org,1707878807,Alexei Starovoitov,ast@kernel.org,1707878807,26d39c1ca7d67401245a928139012ad7624faad1,32e18e7688c6847b0c9db073aafb00639ecf576c 63d5a33fb4ec2a4ed6907c8ac144b6f10f6dba47,"Merge branch 'fix-global-subprog-ptr_to_ctx-arg-handling' + +Andrii Nakryiko says: + +==================== +Fix global subprog PTR_TO_CTX arg handling + +Fix confusing and incorrect inference of PTR_TO_CTX argument type in BPF +global subprogs. For some program types (iters", tracepoint,"[' any program type\nthat doesn\'t have fixed named ""canonical"" context type) when user uses (in\na correct and valid way) a pointer argument to user-defined anonymous struct\ntype', ' verifier will incorrectly assume that it has to be PTR_TO_CTX argument.\nWhile it should be just a PTR_TO_MEM argument with allowed size calculated\nfrom user-provided (even if anonymous) struct.\n\nThis did come up in practice and was very confusing to users', "" so let's prevent\nthis going forward. We had to do a slight refactoring of\nbtf_get_prog_ctx_type() to make it easy to support a special s390x KPROBE use\ncases. See details in respective patches.\n\nv1->v2:\n - special-case typedef bpf_user_pt_regs_t handling for KPROBE programs"", '\n fixing s390x after changes in patch #2.\n====================\n\nLink: https://lore.kernel.org/r/20240212233221.2575350-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes incorrect inference of PTR_TO_CTX argument type in BPF global subprograms.,"PTR_TO_CTX,global subprog,fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,['tracepoints like programs'] +63d5a33fb4ec2a4ed6907c8ac144b6f10f6dba47,63d5a33fb4ec2a4ed6907c8ac144b6f10f6dba47,Andrii Nakryiko,andrii@kernel.org,1707780741,Alexei Starovoitov,ast@kernel.org,1707878807,26d39c1ca7d67401245a928139012ad7624faad1,879bbe7aa4afa80acf72a1cad7f52416ea78c52d,"selftests/bpf: add anonymous user struct as global subprog arg test + +Add tests validating that kernel handles pointer to anonymous struct +argument as PTR_TO_MEM case"," not as PTR_TO_CTX case. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240212233221.2575350-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add a test case for handling anonymous struct pointers as PTR_TO_MEM in eBPF selftests.,"anonymous, struct, test",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +879bbe7aa4afa80acf72a1cad7f52416ea78c52d,879bbe7aa4afa80acf72a1cad7f52416ea78c52d,Andrii Nakryiko,andrii@kernel.org,1707780740,Alexei Starovoitov,ast@kernel.org,1707878807,7167d3b75c871d1ba5001c27c13a751e2f0b77a8,824c58fb1090ae5e502284400682e30841280a87,"bpf: don't infer PTR_TO_CTX for programs with unnamed context type + +For program types that don't have named context type name (e.g."," BPF +iterator programs or tracepoint programs)","["" ctx_tname will be a non-NULL\nempty string. For such programs it shouldn't be possible to have\nPTR_TO_CTX argument for global subprogs based on type name alone.\narg:ctx tag is the only way to have PTR_TO_CTX passed into global\nsubprog for such program types.\n\nFix this loophole"", ' which currently would assume PTR_TO_CTX whenever\nuser uses a pointer to anonymous struct as an argument to their global\nsubprogs. This happens in practice with the following (quite common', "" in\npractice) approach:\n\ntypedef struct { /* anonymous */\n int x;\n} my_type_t;\n\nint my_subprog(my_type_t *arg) { ... }\n\nUser's intent is to have PTR_TO_MEM argument for `arg`"", ' but verifier\nwill complain about expecting PTR_TO_CTX.\n\nThis fix also closes unintended s390x-specific KPROBE handling of\nPTR_TO_CTX case. Selftest change is necessary to accommodate this.\n\nFixes: 91cc1a99740e (""bpf: Annotate context types"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240212233221.2575350-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Prevent automatic inference of PTR_TO_CTX for eBPF programs with unnamed context types.,"PTR_TO_CTX, unnamed context, programs",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['tracepoints like programs', ""It's not related to any of the above.""]" +824c58fb1090ae5e502284400682e30841280a87,824c58fb1090ae5e502284400682e30841280a87,Andrii Nakryiko,andrii@kernel.org,1707780739,Alexei Starovoitov,ast@kernel.org,1707878807,268b666e38890c286cc91c2cc2780a1304706902,fb5b86cfd4ef21ea18966718f6bf6c8f1b9df12e,"bpf: handle bpf_user_pt_regs_t typedef explicitly for PTR_TO_CTX global arg + +Expected canonical argument type for global function arguments +representing PTR_TO_CTX is `bpf_user_pt_regs_t *ctx`. This currently +works on s390x by accident because kernel resolves such typedef to +underlying struct (which is anonymous on s390x)"," and erroneously +accepting it as expected context type. We are fixing this problem next","['\nwhich would break s390x arch', ' so we need to handle `bpf_user_pt_regs_t`\ncase explicitly for KPROBE programs.\n\nFixes: 91cc1a99740e (""bpf: Annotate context types"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240212233221.2575350-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixed handling of bpf_user_pt_regs_t typedef for PTR_TO_CTX global argument to ensure proper context type recognition across architectures.,bpf typedef PTR_TO_CTX,It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fb5b86cfd4ef21ea18966718f6bf6c8f1b9df12e,fb5b86cfd4ef21ea18966718f6bf6c8f1b9df12e,Andrii Nakryiko,andrii@kernel.org,1707780738,Alexei Starovoitov,ast@kernel.org,1707878806,eb856ee133bdfa5517d4e25a7331ce560ba56b22,32e18e7688c6847b0c9db073aafb00639ecf576c,"bpf: simplify btf_get_prog_ctx_type() into btf_is_prog_ctx_type() + +Return result of btf_get_prog_ctx_type() is never used and callers only +check NULL vs non-NULL case to determine if given type matches expected +PTR_TO_CTX type. So rename function to `btf_is_prog_ctx_type()` and +return a simple true/false. We'll use this simpler interface to handle +kprobe program type's special typedef case in the next patch. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240212233221.2575350-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Refactored btf_get_prog_ctx_type() to btf_is_prog_ctx_type() simplifying its interface for detecting PTR_TO_CTX types.,"BTF,simplify,kprobe",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),['kprobe/uprobe/ftrace like programs'] +32e18e7688c6847b0c9db073aafb00639ecf576c,32e18e7688c6847b0c9db073aafb00639ecf576c,Oliver Crumrine,ozlinuxc@gmail.com,1707507682,Martin KaFai Lau,martin.lau@kernel.org,1707867677,dd578e3b4d1a6678286ee3b1f1fcbc70b60c411d,2c21a0f67c8ce334b8a58332e8c2d71694bef0ab,"bpf: remove check in __cgroup_bpf_run_filter_skb + +Originally"," this patch removed a redundant check in +BPF_CGROUP_RUN_PROG_INET_EGRESS","[' as the check was already being done in\nthe function it called', ' __cgroup_bpf_run_filter_skb. For v2', ' it was\nreccomended that I remove the check from __cgroup_bpf_run_filter_skb', '\nand add the checks to the other macro that calls that function', '\nBPF_CGROUP_RUN_PROG_INET_INGRESS.\n\nTo sum it up', ' checking that the socket exists and that it is a full\nsocket is now part of both macros BPF_CGROUP_RUN_PROG_INET_EGRESS and\nBPF_CGROUP_RUN_PROG_INET_INGRESS', ' and it is no longer part of the\nfunction they call', ' __cgroup_bpf_run_filter_skb.\n\nv3->v4: Fixed weird merge conflict.\nv2->v3: Sent to bpf-next instead of generic patch\nv1->v2: Addressed feedback about where check should be removed.\n\nSigned-off-by: Oliver Crumrine \nAcked-by: Stanislav Fomichev \nLink: https://lore.kernel.org/r/7lv62yiyvmj5a7eozv2iznglpkydkdfancgmbhiptrgvgan5sy@3fl3onchgdz3\nSigned-off-by: Martin KaFai Lau \n', '']",Removed a redundant check in BPF_CGROUP_RUN_PROG_INET_EGRESS function.,"remove, redundant, cgroup",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,['cgroup like programs'] +2c21a0f67c8ce334b8a58332e8c2d71694bef0ab,2c21a0f67c8ce334b8a58332e8c2d71694bef0ab,Martin KaFai Lau,martin.lau@kernel.org,1707859692,Martin KaFai Lau,martin.lau@kernel.org,1707866204,2f57131d002ff067db53ab4a62ccd8d5f735ef54,dc8543b597c282643a433e9a8af0459ed3046908 00f239eccf461a6403b3c16e767d04f3954cae98,"Merge branch 'Support PTR_MAYBE_NULL for struct_ops arguments.' + +Kui-Feng Lee says: + +==================== +Allow passing null pointers to the operators provided by a struct_ops +object. This is an RFC to collect feedbacks/opinions. + +The function pointers that are passed to struct_ops operators (the function +pointers) are always considered reliable until now. They cannot be +null. However", in certain scenarios,"[' it should be possible to pass null\npointers to these operators. For instance', ' sched_ext may pass a null\npointer in the struct task type to an operator that is provided by its\nstruct_ops objects.\n\nThe proposed solution here is to add PTR_MAYBE_NULL annotations to\narguments and create instances of struct bpf_ctx_arg_aux (arg_info) for\nthese arguments. These arg_infos will be installed at\nprog->aux->ctx_arg_info and will be checked by the BPF verifier when\nloading the programs. When a struct_ops program accesses arguments in the\nctx', ' the verifier will call btf_ctx_access() (through\nbpf_verifier_ops->is_valid_access) to verify the access. btf_ctx_access()\nwill check arg_info and use the information of the matched arg_info to\nproperly set reg_type.\n\nFor nullable arguments', ' this patch sets an arg_info to label them with\nPTR_TO_BTF_ID | PTR_TRUSTED | PTR_MAYBE_NULL. This enforces the verifier to\ncheck programs and ensure that they properly check the pointer. The\nprograms should check if the pointer is null before reading/writing the\npointed memory.\n\nThe implementer of a struct_ops should annotate the arguments that can\nbe null. The implementer should define a stub function (empty) as a\nplaceholder for each defined operator. The name of a stub function\nshould be in the pattern ""__"". For example', '\nfor test_maybe_null of struct bpf_testmod_ops', ' it\'s stub function name\nshould be ""bpf_testmod_ops__test_maybe_null"". You mark an argument\nnullable by suffixing the argument name with ""__nullable"" at the stub\nfunction. Here is the example in bpf_testmod.c.\n\n static int bpf_testmod_ops__test_maybe_null(int dummy', '\n struct task_struct *task__nullable)\n {\n return 0;\n }\n\nThis means that the argument 1 (2nd) of bpf_testmod_ops->test_maybe_null', '\nwhich is a function pointer that can be null. With this annotation', ' the\nverifier will understand how to check programs using this arguments. A BPF\nprogram that implement test_maybe_null should check the pointer to make\nsure it is not null before using it. For example', '\n\n if (task__nullable)\n save_tgid = task__nullable->tgid\n\nWithout the check', ' the verifier will reject the program.\n\nSince we already has stub functions for kCFI', ' we just reuse these stub\nfunctions with the naming convention mentioned earlier. These stub\nfunctions with the naming convention is only required if there are nullable\narguments to annotate. For functions without nullable arguments', ' stub\nfunctions are not necessary for the purpose of this patch.\n---\nMajor changes from v7:\n\n - Update a comment that is out of date.\n\nMajor changes from v6:\n\n - Remove ""len"" from bpf_struct_ops_desc_release().\n\n - Rename arg_info(s) to info', ' and rename all_arg_info to arg_info in\n prepare_arg_info().\n\n - Rename arg_info to info in struct bpf_struct_ops_arg_info.\n\nMajor changes from v5:\n\n - Rename all member_arg_info variables.\n\n - Refactor to bpf_struct_ops_desc_release() to share code\n between btf_free_struct_ops_tab() and bpf_struct_ops_desc_init().\n\n - Refactor to btf_param_match_suffix(). (Add a new patch as the part 2.)\n\n - Clean up the commit log and remaining code in the patch of test cases.\n\n - Update a comment in struct_ops_maybe_null.c.\n\nMajor changes from v4:\n\n - Remove the support of pointers to types other than struct\n types. That would be a separate patchset.\n\n - Remove the patch about extending PTR_TO_BTF_ID.\n\n - Remove the test against various pointer types from selftests.\n\n - Remove the patch ""bpf: Remove an unnecessary check"" and send that\n patch separately.\n\n - Remove member_arg_info_cnt from struct bpf_struct_ops_desc.\n\n - Use btf_id from FUNC_PROTO of a function pointer instead of a stub\n function.\n\nMajor changes from v3:\n\n - Move the code collecting argument information to prepare_arg_info()\n called in the loop in bpf_struct_ops_desc_init().\n\n - Simplify the memory allocation by having separated arg_info for\n each member of a struct_ops type.\n\n - Extend PTR_TO_BTF_ID to pointers to scalar types and array types', '\n not only to struct types.\n\nMajor changes from v2:\n\n - Remove dead code.\n\n - Add comments to explain the code itself.\n\nMajor changes from v1:\n\n - Annotate arguments by suffixing argument names with ""__nullable"" at\n stub functions.\n\nv7: https://lore.kernel.org/all/20240209020053.1132710-1-thinker.li@gmail.com/\nv6: https://lore.kernel.org/all/20240208065103.2154768-1-thinker.li@gmail.com/\nv5: https://lore.kernel.org/all/20240206063833.2520479-1-thinker.li@gmail.com/\nv4: https://lore.kernel.org/all/20240202220516.1165466-1-thinker.li@gmail.com/\nv3: https://lore.kernel.org/all/20240122212217.1391878-1-thinker.li@gmail.com/\nv2: https://lore.kernel.org/all/20240118224922.336006-1-thinker.li@gmail.com/\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",The commit allows null pointers for struct_ops function arguments in certain scenarios.,"null,pointers,struct_ops",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +00f239eccf461a6403b3c16e767d04f3954cae98,00f239eccf461a6403b3c16e767d04f3954cae98,Kui-Feng Lee,thinker.li@gmail.com,1707446270,Martin KaFai Lau,martin.lau@kernel.org,1707866204,2f57131d002ff067db53ab4a62ccd8d5f735ef54,1611603537a4b88cec7993f32b70c03113801a46,"selftests/bpf: Test PTR_MAYBE_NULL arguments of struct_ops operators. + +Test if the verifier verifies nullable pointer arguments correctly for BPF +struct_ops programs. + +""test_maybe_null"" in struct bpf_testmod_ops is the operator defined for the +test cases here. + +A BPF program should check a pointer for NULL beforehand to access the +value pointed by the nullable pointer arguments"," or the verifier should +reject the programs. The test here includes two parts; the programs +checking pointers properly and the programs not checking pointers +beforehand. The test checks if the verifier accepts the programs checking +properly and rejects the programs not checking at all. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240209023750.1153905-5-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Add tests for nullable pointer verification in BPF struct_ops programs.,"selftests,bpf,nullable",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1611603537a4b88cec7993f32b70c03113801a46,1611603537a4b88cec7993f32b70c03113801a46,Kui-Feng Lee,thinker.li@gmail.com,1707446269,Martin KaFai Lau,martin.lau@kernel.org,1707866204,7ab0b168954609b13b81b777444c8e574ac4fb3b,6115a0aeef01aef152ad7738393aad11422bfb82,"bpf: Create argument information for nullable arguments. + +Collect argument information from the type information of stub functions to +mark arguments of BPF struct_ops programs with PTR_MAYBE_NULL if they are +nullable. A nullable argument is annotated by suffixing ""__nullable"" at +the argument name of stub function. + +For nullable arguments"," this patch sets a struct bpf_ctx_arg_aux to label +their reg_type with PTR_TO_BTF_ID | PTR_TRUSTED | PTR_MAYBE_NULL. This +makes the verifier to check programs and ensure that they properly check +the pointer. The programs should check if the pointer is null before +accessing the pointed memory. + +The implementer of a struct_ops type should annotate the arguments that can +be null. The implementer should define a stub function (empty) as a +placeholder for each defined operator. The name of a stub function should +be in the pattern ""__"". For example","[' for\ntest_maybe_null of struct bpf_testmod_ops', ' it\'s stub function name should\nbe ""bpf_testmod_ops__test_maybe_null"". You mark an argument nullable by\nsuffixing the argument name with ""__nullable"" at the stub function.\n\nSince we already has stub functions for kCFI', ' we just reuse these stub\nfunctions with the naming convention mentioned earlier. These stub\nfunctions with the naming convention is only required if there are nullable\narguments to annotate. For functions having not nullable arguments', ' stub\nfunctions are not necessary for the purpose of this patch.\n\nThis patch will prepare a list of struct bpf_ctx_arg_aux', ' aka arg_info', ' for\neach member field of a struct_ops type. ""arg_info"" will be assigned to\n""prog->aux->ctx_arg_info"" of BPF struct_ops programs in\ncheck_struct_ops_btf_id() so that it can be used by btf_ctx_access() later\nto set reg_type properly for the verifier.\n\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240209023750.1153905-4-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Adds handling for nullable arguments in BPF struct_ops by marking them with PTR_MAYBE_NULL.,"nullable, arguments, struct_ops",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6115a0aeef01aef152ad7738393aad11422bfb82,6115a0aeef01aef152ad7738393aad11422bfb82,Kui-Feng Lee,thinker.li@gmail.com,1707446268,Martin KaFai Lau,martin.lau@kernel.org,1707866204,347d202fac2f91df9dcdc3c772c970860390fc86,77c0208e199ccb0986fb3612f2409c8cdcb036ad,"bpf: Move __kfunc_param_match_suffix() to btf.c. + +Move __kfunc_param_match_suffix() to btf.c and rename it as +btf_param_match_suffix(). It can be reused by bpf_struct_ops later. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240209023750.1153905-3-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",,The function __kfunc_param_match_suffix() is moved and renamed to btf_param_match_suffix() for reuse soon.,"bpf,moved,reuse",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +77c0208e199ccb0986fb3612f2409c8cdcb036ad,77c0208e199ccb0986fb3612f2409c8cdcb036ad,Kui-Feng Lee,thinker.li@gmail.com,1707446267,Martin KaFai Lau,martin.lau@kernel.org,1707866204,f8b3520a1efab15f6e766f7f559887c2964606f5,dc8543b597c282643a433e9a8af0459ed3046908,"bpf: add btf pointer to struct bpf_ctx_arg_aux. + +Enable the providers to use types defined in a module instead of in the +kernel (btf_vmlinux). + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240209023750.1153905-2-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",,Add BTF pointer in struct bpf_ctx_arg_aux to enable use of module-defined types.,"BTF, bpf_ctx_arg_aux, module",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dc8543b597c282643a433e9a8af0459ed3046908,dc8543b597c282643a433e9a8af0459ed3046908,Dave Thaler,dthaler1968@googlemail.com,1707430489,Daniel Borkmann,daniel@iogearbox.net,1707862455,482bd672866f482580e325473d1296224ec472d6,12bbcf8e840f40b82b02981e96e0a5fbb0703ea9,bpf," docs: Update ISA document title + +* Use ""Instruction Set Architecture (ISA)"" instead of ""Instruction Set + Specification"" +* Remove version number + +As previously discussed on the mailing list at +https://mailarchive.ietf.org/arch/msg/bpf/SEpn3OL9TabNRn-4rDX9A6XVbjM/ + +Signed-off-by: Dave Thaler +Signed-off-by: Daniel Borkmann +Acked-by: David Vernet +Link: https://lore.kernel.org/bpf/20240208221449.12274-1-dthaler1968@gmail.com +",[''],Updated the BPF ISA document by changing the title and removing the version number.,"ISA, document, update",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +2127c604383666675789fd4a5fc2aead46c73aad,2127c604383666675789fd4a5fc2aead46c73aad,Sebastian Andrzej Siewior,bigeasy@linutronix.de,1706891540,Daniel Borkmann,daniel@iogearbox.net,1707862229,02052833aea3ecc5810989ab53e4eeaa550c4a5f,11f522256e9043b0fcd2f994278645d3e201d20c,"xsk: Add truesize to skb_add_rx_frag(). + +xsk_build_skb() allocates a page and adds it to the skb via +skb_add_rx_frag() and specifies 0 for truesize. This leads to a warning +in skb_add_rx_frag() with CONFIG_DEBUG_NET enabled because size is +larger than truesize. + +Increasing truesize requires to add the same amount to socket's +sk_wmem_alloc counter in order not to underflow the counter during +release in the destructor (sock_wfree()). + +Pass the size of the allocated page as truesize to skb_add_rx_frag(). +Add this mount to socket's sk_wmem_alloc counter. + +Fixes: cf24f5a5feea (""xsk: add support for AF_XDP multi-buffer on Tx path"") +Signed-off-by: Sebastian Andrzej Siewior +Signed-off-by: Daniel Borkmann +Acked-by: Maciej Fijalkowski +Link: https://lore.kernel.org/bpf/20240202163221.2488589-1-bigeasy@linutronix.de +",,The commit addresses a warning by adding truesize to skb_add_rx_frag and updating sk_wmem_alloc accordingly.,"truesize, xsk, skb_add_rx_frag",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['socket like programs'] +12bbcf8e840f40b82b02981e96e0a5fbb0703ea9,12bbcf8e840f40b82b02981e96e0a5fbb0703ea9,Cupertino Miranda,cupertino.miranda@oracle.com,1707845743,Andrii Nakryiko,andrii@kernel.org,1707852492,9238bb36e780acb761de92836f81c420f941aeb8,52dbd67dff5d050e99301100e2cac578eef9b2e9,"libbpf: Add support to GCC in CORE macro definitions + +Due to internal differences between LLVM and GCC the current +implementation for the CO-RE macros does not fit GCC parser"," as it will +optimize those expressions even before those would be accessible by the +BPF backend. + +As examples","[' the following would be optimized out with the original\ndefinitions:\n - As enums are converted to their integer representation during\n parsing', ' the IR would not know how to distinguish an integer\n constant from an actual enum value.\n - Types need to be kept as temporary variables', ' as the existing type\n casts of the 0 address (as expanded for LLVM)', ' are optimized away by\n the GCC C parser', ' never really reaching GCCs IR.\n\nAlthough', ' the macros appear to add extra complexity', ' the expanded code\nis removed from the compilation flow very early in the compilation\nprocess', ' not really affecting the quality of the generated assembly.\n\nSigned-off-by: Cupertino Miranda \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240213173543.1397708-1-cupertino.miranda@oracle.com\n', '']",Add support for GCC in CO-RE macro definitions in libbpf.,"GCC, CORE, libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +52dbd67dff5d050e99301100e2cac578eef9b2e9,52dbd67dff5d050e99301100e2cac578eef9b2e9,Jose E. Marchesi,jose.marchesi@oracle.com,1707424572,Andrii Nakryiko,andrii@kernel.org,1707851850,221cc0a5b0dac1f0336a9da2c59112269c77a0b2,fc1c9e40da37905f87c73711a1ecc57f52c1fe1c,"bpf: Abstract loop unrolling pragmas in BPF selftests + +[Changes from V1: +- Avoid conflict by rebasing with latest master.] + +Some BPF tests use loop unrolling compiler pragmas that are clang +specific and not supported by GCC. These pragmas"," along with their +GCC equivalences are: + + #pragma clang loop unroll_count(N) + #pragma GCC unroll N + + #pragma clang loop unroll(full) + #pragma GCC unroll 65534 + + #pragma clang loop unroll(disable) + #pragma GCC unroll 1 + + #pragma unroll [aka #pragma clang loop unroll(enable)] + There is no GCC equivalence to this pragma. It enables unrolling on + loops that the compiler would not ordinarily unroll even with + -O2|-funroll-loops","[' but it is not equivalent to full unrolling\n either.\n\nThis patch adds a new header progs/bpf_compiler.h that defines the\nfollowing macros', ' which correspond to each pair of compiler-specific\npragmas above:\n\n __pragma_loop_unroll_count(N)\n __pragma_loop_unroll_full\n __pragma_loop_no_unroll\n __pragma_loop_unroll\n\nThe selftests using loop unrolling pragmas are then changed to include\nthe header and use these macros in place of the explicit pragmas.\n\nTested in bpf-next master.\nNo regressions.\n\nSigned-off-by: Jose E. Marchesi \nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240208203612.29611-1-jose.marchesi@oracle.com\n', '']",Abstracts loop unrolling pragmas for BPF selftests to support both Clang and GCC compilers.,"loop unrolling, BPF selftests, compilers",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +11f522256e9043b0fcd2f994278645d3e201d20c,11f522256e9043b0fcd2f994278645d3e201d20c,Hari Bathini,hbathini@linux.ibm.com,1707386475,Andrii Nakryiko,andrii@kernel.org,1707851619,f6cdb169c58301dcc9d1419af3a9eb0d0e885776,577e4432f3ac810049cb7e6b71f4d96ec7c6e894,"bpf: Fix warning for bpf_cpumask in verifier + +Compiling with CONFIG_BPF_SYSCALL & !CONFIG_BPF_JIT throws the below +warning: + + ""WARN: resolve_btfids: unresolved symbol bpf_cpumask"" + +Fix it by adding the appropriate #ifdef. + +Signed-off-by: Hari Bathini +Signed-off-by: Andrii Nakryiko +Acked-by: Jiri Olsa +Acked-by: Stanislav Fomichev +Acked-by: David Vernet +Link: https://lore.kernel.org/bpf/20240208100115.602172-1-hbathini@linux.ibm.com +",,Fix warning for unresolved symbol bpf_cpumask in the eBPF verifier using an appropriate #ifdef.,"warning,bpf_cpumask,verifier",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fc1c9e40da37905f87c73711a1ecc57f52c1fe1c,fc1c9e40da37905f87c73711a1ecc57f52c1fe1c,Yonghong Song,yonghong.song@linux.dev,1707289267,Andrii Nakryiko,andrii@kernel.org,1707851485,b952abe8f9f1f32783a44801d5e99973ee43b0a6,178c54666f9c4d2f49f2ea661d0c11b52f0ed190,selftests/bpf: Ensure fentry prog cannot attach to bpf_spin_{lock,"unlcok}() + +Add two tests to ensure fentry programs cannot attach to +bpf_spin_{lock","['unlock}() helpers. The tracing_failure.c files\ncan be used in the future for other tracing failure cases.\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240207070107.335341-1-yonghong.song@linux.dev\n', '']",The commit adds tests to ensure fentry programs cannot attach to bpf_spin_lock functions.,"fentry, bpf_spin_lock, tests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +178c54666f9c4d2f49f2ea661d0c11b52f0ed190,178c54666f9c4d2f49f2ea661d0c11b52f0ed190,Yonghong Song,yonghong.song@linux.dev,1707289262,Andrii Nakryiko,andrii@kernel.org,1707851485,5ea3e36d839819b4ec8deb0a4fec766d12fdf13f,5b268d1ebcdceacf992dfda8f9031d56005a274e,bpf: Mark bpf_spin_{lock,"unlock}() helpers with notrace correctly + +Currently tracing is supposed not to allow for bpf_spin_{lock","['unlock}()\nhelper calls. This is to prevent deadlock for the following cases:\n - there is a prog (prog-A) calling bpf_spin_{lock', 'unlock}().\n - there is a tracing program (prog-B)', ' e.g.', ' fentry', ' attached\n to bpf_spin_lock() and/or bpf_spin_unlock().\n - prog-B calls bpf_spin_{lock', 'unlock}().\nFor such a case', ' when prog-A calls bpf_spin_{lock', 'unlock}()', '\na deadlock will happen.\n\nThe related source codes are below in kernel/bpf/helpers.c:\n notrace BPF_CALL_1(bpf_spin_lock', ' struct bpf_spin_lock *', ' lock)\n notrace BPF_CALL_1(bpf_spin_unlock', ' struct bpf_spin_lock *', ' lock)\nnotrace is supposed to prevent fentry prog from attaching to\nbpf_spin_{lock', 'unlock}().\n\nBut actually this is not the case and fentry prog can successfully\nattached to bpf_spin_lock(). Siddharth Chintamaneni reported\nthe issue in [1]. The following is the macro definition for\nabove BPF_CALL_1:\n #define BPF_CALL_x(x', ' name', ' ...) \\\n static __always_inline \\\n u64 ____##name(__BPF_MAP(x', ' __BPF_DECL_ARGS', ' __BPF_V', ' __VA_ARGS__)); \\\n typedef u64 (*btf_##name)(__BPF_MAP(x', ' __BPF_DECL_ARGS', ' __BPF_V', ' __VA_ARGS__)); \\\n u64 name(__BPF_REG(x', ' __BPF_DECL_REGS', ' __BPF_N', ' __VA_ARGS__)); \\\n u64 name(__BPF_REG(x', ' __BPF_DECL_REGS', ' __BPF_N', ' __VA_ARGS__)) \\\n { \\\n return ((btf_##name)____##name)(__BPF_MAP(x', '__BPF_CAST', '__BPF_N', '__VA_ARGS__));\\\n } \\\n static __always_inline \\\n u64 ____##name(__BPF_MAP(x', ' __BPF_DECL_ARGS', ' __BPF_V', ' __VA_ARGS__))\n\n #define BPF_CALL_1(name', ' ...) BPF_CALL_x(1', ' name', ' __VA_ARGS__)\n\nThe notrace attribute is actually applied to the static always_inline function\n____bpf_spin_{lock', 'unlock}(). The actual callback function\nbpf_spin_{lock', 'unlock}() is not marked with notrace', ' hence\nallowing fentry prog to attach to two helpers', ' and this\nmay cause the above mentioned deadlock. Siddharth Chintamaneni\nactually has a reproducer in [2].\n\nTo fix the issue', ' a new macro NOTRACE_BPF_CALL_1 is introduced which\nwill add notrace attribute to the original function instead of\nthe hidden always_inline function and this fixed the problem.\n\n [1] https://lore.kernel.org/bpf/CAE5sdEigPnoGrzN8WU7Tx-h-iFuMZgW06qp0KHWtpvoXxf1OAQ@mail.gmail.com/\n [2] https://lore.kernel.org/bpf/CAE5sdEg6yUc_Jz50AnUXEEUh6O73yQ1Z6NV2srJnef0ZrQkZew@mail.gmail.com/\n\nFixes: d83525ca62cf (""bpf: introduce bpf_spin_lock"")\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/bpf/20240207070102.335167-1-yonghong.song@linux.dev\n', '']","This commit correctly marks bpf_spin_{lock,unlock} helpers with notrace attribute.","bpf_spin_lock,helpers,notrace",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5b268d1ebcdceacf992dfda8f9031d56005a274e,5b268d1ebcdceacf992dfda8f9031d56005a274e,Daniel Xu,dxu@dxuuu.xyz,1707080794,Andrii Nakryiko,andrii@kernel.org,1707851126,aaadf3248447dd3757ec764eaec06de4025b1afc,68bc61c26cacf152baf905786b5949769700f40d,"bpf: Have bpf_rdonly_cast() take a const pointer + +Since 20d59ee55172 (""libbpf: add bpf_core_cast() macro"")"," libbpf is now +exporting a const arg version of bpf_rdonly_cast(). This causes the +following conflicting type error when generating kfunc prototypes from +BTF: + +In file included from skeleton/pid_iter.bpf.c:5: +/home/dxu/dev/linux/tools/bpf/bpftool/bootstrap/libbpf/include/bpf/bpf_core_read.h:297:14: error: conflicting types for 'bpf_rdonly_cast' +extern void *bpf_rdonly_cast(const void *obj__ign","[' __u32 btf_id__k) __ksym __weak;\n ^\n./vmlinux.h:135625:14: note: previous declaration is here\nextern void *bpf_rdonly_cast(void *obj__ign', ' u32 btf_id__k) __weak __ksym;\n\nThis is b/c the kernel defines bpf_rdonly_cast() with non-const arg.\nSince const arg is more permissive and thus backwards compatible', ' we\nchange the kernel definition as well to avoid conflicting type errors.\n\nSigned-off-by: Daniel Xu \nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/dfd3823f11ffd2d4c838e961d61ec9ae8a646773.1707080349.git.dxu@dxuuu.xyz\n', '']",The commit modifies bpf_rdonly_cast function to accept a constant pointer for compatibility with libbpf changes.,"bpf,rdonly_cast,const",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ed94a8f8ca75ea0f607c919edf2ed5a5e707ef44,ed94a8f8ca75ea0f607c919edf2ed5a5e707ef44,Jiri Slaby (SUSE),jirislaby@kernel.org,1706788396,Jiri Kosina,jkosina@suse.com,1707821035,f02180c3f5fb8557ff350cde1f2ee866115c9502,dcd5231f093b6cd8ea2015e7fe1f372cef5c643d,"HID: protect hid_device::bpf by CONFIG_HID_BPF + +And not by CONFIG_BPF. BPF can be selected while HID_BPF does not have +to. It actually cannot be on some platforms due to Kconfig dependences. + +This saves quite some bytes on those setups. + +Found by https://github.com/jirislaby/clang-struct. + +Signed-off-by: Jiri Slaby (SUSE) +Cc: Jiri Kosina +Cc: Benjamin Tissoires +Signed-off-by: Jiri Kosina +",,The commit modifies HID device configuration dependency to use CONFIG_HID_BPF instead of CONFIG_BPF.,"HID, CONFIG_HID_BPF, configuration",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['HID driver like programs'] +923e4616ec15b7feabdc353b229762069eb73c43,923e4616ec15b7feabdc353b229762069eb73c43,Ian Rogers,irogers@google.com,1707535066,Namhyung Kim,namhyung@kernel.org,1707770141,6f9d5e861d27560f0ba58a98cd191924abc6546f,ff0bd79980fffa00c36eb2b9044dbe9cfdf4bb79,"perf maps: Locking tidy up of nr_maps + +After this change maps__nr_maps is only used by tests"," existing users +are migrated to maps__empty. Compute maps__empty under the read lock. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-7-irogers@google.com +",[''],"The commit tidies up locking of nr_maps, migrating users to maps__empty under a read lock, used only by tests.","locking, maps, read-lock",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"[""It's not related to any of the above.""]" +ff0bd79980fffa00c36eb2b9044dbe9cfdf4bb79,ff0bd79980fffa00c36eb2b9044dbe9cfdf4bb79,Ian Rogers,irogers@google.com,1707535065,Namhyung Kim,namhyung@kernel.org,1707770141,530469d90e3fce274309acbff0df69ea8f7d9704,39a27325e6099e9f9a10d8b5f3b2470a3c10efa5,"perf maps: Hide maps internals + +Move the struct into the C file. Add maps__equal to work around +exposing the struct for reference count checking. Add accessors for +the unwind_libunwind_ops. Move maps_list_node to its only use in +symbol.c. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-6-irogers@google.com +",,"Refactor the perf map internals by moving structs, adding workarounds and accessors, and relocating specific elements to improve encapsulation.","perf maps, structures, encapsulation",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +39a27325e6099e9f9a10d8b5f3b2470a3c10efa5,39a27325e6099e9f9a10d8b5f3b2470a3c10efa5,Ian Rogers,irogers@google.com,1707535064,Namhyung Kim,namhyung@kernel.org,1707770141,408c5e465935ca0fa8da2244f6e65ba1c3b42e4b,107ef66cb054f8d54e336236a31631a8cc167c1f,"perf maps: Get map before returning in maps__find_next_entry + +Finding a map is done under a lock"," returning the map without a +reference count means it can be removed without notice and causing +uses after free. Grab a reference count to the map within the lock +region and return this. Fix up locations that need a map__put +following this. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-5-irogers@google.com +",[''],Acquire map reference count within lock to prevent use-after-free in maps__find_next_entry.,map lock reference,It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +107ef66cb054f8d54e336236a31631a8cc167c1f,107ef66cb054f8d54e336236a31631a8cc167c1f,Ian Rogers,irogers@google.com,1707535063,Namhyung Kim,namhyung@kernel.org,1707770133,d3b67ab8a3a16e344c3b05d1023bd80a2fa144d0,42fd623b58dbcc48310705bbf3e3d4d7c1deec29,"perf maps: Get map before returning in maps__find_by_name + +Finding a map is done under a lock"," returning the map without a +reference count means it can be removed without notice and causing +uses after free. Grab a reference count to the map within the lock +region and return this. Fix up locations that need a map__put +following this. Also fix some reference counted pointer comparisons. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-4-irogers@google.com +",[''],Fix potential use after free in perf maps by ensuring reference count manipulation within lock.,"perf maps,reference count,lock",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +42fd623b58dbcc48310705bbf3e3d4d7c1deec29,42fd623b58dbcc48310705bbf3e3d4d7c1deec29,Ian Rogers,irogers@google.com,1707535062,Namhyung Kim,namhyung@kernel.org,1707770126,c83e8fd2ea1911d949137e0d51979a3d4675195d,659ad3492b913c9033d47cb406ac5754780875b6,"perf maps: Get map before returning in maps__find + +Finding a map is done under a lock"," returning the map without a +reference count means it can be removed without notice and causing +uses after free. Grab a reference count to the map within the lock +region and return this. Fix up locations that need a map__put +following this. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: K Prateek Nayak +Cc: James Clark +Cc: Vincent Whitchurch +Cc: Alexey Dobriyan +Cc: Colin Ian King +Cc: Changbin Du +Cc: Masami Hiramatsu +Cc: Song Liu +Cc: Leo Yan +Cc: Athira Rajeev +Cc: Liam Howlett +Cc: Artem Savkov +Cc: bpf@vger.kernel.org +Signed-off-by: Namhyung Kim +Link: https://lore.kernel.org/r/20240210031746.4057262-3-irogers@google.com +",[''],This commit fixes use-after-free by managing reference counts for maps in perf maps.,"perf maps, reference count, use-after-free",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['other'] +659ad3492b913c9033d47cb406ac5754780875b6,659ad3492b913c9033d47cb406ac5754780875b6,Ian Rogers,irogers@google.com,1707535061,Namhyung Kim,namhyung@kernel.org,1707770114,0f0076d25aace83d0503a56b2d6ba59a279665c2,39d14c0dd650f3de62242c2f92fb4d7a0ec3386a,"perf maps: Switch from rbtree to lazily sorted array for addresses + +Maps is a collection of maps primarily sorted by the starting address +of the map. Prior to this change the maps were held in an rbtree +requiring 4 pointers per node. Prior to reference count checking"," the +rbnode was embedded in the map so 3 pointers per node were +necessary. This change switches the rbtree to an array lazily sorted +by address","[' much as the array sorting nodes by name. 1 pointer is\nneeded per node', ' but to avoid excessive resizing the backing array may\nbe twice the number of used elements. Meaning the memory overhead is\nroughly half that of the rbtree. For a perf record with\n""--no-bpf-event -g -a"" of true', ' the memory overhead of perf inject is\nreduce fom 3.3MB to 3MB', ' so 10% or 300KB is saved.\n\nMap inserts always happen at the end of the array. The code tracks\nwhether the insertion violates the sorting property. O(log n) rb-tree\ncomplexity is switched to O(1).\n\nRemove slides the array', ' so O(log n) rb-tree complexity is degraded to\nO(n).\n\nA find may need to sort the array using qsort which is O(n*log n)', ' but\nin general the maps should be sorted and so average performance should\nbe O(log n) as with the rbtree.\n\nAn rbtree node consumes a cache line', ' but with the array 4 nodes fit\non a cache line. Iteration is simplified to scanning an array rather\nthan pointer chasing.\n\nOverall it is expected the performance after the change should be\ncomparable to before', ' but with half of the memory consumed.\n\nTo avoid a list and repeated logic around splitting maps', '\nmaps__merge_in is rewritten in terms of\nmaps__fixup_overlap_and_insert. maps_merge_in splits the given mapping\ninserting remaining gaps. maps__fixup_overlap_and_insert splits the\nexisting mappings', ' then adds the incoming mapping. By adding the new\nmapping first', ' then re-inserting the existing mappings the splitting\nbehavior matches.\n\nSigned-off-by: Ian Rogers \nAcked-by: Namhyung Kim \nCc: K Prateek Nayak \nCc: James Clark \nCc: Vincent Whitchurch \nCc: Alexey Dobriyan \nCc: Colin Ian King \nCc: Changbin Du \nCc: Masami Hiramatsu \nCc: Song Liu \nCc: Leo Yan \nCc: Athira Rajeev \nCc: Liam Howlett \nCc: Artem Savkov \nCc: bpf@vger.kernel.org\nSigned-off-by: Namhyung Kim \nLink: https://lore.kernel.org/r/20240210031746.4057262-2-irogers@google.com\n', '']",The commit switches perf maps from using an rbtree to a lazily sorted array for better memory efficiency.,"perf maps,rbtree,lazily sorted array",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +68bc61c26cacf152baf905786b5949769700f40d,68bc61c26cacf152baf905786b5949769700f40d,Marco Elver,elver@google.com,1707308777,Martin KaFai Lau,martin.lau@kernel.org,1707689184,f49b1e314e72c5ce745c3ecd05cdfb4e624792bf,a7170d81e0002345576b5f87a5890d91bc06c106,"bpf: Allow compiler to inline most of bpf_local_storage_lookup() + +In various performance profiles of kernels with BPF programs attached"," +bpf_local_storage_lookup() appears as a significant portion of CPU +cycles spent. To enable the compiler generate more optimal code","[' turn\nbpf_local_storage_lookup() into a static inline function', ' where only the\ncache insertion code path is outlined\n\nNotably', ' outlining cache insertion helps avoid bloating callers by\nduplicating setting up calls to raw_spin_{lock', 'unlock}_irqsave() (on\narchitectures which do not inline spin_lock/unlock', ' such as x86)', ' which\nwould cause the compiler produce worse code by deciding to outline\notherwise inlinable functions. The call overhead is neutral', ' because we\nmake 2 calls either way: either calling raw_spin_lock_irqsave() and\nraw_spin_unlock_irqsave(); or call __bpf_local_storage_insert_cache()', '\nwhich calls raw_spin_lock_irqsave()', "" followed by a tail-call to\nraw_spin_unlock_irqsave() where the compiler can perform TCO and (in\noptimized uninstrumented builds) turns it into a plain jump. The call to\n__bpf_local_storage_insert_cache() can be elided entirely if\ncacheit_lockit is a false constant expression.\n\nBased on results from './benchs/run_bench_local_storage.sh' (21 trials"", '\nreboot between each trial; x86 defconfig + BPF', ' clang 16) this produces\nimprovements in throughput and latency in the majority of cases', ' with an\naverage (geomean) improvement of 8%:\n\n+---- Hashmap Control --------------------\n|\n| + num keys: 10\n| : | \n| +-+ hashmap (control) sequential get +----------------------+----------------------\n| +- hits throughput | 14.789 M ops/s | 14.745 M ops/s ( ~ )\n| +- hits latency | 67.679 ns/op | 67.879 ns/op ( ~ )\n| +- important_hits throughput | 14.789 M ops/s | 14.745 M ops/s ( ~ )\n|\n| + num keys: 1000\n| : | \n| +-+ hashmap (control) sequential get +----------------------+----------------------\n| +- hits throughput | 12.233 M ops/s | 12.170 M ops/s ( ~ )\n| +- hits latency | 81.754 ns/op | 82.185 ns/op ( ~ )\n| +- important_hits throughput | 12.233 M ops/s | 12.170 M ops/s ( ~ )\n|\n| + num keys: 10000\n| : | \n| +-+ hashmap (control) sequential get +----------------------+----------------------\n| +- hits throughput | 7.220 M ops/s | 7.204 M ops/s ( ~ )\n| +- hits latency | 138.522 ns/op | 138.842 ns/op ( ~ )\n| +- important_hits throughput | 7.220 M ops/s | 7.204 M ops/s ( ~ )\n|\n| + num keys: 100000\n| : | \n| +-+ hashmap (control) sequential get +----------------------+----------------------\n| +- hits throughput | 5.061 M ops/s | 5.165 M ops/s (+2.1%)\n| +- hits latency | 198.483 ns/op | 194.270 ns/op (-2.1%)\n| +- important_hits throughput | 5.061 M ops/s | 5.165 M ops/s (+2.1%)\n|\n| + num keys: 4194304\n| : | \n| +-+ hashmap (control) sequential get +----------------------+----------------------\n| +- hits throughput | 2.864 M ops/s | 2.882 M ops/s ( ~ )\n| +- hits latency | 365.220 ns/op | 361.418 ns/op (-1.0%)\n| +- important_hits throughput | 2.864 M ops/s | 2.882 M ops/s ( ~ )\n|\n+---- Local Storage ----------------------\n|\n| + num_maps: 1\n| : | \n| +-+ local_storage cache sequential get +----------------------+----------------------\n| +- hits throughput | 33.005 M ops/s | 39.068 M ops/s (+18.4%)\n| +- hits latency | 30.300 ns/op | 25.598 ns/op (-15.5%)\n| +- important_hits throughput | 33.005 M ops/s | 39.068 M ops/s (+18.4%)\n| :\n| : | \n| +-+ local_storage cache interleaved get +----------------------+----------------------\n| +- hits throughput | 37.151 M ops/s | 44.926 M ops/s (+20.9%)\n| +- hits latency | 26.919 ns/op | 22.259 ns/op (-17.3%)\n| +- important_hits throughput | 37.151 M ops/s | 44.926 M ops/s (+20.9%)\n|\n| + num_maps: 10\n| : | \n| +-+ local_storage cache sequential get +----------------------+----------------------\n| +- hits throughput | 32.288 M ops/s | 38.099 M ops/s (+18.0%)\n| +- hits latency | 30.972 ns/op | 26.248 ns/op (-15.3%)\n| +- important_hits throughput | 3.229 M ops/s | 3.810 M ops/s (+18.0%)\n| :\n| : | \n| +-+ local_storage cache interleaved get +----------------------+----------------------\n| +- hits throughput | 34.473 M ops/s | 41.145 M ops/s (+19.4%)\n| +- hits latency | 29.010 ns/op | 24.307 ns/op (-16.2%)\n| +- important_hits throughput | 12.312 M ops/s | 14.695 M ops/s (+19.4%)\n|\n| + num_maps: 16\n| : | \n| +-+ local_storage cache sequential get +----------------------+----------------------\n| +- hits throughput | 32.524 M ops/s | 38.341 M ops/s (+17.9%)\n| +- hits latency | 30.748 ns/op | 26.083 ns/op (-15.2%)\n| +- important_hits throughput | 2.033 M ops/s | 2.396 M ops/s (+17.9%)\n| :\n| : | \n| +-+ local_storage cache interleaved get +----------------------+----------------------\n| +- hits throughput | 34.575 M ops/s | 41.338 M ops/s (+19.6%)\n| +- hits latency | 28.925 ns/op | 24.193 ns/op (-16.4%)\n| +- important_hits throughput | 11.001 M ops/s | 13.153 M ops/s (+19.6%)\n|\n| + num_maps: 17\n| : | \n| +-+ local_storage cache sequential get +----------------------+----------------------\n| +- hits throughput | 28.861 M ops/s | 32.756 M ops/s (+13.5%)\n| +- hits latency | 34.649 ns/op | 30.530 ns/op (-11.9%)\n| +- important_hits throughput | 1.700 M ops/s | 1.929 M ops/s (+13.5%)\n| :\n| : | \n| +-+ local_storage cache interleaved get +----------------------+----------------------\n| +- hits throughput | 31.529 M ops/s | 36.110 M ops/s (+14.5%)\n| +- hits latency | 31.719 ns/op | 27.697 ns/op (-12.7%)\n| +- important_hits throughput | 9.598 M ops/s | 10.993 M ops/s (+14.5%)\n|\n| + num_maps: 24\n| : | \n| +-+ local_storage cache sequential get +----------------------+----------------------\n| +- hits throughput | 18.602 M ops/s | 19.937 M ops/s (+7.2%)\n| +- hits latency | 53.767 ns/op | 50.166 ns/op (-6.7%)\n| +- important_hits throughput | 0.776 M ops/s | 0.831 M ops/s (+7.2%)\n| :\n| : | \n| +-+ local_storage cache interleaved get +----------------------+----------------------\n| +- hits throughput | 21.718 M ops/s | 23.332 M ops/s (+7.4%)\n| +- hits latency | 46.047 ns/op | 42.865 ns/op (-6.9%)\n| +- important_hits throughput | 6.110 M ops/s | 6.564 M ops/s (+7.4%)\n|\n| + num_maps: 32\n| : | \n| +-+ local_storage cache sequential get +----------------------+----------------------\n| +- hits throughput | 14.118 M ops/s | 14.626 M ops/s (+3.6%)\n| +- hits latency | 70.856 ns/op | 68.381 ns/op (-3.5%)\n| +- important_hits throughput | 0.442 M ops/s | 0.458 M ops/s (+3.6%)\n| :\n| : | \n| +-+ local_storage cache interleaved get +----------------------+----------------------\n| +- hits throughput | 17.111 M ops/s | 17.906 M ops/s (+4.6%)\n| +- hits latency | 58.451 ns/op | 55.865 ns/op (-4.4%)\n| +- important_hits throughput | 4.776 M ops/s | 4.998 M ops/s (+4.6%)\n|\n| + num_maps: 100\n| : | \n| +-+ local_storage cache sequential get +----------------------+----------------------\n| +- hits throughput | 5.281 M ops/s | 5.528 M ops/s (+4.7%)\n| +- hits latency | 192.398 ns/op | 183.059 ns/op (-4.9%)\n| +- important_hits throughput | 0.053 M ops/s | 0.055 M ops/s (+4.9%)\n| :\n| : | \n| +-+ local_storage cache interleaved get +----------------------+----------------------\n| +- hits throughput | 6.265 M ops/s | 6.498 M ops/s (+3.7%)\n| +- hits latency | 161.436 ns/op | 152.877 ns/op (-5.3%)\n| +- important_hits throughput | 1.636 M ops/s | 1.697 M ops/s (+3.7%)\n|\n| + num_maps: 1000\n| : | \n| +-+ local_storage cache sequential get +----------------------+----------------------\n| +- hits throughput | 0.355 M ops/s | 0.354 M ops/s ( ~ )\n| +- hits latency | 2826.538 ns/op | 2827.139 ns/op ( ~ )\n| +- important_hits throughput | 0.000 M ops/s | 0.000 M ops/s ( ~ )\n| :\n| : | \n| +-+ local_storage cache interleaved get +----------------------+----------------------\n| +- hits throughput | 0.404 M ops/s | 0.403 M ops/s ( ~ )\n| +- hits latency | 2481.190 ns/op | 2487.555 ns/op ( ~ )\n| +- important_hits throughput | 0.102 M ops/s | 0.101 M ops/s ( ~ )\n\nThe on_lookup test in {cgrp', 'task}_ls_recursion.c is removed\nbecause the bpf_local_storage_lookup is no longer traceable\nand adding tracepoint will make the compiler generate worse\ncode: https://lore.kernel.org/bpf/ZcJmok64Xqv6l4ZS@elver.google.com/\n\nSigned-off-by: Marco Elver \nCc: Martin KaFai Lau \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240207122626.3508658-1-elver@google.com\nSigned-off-by: Martin KaFai Lau \n', '']",Enable compiler to inline bpf_local_storage_lookup() for improved performance in BPF programs.,"compiler,inlining,performance",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d27553c14f06f4db61cb9ddaf88e8d4df91d740c,d27553c14f06f4db61cb9ddaf88e8d4df91d740c,Jinjian Song,jinjian.song@fibocom.com,1707128549,David S. Miller,davem@davemloft.net,1707480468,e583d2ef036c42727f1227315eca3aa5a38dfecb,409c38d4f156740bf3165fd6ceae4fa6425eebf4,"net: wwan: t7xx: Infrastructure for early port configuration + +To support cases such as FW update or Core dump"," the t7xx +device is capable of signaling the host that a special port +needs to be created before the handshake phase. + +Adds the infrastructure required to create the early ports +which also requires a different configuration of CLDMA queues. + +Base on the v5 patch version of follow series: +'net: wwan: t7xx: fw flashing & coredump support' +(https://patchwork.kernel.org/project/netdevbpf/patch/3777bb382f4b0395cb594a602c5c79dbab86c9e0.1674307425.git.m.chetan.kumar@linux.intel.com/) + +Signed-off-by: Jinjian Song +Signed-off-by: David S. Miller +",[''],"This commit adds early port infrastructure for t7xx device in network subsystem, supporting firmware updates and core dumps.","early port infrastructure, firmware update, core dump",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +a7170d81e0002345576b5f87a5890d91bc06c106,a7170d81e0002345576b5f87a5890d91bc06c106,Martin KaFai Lau,martin.lau@kernel.org,1707419109,Martin KaFai Lau,martin.lau@kernel.org,1707421218,d86d4ccbb81089e586156921f3bc70d759d02936,e55dad12abe42383b68ba88212eb3d0fba0e9820 947e56f82fd783a1ec1c9359b20b5699d09cae14,Merge branch 'bpf," btf: Add DEBUG_INFO_BTF checks for __register_bpf_struct_ops' + +Geliang Tang says: + +==================== +bpf: Add DEBUG_INFO_BTF checks for __register_bpf_struct_ops + +This patch set avoids module loading failure when the module +trying to register a struct_ops and the module has its btf section +stripped. This will then work similarly as module kfunc registration in +commit 3de4d22cc9ac (""bpf","[' btf: Warn but return no error for NULL btf from __register_btf_kfunc_id_set()"")\n\nv5:\n - drop CONFIG_MODULE_ALLOW_BTF_MISMATCH check as Martin suggested.\n\nv4:\n - add a new patch to fix error checks for btf_get_module_btf.\n - rename the helper to check_btf_kconfigs.\n\nv3:\n - fix this build error:\nkernel/bpf/btf.c:7750:11: error: incomplete definition of type \'struct module\'\n\nReported-by: kernel test robot \nCloses: https://lore.kernel.org/oe-kbuild-all/202402040934.Fph0XeEo-lkp@intel.com/\n\nv2:\n - add register_check_missing_btf helper as Jiri suggested.\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",Fix module loading issues by adding DEBUG_INFO_BTF checks for struct_ops registration in eBPF.,"DEBUG_INFO_BTF, struct_ops, module",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +947e56f82fd783a1ec1c9359b20b5699d09cae14,947e56f82fd783a1ec1c9359b20b5699d09cae14,Geliang Tang,tanggeliang@kylinos.cn,1707373463,Martin KaFai Lau,martin.lau@kernel.org,1707421069,d86d4ccbb81089e586156921f3bc70d759d02936,9e60b0e02550aaf5f2301e49353641a5e3701674,bpf," btf: Check btf for register_bpf_struct_ops + +Similar to the handling in the functions __register_btf_kfunc_id_set() +and register_btf_id_dtor_kfuncs()","[' this patch uses the newly added\nhelper check_btf_kconfigs() to handle module with its btf section\nstripped.\n\nWhile at it', ' the patch also adds the missed IS_ERR() check to fix the\ncommit f6be98d19985 (""bpf', ' net: switch to dynamic registration"")\n\nFixes: f6be98d19985 (""bpf', ' net: switch to dynamic registration"")\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/69082b9835463fe36f9e354bddf2d0a97df39c2b.1707373307.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Add btf check for register_bpf_struct_ops aligning with similar btf use in registration functions.,"btf, register, struct_ops",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9e60b0e02550aaf5f2301e49353641a5e3701674,9e60b0e02550aaf5f2301e49353641a5e3701674,Geliang Tang,tanggeliang@kylinos.cn,1707373462,Martin KaFai Lau,martin.lau@kernel.org,1707420176,eb3073aaab7aa1ca63533f8e396fb487df354172,b9a395f0f7af66fe8224450481b99d4f83b57207,bpf," btf: Add check_btf_kconfigs helper + +This patch extracts duplicate code on error path when btf_get_module_btf() +returns NULL from the functions __register_btf_kfunc_id_set() and +register_btf_id_dtor_kfuncs() into a new helper named check_btf_kconfigs() +to check CONFIG_DEBUG_INFO_BTF and CONFIG_DEBUG_INFO_BTF_MODULES in it. + +Signed-off-by: Geliang Tang +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/r/fa5537fc55f1e4d0bfd686598c81b7ab9dbd82b7.1707373307.git.tanggeliang@kylinos.cn +Signed-off-by: Martin KaFai Lau +",[''],Refactor error handling with check_btf_kconfigs helper for BTF module support.,"duplicated, error, helper",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b9a395f0f7af66fe8224450481b99d4f83b57207,b9a395f0f7af66fe8224450481b99d4f83b57207,Geliang Tang,tanggeliang@kylinos.cn,1707373461,Martin KaFai Lau,martin.lau@kernel.org,1707419107,1d92c1af25cd8725f9d870209de02717462b69bb,e55dad12abe42383b68ba88212eb3d0fba0e9820,bpf," btf: Fix return value of register_btf_id_dtor_kfuncs + +The same as __register_btf_kfunc_id_set()","[' to let the modules with\nstripped btf section loaded', ' this patch changes the return value of\nregister_btf_id_dtor_kfuncs() too from -ENOENT to 0 when btf is NULL.\n\nSigned-off-by: Geliang Tang \nLink: https://lore.kernel.org/r/eab65586d7fb0e72f2707d3747c7d4a5d60c823f.1707373307.git.tanggeliang@kylinos.cn\nSigned-off-by: Martin KaFai Lau \n', '']",Fixes the return value handling for BTF ID destructor kfuncs registration in BPF.,"BTF, return value, kfuncs",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +03fa49a386b298d357b90c9c5599f8d00dfc425c,03fa49a386b298d357b90c9c5599f8d00dfc425c,Paolo Abeni,pabeni@redhat.com,1707388402,Paolo Abeni,pabeni@redhat.com,1707388402,71db0a1c6f0d74e21e6ccb5b7a35a000e2f7ea5e,335bac1daae3fd9070d0f9f34d7d7ba708729256 bc4ce46b1e3d1da4309405cd4afc7c0fcddd0b90,"Merge branch 'cpsw-enable-mac_managed_pm-to-fix-mdio' + +Sinthu Raja says: + +==================== +CPSW: enable mac_managed_pm to fix mdio + +This patch fix the resume/suspend issue on CPSW interface. + +Reference from the foloowing patchwork: +https://lore.kernel.org/netdev/20221014144729.1159257-2-shenwei.wang@nxp.com/T/ + +V1: https://patchwork.kernel.org/project/netdevbpf/patch/20240122083414.6246-1-sinthu.raja@ti.com/ +V2: https://patchwork.kernel.org/project/netdevbpf/patch/20240122093326.7618-1-sinthu.raja@ti.com/ +==================== + +Link: https://lore.kernel.org/r/20240206005928.15703-1-sinthu.raja@ti.com +Signed-off-by: Paolo Abeni +",,Fix resume/suspend issue on CPSW interface by enabling mac_managed_pm.,"CPSW,mac_managed_pm,MDIO",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +79d72c68c58784a3e1cd2378669d51bfd0cb7498,79d72c68c58784a3e1cd2378669d51bfd0cb7498,Oscar Salvador,osalvador@suse.de,1706648658,Andrew Morton,akpm@linux-foundation.org,1707369636,5b501e855a003844b161205e566581253afb08e3,f2076032096775d1bb1af16b6eddbc6534575328,fs,"hugetlb: fix NULL pointer dereference in hugetlbs_fill_super + +When configuring a hugetlb filesystem via the fsconfig() syscall","[' there is\na possible NULL dereference in hugetlbfs_fill_super() caused by assigning\nNULL to ctx->hstate in hugetlbfs_parse_param() when the requested pagesize\nis non valid.\n\nE.g: Taking the following steps:\n\n fd = fsopen(""hugetlbfs""', ' FSOPEN_CLOEXEC);\n fsconfig(fd', ' FSCONFIG_SET_STRING', ' ""pagesize""', ' ""1024""', ' 0);\n fsconfig(fd', ' FSCONFIG_CMD_CREATE', ' NULL', ' NULL', ' 0);\n\nGiven that the requested ""pagesize"" is invalid', ' ctxt->hstate will be replaced\nwith NULL', ' losing its previous value', ' and we will print an error:\n\n ...\n ...\n case Opt_pagesize:\n ps = memparse(param->string', ' &rest);\n ctx->hstate = h;\n if (!ctx->hstate) {\n pr_err(""Unsupported page size %lu MB\\n""', ' ps / SZ_1M);\n return -EINVAL;\n }\n return 0;\n ...\n ...\n\nThis is a problem because later on', ' we will dereference ctxt->hstate in\nhugetlbfs_fill_super()\n\n ...\n ...\n sb->s_blocksize = huge_page_size(ctx->hstate);\n ...\n ...\n\nCausing below Oops.\n\nFix this by replacing cxt->hstate value only when then pagesize is known\nto be valid.\n\n kernel: hugetlbfs: Unsupported page size 0 MB\n kernel: BUG: kernel NULL pointer dereference', ' address: 0000000000000028\n kernel: #PF: supervisor read access in kernel mode\n kernel: #PF: error_code(0x0000) - not-present page\n kernel: PGD 800000010f66c067 P4D 800000010f66c067 PUD 1b22f8067 PMD 0\n kernel: Oops: 0000 [#1] PREEMPT SMP PTI\n kernel: CPU: 4 PID: 5659 Comm: syscall Tainted: G E 6.8.0-rc2-default+ #22 5a47c3fef76212addcc6eb71344aabc35190ae8f\n kernel: Hardware name: Intel Corp. GROVEPORT/GROVEPORT', ' BIOS GVPRCRB1.86B.0016.D04.1705030402 05/03/2017\n kernel: RIP: 0010:hugetlbfs_fill_super+0xb4/0x1a0\n kernel: Code: 48 8b 3b e8 3e c6 ed ff 48 85 c0 48 89 45 20 0f 84 d6 00 00 00 48 b8 ff ff ff ff ff ff ff 7f 4c 89 e7 49 89 44 24 20 48 8b 03 <8b> 48 28 b8 00 10 00 00 48 d3 e0 49 89 44 24 18 48 8b 03 8b 40 28\n kernel: RSP: 0018:ffffbe9960fcbd48 EFLAGS: 00010246\n kernel: RAX: 0000000000000000 RBX: ffff9af5272ae780 RCX: 0000000000372004\n kernel: RDX: ffffffffffffffff RSI: ffffffffffffffff RDI: ffff9af555e9b000\n kernel: RBP: ffff9af52ee66b00 R08: 0000000000000040 R09: 0000000000370004\n kernel: R10: ffffbe9960fcbd48 R11: 0000000000000040 R12: ffff9af555e9b000\n kernel: R13: ffffffffa66b86c0 R14: ffff9af507d2f400 R15: ffff9af507d2f400\n kernel: FS: 00007ffbc0ba4740(0000) GS:ffff9b0bd7000000(0000) knlGS:0000000000000000\n kernel: CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033\n kernel: CR2: 0000000000000028 CR3: 00000001b1ee0000 CR4: 00000000001506f0\n kernel: Call Trace:\n kernel: \n kernel: ? __die_body+0x1a/0x60\n kernel: ? page_fault_oops+0x16f/0x4a0\n kernel: ? search_bpf_extables+0x65/0x70\n kernel: ? fixup_exception+0x22/0x310\n kernel: ? exc_page_fault+0x69/0x150\n kernel: ? asm_exc_page_fault+0x22/0x30\n kernel: ? __pfx_hugetlbfs_fill_super+0x10/0x10\n kernel: ? hugetlbfs_fill_super+0xb4/0x1a0\n kernel: ? hugetlbfs_fill_super+0x28/0x1a0\n kernel: ? __pfx_hugetlbfs_fill_super+0x10/0x10\n kernel: vfs_get_super+0x40/0xa0\n kernel: ? __pfx_bpf_lsm_capable+0x10/0x10\n kernel: vfs_get_tree+0x25/0xd0\n kernel: vfs_cmd_create+0x64/0xe0\n kernel: __x64_sys_fsconfig+0x395/0x410\n kernel: do_syscall_64+0x80/0x160\n kernel: ? syscall_exit_to_user_mode+0x82/0x240\n kernel: ? do_syscall_64+0x8d/0x160\n kernel: ? syscall_exit_to_user_mode+0x82/0x240\n kernel: ? do_syscall_64+0x8d/0x160\n kernel: ? exc_page_fault+0x69/0x150\n kernel: entry_SYSCALL_64_after_hwframe+0x6e/0x76\n kernel: RIP: 0033:0x7ffbc0cb87c9\n kernel: Code: 00 90 90 90 90 90 90 90 90 90 90 90 90 90 90 66 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 97 96 0d 00 f7 d8 64 89 01 48\n kernel: RSP: 002b:00007ffc29d2f388 EFLAGS: 00000206 ORIG_RAX: 00000000000001af\n kernel: RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007ffbc0cb87c9\n kernel: RDX: 0000000000000000 RSI: 0000000000000006 RDI: 0000000000000003\n kernel: RBP: 00007ffc29d2f3b0 R08: 0000000000000000 R09: 0000000000000000\n kernel: R10: 0000000000000000 R11: 0000000000000206 R12: 0000000000000000\n kernel: R13: 00007ffc29d2f4c0 R14: 0000000000000000 R15: 0000000000000000\n kernel: \n kernel: Modules linked in: rpcsec_gss_krb5(E) auth_rpcgss(E) nfsv4(E) dns_resolver(E) nfs(E) lockd(E) grace(E) sunrpc(E) netfs(E) af_packet(E) bridge(E) stp(E) llc(E) iscsi_ibft(E) iscsi_boot_sysfs(E) intel_rapl_msr(E) intel_rapl_common(E) iTCO_wdt(E) intel_pmc_bxt(E) sb_edac(E) iTCO_vendor_support(E) x86_pkg_temp_thermal(E) intel_powerclamp(E) coretemp(E) kvm_intel(E) rfkill(E) ipmi_ssif(E) kvm(E) acpi_ipmi(E) irqbypass(E) pcspkr(E) igb(E) ipmi_si(E) mei_me(E) i2c_i801(E) joydev(E) intel_pch_thermal(E) i2c_smbus(E) dca(E) lpc_ich(E) mei(E) ipmi_devintf(E) ipmi_msghandler(E) acpi_pad(E) tiny_power_button(E) button(E) fuse(E) efi_pstore(E) configfs(E) ip_tables(E) x_tables(E) ext4(E) mbcache(E) jbd2(E) hid_generic(E) usbhid(E) sd_mod(E) t10_pi(E) crct10dif_pclmul(E) crc32_pclmul(E) crc32c_intel(E) polyval_clmulni(E) ahci(E) xhci_pci(E) polyval_generic(E) gf128mul(E) ghash_clmulni_intel(E) sha512_ssse3(E) sha256_ssse3(E) xhci_pci_renesas(E) libahci(E) ehci_pci(E) sha1_ssse3(E) xhci_hcd(E) ehci_hcd(E) libata(E)\n kernel: mgag200(E) i2c_algo_bit(E) usbcore(E) wmi(E) sg(E) dm_multipath(E) dm_mod(E) scsi_dh_rdac(E) scsi_dh_emc(E) scsi_dh_alua(E) scsi_mod(E) scsi_common(E) aesni_intel(E) crypto_simd(E) cryptd(E)\n kernel: Unloaded tainted modules: acpi_cpufreq(E):1 fjes(E):1\n kernel: CR2: 0000000000000028\n kernel: ---[ end trace 0000000000000000 ]---\n kernel: RIP: 0010:hugetlbfs_fill_super+0xb4/0x1a0\n kernel: Code: 48 8b 3b e8 3e c6 ed ff 48 85 c0 48 89 45 20 0f 84 d6 00 00 00 48 b8 ff ff ff ff ff ff ff 7f 4c 89 e7 49 89 44 24 20 48 8b 03 <8b> 48 28 b8 00 10 00 00 48 d3 e0 49 89 44 24 18 48 8b 03 8b 40 28\n kernel: RSP: 0018:ffffbe9960fcbd48 EFLAGS: 00010246\n kernel: RAX: 0000000000000000 RBX: ffff9af5272ae780 RCX: 0000000000372004\n kernel: RDX: ffffffffffffffff RSI: ffffffffffffffff RDI: ffff9af555e9b000\n kernel: RBP: ffff9af52ee66b00 R08: 0000000000000040 R09: 0000000000370004\n kernel: R10: ffffbe9960fcbd48 R11: 0000000000000040 R12: ffff9af555e9b000\n kernel: R13: ffffffffa66b86c0 R14: ffff9af507d2f400 R15: ffff9af507d2f400\n kernel: FS: 00007ffbc0ba4740(0000) GS:ffff9b0bd7000000(0000) knlGS:0000000000000000\n kernel: CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033\n kernel: CR2: 0000000000000028 CR3: 00000001b1ee0000 CR4: 00000000001506f0\n\nLink: https://lkml.kernel.org/r/20240130210418.3771-1-osalvador@suse.de\nFixes: 32021982a324 (""hugetlbfs: Convert to fs_context"")\nSigned-off-by: Michal Hocko \nSigned-off-by: Oscar Salvador \nAcked-by: Muchun Song \nCc: \nSigned-off-by: Andrew Morton \n', '']",Fix a NULL pointer dereference in hugetlb filesystem configuration using fsconfig() syscall.,"NULL pointer, hugetlb, fsconfig",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +e55dad12abe42383b68ba88212eb3d0fba0e9820,e55dad12abe42383b68ba88212eb3d0fba0e9820,Masahiro Yamada,masahiroy@kernel.org,1707033394,Andrii Nakryiko,andrii@kernel.org,1707352700,95060d8656e08791594f03f7a6f9897238a7dc0f,ba6a6abb3bfa8377bcf386a11077c0533909f9e8,"bpf: Merge two CONFIG_BPF entries + +'config BPF' exists in both init/Kconfig and kernel/bpf/Kconfig. + +Commit b24abcff918a (""bpf"," kconfig: Add consolidated menu entry for bpf +with core options"") added the second one to kernel/bpf/Kconfig instead +of moving the existing one. + +Merge them together. + +Signed-off-by: Masahiro Yamada +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240204075634.32969-1-masahiroy@kernel.org +",[''],Merge two CONFIG_BPF entries from init/Kconfig and kernel/bpf/Kconfig into one.,"CONFIG_BPF,Kconfig,merge",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['other'] +ba6a6abb3bfa8377bcf386a11077c0533909f9e8,ba6a6abb3bfa8377bcf386a11077c0533909f9e8,Yafang Shao,laoar.shao@gmail.com,1707207255,Andrii Nakryiko,andrii@kernel.org,1707351259,2a279297c137645aa92eedc2632d6f675ab179ea,a2bff65cfca93f0fe4c5996f55ce8f413e85e4fe,"selftests/bpf: Mark cpumask kfunc declarations as __weak + +After the series ""Annotate kfuncs in .BTF_ids section""[0]"," kfuncs can be +generated from bpftool. Let's mark the existing cpumask kfunc declarations +__weak so they don't conflict with definitions that will eventually come +from vmlinux.h. + +[0]. https://lore.kernel.org/all/cover.1706491398.git.dxu@dxuuu.xyz + +Suggested-by: Andrii Nakryiko +Signed-off-by: Yafang Shao +Signed-off-by: Andrii Nakryiko +Acked-by: Daniel Xu +Link: https://lore.kernel.org/bpf/20240206081416.26242-5-laoar.shao@gmail.com +",[''],Mark cpumask kfunc declarations as __weak to avoid conflicts with future vmlinux.h definitions.,"cpumask,kfunc,weak",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a2bff65cfca93f0fe4c5996f55ce8f413e85e4fe,a2bff65cfca93f0fe4c5996f55ce8f413e85e4fe,Yafang Shao,laoar.shao@gmail.com,1707207254,Andrii Nakryiko,andrii@kernel.org,1707351259,08f77121b850c0a41aebedae163280cf12231b49,abae1ac5231e56ecc3932f83f2de13701070803a,"selftests/bpf: Fix error checking for cpumask_success__load() + +We should verify the return value of cpumask_success__load(). + +Signed-off-by: Yafang Shao +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240206081416.26242-4-laoar.shao@gmail.com +",,Added error checking for cpumask_success__load() in the selftests/bpf tests.,"error checking,selftests,bpf",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +abae1ac5231e56ecc3932f83f2de13701070803a,abae1ac5231e56ecc3932f83f2de13701070803a,Andrii Nakryiko,andrii@kernel.org,1707350178,Andrii Nakryiko,andrii@kernel.org,1707350178,78646bb8e255f22fb742237706ed2d49bbeee529,92a871ab9fa59a74d013bc04f321026a057618e7 903fad4394666bc23975c93fb58f137ce64b5192,"Merge branch 'tools-resolve_btfids-fix-cross-compilation-to-non-host-endianness' + +Viktor Malik says: + +==================== +tools/resolve_btfids: fix cross-compilation to non-host endianness + +The .BTF_ids section is pre-filled with zeroed BTF ID entries during the +build and afterwards patched by resolve_btfids with correct values. +Since resolve_btfids always writes in host-native endianness"," it relies +on libelf to do the translation when the target ELF is cross-compiled to +a different endianness (this was introduced in commit 61e8aeda9398 +(""bpf: Fix libelf endian handling in resolv_btfids"")). + +Unfortunately","["" the translation will corrupt the flags fields of SET8\nentries because these were written during vmlinux compilation and are in\nthe correct endianness already. This will lead to numerous selftests\nfailures such as:\n\n $ sudo ./test_verifier 502 502\n #502/p sleepable fentry accept FAIL\n Failed to load prog 'Invalid argument'!\n bpf_fentry_test1 is not sleepable\n verification time 34 usec\n stack depth 0\n processed 0 insns (limit 1000000) max_states_per_insn 0 total_states 0 peak_states 0 mark_read 0\n Summary: 0 PASSED"", ' 0 SKIPPED', "" 1 FAILED\n\nSince it's not possible to instruct libelf to translate just certain\nvalues"", "" let's manually bswap the flags (both global and entry flags) in\nresolve_btfids when needed"", "" so that libelf then translates everything\ncorrectly.\n\nThe first patch of the series refactors resolve_btfids by using types\nfrom btf_ids.h instead of accessing the BTF ID data using magic offsets.\nAcked-by: Jiri Olsa \n---\nChanges in v4:\n- remove unnecessary vars and pointer casts (suggested by Daniel Xu)\n\nChanges in v3:\n- add byte swap of global 'flags' field in btf_id_set8 (suggested by\n Jiri Olsa)\n- cleaner refactoring of sets_patch (suggested by Jiri Olsa)\n- add compile-time assertion that IDs are at the beginning of pairs\n struct in btf_id_set8 (suggested by Daniel Borkmann)\n\nChanges in v2:\n- use type defs from btf_ids.h (suggested by Andrii Nakryiko)\n====================\n\nLink: https://lore.kernel.org/r/cover.1707223196.git.vmalik@redhat.com\nSigned-off-by: Andrii Nakryiko \n"", '']",The commit fixes cross-compilation of BTF ID entries in non-host endianness.,"cross-compilation,BTF,endianness",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +903fad4394666bc23975c93fb58f137ce64b5192,903fad4394666bc23975c93fb58f137ce64b5192,Viktor Malik,vmalik@redhat.com,1707223570,Andrii Nakryiko,andrii@kernel.org,1707350178,78646bb8e255f22fb742237706ed2d49bbeee529,9707ac4fe2f5bac6406d2403f8b8a64d7b3d8e43,"tools/resolve_btfids: Fix cross-compilation to non-host endianness + +The .BTF_ids section is pre-filled with zeroed BTF ID entries during the +build and afterwards patched by resolve_btfids with correct values. +Since resolve_btfids always writes in host-native endianness"," it relies +on libelf to do the translation when the target ELF is cross-compiled to +a different endianness (this was introduced in commit 61e8aeda9398 +(""bpf: Fix libelf endian handling in resolv_btfids"")). + +Unfortunately","["" the translation will corrupt the flags fields of SET8\nentries because these were written during vmlinux compilation and are in\nthe correct endianness already. This will lead to numerous selftests\nfailures such as:\n\n $ sudo ./test_verifier 502 502\n #502/p sleepable fentry accept FAIL\n Failed to load prog 'Invalid argument'!\n bpf_fentry_test1 is not sleepable\n verification time 34 usec\n stack depth 0\n processed 0 insns (limit 1000000) max_states_per_insn 0 total_states 0 peak_states 0 mark_read 0\n Summary: 0 PASSED"", ' 0 SKIPPED', "" 1 FAILED\n\nSince it's not possible to instruct libelf to translate just certain\nvalues"", "" let's manually bswap the flags (both global and entry flags) in\nresolve_btfids when needed"", ' so that libelf then translates everything\ncorrectly.\n\nFixes: ef2c6f370a63 (""tools/resolve_btfids: Add support for 8-byte BTF sets"")\nSigned-off-by: Viktor Malik \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/7b6bff690919555574ce0f13d2a5996cacf7bf69.1707223196.git.vmalik@redhat.com\n', '']",Fixes cross-compilation issue in resolve_btfids for non-host endianness by correcting BTF ID entry handling.,"cross-compilation,endian,BTF",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9707ac4fe2f5bac6406d2403f8b8a64d7b3d8e43,9707ac4fe2f5bac6406d2403f8b8a64d7b3d8e43,Viktor Malik,vmalik@redhat.com,1707223569,Andrii Nakryiko,andrii@kernel.org,1707350178,0d58e1e1bff4f1d5e73cb9f11b7fa9157ec58a14,92a871ab9fa59a74d013bc04f321026a057618e7,"tools/resolve_btfids: Refactor set sorting with types from btf_ids.h + +Instead of using magic offsets to access BTF ID set data"," leverage types +from btf_ids.h (btf_id_set and btf_id_set8) which define the actual +layout of the data. Thanks to this change","["" set sorting should also\ncontinue working if the layout changes.\n\nThis requires to sync the definition of 'struct btf_id_set8' from\ninclude/linux/btf_ids.h to tools/include/linux/btf_ids.h. We don't sync\nthe rest of the file at the moment"", "" b/c that would require to also sync\nmultiple dependent headers and we don't need any other defs from\nbtf_ids.h.\n\nSigned-off-by: Viktor Malik \nSigned-off-by: Andrii Nakryiko \nAcked-by: Daniel Xu \nLink: https://lore.kernel.org/bpf/ff7f062ddf6a00815fda3087957c4ce667f50532.1707223196.git.vmalik@redhat.com\n"", '']",Refactor tools/resolve_btfids to use type definitions from btf_ids.h for set sorting.,"refactor,BTF ID,tools",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +92a871ab9fa59a74d013bc04f321026a057618e7,92a871ab9fa59a74d013bc04f321026a057618e7,Toke Høiland-Jørgensen,toke@redhat.com,1707224362,Andrii Nakryiko,andrii@kernel.org,1707241886,8e13b5d7d65df829f352e669512badd7f97fb2b5,c27aa462aa78ff157fdda222af242e4571803d4a,"libbpf: Use OPTS_SET() macro in bpf_xdp_query() + +When the feature_flags and xdp_zc_max_segs fields were added to the libbpf +bpf_xdp_query_opts"," the code writing them did not use the OPTS_SET() macro. +This causes libbpf to write to those fields unconditionally","[' which means\nthat programs compiled against an older version of libbpf (with a smaller\nsize of the bpf_xdp_query_opts struct) will have its stack corrupted by\nlibbpf writing out of bounds.\n\nThe patch adding the feature_flags field has an early bail out if the\nfeature_flags field is not part of the opts struct (via the OPTS_HAS)\nmacro', ' but the patch adding xdp_zc_max_segs does not. For consistency', ' this\nfix just changes the assignments to both fields to use the OPTS_SET()\nmacro.\n\nFixes: 13ce2daa259a (""xsk: add new netlink attribute dedicated for ZC max frags"")\nSigned-off-by: Toke Høiland-Jørgensen \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240206125922.1992815-1-toke@redhat.com\n', '']",The commit updates libbpf's bpf_xdp_query function to use the OPTS_SET() macro for feature_flags and xdp_zc_max_segs fields.,"libbpf, OPTS_SET, bpf_xdp_query",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,['xdp like programs'] +c27aa462aa78ff157fdda222af242e4571803d4a,c27aa462aa78ff157fdda222af242e4571803d4a,Jose E. Marchesi,jose.marchesi@oracle.com,1707215010,Andrii Nakryiko,andrii@kernel.org,1707241225,9fa7f115dee42bc9786a742bd5c661970cfc71d1,563918a0e3afd97bcfb680b72c52ec080c82aea6,"bpf: Use -Wno-address-of-packed-member in some selftests + +[Differences from V2: +- Remove conditionals in the source files pragmas"," as the + pragma is supported by both GCC and clang.] + +Both GCC and clang implement the -Wno-address-of-packed-member +warning","[' which is enabled by -Wall', ' that warns about taking the\naddress of a packed struct field when it can lead to an ""unaligned""\naddress.\n\nThis triggers the following errors (-Werror) when building three\nparticular BPF selftests with GCC:\n\n progs/test_cls_redirect.c\n 986 | if (ipv4_is_fragment((void *)&encap->ip)) {\n progs/test_cls_redirect_dynptr.c\n 410 | pkt_ipv4_checksum((void *)&encap_gre->ip);\n progs/test_cls_redirect.c\n 521 | pkt_ipv4_checksum((void *)&encap_gre->ip);\n progs/test_tc_tunnel.c\n 232 | set_ipv4_csum((void *)&h_outer.ip);\n\nThese warnings do not signal any real problem in the tests as far as I\ncan see.\n\nThis patch adds pragmas to these test files that inhibit the\n-Waddress-of-packed-member warning.\n\nTested in bpf-next master.\nNo regressions.\n\nSigned-off-by: Jose E. Marchesi \nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240206102330.7113-1-jose.marchesi@oracle.com\n', '']",Suppress the address-of-packed-member warning in certain BPF selftests using specific compiler flags.,"compiler, selftests, warning",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +563918a0e3afd97bcfb680b72c52ec080c82aea6,563918a0e3afd97bcfb680b72c52ec080c82aea6,Dave Thaler,dthaler1968@googlemail.com,1707195106,Alexei Starovoitov,ast@kernel.org,1707234299,e3a42c09c1b3d1e748b044ca7fca5e831e9a4139,c7dcb6c9aa85fa310251dad7e233eb955a5235ed,bpf," docs: Fix typos in instructions-set.rst + +* ""imm32"" should just be ""imm"" +* Add blank line to fix formatting error reported by Stephen Rothwell [0] + +[0]: https://lore.kernel.org/bpf/20240206153301.4ead0bad@canb.auug.org.au/T/#u + +Signed-off-by: Dave Thaler +Acked-by: David Vernet +Link: https://lore.kernel.org/r/20240206045146.4965-1-dthaler1968@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Fix typos and formatting errors in BPF documentation files.,"typos, formatting, documentation",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +c7dcb6c9aa85fa310251dad7e233eb955a5235ed,c7dcb6c9aa85fa310251dad7e233eb955a5235ed,Andrii Nakryiko,andrii@kernel.org,1707180008,Alexei Starovoitov,ast@kernel.org,1707192158,1b1f362cb3489569fd473d0fda11c678c016df7c,d7bc416aa5cc183691287e8f0b1d5b182a7ce9c3,"selftests/bpf: mark dynptr kfuncs __weak to make them optional on old kernels + +Mark dynptr kfuncs as __weak to allow +verifier_global_subprogs/arg_ctx_{perf",kprobe,"['raw_tp} subtests to be\nloadable on old kernels. Because bpf_dynptr_from_xdp() kfunc is used\nfrom arg_tag_dynptr BPF program in progs/verifier_global_subprogs.c\n*and* is not marked as __weak', "" loading any subtest from\nverifier_global_subprogs fails on old kernels that don't have\nbpf_dynptr_from_xdp() kfunc defined. Even if arg_tag_dynptr program\nitself is not loaded"", "" libbpf bails out on non-weak reference to\nbpf_dynptr_from_xdp (that can't be resolved)"", ' which shared across all\nprograms in progs/verifier_global_subprogs.c.\n\nSo mark all dynptr-related kfuncs as __weak to unblock libbpf CI ([0]).\nIn the upcoming ""kfunc in vmlinux.h"" work we should make sure that\nkfuncs are always declared __weak as well.\n\n [0] https://github.com/libbpf/libbpf/actions/runs/7792673215/job/21251250831?pr=776#step:4:7961\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240206004008.1541513-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Mark dynamic pointer kfuncs as __weak to ensure compatibility with older kernels in BPF selftests.,"dynptr, optional, kfuncs",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +d7bc416aa5cc183691287e8f0b1d5b182a7ce9c3,d7bc416aa5cc183691287e8f0b1d5b182a7ce9c3,Andrii Nakryiko,andrii@kernel.org,1707178963,Alexei Starovoitov,ast@kernel.org,1707192106,1e054fec46141850da461e64e9a72c06039dbcff,6146fae67bc2b92100bff8b2d6a6d5bca07edcf8,"libbpf: fix return value for PERF_EVENT __arg_ctx type fix up check + +If PERF_EVENT program has __arg_ctx argument with matching +architecture-specific pt_regs/user_pt_regs/user_regs_struct pointer +type", libbpf should still perform type rewrite for old kernels,"[' but not\nemit the warning. Fix copy/paste from kernel code where 0 is meant to\nsignify ""no error"" condition. For libbpf we need to return ""true"" to\nproceed with type rewrite (which for PERF_EVENT program will be\na canonical `struct bpf_perf_event_data *` type).\n\nFixes: 9eea8fafe33e (""libbpf: fix __arg_ctx type enforcement for perf_event programs"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240206002243.1439450-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes return value handling for type fix-up check in libbpf for PERF_EVENT programs.,"libbpf,return value,PERF_EVENT",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,['tracepoints like programs'] +20a286c1a35ba4dc2fca5d4c1fb2e7ced101e576,20a286c1a35ba4dc2fca5d4c1fb2e7ced101e576,Alexei Starovoitov,ast@kernel.org,1707192014,Alexei Starovoitov,ast@kernel.org,1707192014,5633630512456d6639125786010e2125253f83eb,8244ab509f89d63941d5ee207967c5a3e00bb493 8be6a0147af314fd60db9da2158cd737dc6394a7,"Merge branch 'transfer-rcu-lock-state-across-subprog-calls' + +Kumar Kartikeya Dwivedi says: + +==================== +Transfer RCU lock state across subprog calls + +David suggested during the discussion in [0] that we should handle RCU +locks in a similar fashion to spin locks where the verifier understands +when a lock held in a caller is released in callee"," or lock taken in +callee is released in a caller","[' or the callee is called within a lock\ncritical section. This set extends the same semantics to RCU read locks\nand adds a few selftests to verify correct behavior. This issue has also\ncome up for sched-ext programs.\n\nThis would now allow static subprog calls to be made without errors\nwithin RCU read sections', ' for subprogs to release RCU locks of callers\nand return to them', ' or for subprogs to take RCU lock which is later\nreleased in the caller.\n\n [0]: https://lore.kernel.org/bpf/20240204120206.796412-1-memxor@gmail.com\n\nChangelog:\n----------\nv1 -> v2:\nv1: https://lore.kernel.org/bpf/20240204230231.1013964-1-memxor@gmail.com\n\n * Add tests for global subprog behaviour (Yafang)\n * Add Acks', ' Tested-by (Yonghong', ' Yafang)\n====================\n\nLink: https://lore.kernel.org/r/20240205055646.1112186-1-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Implements transfer of RCU lock state across subprogram calls in eBPF verifier.,"RCU,verifier,locks",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8be6a0147af314fd60db9da2158cd737dc6394a7,8be6a0147af314fd60db9da2158cd737dc6394a7,Kumar Kartikeya Dwivedi,memxor@gmail.com,1707112606,Alexei Starovoitov,ast@kernel.org,1707192014,5633630512456d6639125786010e2125253f83eb,6fceea0fa59f6786a2847a4cae409117624e8b58,"selftests/bpf: Add tests for RCU lock transfer between subprogs + +Add selftests covering the following cases: +- A static or global subprog called from within a RCU read section works +- A static subprog taking an RCU read lock which is released in caller works +- A static subprog releasing the caller's RCU read lock works + +Global subprogs that leave the lock in an imbalanced state will not +work", as they are verified separately,"[' so ensure those cases fail as\nwell.\n\nAcked-by: Yonghong Song \nSigned-off-by: Kumar Kartikeya Dwivedi \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240205055646.1112186-3-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftests for RCU lock handling in static or global subprograms within BPF programs.,"selftests, RCU lock, subprograms",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'cgroup like programs']" +6fceea0fa59f6786a2847a4cae409117624e8b58,6fceea0fa59f6786a2847a4cae409117624e8b58,Kumar Kartikeya Dwivedi,memxor@gmail.com,1707112605,Alexei Starovoitov,ast@kernel.org,1707192014,0756fa0cce159ca3d2eb887f3b4c53fab2e823c5,8244ab509f89d63941d5ee207967c5a3e00bb493,"bpf: Transfer RCU lock state between subprog calls + +Allow transferring an imbalanced RCU lock state between subprog calls +during verification. This allows patterns where a subprog call returns +with an RCU lock held"," or a subprog call releases an RCU lock held by +the caller. Currently","[' the verifier would end up complaining if the RCU\nlock is not released when processing an exit from a subprog', ' which is\nnon-ideal if its execution is supposed to be enclosed in an RCU read\nsection of the caller.\n\nInstead', ' simply only check whether we are processing exit for frame#0\nand do not complain on an active RCU lock otherwise. We only need to\nupdate the check when processing BPF_EXIT insn', ' as copy_verifier_state\nis already set up to do the right thing.\n\nSuggested-by: David Vernet \nTested-by: Yafang Shao \nAcked-by: Yonghong Song \nSigned-off-by: Kumar Kartikeya Dwivedi \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240205055646.1112186-2-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Enable transferring imbalanced RCU lock state between subprogram calls during eBPF verification.,"RCU lock,state transfer,subprog calls",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8244ab509f89d63941d5ee207967c5a3e00bb493,8244ab509f89d63941d5ee207967c5a3e00bb493,Alexei Starovoitov,ast@kernel.org,1707191927,Alexei Starovoitov,ast@kernel.org,1707191927,b0dda80da2bdd867ad47d5d108bbea0e1e5f822c,2d9a925d0fbf0dae99af148adaf4f5cadf1be5e0 e8699c4ff85baedcf40f33db816cc487cee39397,"Merge branch 'enable-static-subprog-calls-in-spin-lock-critical-sections' + +Kumar Kartikeya Dwivedi says: + +==================== +Enable static subprog calls in spin lock critical sections + +This set allows a BPF program to make a call to a static subprog within +a bpf_spin_lock critical section. This problem has been hit in sched-ext +and ghOSt [0] as well"," and is mostly an annoyance which is worked around +by inling the static subprog into the critical section. + +In case of sched-ext","[' there are a lot of other helper/kfunc calls that\nneed to be allow listed for the support to be complete', ' but a separate\nfollow up will deal with that.\n\nUnlike static subprogs', ' global subprogs cannot be allowed yet as the\nverifier will not explore their body when encountering a call\ninstruction for them. Therefore', ' we would need an alternative approach\n(some sort of function summarization to ensure a lock is never taken\nfrom a global subprog and all its callees).\n\n [0]: https://lore.kernel.org/bpf/bd173bf2-dea6-3e0e-4176-4a9256a9a056@google.com\n\nChangelog:\n----------\nv1 -> v2\nv1: https://lore.kernel.org/bpf/20240204120206.796412-1-memxor@gmail.com\n\n * Indicate global function call in verifier error string (Yonghong', ' David)\n * Add Acks from Yonghong', ' David\n====================\n\nLink: https://lore.kernel.org/r/20240204222349.938118-1-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Enable static subprog calls within bpf_spin_lock critical sections in eBPF programs.,"static subprog, spin lock, eBPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['scheduler like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e8699c4ff85baedcf40f33db816cc487cee39397,e8699c4ff85baedcf40f33db816cc487cee39397,Kumar Kartikeya Dwivedi,memxor@gmail.com,1707085429,Alexei Starovoitov,ast@kernel.org,1707191927,b0dda80da2bdd867ad47d5d108bbea0e1e5f822c,a44b1334aadd82203f661adb9adb41e53ad0e8d1,"selftests/bpf: Add test for static subprog call in lock cs + +Add selftests for static subprog calls within bpf_spin_lock critical +section"," and ensure we still reject global subprog calls. Also test the +case where a subprog call will unlock the caller's held lock","[' or the\ncaller will unlock a lock taken by a subprog call', ' ensuring correct\ntransfer of lock state across frames on exit.\n\nAcked-by: Yonghong Song \nAcked-by: David Vernet \nSigned-off-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/r/20240204222349.938118-3-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit adds selftests for static subprogram calls within bpf_spin_lock critical section.,"selftests, subprog, bpf_spin_lock",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a44b1334aadd82203f661adb9adb41e53ad0e8d1,a44b1334aadd82203f661adb9adb41e53ad0e8d1,Kumar Kartikeya Dwivedi,memxor@gmail.com,1707085428,Alexei Starovoitov,ast@kernel.org,1707191927,05b11f422c3dc5bc08aec65c23cda9a0a3b7d885,2d9a925d0fbf0dae99af148adaf4f5cadf1be5e0,"bpf: Allow calling static subprogs while holding a bpf_spin_lock + +Currently", calling any helpers,"[' kfuncs', ' or subprogs except the graph\ndata structure (lists', "" rbtrees) API kfuncs while holding a bpf_spin_lock\nis not allowed. One of the original motivations of this decision was to\nforce the BPF programmer's hand into keeping the bpf_spin_lock critical\nsection small"", ' and to ensure the execution time of the program does not\nincrease due to lock waiting times. In addition to this', ' some of the\nhelpers and kfuncs may be unsafe to call while holding a bpf_spin_lock.\n\nHowever', ' when it comes to subprog calls', ' atleast for static subprogs', '\nthe verifier is able to explore their instructions during verification.\nTherefore', ' it is similar in effect to having the same code inlined into\nthe critical section. Hence', ' not allowing static subprog calls in the\nbpf_spin_lock critical section is mostly an annoyance that needs to be\nworked around', ' without providing any tangible benefit.\n\nUnlike static subprog calls', ' global subprog calls are not safe to permit\nwithin the critical section', ' as the verifier does not explore them\nduring verification', ' therefore whether the same lock will be taken\nagain', ' or unlocked', ' cannot be ascertained.\n\nTherefore', ' allow calling static subprogs within a bpf_spin_lock critical\nsection', ' and only reject it in case the subprog linkage is global.\n\nAcked-by: Yonghong Song \nAcked-by: David Vernet \nSigned-off-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/r/20240204222349.938118-2-memxor@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit allows calling static subprograms while holding a bpf_spin_lock in eBPF programs.,"bpf_spin_lock,static subprograms,eBPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['xdp like programs', 'tc/netfilter like programs', 'tracepoints like programs']" +2d9a925d0fbf0dae99af148adaf4f5cadf1be5e0,2d9a925d0fbf0dae99af148adaf4f5cadf1be5e0,Dave Thaler,dthaler1968@googlemail.com,1706911870,Alexei Starovoitov,ast@kernel.org,1707173085,d9dea1846484578b31d59625e04b3821f590a24c,e7f31873176a345d72ca77c7b4da48493ccd9efd,bpf," docs: Expand set of initial conformance groups + +This patch attempts to update the ISA specification according +to the latest mailing list discussion about conformance groups","['\nin a way that is intended to be consistent with IANA registry\nprocesses and IETF 118 WG meeting discussion.\n\nIt does the following:\n* Split basic into base32 and base64 for 32-bit vs 64-bit base\n instructions\n* Split division/multiplication/modulo instructions out of base groups\n* Split atomic instructions out of base groups\n\nThere may be additional changes as discussion continues', '\nbut there seems to be consensus on the principles above.\n\nv1->v2: fixed typo pointed out by David Vernet\n\nv2->v3: Moved multiplication to same groups as division/modulo\n\nSigned-off-by: Dave Thaler \nAcked-by: David Vernet \nLink: https://lore.kernel.org/r/20240202221110.3872-1-dthaler1968@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Update the ISA specification with changes from latest mailing list discussion on conformance groups.,"ISA,specification,conformance",It's a documentation change or typo fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e7f31873176a345d72ca77c7b4da48493ccd9efd,e7f31873176a345d72ca77c7b4da48493ccd9efd,Yonghong Song,yonghong.song@linux.dev,1707110954,Andrii Nakryiko,andrii@kernel.org,1707160416,ef486ceb0fff08250fc11800b2987299daf71041,169e650069647325496e5a65408ff301874c8e01,"selftests/bpf: Fix flaky selftest lwt_redirect/lwt_reroute + +Recently", when running './test_progs -j',"[' I occasionally hit the\nfollowing errors:\n\n test_lwt_redirect:PASS:pthread_create 0 nsec\n test_lwt_redirect_run:FAIL:netns_create unexpected error: 256 (errno 0)\n #142/2 lwt_redirect/lwt_redirect_normal_nomac:FAIL\n #142 lwt_redirect:FAIL\n test_lwt_reroute:PASS:pthread_create 0 nsec\n test_lwt_reroute_run:FAIL:netns_create unexpected error: 256 (errno 0)\n test_lwt_reroute:PASS:pthread_join 0 nsec\n #143/2 lwt_reroute/lwt_reroute_qdisc_dropped:FAIL\n #143 lwt_reroute:FAIL\n\nThe netns_create() definition looks like below:\n\n #define NETNS ""ns_lwt""\n static inline int netns_create(void)\n {\n return system(""ip netns add "" NETNS);\n }\n\nOne possibility is that both lwt_redirect and lwt_reroute create\nnetns with the same name ""ns_lwt"" which may cause conflict. I tried\nthe following example:\n $ sudo ip netns add abc\n $ echo $?\n 0\n $ sudo ip netns add abc\n Cannot create namespace file ""/var/run/netns/abc"": File exists\n $ echo $?\n 1\n $\n\nThe return code for above netns_create() is 256. The internet search\nsuggests that the return value for \'ip netns add ns_lwt\' is 1', "" which\nmatches the above 'sudo ip netns add abc' example.\n\nThis patch tried to use different netns names for two tests to avoid\n'ip netns add ' failure.\n\nI ran './test_progs -j' 10 times and all succeeded with\nlwt_redirect/lwt_reroute tests.\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nTested-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20240205052914.1742687-1-yonghong.song@linux.dev\n"", '']",Fixes a flaky selftest for lwt_redirect and lwt_reroute in the BPF testing suite.,"flaky,selftest,lwt_redirect",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['socket like programs', 'tc/netfilter like programs']" +169e650069647325496e5a65408ff301874c8e01,169e650069647325496e5a65408ff301874c8e01,Kui-Feng Lee,thinker.li@gmail.com,1707027124,Martin KaFai Lau,martin.lau@kernel.org,1707159158,1ccdd32f79d639cd3cdf9b86c50debd1a864df24,7e428638bd784fd9e8944bfbf11513520e141b91,"selftests/bpf: Suppress warning message of an unused variable. + +""r"" is used to receive the return value of test_2 in bpf_testmod.c"," but it +is not actually used. So","[' we remove ""r"" and change the return type to\n""void"".\n\nReported-by: kernel test robot \nCloses: https://lore.kernel.org/oe-kbuild-all/202401300557.z5vzn8FM-lkp@intel.com/\nSigned-off-by: Kui-Feng Lee \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240204061204.1864529-1-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Suppress unused variable warning in bpf_testmod.c selftest.,"selftests,bpf,unused variable",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7e428638bd784fd9e8944bfbf11513520e141b91,7e428638bd784fd9e8944bfbf11513520e141b91,Yonghong Song,yonghong.song@linux.dev,1707075892,Andrii Nakryiko,andrii@kernel.org,1707158921,bab39b99b5cc9453ae43dbc5a06df7c60072b2a4,df9705eaa0bad034dad0f73386ff82f5c4dd7e24,"selftests/bpf: Fix flaky test ptr_untrusted + +Somehow recently I frequently hit the following test failure +with either ./test_progs or ./test_progs-cpuv4: + serial_test_ptr_untrusted:PASS:skel_open 0 nsec + serial_test_ptr_untrusted:PASS:lsm_attach 0 nsec + serial_test_ptr_untrusted:PASS:raw_tp_attach 0 nsec + serial_test_ptr_untrusted:FAIL:cmp_tp_name unexpected cmp_tp_name: actual -115 != expected 0 + #182 ptr_untrusted:FAIL + +Further investigation found the failure is due to + bpf_probe_read_user_str() +where reading user-level string attr->raw_tracepoint.name +is not successfully"," most likely due to the +string itself still in disk and not populated into memory yet. + +One solution is do a printf() call of the string before doing bpf +syscall which will force the raw_tracepoint.name into memory. +But I think a more robust solution is to use bpf_copy_from_user() +which is used in sleepable program and can tolerate page fault","['\nand the fix here used the latter approach.\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240204194452.2785936-1-yonghong.song@linux.dev\n', '']",Fixes a flaky test caused by bpf_probe_read_user_str() failure in ptr_untrusted.,"flaky,test,bpf_probe_read_user_str",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +df9705eaa0bad034dad0f73386ff82f5c4dd7e24,df9705eaa0bad034dad0f73386ff82f5c4dd7e24,Kui-Feng Lee,thinker.li@gmail.com,1706939479,Martin KaFai Lau,martin.lau@kernel.org,1707157508,524621a4914a63253486e260a7d1ed7932108f7b,2a79690eae953daaac232f93e6c5ac47ac539f2d,"bpf: Remove an unnecessary check. + +The ""i"" here is always equal to ""btf_type_vlen(t)"" since +the ""for_each_member()"" loop never breaks. + +Signed-off-by: Kui-Feng Lee +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240203055119.2235598-1-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",,Removed an unnecessary check in bpf code related to loop iteration.,"unnecessary, check, loop",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a8882313c5640103f93a07cf352f6ccf8e7defc3,a8882313c5640103f93a07cf352f6ccf8e7defc3,David S. Miller,davem@davemloft.net,1707136767,David S. Miller,davem@davemloft.net,1707136767,c9cb385d4255e5d83b7955a628fdc71a54578344,0cd216d769fbd161c06f5a702bf7a951f276f558 709776ea85625fb668ced6b97b005cf53612996e,"Merge branch 'qca8k-cleanup-fixes' + +Vladimir Oltean says: + +==================== +Fixups for qca8k ds->user_mii_bus cleanup + +The series ""ds->user_mii_bus cleanup (part 1)"" from the last development +cycle: +https://patchwork.kernel.org/project/netdevbpf/cover/20240104140037.374166-1-vladimir.oltean@nxp.com/ + +had some review comments I didn't have the time to address at the time. +One from Alvin and one from Luiz. They can reasonably be treated as +improvements for v6.9. +==================== + +Signed-off-by: David S. Miller +",,The commit merges cleanup and fix improvements for qca8k driver user MII bus implementation.,"qca8k,cleanup,fixes",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +aad98efd0b121f63a2e1c221dcb4d4850128c697,aad98efd0b121f63a2e1c221dcb4d4850128c697,Naveen N Rao,naveen@kernel.org,1706888596,Michael Ellerman,mpe@ellerman.id.au,1707133399,731c97a15b910942119143471d340ec0ae0d441a,ed8b94f6e0acd652ce69bd69d678a0c769172df8,"powerpc/64: Set task pt_regs->link to the LR value on scv entry + +Nysal reported that userspace backtraces are missing in offcputime bcc +tool. As an example: + $ sudo ./bcc/tools/offcputime.py -uU + Tracing off-CPU time (us) of user threads by user stack... Hit Ctrl-C to end. + + ^C + write + - python (9107) + 8 + + write + - sudo (9105) + 9 + + mmap + - python (9107) + 16 + + clock_nanosleep + - multipathd (697) + 3001604 + +The offcputime bcc tool attaches a bpf program to a kprobe on +finish_task_switch()"," which is usually hit on a syscall from userspace. +With the switch to system call vectored","[' we started setting\npt_regs->link to zero. This is because system call vectored behaves like\na function call with LR pointing to the system call return address', ' and\nwith no modification to SRR0/SRR1. The LR value does indicate our next\ninstruction', ' so it is being saved as pt_regs->nip', ' and pt_regs->link is\nbeing set to zero. This is not a problem by itself', ' but BPF uses perf\ncallchain infrastructure for capturing stack traces', ' and that stores LR\nas the second entry in the stack trace. perf has code to cope with the\nsecond entry being zero', ' and skips over it. However', ' generic userspace\nunwinders assume that a zero entry indicates end of the stack trace', '\nresulting in a truncated userspace stack trace.\n\nRather than fixing all userspace unwinders to ignore/skip past the\nsecond entry', ' store the real LR value in pt_regs->link so that there\ncontinues to be a valid', ' though duplicate entry in the stack trace.\n\nWith this change:\n $ sudo ./bcc/tools/offcputime.py -uU\n Tracing off-CPU time (us) of user threads by user stack... Hit Ctrl-C to end.\n\n ^C\n\twrite\n\twrite\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\tPyObject_VectorcallMethod\n\t[unknown]\n\t[unknown]\n\tPyObject_CallOneArg\n\tPyFile_WriteObject\n\tPyFile_WriteString\n\t[unknown]\n\t[unknown]\n\tPyObject_Vectorcall\n\t_PyEval_EvalFrameDefault\n\tPyEval_EvalCode\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\t_PyRun_SimpleFileObject\n\t_PyRun_AnyFileObject\n\tPy_RunMain\n\t[unknown]\n\tPy_BytesMain\n\t[unknown]\n\t__libc_start_main\n\t- python (1293)\n\t 7\n\n\twrite\n\twrite\n\t[unknown]\n\tsudo_ev_loop_v1\n\tsudo_ev_dispatch_v1\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\t__libc_start_main\n\t- sudo (1291)\n\t 7\n\n\tsyscall\n\tsyscall\n\tbpf_open_perf_buffer_opts\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\t_PyObject_MakeTpCall\n\tPyObject_Vectorcall\n\t_PyEval_EvalFrameDefault\n\tPyEval_EvalCode\n\t[unknown]\n\t[unknown]\n\t[unknown]\n\t_PyRun_SimpleFileObject\n\t_PyRun_AnyFileObject\n\tPy_RunMain\n\t[unknown]\n\tPy_BytesMain\n\t[unknown]\n\t__libc_start_main\n\t- python (1293)\n\t 11\n\n\tclock_nanosleep\n\tclock_nanosleep\n\tnanosleep\n\tsleep\n\t[unknown]\n\t[unknown]\n\t__clone\n\t- multipathd (698)\n\t 3001661\n\nFixes: 7fa95f9adaee (""powerpc/64s: system call support for scv/rfscv instructions"")\nCc: stable@vger.kernel.org\nReported-by: ""Nysal Jan K.A"" \nSigned-off-by: Naveen N Rao \nSigned-off-by: Michael Ellerman \nLink: https://msgid.link/20240202154316.395276-1-naveen@kernel.org\n\n', '']",This commit fixes the missing userspace backtraces in offcputime bcc tool by setting task pt_regs->link to the LR value on scv entry for powerpc.,"offcputime, backtraces, powerpc",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +1eb986746a67952df86eb2c50a36450ef103d01b,1eb986746a67952df86eb2c50a36450ef103d01b,Andrii Nakryiko,andrii@kernel.org,1706900729,Alexei Starovoitov,ast@kernel.org,1706926139,0e4d601040f137b0bc160f6757cff8577ae15fe4,e2e70535dd76c6f17bdc9009ffca3d26cfd35ea4,"bpf: don't emit warnings intended for global subprogs for static subprogs + +When btf_prepare_func_args() was generalized to handle both static and +global subprogs"," a few warnings/errors that are meant only for global +subprog cases started to be emitted for static subprogs","[' where they are\nsort of expected and irrelavant.\n\nStop polutting verifier logs with irrelevant scary-looking messages.\n\nFixes: e26080d0da87 (""bpf: prepare btf_prepare_func_args() for handling static subprogs"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240202190529.2374377-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit stops warnings for global subprograms from being emitted for static subprograms in bpf.,"warnings, global, subprograms",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e2e70535dd76c6f17bdc9009ffca3d26cfd35ea4,e2e70535dd76c6f17bdc9009ffca3d26cfd35ea4,Andrii Nakryiko,andrii@kernel.org,1706900728,Alexei Starovoitov,ast@kernel.org,1706926138,c62f08e9d64c498ef6d87b9d47430f4438fd9c83,8f13c34087d3eb64329529b8517e5a6251653176,"selftests/bpf: add more cases for __arg_trusted __arg_nullable args + +Add extra layer of global functions to ensure that passing around +(trusted) PTR_TO_BTF_ID_OR_NULL registers works as expected. We also +extend trusted_task_arg_nullable subtest to check three possible valid +argumements: known NULL", known non-NULL,"[' and maybe NULL cases.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240202190529.2374377-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added tests for handling __arg_trusted and __arg_nullable argument cases in BPF selftests.,"tests,selftests,arguments",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8f13c34087d3eb64329529b8517e5a6251653176,8f13c34087d3eb64329529b8517e5a6251653176,Andrii Nakryiko,andrii@kernel.org,1706900727,Alexei Starovoitov,ast@kernel.org,1706926138,a3fb464c0e39b7aeab5aa2ee9c514bda0e0af6b7,a68b50f47bec8bd6a33b07b7e1562db2553981a7,"bpf: handle trusted PTR_TO_BTF_ID_OR_NULL in argument check logic + +Add PTR_TRUSTED | PTR_MAYBE_NULL modifiers for PTR_TO_BTF_ID to +check_reg_type() to support passing trusted nullable PTR_TO_BTF_ID +registers into global functions accepting `__arg_trusted __arg_nullable` +arguments. This hasn't been caught earlier because tests were either +passing known non-NULL PTR_TO_BTF_ID registers or known NULL (SCALAR) +registers. + +When utilizing this functionality in complicated real-world BPF +application that passes around PTR_TO_BTF_ID_OR_NULL"," it became apparent +that verifier rejects valid case because check_reg_type() doesn't handle +this case explicitly. Existing check_reg_type() logic is already +anticipating this combination","[' so we just need to explicitly list this\ncombo in the switch statement.\n\nFixes: e2b3c4ff5d18 (""bpf: add __arg_trusted global func arg tag"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240202190529.2374377-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit enhances argument check logic in eBPF verifier to support trusted nullable PTR_TO_BTF_ID registers.,"PTR_TO_BTF_ID, trusted, nullable",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['kprobe/uprobe/ftrace like programs', 'tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ffd856537b95dd65facb4e0c78ca1cb92c2048ff,ffd856537b95dd65facb4e0c78ca1cb92c2048ff,Arnaldo Carvalho de Melo,acme@kernel.org,1706884340,Namhyung Kim,namhyung@kernel.org,1706925837,0df147ce149485520701e8620567753cd234b902,b8db070f389c902f48e83ee7a94952e9557199e8,"perf bpf: Clean up the generated/copied vmlinux.h + +When building perf with BPF skels we either copy the minimalistic +tools/perf/util/bpf_skel/vmlinux/vmlinux.h or use bpftool to generate a +vmlinux from BTF"," storing the result in $(SKEL_OUT)/vmlinux.h. + +We need to remove that when doing a 'make -C tools/perf clean'","[' fix it.\n\nFixes: b7a2d774c9c5a9a3 (""perf build: Add ability to build with a generated vmlinux.h"")\nReviewed-by: Ian Rogers \nCc: Andrii Nakryiko \nCc: James Clark \nCc: Tiezhu Yang \nCc: Yang Jihong \nCc: bpf@vger.kernel.org\nSigned-off-by: Arnaldo Carvalho de Melo \nSigned-off-by: Namhyung Kim \nLink: https://lore.kernel.org/r/Zbz89KK5wHfZ82jv@x1\n', '']",This commit cleans up the generated/copied vmlinux.h file when cleaning the perf build directory.,"perf,BPF,vmlinux.h",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a68b50f47bec8bd6a33b07b7e1562db2553981a7,a68b50f47bec8bd6a33b07b7e1562db2553981a7,Shung-Hsi Yu,shung-hsi.yu@suse.com,1706867758,Martin KaFai Lau,martin.lau@kernel.org,1706912043,319c590302cf34ab5eae788a6b59f698fe848f09,6fb3f72702fba97323a89e53f484de58bc59d13c,"selftests/bpf: trace_helpers.c: do not use poisoned type + +After commit c698eaebdf47 (""selftests/bpf: trace_helpers.c: Optimize +kallsyms cache"") trace_helpers.c now includes libbpf_internal.h"," and +thus can no longer use the u32 type (among others) since they are poison +in libbpf_internal.h. Replace u32 with __u32 to fix the following error +when building trace_helpers.c on powerpc: + + error: attempt to use poisoned ""u32"" + +Fixes: c698eaebdf47 (""selftests/bpf: trace_helpers.c: Optimize kallsyms cache"") +Signed-off-by: Shung-Hsi Yu +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/r/20240202095559.12900-1-shung-hsi.yu@suse.com +Signed-off-by: Martin KaFai Lau +",[''],Replace poisoned u32 type with __u32 in trace_helpers.c to fix build error.,"poisoned,u32,trace_helpers",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6fb3f72702fba97323a89e53f484de58bc59d13c,6fb3f72702fba97323a89e53f484de58bc59d13c,Andrii Nakryiko,andrii@kernel.org,1706908935,Andrii Nakryiko,andrii@kernel.org,1706908935,3fc8bcaba15ec02e57e63eb576acba505394dd84,943b043aeecce9accb6d367af47791c633e95e4d 73a28d9d000e8d20b4b3c516b74ee92afe3ae4be,"Merge branch 'improvements-for-tracking-scalars-in-the-bpf-verifier' + +Maxim Mikityanskiy says: + +==================== +Improvements for tracking scalars in the BPF verifier + +From: Maxim Mikityanskiy + +The goal of this series is to extend the verifier's capabilities of +tracking scalars when they are spilled to stack"," especially when the +spill or fill is narrowing. It also contains a fix by Eduard for +infinite loop detection and a state pruning optimization by Eduard that +compensates for a verification complexity regression introduced by +tracking unbounded scalars. These improvements reduce the surface of +false rejections that I saw while working on Cilium codebase. + +Patches 1-9 of the original series were previously applied in v2. + +Patches 1-2 (Maxim): Support the case when boundary checks are first +performed after the register was spilled to the stack. + +Patches 3-4 (Maxim): Support narrowing fills. + +Patches 5-6 (Eduard): Optimization for state pruning in stacksafe() to +mitigate the verification complexity regression. + +veristat -e file","['prog', ""states -f '!states_diff<50' -f '!states_pct<10' -f '!states_a<10' -f '!states_b<10' -C ...\n\n * Without patch 5:\n\nFile Program States (A) States (B) States (DIFF)\n-------------------- -------- ---------- ---------- ----------------\npyperf100.bpf.o on_event 4878 6528 +1650 (+33.83%)\npyperf180.bpf.o on_event 6936 11032 +4096 (+59.05%)\npyperf600.bpf.o on_event 22271 39455 +17184 (+77.16%)\npyperf600_iter.bpf.o on_event 400 490 +90 (+22.50%)\nstrobemeta.bpf.o on_event 4895 14028 +9133 (+186.58%)\n\n * With patch 5:\n\nFile Program States (A) States (B) States (DIFF)\n----------------------- ------------- ---------- ---------- ---------------\nbpf_xdp.o tail_lb_ipv4 2770 2224 -546 (-19.71%)\npyperf100.bpf.o on_event 4878 5848 +970 (+19.89%)\npyperf180.bpf.o on_event 6936 8868 +1932 (+27.85%)\npyperf600.bpf.o on_event 22271 29656 +7385 (+33.16%)\npyperf600_iter.bpf.o on_event 400 450 +50 (+12.50%)\nxdp_synproxy_kern.bpf.o syncookie_tc 280 226 -54 (-19.29%)\nxdp_synproxy_kern.bpf.o syncookie_xdp 302 228 -74 (-24.50%)\n\nv2 changes:\n\nFixed comments in patch 1"", ' moved endianness checks to header files in\npatch 12 where possible', "" added Eduard's ACKs.\n\nv3 changes:\n\nMaxim: Removed __is_scalar_unbounded altogether"", "" addressed Andrii's\ncomments.\n\nEduard: Patch #5 (#14 in v2) changed significantly:\n- Logical changes:\n - Handling of STACK_{MISC"", 'ZERO} mix turned out to be incorrect:\n a mix of MISC and ZERO in old state is not equivalent to e.g.\n just MISC is current state', ' because verifier could have deduced\n zero scalars from ZERO slots in old state for some loads.\n - There is no reason to limit the change only to cases when\n old or current stack is a spill of unbounded scalar', '\n it is valid to compare any 64-bit scalar spill with fake\n register impersonating MISC.\n - STACK_ZERO vs spilled zero case was dropped', '\n after recent changes for zero handling by Andrii and Yonghong\n it is hard (impossible?) to conjure all ZERO slots for an spi.\n => the case does not make any difference in veristat results.\n- Use global static variable for unbound_reg (Andrii)\n- Code shuffling to remove duplication in stacksafe() (Andrii)\n====================\n\nLink: https://lore.kernel.org/r/20240127175237.526726-1-maxtram95@gmail.com\nSigned-off-by: Andrii Nakryiko \n', '']","The commit improves scalar tracking in the BPF verifier, including state pruning optimization for verification complexity regression.","scalar tracking, BPF verifier, optimization",It's a cleanup or refactoring in the code.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +73a28d9d000e8d20b4b3c516b74ee92afe3ae4be,73a28d9d000e8d20b4b3c516b74ee92afe3ae4be,Eduard Zingerman,eddyz87@gmail.com,1706377957,Andrii Nakryiko,andrii@kernel.org,1706908934,3fc8bcaba15ec02e57e63eb576acba505394dd84,6efbde200bf3cf2dbf6e7181893fed13a79c789b,"selftests/bpf: States pruning checks for scalar vs STACK_MISC + +Check that stacksafe() compares spilled scalars with STACK_MISC. +The following combinations are explored: +- old spill of imprecise scalar is equivalent to cur STACK_{MISC","INVALID} + (plus error in unpriv mode); +- old spill of precise scalar is not equivalent to cur STACK_MISC; +- old STACK_MISC is equivalent to cur scalar; +- old STACK_MISC is not equivalent to cur non-scalar. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240127175237.526726-7-maxtram95@gmail.com +",[''],Add selftests for checking stack safety with scalar and STACK_MISC comparisons in eBPF.,"selftests,stack,scalar",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6efbde200bf3cf2dbf6e7181893fed13a79c789b,6efbde200bf3cf2dbf6e7181893fed13a79c789b,Eduard Zingerman,eddyz87@gmail.com,1706377956,Andrii Nakryiko,andrii@kernel.org,1706908934,0b91ca2602847f5df1035b1b80bf01ab8872bb3c,067313a85c6f213932518f12f628810f0092492b,"bpf: Handle scalar spill vs all MISC in stacksafe() + +When check_stack_read_fixed_off() reads value from an spi +all stack slots of which are set to STACK_{MISC",INVALID},"[""\nthe destination register is set to unbound SCALAR_VALUE.\n\nExploit this fact by allowing stacksafe() to use a fake\nunbound scalar register to compare 'mmmm mmmm' stack value\nin old state vs spilled 64-bit scalar in current state\nand vice versa.\n\nVeristat results after this patch show some gains:\n\n./veristat -C -e file"", 'prog', ""states -f 'states_pct>10' not-opt after\nFile Program States (DIFF)\n----------------------- --------------------- ---------------\nbpf_overlay.o tail_rev_nodeport_lb4 -45 (-15.85%)\nbpf_xdp.o tail_lb_ipv4 -541 (-19.57%)\npyperf100.bpf.o on_event -680 (-10.42%)\npyperf180.bpf.o on_event -2164 (-19.62%)\npyperf600.bpf.o on_event -9799 (-24.84%)\nstrobemeta.bpf.o on_event -9157 (-65.28%)\nxdp_synproxy_kern.bpf.o syncookie_tc -54 (-19.29%)\nxdp_synproxy_kern.bpf.o syncookie_xdp -74 (-24.50%)\n\nSigned-off-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240127175237.526726-6-maxtram95@gmail.com\n"", '']",Fixes handling of scalar spills vs all MISC states in stacksafe checks in eBPF.,"scalar,spill,stacksafe",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +067313a85c6f213932518f12f628810f0092492b,067313a85c6f213932518f12f628810f0092492b,Maxim Mikityanskiy,maxim@isovalent.com,1706377955,Andrii Nakryiko,andrii@kernel.org,1706908934,fb3a4026aa0f46104a8a929e1711f6ef262df857,c1e6148cb4f83cec841db1f066e8db4a86c1f118,"selftests/bpf: Add test cases for narrowing fill + +The previous commit allowed to preserve boundaries and track IDs of +scalars on narrowing fills. Add test cases for that pattern. + +Signed-off-by: Maxim Mikityanskiy +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20240127175237.526726-5-maxtram95@gmail.com +",,Add test cases for handling narrowing fill patterns in eBPF selftests.,"test cases,narrowing fill,selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c1e6148cb4f83cec841db1f066e8db4a86c1f118,c1e6148cb4f83cec841db1f066e8db4a86c1f118,Maxim Mikityanskiy,maxim@isovalent.com,1706377954,Andrii Nakryiko,andrii@kernel.org,1706908934,d27fac029e258f1f529907e0c05ab9ce458ee021,6be503cec6c9bccd64f72c03697011d2e2b96fc3,"bpf: Preserve boundaries and track scalars on narrowing fill + +When the width of a fill is smaller than the width of the preceding +spill", the information about scalar boundaries can still be preserved,"[""\nas long as it's coerced to the right width (done by coerce_reg_to_size).\nEven further"", ' if the actual value fits into the fill width', ' the ID can\nbe preserved as well for further tracking of equal scalars.\n\nImplement the above improvements', "" which makes narrowing fills behave the\nsame as narrowing spills and MOVs between registers.\n\nTwo tests are adjusted to accommodate for endianness differences and to\ntake into account that it's now allowed to do a narrowing fill from the\nleast significant bits.\n\nreg_bounds_sync is added to coerce_reg_to_size to correctly adjust\numin/umax boundaries after the var_off truncation"", ' for example', ' a 64-bit\nvalue 0xXXXXXXXX00000000', ' when read as a 32-bit', ' gets umin = 0', ' umax =\n0xFFFFFFFF', ' var_off = (0x0; 0xffffffff00000000)', ' which needs to be\nsynced down to umax = 0', "" otherwise reg_bounds_sanity_check doesn't pass.\n\nSigned-off-by: Maxim Mikityanskiy \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240127175237.526726-4-maxtram95@gmail.com\n"", '']",This commit preserves boundaries and tracks scalars when narrowing fills in eBPF programs.,"preserve, boundaries, scalars",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6be503cec6c9bccd64f72c03697011d2e2b96fc3,6be503cec6c9bccd64f72c03697011d2e2b96fc3,Maxim Mikityanskiy,maxim@isovalent.com,1706377953,Andrii Nakryiko,andrii@kernel.org,1706908934,26368b72f39c3d9bc5236197f86cad5feb243f61,e67ddd9b1cff7872d43ead73a1403c4e532003d9,"selftests/bpf: Test tracking spilled unbounded scalars + +The previous commit added tracking for unbounded scalars on spill. Add +the test case to check the new functionality. + +Signed-off-by: Maxim Mikityanskiy +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20240127175237.526726-3-maxtram95@gmail.com +",,Add a test case to validate the functionality of tracking spilled unbounded scalars in selftests for BPF.,"test, unbounded scalars, selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e67ddd9b1cff7872d43ead73a1403c4e532003d9,e67ddd9b1cff7872d43ead73a1403c4e532003d9,Maxim Mikityanskiy,maxim@isovalent.com,1706377952,Andrii Nakryiko,andrii@kernel.org,1706908934,41bab4348d2c9d1a9a07548d2bbb3e44c6dcd444,943b043aeecce9accb6d367af47791c633e95e4d,"bpf: Track spilled unbounded scalars + +Support the pattern where an unbounded scalar is spilled to the stack"," +then boundary checks are performed on the src register","[' after which the\nstack frame slot is refilled into a register.\n\nBefore this commit', "" the verifier didn't treat the src register and the\nstack slot as related if the src register was an unbounded scalar. The\nregister state wasn't copied"", "" the id wasn't preserved"", "" and the stack\nslot was marked as STACK_MISC. Subsequent boundary checks on the src\nregister wouldn't result in updating the boundaries of the spilled\nvariable on the stack.\n\nAfter this commit"", ' the verifier will preserve the bond between src and\ndst even if src is unbounded', ' which permits to do boundary checks on src\nand refill dst later', ' still remembering its boundaries. Such a pattern\nis sometimes generated by clang when compiling complex long functions.\n\nOne test is adjusted to reflect that now unbounded scalars are tracked.\n\nSigned-off-by: Maxim Mikityanskiy \nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20240127175237.526726-2-maxtram95@gmail.com\n', '']",The commit tracks spilled unbounded scalars to improve boundary checks for src registers in BPF programs.,"spilled, scalars, unbounded",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +943b043aeecce9accb6d367af47791c633e95e4d,943b043aeecce9accb6d367af47791c633e95e4d,Andrii Nakryiko,andrii@kernel.org,1706808027,Daniel Borkmann,daniel@iogearbox.net,1706822172,97a7fbc05a135c421de0685dceeb38ee74693da4,b9551da8cf3ade01a50316df8a618fd945723ee0,"selftests/bpf: Fix bench runner SIGSEGV + +Some benchmarks don't have either ""consumer"" or ""producer"" sides. For +example"," trig-tp and other BPF triggering benchmarks don't have +consumers","[' as they only do ""producing"" by calling into syscall or\npredefined uproes. As such it\'s valid for some benchmarks to have zero\nconsumers or producers. So allows to specify `-c0` explicitly.\n\nThis triggers another problem. If benchmark doesn\'t support either\nconsumer or producer side', ' consumer_thread/producer_thread callback will\nbe NULL', ' but benchmark runner will attempt to use those NULL callback to\ncreate threads anyways. So instead of crashing with SIGSEGV in case of\nmisconfigured benchmark', ' detect the condition and report error.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20240201172027.604869-6-andrii@kernel.org\n', '']",Fixes a segmentation fault in the selftests benchmark runner due to missing consumer or producer sides.,"selftests, benchmark, SIGSEGV",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tracepoints like programs'] +b9551da8cf3ade01a50316df8a618fd945723ee0,b9551da8cf3ade01a50316df8a618fd945723ee0,Andrii Nakryiko,andrii@kernel.org,1706808026,Daniel Borkmann,daniel@iogearbox.net,1706822172,697abd705136a3f892e83bbe4f4d9041c774150c,c81a8ab196b5083d5109a51585fcc24fa2055a77,"libbpf: Add missed btf_ext__raw_data() API + +Another API that was declared in libbpf.map but actual implementation +was missing. btf_ext__get_raw_data() was intended as a discouraged alias +to consistently-named btf_ext__raw_data()"," so make this an actuality. + +Fixes: 20eccf29e297 (""libbpf: hide and discourage inconsistently named getters"") +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20240201172027.604869-5-andrii@kernel.org +",[''],Add implementation of missing btf_ext__raw_data() API in libbpf.,"libbpf, API, implementation",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c81a8ab196b5083d5109a51585fcc24fa2055a77,c81a8ab196b5083d5109a51585fcc24fa2055a77,Andrii Nakryiko,andrii@kernel.org,1706808025,Daniel Borkmann,daniel@iogearbox.net,1706822172,79b7a7266067dcdca3d01e7d949050951533d069,93ee1eb85e28d1e35bb059c1f5965d65d5fc83c2,"libbpf: Add btf__new_split() API that was declared but not implemented + +Seems like original commit adding split BTF support intended to add +btf__new_split() API", and even declared it in libbpf.map,"[' but never\nadded (trivial) implementation. Fix this.\n\nFixes: ba451366bf44 (""libbpf: Implement basic split BTF support"")\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20240201172027.604869-4-andrii@kernel.org\n', '']",The commit implements the previously declared but unimplemented btf__new_split() API in libbpf.,libbpf BTF API,It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +93ee1eb85e28d1e35bb059c1f5965d65d5fc83c2,93ee1eb85e28d1e35bb059c1f5965d65d5fc83c2,Andrii Nakryiko,andrii@kernel.org,1706808024,Daniel Borkmann,daniel@iogearbox.net,1706822171,42db78e843ce7af0251e565fd25d91004d7b49e3,9fa5e1a180aa639fb156a16e453ab820b7e7860b,"libbpf: Add missing LIBBPF_API annotation to libbpf_set_memlock_rlim API + +LIBBPF_API annotation seems missing on libbpf_set_memlock_rlim API"," so +add it to make this API callable from libbpf's shared library version. + +Fixes: e542f2c4cd16 (""libbpf: Auto-bump RLIMIT_MEMLOCK if kernel needs it for BPF"") +Fixes: ab9a5a05dc48 (""libbpf: fix up few libbpf.map problems"") +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20240201172027.604869-3-andrii@kernel.org +",[''],Add missing LIBBPF_API annotation to libbpf_set_memlock_rlim for shared library usage.,"LIBBPF_API, libbpf, memlock",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9fa5e1a180aa639fb156a16e453ab820b7e7860b,9fa5e1a180aa639fb156a16e453ab820b7e7860b,Andrii Nakryiko,andrii@kernel.org,1706808023,Daniel Borkmann,daniel@iogearbox.net,1706822171,31cb7e6da88097ca1880c6a8776ee4e56b4e469b,1581e5118e485e82cfb5d04d636a79aaefb6f266,"libbpf: Call memfd_create() syscall directly + +Some versions of Android do not implement memfd_create() wrapper in +their libc implementation"," leading to build failures ([0]). On the other +hand","[' memfd_create() is available as a syscall on quite old kernels\n(3.17+', ' while bpf() syscall itself is available since 3.18+)', "" so it is\nok to assume that syscall availability and call into it with syscall()\nhelper to avoid Android-specific workarounds.\n\nValidated in libbpf-bootstrap's CI ([1]).\n\n [0] https://github.com/libbpf/libbpf-bootstrap/actions/runs/7701003207/job/20986080319#step:5:83\n [1] https://github.com/libbpf/libbpf-bootstrap/actions/runs/7715988887/job/21031767212?pr=253\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20240201172027.604869-2-andrii@kernel.org\n"", '']",This commit modifies libbpf to call the memfd_create syscall directly to avoid build issues on some Android platforms.,"libbpf, memfd_create, Android",It's a build system or CI/CD change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"[""It's not related to any of the above.""]" +5c24e4e9e70822cf49955fc8174bc5efaa93d17f,5c24e4e9e70822cf49955fc8174bc5efaa93d17f,Linus Torvalds,torvalds@linux-foundation.org,1706811574,Linus Torvalds,torvalds@linux-foundation.org,1706811574,a793614a9f5bde6302d84c932d36887d530ad14b,f6cdd897cc7030a573f56ab1e9ebaece26c7c10c 764ad6b02777d77dca3659ca490f0898aa593670,"Merge tag 'hid-for-linus-2024020101' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid + +Pull HID fixes from Benjamin Tissoires: + + - cleanups in the error path in hid-steam (Dan Carpenter) + + - fixes for Wacom tablets selftests that sneaked in while the CI was + taking a break during the year end holidays (Benjamin Tissoires) + + - null pointer check in nvidia-shield (Kunwu Chan) + + - memory leak fix in hidraw (Su Hui) + + - another null pointer fix in i2c-hid-of (Johan Hovold) + + - another memory leak fix in HID-BPF this time"," as well as a double + fdget() fix reported by Dan Carpenter (Benjamin Tissoires) + + - fix for Cirque touchpad when they go on suspend (Kai-Heng Feng) + + - new device ID in hid-logitech-hidpp: ""Logitech G Pro X SuperLight 2"" + (Jiri Kosina) + +* tag 'hid-for-linus-2024020101' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid: + HID: bpf: use __bpf_kfunc instead of noinline + HID: bpf: actually free hdev memory after attaching a HID-BPF program + HID: bpf: remove double fdget() + HID: i2c-hid-of: fix NULL-deref on failed power up + HID: hidraw: fix a problem of memory leak in hidraw_release() + HID: i2c-hid: Skip SET_POWER SLEEP for Cirque touchpad on system suspend + HID: nvidia-shield: Add missing null pointer checks to LED initialization + HID: logitech-hidpp: add support for Logitech G Pro X Superlight 2 + selftests/hid: wacom: fix confidence tests + HID: hid-steam: Fix cleanup in probe() + HID: hid-steam: remove pointless error message +",[''],This commit merges HID fixes including memory leak and null pointer checks for various devices.,"HID, fixes, memory",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['HID driver like programs'] +1581e5118e485e82cfb5d04d636a79aaefb6f266,1581e5118e485e82cfb5d04d636a79aaefb6f266,Matt Bobrowski,mattbobrowski@google.com,1706784220,Daniel Borkmann,daniel@iogearbox.net,1706809065,977ae9fe3c50e0a68463195acf4b0835c7a15419,994ff2f7973982af286608da10c295383650fc28,"bpf: Minor clean-up to sleepable_lsm_hooks BTF set + +There's already one main CONFIG_SECURITY_NETWORK ifdef block within +the sleepable_lsm_hooks BTF set. Consolidate this duplicated ifdef +block as there's no need for it and all things guarded by it should +remain in one place in this specific context. + +Signed-off-by: Matt Bobrowski +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/Zbt1smz43GDMbVU3@google.com +",,Consolidate duplicated ifdef blocks in sleepable_lsm_hooks BTF set for cleaner code structure.,"clean-up, ifdef, BTF",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),['LSM like programs'] +e0526ec5360a48ad3ab2e26e802b0532302a7e11,e0526ec5360a48ad3ab2e26e802b0532302a7e11,Souradeep Chakrabarti,schakrabarti@linux.microsoft.com,1706686551,Jakub Kicinski,kuba@kernel.org,1706805223,0e9d7ebabe6893cdaad90907275584cbf84cc83c,7b55984c96ffe9e236eb9c82a2196e0b1f84990d,"hv_netvsc: Fix race condition between netvsc_probe and netvsc_remove + +In commit ac5047671758 (""hv_netvsc: Disable NAPI before closing the +VMBus channel"")", napi_disable was getting called for all channels,"['\nincluding all subchannels without confirming if they are enabled or not.\n\nThis caused hv_netvsc getting hung at napi_disable', ' when netvsc_probe()\nhas finished running but nvdev->subchan_work has not started yet.\nnetvsc_subchan_work() -> rndis_set_subchannel() has not created the\nsub-channels and because of that netvsc_sc_open() is not running.\nnetvsc_remove() calls cancel_work_sync(&nvdev->subchan_work)', ' for which\nnetvsc_subchan_work did not run.\n\nnetif_napi_add() sets the bit NAPI_STATE_SCHED because it ensures NAPI\ncannot be scheduled. Then netvsc_sc_open() -> napi_enable will clear the\nNAPIF_STATE_SCHED bit', ' so it can be scheduled. napi_disable() does the\nopposite.\n\nNow during netvsc_device_remove()', ' when napi_disable is called for those\nsubchannels', ' napi_disable gets stuck on infinite msleep.\n\nThis fix addresses this problem by ensuring that napi_disable() is not\ngetting called for non-enabled NAPI struct.\nBut netif_napi_del() is still necessary for these non-enabled NAPI struct\nfor cleanup purpose.\n\nCall trace:\n[ 654.559417] task:modprobe state:D stack: 0 pid: 2321 ppid: 1091 flags:0x00004002\n[ 654.568030] Call Trace:\n[ 654.571221] \n[ 654.573790] __schedule+0x2d6/0x960\n[ 654.577733] schedule+0x69/0xf0\n[ 654.581214] schedule_timeout+0x87/0x140\n[ 654.585463] ? __bpf_trace_tick_stop+0x20/0x20\n[ 654.590291] msleep+0x2d/0x40\n[ 654.593625] napi_disable+0x2b/0x80\n[ 654.597437] netvsc_device_remove+0x8a/0x1f0 [hv_netvsc]\n[ 654.603935] rndis_filter_device_remove+0x194/0x1c0 [hv_netvsc]\n[ 654.611101] ? do_wait_intr+0xb0/0xb0\n[ 654.615753] netvsc_remove+0x7c/0x120 [hv_netvsc]\n[ 654.621675] vmbus_remove+0x27/0x40 [hv_vmbus]\n\nCc: stable@vger.kernel.org\nFixes: ac5047671758 (""hv_netvsc: Disable NAPI before closing the VMBus channel"")\nSigned-off-by: Souradeep Chakrabarti \nReviewed-by: Dexuan Cui \nReviewed-by: Haiyang Zhang \nReviewed-by: Simon Horman \nLink: https://lore.kernel.org/r/1706686551-28510-1-git-send-email-schakrabarti@linux.microsoft.com\nSigned-off-by: Jakub Kicinski \n', '']",Fixes a race condition between netvsc_probe and netvsc_remove in hv_netvsc driver.,"hv_netvsc,race condition,probe",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +6a9d552483d50953320b9d3b57abdee8d436f23f,6a9d552483d50953320b9d3b57abdee8d436f23f,Sean Young,sean@mess.org,1681375832,Mauro Carvalho Chehab,mchehab@kernel.org,1706791737,fae8ab584d5b37806ceccaef3b6205dd53fcfb9b,f66556c1333b3bd4806fc98ee07c419ab545e6ee,"media: rc: bpf attach/detach requires write permission + +Note that bpf attach/detach also requires CAP_NET_ADMIN. + +Cc: stable@vger.kernel.org +Signed-off-by: Sean Young +Signed-off-by: Mauro Carvalho Chehab +",,The commit requires write permission for bpf attach/detach operations in media rc subsystem.,"bpf,attach,permission",It's a security fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['other'] +994ff2f7973982af286608da10c295383650fc28,994ff2f7973982af286608da10c295383650fc28,Pu Lehui,pulehui@huawei.com,1706618819,Daniel Borkmann,daniel@iogearbox.net,1706783748,71e4c406e87719866e5e9e1163654267fd28feaa,69065aa11ca680d76a6c6bc088aa0f0abe24afdb,"selftests/bpf: Enable inline bpf_kptr_xchg() test for RV64 + +Enable inline bpf_kptr_xchg() test for RV64"," and the test have passed as +show below: + +Summary: 1/0 PASSED","[' 0 SKIPPED', ' 0 FAILED\n\nSigned-off-by: Pu Lehui \nSigned-off-by: Daniel Borkmann \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240130124659.670321-3-pulehui@huaweicloud.com\n', '']",Enable inline bpf_kptr_xchg() test for RV64 architecture in selftests.,bpf_kptr_xchg RV64 selftests,It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +69065aa11ca680d76a6c6bc088aa0f0abe24afdb,69065aa11ca680d76a6c6bc088aa0f0abe24afdb,Pu Lehui,pulehui@huawei.com,1706618818,Daniel Borkmann,daniel@iogearbox.net,1706783748,0228b8ec5043cee4077500406119b3c0aa777d7a,088a464ed53feeab9632c6748b9f25354639e2bd,riscv," bpf: Enable inline bpf_kptr_xchg() for RV64 + +RV64 JIT supports 64-bit BPF_XCHG atomic instructions. At the same time","[""\nthe underlying implementation of xchg() and atomic64_xchg() in RV64 both\nare raw_xchg() that supported 64-bit. Therefore inline bpf_kptr_xchg()\nwill have equivalent semantics. Let's inline it for better performance.\n\nSigned-off-by: Pu Lehui \nSigned-off-by: Daniel Borkmann \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240130124659.670321-2-pulehui@huaweicloud.com\n"", '']",Enable inline bpf_kptr_xchg() support for RV64 JIT with 64-bit atomic instructions.,"RV64,JIT,BPF_XCHG",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +088a464ed53feeab9632c6748b9f25354639e2bd,088a464ed53feeab9632c6748b9f25354639e2bd,Dave Thaler,dthaler1968@googlemail.com,1706672279,Daniel Borkmann,daniel@iogearbox.net,1706783533,a2956e5c82064fc3d1a2c0f1be58490c27d0c0db,8263b3382d8c1af0fffa27095a9f1db6f2dad899,bpf," docs: Clarify which legacy packet instructions existed + +As discussed on the BPF IETF mailing list (see link)","[' this patch updates\nthe ""Legacy BPF Packet access instructions"" section to clarify which\ninstructions are deprecated (vs which were never defined and so are not\ndeprecated).\n\nSigned-off-by: Dave Thaler \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nAcked-by: David Vernet \nLink: https://mailarchive.ietf.org/arch/msg/bpf/5LnnKm093cGpOmDI9TnLQLBXyys\nLink: https://lore.kernel.org/bpf/20240131033759.3634-1-dthaler1968@gmail.com\n', '']",The commit clarifies documentation regarding legacy packet instructions discussed on the BPF IETF mailing list.,"docs, packet, instructions",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"[""It's not related to any of the above.""]" +8263b3382d8c1af0fffa27095a9f1db6f2dad899,8263b3382d8c1af0fffa27095a9f1db6f2dad899,Eduard Zingerman,eddyz87@gmail.com,1706736375,Daniel Borkmann,daniel@iogearbox.net,1706782425,aaf52c8edacd92fe52eea3edc723ebc760ecc6ee,b3d3e29376a3f898bc90063a1e8c36c76cea1901,"libbpf: Remove unnecessary null check in kernel_supports() + +After recent changes"," Coverity complained about inconsistent null checks +in kernel_supports() function: + + kernel_supports(const struct bpf_object *obj","[' ...)\n [...]\n // var_compare_op: Comparing obj to null implies that obj might be null\n if (obj && obj->gen_loader)\n return true;\n\n // var_deref_op: Dereferencing null pointer obj\n if (obj->token_fd)\n return feat_supported(obj->feat_cache', ' feat_id);\n [...]\n\n- The original null check was introduced by commit [0]', ' which introduced\n a call `kernel_supports(NULL', ' ...)` in function bump_rlimit_memlock();\n- This call was refactored to use `feat_supported(NULL', ' ...)` in commit [1].\n\nLooking at all places where kernel_supports() is called:\n\n- There is either `obj->...` access before the call;\n- Or `obj` comes from `prog->obj` expression', ' where `prog` comes from\n enumeration of programs in `obj`;\n- Or `obj` comes from `prog->obj`', ' where `prog` is a parameter to one\n of the API functions:\n - bpf_program__attach_kprobe_opts;\n - bpf_program__attach_kprobe;\n - bpf_program__attach_ksyscall.\n\nAssuming correct API usage', ' it appears that `obj` can never be null when\npassed to kernel_supports(). Silence the Coverity warning by removing\nredundant null check.\n\n [0] e542f2c4cd16 (""libbpf: Auto-bump RLIMIT_MEMLOCK if kernel needs it for BPF"")\n [1] d6dd1d49367a (""libbpf: Further decouple feature checking logic from bpf_object"")\n\nSigned-off-by: Eduard Zingerman \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240131212615.20112-1-eddyz87@gmail.com\n', '']",This commit removes an unnecessary null check in the kernel_supports() function in libbpf.,"null check, libbpf, kernel_supports",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b3d3e29376a3f898bc90063a1e8c36c76cea1901,b3d3e29376a3f898bc90063a1e8c36c76cea1901,Alexei Starovoitov,ast@kernel.org,1706731524,Alexei Starovoitov,ast@kernel.org,1706762456,fd932c0339367596adb67fd652849506971fda3f,2ef61296d2844c6a4211e07ab70ef2fb412b2c30 6f3189f38a3e995232e028a4c341164c4aca1b20,"Merge branch 'annotate-kfuncs-in-btf_ids-section' + +Daniel Xu says: + +==================== +Annotate kfuncs in .BTF_ids section + +=== Description === + +This is a bpf-treewide change that annotates all kfuncs as such inside +.BTF_ids. This annotation eventually allows us to automatically generate +kfunc prototypes from bpftool. + +We store this metadata inside a yet-unused flags field inside struct +btf_id_set8 (thanks Kumar!). pahole will be taught where to look. + +More details about the full chain of events are available in commit 3's +description. + +The accompanying pahole and bpftool changes can be viewed +here on these ""frozen"" branches [0][1]. + +[0]: https://github.com/danobi/pahole/tree/kfunc_btf-v3-mailed +[1]: https://github.com/danobi/linux/tree/kfunc_bpftool-mailed + +=== Changelog === + +Changes from v3: +* Rebase to bpf-next and add missing annotation on new kfunc + +Changes from v2: +* Only WARN() for vmlinux kfuncs + +Changes from v1: +* Move WARN_ON() up a call level +* Also return error when kfunc set is not properly tagged +* Use BTF_KFUNCS_START/END instead of flags +* Rename BTF_SET8_KFUNC to BTF_SET8_KFUNCS +==================== + +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/r/cover.1706491398.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",,This commit annotates kfuncs in the .BTF_ids section for automatic kfunc prototype generation with bpftool.,"kfuncs,BTF_ids,bpftool",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6f3189f38a3e995232e028a4c341164c4aca1b20,6f3189f38a3e995232e028a4c341164c4aca1b20,Daniel Xu,dxu@dxuuu.xyz,1706491448,Alexei Starovoitov,ast@kernel.org,1706762456,fd932c0339367596adb67fd652849506971fda3f,a05e90427ef6706f59188b379ad6366b9d298bc5,"bpf: treewide: Annotate BPF kfuncs in BTF + +This commit marks kfuncs as such inside the .BTF_ids section. The upshot +of these annotations is that we'll be able to automatically generate +kfunc prototypes for downstream users. The process is as follows: + +1. In source"," use BTF_KFUNCS_START/END macro pair to mark kfuncs +2. During build","[' pahole injects into BTF a ""bpf_kfunc"" BTF_DECL_TAG for\n each function inside BTF_KFUNCS sets\n3. At runtime', ' vmlinux or module BTF is made available in sysfs\n4. At runtime', ' bpftool (or similar) can look at provided BTF and\n generate appropriate prototypes for functions with ""bpf_kfunc"" tag\n\nTo ensure future kfunc are similarly tagged', ' we now also return error\ninside kfunc registration for untagged kfuncs. For vmlinux kfuncs', '\nwe also WARN()', ' as initcall machinery does not handle errors.\n\nSigned-off-by: Daniel Xu \nAcked-by: Benjamin Tissoires \nLink: https://lore.kernel.org/r/e55150ceecbf0a5d961e608941165c0bee7bc943.1706491398.git.dxu@dxuuu.xyz\nSigned-off-by: Alexei Starovoitov \n', '']",Annotate BPF kfuncs in BTF to enable automatic kfunc prototype generation for downstream users.,"kfuncs,BTF,annotations",It's a documentation change or typo fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a05e90427ef6706f59188b379ad6366b9d298bc5,a05e90427ef6706f59188b379ad6366b9d298bc5,Daniel Xu,dxu@dxuuu.xyz,1706491447,Alexei Starovoitov,ast@kernel.org,1706762452,5bafea12fa3f4e5bdf0d08a0db79cf73fc0c9de5,79b47344bbc5a693a92ed6b2b09dac59254bfac8,"bpf: btf: Add BTF_KFUNCS_START/END macro pair + +This macro pair is functionally equivalent to BTF_SET8_START/END"," except +with BTF_SET8_KFUNCS flag set in the btf_id_set8 flags field. The next +commit will codemod all kfunc set8s to this new variant such that all +kfuncs are tagged as such in .BTF_ids section. + +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/d536c57c7c2af428686853cc7396b7a44faa53b7.1706491398.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",[''],Add BTF_KFUNCS_START/END macro pair for improved kfunc tagging in BTF_ids section.,"BTF,KFUNCS,macro",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +79b47344bbc5a693a92ed6b2b09dac59254bfac8,79b47344bbc5a693a92ed6b2b09dac59254bfac8,Daniel Xu,dxu@dxuuu.xyz,1706491446,Alexei Starovoitov,ast@kernel.org,1706731524,e4c178e4c0ba6bed66b699a815c7289301b21b37,2ef61296d2844c6a4211e07ab70ef2fb412b2c30,"bpf: btf: Support flags for BTF_SET8 sets + +This commit adds support for flags on BTF_SET8s. struct btf_id_set8 +already supported 32 bits worth of flags"," but was only used for +alignment purposes before. + +We now use these bits to encode flags. The first use case is tagging +kfunc sets with a flag so that pahole can recognize which +BTF_ID_FLAGS(func","[' ..) are actual kfuncs.\n\nSigned-off-by: Daniel Xu \nLink: https://lore.kernel.org/r/7bb152ec76d6c2c930daec88e995bf18484a5ebb.1706491398.git.dxu@dxuuu.xyz\nSigned-off-by: Alexei Starovoitov \n', '']","Adds support for flags in BTF_SET8 structures, enabling flag tagging for kfunc sets.","BTF_SET8, flags, kfunc",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2ef61296d2844c6a4211e07ab70ef2fb412b2c30,2ef61296d2844c6a4211e07ab70ef2fb412b2c30,Manu Bretelle,chantr4@gmail.com,1706679132,Andrii Nakryiko,andrii@kernel.org,1706721243,2f93f0305f24453b2d94f48f3e6100207723818a,e4009250574c69d2a3dd838af81cc3d4d72058e4,"selftests/bpf: Disable IPv6 for lwt_redirect test + +After a recent change in the vmtest runner"," this test started failing +sporadically. + +Investigation showed that this test was subject to race condition which +got exacerbated after the vm runner change. The symptoms being that the +logic that waited for an ICMPv4 packet is naive and will break if 5 or +more non-ICMPv4 packets make it to tap0. +When ICMPv6 is enabled","[' the kernel will generate traffic such as ICMPv6\nrouter solicitation...\nOn a system with good performance', ' the expected ICMPv4 packet would very\nlikely make it to the network interface promptly', ' but on a system with\npoor performance', ' those ""guarantees"" do not hold true anymore.\n\nGiven that the test is IPv4 only', ' this change disable IPv6 in the test\nnetns by setting `net.ipv6.conf.all.disable_ipv6` to 1.\nThis essentially leaves ""ping"" as the sole generator of traffic in the\nnetwork namespace.\nIf this test was to be made IPv6 compatible', ' the logic in\n`wait_for_packet` would need to be modified.\n\nIn more details...\n\nAt a high level', ' the test does:\n- create a new namespace\n- in `setup_redirect_target` set up lo', ' tap0', ' and link_err interfaces as\n well as add 2 routes that attaches ingress/egress sections of\n `test_lwt_redirect.bpf.o` to the xmit path.\n- in `send_and_capture_test_packets` send an ICMP packet and read off\n the tap interface (using `wait_for_packet`) to check that a ICMP packet\n with the right size is read.\n\n`wait_for_packet` will try to read `max_retry` (5) times from the tap0\nfd looking for an ICMPv4 packet matching some criteria.\n\nThe problem is that when we set up the `tap0` interface', ' because IPv6 is\nenabled by default', ' traffic such as Router solicitation is sent through\ntap0', ' as in:\n\n # tcpdump -r /tmp/lwt_redirect.pc\n reading from file /tmp/lwt_redirect.pcap', ' link-type EN10MB (Ethernet)\n 04:46:23.578352 IP6 :: > ff02::1:ffc0:4427: ICMP6', ' neighbor solicitation', ' who has fe80::fcba:dff:fec0:4427', ' length 32\n 04:46:23.659522 IP6 :: > ff02::16: HBH ICMP6', ' multicast listener report v2', ' 1 group record(s)', ' length 28\n 04:46:24.389169 IP 10.0.0.1 > 20.0.0.9: ICMP echo request', ' id 122', ' seq 1', ' length 108\n 04:46:24.618599 IP6 fe80::fcba:dff:fec0:4427 > ff02::16: HBH ICMP6', ' multicast listener report v2', ' 1 group record(s)', ' length 28\n 04:46:24.619985 IP6 fe80::fcba:dff:fec0:4427 > ff02::2: ICMP6', ' router solicitation', ' length 16\n 04:46:24.767326 IP6 fe80::fcba:dff:fec0:4427 > ff02::16: HBH ICMP6', ' multicast listener report v2', ' 1 group record(s)', ' length 28\n 04:46:28.936402 IP6 fe80::fcba:dff:fec0:4427 > ff02::2: ICMP6', ' router solicitation', ' length 16\n\nIf `wait_for_packet` sees 5 non-ICMPv4 packets', ' it will return 0', ' which is what we see in:\n\n 2024-01-31T03:51:25.0336992Z test_lwt_redirect_run:PASS:netns_create 0 nsec\n 2024-01-31T03:51:25.0341309Z open_netns:PASS:malloc token 0 nsec\n 2024-01-31T03:51:25.0344844Z open_netns:PASS:open /proc/self/ns/net 0 nsec\n 2024-01-31T03:51:25.0350071Z open_netns:PASS:open netns fd 0 nsec\n 2024-01-31T03:51:25.0353516Z open_netns:PASS:setns 0 nsec\n 2024-01-31T03:51:25.0356560Z test_lwt_redirect_run:PASS:setns 0 nsec\n 2024-01-31T03:51:25.0360140Z open_tuntap:PASS:open(/dev/net/tun) 0 nsec\n 2024-01-31T03:51:25.0363822Z open_tuntap:PASS:ioctl(TUNSETIFF) 0 nsec\n 2024-01-31T03:51:25.0367402Z open_tuntap:PASS:fcntl(O_NONBLOCK) 0 nsec\n 2024-01-31T03:51:25.0371167Z setup_redirect_target:PASS:open_tuntap 0 nsec\n 2024-01-31T03:51:25.0375180Z setup_redirect_target:PASS:if_nametoindex 0 nsec\n 2024-01-31T03:51:25.0379929Z setup_redirect_target:PASS:ip link add link_err type dummy 0 nsec\n 2024-01-31T03:51:25.0384874Z setup_redirect_target:PASS:ip link set lo up 0 nsec\n 2024-01-31T03:51:25.0389678Z setup_redirect_target:PASS:ip addr add dev lo 10.0.0.1/32 0 nsec\n 2024-01-31T03:51:25.0394814Z setup_redirect_target:PASS:ip link set link_err up 0 nsec\n 2024-01-31T03:51:25.0399874Z setup_redirect_target:PASS:ip link set tap0 up 0 nsec\n 2024-01-31T03:51:25.0407731Z setup_redirect_target:PASS:ip route add 10.0.0.0/24 dev link_err encap bpf xmit obj test_lwt_redirect.bpf.o sec redir_ingress 0 nsec\n 2024-01-31T03:51:25.0419105Z setup_redirect_target:PASS:ip route add 20.0.0.0/24 dev link_err encap bpf xmit obj test_lwt_redirect.bpf.o sec redir_egress 0 nsec\n 2024-01-31T03:51:25.0427209Z test_lwt_redirect_normal:PASS:setup_redirect_target 0 nsec\n 2024-01-31T03:51:25.0431424Z ping_dev:PASS:if_nametoindex 0 nsec\n 2024-01-31T03:51:25.0437222Z send_and_capture_test_packets:FAIL:wait_for_epacket unexpected wait_for_epacket: actual 0 != expected 1\n 2024-01-31T03:51:25.0448298Z (/tmp/work/bpf/bpf/tools/testing/selftests/bpf/prog_tests/lwt_redirect.c:175: errno: Success) test_lwt_redirect_normal egress test fails\n 2024-01-31T03:51:25.0457124Z close_netns:PASS:setns 0 nsec\n\nWhen running in a VM which potential resource contrains', ' the odds that calling\n`ping` is not scheduled very soon after bringing `tap0` up increases', '\nand with this the chances to get our ICMP packet pushed to position 6+\nin the network trace.\n\nTo confirm this indeed solves the issue', ' I ran the test 100 times in a\nrow with:\n\n errors=0\n successes=0\n for i in `seq 1 100`\n do\n ./test_progs -t lwt_redirect/lwt_redirect_normal\n if [ $? -eq 0 ]; then\n successes=$((successes+1))\n else\n errors=$((errors+1))\n fi\n done\n echo ""successes: $successes/errors: $errors""\n\nWhile this test would at least fail a couple of time every 10 runs', ' here\nit ran 100 times with no error.\n\nFixes: 43a7c3ef8a15 (""selftests/bpf: Add lwt_xmit tests for BPF_REDIRECT"")\nSigned-off-by: Manu Bretelle \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240131053212.2247527-1-chantr4@gmail.com\n', '']",Disable IPv6 in lwt_redirect test due to race conditions causing sporadic failures.,"selftests, IPv6, race condition",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +764ad6b02777d77dca3659ca490f0898aa593670,764ad6b02777d77dca3659ca490f0898aa593670,Benjamin Tissoires,bentiss@kernel.org,1706095619,Benjamin Tissoires,bentiss@kernel.org,1706693228,0e42f1b4a2b6c57fec946137e316371f90a3e69d,89be8aa5b0ecb3b729c7bcff64bb2af7921fec63,"HID: bpf: use __bpf_kfunc instead of noinline + +Follow the docs at Documentation/bpf/kfuncs.rst: +- declare the function with `__bpf_kfunc` +- disables missing prototype warnings"," which allows to remove them from + include/linux/hid-bpf.h + +Removing the prototypes is not an issue because we currently have to +redeclare them when writing the BPF program. They will eventually be +generated by bpftool directly AFAIU. + +Link: https://lore.kernel.org/r/20240124-b4-hid-bpf-fixes-v2-3-052520b1e5e6@kernel.org +Signed-off-by: Benjamin Tissoires +",[''],The commit replaces noinline with __bpf_kfunc for HID related BPF functions to align with documentation and streamline prototype handling.,"HID, __bpf_kfunc, prototype",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['HID driver like programs'] +89be8aa5b0ecb3b729c7bcff64bb2af7921fec63,89be8aa5b0ecb3b729c7bcff64bb2af7921fec63,Benjamin Tissoires,bentiss@kernel.org,1706095618,Benjamin Tissoires,bentiss@kernel.org,1706693225,b1a6d7ede14188df09992669cbfda5f6eaea0c5b,7cdd2108903a4e369eb37579830afc12a6877ec2,"HID: bpf: actually free hdev memory after attaching a HID-BPF program + +Turns out that I got my reference counts wrong and each successful +bus_find_device() actually calls get_device()"," and we need to manually +call put_device(). + +Ensure each bus_find_device() gets a matching put_device() when releasing +the bpf programs and fix all the error paths. + +Cc: +Fixes: f5c27da4e3c8 (""HID: initial BPF implementation"") +Link: https://lore.kernel.org/r/20240124-b4-hid-bpf-fixes-v2-2-052520b1e5e6@kernel.org +Signed-off-by: Benjamin Tissoires +",[''],Fixes memory leak by ensuring each bus_find_device() call is matched with a put_device() call in HID-BPF implementation.,"memory, HID-BPF, bus_find_device",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['HID driver like programs'] +7cdd2108903a4e369eb37579830afc12a6877ec2,7cdd2108903a4e369eb37579830afc12a6877ec2,Benjamin Tissoires,bentiss@kernel.org,1706095617,Benjamin Tissoires,bentiss@kernel.org,1706693220,53d7b58e90273e85e237500a2b887a18497d6c5d,00aab7dcb2267f2aef59447602f34501efe1a07f,"HID: bpf: remove double fdget() + +When the kfunc hid_bpf_attach_prog() is called"," we called twice fdget(): +one for fetching the type of the bpf program","[' and one for actually\nattaching the program to the device.\n\nThe problem is that between those two calls', ' we have no guarantees that\nthe prog_fd is still the same file descriptor for the given program.\n\nSolve this by calling bpf_prog_get() earlier', ' and use this to fetch the\nprogram type.\n\nReported-by: Dan Carpenter \nLink: https://lore.kernel.org/bpf/CAO-hwJJ8vh8JD3-P43L-_CLNmPx0hWj44aom0O838vfP4=_1CA@mail.gmail.com/T/#t\nCc: \nFixes: f5c27da4e3c8 (""HID: initial BPF implementation"")\nLink: https://lore.kernel.org/r/20240124-b4-hid-bpf-fixes-v2-1-052520b1e5e6@kernel.org\nSigned-off-by: Benjamin Tissoires \n', '']",Removed redundant fdget() call in hid_bpf_attach_prog() function.,"HID,bpf,fdget",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['HID driver like programs'] +e4009250574c69d2a3dd838af81cc3d4d72058e4,e4009250574c69d2a3dd838af81cc3d4d72058e4,Martin KaFai Lau,martin.lau@kernel.org,1706658950,Martin KaFai Lau,martin.lau@kernel.org,1706658959,a894b1c60e0bfa06e3acb82179271039dbedd3e3,4d8ebe1304e99cf6e08e432c23041638d6d1de56 ea9d561686fbd0e1ddf05d861d8f2c1ae8291870,"Merge branch 'libbpf: add bpf_core_cast() helper' + +Andrii Nakryiko says: + +==================== +Add bpf_core_cast("," ) macro wrapper around bpf_rdonly_cast() kfunc +to make it easier to use this functionality in BPF code. See patch #2 for +BPF selftests conversions demonstrating improvements in code succinctness. +==================== + +Signed-off-by: Martin KaFai Lau +",[''],Add bpf_core_cast() macro in libbpf to simplify usage of bpf_rdonly_cast() in BPF code.,"bpf_core_cast,libbpf,bpf_rdonly_cast",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ea9d561686fbd0e1ddf05d861d8f2c1ae8291870,ea9d561686fbd0e1ddf05d861d8f2c1ae8291870,Andrii Nakryiko,andrii@kernel.org,1706649623,Martin KaFai Lau,martin.lau@kernel.org,1706658950,a894b1c60e0bfa06e3acb82179271039dbedd3e3,20d59ee55172fdf6072abf871fa62b2070d6383f,"selftests/bpf: convert bpf_rdonly_cast() uses to bpf_core_cast() macro + +Use more ergonomic bpf_core_cast() macro instead of bpf_rdonly_cast() in +selftests code. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240130212023.183765-3-andrii@kernel.org +Signed-off-by: Martin KaFai Lau +",,The commit updates selftests to use bpf_core_cast() instead of bpf_rdonly_cast() for better ergonomics.,"bpf_core_cast,selftests,ergonomic",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +20d59ee55172fdf6072abf871fa62b2070d6383f,20d59ee55172fdf6072abf871fa62b2070d6383f,Andrii Nakryiko,andrii@kernel.org,1706649622,Martin KaFai Lau,martin.lau@kernel.org,1706658950,943d0e21220a3f83781da27546c470cbd56f71cf,4d8ebe1304e99cf6e08e432c23041638d6d1de56,"libbpf: add bpf_core_cast() macro + +Add bpf_core_cast() macro that wraps bpf_rdonly_cast() kfunc. It's more +ergonomic than kfunc"," as it automatically extracts btf_id with +bpf_core_type_id_kernel()","[' and works with type names. It also casts result\nto (T *) pointer. See the definition of the macro', "" it's self-explanatory.\n\nlibbpf declares bpf_rdonly_cast() extern as __weak __ksym and should be\nsafe to not conflict with other possible declarations in user code.\n\nBut we do have a conflict with current BPF selftests that declare their\nexterns with first argument as `void *obj`"", ' while libbpf opts into more\npermissive `const void *obj`. This causes conflict', ' so we fix up BPF\nselftests uses in the same patch.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240130212023.183765-2-andrii@kernel.org\nSigned-off-by: Martin KaFai Lau \n', '']",Introduces bpf_core_cast() macro to enhance usability by wrapping bpf_rdonly_cast() kfunc in libbpf.,"bpf_core_cast, ergonomic, libbpf",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4207b556e62f0a8915afc5da4c5d5ad915a253a5,4207b556e62f0a8915afc5da4c5d5ad915a253a5,Tejun Heo,tj@kernel.org,1704836884,Greg Kroah-Hartman,gregkh@linuxfoundation.org,1706658865,ee2acfd9720b3ed444d539954ba55447e6808aa4,1c9f2c7606afe149800986182638f636646dd824,"kernfs: RCU protect kernfs_nodes and avoid kernfs_idr_lock in kernfs_find_and_get_node_by_id() + +The BPF helper bpf_cgroup_from_id() calls kernfs_find_and_get_node_by_id() +which acquires kernfs_idr_lock"," which is an non-raw non-IRQ-safe lock. This +can lead to deadlocks as bpf_cgroup_from_id() can be called from any BPF +programs including e.g. the ones that attach to functions which are holding +the scheduler rq lock. + +Consider the following BPF program: + + SEC(""fentry/__set_cpus_allowed_ptr_locked"") + int BPF_PROG(__set_cpus_allowed_ptr_locked","[' struct task_struct *p', '\n\t struct affinity_context *affn_ctx', ' struct rq *rq', ' struct rq_flags *rf)\n {\n\t struct cgroup *cgrp = bpf_cgroup_from_id(p->cgroups->dfl_cgrp->kn->id);\n\n\t if (cgrp) {\n\t\t bpf_printk(""%d[%s] in %s""', ' p->pid', ' p->comm', ' cgrp->kn->name);\n\t\t bpf_cgroup_release(cgrp);\n\t }\n\t return 0;\n }\n\n__set_cpus_allowed_ptr_locked() is called with rq lock held and the above\nBPF program calls bpf_cgroup_from_id() within leading to the following\nlockdep warning:\n\n =====================================================\n WARNING: HARDIRQ-safe -> HARDIRQ-unsafe lock order detected\n 6.7.0-rc3-work-00053-g07124366a1d7-dirty #147 Not tainted\n -----------------------------------------------------\n repro/1620 [HC0[0]:SC0[0]:HE0:SE1] is trying to acquire:\n ffffffff833b3688 (kernfs_idr_lock){+.+.}-{2:2}', ' at: kernfs_find_and_get_node_by_id+0x1e/0x70\n\n\t\tand this task is already holding:\n ffff888237ced698 (&rq->__lock){-.-.}-{2:2}', "" at: task_rq_lock+0x4e/0xf0\n which would create a new lock dependency:\n (&rq->__lock){-.-.}-{2:2} -> (kernfs_idr_lock){+.+.}-{2:2}\n ...\n Possible interrupt unsafe locking scenario:\n\n\t CPU0 CPU1\n\t ---- ----\n lock(kernfs_idr_lock);\n\t\t\t\t local_irq_disable();\n\t\t\t\t lock(&rq->__lock);\n\t\t\t\t lock(kernfs_idr_lock);\n \n lock(&rq->__lock);\n\n\t\t *** DEADLOCK ***\n ...\n Call Trace:\n dump_stack_lvl+0x55/0x70\n dump_stack+0x10/0x20\n __lock_acquire+0x781/0x2a40\n lock_acquire+0xbf/0x1f0\n _raw_spin_lock+0x2f/0x40\n kernfs_find_and_get_node_by_id+0x1e/0x70\n cgroup_get_from_id+0x21/0x240\n bpf_cgroup_from_id+0xe/0x20\n bpf_prog_98652316e9337a5a___set_cpus_allowed_ptr_locked+0x96/0x11a\n bpf_trampoline_6442545632+0x4f/0x1000\n __set_cpus_allowed_ptr_locked+0x5/0x5a0\n sched_setaffinity+0x1b3/0x290\n __x64_sys_sched_setaffinity+0x4f/0x60\n do_syscall_64+0x40/0xe0\n entry_SYSCALL_64_after_hwframe+0x46/0x4e\n\nLet's fix it by protecting kernfs_node and kernfs_root with RCU and making\nkernfs_find_and_get_node_by_id() acquire rcu_read_lock() instead of\nkernfs_idr_lock.\n\nThis adds an rcu_head to kernfs_node making it larger by 16 bytes on 64bit.\nCombined with the preceding rearrange patch"", ' the net increase is 8 bytes.\n\nSigned-off-by: Tejun Heo \nCc: Andrea Righi \nCc: Geert Uytterhoeven \nLink: https://lore.kernel.org/r/20240109214828.252092-4-tj@kernel.org\nSigned-off-by: Greg Kroah-Hartman \n', '']",This commit improves RCU protection for kernfs_nodes to avoid deadlocks in bpf_cgroup_from_id().,"kernfs,RUC protection,deadlocks",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4d8ebe1304e99cf6e08e432c23041638d6d1de56,4d8ebe1304e99cf6e08e432c23041638d6d1de56,Alexei Starovoitov,ast@kernel.org,1706636511,Alexei Starovoitov,ast@kernel.org,1706636511,4d444f41e3e3e2410dc6faac1ce817127a40b4e2,24219056805f3988bf93e494499b2329453fc706 c381203eadb76d5601fc04b814317e7608af5f5c,"Merge branch 'trusted-ptr_to_btf_id-arg-support-in-global-subprogs' + +Andrii Nakryiko says: + +==================== +Trusted PTR_TO_BTF_ID arg support in global subprogs + +This patch set follows recent changes that added btf_decl_tag-based argument +annotation support for global subprogs. This time we add ability to pass +PTR_TO_BTF_ID (BTF-aware kernel pointers) arguments into global subprograms. +We support explicitly trusted arguments only"," for now. + +Patch #1 adds logic for arg:trusted tag support on the verifier side. Default +semantic of such arguments is non-NULL","[' enforced on caller side. But patch #2\nadds arg:nullable tag that can be combined with arg:trusted to make callee\nexplicitly do the NULL check', ' which helps implement ""optional"" PTR_TO_BTF_ID\narguments.\n\nPatch #3 adds libbpf-side __arg_trusted and __arg_nullable macros.\n\nPatch #4 adds a bunch of tests validating __arg_trusted in combination with\n__arg_nullable.\n\nv2->v3:\n - went back to arg:nullable and __arg_nullable naming;\n - rebased on latest bpf-next after prepartory patches landed;\nv1->v2:\n - added fix up to type enforcement changes', ' landed earlier;\n - dropped bpf_core_cast() changes', ' will post them separately', ' as they now\n are not used in added tests;\n - dropped arg:untrusted support (Alexei);\n - renamed arg:nullable to arg:maybe_null (Alexei);\n - and also added task_struct___local flavor tests (Alexei).\n====================\n\nLink: https://lore.kernel.org/r/20240130000648.2144827-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit supports trusted PTR_TO_BTF_ID argument handling in global subprograms.,"trusted arguments, PTR_TO_BTF_ID, global subprograms",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c381203eadb76d5601fc04b814317e7608af5f5c,c381203eadb76d5601fc04b814317e7608af5f5c,Andrii Nakryiko,andrii@kernel.org,1706573208,Alexei Starovoitov,ast@kernel.org,1706636510,4d444f41e3e3e2410dc6faac1ce817127a40b4e2,d28bb1a86e68a3d523e0acee8281bb904dd7f451,"selftests/bpf: add trusted global subprog arg tests + +Add a bunch of test cases validating behavior of __arg_trusted and its +combination with __arg_nullable tag. We also validate CO-RE flavor +support by kernel for __arg_trusted args. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240130000648.2144827-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add selftests for trusted global subprogram arguments in eBPF.,"selftests,arg_trusted,CO-RE",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d28bb1a86e68a3d523e0acee8281bb904dd7f451,d28bb1a86e68a3d523e0acee8281bb904dd7f451,Andrii Nakryiko,andrii@kernel.org,1706573207,Alexei Starovoitov,ast@kernel.org,1706636510,68c3f0fffa3d5b2c2394a9f3e7dca317d20c2546,8f2b44cd9d69ec36c9ce9623993978babb575ee8,"libbpf: add __arg_trusted and __arg_nullable tag macros + +Add __arg_trusted to annotate global func args that accept trusted +PTR_TO_BTF_ID arguments. + +Also add __arg_nullable to combine with __arg_trusted (and maybe other +tags in the future) to force global subprog itself (i.e."," callee) to do +NULL checks","["" as opposed to default non-NULL semantics (and thus caller's\nresponsibility to ensure non-NULL values).\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240130000648.2144827-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",This commit introduces __arg_trusted and __arg_nullable tag macros for annotating global function arguments in libbpf.,"libbpf, trusted, nullable",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8f2b44cd9d69ec36c9ce9623993978babb575ee8,8f2b44cd9d69ec36c9ce9623993978babb575ee8,Andrii Nakryiko,andrii@kernel.org,1706573206,Alexei Starovoitov,ast@kernel.org,1706636510,45c7502fc70ead45db93a3891838d7f2c364d6ac,e2b3c4ff5d183da6d1863c2321413406a2752e7a,"bpf: add arg:nullable tag to be combined with trusted pointers + +Add ability to mark arg:trusted arguments with optional arg:nullable +tag to mark it as PTR_TO_BTF_ID_OR_NULL variant"," which will allow +callers to pass NULL","[' and subsequently will force global subprog\'s code\nto do NULL check. This allows to have ""optional"" PTR_TO_BTF_ID values\npassed into global subprogs.\n\nFor now arg:nullable cannot be combined with anything else.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240130000648.2144827-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added support for marking trusted pointer arguments as nullable in eBPF.,"nullable, trusted, pointers",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e2b3c4ff5d183da6d1863c2321413406a2752e7a,e2b3c4ff5d183da6d1863c2321413406a2752e7a,Andrii Nakryiko,andrii@kernel.org,1706573205,Alexei Starovoitov,ast@kernel.org,1706636510,f72b7b9a230cda038b505d3a98732b658440bd3f,24219056805f3988bf93e494499b2329453fc706,"bpf: add __arg_trusted global func arg tag + +Add support for passing PTR_TO_BTF_ID registers to global subprogs. +Currently only PTR_TRUSTED flavor of PTR_TO_BTF_ID is supported. +Non-NULL semantics is assumed"," so caller will be forced to prove +PTR_TO_BTF_ID can't be NULL. + +Note","[' we disallow global subprogs to destroy passed in PTR_TO_BTF_ID\narguments', ' even the trusted one. We achieve that by not setting\nref_obj_id when validating subprog code. This basically enforces (in\nRust terms) borrowing semantics vs move semantics. Borrowing semantics\nseems to be a better fit for isolated global subprog validation\napproach.\n\nImplementation-wise', ' we utilize existing logic for matching\nuser-provided BTF type to kernel-side BTF type', ' used by BPF CO-RE logic\nand following same matching rules. We enforce a unique match for types.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240130000648.2144827-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Support is added for passing PTR_TO_BTF_ID registers with PTR_TRUSTED flavor to global subprogs in bpf.,"PTR_TO_BTF_ID,PTR_TRUSTED,global subprogs",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +24219056805f3988bf93e494499b2329453fc706,24219056805f3988bf93e494499b2329453fc706,Jose E. Marchesi,jose.marchesi@oracle.com,1706614584,Daniel Borkmann,daniel@iogearbox.net,1706627620,24f307e11435646d679987cebd4c7c9fbe198f06,27a90b14b93d3b2e1efd10764e456af7e2a42991,"bpf: Move -Wno-compare-distinct-pointer-types to BPF_CFLAGS + +Clang supports enabling/disabling certain conversion diagnostics via +the -W[no-]compare-distinct-pointer-types command line options. +Disabling this warning is required by some BPF selftests due to +-Werror. Until very recently GCC would emit these warnings +unconditionally", which was a problem for gcc-bpf,"[' but we added support\nfor the command-line options to GCC upstream [1].\n\nThis patch moves the -Wno-cmopare-distinct-pointer-types from\nCLANG_CFLAGS to BPF_CFLAGS in selftests/bpf/Makefile so the option\nis also used in gcc-bpf builds', ' not just in clang builds.\n\nTested in bpf-next master.\nNo regressions.\n\n [1] https://gcc.gnu.org/pipermail/gcc-patches/2023-August/627769.html\n\nSigned-off-by: Jose E. Marchesi \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240130113624.24940-1-jose.marchesi@oracle.com\n', '']",Move Clang diagnostic flag -Wno-compare-distinct-pointer-types to BPF_CFLAGS for BPF selftests compatibility.,"Clang, BPF_CFLAGS, selftests",It's a build system or CI/CD change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +27a90b14b93d3b2e1efd10764e456af7e2a42991,27a90b14b93d3b2e1efd10764e456af7e2a42991,Jose E. Marchesi,jose.marchesi@oracle.com,1706612623,Daniel Borkmann,daniel@iogearbox.net,1706627298,d830754421a89bf6005406d6e13f276796662a78,6668e818f960b0f32110a9efa7c97351a5771b35,"bpf: Build type-punning BPF selftests with -fno-strict-aliasing + +A few BPF selftests perform type punning and they may break strict +aliasing rules"," which are exploited by both GCC and clang by default +while optimizing. This can lead to broken compiled programs. + +This patch disables strict aliasing for these particular tests","[' by\nmean of the -fno-strict-aliasing command line option. This will make\nsure these tests are optimized properly even if some strict aliasing\nrule gets violated.\n\nAfter this patch', ' GCC is able to build all the selftests without\nwarning about potential strict aliasing issue.\n\nbpf@vger discussion on strict aliasing and BPF selftests:\nhttps://lore.kernel.org/bpf/bae1205a-b6e5-4e46-8e20-520d7c327f7a@linux.dev/T/#t\n\nTested in bpf-next master.\nNo regressions.\n\nSigned-off-by: Jose E. Marchesi \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/bae1205a-b6e5-4e46-8e20-520d7c327f7a@linux.dev\nLink: https://lore.kernel.org/bpf/20240130110343.11217-1-jose.marchesi@oracle.com\n', '']",Disable strict aliasing in certain BPF selftests to prevent optimization-related issues by compilers.,"type-punning,BPF selftests,strict-aliasing",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6668e818f960b0f32110a9efa7c97351a5771b35,6668e818f960b0f32110a9efa7c97351a5771b35,Haiyue Wang,haiyue.wang@intel.com,1706363336,Andrii Nakryiko,andrii@kernel.org,1706587495,e0d8c6487fd080914d48eababd5bfb1f38a9f049,ff2071a7b7fd77908417603c4a785822939b3841,bpf,"token: Use BIT_ULL() to convert the bit mask + +Replace the '(1ULL << *)' with the macro BIT_ULL(nr). + +Signed-off-by: Haiyue Wang +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240127134901.3698613-1-haiyue.wang@intel.com +",[''],Replace bit mask calculation with BIT_ULL macro for improved readability.,"BIT_ULL,macro,bit",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ff2071a7b7fd77908417603c4a785822939b3841,ff2071a7b7fd77908417603c4a785822939b3841,Jose E. Marchesi,jose.marchesi@oracle.com,1706381431,Andrii Nakryiko,andrii@kernel.org,1706575572,e98a8449e31b80a0d7c0288571ca0a0aa426a09f,f2e4040c82d3fddd11fa7c64e8f810e6f9cb7460,"bpf: Generate const static pointers for kernel helpers + +The generated bpf_helper_defs.h file currently contains definitions +like this for the kernel helpers"," which are static objects: + + static void *(*bpf_map_lookup_elem)(void *map","[' const void *key) = (void *) 1;\n\nThese work well in both clang and GCC because both compilers do\nconstant propagation with -O1 and higher optimization', "" resulting in\n`call 1' BPF instructions being generated"", ' which are calls to kernel\nhelpers.\n\nHowever', ' there is a discrepancy on how the -Wunused-variable\nwarning (activated by -Wall) is handled in these compilers:\n\n- clang will not emit -Wunused-variable warnings for static variables\n defined in C header files', ' be them constant or not constant.\n\n- GCC will not emit -Wunused-variable warnings for _constant_ static\n variables defined in header files', ' but it will emit warnings for\n non-constant static variables defined in header files.\n\nThere is no reason for these bpf_helpers_def.h pointers to not be\ndeclared constant', ' and it is actually desirable to do so', ' since their\nvalues are not to be changed. So this patch modifies bpf_doc.py to\ngenerate prototypes like:\n\n static void *(* const bpf_map_lookup_elem)(void *map', "" const void *key) = (void *) 1;\n\nThis allows GCC to not error while compiling BPF programs with `-Wall\n-Werror'"", "" while still being able to detect and error on legitimate\nunused variables in the program themselves.\n\nThis change doesn't impact the desired constant propagation in neither\nClang nor GCC with -O1 and higher. On the contrary"", ' being declared as\nconstant may increase the odds they get constant folded when\nused/referred to in certain circumstances.\n\nTested in bpf-next master.\nNo regressions.\n\nSigned-off-by: Jose E. Marchesi \nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240127185031.29854-1-jose.marchesi@oracle.com\n', '']",The commit generates const static pointers for kernel helper functions in bpf_helper_defs.h file.,"bpf, kernel helpers, pointers",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f2e4040c82d3fddd11fa7c64e8f810e6f9cb7460,f2e4040c82d3fddd11fa7c64e8f810e6f9cb7460,Ian Rogers,irogers@google.com,1706224720,Andrii Nakryiko,andrii@kernel.org,1706575362,f413ae5bdb8800f9612a875e827cc811bd3639b9,aecaa3ed48c3ae74c06f5e8ef0746b69c62397f1,"libbpf: Add some details for BTF parsing failures + +As CONFIG_DEBUG_INFO_BTF is default off the existing ""failed to find +valid kernel BTF"" message makes diagnosing the kernel build issue somewhat +cryptic. Add a little more detail with the hope of helping users. + +Before: +``` +libbpf: failed to find valid kernel BTF +libbpf: Error loading vmlinux BTF: -3 +``` + +After not accessible: +``` +libbpf: kernel BTF is missing at '/sys/kernel/btf/vmlinux'"," was CONFIG_DEBUG_INFO_BTF enabled? +libbpf: failed to find valid kernel BTF +libbpf: Error loading vmlinux BTF: -3 +``` + +After not readable: +``` +libbpf: failed to read kernel BTF from (/sys/kernel/btf/vmlinux): -1 +``` + +Closes: https://lore.kernel.org/bpf/CAP-5=fU+DN_+Y=Y4gtELUsJxKNDDCOvJzPHvjUVaUoeFAzNnig@mail.gmail.com/ + +Signed-off-by: Ian Rogers +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20240125231840.1647951-1-irogers@google.com +",[''],The commit enhances error messages for BTF parsing failures to aid in diagnosing kernel build issues.,"BTF,libbpf,error messages",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +aecaa3ed48c3ae74c06f5e8ef0746b69c62397f1,aecaa3ed48c3ae74c06f5e8ef0746b69c62397f1,Florian Lehner,dev@der-flo.net,1705763360,Daniel Borkmann,daniel@iogearbox.net,1706564437,595fcd3705bd6c5641be5b3c794cbfe53f47e71d,646751d523587cfd7ebcf1733298ecd470879eda,"perf/bpf: Fix duplicate type check + +Remove the duplicate check on type and unify result. + +Signed-off-by: Florian Lehner +Signed-off-by: Daniel Borkmann +Acked-by: Daniel Borkmann +Acked-by: Song Liu +Link: https://lore.kernel.org/bpf/20240120150920.3370-1-dev@der-flo.net +",,Remove duplicate type check in perf/bpf for consistency.,"perf,bpf,duplicate",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +646751d523587cfd7ebcf1733298ecd470879eda,646751d523587cfd7ebcf1733298ecd470879eda,Jose E. Marchesi,jose.marchesi@oracle.com,1706350022,Daniel Borkmann,daniel@iogearbox.net,1706564328,2cbf6d8e7a106064183bceb0c8c49581ac0c550e,fbaf59a9f513416c05f4b4e87d26898d3dccd1cc,"bpf: Use -Wno-error in certain tests when building with GCC + +Certain BPF selftests contain code that", albeit being legal C,"[' trigger\nwarnings in GCC that cannot be disabled. This is the case for example\nfor the tests\n\n progs/btf_dump_test_case_bitfields.c\n progs/btf_dump_test_case_namespacing.c\n progs/btf_dump_test_case_packing.c\n progs/btf_dump_test_case_padding.c\n progs/btf_dump_test_case_syntax.c\n\nwhich contain struct type declarations inside function parameter\nlists. This is problematic', ' because:\n\n- The BPF selftests are built with -Werror.\n\n- The Clang and GCC compilers sometimes differ when it comes to handle\n warnings. in the handling of warnings. One compiler may emit\n warnings for code that the other compiles compiles silently', ' and one\n compiler may offer the possibility to disable certain warnings', "" while\n the other doesn't.\n\nIn order to overcome this problem"", ' this patch modifies the\ntools/testing/selftests/bpf/Makefile in order to:\n\n1. Enable the possibility of specifing per-source-file extra CFLAGS.\n This is done by defining a make variable like:\n\n -CFLAGS := \n\n And then modifying the proper Make rule in order to use these flags\n when compiling .\n\n2. Use the mechanism above to add -Wno-error to CFLAGS for the\n following selftests:\n\n progs/btf_dump_test_case_bitfields.c\n progs/btf_dump_test_case_namespacing.c\n progs/btf_dump_test_case_packing.c\n progs/btf_dump_test_case_padding.c\n progs/btf_dump_test_case_syntax.c\n\n Note the corresponding -CFLAGS variables for these files are\n defined only if the selftests are being built with GCC.\n\nNote that', ' while compiler pragmas can generally be used to disable\nparticular warnings per file', ' this 1) is only possible for warning\nthat actually can be disabled in the command line', ' i.e. that have\n-Wno-FOO options', "" and 2) doesn't apply to -Wno-error.\n\nTested in bpf-next master branch.\nNo regressions.\n\nSigned-off-by: Jose E. Marchesi \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20240127100702.21549-1-jose.marchesi@oracle.com\n"", '']",Add -Wno-error flag to certain BPF selftests when using GCC.,"BPF selftests,GCC,-Wno-error",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fbaf59a9f513416c05f4b4e87d26898d3dccd1cc,fbaf59a9f513416c05f4b4e87d26898d3dccd1cc,Martin KaFai Lau,martin.lau@kernel.org,1706323817,Alexei Starovoitov,ast@kernel.org,1706561312,515085461029a2092aebd20f5a3b5187453d4a15,add9c58cd44e88a15f285945e26bf0d9d81c5890,"selftests/bpf: Remove ""&>"" usage in the selftests + +In s390"," CI reported that the sock_iter_batch selftest +hits this error very often: + +2024-01-26T16:56:49.3091804Z Bind /proc/self/ns/net -> /run/netns/sock_iter_batch_netns failed: No such file or directory +2024-01-26T16:56:49.3149524Z Cannot remove namespace file ""/run/netns/sock_iter_batch_netns"": No such file or directory +2024-01-26T16:56:49.3772213Z test_sock_iter_batch:FAIL:ip netns add sock_iter_batch_netns unexpected error: 256 (errno 0) + +It happens very often in s390 but Manu also noticed it happens very +sparsely in other arch also. + +It turns out the default dash shell does not recognize ""&>"" +as a redirection operator","[' so the command went to the background.\nIn the sock_iter_batch selftest', ' the ""ip netns delete"" went\ninto background and then race with the following ""ip netns add""\ncommand.\n\nThis patch replaces the ""&> /dev/null"" usage with "">/dev/null 2>&1""\nand does this redirection in the SYS_NOFAIL macro instead of doing\nit individually by its caller. The SYS_NOFAIL callers do not care\nabout failure', ' so it is no harm to do this redirection even if\nsome of the existing callers do not redirect to /dev/null now.\n\nIt touches different test files', ' so I skipped the Fixes tags\nin this patch. Some of the changed tests do not use ""&>""\nbut they use the SYS_NOFAIL', ' so these tests are also\nchanged to avoid doing its own redirection because\nSYS_NOFAIL does it internally now.\n\nSigned-off-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20240127025017.950825-1-martin.lau@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']","Remove ""&>"" redirection usage in bpf selftests to address shell compatibility issues.","selftests, redirection, s390",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +add9c58cd44e88a15f285945e26bf0d9d81c5890,add9c58cd44e88a15f285945e26bf0d9d81c5890,Andrii Nakryiko,andrii@kernel.org,1706216106,Alexei Starovoitov,ast@kernel.org,1706560453,c1d2907a12d225121b23ffc703031d33f9f48cc4,9eea8fafe33eb70868f6ace2fc1e17c4ff5539c3,"bpf: move arg:ctx type enforcement check inside the main logic loop + +Now that bpf and bpf-next trees converged and we don't run the risk of +merge conflicts"," move btf_validate_prog_ctx_type() into its most logical +place inside the main logic loop. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240125205510.3642094-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Refactor the position of context type enforcement check inside the bpf main logic loop.,"type enforcement, context, logic loop",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9eea8fafe33eb70868f6ace2fc1e17c4ff5539c3,9eea8fafe33eb70868f6ace2fc1e17c4ff5539c3,Andrii Nakryiko,andrii@kernel.org,1706216105,Alexei Starovoitov,ast@kernel.org,1706560453,504fe883aa1bf4cbb27a7cbf85152d3cd2d93c65,0e6d0a9d2348b64df74239e859fa9d6e86cdcdef,"libbpf: fix __arg_ctx type enforcement for perf_event programs + +Adjust PERF_EVENT type enforcement around __arg_ctx to match exactly +what kernel is doing. + +Fixes: 76ec90a996e3 (""libbpf: warn on unexpected __arg_ctx type when rewriting BTF"") +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240125205510.3642094-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Fixes type enforcement for __arg_ctx in PERF_EVENT programs to match kernel behavior in libbpf.,"libbpf, perf_event, __arg_ctx",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,['tracepoints like programs'] +0e6d0a9d2348b64df74239e859fa9d6e86cdcdef,0e6d0a9d2348b64df74239e859fa9d6e86cdcdef,Andrii Nakryiko,andrii@kernel.org,1706216104,Alexei Starovoitov,ast@kernel.org,1706560453,02f3789507760c1311101d6c8203d84addec2955,ced33f2cfa21a14a292a00e31dc9f85c1bfbda1c,"libbpf: integrate __arg_ctx feature detector into kernel_supports() + +Now that feature detection code is in bpf-next tree"," integrate __arg_ctx +kernel-side support into kernel_supports() framework. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240125205510.3642094-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Integrates the __arg_ctx feature detection into the libbpf's kernel_supports framework.,"libbpf,__arg_ctx,feature",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ced33f2cfa21a14a292a00e31dc9f85c1bfbda1c,ced33f2cfa21a14a292a00e31dc9f85c1bfbda1c,Yonghong Song,yonghong.song@linux.dev,1706384789,Daniel Borkmann,daniel@iogearbox.net,1706543673,c1ff1a7054587716b2ad4cd071023314b4cca538,efaa47db92451608499ab7edf108bf30141c33db,"docs/bpf: Improve documentation of 64-bit immediate instructions + +For 64-bit immediate instruction"," 'BPF_IMM | BPF_DW | BPF_LD' and +src_reg=[0-6]","[' the current documentation describes the 64-bit\nimmediate is constructed by:\n\n imm64 = (next_imm << 32) | imm\n\nBut actually imm64 is only used when src_reg=0. For all other\nvariants (src_reg != 0)', "" 'imm' and 'next_imm' have separate special\nencoding requirement and imm64 cannot be easily used to describe\ninstruction semantics.\n\nThis patch clarifies that 64-bit immediate instructions use\ntwo 32-bit immediate values instead of a 64-bit immediate value"", '\nso later describing individual 64-bit immediate instructions\nbecomes less confusing.\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Daniel Borkmann \nAcked-by: Dave Thaler \nLink: https://lore.kernel.org/bpf/20240127194629.737589-1-yonghong.song@linux.dev\n', '']",Improve the documentation for 64-bit immediate instructions in eBPF.,"documentation, 64-bit, instructions",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +efaa47db92451608499ab7edf108bf30141c33db,efaa47db92451608499ab7edf108bf30141c33db,Menglong Dong,dongmenglong.8@bytedance.com,1706421283,Daniel Borkmann,daniel@iogearbox.net,1706543093,d8c2405cd3568bca72a9c7472cc0d1418646d207,f149d03f450b4afab11f5e1ebd8fdfaf7eb24a28,"bpf: Remove unused field ""mod"" in struct bpf_trampoline + +It seems that the field ""mod"" in struct bpf_trampoline is not used +anywhere after the commit 31bf1dbccfb0 (""bpf: Fix attaching +fentry/fexit/fmod_ret/lsm to modules""). So we can just remove it now. + +Fixes: 31bf1dbccfb0 (""bpf: Fix attaching fentry/fexit/fmod_ret/lsm to modules"") +Signed-off-by: Menglong Dong +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/bpf/20240128055443.413291-1-dongmenglong.8@bytedance.com +",,"Remove unused ""mod"" field from bpf_trampoline structure for simplification.","unused field,bpf_trampoline,mod removal",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f149d03f450b4afab11f5e1ebd8fdfaf7eb24a28,f149d03f450b4afab11f5e1ebd8fdfaf7eb24a28,Geliang Tang,tanggeliang@kylinos.cn,1706442237,Daniel Borkmann,daniel@iogearbox.net,1706542889,4ad7347ebcf54143db3162389cff406a0c89ff50,06a33d024838414432b6c0f51f994e7f1695b74f,"selftests/bpf: Drop return in bpf_testmod_exit + +bpf_testmod_exit() does not need to have a return value (given the void)"," +so this patch drops this useless 'return' in it. + +Signed-off-by: Geliang Tang +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/bpf/5765b287ea088f0c820f2a834faf9b20fb2f8215.1706442113.git.tanggeliang@kylinos.cn +",[''],Removed unnecessary return statement in bpf_testmod_exit() due to void return type.,"selftests,bpf,bpf_testmod_exit",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +06a33d024838414432b6c0f51f994e7f1695b74f,06a33d024838414432b6c0f51f994e7f1695b74f,Pu Lehui,pulehui@huawei.com,1705324355,Daniel Borkmann,daniel@iogearbox.net,1706541933,ce2470d5a3291c05e9a48eb2fd0f20334c769379,519fb722bea09ae2664ad21f8ef4360fb799eb2f,riscv," bpf: Optimize bswap insns with Zbb support + +Optimize bswap instructions by rev8 Zbb instruction conbined with srli +instruction. And Optimize 16-bit zero-extension with Zbb support. + +Signed-off-by: Pu Lehui +Signed-off-by: Daniel Borkmann +Tested-by: Björn Töpel +Acked-by: Björn Töpel +Link: https://lore.kernel.org/bpf/20240115131235.2914289-7-pulehui@huaweicloud.com +",[''],Optimize bswap instructions with Zbb support on RISC-V architecture.,"Optimize,RISC-V,Zbb",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +519fb722bea09ae2664ad21f8ef4360fb799eb2f,519fb722bea09ae2664ad21f8ef4360fb799eb2f,Pu Lehui,pulehui@huawei.com,1705324354,Daniel Borkmann,daniel@iogearbox.net,1706541933,e20f5b0751cd2551f703834bd9be65633771a59c,647b93f65daa128d9a0e4aac744a5fcf5f58b2d2,riscv," bpf: Optimize sign-extention mov insns with Zbb support + +Add 8-bit and 16-bit sign-extention wraper with Zbb support to optimize +sign-extension mov instructions. + +Signed-off-by: Pu Lehui +Signed-off-by: Daniel Borkmann +Tested-by: Björn Töpel +Acked-by: Björn Töpel +Link: https://lore.kernel.org/bpf/20240115131235.2914289-6-pulehui@huaweicloud.com +",[''],Optimize sign-extension mov instructions on RISC-V with support for 8-bit and 16-bit Zbb extensions.,"sign-extension,RISC-V,Zbb",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +647b93f65daa128d9a0e4aac744a5fcf5f58b2d2,647b93f65daa128d9a0e4aac744a5fcf5f58b2d2,Pu Lehui,pulehui@huawei.com,1705324353,Daniel Borkmann,daniel@iogearbox.net,1706541933,1dbbebfef86d0568d6de577164baac167ef10f27,361db44c3c59cde05e9926647f16255e274a37f4,riscv," bpf: Add necessary Zbb instructions + +Add necessary Zbb instructions introduced by [0] to reduce code size and +improve performance of RV64 JIT. Meanwhile","[' a runtime deteted helper is\nadded to check whether the CPU supports Zbb instructions.\n\nSigned-off-by: Pu Lehui \nSigned-off-by: Daniel Borkmann \nTested-by: Björn Töpel \nAcked-by: Björn Töpel \nLink: https://github.com/riscv/riscv-bitmanip/releases/download/1.0.0/bitmanip-1.0.0-38-g865e7a7.pdf [0]\nLink: https://lore.kernel.org/bpf/20240115131235.2914289-5-pulehui@huaweicloud.com\n', '']",Add Zbb instructions to enhance performance and reduce code size for RV64 JIT in RISC-V architecture.,"Zbb, RV64, JIT",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +361db44c3c59cde05e9926647f16255e274a37f4,361db44c3c59cde05e9926647f16255e274a37f4,Pu Lehui,pulehui@huawei.com,1705324352,Daniel Borkmann,daniel@iogearbox.net,1706541933,5a95a54d3a7fbc93b9d4dbf3205b4f854f562ace,914c7a5ff18a225f7df254ae3433574f3d47b711,riscv," bpf: Simplify sext and zext logics in branch instructions + +There are many extension helpers in the current branch instructions","[' and\nthe implementation is a bit complicated. We simplify this logic through\ntwo simple extension helpers with alternate register.\n\nSigned-off-by: Pu Lehui \nSigned-off-by: Daniel Borkmann \nTested-by: Björn Töpel \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240115131235.2914289-4-pulehui@huaweicloud.com\n', '']",Simplify the extension logic in RISC-V branch instructions for the BPF subsystem.,"riscv, simplify, branch",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +914c7a5ff18a225f7df254ae3433574f3d47b711,914c7a5ff18a225f7df254ae3433574f3d47b711,Pu Lehui,pulehui@huawei.com,1705324351,Daniel Borkmann,daniel@iogearbox.net,1706541933,e4dc7d61f7d90f4121042426892ee4f7a3ab1c0c,e33758f7493c9ad8cf6960bcf7c70f5761f3acfb,riscv," bpf: Unify 32-bit zero-extension to emit_zextw + +For code unification","[' add emit_zextw wrapper to unify all the 32-bit\nzero-extension operations.\n\nSigned-off-by: Pu Lehui \nSigned-off-by: Daniel Borkmann \nTested-by: Björn Töpel \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240115131235.2914289-3-pulehui@huaweicloud.com\n', '']",Unify 32-bit zero-extension code in riscv architecture.,"riscv, code unification, emit_zextw",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e33758f7493c9ad8cf6960bcf7c70f5761f3acfb,e33758f7493c9ad8cf6960bcf7c70f5761f3acfb,Pu Lehui,pulehui@huawei.com,1705324350,Daniel Borkmann,daniel@iogearbox.net,1706541932,dcc00029047295dfcb3f8be9454ac90b444c1a30,ad57654053805bf9a62602aaec74cc78edb6f235,riscv," bpf: Unify 32-bit sign-extension to emit_sextw + +For code unification","[' add emit_sextw wrapper to unify all the 32-bit\nsign-extension operations.\n\nSigned-off-by: Pu Lehui \nSigned-off-by: Daniel Borkmann \nTested-by: Björn Töpel \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240115131235.2914289-2-pulehui@huaweicloud.com\n', '']",Unifies 32-bit sign-extension for the RISC-V architecture in BPF.,"unify, sign-extension, riscv",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ad57654053805bf9a62602aaec74cc78edb6f235,ad57654053805bf9a62602aaec74cc78edb6f235,Andrii Nakryiko,andrii@kernel.org,1706306984,Daniel Borkmann,daniel@iogearbox.net,1706541464,d6f66e87082111583b271b5dff78a22745acb1c4,29788f39a4171dd48a6d19eb78cf2ab168c4349a,"libbpf: Fix faccessat() usage on Android + +Android implementation of libc errors out with -EINVAL in faccessat() if +passed AT_EACCESS ([0])"," this leads to ridiculous issue with libbpf +refusing to load /sys/kernel/btf/vmlinux on Androids ([1]). Fix by +detecting Android and redefining AT_EACCESS to 0","[' it\'s equivalent on\nAndroid.\n\n [0] https://android.googlesource.com/platform/bionic/+/refs/heads/android13-release/libc/bionic/faccessat.cpp#50\n [1] https://github.com/libbpf/libbpf-bootstrap/issues/250#issuecomment-1911324250\n\nFixes: 6a4ab8869d0b (""libbpf: Fix the case of running as non-root with capabilities"")\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/bpf/20240126220944.2497665-1-andrii@kernel.org\n', '']",The commit fixes faccessat() usage in libbpf on Android by handling AT_EACCESS error.,"libbpf, Android, faccessat",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +29788f39a4171dd48a6d19eb78cf2ab168c4349a,29788f39a4171dd48a6d19eb78cf2ab168c4349a,Arnaldo Carvalho de Melo,acme@kernel.org,1706538806,Daniel Borkmann,daniel@iogearbox.net,1706540926,d072aec607a6d5fa0825e542e00f11a9e9fdef95,723de3ebef03bc14bd72531f00f9094337654009,"bpftool: Be more portable by using POSIX's basename() + +musl libc had the basename() prototype in string.h"," but this is a +glibc-ism","[' now they removed the _GNU_SOURCE bits in their devel distro', '\nAlpine Linux edge:\n\n https://git.musl-libc.org/cgit/musl/commit/?id=725e17ed6dff4d0cd22487bb64470881e86a92e7\n\nSo lets use the POSIX version', ' the whole rationale is spelled out at:\n\n https://gitlab.alpinelinux.org/alpine/aports/-/issues/15643\n\nSigned-off-by: Arnaldo Carvalho de Melo \nSigned-off-by: Daniel Borkmann \nAcked-by: Jiri Olsa \nAcked-by: Quentin Monnet \nLink: https://lore.kernel.org/lkml/ZZhsPs00TI75RdAr@kernel.org\nLink: https://lore.kernel.org/bpf/Zbe3NuOgaupvUcpF@kernel.org\n', '']",Improve bpftool portability by using POSIX basename() function.,"bpftool, portability, POSIX",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +92046e83c07b064ca65ac4ae7660a540016bdfc1,92046e83c07b064ca65ac4ae7660a540016bdfc1,Jakub Kicinski,kuba@kernel.org,1706332101,Jakub Kicinski,kuba@kernel.org,1706332102,7f8a5dd9522e2b744a48d93ca5a7ec418ea192f5,c09f32a859458002b40ba44fc736329a4c0fe4e5 fa7178b0f12e55a4f2d4906df3f25d6d4f88d962,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-01-26 + +We've added 107 non-merge commits during the last 4 day(s) which contain +a total of 101 files changed", 6009 insertions(+),"["" 1260 deletions(-).\n\nThe main changes are:\n\n1) Add BPF token support to delegate a subset of BPF subsystem\n functionality from privileged system-wide daemons such as systemd\n through special mount options for userns-bound BPF fs to a trusted\n & unprivileged application. With addressed changes from Christian\n and Linus' reviews"", ' from Andrii Nakryiko.\n\n2) Support registration of struct_ops types from modules which helps\n projects like fuse-bpf that seeks to implement a new struct_ops type', '\n from Kui-Feng Lee.\n\n3) Add support for retrieval of cookies for perf/kprobe multi links', '\n from Jiri Olsa.\n\n4) Bigger batch of prep-work for the BPF verifier to eventually support\n preserving boundaries and tracking scalars on narrowing fills', '\n from Maxim Mikityanskiy.\n\n5) Extend the tc BPF flavor to support arbitrary TCP SYN cookies to help\n with the scenario of SYN floods', ' from Kuniyuki Iwashima.\n\n6) Add code generation to inline the bpf_kptr_xchg() helper which\n improves performance when stashing/popping the allocated BPF objects', '\n from Hou Tao.\n\n7) Extend BPF verifier to track aligned ST stores as imprecise spilled\n registers', ' from Yonghong Song.\n\n8) Several fixes to BPF selftests around inline asm constraints and\n unsupported VLA code generation', ' from Jose E. Marchesi.\n\n9) Various updates to the BPF IETF instruction set draft document such\n as the introduction of conformance groups for instructions', '\n from Dave Thaler.\n\n10) Fix BPF verifier to make infinite loop detection in is_state_visited()\n exact to catch some too lax spill/fill corner cases', '\n from Eduard Zingerman.\n\n11) Refactor the BPF verifier pointer ALU check to allow ALU explicitly\n instead of implicitly for various register types', ' from Hao Sun.\n\n12) Fix the flaky tc_redirect_dtime BPF selftest due to slowness\n in neighbor advertisement at setup time', ' from Martin KaFai Lau.\n\n13) Change BPF selftests to skip callback tests for the case when the\n JIT is disabled', "" from Tiezhu Yang.\n\n14) Add a small extension to libbpf which allows to auto create\n a map-in-map's inner map"", "" from Andrey Grafin.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (107 commits)\n selftests/bpf: Add missing line break in test_verifier\n bpf"", ' docs: Clarify definitions of various instructions\n bpf: Fix error checks against bpf_get_btf_vmlinux().\n bpf: One more maintainer for libbpf and BPF selftests\n selftests/bpf: Incorporate LSM policy to token-based tests\n selftests/bpf: Add tests for LIBBPF_BPF_TOKEN_PATH envvar\n libbpf: Support BPF token path setting through LIBBPF_BPF_TOKEN_PATH envvar\n selftests/bpf: Add tests for BPF object load with implicit token\n selftests/bpf: Add BPF object loading tests with explicit token passing\n libbpf: Wire up BPF token support at BPF object level\n libbpf: Wire up token_fd into feature probing logic\n libbpf: Move feature detection code into its own file\n libbpf: Further decouple feature checking logic from bpf_object\n libbpf: Split feature detectors definitions from cached results\n selftests/bpf: Utilize string values for delegate_xxx mount options\n bpf: Support symbolic BPF FS delegation mount options\n bpf: Fail BPF_TOKEN_CREATE if no delegation option was set on BPF FS\n bpf', 'selinux: Allocate bpf_security_struct per BPF token\n selftests/bpf: Add BPF token-enabled tests\n libbpf: Add BPF token support to bpf_prog_load() API\n ...\n====================\n\nLink: https://lore.kernel.org/r/20240126215710.19855-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merged branch 'for-netdev' from bpf-next with 107 new commits.,"bpf-next, merge, netdev",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +d3cb3b0088ca92082e2bebc40cc6894a632173e2,d3cb3b0088ca92082e2bebc40cc6894a632173e2,Paolo Abeni,pabeni@redhat.com,1706170970,Jakub Kicinski,kuba@kernel.org,1706306970,b0dd97fb4c484d1c9cbab15cbc302989a9b0f5dd,281cb9d65a95c00bb844f332cd187491d2d55496,"selftests: net: add missing required classifier + +the udpgro_fraglist self-test uses the BPF classifiers"," but the +current net self-test configuration does not include it","[' causing\nCI failures:\n\n # selftests: net: udpgro_frglist.sh\n # ipv6\n # tcp - over veth touching data\n # -l 4 -6 -D 2001:db8::1 -t rx -4 -t\n # Error: TC classifier not found.\n # We have an error talking to the kernel\n # Error: TC classifier not found.\n # We have an error talking to the kernel\n\nAdd the missing knob.\n\nFixes: edae34a3ed92 (""selftests net: add UDP GRO fraglist + bpf self-tests"")\nSigned-off-by: Paolo Abeni \nReviewed-by: Maciej Żenczykowski \nReviewed-by: Eric Dumazet \nLink: https://lore.kernel.org/r/7c3643763b331e9a400e1874fe089193c99a1c3f.1706170897.git.pabeni@redhat.com\nSigned-off-by: Jakub Kicinski \n', '']",The commit adds a missing required BPF classifier for the udpgro_fraglist self-test in net self-tests.,"self-test, BPF classifiers, net",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fa7178b0f12e55a4f2d4906df3f25d6d4f88d962,fa7178b0f12e55a4f2d4906df3f25d6d4f88d962,Tiezhu Yang,yangtiezhu@loongson.cn,1706234256,Andrii Nakryiko,andrii@kernel.org,1706296172,6817be7ae5fd0cbb8587ea8d4e8ee6acec766f39,e48f0f4a9bfed8947e4d1123e8b6a15c18ee1708,"selftests/bpf: Add missing line break in test_verifier + +There are no break lines in the test log for test_verifier #106 ~ #111 +if jit is disabled"," add the missing line break at the end of printf() +to fix it. + +Without this patch: + + [root@linux bpf]# echo 0 > /proc/sys/net/core/bpf_jit_enable + [root@linux bpf]# ./test_verifier 106 + #106/p inline simple bpf_loop call SKIP (requires BPF JIT)Summary: 0 PASSED","[' 1 SKIPPED', ' 0 FAILED\n\nWith this patch:\n\n [root@linux bpf]# echo 0 > /proc/sys/net/core/bpf_jit_enable\n [root@linux bpf]# ./test_verifier 106\n #106/p inline simple bpf_loop call SKIP (requires BPF JIT)\n Summary: 0 PASSED', ' 1 SKIPPED', ' 0 FAILED\n\nFixes: 0b50478fd877 (""selftests/bpf: Skip callback tests if jit is disabled in test_verifier"")\nSigned-off-by: Tiezhu Yang \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240126015736.655-1-yangtiezhu@loongson.cn\n', '']",Added missing line break in test_verifier selftest to improve readability for non-JIT logs.,"line break,selftests,test_verifier",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e48f0f4a9bfed8947e4d1123e8b6a15c18ee1708,e48f0f4a9bfed8947e4d1123e8b6a15c18ee1708,Dave Thaler,dthaler1968@googlemail.com,1706241650,Daniel Borkmann,daniel@iogearbox.net,1706292338,c0d661ff0303c6bf02ae0aad1d355e72cbd8ea23,e6be8cd5d3cf54ccd0ae66027d6f4697b15f4c3e,bpf," docs: Clarify definitions of various instructions + +Clarify definitions of several instructions: + +* BPF_NEG does not support BPF_X +* BPF_CALL does not support BPF_JMP32 or BPF_X +* BPF_EXIT does not support BPF_X +* BPF_JA does not support BPF_X (was implied but not explicitly stated) + +Also fix a typo in the wide instruction figure where the field is +actually named ""opcode"" not ""code"". + +Signed-off-by: Dave Thaler +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240126040050.8464-1-dthaler1968@gmail.com +",[''],Clarified instruction definitions in documentation and fixed typo in BPF opcode description.,"documentation, instruction, typo",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +e6be8cd5d3cf54ccd0ae66027d6f4697b15f4c3e,e6be8cd5d3cf54ccd0ae66027d6f4697b15f4c3e,Kui-Feng Lee,thinker.li@gmail.com,1706236273,Martin KaFai Lau,martin.lau@kernel.org,1706244599,ea60dfda94c8a06e4c14f90a4900b7167121d847,be4840b33eb2ea7d80830530aab5fcbeaa90e857,"bpf: Fix error checks against bpf_get_btf_vmlinux(). + +In bpf_struct_ops_map_alloc"," it needs to check for NULL in the returned +pointer of bpf_get_btf_vmlinux() when CONFIG_DEBUG_INFO_BTF is not set. +ENOTSUPP is used to preserve the same behavior before the +struct_ops kmod support. + +In the function check_struct_ops_btf_id()","[' instead of redoing the\nbpf_get_btf_vmlinux() that has already been done in syscall.c', ' the fix\nhere is to check for prog->aux->attach_btf_id.\nBPF_PROG_TYPE_STRUCT_OPS must require attach_btf_id and syscall.c\nguarantees a valid attach_btf as long as attach_btf_id is set.\nWhen attach_btf_id is not set', ' this patch returns -ENOTSUPP\nbecause it is what the selftest in test_libbpf_probe_prog_types()\nand libbpf_probes.c are expecting for feature probing purpose.\n\nChanges from v1:\n\n - Remove an unnecessary NULL check in check_struct_ops_btf_id()\n\nReported-by: syzbot+88f0aafe5f950d7489d7@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/00000000000040d68a060fc8db8c@google.com/\nReported-by: syzbot+1336f3d4b10bcda75b89@syzkaller.appspotmail.com\nCloses: https://lore.kernel.org/bpf/00000000000026353b060fc21c07@google.com/\nFixes: fcc2c1fb0651 (""bpf: pass attached BTF to the bpf_struct_ops subsystem"")\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240126023113.1379504-1-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Fix NULL pointer checks for bpf_get_btf_vmlinux() in bpf_struct_ops_map_alloc.,"NULL, ENOTSUPP, struct_ops",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +be4840b33eb2ea7d80830530aab5fcbeaa90e857,be4840b33eb2ea7d80830530aab5fcbeaa90e857,Eduard Zingerman,eddyz87@gmail.com,1706239554,Alexei Starovoitov,ast@kernel.org,1706241452,84f56e6cb2fdbe64638b989d2cf7a1f94df5b809,c8632acf193beac64bbdaebef013368c480bf74f,"bpf: One more maintainer for libbpf and BPF selftests + +I've been working on BPF verifier", BPF selftests and,"[' to some extent', '\nlibbpf', ' for some time. As suggested by Andrii and Alexei', '\nI humbly ask to add me to maintainers list:\n- As reviewer for BPF [GENERAL]\n- As maintainer for BPF [LIBRARY]\n- As maintainer for BPF [SELFTESTS]\n\nThis patch adds dedicated entries to MAINTAINERS.\n\nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240126032554.9697-1-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Added an additional maintainer for libbpf and BPF selftests.,"maintainer, libbpf, selftests",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ce36ea754051cfae39eabd841f907de0e8d8a6b7,ce36ea754051cfae39eabd841f907de0e8d8a6b7,Jakub Kicinski,kuba@kernel.org,1706227164,Jakub Kicinski,kuba@kernel.org,1706227165,965e547493fc98430faa22c5c62678935754dfee,b64787840080bdbd048bb9c68222ad17236cbd7e 4acffb66630a0e4800880baa61a54ef18047ccd3,"Merge branch 'selftests-net-a-few-fixes' + +Paolo Abeni says: + +==================== +selftests: net: a few fixes + +This series address self-tests failures for udp gro-related tests. + +The first patch addresses the main problem I observe locally - the XDP +program required by such tests", xdp_dummy,"[' is currently build in the\nebpf self-tests directory', ' not available if/when the user targets net\nonly. Arguably is more a refactor than a fix', ' but still targeting net\nto hopefully\n\nThe second patch fixes the integration of such tests with the build\nsystem.\n\nPatch 3/3 fixes sporadic failures due to races.\n\nTested with:\n\nmake -C tools/testing/selftests/ TARGETS=net install\n./tools/testing/selftests/kselftest_install/run_kselftest.sh \\\n\t-t ""net:udpgro_bench.sh net:udpgro.sh net:udpgro_fwd.sh \\\n\t net:udpgro_frglist.sh net:veth.sh""\n\nno failures.\n====================\n\nLink: https://lore.kernel.org/r/cover.1706131762.git.pabeni@redhat.com\nSigned-off-by: Jakub Kicinski \n', '']",This commit integrates a series of fixes for self-tests related to udp gro and XDP programs.,"self-tests, udp, XDP",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['xdp like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +98cb12eb52a780e682bea8372fdb2912c08132dd,98cb12eb52a780e682bea8372fdb2912c08132dd,Paolo Abeni,pabeni@redhat.com,1706132000,Jakub Kicinski,kuba@kernel.org,1706227162,b02b00f3fe5c800af62c6560bd47f96d4aec1a41,b64787840080bdbd048bb9c68222ad17236cbd7e,"selftests: net: remove dependency on ebpf tests + +Several net tests requires an XDP program build under the ebpf +directory"," and error out if such program is not available. + +That makes running successful net test hard","["" let's duplicate into the\nnet dir the [very small] program"", ' re-using the existing rules to build\nit', ' and finally dropping the bogus dependency.\n\nSigned-off-by: Paolo Abeni \nReviewed-by: Willem de Bruijn \nLink: https://lore.kernel.org/r/28e7af7c031557f691dc8045ee41dd549dd5e74c.1706131762.git.pabeni@redhat.com\nSigned-off-by: Jakub Kicinski \n', '']",The commit removes the dependency of net tests on building XDP programs in the ebpf directory.,"selftests, net, dependency",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['xdp like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ecb1b8288dc7ccbdcb3b9df005fa1c0e0c0388a7,ecb1b8288dc7ccbdcb3b9df005fa1c0e0c0388a7,Linus Torvalds,torvalds@linux-foundation.org,1706209115,Linus Torvalds,torvalds@linux-foundation.org,1706209115,0079bb506b44bd5add46812c38ec0addf34078a7,bdc010200eb5e2cddf1c76c83386bdde8aad0899 0a5bd0ffe790511d802e7f40898429a89e2487df,"Merge tag 'net-6.8-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + ""Including fixes from bpf"," netfilter and WiFi. + + Jakub is doing a lot of work to include the self-tests in our CI","[' as a\n result a significant amount of self-tests related fixes is flowing in\n (and will likely continue in the next few weeks).\n\n Current release - regressions:\n\n - bpf: fix a kernel crash for the riscv 64 JIT\n\n - bnxt_en: fix memory leak in bnxt_hwrm_get_rings()\n\n - revert ""net: macsec: use skb_ensure_writable_head_tail to expand\n the skb""\n\n Previous releases - regressions:\n\n - core: fix removing a namespace with conflicting altnames\n\n - tc/flower: fix chain template offload memory leak\n\n - tcp:\n - make sure init the accept_queue\'s spinlocks once\n - fix autocork on CPUs with weak memory model\n\n - udp: fix busy polling\n\n - mlx5e:\n - fix out-of-bound read in port timestamping\n - fix peer flow lists corruption\n\n - iwlwifi: fix a memory corruption\n\n Previous releases - always broken:\n\n - netfilter:\n - nft_chain_filter: handle NETDEV_UNREGISTER for inet/ingress\n basechain\n - nft_limit: reject configurations that cause integer overflow\n\n - bpf: fix bpf_xdp_adjust_tail() with XSK zero-copy mbuf', ' avoiding a\n NULL pointer dereference upon shrinking\n\n - llc: make llc_ui_sendmsg() more robust against bonding changes\n\n - smc: fix illegal rmb_desc access in SMC-D connection dump\n\n - dpll: fix pin dump crash for rebound module\n\n - bnxt_en: fix possible crash after creating sw mqprio TCs\n\n - hv_netvsc: calculate correct ring size when PAGE_SIZE is not 4kB\n\n Misc:\n\n - several self-tests fixes for better integration with the netdev CI\n\n - added several missing modules descriptions""\n\n* tag \'net-6.8-rc2\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (88 commits)\n tsnep: Fix XDP_RING_NEED_WAKEUP for empty fill ring\n tsnep: Remove FCS for XDP data path\n net: fec: fix the unhandled context fault from smmu\n selftests: bonding: do not test arp/ns target with mode balance-alb/tlb\n fjes: fix memleaks in fjes_hw_setup\n i40e: update xdp_rxq_info::frag_size for ZC enabled Rx queue\n i40e: set xdp_rxq_info::frag_size\n xdp: reflect tail increase for MEM_TYPE_XSK_BUFF_POOL\n ice: update xdp_rxq_info::frag_size for ZC enabled Rx queue\n intel: xsk: initialize skb_frag_t::bv_offset in ZC drivers\n ice: remove redundant xdp_rxq_info registration\n i40e: handle multi-buffer packets that are shrunk by xdp prog\n ice: work on pre-XDP prog frag count\n xsk: fix usage of multi-buffer BPF helpers for ZC XDP\n xsk: make xsk_buff_pool responsible for clearing xdp_buff::flags\n xsk: recycle buffer in case Rx queue was full\n net: fill in MODULE_DESCRIPTION()s for rvu_mbox\n net: fill in MODULE_DESCRIPTION()s for litex\n net: fill in MODULE_DESCRIPTION()s for fsl_pq_mdio\n net: fill in MODULE_DESCRIPTION()s for fec\n ...\n', '']",Merge networking fixes including BPF improvements in net-6.8-rc2.,"Merge, networking, BPF",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', 'tc/netfilter like programs', 'other']" +fdf8e6d18c6dcc0421d65aa6382f5a4fa0050149,fdf8e6d18c6dcc0421d65aa6382f5a4fa0050149,Paolo Abeni,pabeni@redhat.com,1706178631,Paolo Abeni,pabeni@redhat.com,1706178631,9c1a9a11efd243b907652499fb22b8d5125b947c,5e344807735023cd3a67c37a1852b849caa42620 9d71bc833f57a6549c753e37ce47136d35b67fc4,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-01-25 + +The following pull-request contains BPF updates for your *net* tree. + +We've added 12 non-merge commits during the last 2 day(s) which contain +a total of 13 files changed", 190 insertions(+),"[' 91 deletions(-).\n\nThe main changes are:\n\n1) Fix bpf_xdp_adjust_tail() in context of XSK zero-copy drivers which\n support XDP multi-buffer. The former triggered a NULL pointer\n dereference upon shrinking', ' from Maciej Fijalkowski & Tirthendu Sarkar.\n\n2) Fix a bug in riscv64 BPF JIT which emitted a wrong prologue and\n epilogue for struct_ops programs', "" from Pu Lehui.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n i40e: update xdp_rxq_info::frag_size for ZC enabled Rx queue\n i40e: set xdp_rxq_info::frag_size\n xdp: reflect tail increase for MEM_TYPE_XSK_BUFF_POOL\n ice: update xdp_rxq_info::frag_size for ZC enabled Rx queue\n intel: xsk: initialize skb_frag_t::bv_offset in ZC drivers\n ice: remove redundant xdp_rxq_info registration\n i40e: handle multi-buffer packets that are shrunk by xdp prog\n ice: work on pre-XDP prog frag count\n xsk: fix usage of multi-buffer BPF helpers for ZC XDP\n xsk: make xsk_buff_pool responsible for clearing xdp_buff::flags\n xsk: recycle buffer in case Rx queue was full\n riscv"", ' bpf: Fix unpredictable kernel crash about RV64 struct_ops\n====================\n\nLink: https://lore.kernel.org/r/20240125084416.10876-1-daniel@iogearbox.net\nSigned-off-by: Paolo Abeni \n', '']","Merged BPF updates into the net tree, adding 12 commits over 13 files.","BPF, merge, net",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9d71bc833f57a6549c753e37ce47136d35b67fc4,9d71bc833f57a6549c753e37ce47136d35b67fc4,Alexei Starovoitov,ast@kernel.org,1706142247,Alexei Starovoitov,ast@kernel.org,1706142247,ef22ef695dcfca8d7ce9ac5222ebbd98a634560c,1732ebc4a26181c8f116c7639db99754b313edc8 0cbb08707c932b3f004bc1a8ec6200ef572c1f5f,"Merge branch 'net-bpf_xdp_adjust_tail-and-intel-mbuf-fixes' + +Maciej Fijalkowski says: + +==================== +net: bpf_xdp_adjust_tail() and Intel mbuf fixes + +Hey"," + +after a break followed by dealing with sickness","[' here is a v6 that makes\nbpf_xdp_adjust_tail() actually usable for ZC drivers that support XDP\nmulti-buffer. Since v4 I tried also using bpf_xdp_adjust_tail() with\npositive offset which exposed yet another issues', ' which can be observed\nby increased commit count when compared to v3.\n\nJohn', ' in the end I think we should remove handling\nMEM_TYPE_XSK_BUFF_POOL from __xdp_return()', ' but it is out of the scope\nfor fixes set', ' IMHO.\n\nThanks', '\nMaciej\n\nv6:\n- add acks [Magnus]\n- fix spelling mistakes [Magnus]\n- avoid touching xdp_buff in xp_alloc_{reused', 'new_from_fq}() [Magnus]\n- s/shrink_data/bpf_xdp_shrink_data [Jakub]\n- remove __shrink_data() [Jakub]\n- check retvals from __xdp_rxq_info_reg() [Magnus]\n\nv5:\n- pick correct version of patch 5 [Simon]\n- elaborate a bit more on what patch 2 fixes\n\nv4:\n- do not clear frags flag when deleting tail; xsk_buff_pool now does\n that\n- skip some NULL tests for xsk_buff_get_tail [Martin', ' John]\n- address problems around registering xdp_rxq_info\n- fix bpf_xdp_frags_increase_tail() for ZC mbuf\n\nv3:\n- add acks\n- s/xsk_buff_tail_del/xsk_buff_del_tail\n- address i40e as well (thanks Tirthendu)\n\nv2:\n- fix !CONFIG_XDP_SOCKETS builds\n- add reviewed-by tag to patch 3\n====================\n\nLink: https://lore.kernel.org/r/20240124191602.566724-1-maciej.fijalkowski@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Merge of branch containing fixes for bpf_xdp_adjust_tail and Intel mbuf.,"bpf_xdp_adjust_tail,Intel,fixes",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['xdp like programs'] +fbadd83a612c3b7aad2987893faca6bd24aaebb3,fbadd83a612c3b7aad2987893faca6bd24aaebb3,Maciej Fijalkowski,maciej.fijalkowski@intel.com,1706123760,Alexei Starovoitov,ast@kernel.org,1706142247,d8b7dc0009593267cd7895da2301e00306da5731,3de38c87174225487fc93befeea7d380db80aef6,"xdp: reflect tail increase for MEM_TYPE_XSK_BUFF_POOL + +XSK ZC Rx path calculates the size of data that will be posted to XSK Rx +queue via subtracting xdp_buff::data_end from xdp_buff::data. + +In bpf_xdp_frags_increase_tail()"," when underlying memory type of +xdp_rxq_info is MEM_TYPE_XSK_BUFF_POOL","[' add offset to data_end in tail\nfragment', ' so that later on user space will be able to take into account\nthe amount of bytes added by XDP program.\n\nFixes: 24ea50127ecf (""xsk: support mbuf on ZC RX"")\nSigned-off-by: Maciej Fijalkowski \nLink: https://lore.kernel.org/r/20240124191602.566724-10-maciej.fijalkowski@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Reflects tail increase in XDP path for MEM_TYPE_XSK_BUFF_POOL in XSK zero-copy RX path.,"XDP, XSK, buffer",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['xdp like programs'] +290779905d09d5fdf6caa4f58ddefc3f4db0c0a9,290779905d09d5fdf6caa4f58ddefc3f4db0c0a9,Maciej Fijalkowski,maciej.fijalkowski@intel.com,1706123758,Alexei Starovoitov,ast@kernel.org,1706142247,0ff7833f4804e35e127494553bef3a3b4aa83112,2ee788c06493d02ee85855414cca39825e768aaf,"intel: xsk: initialize skb_frag_t::bv_offset in ZC drivers + +Ice and i40e ZC drivers currently set offset of a frag within +skb_shared_info to 0"," which is incorrect. xdp_buffs that come from +xsk_buff_pool always have 256 bytes of a headroom","[' so they need to be\ntaken into account to retrieve xdp_buff::data via skb_frag_address().\nOtherwise', ' bpf_xdp_frags_increase_tail() would be starting its job from\nxdp_buff::data_hard_start which would result in overwriting existing\npayload.\n\nFixes: 1c9ba9c14658 (""i40e: xsk: add RX multi-buffer support"")\nFixes: 1bbc04de607b (""ice: xsk: add RX multi-buffer support"")\nAcked-by: Magnus Karlsson \nSigned-off-by: Maciej Fijalkowski \nLink: https://lore.kernel.org/r/20240124191602.566724-8-maciej.fijalkowski@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Initialize skb_frag_t::bv_offset in Ice and i40e ZC drivers to ensure correct skb_shared_info handling.,"ZC drivers,skb_frag_t,offset",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['xdp like programs'] +2ee788c06493d02ee85855414cca39825e768aaf,2ee788c06493d02ee85855414cca39825e768aaf,Maciej Fijalkowski,maciej.fijalkowski@intel.com,1706123757,Alexei Starovoitov,ast@kernel.org,1706142246,8aa66f5fcc39f0312c7f261f26268e241bf43c51,83014323c642b8faa2d64a5f303b41c019322478,"ice: remove redundant xdp_rxq_info registration + +xdp_rxq_info struct can be registered by drivers via two functions - +xdp_rxq_info_reg() and __xdp_rxq_info_reg(). The latter one allows +drivers that support XDP multi-buffer to set up xdp_rxq_info::frag_size +which in turn will make it possible to grow the packet via +bpf_xdp_adjust_tail() BPF helper. + +Currently"," ice registers xdp_rxq_info in two spots: +1) ice_setup_rx_ring() // via xdp_rxq_info_reg()","[' BUG\n2) ice_vsi_cfg_rxq() // via __xdp_rxq_info_reg()', ' OK\n\nCited commit under fixes tag took care of setting up frag_size and\nupdated registration scheme in 2) but it did not help as\n1) is called before 2) and as shown above it uses old registration\nfunction. This means that 2) sees that xdp_rxq_info is already\nregistered and never calls __xdp_rxq_info_reg() which leaves us with\nxdp_rxq_info::frag_size being set to 0.\n\nTo fix this misbehavior', ' simply remove xdp_rxq_info_reg() call from\nice_setup_rx_ring().\n\nFixes: 2fba7dc5157b (""ice: Add support for XDP multi-buffer on Rx side"")\nAcked-by: Magnus Karlsson \nSigned-off-by: Maciej Fijalkowski \nLink: https://lore.kernel.org/r/20240124191602.566724-7-maciej.fijalkowski@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Remove redundant xdp_rxq_info registration in the ice driver to optimize XDP multi-buffer usage.,"xdp_rxq_info, ice, XDP",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['xdp like programs'] +83014323c642b8faa2d64a5f303b41c019322478,83014323c642b8faa2d64a5f303b41c019322478,Tirthendu Sarkar,tirthendu.sarkar@intel.com,1706123756,Alexei Starovoitov,ast@kernel.org,1706142246,2bfb6d09ea8288c8c84cafac9b3bd8930d6cba85,ad2047cf5d9313200e308612aed516548873d124,"i40e: handle multi-buffer packets that are shrunk by xdp prog + +XDP programs can shrink packets by calling the bpf_xdp_adjust_tail() +helper function. For multi-buffer packets this may lead to reduction of +frag count stored in skb_shared_info area of the xdp_buff struct. This +results in issues with the current handling of XDP_PASS and XDP_DROP +cases. + +For XDP_PASS"," currently skb is being built using frag count of +xdp_buffer before it was processed by XDP prog and thus will result in +an inconsistent skb when frag count gets reduced by XDP prog. To fix +this","[' get correct frag count while building the skb instead of using\npre-obtained frag count.\n\nFor XDP_DROP', ' current page recycling logic will not reuse the page but\ninstead will adjust the pagecnt_bias so that the page can be freed. This\nagain results in inconsistent behavior as the page refcnt has already\nbeen changed by the helper while freeing the frag(s) as part of\nshrinking the packet. To fix this', ' only adjust pagecnt_bias for buffers\nthat are stillpart of the packet post-xdp prog run.\n\nFixes: e213ced19bef (""i40e: add support for XDP multi-buffer Rx"")\nReported-by: Maciej Fijalkowski \nSigned-off-by: Tirthendu Sarkar \nLink: https://lore.kernel.org/r/20240124191602.566724-6-maciej.fijalkowski@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix handling of multi-buffer packets that are shrunk by XDP programs in the i40e driver.,"XDP, multi-buffer, i40e",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['xdp like programs'] +ad2047cf5d9313200e308612aed516548873d124,ad2047cf5d9313200e308612aed516548873d124,Maciej Fijalkowski,maciej.fijalkowski@intel.com,1706123755,Alexei Starovoitov,ast@kernel.org,1706142246,072a44e3d79d4a2093430b2cc5073aedcd106f3b,c5114710c8ce86b8317e9b448f4fd15c711c2a82,"ice: work on pre-XDP prog frag count + +Fix an OOM panic in XDP_DRV mode when a XDP program shrinks a +multi-buffer packet by 4k bytes and then redirects it to an AF_XDP +socket. + +Since support for handling multi-buffer frames was added to XDP"," usage +of bpf_xdp_adjust_tail() helper within XDP program can free the page +that given fragment occupies and in turn decrease the fragment count +within skb_shared_info that is embedded in xdp_buff struct. In current +ice driver codebase","[' it can become problematic when page recycling logic\ndecides not to reuse the page. In such case', ' __page_frag_cache_drain()\nis used with ice_rx_buf::pagecnt_bias that was not adjusted after\nrefcount of page was changed by XDP prog which in turn does not drain\nthe refcount to 0 and page is never freed.\n\nTo address this', ' let us store the count of frags before the XDP program\nwas executed on Rx ring struct. This will be used to compare with\ncurrent frag count from skb_shared_info embedded in xdp_buff. A smaller\nvalue in the latter indicates that XDP prog freed frag(s). Then', ' for\ngiven delta decrement pagecnt_bias for XDP_DROP verdict.\n\nWhile at it', ' let us also handle the EOP frag within\nice_set_rx_bufs_act() to make our life easier', ' so all of the adjustments\nneeded to be applied against freed frags are performed in the single\nplace.\n\nFixes: 2fba7dc5157b (""ice: Add support for XDP multi-buffer on Rx side"")\nAcked-by: Magnus Karlsson \nSigned-off-by: Maciej Fijalkowski \nLink: https://lore.kernel.org/r/20240124191602.566724-5-maciej.fijalkowski@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes an OOM panic issue when shrinking multi-buffer packets in XDP_DRV mode for the ice driver.,"OOM panic,XDP_DRV,multi-buffer",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['xdp like programs'] +c5114710c8ce86b8317e9b448f4fd15c711c2a82,c5114710c8ce86b8317e9b448f4fd15c711c2a82,Maciej Fijalkowski,maciej.fijalkowski@intel.com,1706123754,Alexei Starovoitov,ast@kernel.org,1706142246,e2ee89bdcbbf9b34c3a32ff0a5fd97bb3dbde6ba,f7f6aa8e24383fbb11ac55942e66da9660110f80,"xsk: fix usage of multi-buffer BPF helpers for ZC XDP + +Currently when packet is shrunk via bpf_xdp_adjust_tail() and memory +type is set to MEM_TYPE_XSK_BUFF_POOL"," null ptr dereference happens: + +[1136314.192256] BUG: kernel NULL pointer dereference","[' address:\n0000000000000034\n[1136314.203943] #PF: supervisor read access in kernel mode\n[1136314.213768] #PF: error_code(0x0000) - not-present page\n[1136314.223550] PGD 0 P4D 0\n[1136314.230684] Oops: 0000 [#1] PREEMPT SMP NOPTI\n[1136314.239621] CPU: 8 PID: 54203 Comm: xdpsock Not tainted 6.6.0+ #257\n[1136314.250469] Hardware name: Intel Corporation S2600WFT/S2600WFT', '\nBIOS SE5C620.86B.02.01.0008.031920191559 03/19/2019\n[1136314.265615] RIP: 0010:__xdp_return+0x6c/0x210\n[1136314.274653] Code: ad 00 48 8b 47 08 49 89 f8 a8 01 0f 85 9b 01 00 00 0f 1f 44 00 00 f0 41 ff 48 34 75 32 4c 89 c7 e9 79 cd 80 ff 83 fe 03 75 17 41 34 01 0f 85 02 01 00 00 48 89 cf e9 22 cc 1e 00 e9 3d d2 86\n[1136314.302907] RSP: 0018:ffffc900089f8db0 EFLAGS: 00010246\n[1136314.312967] RAX: ffffc9003168aed0 RBX: ffff8881c3300000 RCX:\n0000000000000000\n[1136314.324953] RDX: 0000000000000000 RSI: 0000000000000003 RDI:\nffffc9003168c000\n[1136314.336929] RBP: 0000000000000ae0 R08: 0000000000000002 R09:\n0000000000010000\n[1136314.348844] R10: ffffc9000e495000 R11: 0000000000000040 R12:\n0000000000000001\n[1136314.360706] R13: 0000000000000524 R14: ffffc9003168aec0 R15:\n0000000000000001\n[1136314.373298] FS: 00007f8df8bbcb80(0000) GS:ffff8897e0e00000(0000)\nknlGS:0000000000000000\n[1136314.386105] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033\n[1136314.396532] CR2: 0000000000000034 CR3: 00000001aa912002 CR4:\n00000000007706f0\n[1136314.408377] DR0: 0000000000000000 DR1: 0000000000000000 DR2:\n0000000000000000\n[1136314.420173] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7:\n0000000000000400\n[1136314.431890] PKRU: 55555554\n[1136314.439143] Call Trace:\n[1136314.446058] \n[1136314.452465] ? __die+0x20/0x70\n[1136314.459881] ? page_fault_oops+0x15b/0x440\n[1136314.468305] ? exc_page_fault+0x6a/0x150\n[1136314.476491] ? asm_exc_page_fault+0x22/0x30\n[1136314.484927] ? __xdp_return+0x6c/0x210\n[1136314.492863] bpf_xdp_adjust_tail+0x155/0x1d0\n[1136314.501269] bpf_prog_ccc47ae29d3b6570_xdp_sock_prog+0x15/0x60\n[1136314.511263] ice_clean_rx_irq_zc+0x206/0xc60 [ice]\n[1136314.520222] ? ice_xmit_zc+0x6e/0x150 [ice]\n[1136314.528506] ice_napi_poll+0x467/0x670 [ice]\n[1136314.536858] ? ttwu_do_activate.constprop.0+0x8f/0x1a0\n[1136314.546010] __napi_poll+0x29/0x1b0\n[1136314.553462] net_rx_action+0x133/0x270\n[1136314.561619] __do_softirq+0xbe/0x28e\n[1136314.569303] do_softirq+0x3f/0x60\n\nThis comes from __xdp_return() call with xdp_buff argument passed as\nNULL which is supposed to be consumed by xsk_buff_free() call.\n\nTo address this properly', ' in ZC case', ' a node that represents the frag\nbeing removed has to be pulled out of xskb_list. Introduce\nappropriate xsk helpers to do such node operation and use them\naccordingly within bpf_xdp_adjust_tail().\n\nFixes: 24ea50127ecf (""xsk: support mbuf on ZC RX"")\nAcked-by: Magnus Karlsson # For the xsk header part\nSigned-off-by: Maciej Fijalkowski \nLink: https://lore.kernel.org/r/20240124191602.566724-4-maciej.fijalkowski@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes null pointer dereference in xsk multi-buffer BPF helpers for ZC XDP.,"xsk, multi-buffer, BPF helpers",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['xdp like programs'] +f7f6aa8e24383fbb11ac55942e66da9660110f80,f7f6aa8e24383fbb11ac55942e66da9660110f80,Maciej Fijalkowski,maciej.fijalkowski@intel.com,1706123753,Alexei Starovoitov,ast@kernel.org,1706142246,81c548183db7e624ea9b3287a8cc5041a3ea831d,269009893146c495f41e9572dd9319e787c2eba9,"xsk: make xsk_buff_pool responsible for clearing xdp_buff::flags + +XDP multi-buffer support introduced XDP_FLAGS_HAS_FRAGS flag that is +used by drivers to notify data path whether xdp_buff contains fragments +or not. Data path looks up mentioned flag on first buffer that occupies +the linear part of xdp_buff"," so drivers only modify it there. This is +sufficient for SKB and XDP_DRV modes as usually xdp_buff is allocated on +stack or it resides within struct representing driver's queue and +fragments are carried via skb_frag_t structs. IOW","[' we are dealing with\nonly one xdp_buff.\n\nZC mode though relies on list of xdp_buff structs that is carried via\nxsk_buff_pool::xskb_list', ' so ZC data path has to make sure that\nfragments do *not* have XDP_FLAGS_HAS_FRAGS set. Otherwise', '\nxsk_buff_free() could misbehave if it would be executed against xdp_buff\nthat carries a frag with XDP_FLAGS_HAS_FRAGS flag set. Such scenario can\ntake place when within supplied XDP program bpf_xdp_adjust_tail() is\nused with negative offset that would in turn release the tail fragment\nfrom multi-buffer frame.\n\nCalling xsk_buff_free() on tail fragment with XDP_FLAGS_HAS_FRAGS would\nresult in releasing all the nodes from xskb_list that were produced by\ndriver before XDP program execution', ' which is not what is intended -\nonly tail fragment should be deleted from xskb_list and then it should\nbe put onto xsk_buff_pool::free_list. Such multi-buffer frame will never\nmake it up to user space', ' so from AF_XDP application POV there would be\nno traffic running', ' however due to free_list getting constantly new\nnodes', ' driver will be able to feed HW Rx queue with recycled buffers.\nBottom line is that instead of traffic being redirected to user space', '\nit would be continuously dropped.\n\nTo fix this', ' let us clear the mentioned flag on xsk_buff_pool side\nduring xdp_buff initialization', ' which is what should have been done\nright from the start of XSK multi-buffer support.\n\nFixes: 1bbc04de607b (""ice: xsk: add RX multi-buffer support"")\nFixes: 1c9ba9c14658 (""i40e: xsk: add RX multi-buffer support"")\nFixes: 24ea50127ecf (""xsk: support mbuf on ZC RX"")\nSigned-off-by: Maciej Fijalkowski \nLink: https://lore.kernel.org/r/20240124191602.566724-3-maciej.fijalkowski@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit ensures xsk_buff_pool handles the clearing of xdp_buff::flags for XDP multi-buffer support.,"xdp_buff, xsk_buff_pool, flags",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['xdp like programs'] +c8632acf193beac64bbdaebef013368c480bf74f,c8632acf193beac64bbdaebef013368c480bf74f,Andrii Nakryiko,andrii@kernel.org,1706125378,Alexei Starovoitov,ast@kernel.org,1706142063,d9b85c5c1cc0518b3c7d98fbd814a4aa51b636d5,c9f115564561af63db662791e9a35fcf1dfefd2a 906ee42cb1be1152ef24465704cc89edc3f571c1,"Merge branch 'bpf-token' + +Andrii Nakryiko says: + +==================== +BPF token + +This patch set is a combination of three BPF token-related patch sets ([0]"," +[1]","[' [2]) with fixes ([3]) to kernel-side token_fd passing APIs incorporated\ninto relevant patches', ' bpf_token_capable() changes requested by\nChristian Brauner', ' and necessary libbpf and BPF selftests side adjustments.\n\nThis patch set introduces an ability to delegate a subset of BPF subsystem\nfunctionality from privileged system-wide daemon (e.g.', ' systemd or any other\ncontainer manager) through special mount options for userns-bound BPF FS to\na *trusted* unprivileged application. Trust is the key here. This\nfunctionality is not about allowing unconditional unprivileged BPF usage.\nEstablishing trust', ' though', ' is completely up to the discretion of respective\nprivileged application that would create and mount a BPF FS instance with\ndelegation enabled', ' as different production setups can and do achieve it\nthrough a combination of different means (signing', ' LSM', ' code reviews', ' etc)', ""\nand it's undesirable and infeasible for kernel to enforce any particular way\nof validating trustworthiness of particular process.\n\nThe main motivation for this work is a desire to enable containerized BPF\napplications to be used together with user namespaces. This is currently\nimpossible"", ' as CAP_BPF', ' required for BPF subsystem usage', ' cannot be namespaced\nor sandboxed', ' as a general rule. E.g.', ' tracing BPF programs', ' thanks to BPF\nhelpers like bpf_probe_read_kernel() and bpf_probe_read_user() can safely read\narbitrary memory', "" and it's impossible to ensure that they only read memory of\nprocesses belonging to any given namespace. This means that it's impossible to\nhave a mechanically verifiable namespace-aware CAP_BPF capability"", ' and as such\nanother mechanism to allow safe usage of BPF functionality is necessary.\n\nBPF FS delegation mount options and BPF token derived from such BPF FS instance\nis such a mechanism. Kernel makes no assumption about what ""trusted""\nconstitutes in any particular case', "" and it's up to specific privileged\napplications and their surrounding infrastructure to decide that. What kernel\nprovides is a set of APIs to setup and mount special BPF FS instance and\nderive BPF tokens from it. BPF FS and BPF token are both bound to its owning\nuserns and in such a way are constrained inside intended container. Users can\nthen pass BPF token FD to privileged bpf() syscall commands"", ' like BPF map\ncreation and BPF program loading', ' to perform such operations without having\ninit userns privileges.\n\nThis version incorporates feedback and suggestions ([4]) received on earlier\niterations of BPF token approach', ' and instead of allowing to create BPF tokens\ndirectly assuming capable(CAP_SYS_ADMIN)', ' we instead enhance BPF FS to accept\na few new delegation mount options. If these options are used and BPF FS itself\nis properly created', ' set up', ' and mounted inside the user namespaced container', '\nuser application is able to derive a BPF token object from BPF FS instance', ' and\npass that token to bpf() syscall. As explained in patch #3', "" BPF token itself\ndoesn't grant access to BPF functionality"", ' but instead allows kernel to do\nnamespaced capabilities checks (ns_capable() vs capable()) for CAP_BPF', '\nCAP_PERFMON', ' CAP_NET_ADMIN', ' and CAP_SYS_ADMIN', ' as applicable. So it forms one\nhalf of a puzzle and allows container managers and sys admins to have safe and\nflexible configuration options: determining which containers get delegation of\nBPF functionality through BPF FS', ' and then which applications within such\ncontainers are allowed to perform bpf() commands', ' based on namespaces\ncapabilities.\n\nPrevious attempt at addressing this very same problem ([5]) attempted to\nutilize authoritative LSM approach', ' but was conclusively rejected by upstream\nLSM maintainers. BPF token concept is not changing anything about LSM\napproach', ' but can be combined with LSM hooks for very fine-grained security\npolicy. Some ideas about making BPF token more convenient to use with LSM (in\nparticular custom BPF LSM programs) was briefly described in recent LSF/MM/BPF\n2023 presentation ([6]). E.g.', ' an ability to specify user-provided data\n(context)', ' which in combination with BPF LSM would allow implementing a very\ndynamic and fine-granular custom security policies on top of BPF token. In the\ninterest of minimizing API surface area and discussions this was relegated to\nfollow up patches', "" as it's not essential to the fundamental concept of\ndelegatable BPF token.\n\nIt should be noted that BPF token is conceptually quite similar to the idea of\n/dev/bpf device file"", ' proposed by Song a while ago ([7]). The biggest\ndifference is the idea of using virtual anon_inode file to hold BPF token and\nallowing multiple independent instances of them', ' each (potentially) with its\nown set of restrictions. And also', ' crucially', ' BPF token approach is not using\nany special stateful task-scoped flags. Instead', ' bpf() syscall accepts\ntoken_fd parameters explicitly for each relevant BPF command. This addresses\nmain concerns brought up during the /dev/bpf discussion', "" and fits better with\noverall BPF subsystem design.\n\nSecond part of this patch set adds full support for BPF token in libbpf's BPF\nobject high-level API. Good chunk of the changes rework libbpf feature\ndetection internals"", ' which are the most affected by BPF token presence.\n\nBesides internal refactorings', ' libbpf allows to pass location of BPF FS from\nwhich BPF token should be created by libbpf. This can be done explicitly though\na new bpf_object_open_opts.bpf_token_path field. But we also add implicit BPF\ntoken creation logic to BPF object load step', ' even without any explicit\ninvolvement of the user. If the environment is setup properly', ' BPF token will\nbe created transparently and used implicitly. This allows for all existing\napplication to gain BPF token support by just linking with latest version of\nlibbpf library. No source code modifications are required. All that under\nassumption that privileged container management agent properly set up default\nBPF FS instance at /sys/bpf/fs to allow BPF token creation.\n\nlibbpf adds support to override default BPF FS location for BPF token creation\nthrough LIBBPF_BPF_TOKEN_PATH envvar knowledge. This allows admins or container\nmanagers to mount BPF token-enabled BPF FS at non-standard location without the\nneed to coordinate with applications. LIBBPF_BPF_TOKEN_PATH can also be used\nto disable BPF token implicit creation by setting it to an empty value.\n\n [0] https://patchwork.kernel.org/project/netdevbpf/list/?series=805707&state=*\n [1] https://patchwork.kernel.org/project/netdevbpf/list/?series=810260&state=*\n [2] https://patchwork.kernel.org/project/netdevbpf/list/?series=809800&state=*\n [3] https://patchwork.kernel.org/project/netdevbpf/patch/20231219053150.336991-1-andrii@kernel.org/\n [4] https://lore.kernel.org/bpf/20230704-hochverdient-lehne-eeb9eeef785e@brauner/\n [5] https://lore.kernel.org/bpf/20230412043300.360803-1-andrii@kernel.org/\n [6] http://vger.kernel.org/bpfconf2023_material/Trusted_unprivileged_BPF_LSFMM2023.pdf\n [7] https://lore.kernel.org/bpf/20190627201923.2589391-2-songliubraving@fb.com/\n\nv1->v2:\n - disable BPF token creation in init userns', ' and simplify\n bpf_token_capable() logic (Christian);\n - use kzalloc/kfree instead of kvzalloc/kvfree (Linus);\n - few more selftest cases to validate LSM and BPF token interations.\n\nSigned-off-by: Andrii Nakryiko \n====================\n\nLink: https://lore.kernel.org/r/20240124022127.2379740-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Merge and integrate BPF token-related patch sets into the main branch.,"BPF, token, merge",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +906ee42cb1be1152ef24465704cc89edc3f571c1,906ee42cb1be1152ef24465704cc89edc3f571c1,Andrii Nakryiko,andrii@kernel.org,1706062887,Alexei Starovoitov,ast@kernel.org,1706142063,d9b85c5c1cc0518b3c7d98fbd814a4aa51b636d5,fadf54935e859c4d512aed6ad54f639b87a3b4d3,"selftests/bpf: Incorporate LSM policy to token-based tests + +Add tests for LSM interactions (both bpf_token_capable and bpf_token_cmd +LSM hooks) with BPF token in bpf() subsystem. Now child process passes +back token FD for parent to be able to do tests with token originating +in ""wrong"" userns. But we also create token in initns and check that +token LSMs don't accidentally reject BPF operations when capable() +checks pass without BPF token. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-31-andrii@kernel.org +",,Adds tests for LSM interactions with BPF tokens in the bpf() subsystem.,"LSM,bpf,tests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['LSM like programs'] +fadf54935e859c4d512aed6ad54f639b87a3b4d3,fadf54935e859c4d512aed6ad54f639b87a3b4d3,Andrii Nakryiko,andrii@kernel.org,1706062886,Alexei Starovoitov,ast@kernel.org,1706142063,04bafd43cb6fe0948b896ff162971f681cfc5994,cac270ad79afe212ed7986e8d271c72521cd8212,"selftests/bpf: Add tests for LIBBPF_BPF_TOKEN_PATH envvar + +Add new subtest validating LIBBPF_BPF_TOKEN_PATH envvar semantics. +Extend existing test to validate that LIBBPF_BPF_TOKEN_PATH allows to +disable implicit BPF token creation by setting envvar to empty string. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-30-andrii@kernel.org +",,Add new tests for validating LIBBPF_BPF_TOKEN_PATH environment variable semantics in selftests.,"selftests,BPF,LIBBPF",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cac270ad79afe212ed7986e8d271c72521cd8212,cac270ad79afe212ed7986e8d271c72521cd8212,Andrii Nakryiko,andrii@kernel.org,1706062885,Alexei Starovoitov,ast@kernel.org,1706142063,704597af62843f5a714b1c4668bf3d8ed2d81220,b73d08d1318a2dde5bacbab77d0e2fd2aa47c933,"libbpf: Support BPF token path setting through LIBBPF_BPF_TOKEN_PATH envvar + +To allow external admin authority to override default BPF FS location +(/sys/fs/bpf) for implicit BPF token creation"," teach libbpf to recognize +LIBBPF_BPF_TOKEN_PATH envvar. If it is specified and user application +didn't explicitly specify bpf_token_path option","[' it will be treated\nexactly like bpf_token_path option', ' overriding default /sys/fs/bpf\nlocation and making BPF token mandatory.\n\nSuggested-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-29-andrii@kernel.org\n', '']",Add support for setting BPF token path via LIBBPF_BPF_TOKEN_PATH environment variable in libbpf.,"libbpf, envvar, BPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b73d08d1318a2dde5bacbab77d0e2fd2aa47c933,b73d08d1318a2dde5bacbab77d0e2fd2aa47c933,Andrii Nakryiko,andrii@kernel.org,1706062884,Alexei Starovoitov,ast@kernel.org,1706142063,0809ecfbdc0da2d20074ffb45e140dab820c7d54,d5baf0cac627fb3a00d9235955a388e5930b6d0e,"selftests/bpf: Add tests for BPF object load with implicit token + +Add a test to validate libbpf's implicit BPF token creation from default +BPF FS location (/sys/fs/bpf). Also validate that disabling this +implicit BPF token creation works. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-28-andrii@kernel.org +",,Add tests for validating implicit BPF token creation and disabling in libbpf.,"tests, implicit token, libbpf",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d5baf0cac627fb3a00d9235955a388e5930b6d0e,d5baf0cac627fb3a00d9235955a388e5930b6d0e,Andrii Nakryiko,andrii@kernel.org,1706062883,Alexei Starovoitov,ast@kernel.org,1706142063,4cd6e9ced35654a88e0658976f8cf7fd1a39d63e,6b434b61b4d9e0e59f2947ce0f58f6fb4de048d8,"selftests/bpf: Add BPF object loading tests with explicit token passing + +Add a few tests that attempt to load BPF object containing privileged +map", program,"[' and the one requiring mandatory BTF uploading into the\nkernel (to validate token FD propagation to BPF_BTF_LOAD command).\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-27-andrii@kernel.org\n', '']",Add tests to load BPF objects with explicit token passing in selftests.,"tests,BPF object,token passing",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6b434b61b4d9e0e59f2947ce0f58f6fb4de048d8,6b434b61b4d9e0e59f2947ce0f58f6fb4de048d8,Andrii Nakryiko,andrii@kernel.org,1706062882,Alexei Starovoitov,ast@kernel.org,1706142062,a0bcb278e5e454b2f0d16c1a38d265348f928364,f3dcee938f485cf403ba2acf1f1548afe637c904,"libbpf: Wire up BPF token support at BPF object level + +Add BPF token support to BPF object-level functionality. + +BPF token is supported by BPF object logic either as an explicitly +provided BPF token from outside (through BPF FS path)"," or implicitly +(unless prevented through bpf_object_open_opts). + +Implicit mode is assumed to be the most common one for user namespaced +unprivileged workloads. The assumption is that privileged container +manager sets up default BPF FS mount point at /sys/fs/bpf with BPF token +delegation options (delegate_{cmds","['maps', 'progs', 'attachs} mount options).\nBPF object during loading will attempt to create BPF token from\n/sys/fs/bpf location', ' and pass it for all relevant operations\n(currently', ' map creation', ' BTF load', ' and program load).\n\nIn this implicit mode', ' if BPF token creation fails due to whatever\nreason (BPF FS is not mounted', "" or kernel doesn't support BPF token"", '\netc)', ' this is not considered an error. BPF object loading sequence will\nproceed with no BPF token.\n\nIn explicit BPF token mode', ' user provides explicitly custom BPF FS mount\npoint path. In such case', ' BPF object will attempt to create BPF token\nfrom provided BPF FS location. If BPF token creation fails', ' that is\nconsidered a critical error and BPF object load fails with an error.\n\nLibbpf provides a way to disable implicit BPF token creation', "" if it\ncauses any troubles (BPF token is designed to be completely optional and\nshouldn't cause any problems even if provided"", ' but in the world of BPF\nLSM', "" custom security logic can be installed that might change outcome\ndepending on the presence of BPF token). To disable libbpf's default BPF\ntoken creation behavior user should provide either invalid BPF token FD\n(negative)"", "" or empty bpf_token_path option.\n\nBPF token presence can influence libbpf's feature probing"", ' so if BPF\nobject has associated BPF token', ' feature probing is instructed to use\nBPF object-specific feature detection cache and token FD.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-26-andrii@kernel.org\n', '']",Add support for BPF token at the BPF object level in libbpf.,"BPF token, BPF object, libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f3dcee938f485cf403ba2acf1f1548afe637c904,f3dcee938f485cf403ba2acf1f1548afe637c904,Andrii Nakryiko,andrii@kernel.org,1706062881,Alexei Starovoitov,ast@kernel.org,1706142062,8bdb88a3455d9395770e6cca76eee597453bd33e,05f9cdd55d61cf9c6283fd3dc0edc7cad09bd7fe,"libbpf: Wire up token_fd into feature probing logic + +Adjust feature probing callbacks to take into account optional token_fd. +In unprivileged contexts"," some feature detectors would fail to detect +kernel support just because BPF program","[' BPF map', "" or BTF object can't be\nloaded due to privileged nature of those operations. So when BPF object\nis loaded with BPF token"", ' this token should be used for feature probing.\n\nThis patch is setting support for this scenario', "" but we don't yet pass\nnon-zero token FD. This will be added in the next patch.\n\nWe also switched BPF cookie detector from using kprobe program to\ntracepoint one"", ' as tracepoint is somewhat less dangerous BPF program\ntype and has higher likelihood of being allowed through BPF token in the\nfuture. This change has no effect on detection behavior.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-25-andrii@kernel.org\n', '']",Adjust feature probing logic to incorporate optional token_fd in unprivileged contexts.,"libbpf, token_fd, feature-probing",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +05f9cdd55d61cf9c6283fd3dc0edc7cad09bd7fe,05f9cdd55d61cf9c6283fd3dc0edc7cad09bd7fe,Andrii Nakryiko,andrii@kernel.org,1706062880,Alexei Starovoitov,ast@kernel.org,1706142062,beee721bec04ba2a6e3e9a21adfd8183827ca4d3,d6dd1d49367ab03832b3c4b6f8211765d488c82b,"libbpf: Move feature detection code into its own file + +It's quite a lot of well isolated code"," so it seems like a good +candidate to move it out of libbpf.c to reduce its size. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-24-andrii@kernel.org +",[''],Refactored libbpf by moving feature detection code to a separate file to reduce libbpf.c size.,"libbpf,refactoring,feature detection",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d6dd1d49367ab03832b3c4b6f8211765d488c82b,d6dd1d49367ab03832b3c4b6f8211765d488c82b,Andrii Nakryiko,andrii@kernel.org,1706062879,Alexei Starovoitov,ast@kernel.org,1706142062,09255745717e9116be414f12956f0e854eb15dde,ea4d587354eb5e32dfa93cebb055b072f518b193,"libbpf: Further decouple feature checking logic from bpf_object + +Add feat_supported() helper that accepts feature cache instead of +bpf_object. This allows low-level code in bpf.c to not know or care +about higher-level concept of bpf_object"," yet it will be able to utilize +custom feature checking in cases where BPF token might influence the +outcome. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-23-andrii@kernel.org +",[''],The commit adds a feat_supported() helper to decouple feature checking logic from bpf_object in libbpf.,"feat_supported, feature checking, libbpf",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ea4d587354eb5e32dfa93cebb055b072f518b193,ea4d587354eb5e32dfa93cebb055b072f518b193,Andrii Nakryiko,andrii@kernel.org,1706062878,Alexei Starovoitov,ast@kernel.org,1706142062,c017487dd6721f90b5be6d2be7b78aba4ddedf17,0350f9d99ee538f2ccf179f0216e704a5f39b317,"libbpf: Split feature detectors definitions from cached results + +Split a list of supported feature detectors with their corresponding +callbacks from actual cached supported/missing values. This will allow +to have more flexible per-token or per-object feature detectors in +subsequent refactorings. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-22-andrii@kernel.org +",,The commit refactors libbpf feature detectors to separate definitions from cached results for improved flexibility.,"libbpf,refactoring,feature detectors",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0350f9d99ee538f2ccf179f0216e704a5f39b317,0350f9d99ee538f2ccf179f0216e704a5f39b317,Andrii Nakryiko,andrii@kernel.org,1706062877,Alexei Starovoitov,ast@kernel.org,1706142062,8b393c90f699150e64a07a9e1eae7d15cc6707ca,6c1752e0b6ca8c7021d6da3926738d8d88f601a9,"selftests/bpf: Utilize string values for delegate_xxx mount options + +Use both hex-based and string-based way to specify delegate mount +options for BPF FS. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20240124022127.2379740-21-andrii@kernel.org +",,The commit updates selftests to support string values for delegate mount options in BPF file system.,"selftests, BPF FS, mount options",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6c1752e0b6ca8c7021d6da3926738d8d88f601a9,6c1752e0b6ca8c7021d6da3926738d8d88f601a9,Andrii Nakryiko,andrii@kernel.org,1706062876,Alexei Starovoitov,ast@kernel.org,1706142062,c5c26149ea47fdc30c6d7395c71878b9fcf03968,aeaa97b006ddc7a8bf13e4adfdd02b3526f648a7,"bpf: Support symbolic BPF FS delegation mount options + +Besides already supported special ""any"" value and hex bit mask"," support +string-based parsing of delegation masks based on exact enumerator +names. Utilize BTF information of `enum bpf_cmd`","[' `enum bpf_map_type`', '\n`enum bpf_prog_type`', ' and `enum bpf_attach_type` types to find supported\nsymbolic names (ignoring __MAX_xxx guard values and stripping repetitive\nprefixes like BPF_ for cmd and attach types', ' BPF_MAP_TYPE_ for maps', "" and\nBPF_PROG_TYPE_ for prog types). The case doesn't matter"", ' but it is\nnormalized to lower case in mount option output. So ""PROG_LOAD""', '\n""prog_load""', ' and ""MAP_create"" are all valid values to specify for\ndelegate_cmds options', ' ""array"" is among supported for map types', ' etc.\n\nBesides supporting string values', ' we also support multiple values\nspecified at the same time', "" using colon (':') separator.\n\nThere are corresponding changes on bpf_show_options side to use known\nvalues to print them in human-readable format"", ' falling back to hex mask\nprinting', "" if there are any unrecognized bits. This shouldn't be\nnecessary when enum BTF information is present"", ' but in general we should\nalways be able to fall back to this even if kernel was built without BTF.\nAs mentioned', ' emitted symbolic names are normalized to be all lower case.\n\nExample below shows various ways to specify delegate_cmds options\nthrough mount command and how mount options are printed back:\n\n12/14 14:39:07.604\nvmuser@archvm:~/local/linux/tools/testing/selftests/bpf\n$ mount | rg token\n\n $ sudo mkdir -p /sys/fs/bpf/token\n $ sudo mount -t bpf bpffs /sys/fs/bpf/token \\\n -o delegate_cmds=prog_load:MAP_CREATE \\\n -o delegate_progs=kprobe \\\n -o delegate_attachs=xdp\n $ mount | grep token\n bpffs on /sys/fs/bpf/token type bpf (rw', 'relatime', 'delegate_cmds=map_create:prog_load', 'delegate_progs=kprobe', 'delegate_attachs=xdp)\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-20-andrii@kernel.org\n', '']",Enhance BPF FS mount options to support symbolic delegation masks using BTF enum information.,"BPF, symbolic, delegation",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +aeaa97b006ddc7a8bf13e4adfdd02b3526f648a7,aeaa97b006ddc7a8bf13e4adfdd02b3526f648a7,Andrii Nakryiko,andrii@kernel.org,1706062875,Alexei Starovoitov,ast@kernel.org,1706142062,b3ccdcf15c0f24c2ba9ecaf3d3b1808984dfefaa,0054493e5141b16e316b8c52d6aa534397e48b6c,"bpf: Fail BPF_TOKEN_CREATE if no delegation option was set on BPF FS + +It's quite confusing in practice when it's possible to successfully +create a BPF token from BPF FS that didn't have any of delegate_xxx +mount options set up. While it's not wrong"," it's actually more +meaningful to reject BPF_TOKEN_CREATE with specific error code (-ENOENT) +to let user-space know that no token delegation is setup up. + +So","["" instead of creating empty BPF token that will be always ignored\nbecause it doesn't have any of the allow_xxx bits set"", ' reject it with\n-ENOENT. If we ever need empty BPF token to be possible', ' we can support\nthat with extra flag passed into BPF_TOKEN_CREATE.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: Christian Brauner \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-19-andrii@kernel.org\n', '']",Fail BPF_TOKEN_CREATE if no delegation option is set on BPF FS to provide meaningful user-space error.,"BPF_TOKEN_CREATE,delegation,ENOENT",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0054493e5141b16e316b8c52d6aa534397e48b6c,0054493e5141b16e316b8c52d6aa534397e48b6c,Andrii Nakryiko,andrii@kernel.org,1706062874,Alexei Starovoitov,ast@kernel.org,1706142062,045ff7cf45922b3eeeca0ddfc2ee440666f9519f,fcb9597ff7d1f7c772c1237dd2d04dd44e622501,bpf,"selinux: Allocate bpf_security_struct per BPF token + +Utilize newly added bpf_token_create/bpf_token_free LSM hooks to +allocate struct bpf_security_struct for each BPF token object in +SELinux. This just follows similar pattern for BPF prog and map. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-18-andrii@kernel.org +",[''],Add LSM hooks to allocate security structure for BPF token objects in SELinux.,"LSM hooks, SELinux, BPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['LSM like programs'] +fcb9597ff7d1f7c772c1237dd2d04dd44e622501,fcb9597ff7d1f7c772c1237dd2d04dd44e622501,Andrii Nakryiko,andrii@kernel.org,1706062873,Alexei Starovoitov,ast@kernel.org,1706142062,dc73432da5e07a162b44ab6c0636b10ea2e2aa9e,404cbc149c3866e6ec2bfe1bce52c8864e1f81fc,"selftests/bpf: Add BPF token-enabled tests + +Add a selftest that attempts to conceptually replicate intended BPF +token use cases inside user namespaced container. + +Child process is forked. It is then put into its own userns and mountns. +Child creates BPF FS context object. This ensures child userns is +captured as the owning userns for this instance of BPF FS. Given setting +delegation mount options is privileged operation"," we ensure that child +cannot set them. + +This context is passed back to privileged parent process through Unix +socket","[' where parent sets up delegation options', ' creates', ' and mounts it\nas a detached mount. This mount FD is passed back to the child to be\nused for BPF token creation', ' which allows otherwise privileged BPF\noperations to succeed inside userns.\n\nWe validate that all of token-enabled privileged commands (BPF_BTF_LOAD', '\nBPF_MAP_CREATE', ' and BPF_PROG_LOAD) work as intended. They should only\nsucceed inside the userns if a) BPF token is provided with proper\nallowed sets of commands and types; and b) namespaces CAP_BPF and other\nprivileges are set. Lacking a) or b) should lead to -EPERM failures.\n\nBased on suggested workflow by Christian Brauner ([0]).\n\n [0] https://lore.kernel.org/bpf/20230704-hochverdient-lehne-eeb9eeef785e@brauner/\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-17-andrii@kernel.org\n', '']",This commit adds selftests for BPF token use cases within user namespaced containers.,"selftests,BPF,userns",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +404cbc149c3866e6ec2bfe1bce52c8864e1f81fc,404cbc149c3866e6ec2bfe1bce52c8864e1f81fc,Andrii Nakryiko,andrii@kernel.org,1706062872,Alexei Starovoitov,ast@kernel.org,1706142062,49a6a98483bd7c85310c86a867a735fb7c747f83,a3d63e85253b6c9b6aa34b99208e835358a91320,"libbpf: Add BPF token support to bpf_prog_load() API + +Wire through token_fd into bpf_prog_load(). + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-16-andrii@kernel.org +",,Add BPF token support in libbpf library's bpf_prog_load() API.,"BPF token support, bpf_prog_load, libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a3d63e85253b6c9b6aa34b99208e835358a91320,a3d63e85253b6c9b6aa34b99208e835358a91320,Andrii Nakryiko,andrii@kernel.org,1706062871,Alexei Starovoitov,ast@kernel.org,1706142062,fdf847731b6ff09709d6974714e7a49a48dd241f,364f848375af311150210a1ad3c5bcb800b65b48,"libbpf: Add BPF token support to bpf_btf_load() API + +Allow user to specify token_fd for bpf_btf_load() API that wraps +kernel's BPF_BTF_LOAD command. This allows loading BTF from unprivileged +process as long as it has BPF token allowing BPF_BTF_LOAD command"," which +can be created and delegated by privileged process. + +Wire through new btf_flags as well","[' so that user can provide\nBPF_F_TOKEN_FD flag', ' if necessary.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-15-andrii@kernel.org\n', '']",Adds BPF token support to the bpf_btf_load() API for unprivileged process access to BPF_BTF_LOAD.,"BPF token support, bpf_btf_load API, unprivileged access",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +364f848375af311150210a1ad3c5bcb800b65b48,364f848375af311150210a1ad3c5bcb800b65b48,Andrii Nakryiko,andrii@kernel.org,1706062870,Alexei Starovoitov,ast@kernel.org,1706142061,acdf69ee43fa21a47b81f24c6f0e961382ca5a91,639ecd7d6247c48a0175f5b458b648f5d4b6dc34,"libbpf: Add BPF token support to bpf_map_create() API + +Add ability to provide token_fd for BPF_MAP_CREATE command through +bpf_map_create() API. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-14-andrii@kernel.org +",,Added support for providing token_fd in BPF_MAP_CREATE using bpf_map_create() API in libbpf.,"libbpf, BPF token, bpf_map_create",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +639ecd7d6247c48a0175f5b458b648f5d4b6dc34,639ecd7d6247c48a0175f5b458b648f5d4b6dc34,Andrii Nakryiko,andrii@kernel.org,1706062869,Alexei Starovoitov,ast@kernel.org,1706142061,1ebb6c82e96c2b0fd9af87770ce333c6be45191e,f568a3d49af9aed813a184353592efe29b0e3d16,"libbpf: Add bpf_token_create() API + +Add low-level wrapper API for BPF_TOKEN_CREATE command in bpf() syscall. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-13-andrii@kernel.org +",,Introduced bpf_token_create() API as a low-level wrapper for BPF_TOKEN_CREATE syscall.,"bpf_token_create, API, syscall",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f568a3d49af9aed813a184353592efe29b0e3d16,f568a3d49af9aed813a184353592efe29b0e3d16,Andrii Nakryiko,andrii@kernel.org,1706062868,Alexei Starovoitov,ast@kernel.org,1706142061,0a3490cd91384780d1c045b2c5df6b7904f53384,a2431c7eabcf9bd5a1e7a1f7ecded40fdda4a8c5,bpf,"lsm: Add BPF token LSM hooks + +Wire up bpf_token_create and bpf_token_free LSM hooks","[' which allow to\nallocate LSM security blob (we add `void *security` field to struct\nbpf_token for that)', "" but also control who can instantiate BPF token.\nThis follows existing pattern for BPF map and BPF prog.\n\nAlso add security_bpf_token_allow_cmd() and security_bpf_token_capable()\nLSM hooks that allow LSM implementation to control and negate (if\nnecessary) BPF token's delegation of a specific bpf_cmd and capability"", '\nrespectively.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: Paul Moore \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-12-andrii@kernel.org\n', '']",Introduce LSM hooks for bpf_token_create and bpf_token_free in BPF.,"LSM hooks, bpf_token_create, bpf_token_free",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['LSM like programs'] +a2431c7eabcf9bd5a1e7a1f7ecded40fdda4a8c5,a2431c7eabcf9bd5a1e7a1f7ecded40fdda4a8c5,Andrii Nakryiko,andrii@kernel.org,1706062867,Alexei Starovoitov,ast@kernel.org,1706142061,fff1b6e0aa61984bc2c2aea9ddaac2a1b95780f9,1b67772e4e3f16cd647b229cae95fc06d120be08,bpf,"lsm: Refactor bpf_map_alloc/bpf_map_free LSM hooks + +Similarly to bpf_prog_alloc LSM hook","[' rename and extend bpf_map_alloc\nhook into bpf_map_create', ' taking not just struct bpf_map', ' but also\nbpf_attr and bpf_token', ' to give a fuller context to LSMs.\n\nUnlike bpf_prog_alloc', ' there is no need to move the hook around', ' as it\ncurrently is firing right before allocating BPF map ID and FD', ' which\nseems to be a sweet spot.\n\nBut like bpf_prog_alloc/bpf_prog_free combo', ' make sure that bpf_map_free\nLSM hook is called even if bpf_map_create hook returned error', ' as if few\nLSMs are combined together it could be that one LSM successfully\nallocated security blob for its needs', ' while subsequent LSM rejected BPF\nmap creation. The former LSM would still need to free up LSM blob', ' so we\nneed to ensure security_bpf_map_free() is called regardless of the\noutcome.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: Paul Moore \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-11-andrii@kernel.org\n', '']",Refactor bpf_map_alloc and bpf_map_free LSM hooks for consistency with bpf_prog_alloc.,"refactor,bpf_map_alloc,LSM",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['LSM like programs'] +1b67772e4e3f16cd647b229cae95fc06d120be08,1b67772e4e3f16cd647b229cae95fc06d120be08,Andrii Nakryiko,andrii@kernel.org,1706062866,Alexei Starovoitov,ast@kernel.org,1706142061,a6d7ab948fcd8d3f138e2f7b67fcf4c0cfe18a45,d79a3549754725bb90e58104417449edddf3da3d,bpf,"lsm: Refactor bpf_prog_alloc/bpf_prog_free LSM hooks + +Based on upstream discussion ([0])","[' rework existing\nbpf_prog_alloc_security LSM hook. Rename it to bpf_prog_load and instead\nof passing bpf_prog_aux', ' pass proper bpf_prog pointer for a full BPF\nprogram struct. Also', ' we pass bpf_attr union with all the user-provided\narguments for BPF_PROG_LOAD command. This will give LSMs as much\ninformation as we can basically provide.\n\nThe hook is also BPF token-aware now', ' and optional bpf_token struct is\npassed as a third argument. bpf_prog_load LSM hook is called after\na bunch of sanity checks were performed', ' bpf_prog and bpf_prog_aux were\nallocated and filled out', ' but right before performing full-fledged BPF\nverification step.\n\nbpf_prog_free LSM hook is now accepting struct bpf_prog argument', ' for\nconsistency. SELinux code is adjusted to all new names', ' types', ' and\nsignatures.\n\nNote', ' given that bpf_prog_load (previously bpf_prog_alloc) hook can be\nused by some LSMs to allocate extra security blob', ' but also by other\nLSMs to reject BPF program loading', "" we need to make sure that\nbpf_prog_free LSM hook is called after bpf_prog_load/bpf_prog_alloc one\n*even* if the hook itself returned error. If we don't do that"", ' we run\nthe risk of leaking memory. This seems to be possible today when\ncombining SELinux and BPF LSM', ' as one example', ' depending on their\nrelative ordering.\n\nAlso', ' for BPF LSM setup', ' add bpf_prog_load and bpf_prog_free to\nsleepable LSM hooks list', ' as they are both executed in sleepable\ncontext. Also drop bpf_prog_load hook from untrusted', ' as there is no\nissue with refcount or anything else anymore', ' that originally forced us\nto add it to untrusted list in c0c852dd1876 (""bpf: Do not mark certain LSM\nhook arguments as trusted""). We now trigger this hook much later and it\nshould not be an issue anymore.\n\n [0] https://lore.kernel.org/bpf/9fe88aef7deabbe87d3fc38c4aea3c69.paul@paul-moore.com/\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: Paul Moore \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-10-andrii@kernel.org\n', '']",Refactor LSM hooks for bpf_prog_alloc and bpf_prog_free functions.,"LSM hooks, refactor, allocation",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['LSM like programs'] +d79a3549754725bb90e58104417449edddf3da3d,d79a3549754725bb90e58104417449edddf3da3d,Andrii Nakryiko,andrii@kernel.org,1706062865,Alexei Starovoitov,ast@kernel.org,1706142061,dbcb8b033e1d9bc85127d229aa6d7bd3b933e356,bbc1d24724e110b86a1a7c3c1724ce0d62cc1e2e,"bpf: Consistently use BPF token throughout BPF verifier logic + +Remove remaining direct queries to perfmon_capable() and bpf_capable() +in BPF verifier logic and instead use BPF token (if available) to make +decisions about privileges. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-9-andrii@kernel.org +",,The commit updates the BPF verifier to consistently use BPF tokens for privilege checks.,"BPF token, verifier, privileges",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +bbc1d24724e110b86a1a7c3c1724ce0d62cc1e2e,bbc1d24724e110b86a1a7c3c1724ce0d62cc1e2e,Andrii Nakryiko,andrii@kernel.org,1706062864,Alexei Starovoitov,ast@kernel.org,1706142061,b9fdd4d3c3693de18200ab474b48566137367e86,caf8f28e036c4ba1e823355da6c0c01c39e70ab9,"bpf: Take into account BPF token when fetching helper protos + +Instead of performing unconditional system-wide bpf_capable() and +perfmon_capable() calls inside bpf_base_func_proto() function (and other +similar ones) to determine eligibility of a given BPF helper for a given +program"," use previously recorded BPF token during BPF_PROG_LOAD command +handling to inform the decision. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-8-andrii@kernel.org +",[''],The commit enhances BPF helper eligibility check using BPF token instead of global capability checks.,"BPF token, helper protos, eligibility",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +caf8f28e036c4ba1e823355da6c0c01c39e70ab9,caf8f28e036c4ba1e823355da6c0c01c39e70ab9,Andrii Nakryiko,andrii@kernel.org,1706062863,Alexei Starovoitov,ast@kernel.org,1706142061,bc60a1165bbbf9e13a1fa840f27298af3cbee67d,9ea7c4bf17e39d463eb4782f948f401d9764b1b3,"bpf: Add BPF token support to BPF_PROG_LOAD command + +Add basic support of BPF token to BPF_PROG_LOAD. BPF_F_TOKEN_FD flag +should be set in prog_flags field when providing prog_token_fd. + +Wire through a set of allowed BPF program types and attach types"," +derived from BPF FS at BPF token creation time. Then make sure we +perform bpf_token_capable() checks everywhere where it's relevant. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Alexei Starovoitov +Link: https://lore.kernel.org/bpf/20240124022127.2379740-7-andrii@kernel.org +",[''],Add BPF token support to BPF_PROG_LOAD command with required security checks.,"BPF token, BPF_PROG_LOAD, prog_flags",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9ea7c4bf17e39d463eb4782f948f401d9764b1b3,9ea7c4bf17e39d463eb4782f948f401d9764b1b3,Andrii Nakryiko,andrii@kernel.org,1706062862,Alexei Starovoitov,ast@kernel.org,1706142061,9cf0cc9d7b7ceb2ec8b7b2fe37baa0b5ce0bd30c,a177fc2bf6fd83704854feaf7aae926b1df4f0b9,"bpf: Add BPF token support to BPF_BTF_LOAD command + +Accept BPF token FD in BPF_BTF_LOAD command to allow BTF data loading +through delegated BPF token. BPF_F_TOKEN_FD flag has to be specified +when passing BPF token FD. Given BPF_BTF_LOAD command didn't have flags +field before"," we also add btf_flags field. + +BTF loading is a pretty straightforward operation","[' so as long as BPF\ntoken is created with allow_cmds granting BPF_BTF_LOAD command', ' kernel\nproceeds to parsing BTF data and creating BTF object.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-6-andrii@kernel.org\n', '']",Add BPF token support to BPF_BTF_LOAD command for loading BTF data using delegated tokens.,"BPF token, BTF_LOAD, delegation",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a177fc2bf6fd83704854feaf7aae926b1df4f0b9,a177fc2bf6fd83704854feaf7aae926b1df4f0b9,Andrii Nakryiko,andrii@kernel.org,1706062861,Alexei Starovoitov,ast@kernel.org,1706142061,74cafa2a721c24e10f9cbbeacd7acf518584edcb,35f96de04127d332a5c5e8a155d31f452f88c76d,"bpf: Add BPF token support to BPF_MAP_CREATE command + +Allow providing token_fd for BPF_MAP_CREATE command to allow controlled +BPF map creation from unprivileged process through delegated BPF token. +New BPF_F_TOKEN_FD flag is added to specify together with BPF token FD +for BPF_MAP_CREATE command. + +Wire through a set of allowed BPF map types to BPF token"," derived from +BPF FS at BPF token creation time. This","[' in combination with allowed_cmds\nallows to create a narrowly-focused BPF token (controlled by privileged\nagent) with a restrictive set of BPF maps that application can attempt\nto create.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-5-andrii@kernel.org\n', '']",This commit adds BPF token support for controlled map creation from unprivileged processes in the BPF_MAP_CREATE command.,"BPF token, BPF_MAP_CREATE, unprivileged",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +35f96de04127d332a5c5e8a155d31f452f88c76d,35f96de04127d332a5c5e8a155d31f452f88c76d,Andrii Nakryiko,andrii@kernel.org,1706062860,Alexei Starovoitov,ast@kernel.org,1706142061,20e268d6358835f0caf0cf82e47e95746c92b465,6fe01d3cbb924a72493eb3f4722dfcfd1c194234,"bpf: Introduce BPF token object + +Add new kind of BPF kernel object"," BPF token. BPF token is meant to +allow delegating privileged BPF functionality","[' like loading a BPF\nprogram or creating a BPF map', ' from privileged process to a *trusted*\nunprivileged process', ' all while having a good amount of control over which\nprivileged operations could be performed using provided BPF token.\n\nThis is achieved through mounting BPF FS instance with extra delegation\nmount options', ' which determine what operations are delegatable', ' and also\nconstraining it to the owning user namespace (as mentioned in the\nprevious patch).\n\nBPF token itself is just a derivative from BPF FS and can be created\nthrough a new bpf() syscall command', ' BPF_TOKEN_CREATE', ' which accepts BPF\nFS FD', ' which can be attained through open() API by opening BPF FS mount\npoint. Currently', ' BPF token ""inherits"" delegated command', ' map types', '\nprog type', ' and attach type bit sets from BPF FS as is. In the future', '\nhaving an BPF token as a separate object with its own FD', "" we can allow\nto further restrict BPF token's allowable set of things either at the\ncreation time or after the fact"", ' allowing the process to guard itself\nfurther from unintentionally trying to load undesired kind of BPF\nprograms. But for now we keep things simple and just copy bit sets as is.\n\nWhen BPF token is created from BPF FS mount', "" we take reference to the\nBPF super block's owning user namespace"", ' and then use that namespace for\nchecking all the {CAP_BPF', ' CAP_PERFMON', ' CAP_NET_ADMIN', ' CAP_SYS_ADMIN}\ncapabilities that are normally only checked against init userns (using\ncapable())', ' but now we check them using ns_capable() instead (if BPF\ntoken is provided). See bpf_token_capable() for details.\n\nSuch setup means that BPF token in itself is not sufficient to grant BPF\nfunctionality. User namespaced process has to *also* have necessary\ncombination of capabilities inside that user namespace. So while\npreviously CAP_BPF was useless when granted within user namespace', ' now\nit gains a meaning and allows container managers and sys admins to have\na flexible control over which processes can and need to use BPF\nfunctionality within the user namespace (i.e.', ' container in practice).\nAnd BPF FS delegation mount options and derived BPF tokens serve as\na per-container ""flag"" to grant overall ability to use bpf() (plus further\nrestrict on which parts of bpf() syscalls are treated as namespaced).\n\nNote also', ' BPF_TOKEN_CREATE command itself requires ns_capable(CAP_BPF)\nwithin the BPF FS owning user namespace', ' rounding up the ns_capable()\nstory of BPF token. Also creating BPF token in init user namespace is\ncurrently not supported', "" given BPF token doesn't have any effect in init\nuser namespace anyways.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: Christian Brauner \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-4-andrii@kernel.org\n"", '']",Introduces a new BPF token object to delegate privileged BPF functionality.,"BPF token, kernel object, privileged functionality",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['other'] +6fe01d3cbb924a72493eb3f4722dfcfd1c194234,6fe01d3cbb924a72493eb3f4722dfcfd1c194234,Andrii Nakryiko,andrii@kernel.org,1706062859,Alexei Starovoitov,ast@kernel.org,1706142060,9388ec7de8315a4a262564b34206c192777ebc93,ed1ad5a7415de8be121055e7ab1303d2be5407e0,"bpf: Add BPF token delegation mount options to BPF FS + +Add few new mount options to BPF FS that allow to specify that a given +BPF FS instance allows creation of BPF token (added in the next patch)"," +and what sort of operations are allowed under BPF token. As such","[' we get\n4 new mount options', ' each is a bit mask\n - `delegate_cmds` allow to specify which bpf() syscall commands are\n allowed with BPF token derived from this BPF FS instance;\n - if BPF_MAP_CREATE command is allowed', ' `delegate_maps` specifies\n a set of allowable BPF map types that could be created with BPF token;\n - if BPF_PROG_LOAD command is allowed', ' `delegate_progs` specifies\n a set of allowable BPF program types that could be loaded with BPF token;\n - if BPF_PROG_LOAD command is allowed', ' `delegate_attachs` specifies\n a set of allowable BPF program attach types that could be loaded with\n BPF token; delegate_progs and delegate_attachs are meant to be used\n together', ' as full BPF program type is', ' in general', ' determined\n through both program type and program attach type.\n\nCurrently', ' these mount options accept the following forms of values:\n - a special value ""any""', ' that enables all possible values of a given\n bit set;\n - numeric value (decimal or hexadecimal', ' determined by kernel\n automatically) that specifies a bit mask value directly;\n - all the values for a given mount option are combined', ' if specified\n multiple times. E.g.', ' `mount -t bpf nodev /path/to/mount -o\n delegate_maps=0x1 -o delegate_maps=0x2` will result in a combined 0x3\n mask.\n\nIdeally', ' more convenient (for humans) symbolic form derived from\ncorresponding UAPI enums would be accepted (e.g.', ' `-o\ndelegate_progs=kprobe|tracepoint`) and I intend to implement this', ' but\nit requires a bunch of UAPI header churn', ' so I postponed it until this\nfeature lands upstream or at least there is a definite consensus that\nthis feature is acceptable and is going to make it', ' just to minimize\namount of wasted effort and not increase amount of non-essential code to\nbe reviewed.\n\nAttentive reader will notice that BPF FS is now marked as\nFS_USERNS_MOUNT', ' which theoretically makes it mountable inside non-init\nuser namespace as long as the process has sufficient *namespaced*\ncapabilities within that user namespace. But in reality we still\nrestrict BPF FS to be mountable only by processes with CAP_SYS_ADMIN *in\ninit userns* (extra check in bpf_fill_super()). FS_USERNS_MOUNT is added\nto allow creating BPF FS context object (i.e.', ' fsopen(""bpf"")) from\ninside unprivileged process inside non-init userns', ' to capture that\nuserns as the owning userns. It will still be required to pass this\ncontext object back to privileged process to instantiate and mount it.\n\nThis manipulation is important', ' because capturing non-init userns as the\nowning userns of BPF FS instance (super block) allows to use that userns\nto constraint BPF token to that userns later on (see next patch). So\ncreating BPF FS with delegation inside unprivileged userns will restrict\nderived BPF token objects to only ""work"" inside that intended userns', '\nmaking it scoped to a intended ""container"". Also', ' setting these\ndelegation options requires capable(CAP_SYS_ADMIN)', ' so unprivileged\nprocess cannot set this up without involvement of a privileged process.\n\nThere is a set of selftests at the end of the patch set that simulates\nthis sequence of steps and validates that everything works as intended.\nBut careful review is requested to make sure there are no missed gaps in\nthe implementation and testing.\n\nThis somewhat subtle set of aspects is the result of previous\ndiscussions ([0]) about various user namespace implications and\ninteractions with BPF token functionality and is necessary to contain\nBPF token inside intended user namespace.\n\n [0] https://lore.kernel.org/bpf/20230704-hochverdient-lehne-eeb9eeef785e@brauner/\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: Christian Brauner \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-3-andrii@kernel.org\n', '']",Add new mount options to BPF FS for BPF token delegation.,"BPF FS,mount options,token",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ed1ad5a7415de8be121055e7ab1303d2be5407e0,ed1ad5a7415de8be121055e7ab1303d2be5407e0,Andrii Nakryiko,andrii@kernel.org,1706062858,Alexei Starovoitov,ast@kernel.org,1706142060,b9da489b27e66f93b861aae564e7bb93d70939db,c9f115564561af63db662791e9a35fcf1dfefd2a,"bpf: Align CAP_NET_ADMIN checks with bpf_capable() approach + +Within BPF syscall handling code CAP_NET_ADMIN checks stand out a bit +compared to CAP_BPF and CAP_PERFMON checks. For the latter"," CAP_BPF or +CAP_PERFMON are checked first","[' but if they are not set', ' CAP_SYS_ADMIN\ntakes over and grants whatever part of BPF syscall is required.\n\nSimilar kind of checks that involve CAP_NET_ADMIN are not so consistent.\nOne out of four uses does follow CAP_BPF/CAP_PERFMON model: during\nBPF_PROG_LOAD', ' if the type of BPF program is ""network-related"" either\nCAP_NET_ADMIN or CAP_SYS_ADMIN is required to proceed.\n\nBut in three other cases CAP_NET_ADMIN is required even if CAP_SYS_ADMIN\nis set:\n - when creating DEVMAP/XDKMAP/CPU_MAP maps;\n - when attaching CGROUP_SKB programs;\n - when handling BPF_PROG_QUERY command.\n\nThis patch is changing the latter three cases to follow BPF_PROG_LOAD\nmodel', ' that is allowing to proceed under either CAP_NET_ADMIN or\nCAP_SYS_ADMIN.\n\nThis also makes it cleaner in subsequent BPF token patches to switch\nwholesomely to a generic bpf_token_capable(int cap) check', ' that always\nfalls back to CAP_SYS_ADMIN if requested capability is missing.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \nAcked-by: Yafang Shao \nLink: https://lore.kernel.org/bpf/20240124022127.2379740-2-andrii@kernel.org\n', '']",Aligns CAP_NET_ADMIN checks with existing bpf_capable() approach for consistency in BPF syscall handling.,"CAP_NET_ADMIN,bpf_capable,BPF",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c9f115564561af63db662791e9a35fcf1dfefd2a,c9f115564561af63db662791e9a35fcf1dfefd2a,Martin KaFai Lau,martin.lau@kernel.org,1706136258,Alexei Starovoitov,ast@kernel.org,1706141979,6806e7bb3c8becfd5478b199b0aaa4d8543515d0,ce6f6cffaeaa0a3bcdafcae7fe03c68c3afae631,"libbpf: Ensure undefined bpf_attr field stays 0 + +The commit 9e926acda0c2 (""libbpf: Find correct module BTFs for struct_ops maps and progs."") +sets a newly added field (value_type_btf_obj_fd) to -1 in libbpf when +the caller of the libbpf's bpf_map_create did not define this field by +passing a NULL ""opts"" or passing in a ""opts"" that does not cover this +new field. OPT_HAS(opts"," field) is used to decide if the field is +defined or not: + + ((opts) && opts->sz >= offsetofend(typeof(*(opts))","[' field))\n\nOnce OPTS_HAS decided the field is not defined', ' that field should\nbe set to 0. For this particular new field (value_type_btf_obj_fd)', '\nits corresponding map_flags ""BPF_F_VTYPE_BTF_OBJ_FD"" is not set.\nThus', ' the kernel does not treat it as an fd field.\n\nFixes: 9e926acda0c2 (""libbpf: Find correct module BTFs for struct_ops maps and progs."")\nReported-by: Andrii Nakryiko \nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240124224418.2905133-1-martin.lau@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",The commit ensures that undefined bpf_attr fields in libbpf remain zero to prevent unintended behavior.,"libbpf, bpf_attr, zero",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ce6f6cffaeaa0a3bcdafcae7fe03c68c3afae631,ce6f6cffaeaa0a3bcdafcae7fe03c68c3afae631,Martin KaFai Lau,martin.lau@kernel.org,1705730718,Andrii Nakryiko,andrii@kernel.org,1706119426,ff244dfc081b96282efd56f5a44fda09d3b16591,177f1d083a19af58f4b1206d299ed73689249fd8,"selftests/bpf: Wait for the netstamp_needed_key static key to be turned on + +After the previous patch that speeded up the test (by avoiding neigh +discovery in IPv6)"," the BPF CI occasionally hits this error: + +rcv tstamp unexpected pkt rcv tstamp: actual 0 == expected 0 + +The test complains about the cmsg returned from the recvmsg() does not +have the rcv timestamp. Setting skb->tstamp or not is +controlled by a kernel static key ""netstamp_needed_key"". The static +key is enabled whenever this is at least one sk with the SOCK_TIMESTAMP +set. + +The test_redirect_dtime does use setsockopt() to turn on +the SOCK_TIMESTAMP for the reading sk. In the kernel +net_enable_timestamp() has a delay to enable the ""netstamp_needed_key"" +when CONFIG_JUMP_LABEL is set. This potential delay is the likely reason +for packet missing rcv timestamp occasionally. + +This patch is to create udp sockets with SOCK_TIMESTAMP set. +It sends and receives some packets until the received packet +has a rcv timestamp. It currently retries at most 5 times with 1s +in between. This should be enough to wait for the ""netstamp_needed_key"". +It then holds on to the socket and only closes it at the end of the test. +This guarantees that the test has the ""netstamp_needed_key"" key turned +on from the beginning. + +To simplify the udp sockets setup","[' they are sending/receiving packets\nin the same netns (ns_dst is used) and communicate over the ""lo"" dev.\nHence', ' the patch enables the ""lo"" dev in the ns_dst.\n\nFixes: c803475fd8dd (""bpf: selftests: test skb->tstamp in redirect_neigh"")\nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240120060518.3604920-2-martin.lau@linux.dev\n', '']",The commit updates selftests to ensure netstamp_needed_key static key is active for correct timestamping in tests.,"selftests, netstamp_needed_key, timestamp",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +177f1d083a19af58f4b1206d299ed73689249fd8,177f1d083a19af58f4b1206d299ed73689249fd8,Martin KaFai Lau,martin.lau@kernel.org,1705730717,Andrii Nakryiko,andrii@kernel.org,1706119426,8d1f4e2907ef8bca18cba5f404cda8cf7b7e85a5,d47b9f68d2899b390a3655f2365f332a63396adf,"selftests/bpf: Fix the flaky tc_redirect_dtime test + +BPF CI has been reporting the tc_redirect_dtime test failing +from time to time: + +test_inet_dtime:PASS:setns src 0 nsec +(network_helpers.c:253: errno: No route to host) Failed to connect to server +close_netns:PASS:setns 0 nsec +test_inet_dtime:FAIL:connect_to_fd unexpected connect_to_fd: actual -1 < expected 0 +test_tcp_clear_dtime:PASS:tcp ip6 clear dtime ingress_fwdns_p100 0 nsec + +The connect_to_fd failure (EHOSTUNREACH) is from the +test_tcp_clear_dtime() test and it is the very first IPv6 traffic +after setting up all the links", addresses,"[' and routes.\n\nThe symptom is this first connect() is always slow. In my setup', ' it\ncould take ~3s.\n\nAfter some tracing and tcpdump', ' the slowness is mostly spent in\nthe neighbor solicitation in the ""ns_fwd"" namespace while\nthe ""ns_src"" and ""ns_dst"" are fine.\n\nI forced the kernel to drop the neighbor solicitation messages.\nI can then reproduce EHOSTUNREACH. What actually happen could be:\n- the neighbor advertisement came back a little slow.\n- the ""ns_fwd"" namespace concluded a neighbor discovery failure\n and triggered the ndisc_error_report() => ip6_link_failure() =>\n icmpv6_send(skb', ' ICMPV6_DEST_UNREACH', ' ICMPV6_ADDR_UNREACH', ' 0)\n- the client\'s connect() reports EHOSTUNREACH after receiving\n the ICMPV6_DEST_UNREACH message.\n\nThe neigh table of both ""ns_src"" and ""ns_dst"" namespace has already\nbeen manually populated but not the ""ns_fwd"" namespace. This patch\nfixes it by manually populating the neigh table also in the ""ns_fwd""\nnamespace.\n\nAlthough the namespace configuration part had been existed before\nthe tc_redirect_dtime test', ' still Fixes-tagging the patch when\nthe tc_redirect_dtime test was added since it is the only test\nhitting it so far.\n\nFixes: c803475fd8dd (""bpf: selftests: test skb->tstamp in redirect_neigh"")\nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240120060518.3604920-1-martin.lau@linux.dev\n', '']",Fixes the flaky tc_redirect_dtime test in BPF selftests due to IPv6 traffic issues.,"flaky, tc_redirect_dtime, test",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d47b9f68d2899b390a3655f2365f332a63396adf,d47b9f68d2899b390a3655f2365f332a63396adf,Dima Tisnek,dimaqq@gmail.com,1705816886,Andrii Nakryiko,andrii@kernel.org,1706070597,723509362b741cbd2b96e158dc47245cff95ec47,32749605e3a9726f2cf277cbc032cf243c2da689,"libbpf: Correct bpf_core_read.h comment wrt bpf_core_relo struct + +Past commit ([0]) removed the last vestiges of struct bpf_field_reloc"," +it's called struct bpf_core_relo now. + + [0] 28b93c64499a (""libbpf: Clean up and improve CO-RE reloc logging"") + +Signed-off-by: Dima Tisnek +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240121060126.15650-1-dimaqq@gmail.com +",[''],This commit corrects comments in libbpf related to struct bpf_core_relo.,"libbpf, comments, bpf_core_relo",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +32749605e3a9726f2cf277cbc032cf243c2da689,32749605e3a9726f2cf277cbc032cf243c2da689,Andrii Nakryiko,andrii@kernel.org,1706070378,Andrii Nakryiko,andrii@kernel.org,1706070486,f9509b14e129f75f49d815c7182f99c714da7ee3,8b593021319d4893a8fbeb7bd1f668657e68403c 0b50478fd8774f42721f4297293b711e17bc4b7b,"Merge branch 'skip-callback-tests-if-jit-is-disabled-in-test_verifier' + +Tiezhu Yang says: + +==================== +Skip callback tests if jit is disabled in test_verifier + +Thanks very much for the feedbacks from Eduard", John,"[' Jiri', ' Daniel', '\nHou Tao', ' Song Liu and Andrii.\n\nv7:\n -- Add an explicit flag F_NEEDS_JIT_ENABLED for checking', '\n thanks Andrii.\n\nv6:\n -- Copy insn_is_pseudo_func() into testing_helpers', '\n thanks Andrii.\n\nv5:\n -- Reuse is_ldimm64_insn() and insn_is_pseudo_func()', '\n thanks Song Liu.\n\nv4:\n -- Move the not-allowed-checking into ""if (expected_ret ...)""\n block', ' thanks Hou Tao.\n -- Do some small changes to avoid checkpatch warning\n about ""line length exceeds 100 columns"".\n\nv3:\n -- Rebase on the latest bpf-next tree.\n -- Address the review comments by Hou Tao', '\n remove the second argument ""0"" of open()', '\n check only once whether jit is disabled', '\n check fd_prog', ' saved_errno and jit_disabled to skip.\n====================\n\nLink: https://lore.kernel.org/r/20240123090351.2207-1-yangtiezhu@loongson.cn\nSigned-off-by: Andrii Nakryiko \n', '']",Skip eBPF callback tests in test_verifier when JIT is disabled.,"callback,JIT,test_verifier",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0b50478fd8774f42721f4297293b711e17bc4b7b,0b50478fd8774f42721f4297293b711e17bc4b7b,Tiezhu Yang,yangtiezhu@loongson.cn,1706000631,Andrii Nakryiko,andrii@kernel.org,1706070461,f9509b14e129f75f49d815c7182f99c714da7ee3,15b4f88dcc0a751f790bfea5ef9dcc6385c62236,"selftests/bpf: Skip callback tests if jit is disabled in test_verifier + +If CONFIG_BPF_JIT_ALWAYS_ON is not set and bpf_jit_enable is 0"," there +exist 6 failed tests. + + [root@linux bpf]# echo 0 > /proc/sys/net/core/bpf_jit_enable + [root@linux bpf]# echo 0 > /proc/sys/kernel/unprivileged_bpf_disabled + [root@linux bpf]# ./test_verifier | grep FAIL + #106/p inline simple bpf_loop call FAIL + #107/p don't inline bpf_loop call","["" flags non-zero FAIL\n #108/p don't inline bpf_loop call"", ' callback non-constant FAIL\n #109/p bpf_loop_inline and a dead func FAIL\n #110/p bpf_loop_inline stack locations for loop vars FAIL\n #111/p inline bpf_loop call in a big program FAIL\n Summary: 768 PASSED', ' 15 SKIPPED', ' 6 FAILED\n\nThe test log shows that callbacks are not allowed in non-JITed programs', ""\ninterpreter doesn't support them yet"", ' thus these tests should be skipped\nif jit is disabled.\n\nAdd an explicit flag F_NEEDS_JIT_ENABLED to those tests to mark that they\nrequire JIT enabled in bpf_loop_inline.c', ' check the flag and jit_disabled\nat the beginning of do_test_single() to handle this case.\n\nWith this patch:\n\n [root@linux bpf]# echo 0 > /proc/sys/net/core/bpf_jit_enable\n [root@linux bpf]# echo 0 > /proc/sys/kernel/unprivileged_bpf_disabled\n [root@linux bpf]# ./test_verifier | grep FAIL\n Summary: 768 PASSED', ' 21 SKIPPED', ' 0 FAILED\n\nSuggested-by: Andrii Nakryiko \nSigned-off-by: Tiezhu Yang \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20240123090351.2207-3-yangtiezhu@loongson.cn\n', '']",Skip callback tests in selftests/bpf if JIT is disabled in test_verifier.,"skip, JIT, tests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +15b4f88dcc0a751f790bfea5ef9dcc6385c62236,15b4f88dcc0a751f790bfea5ef9dcc6385c62236,Tiezhu Yang,yangtiezhu@loongson.cn,1706000630,Andrii Nakryiko,andrii@kernel.org,1706070377,166a41af24d6304c34d61e2f797bbaf07f1765f8,8b593021319d4893a8fbeb7bd1f668657e68403c,"selftests/bpf: Move is_jit_enabled() into testing_helpers + +Currently", is_jit_enabled() is only used in test_progs,"[' move it into\ntesting_helpers so that it can be used in test_verifier. While at it', '\nremove the second argument ""0"" of open() as Hou Tao suggested.\n\nSigned-off-by: Tiezhu Yang \nSigned-off-by: Andrii Nakryiko \nAcked-by: Hou Tao \nAcked-by: Song Liu \nLink: https://lore.kernel.org/bpf/20240123090351.2207-2-yangtiezhu@loongson.cn\n', '']",The function is_jit_enabled() is moved to testing_helpers for better organization in selftests.,"selftests,bpf,testing_helpers",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tracepoints like programs'] +8b593021319d4893a8fbeb7bd1f668657e68403c,8b593021319d4893a8fbeb7bd1f668657e68403c,Martin KaFai Lau,martin.lau@kernel.org,1706056794,Martin KaFai Lau,martin.lau@kernel.org,1706058772,85add1361db079527e9798ff1f78d180e9f08180,b7d1af3791036a619ca8ffde5f832111b05ca833 0253e0590e2dc46996534371d56b5297099aed4e,"Merge branch 'Registrating struct_ops types from modules' + +Kui-Feng Lee says: + +==================== +Given the current constraints of the current implementation"," +struct_ops cannot be registered dynamically. This presents a +significant limitation for modules like coming fuse-bpf","[' which seeks\nto implement a new struct_ops type. To address this issue', ' a new API\nis introduced that allows the registration of new struct_ops types\nfrom modules.\n\nPreviously', ' struct_ops types were defined in bpf_struct_ops_types.h\nand collected as a static array. The new API lets callers add new\nstruct_ops types dynamically. The static array has been removed and\nreplaced by the per-btf struct_ops_tab.\n\nThe struct_ops subsystem relies on BTF to determine the layout of\nvalues in a struct_ops map and identify the subsystem that the\nstruct_ops map registers to. However', ' the kernel BTF does not include\nthe type information of struct_ops types defined by a module. The\nstruct_ops subsystem requires knowledge of the corresponding module\nfor a given struct_ops map and the utilization of BTF information from\nthat module. We empower libbpf to determine the correct module for\naccessing the BTF information and pass an identity (FD) of the module\nbtf to the kernel. The kernel looks up type information and registered\nstruct_ops types directly from the given btf.\n\nIf a module exits while one or more struct_ops maps still refer to a\nstruct_ops type defined by the module', ' it can lead to unforeseen\ncomplications. Therefore', ' it is crucial to ensure that a module\nremains intact as long as any struct_ops map is still linked to a\nstruct_ops type defined by the module. To achieve this', ' every\nstruct_ops map holds a reference to the module while being registered.\n\nChanges from v16:\n\n - Fix unnecessary bpf_struct_ops_link_create() removing/adding.\n\n - Rename REGISTER_BPF_STRUCT_OPS() to register_bpf_struct_ops().\n\n - Implement bpf_map_struct_ops_info_fill() for !CONFIG_BPF_JIT.\n\nChanges from v15:\n\n - Fix the misleading commit message of part 4.\n\n - Introduce BPF_F_VTYPE_BTF_OBJ_FD flag to struct bpf_attr to tell\n if value_type_btf_obj_fd is set or not.\n\n - Introduce links_cnt to struct bpf_struct_ops_map to avoid accessing\n struct bpf_struct_ops_desc in bpf_struct_ops_map_put_progs() after\n calling module_put() against the owner module of the struct_ops\n type. (Part 9)\n\nChanges from v14:\n\n - Rebase. Add cif_stub required by\n the commit 2cd3e3772e413 (""x86/cfi', 'bpf: Fix bpf_struct_ops CFI"")\n\n - Remove creating struct_ops map without bpf_testmod.ko from the\n test.\n\n - Check the name of btf returned by bpf_map_info by getting the name\n with bpf_btf_get_info_by_fd().\n\n - Change value_type_btf_obj_fd to a signed type to allow the 0 fd.\n\nChanges from v13:\n\n - Change the test case to use bpf_map_create() to create a struct_ops\n map while testmod.ko is unloaded.\n\n - Move bpf_struct_ops_find*() to btf.c.\n\n - Use btf_is_module() to replace btf != btf_vmlinux.\n\nChanges from v12:\n\n - Rebase to for-next to fix conflictions.\n\nChanges from v11:\n\n - bpf_struct_ops_maps hold only the refcnt to the module', ' but not\n btf. (patch 1)\n\n - Fix warning messages. (patch 1', ' 9 and 10)\n\n - Remove unnecessary conditional compiling of CONFIG_BPF_JIT.\n (patch 4', "" 9 and 10)\n\n - Fix the commit log of the patch 7 to explain how a btf is pass from\n the user space and how the kernel handle it.\n\n - bpf_struct_ops_maps hold the module defining it's type"", "" but not\n btf. A map will hold the module through its life-span from\n allocating to being free. (patch 8)\n\n - Change selftests and tracing __bpf_struct_ops_map_free() to wait\n for the release of the bpf_testmod module.\n\n - Include btf_obj_id in bpf_map_info. (patch 14)\n\nChanges from v10:\n\n - Guard btf.c from CONFIG_BPF_JIT=n. This patchset has introduced\n symbols from bpf_struct_ops.c which is only built when\n CONFIG_BPF_JIT=y.\n\n - Fix the warning of unused errout_free label by moving code that is\n leaked to patch 8 to patch 7.\n\nChanges from v9:\n\n - Remove the call_rcu_tasks_trace() changes from kern_sync_rcu().\n\n - Trace btf_put() in the test case to ensure the release of kmod's\n btf"", "" or the consequent tests may fail for using kmod's unloaded old\n btf instead the new one created after loading again. The kmod's btf\n may live for awhile after unloading the kmod"", ' for a map being freed\n asynchronized is still holding the btf.\n\n - Split ""add struct_ops_tab to btf"" into tow patches by adding\n ""make struct_ops_map support btfs other than btf_vmlinux"".\n\n - Flip the order of ""pass attached BTF to the bpf_struct_ops\n subsystem"" and ""hold module for bpf_struct_ops_map"" to make it more\n reasonable.\n\n - Fix the compile errors of a missing header file.\n\nChanges from v8:\n\n - Rename bpf_struct_ops_init_one() to bpf_struct_ops_desc_init().\n\n - Move code that using BTF_ID_LIST to the newly added patch 2.\n\n - Move code that lookup struct_ops types from a given module to the\n newly added patch 5.\n\n - Store the pointers of btf at st_maps.\n\n - Add test cases for the cases of modules being unload.\n\n - Call bpf_struct_ops_init() in btf_add_struct_ops() to fix an\n inconsistent issue.\n\nChanges from v7:\n\n - Fix check_struct_ops_btf_id() to use attach btf if there is instead\n of btf_vmlinux.\n\nChanges from v6:\n\n - Change returned error code to -EINVAL for the case of\n bpf_try_get_module().\n\n - Return an error code from bpf_struct_ops_init().\n\n - Fix the dependency issue of testing_helpers.c and\n rcu_tasks_trace_gp.skel.h.\n\nChanges from v5:\n\n - As the 2nd patch', ' we introduce ""bpf_struct_ops_desc"". This change\n involves moving certain members of ""bpf_struct_ops"" to\n ""bpf_struct_ops_desc""', ' which becomes a part of\n ""btf_struct_ops_tab"". This ensures that these members remain\n accessible even when the owner module of a ""bpf_struct_ops"" is\n unloaded.\n\n - Correct the order of arguments when calling\n in the 3rd patch.\n\n - Remove the owner argument from bpf_struct_ops_init_one(). Instead', ""\n callers should fill in st_ops->owner.\n\n - Make sure to hold the owner module when calling\n bpf_struct_ops_find() and bpf_struct_ops_find_value() in the 6th\n patch.\n\n - Merge the functions register_bpf_struct_ops_btf() and\n register_bpf_struct_ops() into a single function and relocate it to\n btf.c for better organization and clarity.\n\n - Undo the name modifications made to find_kernel_btf_id() and\n find_ksym_btf_id() in the 8th patch.\n\nChanges from v4:\n\n - Fix the dependency between testing_helpers.o and\n rcu_tasks_trace_gp.skel.h.\n\nChanges from v3:\n\n - Fix according to the feedback for v3.\n\n - Change of the order of arguments to make btf as the first\n argument.\n\n - Use btf_try_get_module() instead of try_get_module() since the\n module pointed by st_ops->owner can gone while some one is still\n holding its btf.\n\n - Move variables defined by BPF_STRUCT_OPS_COMMON_VALUE to struct\n bpf_struct_ops_common_value to validation easier.\n\n - Register the struct_ops type defined by bpf_testmod in its init\n function.\n\n - Rename field name to 'value_type_btf_obj_fd' to make it explicit.\n\n - Fix leaking of btf objects on error.\n\n - st_maps hold their modules to keep modules alive and prevent they\n from unloading.\n\n - bpf_map of libbpf keeps mod_btf_fd instead of a pointer to module_btf.\n\n - Do call_rcu_tasks_trace() in kern_sync_rcu() to ensure the\n bpf_testmod is unloaded properly. It uses rcu_tasks_trace_gp to\n trigger call_rcu_tasks_trace() in the kernel.\n\n - Merge and reorder patches in a reasonable order.\n\nChanges from v2:\n\n - Remove struct_ops array"", ' and add a per-btf (module) struct_ops_tab\n to collect registered struct_ops types.\n\n - Validate value_type by checking member names and types.\n---\nv16: https://lore.kernel.org/all/20240118014930.1992551-1-thinker.li@gmail.com/\nv15: https://lore.kernel.org/all/20231220222654.1435895-1-thinker.li@gmail.com/\nv14: https://lore.kernel.org/all/20231217081132.1025020-1-thinker.li@gmail.com/\nv13: https://lore.kernel.org/all/20231209002709.535966-1-thinker.li@gmail.com/\nv12: https://lore.kernel.org/all/20231207013950.1689269-1-thinker.li@gmail.com/\nv11: https://lore.kernel.org/all/20231106201252.1568931-1-thinker.li@gmail.com/\nv10: https://lore.kernel.org/all/20231103232202.3664407-1-thinker.li@gmail.com/\nv9: https://lore.kernel.org/all/20231101204519.677870-1-thinker.li@gmail.com/\nv8: https://lore.kernel.org/all/20231030192810.382942-1-thinker.li@gmail.com/\nv7: https://lore.kernel.org/all/20231027211702.1374597-1-thinker.li@gmail.com/\nv6: https://lore.kernel.org/all/20231022050335.2579051-11-thinker.li@gmail.com/\nv5: https://lore.kernel.org/all/20231017162306.176586-1-thinker.li@gmail.com/\nv4: https://lore.kernel.org/all/20231013224304.187218-1-thinker.li@gmail.com/\nv3: https://lore.kernel.org/all/20230920155923.151136-1-thinker.li@gmail.com/\nv2: https://lore.kernel.org/all/20230913061449.1918219-1-thinker.li@gmail.com/\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",This commit addresses the limitation of dynamically registering struct_ops in eBPF modules.,"struct_ops,dynamic registration,modules",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +0253e0590e2dc46996534371d56b5297099aed4e,0253e0590e2dc46996534371d56b5297099aed4e,Kui-Feng Lee,thinker.li@gmail.com,1705704605,Martin KaFai Lau,martin.lau@kernel.org,1706058772,85add1361db079527e9798ff1f78d180e9f08180,7c81c2490c73e614c6d48e4f339f4f224140b565,"selftests/bpf: test case for register_bpf_struct_ops(). + +Create a new struct_ops type called bpf_testmod_ops within the bpf_testmod +module. When a struct_ops object is registered"," the bpf_testmod module will +invoke test_2 from the module. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-15-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Add a new test case for register_bpf_struct_ops in the bpf_testmod module.,"bpf_testmod,struct_ops,test case",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7c81c2490c73e614c6d48e4f339f4f224140b565,7c81c2490c73e614c6d48e4f339f4f224140b565,Kui-Feng Lee,thinker.li@gmail.com,1705704604,Martin KaFai Lau,martin.lau@kernel.org,1706058772,e4818b6ed76d5c6cb7148ac56db2a826c36272e5,9e926acda0c2e21bca431a1818665ddcd6939755,"bpf: export btf_ctx_access to modules. + +The module requires the use of btf_ctx_access() to invoke +bpf_tracing_btf_ctx_access() from a module. This function is valuable for +implementing validation functions that ensure proper access to ctx. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-14-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",,The commit exports btf_ctx_access to modules for implementing validation functions in eBPF.,"btf_ctx_access, modules, validation",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['kprobe/uprobe/ftrace like programs', 'tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9e926acda0c2e21bca431a1818665ddcd6939755,9e926acda0c2e21bca431a1818665ddcd6939755,Kui-Feng Lee,thinker.li@gmail.com,1705704603,Martin KaFai Lau,martin.lau@kernel.org,1706058772,4d4f1f22b84386dcd06c0402d196ffb748be121b,f6be98d19985411ca1f3d53413d94d5b7f41c200,"libbpf: Find correct module BTFs for struct_ops maps and progs. + +Locate the module BTFs for struct_ops maps and progs and pass them to the +kernel. This ensures that the kernel correctly resolves type IDs from the +appropriate module BTFs. + +For the map of a struct_ops object"," the FD of the module BTF is set to +bpf_map to keep a reference to the module BTF. The FD is passed to the +kernel as value_type_btf_obj_fd when the struct_ops object is loaded. + +For a bpf_struct_ops prog","[' attach_btf_obj_fd of bpf_prog is the FD of a\nmodule BTF in the kernel.\n\nSigned-off-by: Kui-Feng Lee \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240119225005.668602-13-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",The commit ensures correct module BTFs are used for struct_ops maps and progs in libbpf.,"libbpf, module BTFs, struct_ops",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f6be98d19985411ca1f3d53413d94d5b7f41c200,f6be98d19985411ca1f3d53413d94d5b7f41c200,Kui-Feng Lee,thinker.li@gmail.com,1705704602,Martin KaFai Lau,martin.lau@kernel.org,1706058766,42992e3ac7a76fbb27a46dabeb2bf93ca7dc6f61,612d087d4ba54cef47946e22e5dabad762dd7ed5,bpf," net: switch to dynamic registration + +Replace the static list of struct_ops types with per-btf struct_ops_tab to +enable dynamic registration. + +Both bpf_dummy_ops and bpf_tcp_ca now utilize the registration function +instead of being listed in bpf_struct_ops_types.h. + +Cc: netdev@vger.kernel.org +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-12-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Introduce dynamic registration for bpf struct operations using per-btf struct_ops_tab in lieu of static listing.,"dynamic registration, struct_ops, bpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['socket like programs', 'tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +612d087d4ba54cef47946e22e5dabad762dd7ed5,612d087d4ba54cef47946e22e5dabad762dd7ed5,Kui-Feng Lee,thinker.li@gmail.com,1705704601,Martin KaFai Lau,martin.lau@kernel.org,1706056665,7044e668fc1d4277daac80e05425caf566aedc02,e3f87fdfed7b770dd7066b02262b12747881e76d,"bpf: validate value_type + +A value_type should consist of three components: refcnt", state,"[' and data.\nrefcnt and state has been move to struct bpf_struct_ops_common_value to\nmake it easier to check the value type.\n\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240119225005.668602-11-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",This commit ensures that value_type in eBPF is validated to contain three components including refcnt.,"validate,value_type,refcnt",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e3f87fdfed7b770dd7066b02262b12747881e76d,e3f87fdfed7b770dd7066b02262b12747881e76d,Kui-Feng Lee,thinker.li@gmail.com,1705704600,Martin KaFai Lau,martin.lau@kernel.org,1706056664,aba3b44c97564fd8d0e61f4b1eec1b90d7b13ee2,fcc2c1fb0651477c8ed78a3a293c175ccd70697a,"bpf: hold module refcnt in bpf_struct_ops map creation and prog verification. + +To ensure that a module remains accessible whenever a struct_ops object of +a struct_ops type provided by the module is still in use. + +struct bpf_struct_ops_map doesn't hold a refcnt to btf anymore since a +module will hold a refcnt to it's btf already. But"," struct_ops programs are +different. They hold their associated btf","[' not the module since they need\nonly btf to assure their types (signatures).\n\nHowever', ' verifier holds the refcnt of the associated module of a struct_ops\ntype temporarily when verify a struct_ops prog. Verifier needs the help\nfrom the verifier operators (struct bpf_verifier_ops) provided by the owner\nmodule to verify data access of a prog', ' provide information', ' and generate\ncode.\n\nThis patch also add a count of links (links_cnt) to bpf_struct_ops_map. It\navoids bpf_struct_ops_map_put_progs() from accessing btf after calling\nmodule_put() in bpf_struct_ops_map_free().\n\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240119225005.668602-10-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Ensure module refcount is maintained for struct_ops objects during map creation and program verification.,"module, refcnt, struct_ops",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fcc2c1fb0651477c8ed78a3a293c175ccd70697a,fcc2c1fb0651477c8ed78a3a293c175ccd70697a,Kui-Feng Lee,thinker.li@gmail.com,1705704599,Martin KaFai Lau,martin.lau@kernel.org,1706056664,5db50a9fefdd357c802c97bfe3962f1c6e0fee90,689423db3bda2244c24db8a64de4cdb37be1de41,"bpf: pass attached BTF to the bpf_struct_ops subsystem + +Pass the fd of a btf from the userspace to the bpf() syscall"," and then +convert the fd into a btf. The btf is generated from the module that +defines the target BPF struct_ops type. + +In order to inform the kernel about the module that defines the target +struct_ops type","["" the userspace program needs to provide a btf fd for the\nrespective module's btf. This btf contains essential information on the\ntypes defined within the module"", ' including the target struct_ops type.\n\nA btf fd must be provided to the kernel for struct_ops maps and for the bpf\nprograms attached to those maps.\n\nIn the case of the bpf programs', ' the attach_btf_obj_fd parameter is passed\nas part of the bpf_attr and is converted into a btf. This btf is then\nstored in the prog->aux->attach_btf field. Here', ' it just let the verifier\naccess attach_btf directly.\n\nIn the case of struct_ops maps', ' a btf fd is passed as value_type_btf_obj_fd\nof bpf_attr. The bpf_struct_ops_map_alloc() function converts the fd to a\nbtf and stores it as st_map->btf. A flag BPF_F_VTYPE_BTF_OBJ_FD is added\nfor map_flags to indicate that the value of value_type_btf_obj_fd is set.\n\nSigned-off-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/20240119225005.668602-9-thinker.li@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Added functionality to pass BTF fd from userspace to bpf() syscall for struct_ops support.,"BTF, struct_ops, syscall",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +689423db3bda2244c24db8a64de4cdb37be1de41,689423db3bda2244c24db8a64de4cdb37be1de41,Kui-Feng Lee,thinker.li@gmail.com,1705704598,Martin KaFai Lau,martin.lau@kernel.org,1706056664,a76dfd5a3ca0c8f459c06a9306ebbbb7fbc78c6d,1338b93346587a2a6ac79bbcf55ef5b357745573,"bpf: lookup struct_ops types from a given module BTF. + +This is a preparation for searching for struct_ops types from a specified +module. BTF is always btf_vmlinux now. This patch passes a pointer of BTF +to bpf_struct_ops_find_value() and bpf_struct_ops_find(). Once the new +registration API of struct_ops types is used"," other BTFs besides +btf_vmlinux can also be passed to them. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-8-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],This commit prepares for searching struct_ops types from specified module BTF by passing BTF pointers to struct_ops functions.,"struct_ops,BTF,module",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1338b93346587a2a6ac79bbcf55ef5b357745573,1338b93346587a2a6ac79bbcf55ef5b357745573,Kui-Feng Lee,thinker.li@gmail.com,1705704597,Martin KaFai Lau,martin.lau@kernel.org,1706056664,3200810e4d2c138d8ecec7ab4303446db88a1bf7,47f4f657acd5d04c78c5c5ac7022cba9ce3b4a7d,"bpf: pass btf object id in bpf_map_info. + +Include btf object id (btf_obj_id) in bpf_map_info so that tools (ex: +bpftools struct_ops dump) know the correct btf from the kernel to look up +type information of struct_ops types. + +Since struct_ops types can be defined and registered in a module. The +type information of a struct_ops type are defined in the btf of the +module defining it. The userspace tools need to know which btf is for +the module defining a struct_ops type. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-7-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",,The commit adds btf_obj_id to bpf_map_info for proper type information lookup by tools.,"btf_obj_id,bpf_map_info,struct_ops",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +47f4f657acd5d04c78c5c5ac7022cba9ce3b4a7d,47f4f657acd5d04c78c5c5ac7022cba9ce3b4a7d,Kui-Feng Lee,thinker.li@gmail.com,1705704596,Martin KaFai Lau,martin.lau@kernel.org,1706056664,5b68fada69c50bef366af6a183fa544887cdab12,e61995111a76633376419d1bccede8696e94e6e5,"bpf: make struct_ops_map support btfs other than btf_vmlinux. + +Once new struct_ops can be registered from modules"," btf_vmlinux is no +longer the only btf that struct_ops_map would face. st_map should remember +what btf it should use to get type information. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-6-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],The commit extends struct_ops_map to support BTFs from modules beyond btf_vmlinux.,"struct_ops_map,BTF,module",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e61995111a76633376419d1bccede8696e94e6e5,e61995111a76633376419d1bccede8696e94e6e5,Kui-Feng Lee,thinker.li@gmail.com,1705704595,Martin KaFai Lau,martin.lau@kernel.org,1706056664,9b9e91ce328a506687b11d4bb03c6f38f2b4657a,4c5763ed996a61b51d721d0968d0df957826ea49,"bpf: add struct_ops_tab to btf. + +Maintain a registry of registered struct_ops types in the per-btf (module) +struct_ops_tab. This registry allows for easy lookup of struct_ops types +that are registered by a specific module. + +It is a preparation work for supporting kernel module struct_ops in a +latter patch. Each struct_ops will be registered under its own kernel +module btf and will be stored in the newly added btf->struct_ops_tab. The +bpf verifier and bpf syscall (e.g. prog and map cmd) can find the +struct_ops and its btf type/size/id... information from +btf->struct_ops_tab. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-5-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",,This commit adds struct_ops_tab to BTF for registering and looking up struct_ops types within kernel modules.,struct_ops BTF registry,It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4c5763ed996a61b51d721d0968d0df957826ea49,4c5763ed996a61b51d721d0968d0df957826ea49,Kui-Feng Lee,thinker.li@gmail.com,1705704594,Martin KaFai Lau,martin.lau@kernel.org,1706056664,12d428d0eb3ea1e409f6f78d4545881b6acbc4b0,95678395386d45fa0a075d2e7a6866326a469d76,bpf," net: introduce bpf_struct_ops_desc. + +Move some of members of bpf_struct_ops to bpf_struct_ops_desc. type_id is +unavailabe in bpf_struct_ops anymore. Modules should get it from the btf +received by kmod's init function. + +Cc: netdev@vger.kernel.org +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-4-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],The commit updates bpf_struct_ops by moving members to bpf_struct_ops_desc and modifies BTF handling.,"bpf_struct_ops,bpf_struct_ops_desc,BTF",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +95678395386d45fa0a075d2e7a6866326a469d76,95678395386d45fa0a075d2e7a6866326a469d76,Kui-Feng Lee,thinker.li@gmail.com,1705704593,Martin KaFai Lau,martin.lau@kernel.org,1706056663,272be15c9b5ae3c0b0758ef982f48d30facc5868,3b1f89e747cd4b24244f2798a35d28815b744303,"bpf: get type information with BTF_ID_LIST + +Get ready to remove bpf_struct_ops_init() in the future. By using +BTF_ID_LIST"," it is possible to gather type information while building +instead of runtime. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-3-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Enhances BTF usage by enabling type information gathering during the build to eventually remove bpf_struct_ops_init().,"BTF_ID_LIST,type information,bpf_struct_ops_init",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),['other'] +3b1f89e747cd4b24244f2798a35d28815b744303,3b1f89e747cd4b24244f2798a35d28815b744303,Kui-Feng Lee,thinker.li@gmail.com,1705704592,Martin KaFai Lau,martin.lau@kernel.org,1706056663,8be9712b5832eaf504966010fc01e0a338eefb35,b7d1af3791036a619ca8ffde5f832111b05ca833,"bpf: refactory struct_ops type initialization to a function. + +Move the majority of the code to bpf_struct_ops_init_one()"," which can then +be utilized for the initialization of newly registered dynamically +allocated struct_ops types in the following patches. + +Signed-off-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/20240119225005.668602-2-thinker.li@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Refactor the struct_ops initialization into a dedicated function for dynamic type registration.,"refactor, struct_ops, initialization",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b7d1af3791036a619ca8ffde5f832111b05ca833,b7d1af3791036a619ca8ffde5f832111b05ca833,Alexei Starovoitov,ast@kernel.org,1706054728,Alexei Starovoitov,ast@kernel.org,1706054742,0d0caf63683de1d45c4c3aba0aa399fe2dee65c6,bbc094b3052647c188d6f155f5c09cb9492ce106 b0dc037399b19a777d569dbd9e2e9bbd62f3b3b1,"Merge branch 'bpf-add-cookies-retrieval-for-perf-kprobe-multi-links' + +Jiri Olsa says: + +==================== +bpf: Add cookies retrieval for perf/kprobe multi links + +hi"," +this patchset adds support to retrieve cookies from existing tracing +links that still did not support it plus changes to bpftool to display +them. It's leftover we discussed some time ago [1]. + +thanks","['\njirka\n\nv2 changes:\n - added review/ack tags\n - fixed memory leak [Quentin]\n - align the uapi fields properly [Yafang Shao]\n\n[1] https://lore.kernel.org/bpf/CALOAHbAZ6=A9j3VFCLoAC_WhgQKU7injMf06=cM2sU4Hi4Sx+Q@mail.gmail.com/\nReviewed-by: Quentin Monnet \n---\n====================\n\nReviewed-by: Quentin Monnet \nLink: https://lore.kernel.org/r/20240119110505.400573-1-jolsa@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit adds cookie retrieval support for perf and kprobe multi-links and updates bpftool to display them.,"cookies,retrieval,bpftool",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +b0dc037399b19a777d569dbd9e2e9bbd62f3b3b1,b0dc037399b19a777d569dbd9e2e9bbd62f3b3b1,Jiri Olsa,jolsa@kernel.org,1705662305,Alexei Starovoitov,ast@kernel.org,1706054728,0d0caf63683de1d45c4c3aba0aa399fe2dee65c6,54258324b934aa8552c239c443272ec7aea55285,"bpftool: Display cookie for kprobe multi link + +Displaying cookies for kprobe multi link"," in plain mode: + + # bpftool link + ... + 1397: kprobe_multi prog 47532 + kretprobe.multi func_cnt 3 + addr cookie func [module] + ffffffff82b370c0 3 bpf_fentry_test1 + ffffffff82b39780 1 bpf_fentry_test2 + ffffffff82b397a0 2 bpf_fentry_test3 + +And in json mode: + + # bpftool link -j | jq + ... + { + ""id"": 1397","['\n ""type"": ""kprobe_multi""', '\n ""prog_id"": 47532', '\n ""retprobe"": true', '\n ""func_cnt"": 3', '\n ""missed"": 0', '\n ""funcs"": [\n {\n ""addr"": 18446744071607382208', '\n ""func"": ""bpf_fentry_test1""', '\n ""module"": null', '\n ""cookie"": 3\n }', '\n {\n ""addr"": 18446744071607392128', '\n ""func"": ""bpf_fentry_test2""', '\n ""module"": null', '\n ""cookie"": 1\n }', '\n {\n ""addr"": 18446744071607392160', '\n ""func"": ""bpf_fentry_test3""', '\n ""module"": null', '\n ""cookie"": 2\n }\n ]\n }\n\nCookie is attached to specific address', ' and because we sort addresses\nbefore printing', ' we need to sort cookies the same way', ' hence adding\nthe struct addr_cookie to keep and sort them together.\n\nAlso adding missing dd.sym_count check to show_kprobe_multi_json.\n\nSigned-off-by: Jiri Olsa \nAcked-by: Song Liu \nLink: https://lore.kernel.org/r/20240119110505.400573-9-jolsa@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhance bpftool to display cookies for kprobe multi links in plain and JSON mode.,"bpftool,kprobe,cookie",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,['kprobe/uprobe/ftrace like programs'] +54258324b934aa8552c239c443272ec7aea55285,54258324b934aa8552c239c443272ec7aea55285,Jiri Olsa,jolsa@kernel.org,1705662304,Alexei Starovoitov,ast@kernel.org,1706054728,4301ff25445e88ff823d6c9e6814017e0f30e978,b7896486688af36e3bc5e27a6d5369cc5dcbcf69,"bpftool: Display cookie for perf event link probes + +Displaying cookie for perf event link probes"," in plain mode: + + # bpftool link + 17: perf_event prog 90 + kprobe ffffffff82b1c2b0 bpf_fentry_test1 cookie 3735928559 + 18: perf_event prog 90 + kretprobe ffffffff82b1c2b0 bpf_fentry_test1 cookie 3735928559 + 20: perf_event prog 92 + tracepoint sched_switch cookie 3735928559 + 21: perf_event prog 93 + event software:page-faults cookie 3735928559 + 22: perf_event prog 91 + uprobe /proc/self/exe+0xd703c cookie 3735928559 + +And in json mode: + + # bpftool link -j | jq + + { + ""id"": 30","['\n ""type"": ""perf_event""', '\n ""prog_id"": 160', '\n ""retprobe"": false', '\n ""addr"": 18446744071607272112', '\n ""func"": ""bpf_fentry_test1""', '\n ""offset"": 0', '\n ""missed"": 0', '\n ""cookie"": 3735928559\n }\n\n {\n ""id"": 33', '\n ""type"": ""perf_event""', '\n ""prog_id"": 162', '\n ""tracepoint"": ""sched_switch""', '\n ""cookie"": 3735928559\n }\n\n {\n ""id"": 34', '\n ""type"": ""perf_event""', '\n ""prog_id"": 163', '\n ""event_type"": ""software""', '\n ""event_config"": ""page-faults""', '\n ""cookie"": 3735928559\n }\n\n {\n ""id"": 35', '\n ""type"": ""perf_event""', '\n ""prog_id"": 161', '\n ""retprobe"": false', '\n ""file"": ""/proc/self/exe""', '\n ""offset"": 880700', '\n ""cookie"": 3735928559\n }\n\nReviewed-by: Quentin Monnet \nSigned-off-by: Jiri Olsa \nAcked-by: Song Liu \nLink: https://lore.kernel.org/r/20240119110505.400573-8-jolsa@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit adds a feature to display cookies for perf event links in bpftool.,"bpftool, perf event, cookie",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,['kprobe/uprobe/ftrace like programs'] +b7896486688af36e3bc5e27a6d5369cc5dcbcf69,b7896486688af36e3bc5e27a6d5369cc5dcbcf69,Jiri Olsa,jolsa@kernel.org,1705662303,Alexei Starovoitov,ast@kernel.org,1706054728,fc35b13c4c2420472d3cfba90a888fdf688fec64,d74179708473c649c653f1db280e29875a532e99,"selftests/bpf: Add fill_link_info test for perf event + +Adding fill_link_info test for perf event and testing we +get its values back through the bpf_link_info interface. + +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-7-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add test case to verify bpf_link_info values for perf events.,"fill_link_info, perf event, bpf_link_info",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +d74179708473c649c653f1db280e29875a532e99,d74179708473c649c653f1db280e29875a532e99,Jiri Olsa,jolsa@kernel.org,1705662302,Alexei Starovoitov,ast@kernel.org,1706054727,c3506f046691e6866ce1c6e2aa16e32c0991253b,59a89706c40c153a74a3a9570b4d696cf9eebb0b,"selftests/bpf: Add cookies check for perf_event fill_link_info test + +Now that we get cookies for perf_event probes"," adding tests +for cookie for kprobe/uprobe/tracepoint. + +The perf_event test needs to be added completely and is coming +in following change. + +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-6-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add selftest for cookies check in perf_event fill_link_info for kprobe/uprobe/tracepoint.,"cookies, perf_event, tests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['kprobe/uprobe/ftrace like programs', 'tracepoints like programs']" +59a89706c40c153a74a3a9570b4d696cf9eebb0b,59a89706c40c153a74a3a9570b4d696cf9eebb0b,Jiri Olsa,jolsa@kernel.org,1705662301,Alexei Starovoitov,ast@kernel.org,1706054727,ce1a51a3cbe58add05cd1be9abf04f9585144600,2adb2e0fcdf3c6d8e28a5a9c33e458e1037ae5ad,"selftests/bpf: Add cookies check for kprobe_multi fill_link_info test + +Adding cookies check for kprobe_multi fill_link_info test"," +plus tests for invalid values related to cookies. + +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-5-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add cookies check and tests for kprobe_multi fill_link_info in selftests/bpf.,"cookies,kprobe_multi,tests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +2adb2e0fcdf3c6d8e28a5a9c33e458e1037ae5ad,2adb2e0fcdf3c6d8e28a5a9c33e458e1037ae5ad,Jiri Olsa,jolsa@kernel.org,1705662300,Alexei Starovoitov,ast@kernel.org,1706054727,a22f6d48ba9745fd24a348248113671c63d40802,9fd112b1f82b587ffb12fb67dd032f551fdb571a,"bpftool: Fix wrong free call in do_show_link + +The error path frees wrong array"," it should be ref_ctr_offsets. + +Acked-by: Yafang Shao +Reviewed-by: Quentin Monnet +Fixes: a7795698f8b6 (""bpftool: Add support to display uprobe_multi links"") +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-4-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Fixed incorrect memory deallocation in bpftool's do_show_link function.,"bpftool, free call, do_show_link",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9fd112b1f82b587ffb12fb67dd032f551fdb571a,9fd112b1f82b587ffb12fb67dd032f551fdb571a,Jiri Olsa,jolsa@kernel.org,1705662299,Alexei Starovoitov,ast@kernel.org,1706054727,d8abc67a33285f67e790a48f801488c73c70b6e6,d5c16492c66fbfca85f36e42363d32212df5927b,"bpf: Store cookies in kprobe_multi bpf_link_info data + +Storing cookies in kprobe_multi bpf_link_info data. The cookies +field is optional and if provided it needs to be an array of +__u64 with kprobe_multi.count length. + +Acked-by: Yafang Shao +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Link: https://lore.kernel.org/r/20240119110505.400573-3-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov +",,Store optional cookies array in kprobe_multi bpf_link_info data for better tracking.,"cookies,kprobe_multi,bpf_link_info",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +d5c16492c66fbfca85f36e42363d32212df5927b,d5c16492c66fbfca85f36e42363d32212df5927b,Jiri Olsa,jolsa@kernel.org,1705662298,Alexei Starovoitov,ast@kernel.org,1706054727,9b3398711339bf2660ed056fee3d49eff741d153,bbc094b3052647c188d6f155f5c09cb9492ce106,"bpf: Add cookie to perf_event bpf_link_info records + +At the moment we don't store cookie for perf_event probes"," +while we do that for the rest of the probes. + +Adding cookie fields to struct bpf_link_info perf event +probe records: + + perf_event.uprobe + perf_event.kprobe + perf_event.tracepoint + perf_event.perf_event + +And the code to store that in bpf_link_info struct. + +Signed-off-by: Jiri Olsa +Acked-by: Song Liu +Acked-by: Yafang Shao +Link: https://lore.kernel.org/r/20240119110505.400573-2-jolsa@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add cookie field to perf_event bpf_link_info records for more event probe types.,"cookie,perf_event,bpf_link_info",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['kprobe/uprobe/ftrace like programs', 'tracepoints like programs', 'profile like programs']" +bbc094b3052647c188d6f155f5c09cb9492ce106,bbc094b3052647c188d6f155f5c09cb9492ce106,Jose E. Marchesi,jose.marchesi@oracle.com,1706033589,Alexei Starovoitov,ast@kernel.org,1706054146,41826ba20b74c0663b8cdf0a13b8c09e710702a1,756e34da5380e4c0ed2cfbe5259e1b015567a099,"bpf: Use r constraint instead of p constraint in selftests + +Some of the BPF selftests use the ""p"" constraint in inline assembly +snippets"," for input operands for MOV (rN = rM) instructions. + +This is mainly done via the __imm_ptr macro defined in +tools/testing/selftests/bpf/progs/bpf_misc.h: + + #define __imm_ptr(name) [name]""p""(&name) + +Example: + + int consume_first_item_only(void *ctx) + { + struct bpf_iter_num iter; + asm volatile ( + /* create iterator */ + ""r1 = %[iter];"" + [...] + : + : __imm_ptr(iter) + : CLOBBERS); + [...] + } + +The ""p"" constraint is a tricky one. It is documented in the GCC manual +section ""Simple Constraints"": + + An operand that is a valid memory address is allowed. This is for + ``load address'' and ``push address'' instructions. + + p in the constraint must be accompanied by address_operand as the + predicate in the match_operand. This predicate interprets the mode + specified in the match_operand as the mode of the memory reference for + which the address would be valid. + +There are two problems: + +1. It is questionable whether that constraint was ever intended to be + used in inline assembly templates","[' because its behavior really\n depends on compiler internals. A ""memory address"" is not the same\n than a ""memory operand"" or a ""memory reference"" (constraint ""m"")', ' and\n in fact its usage in the template above results in an error in both\n x86_64-linux-gnu and bpf-unkonwn-none:\n\n foo.c: In function ‘bar’:\n foo.c:6:3: error: invalid \'asm\': invalid expression as operand\n 6 | asm volatile (""r1 = %[jorl]"" : : [jorl]""p""(&jorl));\n | ^~~\n\n I would assume the same happens with aarch64', ' riscv', ' and most/all\n other targets in GCC', ' that do not accept operands of the form A + B\n that are not wrapped either in a const or in a memory reference.\n\n To avoid that error', ' the usage of the ""p"" constraint in internal GCC\n instruction templates is supposed to be complemented by the \'a\'\n modifier', ' like in:\n\n asm volatile (""r1 = %a[jorl]"" : : [jorl]""p""(&jorl));\n\n Internally documented (in GCC\'s final.cc) as:\n\n %aN means expect operand N to be a memory address\n (not a memory reference!) and print a reference\n to that address.\n\n That works because when the modifier \'a\' is found', ' GCC prints an\n ""operand address""', ' which is not the same than an ""operand"".\n\n But...\n\n2. Even if we used the internal \'a\' modifier (we shouldn\'t) the \'rN =\n rM\' instruction really requires a register argument. In cases\n involving automatics', ' like in the examples above', ' we easily end with:\n\n bar:\n #APP\n r1 = r10-4\n #NO_APP\n\n In other cases we could conceibly also end with a 64-bit label that\n may overflow the 32-bit immediate operand of `rN = imm32\'\n instructions:\n\n r1 = foo\n\n All of which is clearly wrong.\n\nclang happens to do ""the right thing"" in the current usage of __imm_ptr\nin the BPF tests', ' because even with -O2 it seems to ""reload"" the\nfp-relative address of the automatic to a register like in:\n\n bar:\n\tr1 = r10\n\tr1 += -4\n\t#APP\n\tr1 = r1\n\t#NO_APP\n\nWhich is what GCC would generate with -O0. Whether this is by chance\nor by design', ' the compiler shouln\'t be expected to do that reload\ndriven by the ""p"" constraint.\n\nThis patch changes the usage of the ""p"" constraint in the BPF\nselftests macros to use the ""r"" constraint instead. If a register is\nwhat is required', ' we should let the compiler know.\n\nPrevious discussion in bpf@vger:\nhttps://lore.kernel.org/bpf/87h6p5ebpb.fsf@oracle.com/T/#ef0df83d6975c34dff20bf0dd52e078f5b8ca2767\n\nTested in bpf-next master.\nNo regressions.\n\nSigned-off-by: Jose E. Marchesi \nCc: Yonghong Song \nCc: Eduard Zingerman \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240123181309.19853-1-jose.marchesi@oracle.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit replaces 'p' constraint with 'r' constraint in BPF selftests inline assembly for better compatibility and correctness.,"BPF,selftests,constraint",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +756e34da5380e4c0ed2cfbe5259e1b015567a099,756e34da5380e4c0ed2cfbe5259e1b015567a099,Jose E. Marchesi,jose.marchesi@oracle.com,1706043384,Alexei Starovoitov,ast@kernel.org,1706053984,7a2fa6f17bda4a2e9fd2f656aebe254ad62e1c61,edb799035dd7d41c3e81e1bef83e2a2120b08abb,"bpf: fix constraint in test_tcpbpf_kern.c + +GCC emits a warning: + + progs/test_tcpbpf_kern.c:60:9: error: ‘op’ is used uninitialized [-Werror=uninitialized] + +when an uninialized op is used with a ""+r"" constraint. The + modifier +means a read-write operand"," but that operand in the selftest is just +written to. + +This patch changes the selftest to use a ""=r"" constraint. This +pacifies GCC. + +Tested in bpf-next master. +No regressions. + +Signed-off-by: Jose E. Marchesi +Cc: Yonghong Song +Cc: Eduard Zingerman +Cc: david.faust@oracle.com +Cc: cupertino.miranda@oracle.com +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240123205624.14746-1-jose.marchesi@oracle.com +Signed-off-by: Alexei Starovoitov +",[''],Fixed a GCC warning by changing a constraint in a selftest for BPF.,"GCC, constraint, selftest",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +edb799035dd7d41c3e81e1bef83e2a2120b08abb,edb799035dd7d41c3e81e1bef83e2a2120b08abb,Jose E. Marchesi,jose.marchesi@oracle.com,1706041049,Alexei Starovoitov,ast@kernel.org,1706053847,2b59e35655f7dd697e9e22c894ee7dd0570b9606,bc308d011ab8cc61bf1be15a2920bcd7d7b9b9d3,"bpf: avoid VLAs in progs/test_xdp_dynptr.c + +VLAs are not supported by either the BPF port of clang nor GCC. The +selftest test_xdp_dynptr.c contains the following code: + + const size_t tcphdr_sz = sizeof(struct tcphdr); + const size_t udphdr_sz = sizeof(struct udphdr); + const size_t ethhdr_sz = sizeof(struct ethhdr); + const size_t iphdr_sz = sizeof(struct iphdr); + const size_t ipv6hdr_sz = sizeof(struct ipv6hdr); + + [...] + + static __always_inline int handle_ipv4(struct xdp_md *xdp"," struct bpf_dynptr *xdp_ptr) + { + __u8 eth_buffer[ethhdr_sz + iphdr_sz + ethhdr_sz]; + __u8 iph_buffer_tcp[iphdr_sz + tcphdr_sz]; + __u8 iph_buffer_udp[iphdr_sz + udphdr_sz]; + [...] + } + +The eth_buffer","[' iph_buffer_tcp and other automatics are fixed size\nonly if the compiler optimizes away the constant global variables.\nclang does this', ' but GCC does not', ' turning these automatics into\nvariable length arrays.\n\nThis patch removes the global variables and turns these values into\npreprocessor constants. This makes the selftest to build properly\nwith GCC.\n\nTested in bpf-next master.\nNo regressions.\n\nSigned-off-by: Jose E. Marchesi \nCc: Yonghong Song \nCc: Eduard Zingerman \nCc: david.faust@oracle.com\nCc: cupertino.miranda@oracle.com\nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240123201729.16173-1-jose.marchesi@oracle.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit removes VLAs from the test_xdp_dynptr.c to maintain compatibility with BPF port of clang and GCC.,"VLAs,selftest,compatibility",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['xdp like programs'] +bc308d011ab8cc61bf1be15a2920bcd7d7b9b9d3,bc308d011ab8cc61bf1be15a2920bcd7d7b9b9d3,Andrii Nakryiko,andrii@kernel.org,1705698121,Alexei Starovoitov,ast@kernel.org,1706051627,54d3d250ff01c286ac139a659b9ed24af74b9b46,c80c6434aaccc689b2c7ff432d43abad8f4217b2,"libbpf: call dup2() syscall directly + +We've ran into issues with using dup2() API in production setting"," where +libbpf is linked into large production environment and ends up calling +unintended custom implementations of dup2(). These custom implementations +don't provide atomic FD replacement guarantees of dup2() syscall","['\nleading to subtle and hard to debug issues.\n\nTo prevent this in the future and guarantee that no libc implementation\nwill do their own custom non-atomic dup2() implementation', "" call dup2()\nsyscall directly with syscall(SYS_dup2).\n\nNote that some architectures don't seem to provide dup2 and have dup3\ninstead. Try to detect and pick best syscall.\n\nSigned-off-by: Andrii Nakryiko \nAcked-by: Song Liu \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240119210201.1295511-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']","The commit alters libbpf to directly use the dup2() syscall, bypassing custom implementations causing production issues.","libbpf, dup2, syscall",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c80c6434aaccc689b2c7ff432d43abad8f4217b2,c80c6434aaccc689b2c7ff432d43abad8f4217b2,Alexei Starovoitov,ast@kernel.org,1706051483,Alexei Starovoitov,ast@kernel.org,1706051483,eabaee12da6ad1bd91e948cab9a6d99f13e5c979,20e109ea9842158a153b24ef42ec5cc3d44e9485 29f868887a7dd3efc6faecc6fc91b28fc25cf5b0,"Merge branch 'enable-the-inline-of-kptr_xchg-for-arm64' + +Hou Tao says: + +==================== +Enable the inline of kptr_xchg for arm64 + +From: Hou Tao + +Hi"," + +The patch set is just a follow-up for ""bpf: inline bpf_kptr_xchg()"". It +enables the inline of bpf_kptr_xchg() and kptr_xchg_inline test for +arm64. + +Please see individual patches for more details. And comments are always +welcome. +==================== + +Link: https://lore.kernel.org/r/20240119102529.99581-1-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Enable inline support for bpf_kptr_xchg() on arm64 architecture.,"bpf_kptr_xchg, inline, arm64",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +29f868887a7dd3efc6faecc6fc91b28fc25cf5b0,29f868887a7dd3efc6faecc6fc91b28fc25cf5b0,Hou Tao,houtao1@huawei.com,1705659929,Alexei Starovoitov,ast@kernel.org,1706051483,eabaee12da6ad1bd91e948cab9a6d99f13e5c979,18a45f12d746c06b7361b0cce59cf8e8b9e38da6,"selftests/bpf: Enable kptr_xchg_inline test for arm64 + +Now arm64 bpf jit has enable bpf_jit_supports_ptr_xchg()"," so enable +the test for arm64 as well. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20240119102529.99581-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Enable kptr_xchg_inline test for arm64 in bpf selftests after JIT support update.,"kptr_xchg_inline, arm64, bpf_jit",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +18a45f12d746c06b7361b0cce59cf8e8b9e38da6,18a45f12d746c06b7361b0cce59cf8e8b9e38da6,Hou Tao,houtao1@huawei.com,1705659928,Alexei Starovoitov,ast@kernel.org,1706051483,58dc3aeffe29eb0e935fb73bb024be2a376f8145,20e109ea9842158a153b24ef42ec5cc3d44e9485,bpf," arm64: Enable the inline of bpf_kptr_xchg() + +ARM64 bpf jit satisfies the following two conditions: +1) support BPF_XCHG() on pointer-sized word. +2) the implementation of xchg is the same as atomic_xchg() on + pointer-sized words. Both of these two functions use arch_xchg() to + implement the exchange. + +So enable the inline of bpf_kptr_xchg() for arm64 bpf jit. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20240119102529.99581-2-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Enable inline implementation of bpf_kptr_xchg for arm64 bpf jit.,"bpf_kptr_xchg,ARM64,JIT",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +20e109ea9842158a153b24ef42ec5cc3d44e9485,20e109ea9842158a153b24ef42ec5cc3d44e9485,Dave Thaler,dthaler1968@googlemail.com,1705620594,Alexei Starovoitov,ast@kernel.org,1706051408,ba89b7c2fba858d3ad06c588e2cf7c5621ca0a84,b3f086a7a136d721d112f35fe4cd7272e93cf06b,bpf," docs: Clarify that MOVSX is only for BPF_X not BPF_K + +Per discussion on the mailing list at +https://mailarchive.ietf.org/arch/msg/bpf/uQiqhURdtxV_ZQOTgjCdm-seh74/ +the MOVSX operation is only defined to support register extension. + +The document didn't previously state this and incorrectly implied +that one could use an immediate value. + +Signed-off-by: Dave Thaler +Acked-by: David Vernet +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20240118232954.27206-1-dthaler1968@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],"Clarified documentation for MOVSX operation to indicate it's only for BPF_X, not BPF_K.","MOVSX,BPF_X,BPF_K",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +b3f086a7a136d721d112f35fe4cd7272e93cf06b,b3f086a7a136d721d112f35fe4cd7272e93cf06b,Kuniyuki Iwashima,kuniyu@amazon.com,1705612671,Alexei Starovoitov,ast@kernel.org,1706051283,bb5a1af3bcae81082c1c5dc901ce4aa54fa3a93c,2ce793ebe207328b1210bb53effd702740987148,"bpf: Define struct bpf_tcp_req_attrs when CONFIG_SYN_COOKIES=n. + +kernel test robot reported the warning below: + + >> net/core/filter.c:11842:13: warning: declaration of 'struct bpf_tcp_req_attrs' will not be visible outside of this function [-Wvisibility] + 11842 | struct bpf_tcp_req_attrs *attrs"," int attrs__sz) + | ^ + 1 warning generated. + +struct bpf_tcp_req_attrs is defined under CONFIG_SYN_COOKIES +but used in kfunc without the config. + +Let's move struct bpf_tcp_req_attrs definition outside of +CONFIG_SYN_COOKIES guard. + +Fixes: e472f88891ab (""bpf: tcp: Support arbitrary SYN Cookie."") +Reported-by: kernel test robot +Closes: https://lore.kernel.org/oe-kbuild-all/202401180418.CUVc0hxF-lkp@intel.com/ +Signed-off-by: Kuniyuki Iwashima +Link: https://lore.kernel.org/r/20240118211751.25790-1-kuniyu@amazon.com +Signed-off-by: Alexei Starovoitov +",[''],Fix visibility issue by defining struct bpf_tcp_req_attrs outside CONFIG_SYN_COOKIES guard.,"struct bpf_tcp_req_attrs, visibility, CONFIG_SYN_COOKIES",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2ce793ebe207328b1210bb53effd702740987148,2ce793ebe207328b1210bb53effd702740987148,Hao Sun,sunhao.th@gmail.com,1705484412,Alexei Starovoitov,ast@kernel.org,1706050899,b3f25ff4be3cc4edd51e70d5c1330e31cfae9742,40628f9fff73adecac77a9aa390f8016724cad99,"bpf: Refactor ptr alu checking rules to allow alu explicitly + +Current checking rules are structured to disallow alu on particular ptr +types explicitly"," so default cases are allowed implicitly. This may lead +to newly added ptr types being allowed unexpectedly. So restruture it to +allow alu explicitly. The tradeoff is mainly a bit more cases added in +the switch. The following table from Eduard summarizes the rules: + + | Pointer type | Arithmetics allowed | + |---------------------+---------------------| + | PTR_TO_CTX | yes | + | CONST_PTR_TO_MAP | conditionally | + | PTR_TO_MAP_VALUE | yes | + | PTR_TO_MAP_KEY | yes | + | PTR_TO_STACK | yes | + | PTR_TO_PACKET_META | yes | + | PTR_TO_PACKET | yes | + | PTR_TO_PACKET_END | no | + | PTR_TO_FLOW_KEYS | conditionally | + | PTR_TO_SOCKET | no | + | PTR_TO_SOCK_COMMON | no | + | PTR_TO_TCP_SOCK | no | + | PTR_TO_TP_BUFFER | yes | + | PTR_TO_XDP_SOCK | no | + | PTR_TO_BTF_ID | yes | + | PTR_TO_MEM | yes | + | PTR_TO_BUF | yes | + | PTR_TO_FUNC | yes | + | CONST_PTR_TO_DYNPTR | yes | + +The refactored rules are equivalent to the original one. Note that +PTR_TO_FUNC and CONST_PTR_TO_DYNPTR are not reject here because: (1) +check_mem_access() rejects load/store on those ptrs","[' and those ptrs\nwith offset passing to calls are rejected check_func_arg_reg_off();\n(2) someone may rely on the verifier not rejecting programs earily.\n\nSigned-off-by: Hao Sun \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240117094012.36798-1-sunhao.th@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Refactor ptr alu checking rules to explicitly allow certain arithmetic operations on pointer types in eBPF.,"pointer, alu, refactor",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +40628f9fff73adecac77a9aa390f8016724cad99,40628f9fff73adecac77a9aa390f8016724cad99,Andrey Grafin,conquistador@yandex-team.ru,1705496779,Alexei Starovoitov,ast@kernel.org,1706049792,c960edc3617755ecdff1b2bcf9c14d24172e586b,f04deb90e516e8e48bf8693397529bc942a9e80b,"selftest/bpf: Add map_in_maps with BPF_MAP_TYPE_PERF_EVENT_ARRAY values + +Check that bpf_object__load() successfully creates map_in_maps +with BPF_MAP_TYPE_PERF_EVENT_ARRAY values. +These changes cover fix in the previous patch +""libbpf: Apply map_set_def_max_entries() for inner_maps on creation"". + +A command line output is: +- w/o fix +$ sudo ./test_maps +libbpf: map 'mim_array_pe': failed to create inner map: -22 +libbpf: map 'mim_array_pe': failed to create: Invalid argument(-22) +libbpf: failed to load object './test_map_in_map.bpf.o' +Failed to load test prog + +- with fix +$ sudo ./test_maps +... +test_maps: OK"," 0 SKIPPED + +Fixes: 646f02ffdd49 (""libbpf: Add BTF-defined map-in-map support"") +Signed-off-by: Andrey Grafin +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: Hou Tao +Link: https://lore.kernel.org/bpf/20240117130619.9403-2-conquistador@yandex-team.ru +Signed-off-by: Alexei Starovoitov +",[''],Adds selftest to ensure map_in_maps with BPF_MAP_TYPE_PERF_EVENT_ARRAY values are correctly loaded.,"selftest,map_in_maps,PERF_EVENT_ARRAY",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f04deb90e516e8e48bf8693397529bc942a9e80b,f04deb90e516e8e48bf8693397529bc942a9e80b,Andrey Grafin,conquistador@yandex-team.ru,1705496778,Alexei Starovoitov,ast@kernel.org,1706049792,f69af605856dedb79f0f1a0f767cd94503fb01c2,091f2bf60d52ac205c48dffcb8646ed9299078c9,"libbpf: Apply map_set_def_max_entries() for inner_maps on creation + +This patch allows to auto create BPF_MAP_TYPE_ARRAY_OF_MAPS and +BPF_MAP_TYPE_HASH_OF_MAPS with values of BPF_MAP_TYPE_PERF_EVENT_ARRAY +by bpf_object__load(). + +Previous behaviour created a zero filled btf_map_def for inner maps and +tried to use it for a map creation but the linux kernel forbids to create +a BPF_MAP_TYPE_PERF_EVENT_ARRAY map with max_entries=0. + +Fixes: 646f02ffdd49 (""libbpf: Add BTF-defined map-in-map support"") +Signed-off-by: Andrey Grafin +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: Hou Tao +Link: https://lore.kernel.org/bpf/20240117130619.9403-1-conquistador@yandex-team.ru +Signed-off-by: Alexei Starovoitov +",,This commit updates libbpf to correctly set max_entries for inner maps on creation.,"libbpf, inner_maps, max_entries",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +091f2bf60d52ac205c48dffcb8646ed9299078c9,091f2bf60d52ac205c48dffcb8646ed9299078c9,Daniel Borkmann,daniel@iogearbox.net,1705482971,Alexei Starovoitov,ast@kernel.org,1706049792,ddeb882389e6364b536cff7f5259eeb7108f735f,f98df79bf7f772597313adca2720cb38770490dd,"bpf: Sync uapi bpf.h header for the tooling infra + +Both commit 91051f003948 (""tcp: Dump bound-only sockets in inet_diag."") +and commit 985b8ea9ec7e (""bpf"," docs: Fix bpf_redirect_peer header doc"") +missed the tooling header sync. Fix it. + +Signed-off-by: Daniel Borkmann +Signed-off-by: Alexei Starovoitov +",[''],Sync the uapi bpf.h header for the tooling infrastructure to fix missed commits.,"sync, tooling, header",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f98df79bf7f772597313adca2720cb38770490dd,f98df79bf7f772597313adca2720cb38770490dd,Victor Stewart,v@nametag.social,1705436992,Alexei Starovoitov,ast@kernel.org,1706049792,4bd5d27f3e34ce6a567e1cdfb3c4a0d0c08278bd,4eaafe5a5b7b5f2fcec22914bc5b8b2d860896b7,bpf," docs: Fix bpf_redirect_peer header doc + +Amend the bpf_redirect_peer() header documentation to also mention +support for the netkit device type. + +Signed-off-by: Victor Stewart +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20240116202952.241009-1-v@nametag.social +Signed-off-by: Alexei Starovoitov +",[''],Amend the bpf_redirect_peer header documentation to mention netkit device support.,"bpf_redirect_peer, header, documentation",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4eaafe5a5b7b5f2fcec22914bc5b8b2d860896b7,4eaafe5a5b7b5f2fcec22914bc5b8b2d860896b7,Martin KaFai Lau,martin.lau@kernel.org,1705444960,Alexei Starovoitov,ast@kernel.org,1706049771,e9af2ccb810881632330d014ecc83b1726537a16,d177c1be06ce28aa8c8710ac55be1b5ad3f314c6 a74712241b4675175cd8e3310fa206d8756ad5a1,"Merge branch 'bpf: tcp: Support arbitrary SYN Cookie at TC.' + +Kuniyuki Iwashima says: + +==================== +Under SYN Flood"," the TCP stack generates SYN Cookie to remain stateless +for the connection request until a valid ACK is responded to the SYN+ACK. + +The cookie contains two kinds of host-specific bits","[' a timestamp and\nsecrets', ' so only can it be validated by the generator. It means SYN\nCookie consumes network resources between the client and the server;\nintermediate nodes must remember which nodes to route ACK for the cookie.\n\nSYN Proxy reduces such unwanted resource allocation by handling 3WHS at\nthe edge network. After SYN Proxy completes 3WHS', ' it forwards SYN to the\nbackend server and completes another 3WHS. However', "" since the server's\nISN differs from the cookie"", ' the proxy must manage the ISN mappings and\nfix up SEQ/ACK numbers in every packet for each connection. If a proxy\nnode goes down', ' all the connections through it are terminated. Keeping\na state at proxy is painful from that perspective.\n\nAt AWS', ' we use a dirty hack to build truly stateless SYN Proxy at scale.\nOur SYN Proxy consists of the front proxy layer and the backend kernel\nmodule. (See slides of LPC2023 [0]', "" p37 - p48)\n\nThe cookie that SYN Proxy generates differs from the kernel's cookie in\nthat it contains a secret (called rolling salt) (i) shared by all the proxy\nnodes so that any node can validate ACK and (ii) updated periodically so\nthat old cookies cannot be validated and we need not encode a timestamp for\nthe cookie. Also"", ' ISN contains WScale', ' SACK', ' and ECN', ' not in TS val. This\nis not to sacrifice any connection quality', ' where some customers turn off\nTCP timestamps option due to retro CVE.\n\nAfter 3WHS', ' the proxy restores SYN', ' encapsulates ACK into SYN', ' and forward\nthe TCP-in-TCP packet to the backend server. Our kernel module works at\nNetfilter input/output hooks and first feeds SYN to the TCP stack to\ninitiate 3WHS. When the module is triggered for SYN+ACK', "" it looks up the\ncorresponding request socket and overwrites tcp_rsk(req)->snt_isn with the\nproxy's cookie. Then"", ' the module can complete 3WHS with the original ACK\nas is.\n\nThis way', "" our SYN Proxy does not manage the ISN mappings nor wait for\nSYN+ACK from the backend thus can remain stateless. It's working very\nwell for high-bandwidth services like multiple Tbps"", ' but we are looking\nfor a way to drop the dirty hack and further optimise the sequences.\n\nIf we could validate an arbitrary SYN Cookie on the backend server with\nBPF', ' the proxy would need not restore SYN nor pass it. After validating\nACK', ' the proxy node just needs to forward it', ' and then the server can do\nthe lightweight validation (e.g. check if ACK came from proxy nodes', ' etc)\nand create a connection from the ACK.\n\nThis series allows us to create a full sk from an arbitrary SYN Cookie', '\nwhich is done in 3 steps.\n\n 1) At tc', ' BPF prog calls a new kfunc to create a reqsk and configure\n it based on the argument populated from SYN Cookie. The reqsk has\n its listener as req->rsk_listener and is passed to the TCP stack as\n skb->sk.\n\n 2) During TCP socket lookup for the skb', ' skb_steal_sock() returns a\n listener in the reuseport group that inet_reqsk(skb->sk)->rsk_listener\n belongs to.\n\n 3) In cookie_v[46]_check()', ' the reqsk (skb->sk) is fully initialised and\n a full sk is created.\n\nThe kfunc usage is as follows:\n\n struct bpf_tcp_req_attrs attrs = {\n .mss = mss', '\n .wscale_ok = wscale_ok', '\n .rcv_wscale = rcv_wscale', "" /* Server's WScale < 15 */\n .snd_wscale = snd_wscale"", "" /* Client's WScale < 15 */\n .tstamp_ok = tstamp_ok"", '\n .rcv_tsval = tsval', '\n .rcv_tsecr = tsecr', "" /* Server's Initial TSval */\n .usec_ts_ok = usec_ts_ok"", '\n .sack_ok = sack_ok', '\n .ecn_ok = ecn_ok', '\n }\n\n skc = bpf_skc_lookup_tcp(...);\n sk = (struct sock *)bpf_skc_to_tcp_sock(skc);\n bpf_sk_assign_tcp_reqsk(skb', ' sk', ' attrs', "" sizeof(attrs));\n bpf_sk_release(skc);\n\n[0]: https://lpc.events/event/17/contributions/1645/attachments/1350/2701/SYN_Proxy_at_Scale_with_BPF.pdf\n\nChanges:\n v8\n * Rebase on Yonghong's cpuv4 fix\n * Patch 5\n * Fill the trailing 3-bytes padding in struct bpf_tcp_req_attrs\n and test it as null\n * Patch 6\n * Remove unused IPPROTP_MPTCP definition\n\n v7: https://lore.kernel.org/bpf/20231221012806.37137-1-kuniyu@amazon.com/\n * Patch 5 & 6\n * Drop MPTCP support\n\n v6: https://lore.kernel.org/bpf/20231214155424.67136-1-kuniyu@amazon.com/\n * Patch 5 & 6\n * /struct /s/tcp_cookie_attributes/bpf_tcp_req_attrs/\n * Don't reuse struct tcp_options_received and use u8 for each attrs\n * Patch 6\n * Check retval of test__start_subtest()\n\n v5: https://lore.kernel.org/netdev/20231211073650.90819-1-kuniyu@amazon.com/\n * Split patch 1-3\n * Patch 3\n * Clear req->rsk_listener in skb_steal_sock()\n * Patch 4 & 5\n * Move sysctl validation and tsoff init from cookie_bpf_check() to kfunc\n * Patch 5\n * Do not increment LINUX_MIB_SYNCOOKIES(RECV|FAILED)\n * Patch 6\n * Remove __always_inline\n * Test if tcp_handle_{syn"", ""ack}() is executed\n * Move some definition to bpf_tracing_net.h\n * s/BPF_F_CURRENT_NETNS/-1/\n\n v4: https://lore.kernel.org/bpf/20231205013420.88067-1-kuniyu@amazon.com/\n * Patch 1 & 2\n * s/CONFIG_SYN_COOKIE/CONFIG_SYN_COOKIES/\n * Patch 1\n * Don't set rcv_wscale for BPF SYN Cookie case.\n * Patch 2\n * Add test for tcp_opt.{unused"", 'rcv_wscale} in kfunc\n * Modify skb_steal_sock() to avoid resetting skb-sk\n * Support SO_REUSEPORT lookup\n * Patch 3\n * Add CONFIG_SYN_COOKIES to Kconfig for CI\n * Define BPF_F_CURRENT_NETNS\n\n v3: https://lore.kernel.org/netdev/20231121184245.69569-1-kuniyu@amazon.com/\n * Guard kfunc and req->syncookie part in inet6?_steal_sock() with\n CONFIG_SYN_COOKIE\n\n v2: https://lore.kernel.org/netdev/20231120222341.54776-1-kuniyu@amazon.com/\n * Drop SOCK_OPS and move SYN Cookie validation logic to TC with kfunc.\n * Add cleanup patches to reduce discrepancy between cookie_v[46]_check()\n\n v1: https://lore.kernel.org/bpf/20231013220433.70792-1-kuniyu@amazon.com/\n====================\n\nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Alexei Starovoitov \n', '']",Support added for arbitrary SYN Cookie in TCP under TC to handle SYN Floods.,"SYN Cookie, TCP, TC",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['tc/netfilter like programs'] +a74712241b4675175cd8e3310fa206d8756ad5a1,a74712241b4675175cd8e3310fa206d8756ad5a1,Kuniyuki Iwashima,kuniyu@amazon.com,1705352114,Alexei Starovoitov,ast@kernel.org,1706049624,e9af2ccb810881632330d014ecc83b1726537a16,e472f88891abbc535a5e16a68a104073985f6061,"selftest: bpf: Test bpf_sk_assign_tcp_reqsk(). + +This commit adds a sample selftest to demonstrate how we can use +bpf_sk_assign_tcp_reqsk() as the backend of SYN Proxy. + +The test creates IPv4/IPv6 x TCP connections and transfer messages +over them on lo with BPF tc prog attached. + +The tc prog will process SYN and returns SYN+ACK with the following +ISN and TS. In a real use case"," this part will be done by other +hosts. + + MSB LSB + ISN: | 31 ... 8 | 7 6 | 5 | 4 | 3 2 1 0 | + | Hash_1 | MSS | ECN | SACK | WScale | + + TS: | 31 ... 8 | 7 ... 0 | + | Random | Hash_2 | + + WScale in SYN is reused in SYN+ACK. + +The client returns ACK","["" and tc prog will recalculate ISN and TS\nfrom ACK and validate SYN Cookie.\n\nIf it's valid"", ' the prog calls kfunc to allocate a reqsk for skb and\nconfigure the reqsk based on the argument created from SYN Cookie.\n\nLater', ' the reqsk will be processed in cookie_v[46]_check() to create\na connection.\n\nSigned-off-by: Kuniyuki Iwashima \nLink: https://lore.kernel.org/r/20240115205514.68364-7-kuniyu@amazon.com\nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Alexei Starovoitov \n', '']",This commit adds a selftest for bpf_sk_assign_tcp_reqsk function using BPF tc program for TCP SYN Proxy backend.,"selftest,BPF tc,bpf_sk_assign_tcp_reqsk",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tc/netfilter like programs'] +e472f88891abbc535a5e16a68a104073985f6061,e472f88891abbc535a5e16a68a104073985f6061,Kuniyuki Iwashima,kuniyu@amazon.com,1705352113,Alexei Starovoitov,ast@kernel.org,1706049624,bf5fa7d7e631cb74d6bc29759fd1cfefc7927d3b,695751e31a63efd2bbe6779873adf1e4deb00cd5,"bpf: tcp: Support arbitrary SYN Cookie. + +This patch adds a new kfunc available at TC hook to support arbitrary +SYN Cookie. + +The basic usage is as follows: + + struct bpf_tcp_req_attrs attrs = { + .mss = mss"," + .wscale_ok = wscale_ok","['\n .rcv_wscale = rcv_wscale', "" /* Server's WScale < 15 */\n .snd_wscale = snd_wscale"", "" /* Client's WScale < 15 */\n .tstamp_ok = tstamp_ok"", '\n .rcv_tsval = tsval', '\n .rcv_tsecr = tsecr', "" /* Server's Initial TSval */\n .usec_ts_ok = usec_ts_ok"", '\n .sack_ok = sack_ok', '\n .ecn_ok = ecn_ok', '\n }\n\n skc = bpf_skc_lookup_tcp(...);\n sk = (struct sock *)bpf_skc_to_tcp_sock(skc);\n bpf_sk_assign_tcp_reqsk(skb', ' sk', ' attrs', ' sizeof(attrs));\n bpf_sk_release(skc);\n\nbpf_sk_assign_tcp_reqsk() takes skb', ' a listener sk', ' and struct\nbpf_tcp_req_attrs and allocates reqsk and configures it. Then', '\nbpf_sk_assign_tcp_reqsk() links reqsk with skb and the listener.\n\nThe notable thing here is that we do not hold refcnt for both reqsk\nand listener. To differentiate that', ' we mark reqsk->syncookie', ' which\nis only used in TX for now. So', ' if reqsk->syncookie is 1 in RX', ' it\nmeans that the reqsk is allocated by kfunc.\n\nWhen skb is freed', ' sock_pfree() checks if reqsk->syncookie is 1', '\nand in that case', ' we set NULL to reqsk->rsk_listener before calling\nreqsk_free() as reqsk does not hold a refcnt of the listener.\n\nWhen the TCP stack looks up a socket from the skb', ' we steal the\nlistener from the reqsk in skb_steal_sock() and create a full sk\nin cookie_v[46]_check().\n\nThe refcnt of reqsk will finally be set to 1 in tcp_get_cookie_sock()\nafter creating a full sk.\n\nNote that we can extend struct bpf_tcp_req_attrs in the future when\nwe add a new attribute that is determined in 3WHS.\n\nSigned-off-by: Kuniyuki Iwashima \nLink: https://lore.kernel.org/r/20240115205514.68364-6-kuniyu@amazon.com\nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Alexei Starovoitov \n', '']",Add a kfunc for arbitrary SYN Cookie support at TC hook in BPF.,"SYN Cookie, TC hook, kfunc",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['tc/netfilter like programs'] +695751e31a63efd2bbe6779873adf1e4deb00cd5,695751e31a63efd2bbe6779873adf1e4deb00cd5,Kuniyuki Iwashima,kuniyu@amazon.com,1705352112,Alexei Starovoitov,ast@kernel.org,1706049624,41904868bb6f47e98aa75ab19e148d03c52514a2,8b5ac68fb5ee416537c1214cbacf0ddc4293cce9,"bpf: tcp: Handle BPF SYN Cookie in cookie_v[46]_check(). + +We will support arbitrary SYN Cookie with BPF in the following +patch. + +If BPF prog validates ACK and kfunc allocates a reqsk"," it will +be carried to cookie_[46]_check() as skb->sk. If skb->sk is not +NULL","[' we call cookie_bpf_check().\n\nThen', ' we clear skb->sk and skb->destructor', ' which are needed not\nto hold refcnt for reqsk and the listener. See the following patch\nfor details.\n\nAfter that', ' we finish initialisation for the remaining fields with\ncookie_tcp_reqsk_init().\n\nNote that the server side WScale is set only for non-BPF SYN Cookie.\n\nSigned-off-by: Kuniyuki Iwashima \nLink: https://lore.kernel.org/r/20240115205514.68364-5-kuniyu@amazon.com\nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Alexei Starovoitov \n', '']",Enhances TCP handling by managing BPF SYN Cookies in the cookie_v[46]_check functions.,"SYN Cookie,BPF,ACK",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8b5ac68fb5ee416537c1214cbacf0ddc4293cce9,8b5ac68fb5ee416537c1214cbacf0ddc4293cce9,Kuniyuki Iwashima,kuniyu@amazon.com,1705352111,Alexei Starovoitov,ast@kernel.org,1706049624,b34d2e597746829ffeb492a42a3532605e5ddb3c,95e752b5299fa8c90099f7bc2aa1ee3e2e2c95ab,"bpf: tcp: Handle BPF SYN Cookie in skb_steal_sock(). + +We will support arbitrary SYN Cookie with BPF. + +If BPF prog validates ACK and kfunc allocates a reqsk"," it will +be carried to TCP stack as skb->sk with req->syncookie 1. Also","['\nthe reqsk has its listener as req->rsk_listener with no refcnt\ntaken.\n\nWhen the TCP stack looks up a socket from the skb', ' we steal\ninet_reqsk(skb->sk)->rsk_listener in skb_steal_sock() so that\nthe skb will be processed in cookie_v[46]_check() with the\nlistener.\n\nNote that we do not clear skb->sk and skb->destructor so that we\ncan carry the reqsk to cookie_v[46]_check().\n\nSigned-off-by: Kuniyuki Iwashima \nLink: https://lore.kernel.org/r/20240115205514.68364-4-kuniyu@amazon.com\nSigned-off-by: Martin KaFai Lau \nSigned-off-by: Alexei Starovoitov \n', '']",Enhance BPF to handle arbitrary SYN cookies in TCP with skb_steal_sock().,"BPF,SYN Cookie,TCP",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', 'other']" +d177c1be06ce28aa8c8710ac55be1b5ad3f314c6,d177c1be06ce28aa8c8710ac55be1b5ad3f314c6,Artem Savkov,asavkov@redhat.com,1704877057,Alexei Starovoitov,ast@kernel.org,1706049623,ab822b88b22a6f8892eda0a9752092fedb63bf3a,f5f30386c78105cba520e443a6a9ee945ec1d066,"selftests/bpf: Fix potential premature unload in bpf_testmod + +It is possible for bpf_kfunc_call_test_release() to be called from +bpf_map_free_deferred() when bpf_testmod is already unloaded and +perf_test_stuct.cnt which it tries to decrease is no longer in memory. +This patch tries to fix the issue by waiting for all references to be +dropped in bpf_testmod_exit(). + +The issue can be triggered by running 'test_progs -t map_kptr' in 6.5"," +but is obscured in 6.6 by d119357d07435 (""rcu-tasks: Treat only +synchronous grace periods urgently""). + +Fixes: 65eb006d85a2 (""bpf: Move kernel test kfuncs to bpf_testmod"") +Signed-off-by: Artem Savkov +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Cc: Jiri Olsa +Link: https://lore.kernel.org/bpf/82f55c0e-0ec8-4fe1-8d8c-b1de07558ad9@linux.dev +Link: https://lore.kernel.org/bpf/20240110085737.8895-1-asavkov@redhat.com +Signed-off-by: Alexei Starovoitov +",[''],Fixes potential premature unloading issue in bpf_testmod during reference drop in selftests.,"premature unload,selftests,bpf_testmod",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f5f30386c78105cba520e443a6a9ee945ec1d066,f5f30386c78105cba520e443a6a9ee945ec1d066,Tiezhu Yang,yangtiezhu@loongson.cn,1705385960,Alexei Starovoitov,ast@kernel.org,1706049623,db009a8d2aabeac49a997c93f2743365558642c9,49c06547d5218b54fbcc6011864b8c8e3aa0b565,"bpftool: Silence build warning about calloc() + +There exists the following warning when building bpftool: + + CC prog.o +prog.c: In function ‘profile_open_perf_events’: +prog.c:2301:24: warning: ‘calloc’ sizes specified with ‘sizeof’ in the earlier argument and not in the later argument [-Wcalloc-transposed-args] + 2301 | sizeof(int)"," obj->rodata->num_cpu * obj->rodata->num_metric); + | ^~~ +prog.c:2301:24: note: earlier argument should specify number of elements","[' later size of each element\n\nTested with the latest upstream GCC which contains a new warning option\n-Wcalloc-transposed-args. The first argument to calloc is documented to\nbe number of elements in array', ' while the second argument is size of each\nelement', ' just switch the first and second arguments of calloc() to silence\nthe build warning', ' compile tested only.\n\nFixes: 47c09d6a9f67 (""bpftool: Introduce ""prog profile"" command"")\nSigned-off-by: Tiezhu Yang \nSigned-off-by: Daniel Borkmann \nReviewed-by: Quentin Monnet \nLink: https://lore.kernel.org/bpf/20240116061920.31172-1-yangtiezhu@loongson.cn\nSigned-off-by: Alexei Starovoitov \n', '']",Fix build warning in bpftool related to incorrect usage of calloc.,"bpftool, calloc, warning",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +49c06547d5218b54fbcc6011864b8c8e3aa0b565,49c06547d5218b54fbcc6011864b8c8e3aa0b565,Alexei Starovoitov,ast@kernel.org,1705096894,Alexei Starovoitov,ast@kernel.org,1706049623,16ac97b8b9e0c296cdffe5603c10c33cd7b52665,88031b929c01fe3686d34a848c413c2e51e6a7c8,"bpf: Minor improvements for bpf_cmp. + +Few minor improvements for bpf_cmp() macro: +. reduce number of args in __bpf_cmp() +. rename NOFLIP to UNLIKELY +. add a comment about 64-bit truncation in ""i"" constraint +. use ""ri"" constraint for sizeof(rhs) <= 4 +. improve error message for bpf_cmp_likely() + +Before: +progs/iters_task_vma.c:31:7: error: variable 'ret' is uninitialized when used here [-Werror","-Wuninitialized] + 31 | if (bpf_cmp_likely(seen","[' <==', "" 1000))\n | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n../bpf/bpf_experimental.h:325:3: note: expanded from macro 'bpf_cmp_likely'\n 325 | ret;\n | ^~~\nprogs/iters_task_vma.c:31:7: note: variable 'ret' is declared here\n../bpf/bpf_experimental.h:310:3: note: expanded from macro 'bpf_cmp_likely'\n 310 | bool ret;\n | ^\n\nAfter:\nprogs/iters_task_vma.c:31:7: error: invalid operand for instruction\n 31 | if (bpf_cmp_likely(seen"", ' <==', ' 1000))\n | ^\n../bpf/bpf_experimental.h:324:17: note: expanded from macro \'bpf_cmp_likely\'\n 324 | asm volatile(""r0 "" #OP "" invalid compare"");\n | ^\n:1:5: note: instantiated into assembly here\n 1 | r0 <== invalid compare\n | ^\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240112220134.71209-1-alexei.starovoitov@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Minor improvements made to bpf_cmp macro for better usage and error handling.,"bpf_cmp, macro, improvements",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +88031b929c01fe3686d34a848c413c2e51e6a7c8,88031b929c01fe3686d34a848c413c2e51e6a7c8,Yonghong Song,yonghong.song@linux.dev,1704950496,Alexei Starovoitov,ast@kernel.org,1706049623,01abae8ed27f9b646851e7b0662fa53ed401f2ac,6ae99ac8b7da30c9fdb15e380624dbc41f8200c8,"docs/bpf: Fix an incorrect statement in verifier.rst + +In verifier.rst"," I found an incorrect statement (maybe a typo) in section +'Liveness marks tracking'. Basically","[' the wrong register is attributed\nto have a read mark. This may confuse the user.\n\nSigned-off-by: Yonghong Song \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240111052136.3440417-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes an incorrect statement in the BPF verifier documentation under 'Liveness marks tracking' section.,verifier fix documentation,It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6ae99ac8b7da30c9fdb15e380624dbc41f8200c8,6ae99ac8b7da30c9fdb15e380624dbc41f8200c8,Yonghong Song,yonghong.song@linux.dev,1704863635,Alexei Starovoitov,ast@kernel.org,1706049623,f5c6c46df17c2350447ed9c8bad37bc2a4aeee47,9a4c57f52b5e0de3a6b1f40c5b656730ce33ee01,"selftests/bpf: Add a selftest with not-8-byte aligned BPF_ST + +Add a selftest with a 4 bytes BPF_ST of 0 where the store is not +8-byte aligned. The goal is to ensure that STACK_ZERO is properly +marked in stack slots and the STACK_ZERO value can propagate +properly during the load. + +Acked-by: Andrii Nakryiko +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20240110051355.2737232-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,Add a selftest to ensure proper STACK_ZERO propagation with non-8-byte aligned BPF_ST operations.,"selftest, BPF_ST, STACK_ZERO",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9a4c57f52b5e0de3a6b1f40c5b656730ce33ee01,9a4c57f52b5e0de3a6b1f40c5b656730ce33ee01,Yonghong Song,yonghong.song@linux.dev,1704863628,Alexei Starovoitov,ast@kernel.org,1706049623,8932505083b07bde8123fea88f57aad54ef120a7,3893f0b6a0698aeeb3d27cb22baef7c4ca1a07f1,"bpf: Track aligned st store as imprecise spilled registers + +With patch set [1]"," precision backtracing supports register spill/fill +to/from the stack. The patch [2] allows initial imprecise register spill +with content 0. This is a common case for cpuv3 and lower for +initializing the stack variables with pattern + r1 = 0 + *(u64 *)(r10 - 8) = r1 +and the [2] has demonstrated good verification improvement. + +For cpuv4","[' the initialization could be\n *(u64 *)(r10 - 8) = 0\nThe current verifier marks the r10-8 contents with STACK_ZERO.\nSimilar to [2]', ' let us permit the above insn to behave like\nimprecise register spill which can reduce number of verified states.\nThe change is in function check_stack_write_fixed_off().\n\nBefore this patch', ' spilled zero will be marked as STACK_ZERO\nwhich can provide precise values. In check_stack_write_var_off()', ""\nSTACK_ZERO will be maintained if writing a const zero\nso later it can provide precise values if needed.\n\nThe above handling of '*(u64 *)(r10 - 8) = 0' as a spill\nwill have issues in check_stack_write_var_off() as the spill\nwill be converted to STACK_MISC and the precise value 0\nis lost. To fix this issue"", ' if the spill slots with const\nzero and the BPF_ST write also with const zero', ' the spill slots\nare preserved', ' which can later provide precise values\nif needed. Without the change in check_stack_write_var_off()', ""\nthe test_verifier subtest 'BPF_ST_MEM stack imm zero"", "" variable offset'\nwill fail.\n\nI checked cpuv3 and cpuv4 with and without this patch with veristat.\nThere is no state change for cpuv3 since '*(u64 *)(r10 - 8) = 0'\nis only generated with cpuv4.\n\nFor cpuv4:\n$ ../veristat -C old.cpuv4.csv new.cpuv4.csv -e file"", 'prog', 'insns', ""states -f 'insns_diff!=0'\nFile Program Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n------------------------------------------ ------------------- --------- --------- --------------- ---------- ---------- -------------\nlocal_storage_bench.bpf.linked3.o get_local 228 168 -60 (-26.32%) 17 14 -3 (-17.65%)\npyperf600_bpf_loop.bpf.linked3.o on_event 6066 4889 -1177 (-19.40%) 403 321 -82 (-20.35%)\ntest_cls_redirect.bpf.linked3.o cls_redirect 35483 35387 -96 (-0.27%) 2179 2177 -2 (-0.09%)\ntest_l4lb_noinline.bpf.linked3.o balancer_ingress 4494 4522 +28 (+0.62%) 217 219 +2 (+0.92%)\ntest_l4lb_noinline_dynptr.bpf.linked3.o balancer_ingress 1432 1455 +23 (+1.61%) 92 94 +2 (+2.17%)\ntest_xdp_noinline.bpf.linked3.o balancer_ingress_v6 3462 3458 -4 (-0.12%) 216 216 +0 (+0.00%)\nverifier_iterating_callbacks.bpf.linked3.o widening 52 41 -11 (-21.15%) 4 3 -1 (-25.00%)\nxdp_synproxy_kern.bpf.linked3.o syncookie_tc 12412 11719 -693 (-5.58%) 345 330 -15 (-4.35%)\nxdp_synproxy_kern.bpf.linked3.o syncookie_xdp 12478 11794 -684 (-5.48%) 346 331 -15 (-4.34%)\n\ntest_l4lb_noinline and test_l4lb_noinline_dynptr has minor regression"", ' but\npyperf600_bpf_loop and local_storage_bench gets pretty good improvement.\n\n [1] https://lore.kernel.org/all/20231205184248.1502704-1-andrii@kernel.org/\n [2] https://lore.kernel.org/all/20231205184248.1502704-9-andrii@kernel.org/\n\nCc: Kuniyuki Iwashima \nCc: Martin KaFai Lau \nSigned-off-by: Yonghong Song \nTested-by: Kuniyuki Iwashima \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240110051348.2737007-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",The commit improves precision of register spill/fill verification for aligned store in eBPF programs.,"aligned store, register spill, precision",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3893f0b6a0698aeeb3d27cb22baef7c4ca1a07f1,3893f0b6a0698aeeb3d27cb22baef7c4ca1a07f1,Maxim Mikityanskiy,maxim@isovalent.com,1704747123,Alexei Starovoitov,ast@kernel.org,1706049623,f74b1463fa15dbfdbf1bd765f939b9906631b2f2,8ecfc371d829bfed75e0ef2cab45b2290b982f64,"selftests/bpf: Test assigning ID to scalars on spill + +The previous commit implemented assigning IDs to registers holding +scalars before spill. Add the test cases to check the new functionality. + +Signed-off-by: Maxim Mikityanskiy +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-10-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov +",,The commit adds test cases for assigning IDs to scalar registers before spill in selftests.,"test cases, scalars, spill",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8ecfc371d829bfed75e0ef2cab45b2290b982f64,8ecfc371d829bfed75e0ef2cab45b2290b982f64,Maxim Mikityanskiy,maxim@isovalent.com,1704747122,Alexei Starovoitov,ast@kernel.org,1706049623,5d245cf62f2a544b828f743091ca1fbcde6ee8b6,87e51ac6cb19c5d33d70d4cae9e26d2a3a5fcba0,"bpf: Assign ID to scalars on spill + +Currently", when a scalar bounded register is spilled to the stack,"[' its\nID is preserved', ' but only if was already assigned', ' i.e. if this register\nwas MOVed before.\n\nAssign an ID on spill if none is set', ' so that equal scalars could be\ntracked if a register is spilled to the stack and filled into another\nregister.\n\nOne test is adjusted to reflect the change in register IDs.\n\nSigned-off-by: Maxim Mikityanskiy \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240108205209.838365-9-maxtram95@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Assign unique IDs to scalars when they are spilled to the stack in the BPF verifier.,"scalars, IDs, spill",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +87e51ac6cb19c5d33d70d4cae9e26d2a3a5fcba0,87e51ac6cb19c5d33d70d4cae9e26d2a3a5fcba0,Maxim Mikityanskiy,maxim@isovalent.com,1704747121,Alexei Starovoitov,ast@kernel.org,1706049623,2d101b89155501e3ece3705a989a57ad327b44ff,8e0e074aafb8fec227363ed905ddd2ac7e4575e4,"bpf: Add the get_reg_width function + +Put calculation of the register value width into a dedicated function. +This function will also be used in a following commit. + +Signed-off-by: Maxim Mikityanskiy +Link: https://lore.kernel.org/r/20240108205209.838365-8-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov +",,Introduces a dedicated function to calculate register value width in eBPF.,"register,function,get_reg_width",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8e0e074aafb8fec227363ed905ddd2ac7e4575e4,8e0e074aafb8fec227363ed905ddd2ac7e4575e4,Maxim Mikityanskiy,maxim@isovalent.com,1704747120,Alexei Starovoitov,ast@kernel.org,1706049622,a8a939758f2ad18de7b344d1980e87ab0cd2c322,b827eee4c4d83ad92094b38d49cfec6844fb5863,"bpf: Add the assign_scalar_id_before_mov function + +Extract the common code that generates a register ID for src_reg before +MOV if needed into a new function. This function will also be used in +a following commit. + +Signed-off-by: Maxim Mikityanskiy +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-7-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov +",,Extracts common code for generating register ID into a new function for reuse before MOV operations.,"register, function, MOV",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b827eee4c4d83ad92094b38d49cfec6844fb5863,b827eee4c4d83ad92094b38d49cfec6844fb5863,Maxim Mikityanskiy,maxim@isovalent.com,1704747119,Alexei Starovoitov,ast@kernel.org,1706049622,10886b0e37fadc9d6c9abacb4b96b8fd42b5cd90,32f55dd4add4df1a5bc8febc1fafd3086290dbf6,"selftests/bpf: Add a test case for 32-bit spill tracking + +When a range check is performed on a register that was 32-bit spilled to +the stack", the IDs of the two instances of the register are the same,"[' so\nthe range should also be the same.\n\nSigned-off-by: Maxim Mikityanskiy \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240108205209.838365-6-maxtram95@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Added a selftest for verifying 32-bit spill tracking in BPF programs.,"selftests,32-bit,spill",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +32f55dd4add4df1a5bc8febc1fafd3086290dbf6,32f55dd4add4df1a5bc8febc1fafd3086290dbf6,Maxim Mikityanskiy,maxim@isovalent.com,1704747118,Alexei Starovoitov,ast@kernel.org,1706049622,fe863af03a5060bd15176ee4d484dba73e6c8919,c035b3e555b5642f786fb2d089a6ddf7b00eb374,"bpf: Make bpf_for_each_spilled_reg consider narrow spills + +Adjust the check in bpf_get_spilled_reg to take into account spilled +registers narrower than 64 bits. That allows find_equal_scalars to +properly adjust the range of all spilled registers that have the same +ID. Before this change"," it was possible for a register and a spilled +register to have the same IDs but different ranges if the spill was +narrower than 64 bits and a range check was performed on the register. + +Signed-off-by: Maxim Mikityanskiy +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-5-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],The commit adjusts the bpf_get_spilled_reg function to handle narrower spills under 64 bits properly.,"bpf,narrower spills,registers",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c035b3e555b5642f786fb2d089a6ddf7b00eb374,c035b3e555b5642f786fb2d089a6ddf7b00eb374,Eduard Zingerman,eddyz87@gmail.com,1704747117,Alexei Starovoitov,ast@kernel.org,1706049622,568c8bfd477b4610624c43ebcd1dd0137ea95ca8,d5b892fd607abec2a1e49b6a2afc278c329a0ee2,"selftests/bpf: check if imprecise stack spills confuse infinite loop detection + +Verify that infinite loop detection logic separates states with +identical register states but different imprecise scalars spilled to +stack. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-4-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov +",,The commit adds a selftest to verify eBPF's infinite loop detection when dealing with imprecise stack spills.,"selftests, detection, stack spills",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d5b892fd607abec2a1e49b6a2afc278c329a0ee2,d5b892fd607abec2a1e49b6a2afc278c329a0ee2,Eduard Zingerman,eddyz87@gmail.com,1704747116,Alexei Starovoitov,ast@kernel.org,1706049622,50975743c8d1ad2caf70a4487f7f37f276dd71e8,242d18514149d86b431b6f5db5a33579ea79ebad,"bpf: make infinite loop detection in is_state_visited() exact + +Current infinite loops detection mechanism is speculative: +- first"," states_maybe_looping() check is done which simply does memcmp + for R1-R10 in current frame; +- second","[' states_equal(...', ' exact=false) is called. With exact=false\n states_equal() would compare scalars for equality only if in old\n state scalar has precision mark.\n\nSuch logic might be problematic if compiler makes some unlucky stack\nspill/fill decisions. An artificial example of a false positive looks\nas follows:\n\n r0 = ... unknown scalar ...\n r0 &= 0xff;\n *(u64 *)(r10 - 8) = r0;\n r0 = 0;\n loop:\n r0 = *(u64 *)(r10 - 8);\n if r0 > 10 goto exit_;\n r0 += 1;\n *(u64 *)(r10 - 8) = r0;\n r0 = 0;\n goto loop;\n\nThis commit updates call to states_equal to use exact=true', ' forcing\nall scalar comparisons to be exact.\n\nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240108205209.838365-3-maxtram95@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit improves the detection of infinite loops in is_state_visited() within the bpf verification process.,"infinite loops,detection,verification",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +242d18514149d86b431b6f5db5a33579ea79ebad,242d18514149d86b431b6f5db5a33579ea79ebad,Maxim Mikityanskiy,maxim@isovalent.com,1704747115,Alexei Starovoitov,ast@kernel.org,1706049622,f672979d6f27e721f583bcf165f14dbc70512249,f067074bafd5060428211ee7bb8a3f86ff6bc58d,"selftests/bpf: Fix the u64_offset_to_skb_data test + +The u64_offset_to_skb_data test is supposed to make a 64-bit fill"," but +instead makes a 16-bit one. Fix the test according to its intention and +update the comments accordingly (umax is no longer 0xffff). The 16-bit +fill is covered by u16_offset_to_skb_data. + +Signed-off-by: Maxim Mikityanskiy +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240108205209.838365-2-maxtram95@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Fix the u64_offset_to_skb_data test to properly perform 64-bit fill and update comments.,"fix,test,64-bit",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f067074bafd5060428211ee7bb8a3f86ff6bc58d,f067074bafd5060428211ee7bb8a3f86ff6bc58d,Nathan Chancellor,nathan@kernel.org,1705004208,Alexei Starovoitov,ast@kernel.org,1706049622,a96fdd2853f261cfeee38c8df26e64bb6f09c40e,56d3e44af80c6b4c7cb89a73061ee35d4a7aee18,"selftests/bpf: Update LLVM Phabricator links + +reviews.llvm.org was LLVM's Phabricator instances for code review. It +has been abandoned in favor of GitHub pull requests. While the majority +of links in the kernel sources still work because of the work Fangrui +has done turning the dynamic Phabricator instance into a static archive"," +there are some issues with that work","[' so preemptively convert all the\nlinks in the kernel sources to point to the commit on GitHub.\n\nMost of the commits have the corresponding differential review link in\nthe commit message itself so there should not be any loss of fidelity in\nthe relevant information.\n\nAdditionally', ' fix a typo in the xdpwall.c print (""LLMV"" -> ""LLVM"") while\nin the area.\n\nLink: https://discourse.llvm.org/t/update-on-github-pull-requests/71540/172\nAcked-by: Yonghong Song \nSigned-off-by: Nathan Chancellor \nLink: https://lore.kernel.org/r/20240111-bpf-update-llvm-phabricator-links-v2-1-9a7ae976bd64@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Update LLVM Phabricator links in selftests to use new GitHub pull request locations.,"LLVM,Phabricator,GitHub",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +56d3e44af80c6b4c7cb89a73061ee35d4a7aee18,56d3e44af80c6b4c7cb89a73061ee35d4a7aee18,Andrii Nakryiko,andrii@kernel.org,1704842258,Alexei Starovoitov,ast@kernel.org,1706049622,fce1436714441a69d07d5e22171399b916e5a984,81777efbf59305fa145bede97dd4abdc35540578,"selftests/bpf: detect testing prog flags support + +Various tests specify extra testing prog_flags when loading BPF +programs", like BPF_F_TEST_RND_HI32,"[' and more recently also\nBPF_F_TEST_REG_INVARIANTS. While BPF_F_TEST_RND_HI32 is old enough to\nnot cause much problem on older kernels', ' BPF_F_TEST_REG_INVARIANTS is\nvery fresh and unconditionally specifying it causes selftests to fail on\neven slightly outdated kernels.\n\nThis breaks libbpf CI test against 4.9 and 5.15 kernels', ' it can break\nsome local development (done outside of VM)', ' etc.\n\nTo prevent this', ' and guard against similar problems in the future', ' do\nruntime detection of supported ""testing flags""', ' and only provide those\nthat host kernel recognizes.\n\nAcked-by: Song Liu \nAcked-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240109231738.575844-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enable selftests to detect support for testing prog_flags when loading BPF programs.,"selftests, prog_flags, BPF",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +15b8b0be985592fd19ee4e661d13d291877b09c7,15b8b0be985592fd19ee4e661d13d291877b09c7,Randy Dunlap,rdunlap@infradead.org,1704524145,Alexei Starovoitov,ast@kernel.org,1706049622,51b2adbba6d5c5104a7814083ee0cd2ac18f44e3,522bb2c1f82b12eb7befaae815d1d959b8e6bba2,"net: filter: fix spelling mistakes + +Fix spelling errors as reported by codespell. + +Signed-off-by: Randy Dunlap +Cc: Alexei Starovoitov +Cc: Daniel Borkmann +Cc: Andrii Nakryiko +Cc: bpf@vger.kernel.org +Cc: ""David S. Miller"" +Cc: Eric Dumazet +Cc: Jakub Kicinski +Cc: Paolo Abeni +Reviewed-by: Simon Horman +Link: https://lore.kernel.org/r/20240106065545.16855-1-rdunlap@infradead.org +Signed-off-by: Alexei Starovoitov +",,This commit fixes spelling mistakes in the net filter code.,"spelling, mistakes, codespell",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","[""It's not related to any of the above.""]" +522bb2c1f82b12eb7befaae815d1d959b8e6bba2,522bb2c1f82b12eb7befaae815d1d959b8e6bba2,Andrii Nakryiko,andrii@kernel.org,1704413345,Alexei Starovoitov,ast@kernel.org,1706049621,7ff504f352fe6f75aa63f2c612504b0ffbe22483,54c11ec4935a61af32bb03fc52e7172c97bd7203,"bpf: support multiple tags per argument + +Add ability to iterate multiple decl_tag types pointed to the same +function argument. Use this to support multiple __arg_xxx tags per +global subprog argument. + +We leave btf_find_decl_tag_value() intact"," but change its implementation +to use a new btf_find_next_decl_tag() which can be straightforwardly +used to find next BTF type ID of a matching btf_decl_tag type. +btf_prepare_func_args() is switched from btf_find_decl_tag_value() to +btf_find_next_decl_tag() to gain multiple tags per argument support. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240105000909.2818934-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],This commit adds support for multiple declaration tags per function argument in eBPF.,"multiple tags, function argument, btf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +54c11ec4935a61af32bb03fc52e7172c97bd7203,54c11ec4935a61af32bb03fc52e7172c97bd7203,Andrii Nakryiko,andrii@kernel.org,1704413344,Alexei Starovoitov,ast@kernel.org,1706049621,655a4689d743a3b584a9247ffcaf64415efa2ed4,18810ad3929ff6b5d8e67e3adc40d690bd780fd6,"bpf: prepare btf_prepare_func_args() for multiple tags per argument + +Add btf_arg_tag flags enum to be able to record multiple tags per +argument. Also streamline pointer argument processing some more. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240105000909.2818934-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Enhances btf_prepare_func_args to support multiple tags per argument and improves pointer argument processing.,"multiple tags, argument, btf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +18810ad3929ff6b5d8e67e3adc40d690bd780fd6,18810ad3929ff6b5d8e67e3adc40d690bd780fd6,Andrii Nakryiko,andrii@kernel.org,1704413343,Alexei Starovoitov,ast@kernel.org,1706049621,d40ce39247e62ac7f5a412cc1d90bd44c4983981,e31f98c1af810a13395ee9ab57402d82272445af,"bpf: make sure scalar args don't accept __arg_nonnull tag + +Move scalar arg processing in btf_prepare_func_args() after all pointer +arg processing is done. This makes it easier to do validation. One +example of unintended behavior right now is ability to specify +__arg_nonnull for integer/enum arguments. This patch fixes this. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240105000909.2818934-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Fixes scalar argument processing in btf_prepare_func_args to prevent __arg_nonnull for non-pointer args.,"scalar,args,validation",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e31f98c1af810a13395ee9ab57402d82272445af,e31f98c1af810a13395ee9ab57402d82272445af,Andrii Nakryiko,andrii@kernel.org,1704413342,Alexei Starovoitov,ast@kernel.org,1706049621,ad3d1f489a9369c14d6c9a1c8f2045ea7ffc35b6,55c14321dbf06c9e32050e99b2555c2f8f6429da,"selftests/bpf: fix test_loader check message + +Seeing: + + process_subtest:PASS:Can't alloc specs array 0 nsec + +... in verbose successful test log is very confusing. Use smaller +identifier-like test tag to denote that we are asserting specs array +allocation success. + +Now it's much less distracting: + + process_subtest:PASS:specs_alloc 0 nsec + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20240105000909.2818934-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,This commit clarifies the test message in selftests for BPF regarding specs array allocation checks.,"selftests,BPF,message",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +55c14321dbf06c9e32050e99b2555c2f8f6429da,55c14321dbf06c9e32050e99b2555c2f8f6429da,Alexei Starovoitov,ast@kernel.org,1705026185,Alexei Starovoitov,ast@kernel.org,1706049621,5bcce9245203d486367b3b41f121cb9ee14b8ab7,2121c43f88f593eea51d483bedd638cb0623c7e2 17bda53e43bc41d881ca6a02b3c6f5376c55b3d3,"Merge branch 'bpf-inline-bpf_kptr_xchg' + +Hou Tao says: + +==================== +The motivation of inlining bpf_kptr_xchg() comes from the performance +profiling of bpf memory allocator benchmark [1]. The benchmark uses +bpf_kptr_xchg() to stash the allocated objects and to pop the stashed +objects for free. After inling bpf_kptr_xchg()"," the performance for +object free on 8-CPUs VM increases about 2%~10%. However the performance +gain comes with costs: both the kasan and kcsan checks on the pointer +will be unavailable. Initially the inline is implemented in do_jit() for +x86-64 directly","[' but I think it will more portable to implement the\ninline in verifier.\n\nPatch #1 supports inlining bpf_kptr_xchg() helper and enables it on\nx86-4. Patch #2 factors out a helper for newly-added test in patch #3.\nPatch #3 tests whether the inlining of bpf_kptr_xchg() is expected.\nPlease see individual patches for more details. And comments are always\nwelcome.\n\nChange Log:\nv3:\n * rebased on bpf-next tree\n * patch 1 & 2: Add Rvb-by and Ack-by tags from Eduard\n * patch 3: use inline assembly and naked function instead of c code\n (suggested by Eduard)\n\nv2: https://lore.kernel.org/bpf/20231223104042.1432300-1-houtao@huaweicloud.com/\n * rebased on bpf-next tree\n * drop patch #1 in v1 due to discussion in [2]\n * patch #1: add the motivation in the commit message', ' merge patch #1\n and #3 into the new patch in v2. (Daniel)\n * patch #2/#3: newly-added patch to test the inlining of\n bpf_kptr_xchg() (Eduard)\n\nv1: https://lore.kernel.org/bpf/95b8c2cd-44d5-5fe1-60b5-7e8218779566@huaweicloud.com/\n\n[1]: https://lore.kernel.org/bpf/20231221141501.3588586-1-houtao@huaweicloud.com/\n[2]: https://lore.kernel.org/bpf/fd94efb9-4a56-c982-dc2e-c66be5202cb7@huaweicloud.com/\n====================\n\nLink: https://lore.kernel.org/r/20240105104819.3916743-1-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit merges changes for inlining bpf_kptr_xchg to improve memory allocator benchmark performance.,"bpf_kptr_xchg, inlining, performance",It's a performance optimization.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +17bda53e43bc41d881ca6a02b3c6f5376c55b3d3,17bda53e43bc41d881ca6a02b3c6f5376c55b3d3,Hou Tao,houtao1@huawei.com,1704451699,Alexei Starovoitov,ast@kernel.org,1706049621,5bcce9245203d486367b3b41f121cb9ee14b8ab7,b4b7a4099b8ccea224577003fcf9d321bf0817b7,"selftests/bpf: Test the inlining of bpf_kptr_xchg() + +The test uses bpf_prog_get_info_by_fd() to obtain the xlated +instructions of the program first. Since these instructions have +already been rewritten by the verifier"," the tests then checks whether +the rewritten instructions are as expected. And to ensure LLVM generates +code exactly as expected","[' use inline assembly and a naked function.\n\nSuggested-by: Eduard Zingerman \nSigned-off-by: Hou Tao \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240105104819.3916743-4-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftests to verify the inlining of bpf_kptr_xchg through bpf_prog_get_info_by_fd().,"selftests,inlining,bpf_kptr_xchg",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b4b7a4099b8ccea224577003fcf9d321bf0817b7,b4b7a4099b8ccea224577003fcf9d321bf0817b7,Hou Tao,houtao1@huawei.com,1704451698,Alexei Starovoitov,ast@kernel.org,1706049621,e7b5deffde0f7169e3545f4c0809c7fdc9946b67,7c05e7f3e74e7e550534d524e04d7e6f78d6fa24,"selftests/bpf: Factor out get_xlated_program() helper + +Both test_verifier and test_progs use get_xlated_program()"," so moving +the helper into testing_helpers.h to reuse it. + +Acked-by: Eduard Zingerman +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20240105104819.3916743-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Refactor by moving get_xlated_program() helper into testing_helpers.h for reuse in selftests/bpf.,"refactor,reuse,tests",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7c05e7f3e74e7e550534d524e04d7e6f78d6fa24,7c05e7f3e74e7e550534d524e04d7e6f78d6fa24,Hou Tao,houtao1@huawei.com,1704451697,Alexei Starovoitov,ast@kernel.org,1706049621,83d12bcddc908580f8bc73f5572ddeda96561665,2121c43f88f593eea51d483bedd638cb0623c7e2,"bpf: Support inlining bpf_kptr_xchg() helper + +The motivation of inlining bpf_kptr_xchg() comes from the performance +profiling of bpf memory allocator benchmark. The benchmark uses +bpf_kptr_xchg() to stash the allocated objects and to pop the stashed +objects for free. After inling bpf_kptr_xchg()"," the performance for +object free on 8-CPUs VM increases about 2%~10%. The inline also has +downside: both the kasan and kcsan checks on the pointer will be +unavailable. + +bpf_kptr_xchg() can be inlined by converting the calling of +bpf_kptr_xchg() into an atomic_xchg() instruction. But the conversion +depends on two conditions: +1) JIT backend supports atomic_xchg() on pointer-sized word +2) For the specific arch","[' the implementation of xchg is the same as\n atomic_xchg() on pointer-sized words.\n\nIt seems most 64-bit JIT backends satisfies these two conditions. But\nas a precaution', ' defining a weak function bpf_jit_supports_ptr_xchg()\nto state whether such conversion is safe and only supporting inline for\n64-bit host.\n\nFor x86-64', ' it supports BPF_XCHG atomic operation and both xchg() and\natomic_xchg() use arch_xchg() to implement the exchange', ' so enabling the\ninline of bpf_kptr_xchg() on x86-64 first.\n\nReviewed-by: Eduard Zingerman \nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20240105104819.3916743-2-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit improves performance by inlining the bpf_kptr_xchg() helper function for better efficiency in memory allocation benchmarks.,"bpf_kptr_xchg, inlining, performance",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['other'] +1732ebc4a26181c8f116c7639db99754b313edc8,1732ebc4a26181c8f116c7639db99754b313edc8,Pu Lehui,pulehui@huawei.com,1705977127,Daniel Borkmann,daniel@iogearbox.net,1706048498,61926561755d53e7889e47ebc4f92cf341898c04,1347775dea7f62798b4d5ef60771cdd7cfff25d8,riscv," bpf: Fix unpredictable kernel crash about RV64 struct_ops + +We encountered a kernel crash triggered by the bpf_tcp_ca testcase as +show below: + +Unable to handle kernel paging request at virtual address ff60000088554500 +Oops [#1] +... +CPU: 3 PID: 458 Comm: test_progs Tainted: G OE 6.8.0-rc1-kselftest_plain #1 +Hardware name: riscv-virtio","['qemu (DT)\nepc : 0xff60000088554500\n ra : tcp_ack+0x288/0x1232\nepc : ff60000088554500 ra : ffffffff80cc7166 sp : ff2000000117ba50\n gp : ffffffff82587b60 tp : ff60000087be0040 t0 : ff60000088554500\n t1 : ffffffff801ed24e t2 : 0000000000000000 s0 : ff2000000117bbc0\n s1 : 0000000000000500 a0 : ff20000000691000 a1 : 0000000000000018\n a2 : 0000000000000001 a3 : ff60000087be03a0 a4 : 0000000000000000\n a5 : 0000000000000000 a6 : 0000000000000021 a7 : ffffffff8263f880\n s2 : 000000004ac3c13b s3 : 000000004ac3c13a s4 : 0000000000008200\n s5 : 0000000000000001 s6 : 0000000000000104 s7 : ff2000000117bb00\n s8 : ff600000885544c0 s9 : 0000000000000000 s10: ff60000086ff0b80\n s11: 000055557983a9c0 t3 : 0000000000000000 t4 : 000000000000ffc4\n t5 : ffffffff8154f170 t6 : 0000000000000030\nstatus: 0000000200000120 badaddr: ff60000088554500 cause: 000000000000000c\nCode: c796 67d7 0000 0000 0052 0002 c13b 4ac3 0000 0000 (0001) 0000\n---[ end trace 0000000000000000 ]---\n\nThe reason is that commit 2cd3e3772e41 (""x86/cfi', 'bpf: Fix bpf_struct_ops\nCFI"") changes the func_addr of arch_prepare_bpf_trampoline in struct_ops\nfrom NULL to non-NULL', ' while we use func_addr on RV64 to differentiate\nbetween struct_ops and regular trampoline. When the struct_ops testcase\nis triggered', ' it emits wrong prologue and epilogue', ' and lead to\nunpredictable issues. After commit 2cd3e3772e41', ' we can use\nBPF_TRAMP_F_INDIRECT to distinguish them as it always be set in\nstruct_ops.\n\nFixes: 2cd3e3772e41 (""x86/cfi', 'bpf: Fix bpf_struct_ops CFI"")\nSigned-off-by: Pu Lehui \nSigned-off-by: Daniel Borkmann \nTested-by: Björn Töpel \nAcked-by: Björn Töpel \nLink: https://lore.kernel.org/bpf/20240123023207.1917284-1-pulehui@huaweicloud.com\n', '']",Fixes a kernel crash related to struct_ops in RISC-V when running bpf_tcp_ca test cases.,"kernel crash, struct_ops, RISC-V",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +999eea92e8d7a1ffa83f7dc89c83d8ed1e746fa9,999eea92e8d7a1ffa83f7dc89c83d8ed1e746fa9,Thomas Richter,tmricht@linux.ibm.com,1704703209,Namhyung Kim,namhyung@kernel.org,1705954099,16c33ebb7331f2fe72888775ff2ea9eba48307f5,6613476e225e090cc9aad49be7fa504e290dd33d,"perf test: raise limit to 20 percent for perf_stat_--bpf-counters_test + +This test case often fails on s390 (about 2 out of 10) because the +10% percent limit on the difference between --bpf-counters event counting +and s390 hardware counting is more than 10% in all failure cases. +Raise the limit to 20% on s390 and the test case succeeds. + +Signed-off-by: Thomas Richter +Acked-by: Namhyung Kim +Cc: gor@linux.ibm.com +Cc: hca@linux.ibm.com +Cc: sumanthk@linux.ibm.com +Cc: svens@linux.ibm.com +Link: https://lore.kernel.org/r/20240108084009.3959211-1-tmricht@linux.ibm.com +Signed-off-by: Namhyung Kim +",,Raise the limit for perf_stat bpf-counters test from 10% to 20% to reduce failures on s390 architecture.,"perf,test,s390",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9d64bf433c53cab2f48a3fff7a1f2a696bc5229a,9d64bf433c53cab2f48a3fff7a1f2a696bc5229a,Linus Torvalds,torvalds@linux-foundation.org,1705703123,Linus Torvalds,torvalds@linux-foundation.org,1705703123,0535254c177c27ec34adbc153d494cea9a9625a0,57f22c8dab6b266ae36b89b073a4a33dea71e762 d988c9f511af71a3445b6a4f3a2c67208ff8e480,"Merge tag 'perf-tools-for-v6.8-1-2024-01-09' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools + +Pull perf tools updates from Arnaldo Carvalho de Melo: + ""Add Namhyung Kim as tools/perf/ co-maintainer"," we're taking turns + processing patches","[' switching roles from perf-tools to perf-tools-next\n at each Linux release.\n\n Data profiling:\n\n - Associate samples that identify loads and stores with data\n structures. This uses events available on Intel', "" AMD and others and\n DWARF info:\n\n # To get memory access samples in kernel for 1 second (on Intel)\n $ perf mem record -a -K --ldlat=4 -- sleep 1\n\n # Similar for the AMD (but it requires 6.3+ kernel for BPF filters)\n $ perf mem record -a --filter 'mem_op == load || mem_op == store"", "" ip > 0x8000000000000000' -- sleep 1\n\n Then"", ' amongst several modes of post processing', ' one can do things like:\n\n $ perf report -s type', ""typeoff --hierarchy --group --stdio\n ...\n #\n # Samples: 10K of events 'cpu/mem-loads"", 'ldlat=4/P', ' cpu/mem-stores/P', "" dummy:u'\n # Event count (approx.): 602758064\n #\n # Overhead Data Type / Data Type Offset\n # ........................... ............................\n #\n 26.09% 3.28% 0.00% long unsigned int\n 26.09% 3.28% 0.00% long unsigned int +0 (no field)\n 18.48% 0.73% 0.00% struct page\n 10.83% 0.02% 0.00% struct page +8 (lru.next)\n 3.90% 0.28% 0.00% struct page +0 (flags)\n 3.45% 0.06% 0.00% struct page +24 (mapping)\n 0.25% 0.28% 0.00% struct page +48 (_mapcount.counter)\n 0.02% 0.06% 0.00% struct page +32 (index)\n 0.02% 0.00% 0.00% struct page +52 (_refcount.counter)\n 0.02% 0.01% 0.00% struct page +56 (memcg_data)\n 0.00% 0.01% 0.00% struct page +16 (lru.prev)\n 15.37% 17.54% 0.00% (stack operation)\n 15.37% 17.54% 0.00% (stack operation) +0 (no field)\n 11.71% 50.27% 0.00% (unknown)\n 11.71% 50.27% 0.00% (unknown) +0 (no field)\n\n $ perf annotate --data-type\n ...\n Annotate type: 'struct cfs_rq' in [kernel.kallsyms] (13 samples):\n ============================================================================\n samples offset size field\n 13 0 640 struct cfs_rq {\n 2 0 16 struct load_weight load {\n 2 0 8 unsigned long weight;\n 0 8 4 u32 inv_weight;\n };\n 0 16 8 unsigned long runnable_weight;\n 0 24 4 unsigned int nr_running;\n 1 28 4 unsigned int h_nr_running;\n ...\n\n $ perf annotate --data-type=page --group\n Annotate type: 'struct page' in [kernel.kallsyms] (480 samples):\n event[0] = cpu/mem-loads"", 'ldlat=4/P\n event[1] = cpu/mem-stores/P\n event[2] = dummy:u\n ===================================================================================\n samples offset size field\n 447 33 0 0 64 struct page {\n 108 8 0 0 8\t long unsigned int flags;\n 319 13 0 8 40\t union {\n 319 13 0 8 40 struct {\n 236 2 0 8 16 union {\n 236 2 0 8 16 struct list_head lru {\n 236 1 0 8 8 struct list_head* next;\n 0 1 0 16 8 struct list_head* prev;\n };\n 236 2 0 8 16 struct {\n 236 1 0 8 8 void* __filler;\n 0 1 0 16 4 unsigned int mlock_count;\n };\n 236 2 0 8 16 struct list_head buddy_list {\n 236 1 0 8 8 struct list_head* next;\n 0 1 0 16 8 struct list_head* prev;\n };\n 236 2 0 8 16 struct list_head pcp_list {\n 236 1 0 8 8 struct list_head* next;\n 0 1 0 16 8 struct list_head* prev;\n };\n };\n 82 4 0 24 8 struct address_space* mapping;\n 1 7 0 32 8 union {\n 1 7 0 32 8 long unsigned int index;\n 1 7 0 32 8 long unsigned int share;\n };\n 0 0 0 40 8 long unsigned int private;\n };\n\n This uses the existing annotate code', ' calling objdump to do the\n disassembly', ' with improvements to avoid having this take too long', '\n but longer term a switch to a disassembler library', ' possibly\n reusing code in the kernel will be pursued.\n\n This is the initial implementation', ' please use it and report\n impressions and bugs. Make sure the kernel-debuginfo packages match\n the running kernel. The \'perf report\' phase for non short perf.data\n files may take a while.\n\n There is a great article about it on LWN:\n\n https://lwn.net/Articles/955709/ - ""Data-type profiling for perf""\n\n One last test I did while writing this text', ' on a AMD Ryzen 5950X', '\n using a distro kernel', "" while doing a simple 'find /' on an\n otherwise idle system resulted in:\n\n # uname -r\n 6.6.9-100.fc38.x86_64\n # perf -vv | grep BPF_\n bpf: [ on ] # HAVE_LIBBPF_SUPPORT\n bpf_skeletons: [ on ] # HAVE_BPF_SKEL\n # rpm -qa | grep kernel-debuginfo\n kernel-debuginfo-common-x86_64-6.6.9-100.fc38.x86_64\n kernel-debuginfo-6.6.9-100.fc38.x86_64\n #\n # perf mem record -a --filter 'mem_op == load || mem_op == store"", "" ip > 0x8000000000000000'\n ^C[ perf record: Woken up 1 times to write data ]\n [ perf record: Captured and wrote 2.199 MB perf.data (2913 samples) ]\n #\n # ls -la perf.data\n -rw-------. 1 root root 2346486 Jan 9 18:36 perf.data\n # perf evlist\n ibs_op//\n dummy:u\n # perf evlist -v\n ibs_op//: type: 11"", ' size: 136', ' config: 0', ' { sample_period', ' sample_freq }: 4000', ' sample_type: IP|TID|TIME|ADDR|CPU|PERIOD|IDENTIFIER|DATA_SRC|WEIGHT', ' read_format: ID', ' disabled: 1', ' inherit: 1', ' freq: 1', ' sample_id_all: 1\n dummy:u: type: 1 (PERF_TYPE_SOFTWARE)', ' size: 136', ' config: 0x9 (PERF_COUNT_SW_DUMMY)', ' { sample_period', ' sample_freq }: 1', ' sample_type: IP|TID|TIME|ADDR|CPU|IDENTIFIER|DATA_SRC|WEIGHT', ' read_format: ID', ' inherit: 1', ' exclude_kernel: 1', ' exclude_hv: 1', ' mmap: 1', ' comm: 1', ' task: 1', ' mmap_data: 1', ' sample_id_all: 1', ' exclude_guest: 1', ' mmap2: 1', ' comm_exec: 1', ' ksymbol: 1', ' bpf_event: 1\n #\n # perf report -s type', ""typeoff --hierarchy --group --stdio\n # Total Lost Samples: 0\n #\n # Samples: 2K of events 'ibs_op//"", "" dummy:u'\n # Event count (approx.): 1904553038\n #\n # Overhead Data Type / Data Type Offset\n # ................... ............................\n #\n 73.70% 0.00% (unknown)\n 73.70% 0.00% (unknown) +0 (no field)\n 3.01% 0.00% long unsigned int\n 3.00% 0.00% long unsigned int +0 (no field)\n 0.01% 0.00% long unsigned int +2 (no field)\n 2.73% 0.00% struct task_struct\n 1.71% 0.00% struct task_struct +52 (on_cpu)\n 0.38% 0.00% struct task_struct +2104 (rcu_read_unlock_special.b.blocked)\n 0.23% 0.00% struct task_struct +2100 (rcu_read_lock_nesting)\n 0.14% 0.00% struct task_struct +2384 ()\n 0.06% 0.00% struct task_struct +3096 (signal)\n 0.05% 0.00% struct task_struct +3616 (cgroups)\n 0.05% 0.00% struct task_struct +2344 (active_mm)\n 0.02% 0.00% struct task_struct +46 (flags)\n 0.02% 0.00% struct task_struct +2096 (migration_disabled)\n 0.01% 0.00% struct task_struct +24 (__state)\n 0.01% 0.00% struct task_struct +3956 (mm_cid_active)\n 0.01% 0.00% struct task_struct +1048 (cpus_ptr)\n 0.01% 0.00% struct task_struct +184 (se.group_node.next)\n 0.01% 0.00% struct task_struct +20 (thread_info.cpu)\n 0.00% 0.00% struct task_struct +104 (on_rq)\n 0.00% 0.00% struct task_struct +2456 (pid)\n 1.36% 0.00% struct module\n 0.59% 0.00% struct module +952 (kallsyms)\n 0.42% 0.00% struct module +0 (state)\n 0.23% 0.00% struct module +8 (list.next)\n 0.12% 0.00% struct module +216 (syms)\n 0.95% 0.00% struct inode\n 0.41% 0.00% struct inode +40 (i_sb)\n 0.22% 0.00% struct inode +0 (i_mode)\n 0.06% 0.00% struct inode +76 (i_rdev)\n 0.06% 0.00% struct inode +56 (i_security)\n \n\n perf top/report:\n\n - Don't ignore job control"", "" allowing control+Z + bg to work.\n\n - Add s390 raw data interpretation for PAI (Processor Activity\n Instrumentation) counters.\n\n perf archive:\n\n - Add new option '--all' to pack perf.data with DSOs.\n\n - Add new option '--unpack' to expand tarballs.\n\n Initialization speedups:\n\n - Lazily initialize zstd streams to save memory when not using it.\n\n - Lazily allocate/size mmap event copy.\n\n - Lazy load kernel symbols in 'perf record'.\n\n - Be lazier in allocating lost samples buffer in 'perf record'.\n\n - Don't synthesize BPF events when disabled via the command line\n (perf record --no-bpf-event).\n\n Assorted improvements:\n\n - Show note on AMD systems that the :p"", ' :pp', ' :ppp and :P are all the\n same', ' as IBS (Instruction Based Sampling) is used and it is\n inherentely precise', "" not having levels of precision like in Intel\n systems.\n\n - When 'cycles' isn't available"", ' fall back to the ""task-clock"" event\n when not system wide', "" not to 'cpu-clock'.\n\n - Add --debug-file option to redirect debug output"", "" e.g.:\n\n $ perf --debug-file /tmp/perf.log record -v true\n\n - Shrink 'struct map' to under one cacheline by avoiding function\n pointers for selecting if addresses are identity or DSO relative"", ""\n and using just a byte for some boolean struct members.\n\n - Resolve the arch specific strerrno just once to use in\n perf_env__arch_strerrno().\n\n - Reduce memory for recording PERF_RECORD_LOST_SAMPLES event.\n\n Assorted fixes:\n\n - Fix the default 'perf top' usage on Intel hybrid systems"", ' now it\n starts with a browser showing the number of samples for Efficiency\n (cpu_atom/cycles/P) and Performance (cpu_core/cycles/P). This\n behaviour is similar on ARM64', "" with its respective set of\n big.LITTLE processors.\n\n - Fix segfault on build_mem_topology() error path.\n\n - Fix 'perf mem' error on hybrid related to availability of mem event\n in a PMU.\n\n - Fix missing reference count gets (map"", "" maps) in the db-export code.\n\n - Avoid recursively taking env->bpf_progs.lock in the 'perf_env'\n code.\n\n - Use the newly introduced maps__for_each_map() to add missing\n locking around iteration of 'struct map' entries.\n\n - Parse NOTE segments until the build id is found"", "" don't stop on the\n first one"", "" ELF files may have several such NOTE segments.\n\n - Remove 'egrep' usage"", ' its deprecated', "" use 'grep -E' instead.\n\n - Warn first about missing libelf"", ' not libbpf', "" that depends on\n libelf.\n\n - Use alternative to 'find ... -printf' as this isn't supported in\n busybox.\n\n - Address python 3.6 DeprecationWarning for string scapes.\n\n - Fix memory leak in uniq() in libsubcmd.\n\n - Fix man page formatting for 'perf lock'\n\n - Fix some spelling mistakes.\n\n perf tests:\n\n - Fail shell tests that needs some symbol in perf itself if it is\n stripped. These tests check if a symbol is resolved"", ' if some hot\n function is indeed detected by profiling', "" etc.\n\n - The 'perf test sigtrap' test is currently failing on PREEMPT_RT"", '\n skip it if sleeping spinlocks are detected (using BTF) and point to\n the mailing list discussion about it. This test is also being\n skipped on several architectures (powerpc', ' s390x', "" arm and aarch64)\n due to other pending issues with intruction breakpoints.\n\n - Adjust test case perf record offcpu profiling tests for s390.\n\n - Fix 'Setup struct perf_event_attr' fails on s390 on z/VM guest"", ""\n addressing issues caused by the fallback from cycles to task-clock\n done in this release.\n\n - Fix mask for VG register in the user-regs test.\n\n - Use shellcheck on 'perf test' shell scripts automatically to make\n sure changes don't introduce things it flags as problematic.\n\n - Add option to change objdump binary and allow it to be set via\n 'perf config'.\n\n - Add basic 'perf script'"", ' \'perf list --json"" and \'perf diff\' tests.\n\n - Basic branch counter support.\n\n - Make DSO tests a suite rather than individual.\n\n - Remove atomics from test_loop to avoid test failures.\n\n - Fix call chain match on powerpc for the record+probe_libc_inet_pton\n test.\n\n - Improve Intel hybrid tests.\n\n Vendor event files (JSON):\n\n powerpc:\n\n - Update datasource event name to fix duplicate events on IBM\'s\n Power10.\n\n - Add PVN for HX-C2000 CPU with Power8 Architecture.\n\n Intel:\n\n - Alderlake/rocketlake metric fixes.\n\n - Update emeraldrapids events to v1.02.\n\n - Update icelakex events to v1.23.\n\n - Update sapphirerapids events to v1.17.\n\n - Add skx', ' clx', ' icx and spr upi bandwidth metric.\n\n AMD:\n\n - Add Zen 4 memory controller events.\n\n RISC-V:\n\n - Add StarFive Dubhe-80 and Dubhe-90 JSON files.\n https://www.starfivetech.com/en/site/cpu-u\n\n - Add T-HEAD C9xx JSON file.\n https://github.com/riscv-software-src/opensbi/blob/master/docs/platform/thead-c9xx.md\n\n ARM64:\n\n - Remove UTF-8 characters from cmn.json', "" that were causing build\n failure in some distros.\n\n - Add core PMU events and metrics for Ampere One X.\n\n - Rename Ampere One's BPU_FLUSH_MEM_FAULT to GPC_FLUSH_MEM_FAULT\n\n libperf:\n\n - Rename several perf_cpu_map constructor names to clarify what they\n really do.\n\n - Ditto for some other methods"", ' coping with some issues in their\n semantics', ' like perf_cpu_map__empty() ->\n perf_cpu_map__has_any_cpu_or_is_empty().\n\n - Document perf_cpu_map__nr()\'s behavior\n\n perf stat:\n\n - Exit if parse groups fails.\n\n - Combine the -A/--no-aggr and --no-merge options.\n\n - Fix help message for --metric-no-threshold option.\n\n Hardware tracing:\n\n ARM64 CoreSight:\n\n - Bump minimum OpenCSD version to ensure a bugfix is present.\n\n - Add \'T\' itrace option for timestamp trace\n\n - Set start vm addr of exectable file to 0 and don\'t ignore first\n sample on the arm-cs-trace-disasm.py \'perf script\'""\n\n* tag \'perf-tools-for-v6.8-1-2024-01-09\' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools: (179 commits)\n MAINTAINERS: Add Namhyung as tools/perf/ co-maintainer\n perf test: test case \'Setup struct perf_event_attr\' fails on s390 on z/vm\n perf db-export: Fix missing reference count get in call_path_from_sample()\n perf tests: Add perf script test\n libsubcmd: Fix memory leak in uniq()\n perf TUI: Don\'t ignore job control\n perf vendor events intel: Update sapphirerapids events to v1.17\n perf vendor events intel: Update icelakex events to v1.23\n perf vendor events intel: Update emeraldrapids events to v1.02\n perf vendor events intel: Alderlake/rocketlake metric fixes\n perf x86 test: Add hybrid test for conflicting legacy/sysfs event\n perf x86 test: Update hybrid expectations\n perf vendor events amd: Add Zen 4 memory controller events\n perf stat: Fix hard coded LL miss units\n perf record: Reduce memory for recording PERF_RECORD_LOST_SAMPLES event\n perf env: Avoid recursively taking env->bpf_progs.lock\n perf annotate: Add --insn-stat option for debugging\n perf annotate: Add --type-stat option for debugging\n perf annotate: Support event group display\n perf annotate: Add --data-type option\n ...\n', '']",Merge perf tools updates adding Namhyung Kim as co-maintainer for tools/perf.,"perf,tools,maintainer",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +736b5545d39ca59d4332a60e56cc8a1a5e264a8e,736b5545d39ca59d4332a60e56cc8a1a5e264a8e,Linus Torvalds,torvalds@linux-foundation.org,1705628030,Linus Torvalds,torvalds@linux-foundation.org,1705628030,3200528110fab00e0f0d3a311b6e3ad2fcd86edd,ed8d84530ab0a3b7b370e8b28f12179314dcfcc3 925781a471d8156011e8f8c1baf61bbe020dac55,"Merge tag 'net-6.8-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + ""Including fixes from bpf and netfilter. + + Previous releases - regressions: + + - Revert ""net: rtnetlink: Enslave device before bringing it up"""," + breaks the case inverse to the one it was trying to fix + + - net: dsa: fix oob access in DSA's netdevice event handler + dereference netdev_priv() before check its a DSA port + + - sched: track device in tcf_block_get/put_ext() only for clsact + binder types + + - net: tls","["" fix WARNING in __sk_msg_free when record becomes full\n during splice and MORE hint set\n\n - sfp-bus: fix SFP mode detect from bitrate\n\n - drv: stmmac: prevent DSA tags from breaking COE\n\n Previous releases - always broken:\n\n - bpf: fix no forward progress in in bpf_iter_udp if output buffer is\n too small\n\n - bpf: reject variable offset alu on registers with a type of\n PTR_TO_FLOW_KEYS to prevent oob access\n\n - netfilter: tighten input validation\n\n - net: add more sanity check in virtio_net_hdr_to_skb()\n\n - rxrpc: fix use of Don't Fragment flag on RESPONSE packets"", ' avoid\n infinite loop\n\n - amt: do not use the portion of skb->cb area which may get clobbered\n\n - mptcp: improve validation of the MPTCPOPT_MP_JOIN MCTCP option\n\n Misc:\n\n - spring cleanup of inactive maintainers""\n\n* tag \'net-6.8-rc1\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (88 commits)\n i40e: Include types.h to some headers\n ipv6: mcast: fix data-race in ipv6_mc_down / mld_ifc_work\n selftests: mlxsw: qos_pfc: Adjust the test to support 8 lanes\n selftests: mlxsw: qos_pfc: Remove wrong description\n mlxsw: spectrum_router: Register netdevice notifier before nexthop\n mlxsw: spectrum_acl_tcam: Fix stack corruption\n mlxsw: spectrum_acl_tcam: Fix NULL pointer dereference in error path\n mlxsw: spectrum_acl_erp: Fix error flow of pool allocation failure\n ethtool: netlink: Add missing ethnl_ops_begin/complete\n selftests: bonding: Add more missing config options\n selftests: netdevsim: add a config file\n libbpf: warn on unexpected __arg_ctx type when rewriting BTF\n selftests/bpf: add tests confirming type logic in kernel for __arg_ctx\n bpf: enforce types for __arg_ctx-tagged arguments in global subprogs\n bpf: extract bpf_ctx_convert_map logic and make it more reusable\n libbpf: feature-detect arg:ctx tag support in kernel\n ipvs: avoid stat macros calls from preemptible context\n netfilter: nf_tables: reject NFT_SET_CONCAT with not field length description\n netfilter: nf_tables: skip dead set elements in netlink dump\n netfilter: nf_tables: do not allow mismatch field size and set key length\n ...\n', '']",Merge of networking fixes including bpf and netfilter regressions,"networking,fixes,bpf",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4349efc52b83af3851df7a4199567ad50b3d1f03,4349efc52b83af3851df7a4199567ad50b3d1f03,Jakub Kicinski,kuba@kernel.org,1705600464,Jakub Kicinski,kuba@kernel.org,1705600464,2f8475b57657b0f5666266df5005622c9aa05200,9cfd3b502153810b66ac0ce47f1fba682228f2d2 35ac085a94efe82d906d3a812612d432aa267cbe,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2024-01-18 + +We've added 10 non-merge commits during the last 5 day(s) which contain +a total of 12 files changed", 806 insertions(+),"[' 51 deletions(-).\n\nThe main changes are:\n\n1) Fix an issue in bpf_iter_udp under backward progress which prevents\n user space process from finishing iteration', ' from Martin KaFai Lau.\n\n2) Fix BPF verifier to reject variable offset alu on registers with a type\n of PTR_TO_FLOW_KEYS to prevent oob access', ' from Hao Sun.\n\n3) Follow up fixes for kernel- and libbpf-side logic around handling\n arg:ctx tagged arguments of BPF global subprogs', "" from Andrii Nakryiko.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n libbpf: warn on unexpected __arg_ctx type when rewriting BTF\n selftests/bpf: add tests confirming type logic in kernel for __arg_ctx\n bpf: enforce types for __arg_ctx-tagged arguments in global subprogs\n bpf: extract bpf_ctx_convert_map logic and make it more reusable\n libbpf: feature-detect arg:ctx tag support in kernel\n selftests/bpf: Add test for alu on PTR_TO_FLOW_KEYS\n bpf: Reject variable offset alu on PTR_TO_FLOW_KEYS\n selftests/bpf: Test udp and tcp iter batching\n bpf: Avoid iter->offset making backward progress in bpf_iter_udp\n bpf: iter_udp: Retry with a larger batch size without going back to the previous bucket\n====================\n\nLink: https://lore.kernel.org/r/20240118153936.11769-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n"", '']",Merges recent non-merge commits from bpf to for-netdev tag affecting 12 files.,"merge, commits, bpf",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +35ac085a94efe82d906d3a812612d432aa267cbe,35ac085a94efe82d906d3a812612d432aa267cbe,Alexei Starovoitov,ast@kernel.org,1705551606,Alexei Starovoitov,ast@kernel.org,1705551606,f8a2ed263a3ea89d0307e293ebc57b795c281a86,33772ff3b887eb2f426ed66bcb1808837a40669c 76ec90a996e3c707eb6772510afa36faeba2ecff,"Merge branch 'tighten-up-arg-ctx-type-enforcement' + +Andrii Nakryiko says: + +==================== +Tighten up arg:ctx type enforcement + +Follow up fixes for kernel-side and libbpf-side logic around handling arg:ctx +(__arg_ctx) tagged arguments of BPF global subprogs. + +Patch #1 adds libbpf feature detection of kernel-side __arg_ctx support to +avoid unnecessary rewriting BTF types. With stricter kernel-side type +enforcement this is now mandatory to avoid problems with using `struct +bpf_user_pt_regs_t` instead of actual typedef. For __arg_ctx tagged arguments +verifier is now supporting either `bpf_user_pt_regs_t` typedef or resolves it +down to the actual struct (pt_regs/user_pt_regs/user_regs_struct)"," depending +on architecture)","["" but for old kernels without __arg_ctx support it's more\nbackwards compatible for libbpf to use `struct bpf_user_pt_regs_t` rewrite\nwhich will work on wider range of kernels. So feature detection prevent libbpf\naccidentally breaking global subprogs on new kernels.\n\nWe also adjust selftests to do similar feature detection (much simpler"", ' but\npotentially breaking due to kernel source code refactoring', ' which is fine for\nselftests)', "" and skip tests expecting libbpf's BTF type rewrites.\n\nPatch #2 is preparatory refactoring for patch #3 which adds type enforcement\nfor arg:ctx tagged global subprog args. See the patch for specifics.\n\nPatch #4 adds many new cases to ensure type logic works as expected.\n\nFinally"", "" patch #5 adds a relevant subset of kernel-side type checks to\n__arg_ctx cases that libbpf supports rewrite of. In libbpf's case"", ' type\nviolations are reported as warnings and BTF rewrite is not performed', ' which\nwill eventually lead to BPF verifier complaining at program verification time.\n\nGood care was taken to avoid conflicts between bpf and bpf-next tree (which\nhas few follow up refactorings in the same code area). Once trees converge\nsome of the code will be moved around a bit (and some will be deleted)', ' but\nwith no change to functionality or general shape of the code.\n\nv2->v3:\n - support `bpf_user_pt_regs_t` typedef for KPROBE and PERF_EVENT (CI);\nv1->v2:\n - add user_pt_regs and user_regs_struct support for PERF_EVENT (CI);\n - drop FEAT_ARG_CTX_TAG enum leftover from patch #1;\n - fix warning about default: without break in the switch (CI).\n====================\n\nLink: https://lore.kernel.org/r/20240118033143.3384355-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhance type enforcement for BPF arg:ctx in kernel and libbpf for stricter verifier checks.,"type enforcement, libbpf, BPF",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +76ec90a996e3c707eb6772510afa36faeba2ecff,76ec90a996e3c707eb6772510afa36faeba2ecff,Andrii Nakryiko,andrii@kernel.org,1705548703,Alexei Starovoitov,ast@kernel.org,1705551606,f8a2ed263a3ea89d0307e293ebc57b795c281a86,989410cde81959c4033dc287d79b42b6eb04f04f,"libbpf: warn on unexpected __arg_ctx type when rewriting BTF + +On kernel that don't support arg:ctx tag"," before adjusting global +subprog BTF information to match kernel's expected canonical type names","['\nmake sure that types used by user are meaningful', ' and if not', "" warn and\ndon't do BTF adjustments.\n\nThis is similar to checks that kernel performs"", ' but narrower in scope', '\nas only a small subset of BPF program types can be accommodated by\nlibbpf using canonical type names.\n\nLibbpf unconditionally allows `struct pt_regs *` for perf_event program\ntypes', ' unlike kernel', ' which supports that conditionally on architecture.\nThis is done to keep things simple and not cause unnecessary false\npositives. This seems like a minor and harmless deviation', ' which in\nreal-world programs will be caught by kernels with arg:ctx tag support\nanyways. So KISS principle.\n\nThis logic is hard to test (especially on latest kernels)', "" so manual\ntesting was performed instead. Libbpf emitted the following warning for\nperf_event program with wrong context argument type:\n\n libbpf: prog 'arg_tag_ctx_perf': subprog 'subprog_ctx_tag' arg#0 is expected to be of `struct bpf_perf_event_data *` type\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240118033143.3384355-6-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",Add warning in libbpf for unexpected __arg_ctx type during BTF rewriting on unsupported kernels.,"libbpf, BTF, warning",It's a documentation change or typo fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +989410cde81959c4033dc287d79b42b6eb04f04f,989410cde81959c4033dc287d79b42b6eb04f04f,Andrii Nakryiko,andrii@kernel.org,1705548702,Alexei Starovoitov,ast@kernel.org,1705551606,5cf0c298e829a66889b975c7f7fa02ef6c0db801,0ba971511d16603599f947459e59b435cc465b0d,"selftests/bpf: add tests confirming type logic in kernel for __arg_ctx + +Add a bunch of global subprogs across variety of program types to +validate expected kernel type enforcement logic for __arg_ctx arguments. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240118033143.3384355-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add tests in selftests/bpf to validate type enforcement logic for __arg_ctx arguments across various program types.,"type logic,__arg_ctx,selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0ba971511d16603599f947459e59b435cc465b0d,0ba971511d16603599f947459e59b435cc465b0d,Andrii Nakryiko,andrii@kernel.org,1705548701,Alexei Starovoitov,ast@kernel.org,1705551606,efdc21275d6199a7ed86c12e1829f8420c6b8295,66967a32d3b16ed447e76fed4d946bab52e43d86,"bpf: enforce types for __arg_ctx-tagged arguments in global subprogs + +Add enforcement of expected types for context arguments tagged with +arg:ctx (__arg_ctx) tag. + +First"," any program type will accept generic `void *` context type when +combined with __arg_ctx tag. + +Besides accepting ""canonical"" struct names and `void *`","[' for a bunch of\nprogram types for which program context is actually a named struct', ' we\nallows a bunch of pragmatic exceptions to match real-world and expected\nusage:\n\n - for both kprobes and perf_event we allow `bpf_user_pt_regs_t *` as\n canonical context argument type', ' where `bpf_user_pt_regs_t` is a\n *typedef*', ' not a struct;\n - for kprobes', ' we also always accept `struct pt_regs *`', "" as that's what\n actually is passed as a context to any kprobe program;\n - for perf_event"", "" we resolve typedefs (unless it's `bpf_user_pt_regs_t`)\n down to actual struct type and accept `struct pt_regs *`"", ' or\n `struct user_pt_regs *`', ' or `struct user_regs_struct *`', ' depending\n on the actual struct type kernel architecture points `bpf_user_pt_regs_t`\n typedef to; otherwise', ' canonical `struct bpf_perf_event_data *` is\n expected;\n - for raw_tp/raw_tp.w programs', ' `u64/long *` are accepted', "" as that's\n what's expected with BPF_PROG() usage; otherwise"", ' canonical\n `struct bpf_raw_tracepoint_args *` is expected;\n - tp_btf supports both `struct bpf_raw_tracepoint_args *` and `u64 *`\n formats', ' both are coded as expections as tp_btf is actually a TRACING\n program type', ' which has no canonical context type;\n - iterator programs accept `struct bpf_iter__xxx *` structs', ' currently\n with no further iterator-type specific enforcement;\n - fentry/fexit/fmod_ret/lsm/struct_ops all accept `u64 *`;\n - classic tracepoint programs', "" as well as syscall and freplace\n programs allow any user-provided type.\n\nIn all other cases kernel will enforce exact match of struct name to\nexpected canonical type. And if user-provided type doesn't match that\nexpectation"", ' verifier will emit helpful message with expected type name.\n\nNote a bit unnatural way the check is done after processing all the\narguments. This is done to avoid conflict between bpf and bpf-next\ntrees. Once trees converge', ' a small follow up patch will place a simple\nbtf_validate_prog_ctx_type() check into a proper ARG_PTR_TO_CTX branch\n(which bpf-next tree patch refactored already)', ' removing duplicated\narg:ctx detection logic.\n\nSuggested-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240118033143.3384355-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enforces expected types for context arguments with __arg_ctx tag in global subprograms in eBPF.,"enforce, context, __arg_ctx",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +66967a32d3b16ed447e76fed4d946bab52e43d86,66967a32d3b16ed447e76fed4d946bab52e43d86,Andrii Nakryiko,andrii@kernel.org,1705548700,Alexei Starovoitov,ast@kernel.org,1705551605,cf12401fd7bc09c7a4b63ce9eadbe67ce63038b2,01b55f4f0cd6ad1a16eca6c43a3190005892ef91,"bpf: extract bpf_ctx_convert_map logic and make it more reusable + +Refactor btf_get_prog_ctx_type() a bit to allow reuse of +bpf_ctx_convert_map logic in more than one places. Simplify interface by +returning btf_type instead of btf_member (field reference in BTF). + +To do the above we need to touch and start untangling +btf_translate_to_vmlinux() implementation. We do the bare minimum to +not regress anything for btf_translate_to_vmlinux()"," but its +implementation is very questionable for what it claims to be doing. +Mapping kfunc argument types to kernel corresponding types conceptually +is quite different from recognizing program context types. Fixing this +is out of scope for this change though. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240118033143.3384355-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Refactors btf_get_prog_ctx_type to enhance reusability of bpf_ctx_convert_map logic.,"refactor,reusability,btf",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +01b55f4f0cd6ad1a16eca6c43a3190005892ef91,01b55f4f0cd6ad1a16eca6c43a3190005892ef91,Andrii Nakryiko,andrii@kernel.org,1705548699,Alexei Starovoitov,ast@kernel.org,1705551605,379519a1519a94a55e0e0948c405959f1eadc984,33772ff3b887eb2f426ed66bcb1808837a40669c,"libbpf: feature-detect arg:ctx tag support in kernel + +Add feature detector of kernel-side arg:ctx (__arg_ctx) tag support. If +this is detected"," libbpf will avoid doing any __arg_ctx-related BTF +rewriting and checks in favor of letting kernel handle this completely. + +test_global_funcs/ctx_arg_rewrite subtest is adjusted to do the same +feature detection (albeit in much simpler","[' though round-about and\ninefficient', ' way)', ' and skip the tests. This is done to still be able to\nexecute this test on older kernels (like in libbpf CI).\n\nNote', ' BPF token series ([0]) does a major refactor and code moving of\nlibbpf-internal feature detection ""framework""', ' so to avoid unnecessary\nconflicts we keep newly added feature detection stand-alone with ad-hoc\nresult caching. Once things settle', ' there will be a small follow up to\nre-integrate everything back and move code into its final place in\nnewly-added (by BPF token series) features.c file.\n\n [0] https://patchwork.kernel.org/project/netdevbpf/list/?series=814209&state=*\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240118033143.3384355-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added feature detection for kernel support of arg:ctx tag in libbpf.,"feature detection,arg:ctx,libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +36a87385e31c9343af9a4756598e704741250a67,36a87385e31c9343af9a4756598e704741250a67,Hengqi Chen,hengqi.chen@gmail.com,1705466593,Huacai Chen,chenhuacai@loongson.cn,1705466593,37abebd6a08c9764bb5285f0b3661b697d842a49,21c5ae5cc1eee70f7f3b09f1d6b237d9812d4b9c,"LoongArch: BPF: Prevent out-of-bounds memory access + +The test_tag test triggers an unhandled page fault: + + # ./test_tag + [ 130.640218] CPU 0 Unable to handle kernel paging request at virtual address ffff80001b898004", era == 9000000003137f7c,"[' ra == 9000000003139e70\n [ 130.640501] Oops[#3]:\n [ 130.640553] CPU: 0 PID: 1326 Comm: test_tag Tainted: G D O 6.7.0-rc4-loong-devel-gb62ab1a397cf #47 61985c1d94084daa2432f771daa45b56b10d8d2a\n [ 130.640764] Hardware name: QEMU QEMU Virtual Machine', ' BIOS unknown 2/2/2022\n [ 130.640874] pc 9000000003137f7c ra 9000000003139e70 tp 9000000104cb4000 sp 9000000104cb7a40\n [ 130.641001] a0 ffff80001b894000 a1 ffff80001b897ff8 a2 000000006ba210be a3 0000000000000000\n [ 130.641128] a4 000000006ba210be a5 00000000000000f1 a6 00000000000000b3 a7 0000000000000000\n [ 130.641256] t0 0000000000000000 t1 00000000000007f6 t2 0000000000000000 t3 9000000004091b70\n [ 130.641387] t4 000000006ba210be t5 0000000000000004 t6 fffffffffffffff0 t7 90000000040913e0\n [ 130.641512] t8 0000000000000005 u0 0000000000000dc0 s9 0000000000000009 s0 9000000104cb7ae0\n [ 130.641641] s1 00000000000007f6 s2 0000000000000009 s3 0000000000000095 s4 0000000000000000\n [ 130.641771] s5 ffff80001b894000 s6 ffff80001b897fb0 s7 9000000004090c50 s8 0000000000000000\n [ 130.641900] ra: 9000000003139e70 build_body+0x1fcc/0x4988\n [ 130.642007] ERA: 9000000003137f7c build_body+0xd8/0x4988\n [ 130.642112] CRMD: 000000b0 (PLV0 -IE -DA +PG DACF=CC DACM=CC -WE)\n [ 130.642261] PRMD: 00000004 (PPLV0 +PIE -PWE)\n [ 130.642353] EUEN: 00000003 (+FPE +SXE -ASXE -BTE)\n [ 130.642458] ECFG: 00071c1c (LIE=2-4', '10-12 VS=7)\n [ 130.642554] ESTAT: 00010000 [PIL] (IS= ECode=1 EsubCode=0)\n [ 130.642658] BADV: ffff80001b898004\n [ 130.642719] PRID: 0014c010 (Loongson-64bit', ' Loongson-3A5000)\n [ 130.642815] Modules linked in: [last unloaded: bpf_testmod(O)]\n [ 130.642924] Process test_tag (pid: 1326', ' threadinfo=00000000f7f4015f', ' task=000000006499f9fd)\n [ 130.643062] Stack : 0000000000000000 9000000003380724 0000000000000000 0000000104cb7be8\n [ 130.643213] 0000000000000000 25af8d9b6e600558 9000000106250ea0 9000000104cb7ae0\n [ 130.643378] 0000000000000000 0000000000000000 9000000104cb7be8 90000000049f6000\n [ 130.643538] 0000000000000090 9000000106250ea0 ffff80001b894000 ffff80001b894000\n [ 130.643685] 00007ffffb917790 900000000313ca94 0000000000000000 0000000000000000\n [ 130.643831] ffff80001b894000 0000000000000ff7 0000000000000000 9000000100468000\n [ 130.643983] 0000000000000000 0000000000000000 0000000000000040 25af8d9b6e600558\n [ 130.644131] 0000000000000bb7 ffff80001b894048 0000000000000000 0000000000000000\n [ 130.644276] 9000000104cb7be8 90000000049f6000 0000000000000090 9000000104cb7bdc\n [ 130.644423] ffff80001b894000 0000000000000000 00007ffffb917790 90000000032acfb0\n [ 130.644572] ...\n [ 130.644629] Call Trace:\n [ 130.644641] [<9000000003137f7c>] build_body+0xd8/0x4988\n [ 130.644785] [<900000000313ca94>] bpf_int_jit_compile+0x228/0x4ec\n [ 130.644891] [<90000000032acfb0>] bpf_prog_select_runtime+0x158/0x1b0\n [ 130.645003] [<90000000032b3504>] bpf_prog_load+0x760/0xb44\n [ 130.645089] [<90000000032b6744>] __sys_bpf+0xbb8/0x2588\n [ 130.645175] [<90000000032b8388>] sys_bpf+0x20/0x2c\n [ 130.645259] [<9000000003f6ab38>] do_syscall+0x7c/0x94\n [ 130.645369] [<9000000003121c5c>] handle_syscall+0xbc/0x158\n [ 130.645507]\n [ 130.645539] Code: 380839f6 380831f9 28412bae <24000ca6> 004081ad 0014cb50 004083e8 02bff34c 58008e91\n [ 130.645729]\n [ 130.646418] ---[ end trace 0000000000000000 ]---\n\nOn my machine', ' which has CONFIG_PAGE_SIZE_16KB=y', ' the test failed at\nloading a BPF prog with 2039 instructions:\n\n prog = (struct bpf_prog *)ffff80001b894000\n insn = (struct bpf_insn *)(prog->insnsi)ffff80001b894048\n insn + 2039 = (struct bpf_insn *)ffff80001b898000 <- end of the page\n\nIn the build_insn() function', ' we are trying to access next instruction\nunconditionally', ' i.e. `(insn + 1)->imm`. The address lies in the next\npage and can be not owned by the current process', ' thus an page fault is\ninevitable and then segfault.\n\nSo', "" let's access next instruction only under `dst = imm64` context.\n\nWith this fix"", ' we have:\n\n # ./test_tag\n test_tag: OK (40945 tests)\n\nFixes: bbfddb904df6f82 (""LoongArch: BPF: Avoid declare variables in switch-case"")\nTested-by: Tiezhu Yang \nSigned-off-by: Hengqi Chen \nSigned-off-by: Huacai Chen \n', '']",The commit prevents out-of-bounds memory access on LoongArch architecture for BPF.,"LoongArch,BPF,memory",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +21c5ae5cc1eee70f7f3b09f1d6b237d9812d4b9c,21c5ae5cc1eee70f7f3b09f1d6b237d9812d4b9c,Hengqi Chen,hengqi.chen@gmail.com,1705466593,Huacai Chen,chenhuacai@loongson.cn,1705466593,b43792773494abb6c9264c8a1998110a054d121e,91af17cd7d03db8836554c91ba7c38b0817aa980,"LoongArch: BPF: Support 64-bit pointers to kfuncs + +Like commit 1cf3bfc60f9836f (""bpf: Support 64-bit pointers to kfuncs"") +for s390x"," add support for 64-bit pointers to kfuncs for LoongArch. +Since the infrastructure is already implemented in BPF core","[' the only\nthing need to be done is to override bpf_jit_supports_far_kfunc_call().\n\nBefore this change', "" several test_verifier tests failed:\n\n # ./test_verifier | grep # | grep FAIL\n #119/p calls: invalid kfunc call: ptr_to_mem to struct with non-scalar FAIL\n #120/p calls: invalid kfunc call: ptr_to_mem to struct with nesting depth > 4 FAIL\n #121/p calls: invalid kfunc call: ptr_to_mem to struct with FAM FAIL\n #122/p calls: invalid kfunc call: reg->type != PTR_TO_CTX FAIL\n #123/p calls: invalid kfunc call: void * not allowed in func proto without mem size arg FAIL\n #124/p calls: trigger reg2btf_ids[reg->type] for reg->type > __BPF_REG_TYPE_MAX FAIL\n #125/p calls: invalid kfunc call: reg->off must be zero when passed to release kfunc FAIL\n #126/p calls: invalid kfunc call: don't match first member type when passed to release kfunc FAIL\n #127/p calls: invalid kfunc call: PTR_TO_BTF_ID with negative offset FAIL\n #128/p calls: invalid kfunc call: PTR_TO_BTF_ID with variable offset FAIL\n #129/p calls: invalid kfunc call: referenced arg needs refcounted PTR_TO_BTF_ID FAIL\n #130/p calls: valid kfunc call: referenced arg needs refcounted PTR_TO_BTF_ID FAIL\n #486/p map_kptr: ref: reference state created and released on xchg FAIL\n\nThis is because the kfuncs in the loaded module are far away from\n__bpf_call_base:\n\n ffff800002009440 t bpf_kfunc_call_test_fail1 [bpf_testmod]\n 9000000002e128d8 T __bpf_call_base\n\nThe offset relative to __bpf_call_base does NOT fit in s32"", ' which breaks\nthe assumption in BPF core. Enable bpf_jit_supports_far_kfunc_call() lifts\nthis limit.\n\nNote that to reproduce the above result', ' tools/testing/selftests/bpf/config\nshould be applied', ' and run the test with JIT enabled', ' unpriv BPF enabled.\n\nWith this change', ' the test_verifier tests now all passed:\n\n # ./test_verifier\n ...\n Summary: 777 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\nTested-by: Tiezhu Yang \nSigned-off-by: Hengqi Chen \nSigned-off-by: Huacai Chen \n', '']",Enable 64-bit pointer support for kfuncs in LoongArch architecture.,"LoongArch, 64-bit, kfuncs",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +33772ff3b887eb2f426ed66bcb1808837a40669c,33772ff3b887eb2f426ed66bcb1808837a40669c,Hao Sun,sunhao.th@gmail.com,1705306828,Daniel Borkmann,daniel@iogearbox.net,1705421568,61761765fc9b6a76a9f4baddb9e63aa6cfe1a016,22c7fa171a02d310e3a3f6ed46a698ca8a0060ed,"selftests/bpf: Add test for alu on PTR_TO_FLOW_KEYS + +Add a test case for PTR_TO_FLOW_KEYS alu. Testing if alu with variable +offset on flow_keys is rejected. For the fixed offset success case"," we +already have C code coverage to verify (e.g. via bpf_flow.c). + +Signed-off-by: Hao Sun +Signed-off-by: Daniel Borkmann +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20240115082028.9992-2-sunhao.th@gmail.com +",[''],Add a test case for validating alu operations on PTR_TO_FLOW_KEYS in selftests.,"alu, PTR_TO_FLOW_KEYS, test",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +22c7fa171a02d310e3a3f6ed46a698ca8a0060ed,22c7fa171a02d310e3a3f6ed46a698ca8a0060ed,Hao Sun,sunhao.th@gmail.com,1705306827,Daniel Borkmann,daniel@iogearbox.net,1705421549,25d757455c4e813c372b4407539ef27566547f9b,8e33d5db7d014ea2fb2994bbe42010d043997d60,"bpf: Reject variable offset alu on PTR_TO_FLOW_KEYS + +For PTR_TO_FLOW_KEYS"," check_flow_keys_access() only uses fixed off +for validation. However","[' variable offset ptr alu is not prohibited\nfor this ptr kind. So the variable offset is not checked.\n\nThe following prog is accepted:\n\n func#0 @0\n 0: R1=ctx() R10=fp0\n 0: (bf) r6 = r1 ; R1=ctx() R6_w=ctx()\n 1: (79) r7 = *(u64 *)(r6 +144) ; R6_w=ctx() R7_w=flow_keys()\n 2: (b7) r8 = 1024 ; R8_w=1024\n 3: (37) r8 /= 1 ; R8_w=scalar()\n 4: (57) r8 &= 1024 ; R8_w=scalar(smin=smin32=0', '\n smax=umax=smax32=umax32=1024', 'var_off=(0x0; 0x400))\n 5: (0f) r7 += r8\n mark_precise: frame0: last_idx 5 first_idx 0 subseq_idx -1\n mark_precise: frame0: regs=r8 stack= before 4: (57) r8 &= 1024\n mark_precise: frame0: regs=r8 stack= before 3: (37) r8 /= 1\n mark_precise: frame0: regs=r8 stack= before 2: (b7) r8 = 1024\n 6: R7_w=flow_keys(smin=smin32=0', 'smax=umax=smax32=umax32=1024', 'var_off\n =(0x0; 0x400)) R8_w=scalar(smin=smin32=0', 'smax=umax=smax32=umax32=1024', '\n var_off=(0x0; 0x400))\n 6: (79) r0 = *(u64 *)(r7 +0) ; R0_w=scalar()\n 7: (95) exit\n\nThis prog loads flow_keys to r7', ' and adds the variable offset r8\nto r7', ' and finally causes out-of-bounds access:\n\n BUG: unable to handle page fault for address: ffffc90014c80038\n [...]\n Call Trace:\n \n bpf_dispatcher_nop_func include/linux/bpf.h:1231 [inline]\n __bpf_prog_run include/linux/filter.h:651 [inline]\n bpf_prog_run include/linux/filter.h:658 [inline]\n bpf_prog_run_pin_on_cpu include/linux/filter.h:675 [inline]\n bpf_flow_dissect+0x15f/0x350 net/core/flow_dissector.c:991\n bpf_prog_test_run_flow_dissector+0x39d/0x620 net/bpf/test_run.c:1359\n bpf_prog_test_run kernel/bpf/syscall.c:4107 [inline]\n __sys_bpf+0xf8f/0x4560 kernel/bpf/syscall.c:5475\n __do_sys_bpf kernel/bpf/syscall.c:5561 [inline]\n __se_sys_bpf kernel/bpf/syscall.c:5559 [inline]\n __x64_sys_bpf+0x73/0xb0 kernel/bpf/syscall.c:5559\n do_syscall_x64 arch/x86/entry/common.c:52 [inline]\n do_syscall_64+0x3f/0x110 arch/x86/entry/common.c:83\n entry_SYSCALL_64_after_hwframe+0x63/0x6b\n\nFix this by rejecting ptr alu with variable offset on flow_keys.\nApplying the patch rejects the program with ""R7 pointer arithmetic\non flow_keys prohibited"".\n\nFixes: d58e468b1112 (""flow_dissector: implements flow dissector BPF hook"")\nSigned-off-by: Hao Sun \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20240115082028.9992-1-sunhao.th@gmail.com\n', '']",This commit rejects variable offset ALU operations on PTR_TO_FLOW_KEYS to ensure fixed offset validation.,"PTR_TO_FLOW_KEYS,variable offset,validation",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8e33d5db7d014ea2fb2994bbe42010d043997d60,8e33d5db7d014ea2fb2994bbe42010d043997d60,Alexei Starovoitov,ast@kernel.org,1705172504,Alexei Starovoitov,ast@kernel.org,1705172504,71e53516b735b032818495974d52ea94d669012e,894d7508316e7ad722df597d68b4b1797a9eee11 dbd7db7787ba1743a505a495e479550932836fa4,"Merge branch 'bpf-fix-backward-progress-bug-in-bpf_iter_udp' + +Martin KaFai Lau says: + +==================== +bpf: Fix backward progress bug in bpf_iter_udp + +From: Martin KaFai Lau + +This patch set fixes an issue in bpf_iter_udp that makes backward +progress and prevents the user space process from finishing. There is +a test at the end to reproduce the bug. + +Please see individual patches for details. + +v3: +- Fixed the iter_fd check and local_port check in the + patch 3 selftest. (Yonghong) +- Moved jhash2 to test_jhash.h in the patch 3. (Yonghong) +- Added explanation in the bucket selection in the patch 3. (Yonghong) + +v2: +- Added patch 1 to fix another bug that goes back to + the previous bucket +- Simplify the fix in patch 2 to always reset iter->offset to 0 +- Add a test case to close all udp_sk in a bucket while + in the middle of the iteration. +==================== + +Link: https://lore.kernel.org/r/20240112190530.3751661-1-martin.lau@linux.dev +Signed-off-by: Alexei Starovoitov +",,Fixes backward progress bug in bpf_iter_udp that prevents user space process completion.,"bpf_iter_udp, bug fix, backward progress",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dbd7db7787ba1743a505a495e479550932836fa4,dbd7db7787ba1743a505a495e479550932836fa4,Martin KaFai Lau,martin.lau@kernel.org,1705086330,Alexei Starovoitov,ast@kernel.org,1705172504,71e53516b735b032818495974d52ea94d669012e,2242fd537fab52d5f4d2fbb1845f047c01fad0cf,"selftests/bpf: Test udp and tcp iter batching + +The patch adds a test to exercise the bpf_iter_udp batching +logic. It specifically tests the case that there are multiple +so_reuseport udp_sk in a bucket of the udp_table. + +The test creates two sets of so_reuseport sockets and +each set on a different port. Meaning there will be +two buckets in the udp_table. + +The test does the following: +1. read() 3 out of 4 sockets in the first bucket. +2. close() all sockets in the first bucket. This + will ensure the current bucket's offset in + the kernel does not affect the read() of the + following bucket. +3. read() all 4 sockets in the second bucket. + +The test also reads one udp_sk at a time from +the bpf_iter_udp prog. The true case in +""do_test(..."," bool onebyone)"". This is the buggy case +that the previous patch fixed. + +It also tests the ""false"" case in ""do_test(...","[' bool onebyone)""', '\nmeaning the userspace reads the whole bucket. There is\nno bug in this case but adding this test also while\nat it.\n\nConsidering the way to have multiple tcp_sk in the same\nbucket is similar (by using so_reuseport)', '\nthis patch also tests the bpf_iter_tcp even though the\nbpf_iter_tcp batching logic works correctly.\n\nBoth IP v4 and v6 are exercising the same bpf_iter batching\ncode path', ' so only v6 is tested.\n\nAcked-by: Yonghong Song \nSigned-off-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20240112190530.3751661-4-martin.lau@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",The commit adds a test for bpf_iter_udp batching in selftests.,"bpf_iter_udp, batching, udp_sk",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2242fd537fab52d5f4d2fbb1845f047c01fad0cf,2242fd537fab52d5f4d2fbb1845f047c01fad0cf,Martin KaFai Lau,martin.lau@kernel.org,1705086329,Alexei Starovoitov,ast@kernel.org,1705172504,edc0bcbd15a6c566dcdeb7fbd1e1ce40b39f56ff,19ca0823f6eaad01d18f664a00550abe912c034c,"bpf: Avoid iter->offset making backward progress in bpf_iter_udp + +There is a bug in the bpf_iter_udp_batch() function that stops +the userspace from making forward progress. + +The case that triggers the bug is the userspace passed in +a very small read buffer. When the bpf prog does bpf_seq_printf"," +the userspace read buffer is not enough to capture the whole bucket. + +When the read buffer is not large enough","[' the kernel will remember\nthe offset of the bucket in iter->offset such that the next userspace\nread() can continue from where it left off.\n\nThe kernel will skip the number (== ""iter->offset"") of sockets in\nthe next read(). However', ' the code directly decrements the\n""--iter->offset"". This is incorrect because the next read() may\nnot consume the whole bucket either and then the next-next read()\nwill start from offset 0. The net effect is the userspace will\nkeep reading from the beginning of a bucket and the process will\nnever finish. ""iter->offset"" must always go forward until the\nwhole bucket is consumed.\n\nThis patch fixes it by using a local variable ""resume_offset""\nand ""resume_bucket"". ""iter->offset"" is always reset to 0 before\nit may be used. ""iter->offset"" will be advanced to the\n""resume_offset"" when it continues from the ""resume_bucket"" (i.e.\n""state->bucket == resume_bucket""). This brings it closer to\nthe bpf_iter_tcp\'s offset handling which does not suffer\nthe same bug.\n\nCc: Aditi Ghag \nFixes: c96dac8d369f (""bpf: udp: Implement batching for sockets iterator"")\nAcked-by: Yonghong Song \nSigned-off-by: Martin KaFai Lau \nReviewed-by: Aditi Ghag \nLink: https://lore.kernel.org/r/20240112190530.3751661-3-martin.lau@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes a bug in bpf_iter_udp_batch to ensure forward progress with small userspace read buffers.,"bug, bpf_iter_udp, userspace",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['socket like programs'] +19ca0823f6eaad01d18f664a00550abe912c034c,19ca0823f6eaad01d18f664a00550abe912c034c,Martin KaFai Lau,martin.lau@kernel.org,1705086328,Alexei Starovoitov,ast@kernel.org,1705172504,f3b56edf62d964d24064b1ffb659697cb71f2408,894d7508316e7ad722df597d68b4b1797a9eee11,"bpf: iter_udp: Retry with a larger batch size without going back to the previous bucket + +The current logic is to use a default size 16 to batch the whole bucket. +If it is too small"," it will retry with a larger batch size. + +The current code accidentally does a state->bucket-- before retrying. +This goes back to retry with the previous bucket which has already +been done. This patch fixed it. + +It is hard to create a selftest. I added a WARN_ON(state->bucket < 0)","['\nforced a particular port to be hashed to the first bucket', '\ncreated >16 sockets', ' and observed the for-loop went back\nto the ""-1"" bucket.\n\nCc: Aditi Ghag \nFixes: c96dac8d369f (""bpf: udp: Implement batching for sockets iterator"")\nAcked-by: Yonghong Song \nSigned-off-by: Martin KaFai Lau \nReviewed-by: Aditi Ghag \nLink: https://lore.kernel.org/r/20240112190530.3751661-2-martin.lau@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']","Fixes issue in iter_udp logic where retries incorrectly decrease bucket index, causing redundant processing of previous bucket.","iter_udp, batch, fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"[""It's not related to any of the above.""]" +fef018d8199661962b5fc0f0d1501caa54b2b533,fef018d8199661962b5fc0f0d1501caa54b2b533,Linus Torvalds,torvalds@linux-foundation.org,1705099513,Linus Torvalds,torvalds@linux-foundation.org,1705099513,df2bb3503feec710d84bca3ba37487b5822cded1,d97a78423c33f68ca6543de510a409167baed6f5 0b43615af19742e1f4f71d332e72381430804804,"Merge tag 'hid-for-linus-2024010801' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid + +Pull HID updates from Jiri Kosina: + + - assorted functional fixes for hid-steam ported from SteamOS betas + (Vicki Pfau) + + - fix for custom sensor-hub sensors (hinge angle sensor and LISS + sensors) not working (Yauhen Kharuzhy) + + - functional fix for handling Confidence in Wacom driver (Jason + Gerecke) + + - support for Ilitek ili2901 touchscreen (Zhengqiao Xia) + + - power management fix for Wacom userspace battery exporting + (Tatsunosuke Tobita) + + - rework of wait-for-reset in order to reduce the need for + I2C_HID_QUIRK_NO_IRQ_AFTER_RESET qurk; the success rate is now 50% + better"," but there are still further improvements to be made (Hans de + Goede) + + - greatly improved coverage of Tablets in hid-selftests (Benjamin + Tissoires) + + - support for Nintendo NSO controllers -- SNES","["" Genesis and N64 (Ryan\n McClelland)\n\n - support for controlling mcp2200 GPIOs (Johannes Roith)\n\n - power management improvement for EHL OOB wakeup in intel-ish\n (Kai-Heng Feng)\n\n - other assorted device-specific fixes and code cleanups\n\n* tag 'hid-for-linus-2024010801' of git://git.kernel.org/pub/scm/linux/kernel/git/hid/hid: (53 commits)\n HID: amd_sfh: Add a new interface for exporting ALS data\n HID: amd_sfh: Add a new interface for exporting HPD data\n HID: amd_sfh: rename float_to_int() to amd_sfh_float_to_int()\n HID: i2c-hid: elan: Add ili2901 timing\n dt-bindings: HID: i2c-hid: elan: Introduce Ilitek ili2901\n HID: bpf: make bus_type const in struct hid_bpf_ops\n HID: make ishtp_cl_bus_type const\n HID: make hid_bus_type const\n HID: hid-steam: Add gamepad-only mode switched to by holding options\n HID: hid-steam: Better handling of serial number length\n HID: hid-steam: Update list of identifiers from SDL\n HID: hid-steam: Make client_opened a counter\n HID: hid-steam: Clean up locking\n HID: hid-steam: Disable watchdog instead of using a heartbeat\n HID: hid-steam: Avoid overwriting smoothing parameter\n HID: magicmouse: fix kerneldoc for struct magicmouse_sc\n HID: sensor-hub: Enable hid core report processing for all devices\n HID: wacom: Add additional tests of confidence behavior\n HID: wacom: Correct behavior when processing some confidence == false touches\n HID: nintendo: add support for nso controllers\n ...\n"", '']","Merged HID updates including functional fixes, sensor support, power management fixes, and improved self-tests.","HID, fixes, support",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +3e7aeb78ab01c2c2f0e1f784e5ddec88fcd3d106,3e7aeb78ab01c2c2f0e1f784e5ddec88fcd3d106,Linus Torvalds,torvalds@linux-foundation.org,1704996449,Linus Torvalds,torvalds@linux-foundation.org,1704996449,bdbfd45f8d8e967b06ed2d9cb92f67f686d02659,de927f6c0b07d9e698416c5b287c521b07694cac a7fe0881d9b78d402bbd9067dd4503a57c57a1d9,"Merge tag 'net-next-6.8' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next + +Pull networking updates from Paolo Abeni: + ""The most interesting thing is probably the networking structs + reorganization and a significant amount of changes is around + self-tests. + + Core & protocols: + + - Analyze and reorganize core networking structs (socks", netdev,"['\n netns', ' mibs) to optimize cacheline consumption and set up build\n time warnings to safeguard against future header changes\n\n This improves TCP performances with many concurrent connections up\n to 40%\n\n - Add page-pool netlink-based introspection', ' exposing the memory\n usage and recycling stats. This helps indentify bad PP users and\n possible leaks\n\n - Refine TCP/DCCP source port selection to no longer favor even\n source port at connect() time when IP_LOCAL_PORT_RANGE is set. This\n lowers the time taken by connect() for hosts having many active\n connections to the same destination\n\n - Refactor the TCP bind conflict code', ' shrinking related socket\n structs\n\n - Refactor TCP SYN-Cookie handling', ' as a preparation step to allow\n arbitrary SYN-Cookie processing via eBPF\n\n - Tune optmem_max for 0-copy usage', ' increasing the default value to\n 128KB and namespecifying it\n\n - Allow coalescing for cloned skbs coming from page pools', ' improving\n RX performances with some common configurations\n\n - Reduce extension header parsing overhead at GRO time\n\n - Add bridge MDB bulk deletion support', ' allowing user-space to\n request the deletion of matching entries\n\n - Reorder nftables struct members', ' to keep data accessed by the\n datapath first\n\n - Introduce TC block ports tracking and use. This allows supporting\n multicast-like behavior at the TC layer\n\n - Remove UAPI support for retired TC qdiscs (dsmark', ' CBQ and ATM) and\n classifiers (RSVP and tcindex)\n\n - More data-race annotations\n\n - Extend the diag interface to dump TCP bound-only sockets\n\n - Conditional notification of events for TC qdisc class and actions\n\n - Support for WPAN dynamic associations with nearby devices', ' to form\n a sub-network using a specific PAN ID\n\n - Implement SMCv2.1 virtual ISM device support\n\n - Add support for Batman-avd mulicast packet type\n\n BPF:\n\n - Tons of verifier improvements:\n - BPF register bounds logic and range support along with a large\n test suite\n - log improvements\n - complete precision tracking support for register spills\n - track aligned STACK_ZERO cases as imprecise spilled registers.\n This improves the verifier ""instructions processed"" metric from\n single digit to 50-60% for some programs\n - support for user\'s global BPF subprogram arguments with few\n commonly requested annotations for a better developer\n experience\n - support tracking of BPF_JNE which helps cases when the compiler\n transforms (unsigned) ""a > 0"" into ""if a == 0 goto xxx"" and the\n like\n - several fixes\n\n - Add initial TX metadata implementation for AF_XDP with support in\n mlx5 and stmmac drivers. Two types of offloads are supported right\n now', ' that is', ' TX timestamp and TX checksum offload\n\n - Fix kCFI bugs in BPF all forms of indirect calls from BPF into\n kernel and from kernel into BPF work with CFI enabled. This allows\n BPF to work with CONFIG_FINEIBT=y\n\n - Change BPF verifier logic to validate global subprograms lazily\n instead of unconditionally before the main program', ' so they can be\n guarded using BPF CO-RE techniques\n\n - Support uid/gid options when mounting bpffs\n\n - Add a new kfunc which acquires the associated cgroup of a task\n within a specific cgroup v1 hierarchy where the latter is\n identified by its id\n\n - Extend verifier to allow bpf_refcount_acquire() of a map value\n field obtained via direct load which is a use-case needed in\n sched_ext\n\n - Add BPF link_info support for uprobe multi link along with bpftool\n integration for the latter\n\n - Support for VLAN tag in XDP hints\n\n - Remove deprecated bpfilter kernel leftovers given the project is\n developed in user-space (https://github.com/facebook/bpfilter)\n\n Misc:\n\n - Support for parellel TC self-tests execution\n\n - Increase MPTCP self-tests coverage\n\n - Updated the bridge documentation', ' including several so-far\n undocumented features\n\n - Convert all the net self-tests to run in unique netns', ' to avoid\n random failures due to conflict and allow concurrent runs\n\n - Add TCP-AO self-tests\n\n - Add kunit tests for both cfg80211 and mac80211\n\n - Autogenerate Netlink families documentation from YAML spec\n\n - Add yml-gen support for fixed headers and recursive nests', ' the tool\n can now generate user-space code for all genetlink families for\n which we have specs\n\n - A bunch of additional module descriptions fixes\n\n - Catch incorrect freeing of pages belonging to a page pool\n\n Driver API:\n\n - Rust abstractions for network PHY drivers; do not cover yet the\n full C API', ' but already allow implementing functional PHY drivers\n in rust\n\n - Introduce queue and NAPI support in the netdev Netlink interface', '\n allowing complete access to the device <> NAPIs <> queues\n relationship\n\n - Introduce notifications filtering for devlink to allow control\n application scale to thousands of instances\n\n - Improve PHY validation', ' requesting rate matching information for\n each ethtool link mode supported by both the PHY and host\n\n - Add support for ethtool symmetric-xor RSS hash\n\n - ACPI based Wifi band RFI (WBRF) mitigation feature for the AMD\n platform\n\n - Expose pin fractional frequency offset value over new DPLL generic\n netlink attribute\n\n - Convert older drivers to platform remove callback returning void\n\n - Add support for PHY package MMD read/write\n\n New hardware / drivers:\n\n - Ethernet:\n - Octeon CN10K devices\n - Broadcom 5760X P7\n - Qualcomm SM8550 SoC\n - Texas Instrument DP83TG720S PHY\n\n - Bluetooth:\n - IMC Networks Bluetooth radio\n\n Removed:\n\n - WiFi:\n - libertas 16-bit PCMCIA support\n - Atmel at76c50x drivers\n - HostAP ISA/PCMCIA style 802.11b driver\n - zd1201 802.11b USB dongles\n - Orinoco ISA/PCMCIA 802.11b driver\n - Aviator/Raytheon driver\n - Planet WL3501 driver\n - RNDIS USB 802.11b driver\n\n Driver updates:\n\n - Ethernet high-speed NICs:\n - Intel (100G', ' ice', "" idpf):\n - allow one by one port representors creation and removal\n - add temperature and clock information reporting\n - add get/set for ethtool's header split ringparam\n - add again FW logging\n - adds support switchdev hardware packet mirroring\n - iavf: implement symmetric-xor RSS hash\n - igc: add support for concurrent physical and free-running\n timers\n - i40e: increase the allowable descriptors\n - nVidia/Mellanox:\n - Preparation for Socket-Direct multi-dev netdev. That will\n allow in future releases combining multiple PFs devices\n attached to different NUMA nodes under the same netdev\n - Broadcom (bnxt):\n - TX completion handling improvements\n - add basic ntuple filter support\n - reduce MSIX vectors usage for MQPRIO offload\n - add VXLAN support"", ' USO offload and TX coalesce completion\n for P7\n - Marvell Octeon EP:\n - xmit-more support\n - add PF-VF mailbox support and use it for FW notifications\n for VFs\n - Wangxun (ngbe/txgbe):\n - implement ethtool functions to operate pause param', ' ring\n param', ' coalesce channel number and msglevel\n - Netronome/Corigine (nfp):\n - add flow-steering support\n - support UDP segmentation offload\n\n - Ethernet NICs embedded', ' slower', ' virtual:\n - Xilinx AXI: remove duplicate DMA code adopting the dma engine\n driver\n - stmmac: add support for HW-accelerated VLAN stripping\n - TI AM654x sw: add mqprio', ' frame preemption & coalescing\n - gve: add support for non-4k page sizes.\n - virtio-net: support dynamic coalescing moderation\n\n - nVidia/Mellanox Ethernet datacenter switches:\n - allow firmware upgrade without a reboot\n - more flexible support for bridge flooding via the compressed\n FID flooding mode\n\n - Ethernet embedded switches:\n - Microchip:\n - fine-tune flow control and speed configurations in KSZ8xxx\n - KSZ88X3: enable setting rmii reference\n - Renesas:\n - add jumbo frames support\n - Marvell:\n - 88E6xxx: add ""eth-mac"" and ""rmon"" stats support\n\n - Ethernet PHYs:\n - aquantia: add firmware load support\n - at803x: refactor the driver to simplify adding support for more\n chip variants\n - NXP C45 TJA11xx: Add MACsec offload support\n\n - Wifi:\n - MediaTek (mt76):\n - NVMEM EEPROM improvements\n - mt7996 Extremely High Throughput (EHT) improvements\n - mt7996 Wireless Ethernet Dispatcher (WED) support\n - mt7996 36-bit DMA support\n - Qualcomm (ath12k):\n - support for a single MSI vector\n - WCN7850: support AP mode\n - Intel (iwlwifi):\n - new debugfs file fw_dbg_clear\n - allow concurrent P2P operation on DFS channels\n\n - Bluetooth:\n - QCA2066: support HFP offload\n - ISO: more broadcast-related improvements\n - NXP: better recovery in case receiver/transmitter get out of sync""\n\n* tag \'net-next-6.8\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next: (1714 commits)\n lan78xx: remove redundant statement in lan78xx_get_eee\n lan743x: remove redundant statement in lan743x_ethtool_get_eee\n bnxt_en: Fix RCU locking for ntuple filters in bnxt_rx_flow_steer()\n bnxt_en: Fix RCU locking for ntuple filters in bnxt_srxclsrldel()\n bnxt_en: Remove unneeded variable in bnxt_hwrm_clear_vnic_filter()\n tcp: Revert no longer abort SYN_SENT when receiving some ICMP\n Revert ""mlx5 updates 2023-12-20""\n Revert ""net: stmmac: Enable Per DMA Channel interrupt""\n ipvlan: Remove usage of the deprecated ida_simple_xx() API\n ipvlan: Fix a typo in a comment\n net/sched: Remove ipt action tests\n net: stmmac: Use interrupt mode INTM=1 for per channel irq\n net: stmmac: Add support for TX/RX channel interrupt\n net: stmmac: Make MSI interrupt routine generic\n dt-bindings: net: snps', 'dwmac: per channel irq\n net: phy: at803x: make read_status more generic\n net: phy: at803x: add support for cdt cross short test for qca808x\n net: phy: at803x: refactor qca808x cable test get status function\n net: phy: at803x: generalize cdt fault length function\n net: ethernet: cortina: Drop TSO support\n ...\n', '']",Merge networking updates from Paolo Abeni including core structs reorganization and self-tests.,"networking, structs, reorganization",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +e3977e0609a07d86406029fceea0fd40d7849368,e3977e0609a07d86406029fceea0fd40d7849368,Tejun Heo,tj@kernel.org,1704836882,Greg Kroah-Hartman,gregkh@linuxfoundation.org,1704970287,f60922c1cf2e540d4b4647f14e1c3e076b2beeb2,c312828c37a72fe2d033a961c47c227b0767e9f8,"Revert ""kernfs: convert kernfs_idr_lock to an irq safe raw spinlock"" + +This reverts commit dad3fb67ca1cbef87ce700e83a55835e5921ce8a. + +The commit converted kernfs_idr_lock to an IRQ-safe raw_spinlock because it +could be acquired while holding an rq lock through bpf_cgroup_from_id(). +However"," kernfs_idr_lock is held while doing GPF_NOWAIT allocations which +involves acquiring an non-IRQ-safe and non-raw lock leading to the following +lockdep warning: + + ============================= + [ BUG: Invalid wait context ] + 6.7.0-rc5-kzm9g-00251-g655022a45b1c #578 Not tainted + ----------------------------- + swapper/0/0 is trying to lock: + dfbcd488 (&c->lock){....}-{3:3}","[' at: local_lock_acquire+0x0/0xa4\n other info that might help us debug this:\n context-{5:5}\n 2 locks held by swapper/0/0:\n #0: dfbc9c60 (lock){+.+.}-{3:3}', ' at: local_lock_acquire+0x0/0xa4\n #1: c0c012a8 (kernfs_idr_lock){....}-{2:2}', "" at: __kernfs_new_node.constprop.0+0x68/0x258\n stack backtrace:\n CPU: 0 PID: 0 Comm: swapper/0 Not tainted 6.7.0-rc5-kzm9g-00251-g655022a45b1c #578\n Hardware name: Generic SH73A0 (Flattened Device Tree)\n unwind_backtrace from show_stack+0x10/0x14\n show_stack from dump_stack_lvl+0x68/0x90\n dump_stack_lvl from __lock_acquire+0x3cc/0x168c\n __lock_acquire from lock_acquire+0x274/0x30c\n lock_acquire from local_lock_acquire+0x28/0xa4\n local_lock_acquire from ___slab_alloc+0x234/0x8a8\n ___slab_alloc from __slab_alloc.constprop.0+0x30/0x44\n __slab_alloc.constprop.0 from kmem_cache_alloc+0x7c/0x148\n kmem_cache_alloc from radix_tree_node_alloc.constprop.0+0x44/0xdc\n radix_tree_node_alloc.constprop.0 from idr_get_free+0x110/0x2b8\n idr_get_free from idr_alloc_u32+0x9c/0x108\n idr_alloc_u32 from idr_alloc_cyclic+0x50/0xb8\n idr_alloc_cyclic from __kernfs_new_node.constprop.0+0x88/0x258\n __kernfs_new_node.constprop.0 from kernfs_create_root+0xbc/0x154\n kernfs_create_root from sysfs_init+0x18/0x5c\n sysfs_init from mnt_init+0xc4/0x220\n mnt_init from vfs_caches_init+0x6c/0x88\n vfs_caches_init from start_kernel+0x474/0x528\n start_kernel from 0x0\n\nLet's rever the commit. It's undesirable to spread out raw spinlock usage\nanyway and the problem can be solved by protecting the lookup path with RCU\ninstead.\n\nSigned-off-by: Tejun Heo \nCc: Andrea Righi \nReported-by: Geert Uytterhoeven \nLink: http://lkml.kernel.org/r/CAMuHMdV=AKt+mwY7svEq5gFPx41LoSQZ_USME5_MEdWQze13ww@mail.gmail.com\nLink: https://lore.kernel.org/r/20240109214828.252092-2-tj@kernel.org\nTested-by: Andrea Righi \nSigned-off-by: Greg Kroah-Hartman \n"", '']",Revert the conversion of kernfs_idr_lock to an IRQ-safe raw spinlock due to lockdep warning issues.,"revert, spinlock, lockdep",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['cgroup like programs'] +8158a50f9058ce882a6a020c41cef6bae2c3eae3,8158a50f9058ce882a6a020c41cef6bae2c3eae3,Jakub Kicinski,kuba@kernel.org,1704510932,Jakub Kicinski,kuba@kernel.org,1704510932,7b0eef570ee9a02971813e074afa674a54e8e403,795fd9342c628839ac9c3f3133d063ce2e577ea7 5fe4ee6ae187523f710f1b93024437a073d88b17,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2024-01-05 + +We've added 40 non-merge commits during the last 2 day(s) which contain +a total of 73 files changed", 1526 insertions(+),"[' 951 deletions(-).\n\nThe main changes are:\n\n1) Fix a memory leak when streaming AF_UNIX sockets were inserted\n into multiple sockmap slots/maps', ' from John Fastabend.\n\n2) Fix gotol in s390 BPF JIT with large offsets', ' from Ilya Leoshkevich.\n\n3) Fix reattachment branch in bpf_tracing_prog_attach() and reject\n the request if there is no valid attach_btf', ' from Jiri Olsa.\n\n4) Remove deprecated bpfilter kernel leftovers given the project\n is developed in user space (https://github.com/facebook/bpfilter)', '\n from Quentin Deslandes.\n\n5) Relax tracing BPF program recursive attach rules given right now\n it is not possible to create tracing program call cycles', '\n from Dmitrii Dolgov.\n\n6) Fix excessive memory consumption for the bpf_global_percpu_ma\n for systems with a large number of CPUs', ' from Yonghong Song.\n\n7) Small x86 BPF JIT cleanup to reuse emit_nops instead of open-coding\n memcpy of x86_nops', ' from Leon Hwang.\n\n8) Follow-up for libbpf to support __arg_ctx global function argument tag\n semantics to complement the merged kernel side', ' from Andrii Nakryiko.\n\n9) Introduce ""volatile compare"" macros for BPF selftests in order\n to make the latter more robust against compiler optimization', ""\n from Alexei Starovoitov.\n\n10) Small simplification in verifier's size checking of helper accesses\n along with additional selftests"", "" from Andrei Matei.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (40 commits)\n selftests/bpf: Test re-attachment fix for bpf_tracing_prog_attach\n bpf: Fix re-attachment branch in bpf_tracing_prog_attach\n selftests/bpf: Add test for recursive attachment of tracing progs\n bpf: Relax tracing prog recursive attach rules\n bpf"", "" x86: Use emit_nops to replace memcpy x86_nops\n selftests/bpf: Test gotol with large offsets\n selftests/bpf: Double the size of test_loader log\n s390/bpf: Fix gotol with large offsets\n bpfilter: remove bpfilter\n bpf: Remove unnecessary cpu == 0 check in memalloc\n selftests/bpf: add __arg_ctx BTF rewrite test\n selftests/bpf: add arg:ctx cases to test_global_funcs tests\n libbpf: implement __arg_ctx fallback logic\n libbpf: move BTF loading step after relocation step\n libbpf: move exception callbacks assignment logic into relocation step\n libbpf: use stable map placeholder FDs\n libbpf: don't rely on map->fd as an indicator of map being created\n libbpf: use explicit map reuse flag to skip map creation steps\n libbpf: make uniform use of btf__fd() accessor inside libbpf\n selftests/bpf: Add a selftest with > 512-byte percpu allocation size\n ...\n====================\n\nLink: https://lore.kernel.org/r/20240105170105.21070-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n"", '']",Merged 'bpf-next' changes with 73 files affected and 1526 insertions.,"merge, bpf-next, changes",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5fe4ee6ae187523f710f1b93024437a073d88b17,5fe4ee6ae187523f710f1b93024437a073d88b17,Alexei Starovoitov,ast@kernel.org,1704429094,Alexei Starovoitov,ast@kernel.org,1704429654,0597b83407e92f101be92851c0b2e0eb5181b045,00bc8988807985e32f5103f1ac099baf593bd8a3 e02feb3f1f47509ec1e07b604bfbeff8c3b4e639,"Merge branch 'relax-tracing-prog-recursive-attach-rules' + +Dmitrii Dolgov says: + +==================== +Relax tracing prog recursive attach rules + +Currently"," it's not allowed to attach an fentry/fexit prog to another +fentry/fexit. At the same time it's not uncommon to see a tracing +program with lots of logic in use","[' and the attachment limitation\nprevents usage of fentry/fexit for performance analysis (e.g. with\n""bpftool prog profile"" command) in this case. An example could be\nfalcosecurity libs project that uses tp_btf tracing programs for\noffloading certain part of logic into tail-called programs', ' but the\nuse-case is still generic enough -- a tracing program could be\ncomplicated and heavy enough to warrant its profiling', "" yet frustratingly\nit's not possible to do so use best tooling for that.\n\nFollowing the corresponding discussion [1]"", ' the reason for that is to\navoid tracing progs call cycles without introducing more complex\nsolutions. But currently it seems impossible to load and attach tracing\nprograms in a way that will form such a cycle. Replace ""no same type""\nrequirement with verification that no more than one level of attachment\nnesting is allowed. In this way only one fentry/fexit program could be\nattached to another fentry/fexit to cover profiling use case', ' and still\nno cycle could be formed.\n\nThe series contains a test for recursive attachment', ' as well as a fix +\ntest for an issue in re-attachment branch of bpf_tracing_prog_attach.\nWhen preparing the test for the main change set', "" I've stumbled upon the\npossibility to construct a sequence of events when attach_btf would be\nNULL while computing a trampoline key. It doesn't look like this issue\nis triggered by the main change"", "" because the reproduces doesn't actually\nneed to have an fentry attachment chain.\n\n[1]: https://lore.kernel.org/bpf/20191108064039.2041889-16-ast@kernel.org/\n====================\n\nLink: https://lore.kernel.org/r/20240103190559.14750-1-9erthalion6@gmail.com\nSigned-off-by: Alexei Starovoitov \n"", '']",This commit relaxes the rules for recursively attaching fentry/fexit tracing programs.,tracing recursive rules,It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'kprobe/uprobe/ftrace like programs']" +e02feb3f1f47509ec1e07b604bfbeff8c3b4e639,e02feb3f1f47509ec1e07b604bfbeff8c3b4e639,Dmitrii Dolgov,9erthalion6@gmail.com,1704308747,Alexei Starovoitov,ast@kernel.org,1704429649,0597b83407e92f101be92851c0b2e0eb5181b045,715d82ba636cb3629a6e18a33bb9dbe53f9936ee,"selftests/bpf: Test re-attachment fix for bpf_tracing_prog_attach + +Add a test case to verify the fix for ""prog->aux->dst_trampoline and +tgt_prog is NULL"" branch in bpf_tracing_prog_attach. The sequence of +events: + +1. load rawtp program +2. load fentry program with rawtp as target_fd +3. create tracing link for fentry program with target_fd = 0 +4. repeat 3 + +Acked-by: Jiri Olsa +Acked-by: Song Liu +Signed-off-by: Dmitrii Dolgov <9erthalion6@gmail.com> +Link: https://lore.kernel.org/r/20240103190559.14750-5-9erthalion6@gmail.com +Signed-off-by: Alexei Starovoitov +",,Add a test case to verify the fix for re-attachment in bpf_tracing_prog_attach.,"test case, re-attachment, bpf_tracing_prog_attach",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs']" +715d82ba636cb3629a6e18a33bb9dbe53f9936ee,715d82ba636cb3629a6e18a33bb9dbe53f9936ee,Jiri Olsa,olsajiri@gmail.com,1704308746,Alexei Starovoitov,ast@kernel.org,1704429619,c164ed8ec5abb70af2adb3809e49542232ba26c6,5c5371e069e1ffc204dda8b20c609b170b823165,"bpf: Fix re-attachment branch in bpf_tracing_prog_attach + +The following case can cause a crash due to missing attach_btf: + +1) load rawtp program +2) load fentry program with rawtp as target_fd +3) create tracing link for fentry program with target_fd = 0 +4) repeat 3 + +In the end we have: + +- prog->aux->dst_trampoline == NULL +- tgt_prog == NULL (because we did not provide target_fd to link_create) +- prog->aux->attach_btf == NULL (the program was loaded with attach_prog_fd=X) +- the program was loaded for tgt_prog but we have no way to find out which one + + BUG: kernel NULL pointer dereference"," address: 0000000000000058 + Call Trace: + + ? __die+0x20/0x70 + ? page_fault_oops+0x15b/0x430 + ? fixup_exception+0x22/0x330 + ? exc_page_fault+0x6f/0x170 + ? asm_exc_page_fault+0x22/0x30 + ? bpf_tracing_prog_attach+0x279/0x560 + ? btf_obj_id+0x5/0x10 + bpf_tracing_prog_attach+0x439/0x560 + __sys_bpf+0x1cf4/0x2de0 + __x64_sys_bpf+0x1c/0x30 + do_syscall_64+0x41/0xf0 + entry_SYSCALL_64_after_hwframe+0x6e/0x76 + +Return -EINVAL in this situation. + +Fixes: f3a95075549e0 (""bpf: Allow trampoline re-attach for tracing and lsm programs"") +Cc: stable@vger.kernel.org +Signed-off-by: Jiri Olsa +Acked-by: Jiri Olsa +Acked-by: Song Liu +Signed-off-by: Dmitrii Dolgov <9erthalion6@gmail.com> +Link: https://lore.kernel.org/r/20240103190559.14750-4-9erthalion6@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Fix crash due to missing attach_btf in bpf_tracing_prog_attach when re-attaching fentry programs.,"crash, attach_btf, bpf_tracing",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'kprobe/uprobe/ftrace like programs']" +5c5371e069e1ffc204dda8b20c609b170b823165,5c5371e069e1ffc204dda8b20c609b170b823165,Dmitrii Dolgov,9erthalion6@gmail.com,1704308745,Alexei Starovoitov,ast@kernel.org,1704429614,9c069886df0b11d18f024da451c384615b2f1200,19bfcdf9498aa968ea293417fbbc39e523527ca8,"selftests/bpf: Add test for recursive attachment of tracing progs + +Verify the fact that only one fentry prog could be attached to another +fentry"," building up an attachment chain of limited size. Use existing +bpf_testmod as a start of the chain. + +Acked-by: Jiri Olsa +Acked-by: Song Liu +Signed-off-by: Dmitrii Dolgov <9erthalion6@gmail.com> +Link: https://lore.kernel.org/r/20240103190559.14750-3-9erthalion6@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Added a test case for recursive attachment of tracing programs in eBPF selftests.,"selftests,bpf,tracing",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tracepoints like programs'] +19bfcdf9498aa968ea293417fbbc39e523527ca8,19bfcdf9498aa968ea293417fbbc39e523527ca8,Dmitrii Dolgov,9erthalion6@gmail.com,1704308744,Alexei Starovoitov,ast@kernel.org,1704429094,b6f41738ec49d90299a77b1eab8fea793cf04dfd,00bc8988807985e32f5103f1ac099baf593bd8a3,"bpf: Relax tracing prog recursive attach rules + +Currently"," it's not allowed to attach an fentry/fexit prog to another +one fentry/fexit. At the same time it's not uncommon to see a tracing +program with lots of logic in use","[' and the attachment limitation\nprevents usage of fentry/fexit for performance analysis (e.g. with\n""bpftool prog profile"" command) in this case. An example could be\nfalcosecurity libs project that uses tp_btf tracing programs.\n\nFollowing the corresponding discussion [1]', ' the reason for that is to\navoid tracing progs call cycles without introducing more complex\nsolutions. But currently it seems impossible to load and attach tracing\nprograms in a way that will form such a cycle. The limitation is coming\nfrom the fact that attach_prog_fd is specified at the prog load (thus\nmaking it impossible to attach to a program loaded after it in this\nway)', ' as well as tracing progs not implementing link_detach.\n\nReplace ""no same type"" requirement with verification that no more than\none level of attachment nesting is allowed. In this way only one\nfentry/fexit program could be attached to another fentry/fexit to cover\nprofiling use case', ' and still no cycle could be formed. To implement', '\nadd a new field into bpf_prog_aux to track nested attachment for tracing\nprograms.\n\n[1]: https://lore.kernel.org/bpf/20191108064039.2041889-16-ast@kernel.org/\n\nAcked-by: Jiri Olsa \nAcked-by: Song Liu \nSigned-off-by: Dmitrii Dolgov <9erthalion6@gmail.com>\nLink: https://lore.kernel.org/r/20240103190559.14750-2-9erthalion6@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit relaxes restrictions on attaching tracing programs like fentry/fexit to allow recursive attachment.,"tracing, recursive, attach",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +00bc8988807985e32f5103f1ac099baf593bd8a3,00bc8988807985e32f5103f1ac099baf593bd8a3,Leon Hwang,hffilwlqm@gmail.com,1704378143,Alexei Starovoitov,ast@kernel.org,1704428530,d649b54630cb71b10e84e48ebb281a36a0253ac0,61a40c12496a763fdb95edc08d59f816a594a87a,bpf," x86: Use emit_nops to replace memcpy x86_nops + +Move emit_nops() before emit_prologue() and replace +memcpy(prog","[' x86_nops[5]', ' X86_PATCH_SIZE) with emit_nops(&prog', ' X86_PATCH_SIZE).\n\nSigned-off-by: Leon Hwang \nLink: https://lore.kernel.org/r/20240104142226.87869-2-hffilwlqm@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Optimize x86 nop insertion by moving emit_nops() before emit_prologue() and replacing memcpy usage.,"x86,emit_nops,optimization",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +61a40c12496a763fdb95edc08d59f816a594a87a,61a40c12496a763fdb95edc08d59f816a594a87a,Alexei Starovoitov,ast@kernel.org,1704396940,Alexei Starovoitov,ast@kernel.org,1704407845,7269325aad0d4d47fab766b3f8dcfc07cfa8f0a5,98e20e5e13d2811898921f999288be7151a11954 63fac34669e4cc666f943173ed2aa76b8db999f0,"Merge branch 's390-bpf-fix-gotol-with-large-offsets' + +Ilya Leoshkevich says: + +==================== +s390/bpf: Fix gotol with large offsets + +Hi"," + +While looking at a pyperf180 failure on s390x (must be related to [1]","[""\nI'm not done with the investigation yet) I noticed that I have\nunfortunately messed up the gotol implementation. Patch 1 is the fix"", '\npatch 2 is a small test infrastructure tweak', ' and patch 3 adds a\ntest.\n\n[1] https://github.com/llvm/llvm-project/issues/55669\n\nBest regards', '\nIlya\n====================\n\nLink: https://lore.kernel.org/r/20240102193531.3169422-1-iii@linux.ibm.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix for BPF gotol instruction handling on s390 architecture with large offsets.,"s390,bpf,gotol",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +63fac34669e4cc666f943173ed2aa76b8db999f0,63fac34669e4cc666f943173ed2aa76b8db999f0,Ilya Leoshkevich,iii@linux.ibm.com,1704223837,Alexei Starovoitov,ast@kernel.org,1704407845,7269325aad0d4d47fab766b3f8dcfc07cfa8f0a5,445aea5afda4759c13dc5c492b309cc1d5c1c486,"selftests/bpf: Test gotol with large offsets + +Test gotol with offsets that don't fit into a short (i.e."," larger than +32k or smaller than -32k). + +Signed-off-by: Ilya Leoshkevich +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240102193531.3169422-4-iii@linux.ibm.com +Signed-off-by: Alexei Starovoitov +",[''],This commit adds tests for gotol instruction with large offsets exceeding 32k in BPF selftests.,"gotol, offsets, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +445aea5afda4759c13dc5c492b309cc1d5c1c486,445aea5afda4759c13dc5c492b309cc1d5c1c486,Ilya Leoshkevich,iii@linux.ibm.com,1704223836,Alexei Starovoitov,ast@kernel.org,1704407735,a8eaf31cb3a84b7da0454d32837dec0775d18645,ecba66cb36e3428e9f0c2362b45e213ad43ba8d0,"selftests/bpf: Double the size of test_loader log + +Testing long jumps requires having >32k instructions. That many +instructions require the verifier log buffer of 2 megabytes. + +The regular test_progs run doesn't need an increased buffer"," since +gotol test with 40k instructions doesn't request a log","['\nbut test_progs -v will set the verifier log level.\nHence to avoid breaking gotol test with -v increase the buffer size.\n\nSigned-off-by: Ilya Leoshkevich \nAcked-by: Yonghong Song \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/r/20240102193531.3169422-3-iii@linux.ibm.com\nSigned-off-by: Alexei Starovoitov \n', '']",Increase the test_loader log size for selftests involving >32k instructions.,selftests log size,It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ecba66cb36e3428e9f0c2362b45e213ad43ba8d0,ecba66cb36e3428e9f0c2362b45e213ad43ba8d0,Ilya Leoshkevich,iii@linux.ibm.com,1704223835,Alexei Starovoitov,ast@kernel.org,1704396940,27f069acb175e293df7874bfd48b73011ca38a3f,98e20e5e13d2811898921f999288be7151a11954,"s390/bpf: Fix gotol with large offsets + +The gotol implementation uses a wrong data type for the offset: it +should be s32"," not s16. + +Fixes: c690191e23d8 (""s390/bpf: Implement unconditional jump with 32-bit offset"") +Signed-off-by: Ilya Leoshkevich +Acked-by: Yonghong Song +Acked-by: John Fastabend +Link: https://lore.kernel.org/r/20240102193531.3169422-2-iii@linux.ibm.com +Signed-off-by: Alexei Starovoitov +",[''],The commit fixes the offset data type for gotol implementation in s390 architecture of BPF.,"gotol,offset,s390",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +98e20e5e13d2811898921f999288be7151a11954,98e20e5e13d2811898921f999288be7151a11954,Quentin Deslandes,qde@naccy.de,1703596062,Alexei Starovoitov,ast@kernel.org,1704392590,194da196f85df00ebcc907347627265ea1fa2d72,9ddf872b47e3ac8f27dbfc4a4737a976c7588de6,"bpfilter: remove bpfilter + +bpfilter was supposed to convert iptables filtering rules into +BPF programs on the fly", from the kernel,"[' through a usermode\nhelper. The base code for the UMH was introduced in 2018', ' and\ncouple of attempts (2', ' 3) tried to introduce the BPF program\ngenerate features but were abandoned.\n\nbpfilter now sits in a kernel tree unused and unusable', ' occasionally\ncausing confusion amongst Linux users (4', ' 5).\n\nAs bpfilter is now developed in a dedicated repository on GitHub (6)', '\nit was suggested a couple of times this year (LSFMM/BPF 2023', '\nLPC 2023) to remove the deprecated kernel part of the project. This\nis the purpose of this patch.\n\n[1]: https://lore.kernel.org/lkml/20180522022230.2492505-1-ast@kernel.org/\n[2]: https://lore.kernel.org/bpf/20210829183608.2297877-1-me@ubique.spb.ru/#t\n[3]: https://lore.kernel.org/lkml/20221224000402.476079-1-qde@naccy.de/\n[4]: https://dxuuu.xyz/bpfilter.html\n[5]: https://github.com/linuxkit/linuxkit/pull/3904\n[6]: https://github.com/facebook/bpfilter\n\nSigned-off-by: Quentin Deslandes \nLink: https://lore.kernel.org/r/20231226130745.465988-1-qde@naccy.de\nSigned-off-by: Alexei Starovoitov \n', '']",Remove bpfilter module responsible for converting iptables rules into BPF programs.,"bpfilter, iptables, removal",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tc/netfilter like programs'] +9ddf872b47e3ac8f27dbfc4a4737a976c7588de6,9ddf872b47e3ac8f27dbfc4a4737a976c7588de6,Yonghong Song,yonghong.song@linux.dev,1704387464,Alexei Starovoitov,ast@kernel.org,1704392294,3cbc51ba9cbb22d6bcb1deb127146fadf31c260e,c040e902b07e946ff73e81d4abb4347d2c0b6044,"bpf: Remove unnecessary cpu == 0 check in memalloc + +After merging the patch set [1] to reduce memory usage +for bpf_global_percpu_ma"," Alexei found a redundant check (cpu == 0) +in function bpf_mem_alloc_percpu_unit_init() ([2]). +Indeed","[' the check is unnecessary since c->unit_size will\nbe all NULL or all non-NULL for all cpus before\nfor_each_possible_cpu() loop.\nRemoving the check makes code less confusing.\n\n [1] https://lore.kernel.org/all/20231222031729.1287957-1-yonghong.song@linux.dev/\n [2] https://lore.kernel.org/all/20231222031745.1289082-1-yonghong.song@linux.dev/\n\nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20240104165744.702239-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Removed an unnecessary cpu check in bpf_mem_alloc_percpu_unit_init function.,"cpu, check, memalloc",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c312828c37a72fe2d033a961c47c227b0767e9f8,c312828c37a72fe2d033a961c47c227b0767e9f8,Andrea Righi,andrea.righi@canonical.com,1703836156,Greg Kroah-Hartman,gregkh@linuxfoundation.org,1704384795,7fd234070dac3a103b59bab0b39e5ed709a418e8,93ec4a3b76404bce01bd5c9032bef5df6feb1d62,"kernfs: convert kernfs_idr_lock to an irq safe raw spinlock + +bpf_cgroup_from_id() is basically a wrapper to cgroup_get_from_id()"," +that is relying on kernfs to determine the right cgroup associated to +the target id. + +As a kfunc","[' it has the potential to be attached to any function through\nBPF', ' particularly in contexts where certain locks are held.\n\nHowever', ' kernfs is not using an irq safe spinlock for kernfs_idr_lock', '\nthat means any kernfs function that is acquiring this lock can be\ninterrupted and potentially hit bpf_cgroup_from_id() in the process', '\ntriggering a deadlock.\n\nFor example', ' it is really easy to trigger a lockdep splat between\nkernfs_idr_lock and rq->_lock', ' attaching a small BPF program to\n__set_cpus_allowed_ptr_locked() that just calls bpf_cgroup_from_id():\n\n =====================================================\n WARNING: HARDIRQ-safe -> HARDIRQ-unsafe lock order detected\n 6.7.0-rc7-virtme #5 Not tainted\n -----------------------------------------------------\n repro/131 [HC0[0]:SC0[0]:HE0:SE1] is trying to acquire:\n ffffffffb2dc4578 (kernfs_idr_lock){+.+.}-{2:2}', ' at: kernfs_find_and_get_node_by_id+0x1d/0x80\n\n and this task is already holding:\n ffff911cbecaf218 (&rq->__lock){-.-.}-{2:2}', ' at: task_rq_lock+0x50/0xc0\n which would create a new lock dependency:\n (&rq->__lock){-.-.}-{2:2} -> (kernfs_idr_lock){+.+.}-{2:2}\n\n but this new dependency connects a HARDIRQ-irq-safe lock:\n (&rq->__lock){-.-.}-{2:2}\n\n ... which became HARDIRQ-irq-safe at:\n lock_acquire+0xbf/0x2b0\n _raw_spin_lock_nested+0x2e/0x40\n scheduler_tick+0x5d/0x170\n update_process_times+0x9c/0xb0\n tick_periodic+0x27/0xe0\n tick_handle_periodic+0x24/0x70\n __sysvec_apic_timer_interrupt+0x64/0x1a0\n sysvec_apic_timer_interrupt+0x6f/0x80\n asm_sysvec_apic_timer_interrupt+0x1a/0x20\n memcpy+0xc/0x20\n arch_dup_task_struct+0x15/0x30\n copy_process+0x1ce/0x1eb0\n kernel_clone+0xac/0x390\n kernel_thread+0x6f/0xa0\n kthreadd+0x199/0x230\n ret_from_fork+0x31/0x50\n ret_from_fork_asm+0x1b/0x30\n\n to a HARDIRQ-irq-unsafe lock:\n (kernfs_idr_lock){+.+.}-{2:2}\n\n ... which became HARDIRQ-irq-unsafe at:\n ...\n lock_acquire+0xbf/0x2b0\n _raw_spin_lock+0x30/0x40\n __kernfs_new_node.isra.0+0x83/0x280\n kernfs_create_root+0xf6/0x1d0\n sysfs_init+0x1b/0x70\n mnt_init+0xd9/0x2a0\n vfs_caches_init+0xcf/0xe0\n start_kernel+0x58a/0x6a0\n x86_64_start_reservations+0x18/0x30\n x86_64_start_kernel+0xc5/0xe0\n secondary_startup_64_no_verify+0x178/0x17b\n\n other info that might help us debug this:\n\n Possible interrupt unsafe locking scenario:\n\n CPU0 CPU1\n ---- ----\n lock(kernfs_idr_lock);\n local_irq_disable();\n lock(&rq->__lock);\n lock(kernfs_idr_lock);\n \n lock(&rq->__lock);\n\n *** DEADLOCK ***\n\nPrevent this deadlock condition converting kernfs_idr_lock to a raw irq\nsafe spinlock.\n\nThe performance impact of this change should be negligible and it also\nhelps to prevent similar deadlock conditions with any other subsystems\nthat may depend on kernfs.\n\nFixes: 332ea1f697be (""bpf: Add bpf_cgroup_from_id() kfunc"")\nCc: stable \nSigned-off-by: Andrea Righi \nAcked-by: Tejun Heo \nLink: https://lore.kernel.org/r/20231229074916.53547-1-andrea.righi@canonical.com\nSigned-off-by: Greg Kroah-Hartman \n', '']",Convert kernfs_idr_lock to irq safe raw spinlock for bpf_cgroup_from_id function.,"kernfs, irq, spinlock",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['cgroup like programs'] +c040e902b07e946ff73e81d4abb4347d2c0b6044,c040e902b07e946ff73e81d4abb4347d2c0b6044,Alexei Starovoitov,ast@kernel.org,1704345770,Alexei Starovoitov,ast@kernel.org,1704346689,60b32e18321347e5c34c7cf03ac24aa8d3650b68,f8506c5734902ebda5c7b4778859b46d0a2ae5f3 95226f5a36695fd5740e130016d9ed697cfb2bad,"Merge branch 'libbpf-side-__arg_ctx-fallback-support' + +Andrii Nakryiko says: + +==================== +Libbpf-side __arg_ctx fallback support + +Support __arg_ctx global function argument tag semantics even on older kernels +that don't natively support it through btf_decl_tag(""arg:ctx""). + +Patches #2-#6 are preparatory work to allow to postpone BTF loading into the +kernel until after all the BPF program relocations (including global func +appending to main programs) are done. Patch #4 is perhaps the most important +and establishes pre-created stable placeholder FDs"," so that relocations can +embed valid map FDs into ldimm64 instructions. + +Once BTF is done after relocation","["" what's left is to adjust BTF information to\nhave each main program's copy of each used global subprog to point to its own\nadjusted FUNC -> FUNC_PROTO type chain (if they use __arg_ctx) in such a way\nas to satisfy type expectations of BPF verifier regarding the PTR_TO_CTX\nargument definition. See patch #8 for details.\n\nPatch #8 adds few more __arg_ctx use cases (edge cases like multiple arguments\nhaving __arg_ctx"", ' etc) to test_global_func_ctx_args.c', ' to make it simple to\nvalidate that this logic indeed works on old kernels. It does. But just to be\n100% sure patch #9 adds a test validating that libbpf uploads func_info with\nproperly modified BTF data.\n\nv2->v3:\n - drop renaming patch (Alexei', ' Eduard);\n - use memfd_create() instead of /dev/null for placeholder FD (Eduard);\n - add one more test for validating BTF rewrite logic (Eduard);\n - fixed wrong -errno usage', ' reshuffled some BTF rewrite bits (Eduard);\nv1->v2:\n - do internal functions renaming in patch #1 (Alexei);\n - extract cloning of FUNC -> FUNC_PROTO information into separate function\n (Alexei);\n====================\n\nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20240104013847.3875810-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit merges support for __arg_ctx fallback in libbpf to older kernels without native support.,"libbpf, __arg_ctx, BTF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +95226f5a36695fd5740e130016d9ed697cfb2bad,95226f5a36695fd5740e130016d9ed697cfb2bad,Andrii Nakryiko,andrii@kernel.org,1704332327,Alexei Starovoitov,ast@kernel.org,1704345769,60b32e18321347e5c34c7cf03ac24aa8d3650b68,67fe459144dd629855bd9fb4b12bd9c4f792a8cf,"selftests/bpf: add __arg_ctx BTF rewrite test + +Add a test validating that libbpf uploads BTF and func_info with +rewritten type information for arguments of global subprogs that are +marked with __arg_ctx tag. + +Suggested-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240104013847.3875810-10-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add a selftest to validate BTF and func_info type rewriting for global subprograms with __arg_ctx tag.,"selftests,bpf,BTF",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +67fe459144dd629855bd9fb4b12bd9c4f792a8cf,67fe459144dd629855bd9fb4b12bd9c4f792a8cf,Andrii Nakryiko,andrii@kernel.org,1704332326,Alexei Starovoitov,ast@kernel.org,1704345769,2b5cc2eb9763c03f430888445f6bdc77f113e349,2f38fe689470055440bf80fc644920023a643a82,"selftests/bpf: add arg:ctx cases to test_global_funcs tests + +Add a few extra cases of global funcs with context arguments. This time +rely on ""arg:ctx"" decl_tag (__arg_ctx macro)"," but put it next to +""classic"" cases where context argument has to be of an exact type that +BPF verifier expects (e.g.","[' bpf_user_pt_regs_t for kprobe/uprobe).\n\nColocating all these cases separately from other global func args that\nrely on arg:xxx decl tags (in verifier_global_subprogs.c) allows for\nsimpler backwards compatibility testing on old kernels. All the cases in\ntest_global_func_ctx_args.c are supposed to work on older kernels', ' which\nwas manually validated during development.\n\nAcked-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240104013847.3875810-9-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']","Add test cases for global functions with context arguments using ""arg:ctx"" macro in BPF selftests.","test cases, global funcs, context arguments",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2f38fe689470055440bf80fc644920023a643a82,2f38fe689470055440bf80fc644920023a643a82,Andrii Nakryiko,andrii@kernel.org,1704332325,Alexei Starovoitov,ast@kernel.org,1704345769,01d770885ccc081748e36076f3b70b868d5e5632,1004742d7ff03a088e74133af2401556ac80092b,"libbpf: implement __arg_ctx fallback logic + +Out of all special global func arg tag annotations"," __arg_ctx is +practically is the most immediately useful and most critical to have +working across multitude kernel version","[' if possible. This would allow\nend users to write much simpler code if __arg_ctx semantics worked for\nolder kernels that don\'t natively understand btf_decl_tag(""arg:ctx"") in\nverifier logic.\n\nLuckily', ' it is possible to ensure __arg_ctx works on old kernels through\na bit of extra work done by libbpf', ' at least in a lot of common cases.\n\nTo explain the overall idea', ' we need to go back at how context argument\nwas supported in global funcs before __arg_ctx support was added. This\nwas done based on special struct name checks in kernel. E.g.', ' for\nBPF_PROG_TYPE_PERF_EVENT the expectation is that argument type `struct\nbpf_perf_event_data *` mark that argument as PTR_TO_CTX. This is all\ngood as long as global function is used from the same BPF program types\nonly', ' which is often not the case. If the same subprog has to be called\nfrom', ' say', ' kprobe and perf_event program types', ' there is no single\ndefinition that would satisfy BPF verifier. Subprog will have context\nargument either for kprobe (if using bpf_user_pt_regs_t struct name) or\nperf_event (with bpf_perf_event_data struct name)', ' but not both.\n\nThis limitation was the reason to add btf_decl_tag(""arg:ctx"")', ' making\nthe actual argument type not important', ' so that user can just define\n""generic"" signature:\n\n __noinline int global_subprog(void *ctx __arg_ctx) { ... }\n\nI won\'t belabor how libbpf is implementing subprograms', "" see a huge\ncomment next to bpf_object_relocate_calls() function. The idea is that\neach main/entry BPF program gets its own copy of global_subprog's code\nappended.\n\nThis per-program copy of global subprog code *and* associated func_info\n.BTF.ext information"", ' pointing to FUNC -> FUNC_PROTO BTF type chain\nallows libbpf to simulate __arg_ctx behavior transparently', "" even if the\nkernel doesn't yet support __arg_ctx annotation natively.\n\nThe idea is straightforward: each time we append global subprog's code\nand func_info information"", ' we adjust its FUNC -> FUNC_PROTO type\ninformation', ' if necessary (that is', ' libbpf can detect the presence of\nbtf_decl_tag(""arg:ctx"") just like BPF verifier would do it).\n\nThe rest is just mechanical and somewhat painful BTF manipulation code.\nIt\'s painful because we need to clone FUNC -> FUNC_PROTO', ' instead of\nreusing it', ' as same FUNC -> FUNC_PROTO chain might be used by another\nmain BPF program within the same BPF object', "" so we can't just modify it\nin-place (and cloning BTF types within the same struct btf object is\npainful due to constant memory invalidation"", "" see comments in code).\nUploaded BPF object's BTF information has to work for all BPF\nprograms at the same time.\n\nOnce we have FUNC -> FUNC_PROTO clones"", ' we make sure that instead of\nusing some `void *ctx` parameter definition', ' we have an expected `struct\nbpf_perf_event_data *ctx` definition (as far as BPF verifier and kernel\nis concerned)', "" which will mark it as context for BPF verifier. Same\nglobal subprog relocated and copied into another main BPF program will\nget different type information according to main program's type. It all\nworks out in the end in a completely transparent way for end user.\n\nLibbpf maintains internal program type -> expected context struct name\nmapping internally. Note"", ' not all BPF program types have named context\nstruct', "" so this approach won't work for such programs (just like it\ndidn't before __arg_ctx). So native __arg_ctx is still important to have\nin kernel to have generic context support across all BPF program types.\n\nAcked-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240104013847.3875810-8-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",Implement __arg_ctx fallback logic in libbpf to ensure compatibility across various kernel versions.,"libbpf, __arg_ctx, fallback",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1004742d7ff03a088e74133af2401556ac80092b,1004742d7ff03a088e74133af2401556ac80092b,Andrii Nakryiko,andrii@kernel.org,1704332324,Alexei Starovoitov,ast@kernel.org,1704345769,5d133fc7e5e29a75f513ad0169f2ec7ff9743561,fb03be7c4a27c25696287df4ee06c5aafa31267c,"libbpf: move BTF loading step after relocation step + +With all the preparations in previous patches done we are ready to +postpone BTF loading and sanitization step until after all the +relocations are performed. + +Acked-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240104013847.3875810-7-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Postpone BTF loading until after relocations in libbpf.,"BTF,relocation,libbpf",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fb03be7c4a27c25696287df4ee06c5aafa31267c,fb03be7c4a27c25696287df4ee06c5aafa31267c,Andrii Nakryiko,andrii@kernel.org,1704332323,Alexei Starovoitov,ast@kernel.org,1704345769,11cfbb2f44610b9064a7ae73502d571642bbf3b9,dac645b950ea4fc0896fe46a645365cb8d9ab92b,"libbpf: move exception callbacks assignment logic into relocation step + +Move the logic of finding and assigning exception callback indices from +BTF sanitization step to program relocations step"," which seems more +logical and will unblock moving BTF loading to after relocation step. + +Exception callbacks discovery and assignment has no dependency on BTF +being loaded into the kernel","[' it only uses BTF information. It does need\nto happen before subprogram relocations happen', ' though. Which is why the\nsplit.\n\nNo functional changes.\n\nAcked-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240104013847.3875810-6-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Refactor the exception callbacks assignment logic from BTF sanitization to program relocations step in libbpf.,"libbpf, exception callbacks, relocation",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dac645b950ea4fc0896fe46a645365cb8d9ab92b,dac645b950ea4fc0896fe46a645365cb8d9ab92b,Andrii Nakryiko,andrii@kernel.org,1704332322,Alexei Starovoitov,ast@kernel.org,1704345769,246b69d04cdbeaa2b277cfb0ecb855e61a13a847,f08c18e083adfef92946ae1d44b07bb81e727e08,"libbpf: use stable map placeholder FDs + +Move map creation to later during BPF object loading by pre-creating +stable placeholder FDs (utilizing memfd_create()). Use dup2() +syscall to then atomically make those placeholder FDs point to real +kernel BPF map objects. + +This change allows to delay BPF map creation to after all the BPF +program relocations. That", in turn,"["" allows to delay BTF finalization and\nloading into kernel to after all the relocations as well. We'll take\nadvantage of the latter in subsequent patches to allow libbpf to adjust\nBTF in a way that helps with BPF global function usage.\n\nClean up a few places where we close map->fd"", "" which now shouldn't\nhappen"", "" because map->fd should be a valid FD regardless of whether map\nwas created or not. Surprisingly and nicely it simplifies a bunch of\nerror handling code. If this change doesn't backfire"", "" I'm tempted to\npre-create such stable FDs for other entities (progs"", ' maybe even BTF).\nWe previously did some manipulations to make gen_loader work with fake\nmap FDs', ' with stable map FDs this hack is not necessary for maps (we\nstill have it for BTF', ' but I left it as is for now).\n\nAcked-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240104013847.3875810-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit introduces stable map placeholder FDs for delayed BPF map creation in libbpf.,"libbpf,placeholder FDs,map creation",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f08c18e083adfef92946ae1d44b07bb81e727e08,f08c18e083adfef92946ae1d44b07bb81e727e08,Andrii Nakryiko,andrii@kernel.org,1704332321,Alexei Starovoitov,ast@kernel.org,1704345769,7b16972d9d1a08dfd503e61129548f672cce1846,fa98b54bff39f51c46fc96d3385c6292391c277b,"libbpf: don't rely on map->fd as an indicator of map being created + +With the upcoming switch to preallocated placeholder FDs for maps"," +switch various getters/setter away from checking map->fd. Use +map_is_created() helper that detect whether BPF map can be modified based +on map->obj->loaded state","[' with special provision for maps set up with\nbpf_map__reuse_fd().\n\nFor backwards compatibility', ' we take map_is_created() into account in\nbpf_map__fd() getter as well. This way before bpf_object__load() phase\nbpf_map__fd() will always return -1', ' just as before the changes in\nsubsequent patches adding stable map->fd placeholders.\n\nWe also get rid of all internal uses of bpf_map__fd() getter', "" as it's\nmore oriented for uses external to libbpf. The above map_is_created()\ncheck actually interferes with some of the internal uses"", ' if map FD is\nfetched through bpf_map__fd().\n\nAcked-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20240104013847.3875810-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Switch libbpf to use map_is_created() instead of map->fd to detect map modification eligibility.,"libbpf,map,fd",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fa98b54bff39f51c46fc96d3385c6292391c277b,fa98b54bff39f51c46fc96d3385c6292391c277b,Andrii Nakryiko,andrii@kernel.org,1704332320,Alexei Starovoitov,ast@kernel.org,1704345769,e044d275ee39e66f4c4724a3f92476a08326082f,df7c3f7d3a3ddab31ca8cfa9b86a8729ec43fd2e,"libbpf: use explicit map reuse flag to skip map creation steps + +Instead of inferring whether map already point to previously +created/pinned BPF map (which user can specify with bpf_map__reuse_fd()) API)"," +use explicit map->reused flag that is set in such case. + +Acked-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240104013847.3875810-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],The commit introduces an explicit map reuse flag to simplify map creation in libbpf.,"explicit,map,reuse",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +df7c3f7d3a3ddab31ca8cfa9b86a8729ec43fd2e,df7c3f7d3a3ddab31ca8cfa9b86a8729ec43fd2e,Andrii Nakryiko,andrii@kernel.org,1704332319,Alexei Starovoitov,ast@kernel.org,1704345768,2384aefbdffa70db6527877f102e6aac2c7a5a4a,f8506c5734902ebda5c7b4778859b46d0a2ae5f3,"libbpf: make uniform use of btf__fd() accessor inside libbpf + +It makes future grepping and code analysis a bit easier. + +Acked-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20240104013847.3875810-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Standardize the use of btf__fd() accessor in libbpf for easier code maintenance.,"libbpf, btf__fd, accessor",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f8506c5734902ebda5c7b4778859b46d0a2ae5f3,f8506c5734902ebda5c7b4778859b46d0a2ae5f3,Alexei Starovoitov,ast@kernel.org,1704344906,Alexei Starovoitov,ast@kernel.org,1704344907,33e7bd54cb6f7ee386fa8abca5ab0ae9cea74d64,417fa6d163df6f13fb2cfad5132eff354c8a472e adc8c4549d9e74d2359c217d2478b18ecdd15c91,"Merge branch 'bpf-reduce-memory-usage-for-bpf_global_percpu_ma' + +Yonghong Song says: + +==================== +bpf: Reduce memory usage for bpf_global_percpu_ma + +Currently when a bpf program intends to allocate memory for percpu kptr"," +the verifier will call bpf_mem_alloc_init() to prefill all supported +unit sizes and this caused memory consumption very big for large number +of cpus. For example","[' for 128-cpu system', ' the total memory consumption\nwith initial prefill is ~175MB. Things will become worse for systems\nwith even more cpus.\n\nPatch 1 avoids unnecessary extra percpu memory allocation.\nPatch 2 adds objcg to bpf_mem_alloc at init stage so objcg can be\nassociated with root cgroup and objcg can be passed to later\nbpf_mem_alloc_percpu_unit_init().\nPatch 3 addresses memory consumption issue by avoiding to prefill\nwith all unit sizes', ' i.e. only prefilling with user specified size.\nPatch 4 further reduces memory consumption by limiting the\nnumber of prefill entries for percpu memory allocation.\nPatch 5 has much smaller low/high watermarks for percpu allocation\nto reduce memory consumption.\nPatch 6 rejects percpu memory allocation with bpf_global_percpu_ma\nwhen allocation size is greater than 512 bytes.\nPatch 7 fixed test_bpf_ma test due to Patch 5.\nPatch 8 added one test to show the verification failure log message.\n\nChangelogs:\n v5 -> v6:\n . Change bpf_mem_alloc_percpu_init() to add objcg as one of parameters.\n For bpf_global_percpu_ma', ' the objcg is NULL', ' corresponding root memcg.\n v4 -> v5:\n . Do not do bpf_global_percpu_ma initialization at init stage', "" instead\n doing initialization when the verifier knows it is going to be used\n by bpf prog.\n . Using much smaller low/high watermarks for percpu allocation.\n v3 -> v4:\n . Add objcg to bpf_mem_alloc during init stage.\n . Initialize objcg at init stage but use it in bpf_mem_alloc_percpu_unit_init().\n . Remove check_obj_size() in bpf_mem_alloc_percpu_unit_init().\n v2 -> v3:\n . Clear the bpf_mem_cache if prefill fails.\n . Change test_bpf_ma percpu allocation tests to use bucket_size\n as allocation size instead of bucket_size - 8.\n . Remove __GFP_ZERO flag from __alloc_percpu_gfp() call.\n v1 -> v2:\n . Avoid unnecessary extra percpu memory allocation.\n . Add a separate function to do bpf_global_percpu_ma initialization\n . promote.\n . Promote function static 'sizes' array to file static.\n . Add comments to explain to refill only one item for percpu alloc.\n====================\n\nLink: https://lore.kernel.org/r/20231222031729.1287957-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n"", '']",Optimize memory usage in bpf programs by adjusting bpf_global_percpu_ma behavior.,"bpf, memory, optimization",It's a performance optimization.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +adc8c4549d9e74d2359c217d2478b18ecdd15c91,adc8c4549d9e74d2359c217d2478b18ecdd15c91,Yonghong Song,yonghong.song@linux.dev,1703215092,Alexei Starovoitov,ast@kernel.org,1704344906,33e7bd54cb6f7ee386fa8abca5ab0ae9cea74d64,21f5a801c171dff4e728e38f62cf626c4197d07c,"selftests/bpf: Add a selftest with > 512-byte percpu allocation size + +Add a selftest to capture the verification failure when the allocation +size is greater than 512. + +Acked-by: Hou Tao +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20231222031812.1293190-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,This commit adds a selftest for verification failure due to percpu allocation size exceeding 512 bytes.,"selftest, percpu, allocation",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +21f5a801c171dff4e728e38f62cf626c4197d07c,21f5a801c171dff4e728e38f62cf626c4197d07c,Yonghong Song,yonghong.song@linux.dev,1703215087,Alexei Starovoitov,ast@kernel.org,1704344906,876d4710deae0593e8aa7c6ad61b95295ddd3880,5c1a37653260ed5d9c8b26fb7fe7b99629612982,"selftests/bpf: Cope with 512 bytes limit with bpf_global_percpu_ma + +In the previous patch"," the maximum data size for bpf_global_percpu_ma +is 512 bytes. This breaks selftest test_bpf_ma. The test is adjusted +in two aspects: + - Since the maximum allowed data size for bpf_global_percpu_ma is + 512","[' remove all tests beyond that', ' names sizes 1024', ' 2048 and 4096.\n - Previously the percpu data size is bucket_size - 8 in order to\n avoid percpu allocation into the next bucket. This patch removed\n such data size adjustment thanks to Patch 1.\n\nAlso', ' a better way to generate BTF type is used than adding\na member to the value struct.\n\nAcked-by: Hou Tao \nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231222031807.1292853-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Adjust selftests to accommodate 512-byte limit of bpf_global_percpu_ma.,"selftests, bpf_global_percpu_ma, limit",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['other'] +5c1a37653260ed5d9c8b26fb7fe7b99629612982,5c1a37653260ed5d9c8b26fb7fe7b99629612982,Yonghong Song,yonghong.song@linux.dev,1703215081,Alexei Starovoitov,ast@kernel.org,1704344906,9cd3e4d1531ee6e46147d65ebc3dce1259409b15,0e2ba9f96f9b82893ba19170ae48d46003f8ef44,"bpf: Limit up to 512 bytes for bpf_global_percpu_ma allocation + +For percpu data structure allocation with bpf_global_percpu_ma"," +the maximum data size is 4K. But for a system with large +number of cpus","[' bigger data size (e.g.', ' 2K', ' 4K) might consume\na lot of memory. For example', ' the percpu memory consumption\nwith unit size 2K and 1024 cpus will be 2K * 1K * 1k = 2GB\nmemory.\n\nWe should discourage such usage. Let us limit the maximum data\nsize to be 512 for bpf_global_percpu_ma allocation.\n\nAcked-by: Hou Tao \nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231222031801.1290841-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",The commit limits bpf_global_percpu_ma allocation size to 512 bytes for handling large CPU systems.,"bpf, percpu, allocation",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0e2ba9f96f9b82893ba19170ae48d46003f8ef44,0e2ba9f96f9b82893ba19170ae48d46003f8ef44,Yonghong Song,yonghong.song@linux.dev,1703215075,Alexei Starovoitov,ast@kernel.org,1704344905,5b253ef511576f6cf1247fad149ecdd81401f5a0,5b95e638f134e552b5ba2976326c02babe248615,"bpf: Use smaller low/high marks for percpu allocation + +Currently"," refill low/high marks are set with the assumption +of normal non-percpu memory allocation. For example","[' for\nan allocation size 256', ' for non-percpu memory allocation', '\nlow mark is 32 and high mark is 96', ' resulting in the\nbatch allocation of 48 elements and the allocated memory\nwill be 48 * 256 = 12KB for this particular cpu.\nAssuming an 128-cpu system', ' the total memory consumption\nacross all cpus will be 12K * 128 = 1.5MB memory.\n\nThis might be okay for non-percpu allocation', ' but may not be\ngood for percpu allocation', ' which will consume 1.5MB * 128 = 192MB\nmemory in the worst case if every cpu has a chance of memory\nallocation.\n\nIn practice', ' percpu allocation is very rare compared to\nnon-percpu allocation. So let us have smaller low/high marks\nwhich can avoid unnecessary memory consumption.\n\nSigned-off-by: Yonghong Song \nAcked-by: Hou Tao \nLink: https://lore.kernel.org/r/20231222031755.1289671-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Adjust low and high marks for more efficient percpu memory allocation in BPF.,"BPF, percpu, allocation",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5b95e638f134e552b5ba2976326c02babe248615,5b95e638f134e552b5ba2976326c02babe248615,Yonghong Song,yonghong.song@linux.dev,1703215070,Alexei Starovoitov,ast@kernel.org,1704344905,ea6a83156f646dd70e550b31b67c441f008da0a6,c39aa3b289e9c10d0d246cd919b06809f13b72b8,"bpf: Refill only one percpu element in memalloc + +Typically for percpu map element or data structure", once allocated,"['\nmost operations are lookup or in-place update. Deletion are really\nrare. Currently', ' for percpu data strcture', ' 4 elements will be\nrefilled if the size is <= 256. Let us just do with one element\nfor percpu data. For example', ' for size 256 and 128 cpus', ' the\npotential saving will be 3 * 256 * 128 * 128 = 12MB.\n\nAcked-by: Hou Tao \nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231222031750.1289290-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Optimize memory allocation by refilling only one percpu element in memalloc.,"bpf, percpu, memalloc",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c39aa3b289e9c10d0d246cd919b06809f13b72b8,c39aa3b289e9c10d0d246cd919b06809f13b72b8,Yonghong Song,yonghong.song@linux.dev,1703215065,Alexei Starovoitov,ast@kernel.org,1704344905,b819faee48f6f8860e5571af8f1a46c0b3a30257,9fc8e802048ad150e8032c4f3dbf40112160cfe9,"bpf: Allow per unit prefill for non-fix-size percpu memory allocator + +Commit 41a5db8d8161 (""Add support for non-fix-size percpu mem allocation"") +added support for non-fix-size percpu memory allocation. +Such allocation will allocate percpu memory for all buckets on all +cpus and the memory consumption is in the order to quadratic. +For example", let us say,"[' 4 cpus', ' unit size 16 bytes', ' so each\ncpu has 16 * 4 = 64 bytes', ' with 4 cpus', ' total will be 64 * 4 = 256 bytes.\nThen let us say', ' 8 cpus with the same unit size', ' each cpu\nhas 16 * 8 = 128 bytes', ' with 8 cpus', ' total will be 128 * 8 = 1024 bytes.\nSo if the number of cpus doubles', ' the number of memory consumption\nwill be 4 times. So for a system with large number of cpus', ' the\nmemory consumption goes up quickly with quadratic order.\nFor example', ' for 4KB percpu allocation', ' 128 cpus. The total memory\nconsumption will 4KB * 128 * 128 = 64MB. Things will become\nworse if the number of cpus is bigger (e.g.', ' 512', ' 1024', ' etc.)\n\nIn Commit 41a5db8d8161', ' the non-fix-size percpu memory allocation is\ndone in boot time', ' so for system with large number of cpus', ' the initial\npercpu memory consumption is very visible. For example', ' for 128 cpu\nsystem', ' the total percpu memory allocation will be at least\n(16 + 32 + 64 + 96 + 128 + 196 + 256 + 512 + 1024 + 2048 + 4096)\n * 128 * 128 = ~138MB.\nwhich is pretty big. It will be even bigger for larger number of cpus.\n\nNote that the current prefill also allocates 4 entries if the unit size\nis less than 256. So on top of 138MB memory consumption', ' this will\nadd more consumption with\n3 * (16 + 32 + 64 + 96 + 128 + 196 + 256) * 128 * 128 = ~38MB.\nNext patch will try to reduce this memory consumption.\n\nLater on', ' Commit 1fda5bb66ad8 (""bpf: Do not allocate percpu memory\nat init stage"") moved the non-fix-size percpu memory allocation\nto bpf verificaiton stage. Once a particular bpf_percpu_obj_new()\nis called by bpf program', ' the memory allocator will try to fill in\nthe cache with all sizes', ' causing the same amount of percpu memory\nconsumption as in the boot stage.\n\nTo reduce the initial percpu memory consumption for non-fix-size\npercpu memory allocation', ' instead of filling the cache with all\nsupported allocation sizes', ' this patch intends to fill the cache\nonly for the requested size. As typically users will not use large\npercpu data structure', ' this can save memory significantly.\nFor example', ' the allocation size is 64 bytes with 128 cpus.\nThen total percpu memory amount will be 64 * 128 * 128 = 1MB', '\nmuch less than previous 138MB.\n\nSigned-off-by: Yonghong Song \nAcked-by: Hou Tao \nLink: https://lore.kernel.org/r/20231222031745.1289082-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",This commit allows per-unit prefill for non-fixed-size percpu memory allocator to optimize memory usage.,"percpu,memory,allocator",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9fc8e802048ad150e8032c4f3dbf40112160cfe9,9fc8e802048ad150e8032c4f3dbf40112160cfe9,Yonghong Song,yonghong.song@linux.dev,1703215059,Alexei Starovoitov,ast@kernel.org,1704344905,a77e0d24b1ba2a4d53645bbed8a724e7f6145c45,9beda16c257d55213f70adee2f16d7f13a8502e1,"bpf: Add objcg to bpf_mem_alloc + +The objcg is a bpf_mem_alloc level property since all bpf_mem_cache's +are with the same objcg. This patch made such a property explicit. +The next patch will use this property to save and restore objcg +for percpu unit allocator. + +Acked-by: Hou Tao +Signed-off-by: Yonghong Song +Link: https://lore.kernel.org/r/20231222031739.1288590-1-yonghong.song@linux.dev +Signed-off-by: Alexei Starovoitov +",,This commit adds objcg as a property to bpf_mem_alloc to enhance its functionality.,"objcg,bpf_mem_alloc,property",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9beda16c257d55213f70adee2f16d7f13a8502e1,9beda16c257d55213f70adee2f16d7f13a8502e1,Yonghong Song,yonghong.song@linux.dev,1703215054,Alexei Starovoitov,ast@kernel.org,1704344905,808b110d7b573d9567de037bfad6783898857d6c,417fa6d163df6f13fb2cfad5132eff354c8a472e,"bpf: Avoid unnecessary extra percpu memory allocation + +Currently", for percpu memory allocation,"[' say if the user\nrequests allocation size to be 32 bytes', ' the actually\ncalculated size will be 40 bytes and it further rounds\nto 64 bytes', ' and eventually 64 bytes are allocated', '\nwasting 32-byte memory.\n\nChange bpf_mem_alloc() to calculate the cache index\nbased on the user-provided allocation size so unnecessary\nextra memory can be avoided.\n\nSuggested-by: Hou Tao \nAcked-by: Hou Tao \nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231222031734.1288400-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Optimize bpf by preventing extra percpu memory allocation.,"bpf, percpu, memory",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +bdbca46d3f84a4455cd5c15a7483666218851549,bdbca46d3f84a4455cd5c15a7483666218851549,John Fastabend,john.fastabend@gmail.com,1703201007,Martin KaFai Lau,martin.lau@kernel.org,1704329422,d8a0d5f195e29edc68c8095a224b082f57ef2dfc,f1300467dd9f67293a7aae86fd26471520fac36d,bpf: sockmap," add tests for proto updates replace socket + +Add test that replaces the same socket with itself. This exercises a +corner case where old element and new element have the same posck. +Test protocols: TCP","[' UDP', ' stream af_unix and dgram af_unix.\n\nSigned-off-by: John Fastabend \nSigned-off-by: Martin KaFai Lau \nReviewed-by: Jakub Sitnicki \nLink: https://lore.kernel.org/r/20231221232327.43678-6-john.fastabend@gmail.com\n', '']","Added tests to handle cases where a socket element is replaced with itself in sockmap, particularly focusing on TCP protocols.","sockmap, tests, TCP",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +f1300467dd9f67293a7aae86fd26471520fac36d,f1300467dd9f67293a7aae86fd26471520fac36d,John Fastabend,john.fastabend@gmail.com,1703201006,Martin KaFai Lau,martin.lau@kernel.org,1704329421,dac441fa7d18eb830409885d90bb0aed52789a1d,8c1b382a555adcd2008ae964047a35b739dfaf24,bpf: sockmap," add tests for proto updates single socket to many map + +Add test with multiple maps where each socket is inserted in multiple +maps. Test protocols: TCP","[' UDP', ' stream af_unix and dgram af_unix.\n\nSigned-off-by: John Fastabend \nSigned-off-by: Martin KaFai Lau \nReviewed-by: Jakub Sitnicki \nLink: https://lore.kernel.org/r/20231221232327.43678-5-john.fastabend@gmail.com\n', '']",Add tests for handling multiple maps with single socket updates for TCP protocols.,"sockmap,TCP,multiple maps",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +8c1b382a555adcd2008ae964047a35b739dfaf24,8c1b382a555adcd2008ae964047a35b739dfaf24,John Fastabend,john.fastabend@gmail.com,1703201005,Martin KaFai Lau,martin.lau@kernel.org,1704329419,8f8dcf31c600ed2677b100f02a4953df5d528c60,7865dfb1eb941ddd25802a9e13b6ff5f3f4dc02f,bpf: sockmap," add tests for proto updates many to single map + +Add test with a single map where each socket is inserted multiple +times. Test protocols: TCP","[' UDP', ' stream af_unix and dgram af_unix.\n\nSigned-off-by: John Fastabend \nSigned-off-by: Martin KaFai Lau \nReviewed-by: Jakub Sitnicki \nLink: https://lore.kernel.org/r/20231221232327.43678-4-john.fastabend@gmail.com\n', '']",Add test cases for TCP protocol updates using a single sockmap with multiple socket entries.,"test,TCP,sockmap",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +7865dfb1eb941ddd25802a9e13b6ff5f3f4dc02f,7865dfb1eb941ddd25802a9e13b6ff5f3f4dc02f,John Fastabend,john.fastabend@gmail.com,1703201004,Martin KaFai Lau,martin.lau@kernel.org,1704329416,80e1650f741a44c94e7ed22c15545aa603839b8f,16b2f264983dc264c1560cc0170e760dec1bf54f,bpf: sockmap," added comments describing update proto rules + +Add a comment describing that the psock update proto callbback can be +called multiple times and this must be safe. + +Signed-off-by: John Fastabend +Signed-off-by: Martin KaFai Lau +Reviewed-by: Jakub Sitnicki +Link: https://lore.kernel.org/r/20231221232327.43678-3-john.fastabend@gmail.com +",[''],Add comments in sockmap for psock update proto callback safety.,"sockmap, psock, comments",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,['socket like programs'] +16b2f264983dc264c1560cc0170e760dec1bf54f,16b2f264983dc264c1560cc0170e760dec1bf54f,John Fastabend,john.fastabend@gmail.com,1703201003,Martin KaFai Lau,martin.lau@kernel.org,1704329406,6193fe6512ba7c9095c01278510cefc390cd2e7f,b4560055c8f11c5e2cfffb4de928b3cfd4eae3b4,bpf: sockmap," fix proto update hook to avoid dup calls + +When sockets are added to a sockmap or sockhash we allocate and init a +psock. Then update the proto ops with sock_map_init_proto the flow is + + sock_hash_update_common + sock_map_link + psock = sock_map_psock_get_checked() <-returns existing psock + sock_map_init_proto(sk","[' psock) <- updates sk_proto\n\nIf the socket is already in a map this results in the sock_map_init_proto\nbeing called multiple times on the same socket. We do this because when\na socket is added to multiple maps this might result in a new set of BPF\nprograms being attached to the socket requiring an updated ops struct.\n\nThis creates a rule where it must be safe to call psock_update_sk_prot\nmultiple times. When we added a fix for UAF through unix sockets in patch\n4dd9a38a753fc we broke this rule by adding a sock_hold in that path\nto ensure the sock is not released. The result is if a af_unix stream sock\nis placed in multiple maps it results in a memory leak because we call\nsock_hold multiple times with only a single sock_put on it.\n\nFixes: 8866730aed51 (""bpf', ' sockmap: af_unix stream sockets need to hold ref for pair sock"")\nReported-by: Xingwei Lee \nSigned-off-by: John Fastabend \nSigned-off-by: Martin KaFai Lau \nReviewed-by: Jakub Sitnicki \nLink: https://lore.kernel.org/r/20231221232327.43678-2-john.fastabend@gmail.com\n', '']",Fixes proto update hook to prevent duplicate calls when adding sockets to sockmaps or sockhashes.,"proto update, sockmap, duplicate calls",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['socket like programs'] +9c51f8788b5d4e9f46afbcf563255cfd355690b3,9c51f8788b5d4e9f46afbcf563255cfd355690b3,Ian Rogers,irogers@google.com,1701913615,Arnaldo Carvalho de Melo,acme@redhat.com,1704315294,573d20cc7b23f03374165ffd9f0c6597c4c7d1a8,58824fa0087e1cb732edbf1f112a5ea0b2205c8b,"perf env: Avoid recursively taking env->bpf_progs.lock + +Add variants of perf_env__insert_bpf_prog_info()"," perf_env__insert_btf() +and perf_env__find_btf prefixed with __ to indicate the +env->bpf_progs.lock is assumed held. + +Call these variants when the lock is held to avoid recursively taking it +and potentially having a thread deadlock with itself. + +Fixes: f8dfeae009effc0b (""perf bpf: Show more BPF program info in print_bpf_prog_info()"") +Signed-off-by: Ian Rogers +Acked-by: Jiri Olsa +Acked-by: Song Liu +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: K Prateek Nayak +Cc: Kan Liang +Cc: Mark Rutland +Cc: Ming Wang +Cc: Namhyung Kim +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Link: https://lore.kernel.org/r/20231207014655.1252484-1-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",[''],This commit addresses a potential deadlock issue in perf env by modifying lock usage when handling bpf prog information.,"perf, deadlock, lock",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b4560055c8f11c5e2cfffb4de928b3cfd4eae3b4,b4560055c8f11c5e2cfffb4de928b3cfd4eae3b4,Andrii Nakryiko,andrii@kernel.org,1704307282,Andrii Nakryiko,andrii@kernel.org,1704308904,0cd08e41ae266dee372fd04ba167791dbbf252ac,a640de4cf9fec0caf43ccb7404ec9f0fde9a6a65 7e3811cb998f0e2493677c7daf6cefb4ece27111,"Merge branch 'bpf-volatile-compare' + +Alexei Starovoitov says: + +==================== +bpf: volatile compare + +From: Alexei Starovoitov + +v2->v3: +Debugged profiler.c regression. It was caused by basic block layout. +Introduce bpf_cmp_likely() and bpf_cmp_unlikely() macros. +Debugged redundant <<=32"," >>=32 with u32 variables. Added cast workaround. + +v1->v2: +Fixed issues pointed out by Daniel","[' added more tests', ' attempted to convert profiler.c', '\nbut barrier_var() wins vs bpf_cmp(). To be investigated.\nPatches 1-4 are good to go', ' but 5 needs more work.\n====================\n\nLink: https://lore.kernel.org/r/20231226191148.48536-1-alexei.starovoitov@gmail.com\nSigned-off-by: Andrii Nakryiko \n', '']",Introduce bpf_cmp_likely() and bpf_cmp_unlikely() macros for optimizing volatile comparisons in BPF programs.,"bpf,cmp,macros",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7e3811cb998f0e2493677c7daf6cefb4ece27111,7e3811cb998f0e2493677c7daf6cefb4ece27111,Alexei Starovoitov,ast@kernel.org,1703617908,Andrii Nakryiko,andrii@kernel.org,1704308903,0cd08e41ae266dee372fd04ba167791dbbf252ac,0bcc62aa9813f519db58df14ddf1d523fa971e62,"selftests/bpf: Convert profiler.c to bpf_cmp. + +Convert profiler[123].c to ""volatile compare"" to compare barrier_var() approach vs bpf_cmp_likely() vs bpf_cmp_unlikely(). + +bpf_cmp_unlikely() produces correct code"," but takes much longer to verify: + +./veristat -C -e prog","['insns', 'states before after_with_unlikely\nProgram Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n------------------------------------ --------- --------- ------------------ ---------- ---------- -----------------\nkprobe__proc_sys_write 1603 19606 +18003 (+1123.08%) 123 1678 +1555 (+1264.23%)\nkprobe__vfs_link 11815 70305 +58490 (+495.05%) 971 4967 +3996 (+411.53%)\nkprobe__vfs_symlink 5464 42896 +37432 (+685.07%) 434 3126 +2692 (+620.28%)\nkprobe_ret__do_filp_open 5641 44578 +38937 (+690.25%) 446 3162 +2716 (+608.97%)\nraw_tracepoint__sched_process_exec 2770 35962 +33192 (+1198.27%) 226 3121 +2895 (+1280.97%)\nraw_tracepoint__sched_process_exit 1526 2135 +609 (+39.91%) 133 208 +75 (+56.39%)\nraw_tracepoint__sched_process_fork 265 337 +72 (+27.17%) 19 24 +5 (+26.32%)\ntracepoint__syscalls__sys_enter_kill 18782 140407 +121625 (+647.56%) 1286 12176 +10890 (+846.81%)\n\nbpf_cmp_likely() is equivalent to barrier_var():\n\n./veristat -C -e prog', 'insns', 'states before after_with_likely\nProgram Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n------------------------------------ --------- --------- -------------- ---------- ---------- -------------\nkprobe__proc_sys_write 1603 1663 +60 (+3.74%) 123 127 +4 (+3.25%)\nkprobe__vfs_link 11815 12090 +275 (+2.33%) 971 971 +0 (+0.00%)\nkprobe__vfs_symlink 5464 5448 -16 (-0.29%) 434 426 -8 (-1.84%)\nkprobe_ret__do_filp_open 5641 5739 +98 (+1.74%) 446 446 +0 (+0.00%)\nraw_tracepoint__sched_process_exec 2770 2608 -162 (-5.85%) 226 216 -10 (-4.42%)\nraw_tracepoint__sched_process_exit 1526 1526 +0 (+0.00%) 133 133 +0 (+0.00%)\nraw_tracepoint__sched_process_fork 265 265 +0 (+0.00%) 19 19 +0 (+0.00%)\ntracepoint__syscalls__sys_enter_kill 18782 18970 +188 (+1.00%) 1286 1286 +0 (+0.00%)\nkprobe__proc_sys_write 2700 2809 +109 (+4.04%) 107 109 +2 (+1.87%)\nkprobe__vfs_link 12238 12366 +128 (+1.05%) 267 269 +2 (+0.75%)\nkprobe__vfs_symlink 7139 7365 +226 (+3.17%) 167 175 +8 (+4.79%)\nkprobe_ret__do_filp_open 7264 7070 -194 (-2.67%) 180 182 +2 (+1.11%)\nraw_tracepoint__sched_process_exec 3768 3453 -315 (-8.36%) 211 199 -12 (-5.69%)\nraw_tracepoint__sched_process_exit 3138 3138 +0 (+0.00%) 83 83 +0 (+0.00%)\nraw_tracepoint__sched_process_fork 265 265 +0 (+0.00%) 19 19 +0 (+0.00%)\ntracepoint__syscalls__sys_enter_kill 26679 24327 -2352 (-8.82%) 1067 1037 -30 (-2.81%)\nkprobe__proc_sys_write 1833 1833 +0 (+0.00%) 157 157 +0 (+0.00%)\nkprobe__vfs_link 9995 10127 +132 (+1.32%) 803 803 +0 (+0.00%)\nkprobe__vfs_symlink 5606 5672 +66 (+1.18%) 451 451 +0 (+0.00%)\nkprobe_ret__do_filp_open 5716 5782 +66 (+1.15%) 462 462 +0 (+0.00%)\nraw_tracepoint__sched_process_exec 3042 3042 +0 (+0.00%) 278 278 +0 (+0.00%)\nraw_tracepoint__sched_process_exit 1680 1680 +0 (+0.00%) 146 146 +0 (+0.00%)\nraw_tracepoint__sched_process_fork 299 299 +0 (+0.00%) 25 25 +0 (+0.00%)\ntracepoint__syscalls__sys_enter_kill 18372 18372 +0 (+0.00%) 1558 1558 +0 (+0.00%)\n\ndefault (mcpu=v3)', ' no_alu32', ' cpuv4 have similar differences.\n\nNote one place where bpf_nop_mov() is used to workaround the verifier lack of link\nbetween the scalar register and its spill to stack.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231226191148.48536-7-alexei.starovoitov@gmail.com\n', '']",Convert profiler test files to use bpf_cmp for volatile comparison.,"selftests,bpf_cmp,profiler",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0bcc62aa9813f519db58df14ddf1d523fa971e62,0bcc62aa9813f519db58df14ddf1d523fa971e62,Alexei Starovoitov,ast@kernel.org,1703617907,Andrii Nakryiko,andrii@kernel.org,1704308903,884e35b466cf0bda2af66675bc3379dae60d37e1,907dbd3ede5ffd4f9519dd1fae2a8a983603bf3b,"bpf: Add bpf_nop_mov() asm macro. + +bpf_nop_mov(var) asm macro emits nop register move: rX = rX. +If 'var' is a scalar and not a fixed constant the verifier will assign ID to it. +If it's later spilled the stack slot will carry that ID as well. +Hence the range refining comparison ""if rX < const"" will update all copies +including spilled slot. +This macro is a temporary workaround until the verifier gets smarter. + +Signed-off-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231226191148.48536-6-alexei.starovoitov@gmail.com +",,Introduces a new bpf_nop_mov() macro for improved control over variable registration and ID tracking.,"bpf_nop_mov, asm macro, verifier",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +907dbd3ede5ffd4f9519dd1fae2a8a983603bf3b,907dbd3ede5ffd4f9519dd1fae2a8a983603bf3b,Alexei Starovoitov,ast@kernel.org,1703617906,Andrii Nakryiko,andrii@kernel.org,1704308903,806a284aa90422430f92c32be1e180822b62be9d,624cd2a17672f4596fee97a5558bc990778bbcf9,"selftests/bpf: Remove bpf_assert_eq-like macros. + +Since the last user was converted to bpf_cmp"," remove bpf_assert_eq/ne/... macros. + +__bpf_assert_op() macro is kept for experiments","["" since it's slightly more efficient\nthan bpf_assert(bpf_cmp_unlikely()) until LLVM is fixed.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nAcked-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/bpf/20231226191148.48536-5-alexei.starovoitov@gmail.com\n"", '']",The commit removes bpf_assert_eq macros from selftests as they are redundant with the new bpf_cmp macro.,"selftests, macros, bpf_cmp",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +624cd2a17672f4596fee97a5558bc990778bbcf9,624cd2a17672f4596fee97a5558bc990778bbcf9,Alexei Starovoitov,ast@kernel.org,1703617905,Andrii Nakryiko,andrii@kernel.org,1704308903,8b24caf8e239bea1bbc4313d0f4a9aaed3c832e0,a8b242d77bd72556b7a9d8be779f7d27b95ba73c,"selftests/bpf: Convert exceptions_assert.c to bpf_cmp + +Convert exceptions_assert.c to bpf_cmp_unlikely() macro. + +Since + +bpf_assert(bpf_cmp_unlikely(var", ==,"["" 100));\nother code;\n\nwill generate assembly code:\n\n if r1 == 100 goto L2;\n r0 = 0\n call bpf_throw\nL1:\n other code;\n ...\n\nL2: goto L1;\n\nLLVM generates redundant basic block with extra goto. LLVM will be fixed eventually.\nRight now it's less efficient than __bpf_assert(var"", ' ==', "" 100) macro that produces:\n if r1 == 100 goto L1;\n r0 = 0\n call bpf_throw\nL1:\n other code;\n\nBut extra goto doesn't hurt the verification process.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nAcked-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/bpf/20231226191148.48536-4-alexei.starovoitov@gmail.com\n"", '']",Convert exceptions_assert.c in selftests to use bpf_cmp_unlikely() macro.,"exceptions_assert,bpf_cmp_unlikely,selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a8b242d77bd72556b7a9d8be779f7d27b95ba73c,a8b242d77bd72556b7a9d8be779f7d27b95ba73c,Alexei Starovoitov,ast@kernel.org,1703617904,Andrii Nakryiko,andrii@kernel.org,1704308322,ee646501c5045d276c5b9ecced32a85eac557be9,495d2d8133fd1407519170a5238f455abbd9ec9b,"bpf: Introduce ""volatile compare"" macros + +Compilers optimize conditional operators at will"," but often bpf programmers +want to force compilers to keep the same operator in asm as it's written in C. +Introduce bpf_cmp_likely/unlikely(var1","[' conditional_op', ' var2) macros that can be used as:\n\n- if (seen >= 1000)\n+ if (bpf_cmp_unlikely(seen', ' >=', "" 1000))\n\nThe macros take advantage of BPF assembly that is C like.\n\nThe macros check the sign of variable 'seen' and emits either\nsigned or unsigned compare.\n\nFor example:\nint a;\nbpf_cmp_unlikely(a"", ' >', "" 0) will be translated to 'if rX s> 0 goto' in BPF assembly.\n\nunsigned int a;\nbpf_cmp_unlikely(a"", ' >', "" 0) will be translated to 'if rX > 0 goto' in BPF assembly.\n\nC type conversions coupled with comparison operator are tricky.\n int i = -1;\n unsigned int j = 1;\n if (i < j) // this is false.\n\n long i = -1;\n unsigned int j = 1;\n if (i < j) // this is true.\n\nMake sure BPF program is compiled with -Wsign-compare then the macros will catch\nthe mistake.\n\nThe macros check LHS (left hand side) only to figure out the sign of compare.\n\n'if 0 < rX goto' is not allowed in the assembly"", ' so the users\nhave to use a variable on LHS anyway.\n\nThe patch updates few tests to demonstrate the use of the macros.\n\nThe macro allows to use BPF_JSET in C code', "" since LLVM doesn't generate it at\npresent. For example:\n\nif (i & j) compiles into r0 &= r1; if r0 == 0 goto\n\nwhile\n\nif (bpf_cmp_unlikely(i"", ' &', ' j)) compiles into if r0 & r1 goto\n\nNote that the macros has to be careful with RHS assembly predicate.\nSince:\nu64 __rhs = 1ull << 42;\nasm goto(""if r0 < %[rhs] goto +1"" :: [rhs] ""ri"" (__rhs));\nLLVM will silently truncate 64-bit constant into s32 imm.\n\nNote that [lhs] ""r""((short)LHS) the type cast is a workaround for LLVM issue.\nWhen LHS is exactly 32-bit LLVM emits redundant <<=32', "" >>=32 to zero upper 32-bits.\nWhen LHS is 64 or 16 or 8-bit variable there are no shifts.\nWhen LHS is 32-bit the (u64) cast doesn't help. Hence use (short) cast.\nIt does _not_ truncate the variable before it's assigned to a register.\n\nTraditional likely()/unlikely() macros that use __builtin_expect(!!(x)"", ' 1 or 0)\nhave no effect on these macros', "" hence macros implement the logic manually.\nbpf_cmp_unlikely() macro preserves compare operator as-is while\nbpf_cmp_likely() macro flips the compare.\n\nConsider two cases:\nA.\n for() {\n if (foo >= 10) {\n bar += foo;\n }\n other code;\n }\n\nB.\n for() {\n if (foo >= 10)\n break;\n other code;\n }\n\nIt's ok to use either bpf_cmp_likely or bpf_cmp_unlikely macros in both cases"", ""\nbut consider that 'break' is effectively 'goto out_of_the_loop'.\nHence it's better to use bpf_cmp_unlikely in the B case.\nWhile 'bar += foo' is better to keep as 'fallthrough' == likely code path in the A case.\n\nWhen it's written as:\nA.\n for() {\n if (bpf_cmp_likely(foo"", ' >=', ' 10)) {\n bar += foo;\n }\n other code;\n }\n\nB.\n for() {\n if (bpf_cmp_unlikely(foo', ' >=', ' 10))\n break;\n other code;\n }\n\nThe assembly will look like:\nA.\n for() {\n if r1 < 10 goto L1;\n bar += foo;\n L1:\n other code;\n }\n\nB.\n for() {\n if r1 >= 10 goto L2;\n other code;\n }\n L2:\n\nThe bpf_cmp_likely vs bpf_cmp_unlikely changes basic block layout', ' hence it will\ngreatly influence the verification process. The number of processed instructions\nwill be different', ' since the verifier walks the fallthrough first.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Daniel Borkmann \nAcked-by: Jiri Olsa \nAcked-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/bpf/20231226191148.48536-3-alexei.starovoitov@gmail.com\n', '']",This commit introduces macros for volatile comparisons to aid bpf programmers in controlling compiler optimizations.,"volatile, macros, operators",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +495d2d8133fd1407519170a5238f455abbd9ec9b,495d2d8133fd1407519170a5238f455abbd9ec9b,Alexei Starovoitov,ast@kernel.org,1703617903,Andrii Nakryiko,andrii@kernel.org,1704307282,12f60945f5c43cbd7daaaf7be7e3594612a477c4,a640de4cf9fec0caf43ccb7404ec9f0fde9a6a65,"selftests/bpf: Attempt to build BPF programs with -Wsign-compare + +GCC's -Wall includes -Wsign-compare while clang does not. +Since BPF programs are built with clang we need to add this flag explicitly +to catch problematic comparisons like: + + int i = -1; + unsigned int j = 1; + if (i < j) // this is false. + + long i = -1; + unsigned int j = 1; + if (i < j) // this is true. + +C standard for reference: + +- If either operand is unsigned long the other shall be converted to unsigned long. + +- Otherwise", if one operand is a long int and the other unsigned int,"[' then if a\nlong int can represent all the values of an unsigned int', ' the unsigned int\nshall be converted to a long int; otherwise both operands shall be converted to\nunsigned long int.\n\n- Otherwise', ' if either operand is long', ' the other shall be converted to long.\n\n- Otherwise', ' if either operand is unsigned', "" the other shall be converted to unsigned.\n\nUnfortunately clang's -Wsign-compare is very noisy.\nIt complains about (s32)a == (u32)b which is safe and doen't have surprising behavior.\n\nThis patch fixes some of the issues. It needs a follow up to fix the rest.\n\nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Jiri Olsa \nAcked-by: Kumar Kartikeya Dwivedi \nLink: https://lore.kernel.org/bpf/20231226191148.48536-2-alexei.starovoitov@gmail.com\n"", '']",Add -Wsign-compare flag to clang when building BPF programs to catch signed/unsigned comparison issues.,"BPF programs, -Wsign-compare, clang",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a640de4cf9fec0caf43ccb7404ec9f0fde9a6a65,a640de4cf9fec0caf43ccb7404ec9f0fde9a6a65,Andrii Nakryiko,andrii@kernel.org,1704307077,Andrii Nakryiko,andrii@kernel.org,1704307077,d58e59ba6536fc754d8aed14bd7ef6a2a3fe2be0,2ab1efad60ad119b616722b81eeb73060728028c 72187506de4f19fcc8ae63a2b2f36d75e5259d9d,"Merge branch 'bpf-simplify-checking-size-of-helper-accesses' + +Andrei Matei says: + +==================== +bpf: Simplify checking size of helper accesses + +v3->v4: +- kept only the minimal change"," undoing debatable changes (Andrii) +- dropped the second patch from before","[' with changes to the error\n message (Andrii)\n- extracted the new test into a separate patch (Andrii)\n- added Acked by Andrii\n\nv2->v3:\n- split the error-logging function to a separate patch (Andrii)\n- make the error buffers smaller (Andrii)\n- include size of memory region for PTR_TO_MEM (Andrii)\n- nits from Andrii and Eduard\n\nv1->v2:\n- make the error message include more info about the context of the\n zero-sized access (Andrii)\n====================\n\nLink: https://lore.kernel.org/r/20231221232225.568730-1-andreimatei1@gmail.com\nSigned-off-by: Andrii Nakryiko \n', '']",Simplifies checking the size of eBPF helper accesses by retaining minimal changes.,"bpf, helper, simplify",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +72187506de4f19fcc8ae63a2b2f36d75e5259d9d,72187506de4f19fcc8ae63a2b2f36d75e5259d9d,Andrei Matei,andreimatei1@gmail.com,1703200945,Andrii Nakryiko,andrii@kernel.org,1704307076,d58e59ba6536fc754d8aed14bd7ef6a2a3fe2be0,8a021e7fa10576eeb3938328f39bbf98fe7d4715,"bpf: Add a possibly-zero-sized read test + +This patch adds a test for the condition that the previous patch mucked +with - illegal zero-sized helper memory access. As opposed to existing +tests", this new one uses a size whose lower bound is zero,"[' as opposed to\na known-zero one.\n\nSigned-off-by: Andrei Matei \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231221232225.568730-3-andreimatei1@gmail.com\n', '']",Add test for zero-sized helper memory access in eBPF.,"test, zero-sized, memory",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8a021e7fa10576eeb3938328f39bbf98fe7d4715,8a021e7fa10576eeb3938328f39bbf98fe7d4715,Andrei Matei,andreimatei1@gmail.com,1703200944,Andrii Nakryiko,andrii@kernel.org,1704307076,6373692e4954ec6a180b35ac37665395c703f8a7,2ab1efad60ad119b616722b81eeb73060728028c,"bpf: Simplify checking size of helper accesses + +This patch simplifies the verification of size arguments associated to +pointer arguments to helpers and kfuncs. Many helpers take a pointer +argument followed by the size of the memory access performed to be +performed through that pointer. Before this patch"," the handling of the +size argument in check_mem_size_reg() was confusing and wasteful: if the +size register's lower bound was 0","[' then the verification was done twice:\nonce considering the size of the access to be the lower-bound of the\nrespective argument', ' and once considering the upper bound (even if the\ntwo are the same). The upper bound checking is a super-set of the\nlower-bound checking(*)', ' except: the only point of the lower-bound check\nis to handle the case where zero-sized-accesses are explicitly not\nallowed and the lower-bound is zero. This static condition is now\nchecked explicitly', ' replacing a much more complex', ' expensive and\nconfusing verification call to check_helper_mem_access().\n\nError messages change in this patch. Before', ' messages about illegal\nzero-size accesses depended on the type of the pointer and on other\nconditions', ' and sometimes the message was plain wrong: in some tests\nthat changed you\'ll see that the old message was something like ""R1 min\nvalue is outside of the allowed memory range""', ' where R1 is the pointer\nregister; the error was wrongly claiming that the pointer was bad\ninstead of the size being bad. Other times the information that the size\ncame for a register with a possible range of values was wrong', ' and the\nerror presented the size as a fixed zero. Now the errors refer to the\nright register. However', ' the old error messages did contain useful\ninformation about the pointer register which is now lost; recovering\nthis information was deemed not important enough.\n\n(*) Besides standing to reason that the checks for a bigger size access\nare a super-set of the checks for a smaller size access', "" I have also\nmechanically verified this by reading the code for all types of\npointers. I could convince myself that it's true for all but\nPTR_TO_BTF_ID (check_ptr_to_btf_access). There"", ' simply looking\nline-by-line does not immediately prove what we want. If anyone has any\nqualms', ' let me know.\n\nSigned-off-by: Andrei Matei \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231221232225.568730-2-andreimatei1@gmail.com\n', '']",This commit simplifies the verification of size arguments for helper and kfunc pointer accesses in eBPF.,"simplify, helper, verification",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9b0a3839e8d29663cd9ee2c43d38b06c3b91619e,9b0a3839e8d29663cd9ee2c43d38b06c3b91619e,Greg Kroah-Hartman,gregkh@linuxfoundation.org,1703057928,Jiri Kosina,jkosina@suse.com,1704191128,ee9eff7ed1ea9cf1e98084619f9081bd3175d8c4,c4a9743699f3b093bad4bcc472c4ee34c7929f33,"HID: bpf: make bus_type const in struct hid_bpf_ops + +The struct bus_type pointer in hid_bpf_ops just passes the pointer to +the driver core", and the driver core can handle,"[' and expects', ' a constant\npointer', ' so also make the pointer constant in hid_bpf_ops.\n\nPart of the process of moving all usages of struct bus_type to be\nconstant to move them all to read-only memory.\n\nCc: Jiri Kosina \nCc: Benjamin Tissoires \nCc: linux-input@vger.kernel.org\nSigned-off-by: Greg Kroah-Hartman \nSigned-off-by: Jiri Kosina \n', '']",Make bus_type const in struct hid_bpf_ops to work with driver core.,"HID,bus_type,const",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['HID driver like programs'] +240436c06ce992879d59e504b0df3d32deebb43e,240436c06ce992879d59e504b0df3d32deebb43e,David S. Miller,davem@davemloft.net,1704120321,David S. Miller,davem@davemloft.net,1704120321,0c1653f11b3e4aca68269bacb978e8e985bb0ee7,cff9c565e65f3622e8dc1dcc21c1520a083dff35 5abde62465222edd3080b70099bd809f166d5d7d,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +bpf-next-for-netdev +The following pull-request contains BPF updates for your *net-next* tree. + +We've added 22 non-merge commits during the last 3 day(s) which contain +a total of 23 files changed", 652 insertions(+),"["" 431 deletions(-).\n\nThe main changes are:\n\n1) Add verifier support for annotating user's global BPF subprogram arguments\n with few commonly requested annotations for a better developer experience"", '\n from Andrii Nakryiko.\n\n These tags are:\n - Ability to annotate a special PTR_TO_CTX argument\n - Ability to annotate a generic PTR_TO_MEM as non-NULL\n\n2) Support BPF verifier tracking of BPF_JNE which helps cases when the compiler\n transforms (unsigned) ""a > 0"" into ""if a == 0 goto xxx"" and the like', "" from\n Menglong Dong.\n\n3) Fix a warning in bpf_mem_cache's check_obj_size() as reported by LKP"", ' from Hou Tao.\n\n4) Re-support uid/gid options when mounting bpffs which had to be reverted with\n the prior token series revert to avoid conflicts', ' from Daniel Borkmann.\n\n5) Fix a libbpf NULL pointer dereference in bpf_object__collect_prog_relos() found\n from fuzzing the library with malformed ELF files', "" from Mingyi Zhang.\n\n6) Skip DWARF sections in libbpf's linker sanity check given compiler options to\n generate compressed debug sections can trigger a rejection due to misalignment"", '\n from Alyssa Ross.\n\n7) Fix an unnecessary use of the comma operator in BPF verifier', ' from Simon Horman.\n\n8) Fix format specifier for unsigned long values in cpustat sample', ' from Colin Ian King.\n====================\n\nSigned-off-by: David S. Miller \n', '']",Merge bpf-next branch into the net-next tree with updates containing various BPF enhancements.,"BPF, merge, updates",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fc044c53b99fad039ac30b95b289992ebf7dd6b4,fc044c53b99fad039ac30b95b289992ebf7dd6b4,Namhyung Kim,namhyung@kernel.org,1702426390,Arnaldo Carvalho de Melo,acme@redhat.com,1703381982,bb61a7d8a1a77612e1af59f7262b5bd6a8f1216a,b9c87f536c6f28c75ace8a014646faad00f0e1ec,"perf annotate-data: Add dso->data_types tree + +To aggregate accesses to the same data type"," add 'data_types' tree in +DSO to maintain data types and find it by name and size. + +It might have different data types that happen to have the same name","[""\nso it also compares the size of the type.\n\nEven if it doesn't 100% guarantee"", "" it reduces the possibility of\nmis-handling of such conflicts.\n\nAnd I don't think it's common to have different types with the same\nname.\n\nCommitter notes:\n\nVery few cases on the Linux kernel"", ' but there are some different types\nwith the same name', ' unsure if there is a debug mode in libbpf dedup that\nwarns about such cases', ' but there are provisions in pahole for that', '\nsee:\n\n ""emit: Notice type shadowing', ' i.e. multiple types with the same name (enum', ' struct', ' union', ' etc)""\n https://git.kernel.org/pub/scm/devel/pahole/pahole.git/commit/?id=4f332dbfd02072e4f410db7bdcda8d6e3422974b\n\n $ pahole --compile > vmlinux.h\n $ rm -f a ; make a\n cc a.c -o a\n $ grep __[0-9] vmlinux.h\n union irte__1 {\n struct map_info__1;\n struct map_info__1 {\n \tstruct map_info__1 * next; /* 0 8 */\n $\n\n drivers/iommu/amd/amd_iommu_types.h \'union irte\'\n include/linux/dmar.h \'struct irte\'\n\n include/linux/device-mapper.h:\n\n union map_info {\n void *ptr;\n };\n\n include/linux/mtd/map.h:\n\n struct map_info {\n const char *name;\n unsigned long size;\n resource_size_t phys;\n \n\n kernel/events/uprobes.c:\n\n struct map_info {\n struct map_info *next;\n struct mm_struct *mm;\n unsigned long vaddr;\n };\n\nSigned-off-by: Namhyung Kim \nCc: Adrian Hunter \nCc: Ian Rogers \nCc: Ingo Molnar \nCc: Jiri Olsa \nCc: Linus Torvalds \nCc: Masami Hiramatsu \nCc: Peter Zijlstra \nCc: Stephane Eranian \nCc: linux-toolchains@vger.kernel.org\nCc: linux-trace-devel@vger.kernel.org\nLink: https://lore.kernel.org/r/20231213001323.718046-5-namhyung@kernel.org\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",Add a data tree structure in DSO to manage and differentiate data types by name and size.,"data tree, DSO, data types",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","[""It's not related to any of the above.""]" +2437c0f5147b82b92075af6085b99051753f4a3c,2437c0f5147b82b92075af6085b99051753f4a3c,David S. Miller,davem@davemloft.net,1703291192,David S. Miller,davem@davemloft.net,1703291192,d63af2761cdb517aceee0e7789c749e7d3d82fcb,6530b29f77c8960bd21639ce71070499d155396b 9d0b4ad82d6117e6d7ead50f64be54ec782aa1fe,"Merge branch 'net-selftests-unique-namespace-last-part' + +Hangbin Liu says: + +==================== +Convert net selftests to run in unique namespace (last part) + +Here is the last part of converting net selftests to run in unique namespace. +This part converts all left tests. After the conversion"," we can run the net +sleftests in parallel. e.g. + + # ./run_kselftest.sh -n -t net:reuseport_bpf + TAP version 13 + 1..1 + # selftests: net: reuseport_bpf + ok 1 selftests: net: reuseport_bpf + mod 10... + # Socket 0: 0 + # Socket 1: 1 + ... + # Socket 4: 19 + # Testing filter add without bind... + # SUCCESS + + # ./run_kselftest.sh -p -n -t net:cmsg_so_mark.sh -t net:cmsg_time.sh -t net:cmsg_ipv6.sh + TAP version 13 + 1..3 + # selftests: net: cmsg_so_mark.sh + ok 1 selftests: net: cmsg_so_mark.sh + # selftests: net: cmsg_time.sh + ok 2 selftests: net: cmsg_time.sh + # selftests: net: cmsg_ipv6.sh + ok 3 selftests: net: cmsg_ipv6.sh + + # ./run_kselftest.sh -p -n -c net + TAP version 13 + 1..95 + # selftests: net: reuseport_bpf_numa + ok 3 selftests: net: reuseport_bpf_numa + # selftests: net: reuseport_bpf_cpu + ok 2 selftests: net: reuseport_bpf_cpu + # selftests: net: sk_bind_sendto_listen + ok 9 selftests: net: sk_bind_sendto_listen + # selftests: net: reuseaddr_conflict + ok 5 selftests: net: reuseaddr_conflict + ... + +Here is the part 1 link: +https://lore.kernel.org/netdev/20231202020110.362433-1-liuhangbin@gmail.com +part 2 link: +https://lore.kernel.org/netdev/20231206070801.1691247-1-liuhangbin@gmail.com +part 3 link: +https://lore.kernel.org/netdev/20231213060856.4030084-1-liuhangbin@gmail.com +==================== + +Signed-off-by: David S. Miller +",[''],Convert remaining net selftests to run in unique namespaces for parallel execution.,"net selftests, unique namespace, parallel execution",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +5abde62465222edd3080b70099bd809f166d5d7d,5abde62465222edd3080b70099bd809f166d5d7d,Simon Horman,horms@kernel.org,1703178232,Daniel Borkmann,daniel@iogearbox.net,1703194825,766b65b7e90551fd0e302979345a1d048a124e3f,b08c8fc0411dce0fc44b78ce4d67f1b67c35c196,"bpf: Avoid unnecessary use of comma operator in verifier + +Although it does not seem to have any untoward side-effects"," the use +of ';' to separate to assignments seems more appropriate than '","[""'.\n\nFlagged by clang-17 -Wcomma\n\nNo functional change intended. Compile tested only.\n\nSigned-off-by: Simon Horman \nSigned-off-by: Daniel Borkmann \nReviewed-by: Dave Marchevsky \nLink: https://lore.kernel.org/bpf/20231221-bpf-verifier-comma-v1-1-cde2530912e9@kernel.org\n"", '']",This commit improves the eBPF verifier by avoiding unnecessary use of the comma operator in assignments.,"bpf, verifier, comma",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7c5e046bdcb2513f9decb3765d8bf92d604279cf,7c5e046bdcb2513f9decb3765d8bf92d604279cf,Linus Torvalds,torvalds@linux-foundation.org,1703178937,Linus Torvalds,torvalds@linux-foundation.org,1703178937,5f8330fbca28d6bc8daaf4fefd40b2d838ef1547,a4aebe936554dac6a91e5d091179c934f8325708 74769d810ead7e7af1a481f07a4d890861a6a4cc,"Merge tag 'net-6.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + ""Including fixes from WiFi and bpf. + + Current release - regressions: + + - bpf: syzkaller found null ptr deref in unix_bpf proto add + + - eth: i40e: fix ST code value for clause 45 + + Previous releases - regressions: + + - core: return error from sk_stream_wait_connect() if sk_wait_event() + fails + + - ipv6: revert remove expired routes with a separated list of routes + + - wifi rfkill: + - set GPIO direction + - fix crash with WED rx support enabled + + - bluetooth: + - fix deadlock in vhci_send_frame + - fix use-after-free in bt_sock_recvmsg + + - eth: mlx5e: fix a race in command alloc flow + + - eth: ice: fix PF with enabled XDP going no-carrier after reset + + - eth: bnxt_en: do not map packet buffers twice + + Previous releases - always broken: + + - core: + - check vlan filter feature in vlan_vids_add_by_dev() and + vlan_vids_del_by_dev() + - check dev->gso_max_size in gso_features_check() + + - mptcp: fix inconsistent state on fastopen race + + - phy: skip LED triggers on PHYs on SFP modules + + - eth: mlx5e: + - fix double free of encap_header + - fix slab-out-of-bounds in mlx5_query_nic_vport_mac_list()"" + +* tag 'net-6.7-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (69 commits) + net: check dev->gso_max_size in gso_features_check() + kselftest: rtnetlink.sh: use grep_fail when expecting the cmd fail + net/ipv6: Revert remove expired routes with a separated list of routes + net: avoid build bug in skb extension length calculation + net: ethernet: mtk_wed: fix possible NULL pointer dereference in mtk_wed_wo_queue_tx_clean() + net: stmmac: fix incorrect flag check in timestamp interrupt + selftests: add vlan hw filter tests + net: check vlan filter feature in vlan_vids_add_by_dev() and vlan_vids_del_by_dev() + net: hns3: add new maintainer for the HNS3 ethernet driver + net: mana: select PAGE_POOL + net: ks8851: Fix TX stall caused by TX buffer overrun + ice: Fix PF with enabled XDP going no-carrier after reset + ice: alter feature support check for SRIOV and LAG + ice: stop trashing VF VSI aggregator node ID information + mailmap: add entries for Geliang Tang + mptcp: fill in missing MODULE_DESCRIPTION() + mptcp: fix inconsistent state on fastopen race + selftests: mptcp: join: fix subflow_send_ack lookup + net: phy: skip LED triggers on PHYs on SFP modules + bpf: Add missing BPF_LINK_TYPE invocations + ... +",,Merge networking fixes including bpf and WiFi enhancements for current and previous release regressions.,"networking, fixes, bpf",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['xdp like programs', 'socket like programs', 'tc/netfilter like programs']" +b08c8fc0411dce0fc44b78ce4d67f1b67c35c196,b08c8fc0411dce0fc44b78ce4d67f1b67c35c196,Daniel Borkmann,daniel@iogearbox.net,1703079485,Daniel Borkmann,daniel@iogearbox.net,1703165070,4939fe5cb33dab0c69fcb62808f63cc982ce6d7b,fc3a5534e2a8855427403113cbeb54af5837bbe0,"bpf: Re-support uid and gid when mounting bpffs + +For a clean"," conflict-free revert of the token-related patches in commit +d17aff807f84 (""Revert BPF token-related functionality"")","[' the bpf fs commit\n750e785796bb (""bpf: Support uid and gid when mounting bpffs"") was undone\ntemporarily as well.\n\nThis patch manually re-adds the functionality from the original one back\nin 750e785796bb', ' no other functional changes intended.\n\nTesting:\n\n # mount -t bpf -o uid=65534', 'gid=65534 bpffs ./foo\n # ls -la . | grep foo\n drwxrwxrwt 2 nobody nogroup 0 Dec 20 13:16 foo\n # mount -t bpf\n bpffs on /root/foo type bpf (rw', 'relatime', 'uid=65534', 'gid=65534)\n\nAlso', ' passing invalid arguments for uid/gid are properly rejected as expected.\n\nFixes: d17aff807f84 (""Revert BPF token-related functionality"")\nSigned-off-by: Daniel Borkmann \nReviewed-by: Christian Brauner \nCc: Jie Jiang \nCc: Andrii Nakryiko \nCc: linux-fsdevel@vger.kernel.org\nLink: https://lore.kernel.org/bpf/20231220133805.20953-1-daniel@iogearbox.net\n', '']",Re-supporting uid and gid functionality when mounting bpf filesystem with bpffs.,"uid,gid,bpffs",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +74769d810ead7e7af1a481f07a4d890861a6a4cc,74769d810ead7e7af1a481f07a4d890861a6a4cc,Paolo Abeni,pabeni@redhat.com,1703158048,Paolo Abeni,pabeni@redhat.com,1703158049,7145a1990f8133b5d490447ad1022fb6cad2b623,24ab059d2ebd62fdccc43794796f6ffbabe49ebc 117211aa739a926e6555cfea883be84bee6f1695,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-12-21 + +Hi David", hi Jakub,"[' hi Paolo', ' hi Eric', ""\n\nThe following pull-request contains BPF updates for your *net* tree.\n\nWe've added 3 non-merge commits during the last 5 day(s) which contain\na total of 4 files changed"", ' 45 insertions(+).\n\nThe main changes are:\n\n1) Fix a syzkaller splat which triggered an oob issue in bpf_link_show_fdinfo()', '\n from Jiri Olsa.\n\n2) Fix another syzkaller-found issue which triggered a NULL pointer dereference\n in BPF sockmap for unconnected unix sockets', "" from John Fastabend.\n\nbpf-for-netdev\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n bpf: Add missing BPF_LINK_TYPE invocations\n bpf: sockmap"", ' test for unconnected af_unix sock\n bpf: syzkaller found null ptr deref in unix_bpf proto add\n====================\n\nLink: https://lore.kernel.org/r/20231221104844.1374-1-daniel@iogearbox.net\nSigned-off-by: Paolo Abeni \n', '']",Merge branch 'for-netdev' from bpf to merge the latest changes.,"merge, netdev, bpf",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +fc3a5534e2a8855427403113cbeb54af5837bbe0,fc3a5534e2a8855427403113cbeb54af5837bbe0,Mingyi Zhang,zhangmingyi5@huawei.com,1703129987,Daniel Borkmann,daniel@iogearbox.net,1703149542,e47f022a97855c56325801ded581662c275a8d0c,812d8bf87678f77055b575d20636fdbbbf15edaf,"libbpf: Fix NULL pointer dereference in bpf_object__collect_prog_relos + +An issue occurred while reading an ELF file in libbpf.c during fuzzing: + + Program received signal SIGSEGV"," Segmentation fault. + 0x0000000000958e97 in bpf_object.collect_prog_relos () at libbpf.c:4206 + 4206 in libbpf.c + (gdb) bt + #0 0x0000000000958e97 in bpf_object.collect_prog_relos () at libbpf.c:4206 + #1 0x000000000094f9d6 in bpf_object.collect_relos () at libbpf.c:6706 + #2 0x000000000092bef3 in bpf_object_open () at libbpf.c:7437 + #3 0x000000000092c046 in bpf_object.open_mem () at libbpf.c:7497 + #4 0x0000000000924afa in LLVMFuzzerTestOneInput () at fuzz/bpf-object-fuzzer.c:16 + #5 0x000000000060be11 in testblitz_engine::fuzzer::Fuzzer::run_one () + #6 0x000000000087ad92 in tracing::span::Span::in_scope () + #7 0x00000000006078aa in testblitz_engine::fuzzer::util::walkdir () + #8 0x00000000005f3217 in testblitz_engine::entrypoint::main::{{closure}} () + #9 0x00000000005f2601 in main () + (gdb) + +scn_data was null at this code(tools/lib/bpf/src/libbpf.c): + + if (rel->r_offset % BPF_INSN_SZ || rel->r_offset >= scn_data->d_size) { + +The scn_data is derived from the code above: + + scn = elf_sec_by_idx(obj","[' sec_idx);\n\tscn_data = elf_sec_data(obj', ' scn);\n\n\trelo_sec_name = elf_sec_str(obj', ' shdr->sh_name);\n\tsec_name = elf_sec_name(obj', "" scn);\n\tif (!relo_sec_name || !sec_name)// don't check whether scn_data is NULL\n\t\treturn -EINVAL;\n\nIn certain special scenarios"", ' such as reading a malformed ELF file', '\nit is possible that scn_data may be a null pointer\n\nSigned-off-by: Mingyi Zhang \nSigned-off-by: Xin Liu \nSigned-off-by: Changye Wu \nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20231221033947.154564-1-liuxin350@huawei.com\n', '']",Fix a NULL pointer dereference in libbpf during ELF file processing.,"NULL,libbpf,dereference",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +812d8bf87678f77055b575d20636fdbbbf15edaf,812d8bf87678f77055b575d20636fdbbbf15edaf,Alyssa Ross,hi@alyssa.is,1702983804,Daniel Borkmann,daniel@iogearbox.net,1703149515,a5f0ff77c9bc6860c18f6a746118d98655ca4661,92999245102a09ab2645424a9c9a0a5b16fda833,"libbpf: Skip DWARF sections in linker sanity check + +clang can generate (with -g -Wa","--compress-debug-sections) 4-byte +aligned DWARF sections that declare themselves to be 8-byte aligned in +the section header. Since DWARF sections are dropped during linking +anyway","[' just skip running the sanity checks on them.\n\nReported-by: Sergei Trofimovich \nSuggested-by: Andrii Nakryiko \nSigned-off-by: Alyssa Ross \nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Daniel Borkmann \nCloses: https://lore.kernel.org/bpf/ZXcFRJVKbKxtEL5t@nz.home/\nLink: https://lore.kernel.org/bpf/20231219110324.8989-1-hi@alyssa.is\n', '']",The commit modifies libbpf to skip DWARF sections in the linker sanity check.,"libbpf, DWARF, linker",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +92999245102a09ab2645424a9c9a0a5b16fda833,92999245102a09ab2645424a9c9a0a5b16fda833,Alexei Starovoitov,ast@kernel.org,1703107547,Alexei Starovoitov,ast@kernel.org,1703107547,40e8e9008dc0f3a7b2eca992662d5266e13b28d8,32f24938a1fce95fce314c1fa9a72af74588ea6c 69ff403d87be4812571c54b1159e24998414bcab,"Merge branch 'bpf-fix-warning-in-check_obj_size' + +Hou Tao says: + +==================== +bpf: Fix warning in check_obj_size() + +From: Hou Tao + +Hi"," + +The patch set aims to fix the warning in check_obj_size() as reported by +lkp [1]. Patch #1 fixes the warning by selecting target cache for free +request through c->unit_size","[' so the unnecessary adjustment of\nsize_index and the checking in check_obj_size() can be removed. Patch #2\nfixes the test failure in test_bpf_ma after applying patch #1.\n\nPlease see individual patches for more details. And comments are always\nwelcome.\n\n[1]: https://lore.kernel.org/bpf/202310302113.9f8fe705-oliver.sang@intel.com/\n====================\n\nLink: https://lore.kernel.org/r/20231216131052.27621-1-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes a warning in check_obj_size function within the BPF subsystem.,"warning, check_obj_size, fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +69ff403d87be4812571c54b1159e24998414bcab,69ff403d87be4812571c54b1159e24998414bcab,Hou Tao,houtao1@huawei.com,1702732252,Alexei Starovoitov,ast@kernel.org,1703107546,40e8e9008dc0f3a7b2eca992662d5266e13b28d8,7ac5c53e00735d183a0f5e2cfce5eeb6c16319f2,"selftests/bpf: Remove tests for zeroed-array kptr + +bpf_mem_alloc() doesn't support zero-sized allocation"," so removing these +tests from test_bpf_ma test. After the removal","[' there will no definition\nfor bin_data_8', ' so remove 8 from data_sizes array and adjust the index\nof data_btf_ids array in all test cases accordingly.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231216131052.27621-3-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Removed tests for zeroed-array kptr in selftests due to unsupported zero-sized allocations in bpf_mem_alloc().,"zeroed-array kptr, bpf_mem_alloc, selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7ac5c53e00735d183a0f5e2cfce5eeb6c16319f2,7ac5c53e00735d183a0f5e2cfce5eeb6c16319f2,Hou Tao,houtao1@huawei.com,1702732251,Alexei Starovoitov,ast@kernel.org,1703107546,e8e69df257fc7993351a6c3889c8da3687affa6e,32f24938a1fce95fce314c1fa9a72af74588ea6c,"bpf: Use c->unit_size to select target cache during free + +At present"," bpf memory allocator uses check_obj_size() to ensure that +ksize() of allocated pointer is equal with the unit_size of used +bpf_mem_cache. Its purpose is to prevent bpf_mem_free() from selecting +a bpf_mem_cache which has different unit_size compared with the +bpf_mem_cache used for allocation. But as reported by lkp","[' the return\nvalue of ksize() or kmalloc_size_roundup() may change due to slab merge\nand it will lead to the warning report in check_obj_size().\n\nThe reported warning happened as follows:\n(1) in bpf_mem_cache_adjust_size()', ' kmalloc_size_roundup(96) returns the\nobject_size of kmalloc-96 instead of kmalloc-cg-96. The object_size of\nkmalloc-96 is 96', ' so size_index for 96 is not adjusted accordingly.\n(2) the object_size of kmalloc-cg-96 is adjust from 96 to 128 due to\nslab merge in __kmem_cache_alias(). For SLAB', ' SLAB_HWCACHE_ALIGN is\nenabled by default for kmalloc slab', ' so align is 64 and size is 128 for\nkmalloc-cg-96. SLUB has a similar merge logic', ' but its object_size will\nnot be changed', ' because its align is 8 under x86-64.\n(3) when unit_alloc() does kmalloc_node(96', ' __GFP_ACCOUNT', ' node)', '\nksize() returns 128 instead of 96 for the returned pointer.\n(4) the warning in check_obj_size() is triggered.\n\nConsidering the slab merge can happen in anytime (e.g', ' a slab created in\na new module)', ' the following case is also possible: during the\ninitialization of bpf_global_ma', ' there is no slab merge and ksize() for\na 96-bytes object returns 96. But after that a new slab created by a\nkernel module is merged to kmalloc-cg-96 and the object_size of\nkmalloc-cg-96 is adjust from 96 to 128 (which is possible for x86-64 +\nCONFIG_SLAB', ' because its alignment requirement is 64 for 96-bytes slab).\nSo soon or later', ' when bpf_global_ma frees a 96-byte-sized pointer\nwhich is allocated from bpf_mem_cache with unit_size=96', ' bpf_mem_free()\nwill free the pointer through a bpf_mem_cache in which unit_size is 128', '\nbecause the return value of ksize() changes. The warning for the\nmismatch will be triggered again.\n\nA feasible fix is introducing similar APIs compared with ksize() and\nkmalloc_size_roundup() to return the actually-allocated size instead of\nsize which may change due to slab merge', ' but it will introduce\nunnecessary dependency on the implementation details of mm subsystem.\n\nAs for now the pointer of bpf_mem_cache is saved in the 8-bytes area\n(or 4-bytes under 32-bit host) above the returned pointer', ' using\nunit_size in the saved bpf_mem_cache to select the target cache instead\nof inferring the size from the pointer itself. Beside no extra\ndependency on mm subsystem', ' the performance for bpf_mem_free_rcu() is\nalso improved as shown below.\n\nBefore applying the patch', ' the performances of bpf_mem_alloc() and\nbpf_mem_free_rcu() on 8-CPUs VM with one producer are as follows:\n\nkmalloc : alloc 11.69 ± 0.28M/s free 29.58 ± 0.93M/s\npercpu : alloc 14.11 ± 0.52M/s free 14.29 ± 0.99M/s\n\nAfter apply the patch', ' the performance for bpf_mem_free_rcu() increases\n9% and 146% for kmalloc memory and per-cpu memory respectively:\n\nkmalloc: alloc 11.01 ± 0.03M/s free 32.42 ± 0.48M/s\npercpu: alloc 12.84 ± 0.12M/s free 35.24 ± 0.23M/s\n\nAfter the fixes', ' there is no need to adjust size_index to fix the\nmismatch between allocation and free', ' so remove it as well. Also return\nNULL instead of ZERO_SIZE_PTR for zero-sized alloc in bpf_mem_alloc()', '\nbecause there is no bpf_mem_cache pointer saved above ZERO_SIZE_PTR.\n\nFixes: 9077fc228f09 (""bpf: Use kmalloc_size_roundup() to adjust size_index"")\nReported-by: kernel test robot \nCloses: https://lore.kernel.org/bpf/202310302113.9f8fe705-oliver.sang@intel.com\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231216131052.27621-2-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixed unit size selection in bpf_mem_free to match allocation cache unit size.,"unit_size, bpf_mem_cache, allocation",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e77b0236cd0cd1572c6a9b25097b207eab799e74,e77b0236cd0cd1572c6a9b25097b207eab799e74,Ian Rogers,irogers@google.com,1701911813,Arnaldo Carvalho de Melo,acme@redhat.com,1703094970,f5a696d86e7d54804b39f6b817559549ee1545f1,9084952704ba075de28684301ec282b6626b5e7a,"perf maps: Add maps__load_first() + +Avoid bpf_lock_contention_read touching the internal maps data structure +by adding a helper function. As access is done directly on the map in +maps"," hold the read lock to stop it being removed. + +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Andi Kleen +Cc: Athira Rajeev +Cc: Changbin Du +Cc: Colin Ian King +Cc: Dmitrii Dolgov <9erthalion6@gmail.com> +Cc: German Gomez +Cc: Guilherme Amadio +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: James Clark +Cc: Jiri Olsa +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Li Dong +Cc: Liam Howlett +Cc: Mark Rutland +Cc: Masami Hiramatsu +Cc: Miguel Ojeda +Cc: Ming Wang +Cc: Namhyung Kim +Cc: Nick Terrell +Cc: Paolo Bonzini +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Vincent Whitchurch +Cc: Wenyu Liu +Cc: Yang Jihong +Link: https://lore.kernel.org/r/20231207011722.1220634-20-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",[''],Introduces the maps__load_first() helper function to reduce bpf_lock_contention_read's interaction with internal map data structures.,"perf maps, helper function, lock contention",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +32f24938a1fce95fce314c1fa9a72af74588ea6c,32f24938a1fce95fce314c1fa9a72af74588ea6c,Colin Ian King,colin.i.king@gmail.com,1702999387,Daniel Borkmann,daniel@iogearbox.net,1703082539,f9927d4134246e6cdbe7d57f6e9e6e46ef6f034d,441c725ed592cb22f2a82f2827dccd045356cc81,"samples/bpf: Use %lu format specifier for unsigned long values + +Currently %ld format specifiers are being used for unsigned long +values. Fix this by using %lu instead. Cleans up cppcheck warnings: + +warning: %ld in format string (no. 1) requires 'long' but the argument +type is 'unsigned long'. [invalidPrintfArgType_sint] + +Signed-off-by: Colin Ian King +Signed-off-by: Daniel Borkmann +Reviewed-by: Randy Dunlap +Link: https://lore.kernel.org/bpf/20231219152307.368921-1-colin.i.king@gmail.com +",,Fix format specifiers in sample BPF code from %ld to %lu for unsigned long values to resolve cppcheck warnings.,"format specifiers, cppcheck, cleanup",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +441c725ed592cb22f2a82f2827dccd045356cc81,441c725ed592cb22f2a82f2827dccd045356cc81,Hou Tao,houtao1@huawei.com,1702994247,Alexei Starovoitov,ast@kernel.org,1703038931,9cac0236c309a0f046fcdbcc5987e947fa2055e6,85dd93ac6e00adf09fc27e4d2e7f5c9aaf275d38,"selftests/bpf: Close cgrp fd before calling cleanup_cgroup_environment() + +There is error log when htab-mem benchmark completes. The error log +looks as follows: + +$ ./bench htab-mem -d1 +Setting up benchmark 'htab-mem'... +Benchmark 'htab-mem' started. +...... +(cgroup_helpers.c:353: errno: Device or resource busy) umount cgroup2 + +Fix it by closing cgrp fd before invoking cleanup_cgroup_environment(). + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231219135727.2661527-1-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",,Fix htab-mem benchmark error by closing cgroup file descriptor before cleanup.,"htab-mem,close,cgroup",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +85dd93ac6e00adf09fc27e4d2e7f5c9aaf275d38,85dd93ac6e00adf09fc27e4d2e7f5c9aaf275d38,Alexei Starovoitov,ast@kernel.org,1703038007,Alexei Starovoitov,ast@kernel.org,1703038007,48f3b6ea5e3a22eed329e643098b62564b85e910,c337f237291b41b308c80124236876cf66c77906 f0a5056222f2cfa6d40b4c888cb6b01e8569e282,"Merge branch 'enhance-bpf-global-subprogs-with-argument-tags' + +Andrii Nakryiko says: + +==================== +Enhance BPF global subprogs with argument tags + +This patch set adds verifier support for annotating user's global BPF subprog +arguments with few commonly requested annotations"," to improve global subprog +verification experience. + +These tags are: + - ability to annotate a special PTR_TO_CTX argument; + - ability to annotate a generic PTR_TO_MEM as non-null. + +We utilize btf_decl_tag attribute for this and provide two helper macros as +part of bpf_helpers.h in libbpf (patch #8). + +Besides this we also add abilit to pass a pointer to dynptr into global +subprog. This is done based on type name match (struct bpf_dynptr *). This +allows to pass dynptrs into global subprogs","[' for use cases that deal with\nvariable-sized generic memory pointers.\n\nBig chunk of the patch set (patches #1 through #5) are various refactorings to\nmake verifier internals around global subprog validation logic easier to\nextend and support long term', ' eliminating BTF parsing logic duplication', '\nfactoring out argument expectation definitions from BTF parsing', ' etc.\n\nNew functionality is added in patch #6 (ctx and non-null) and patch #7\n(dynptr)', ' extending global subprog checks with awareness for arg tags.\n\nPatch #9 adds simple tests validating each of the added tags and dynptr\nargument passing.\n\nPatch #10 adds a simple negative case for freplace programs to make sure that\ntarget BPF programs with ""unreliable"" BTF func proto cannot be freplaced.\n\nv2->v3:\n - patch #10 improved by checking expected verifier error (Eduard);\nv1->v2:\n - dropped packet args for now (Eduard);\n - added back unreliable=true detection for entry BPF programs (Eduard);\n - improved subprog arg validation (Eduard);\n - switched dynptr arg from tag to just type name based check (Eduard).\n====================\n\nLink: https://lore.kernel.org/r/20231215011334.2307144-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhance BPF subprograms with argument tags for improved global subprogram verification experience.,"BPF, argument, tags",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f0a5056222f2cfa6d40b4c888cb6b01e8569e282,f0a5056222f2cfa6d40b4c888cb6b01e8569e282,Andrii Nakryiko,andrii@kernel.org,1702602814,Alexei Starovoitov,ast@kernel.org,1703038007,48f3b6ea5e3a22eed329e643098b62564b85e910,0a0ffcac92d5b41133c97d260ad1f320572783a5,"selftests/bpf: add freplace of BTF-unreliable main prog test + +Add a test validating that freplace'ing another main (entry) BPF program +fails if the target BPF program doesn't have valid/expected func proto BTF. + +We extend fexit_bpf2bpf test to allow to specify expected log message +for negative test cases (where freplace program is expected to fail to +load). + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231215011334.2307144-11-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,This commit adds a self-test for freplace of BTF-unreliable main BPF programs.,"self-test,BTF-unreliable,freplace",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0a0ffcac92d5b41133c97d260ad1f320572783a5,0a0ffcac92d5b41133c97d260ad1f320572783a5,Andrii Nakryiko,andrii@kernel.org,1702602813,Alexei Starovoitov,ast@kernel.org,1703038007,d3ab441e7f404c20aa86baa9bea9ebc3f4327619,aae9c25dda159045b223ecb471cd0729ccec8285,"selftests/bpf: add global subprog annotation tests + +Add test cases to validate semantics of global subprog argument +annotations: + - non-null pointers; + - context argument; + - const dynptr passing; + - packet pointers (data", metadata,"[' end).\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231215011334.2307144-10-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add test cases for global subprog argument annotations in BPF selftests.,"selftests, annotations, subprog",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['other'] +aae9c25dda159045b223ecb471cd0729ccec8285,aae9c25dda159045b223ecb471cd0729ccec8285,Andrii Nakryiko,andrii@kernel.org,1702602812,Alexei Starovoitov,ast@kernel.org,1703038007,9deb9267269fb33e487df552afa5fa6bd416942b,a64bfe618665ea9c722f922cba8c6e3234eac5ac,"libbpf: add __arg_xxx macros for annotating global func args + +Add a set of __arg_xxx macros which can be used to augment BPF global +subprogs/functions with extra information for use by BPF verifier. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231215011334.2307144-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,The commit adds __arg_xxx macros to annotate global BPF functions for the verifier.,"macros, global functions, verifier",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a64bfe618665ea9c722f922cba8c6e3234eac5ac,a64bfe618665ea9c722f922cba8c6e3234eac5ac,Andrii Nakryiko,andrii@kernel.org,1702602811,Alexei Starovoitov,ast@kernel.org,1703038006,da7ae244a52d141b473dfe288f537fa07d248350,94e1c70a34523b5e1529e4ec508316acc6a26a2b,"bpf: add support for passing dynptr pointer to global subprog + +Add ability to pass a pointer to dynptr into global functions. +This allows to have global subprogs that accept and work with generic +dynptrs that are created by caller. Dynptr argument is detected based on +the name of a struct type"," if it's ""bpf_dynptr""","["" it's assumed to be\na proper dynptr pointer. Both actual struct and forward struct\ndeclaration types are supported.\n\nThis is conceptually exactly the same semantics as\nbpf_user_ringbuf_drain()'s use of dynptr to pass a variable-sized\npointer to ringbuf record. So we heavily rely on CONST_PTR_TO_DYNPTR\nbits of already existing logic in the verifier.\n\nDuring global subprog validation"", ' we mark such CONST_PTR_TO_DYNPTR as\nhaving LOCAL type', "" as that's the most unassuming type of dynptr and it\ndoesn't have any special helpers that can try to free or acquire extra\nreferences (unlike skb"", ' xdp', ' or ringbuf dynptr). So that seems like a safe\n""choice"" to make from correctness standpoint. It\'s still possible to\npass any type of dynptr to such subprog', ' though', ' because generic dynptr\nhelpers', ' like getting data/slice pointers', ' read/write memory copying\nroutines', ' dynptr adjustment and getter routines all work correctly with\nany type of dynptr.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231215011334.2307144-8-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add support for passing dynamic pointer to global subprograms in BPF.,"dynptr, global, subprog",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +94e1c70a34523b5e1529e4ec508316acc6a26a2b,94e1c70a34523b5e1529e4ec508316acc6a26a2b,Andrii Nakryiko,andrii@kernel.org,1702602810,Alexei Starovoitov,ast@kernel.org,1703038006,05e9543579a9017dfd5f38bd6dfbcc95400b4ccb,f18c3d88deedf0defc3e4800341cc7bcaaabcdf9,"bpf: support 'arg:xxx' btf_decl_tag-based hints for global subprog args + +Add support for annotating global BPF subprog arguments to provide more +information about expected semantics of the argument. Currently"," +verifier relies purely on argument's BTF type information","[' and supports\nthree general use cases: scalar', ' pointer-to-context', ' and\npointer-to-fixed-size-memory.\n\nScalar and pointer-to-fixed-mem work well in practice and are quite\nnatural to use. But pointer-to-context is a bit problematic', "" as typical\nBPF users don't realize that they need to use a special type name to\nsignal to verifier that argument is not just some pointer"", ' but actually\na PTR_TO_CTX. Further', ' even if users do know which type to use', ' it is\nlimiting in situations where the same BPF program logic is used across\nfew different program types. Common case is kprobes', ' tracepoints', ' and\nperf_event programs having a helper to send some data over BPF perf\nbuffer. bpf_perf_event_output() requires `ctx` argument', "" and so it's\nquite cumbersome to share such global subprog across few BPF programs of\ndifferent types"", ' necessitating extra static subprog that is context\ntype-agnostic.\n\nLong story short', ' there is a need to go beyond types and allow users to\nadd hints to global subprog arguments to define expectations.\n\nThis patch adds such support for two initial special tags:\n - pointer to context;\n - non-null qualifier for generic pointer arguments.\n\nAll of the above came up in practice already and seem generally useful\nadditions. Non-null qualifier is an often requested feature', ' which\ncurrently has to be worked around by having unnecessary NULL checks\ninside subprogs even if we know that arguments are never NULL. Pointer\nto context was discussed earlier.\n\nAs for implementation', ' we utilize btf_decl_tag attribute and set up an\n""arg:xxx"" convention to specify argument hint. As such:\n - btf_decl_tag(""arg:ctx"") is a PTR_TO_CTX hint;\n - btf_decl_tag(""arg:nonnull"") marks pointer argument as not allowed to\n be NULL', ' making NULL check inside global subprog unnecessary.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231215011334.2307144-7-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add support for BTF declaration tag-based hints for global eBPF subprogram arguments.,"BTF, subprogram, hints",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f18c3d88deedf0defc3e4800341cc7bcaaabcdf9,f18c3d88deedf0defc3e4800341cc7bcaaabcdf9,Andrii Nakryiko,andrii@kernel.org,1702602809,Alexei Starovoitov,ast@kernel.org,1703038006,d57714bbf760073e1542452360d88ebc854d443b,c5a7244759b1eeacc59d0426fb73859afa942d0d,"bpf: reuse subprog argument parsing logic for subprog call checks + +Remove duplicated BTF parsing logic when it comes to subprog call check. +Instead"," use (potentially cached) results of btf_prepare_func_args() to +abstract away expectations of each subprog argument in generic terms +(e.g.","[' ""this is pointer to context""', ' or ""this is a pointer to memory of\nsize X"")', ' and then use those simple high-level argument type\nexpectations to validate actual register states to check if they match\nexpectations.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231215011334.2307144-6-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit removes duplicated BTF parsing logic for subprogram call checks and improves argument parsing.,"BTF, parsing, subprog",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c5a7244759b1eeacc59d0426fb73859afa942d0d,c5a7244759b1eeacc59d0426fb73859afa942d0d,Andrii Nakryiko,andrii@kernel.org,1702602808,Alexei Starovoitov,ast@kernel.org,1703038006,bdc7b9d4e0dc6d2d81f457fdb87a9209b7597d75,e26080d0da87f20222ca6712b65f95a856fadee0,"bpf: move subprog call logic back to verifier.c + +Subprog call logic in btf_check_subprog_call() currently has both a lot +of BTF parsing logic (which is", presumably,"[' what justified putting it\ninto btf.c)', ' but also a bunch of register state checks', ' some of each\nutilize deep verifier logic helpers', ' necessarily exported from\nverifier.c: check_ptr_off_reg()', ' check_func_arg_reg_off()', '\nand check_mem_reg().\n\nGoing forward', ' btf_check_subprog_call() will have a minimum of\nBTF-related logic', ' but will get more internal verifier logic related to\nregister state manipulation. So move it into verifier.c to minimize\namount of verifier-specific logic exposed to btf.c.\n\nWe do this move before refactoring btf_check_func_arg_match() to\npreserve as much history post-refactoring as possible.\n\nNo functional changes.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231215011334.2307144-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit moves subprogram call logic back to verifier.c to separate it from BTF parsing logic.,"subprog, verifier, BTF",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e26080d0da87f20222ca6712b65f95a856fadee0,e26080d0da87f20222ca6712b65f95a856fadee0,Andrii Nakryiko,andrii@kernel.org,1702602807,Alexei Starovoitov,ast@kernel.org,1703038006,9640fff87f7876017c029fdc24cdce42b91e1f93,5eccd2db42d77e3570619c32d39e39bf486607cf,"bpf: prepare btf_prepare_func_args() for handling static subprogs + +Generalize btf_prepare_func_args() to support both global and static +subprogs. We are going to utilize this property in the next patch"," +reusing btf_prepare_func_args() for subprog call logic instead of +reparsing BTF information in a completely separate implementation. + +btf_prepare_func_args() now detects whether subprog is global or static +makes slight logic adjustments for static func cases","[' like not failing\nfatally (-EFAULT) for conditions that are allowable for static subprogs.\n\nSomewhat subtle (but major!) difference is the handling of pointer arguments.\nBoth global and static functions need to handle special context\narguments (which are pointers to predefined type names)', ' but static\nsubprogs give up on any other pointers', ' falling back to marking subprog\nas ""unreliable""', ' disabling the use of BTF type information altogether.\n\nFor global functions', ' though', ' we are assuming that such pointers to\nunrecognized types are just pointers to fixed-sized memory region (or\nerror out if size cannot be established', ' like for `void *` pointers).\n\nThis patch accommodates these small differences and sets up a stage for\nrefactoring in the next patch', ' eliminating a separate BTF-based parsing\nlogic in btf_check_func_arg_match().\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231215011334.2307144-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Generalize btf_prepare_func_args() to support both global and static subprograms for BTF information parsing.,"BTF, subprog, function",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5eccd2db42d77e3570619c32d39e39bf486607cf,5eccd2db42d77e3570619c32d39e39bf486607cf,Andrii Nakryiko,andrii@kernel.org,1702602806,Alexei Starovoitov,ast@kernel.org,1703038006,95ed25214aa13ffbc8b9f4b9733dec093c6f4b53,4ba1d0f23414135e4f426dae4cb5cdc2ce246f89,"bpf: reuse btf_prepare_func_args() check for main program BTF validation + +Instead of btf_check_subprog_arg_match()"," use btf_prepare_func_args() +logic to validate ""trustworthiness"" of main BPF program's BTF information","['\nif it is present.\n\nWe ignored results of original BTF check anyway', ' often times producing\nconfusing and ominously-sounding ""reg type unsupported for arg#0\nfunction"" message', ' which has no apparent effect on program correctness\nand verification process.\n\nAll the -EFAULT returning sanity checks are already performed in\ncheck_btf_info_early()', "" so there is zero reason to have this duplication\nof logic between btf_check_subprog_call() and btf_check_subprog_arg_match().\nDropping btf_check_subprog_arg_match() simplifies\nbtf_check_func_arg_match() further removing `bool processing_call` flag.\n\nOne subtle bit that was done by btf_check_subprog_arg_match() was\npotentially marking main program's BTF as unreliable. We do this\nexplicitly now with a dedicated simple check"", ' preserving the original\nbehavior', ' but now based on well factored btf_prepare_func_args() logic.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231215011334.2307144-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit improves main BPF program BTF validation by reusing btf_prepare_func_args() check.,"BPF,BTF,validation",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4ba1d0f23414135e4f426dae4cb5cdc2ce246f89,4ba1d0f23414135e4f426dae4cb5cdc2ce246f89,Andrii Nakryiko,andrii@kernel.org,1702602805,Alexei Starovoitov,ast@kernel.org,1703038006,afd2128f045eed09c7d826b44ea423136c1f7369,c337f237291b41b308c80124236876cf66c77906,"bpf: abstract away global subprog arg preparation logic from reg state setup + +btf_prepare_func_args() is used to understand expectations and +restrictions on global subprog arguments. But current implementation is +hard to extend"," as it intermixes BTF-based func prototype parsing and +interpretation logic with setting up register state at subprog entry. + +Worse still","[' those registers are not completely set up inside\nbtf_prepare_func_args()', ' requiring some more logic later in\ndo_check_common(). Like calling mark_reg_unknown() and similar\ninitialization operations.\n\nThis intermixing of BTF interpretation and register state setup is\nproblematic. First', ' it causes duplication of BTF parsing logic for global\nsubprog verification (to set up initial state of global subprog) and\nglobal subprog call sites analysis (when we need to check that whatever\nis being passed into global subprog matches expectations)', ' performed in\nbtf_check_subprog_call().\n\nGiven we want to extend global func argument with tags later', ' this\nduplication is problematic. So refactor btf_prepare_func_args() to do\nonly BTF-based func proto and args parsing', ' returning high-level\nargument ""expectations"" only', ' with no regard to specifics of register\nstate. I.e.', "" if it's a context argument"", ' instead of setting register\nstate to PTR_TO_CTX', ' we return ARG_PTR_TO_CTX enum for that argument as\n""an argument specification"" for further processing inside\ndo_check_common(). Similarly for SCALAR arguments', ' PTR_TO_MEM', ' etc.\n\nThis allows to reuse btf_prepare_func_args() in following patches at\nglobal subprog call site analysis time. It also keeps register setup\ncode consistently in one place', ' do_check_common().\n\nBesides all this', ' we cache this argument specs information inside\nenv->subprog_info', ' eliminating the need to redo these potentially\nexpensive BTF traversals', "" especially if BPF program's BTF is big and/or\nthere are lots of global subprog calls.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231215011334.2307144-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",Refactor global subprog argument handling logic for better extensibility in bpf.,"global subprog, argument, extensibility",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c337f237291b41b308c80124236876cf66c77906,c337f237291b41b308c80124236876cf66c77906,Alexei Starovoitov,ast@kernel.org,1703035136,Alexei Starovoitov,ast@kernel.org,1703035136,0d1fa15dd3ee74bc0af37143406f7d19e8a3dddc,1728df7fc11bf09322852ff05e73908244011594 463ea64eb008b7abb63245ed69446b404bf042b1,"Merge branch 'bpf-support-to-track-bpf_jne' + +Menglong Dong says: + +==================== +bpf: support to track BPF_JNE + +For now", the reg bounds is not handled for BPF_JNE case,"[' which can cause\nthe failure of following case:\n\n /* The type of ""a"" is u32 */\n if (a > 0 && a < 100) {\n /* the range of the register for a is [0', ' 99]', ' not [1', ' 99]', '\n * and will cause the following error:\n *\n * invalid zero-sized read\n *\n * as a can be 0.\n */\n bpf_skb_store_bytes(skb', ' xx', ' xx', ' a', ' 0);\n }\n\nIn the code above', ' ""a > 0"" will be compiled to ""if a == 0 goto xxx"". In\nthe TRUE branch', ' the dst_reg will be marked as known to 0. However', ' in the\nfallthrough(FALSE) branch', ' the dst_reg will not be handled', ' which makes\nthe [min', ' max] for a is [0', ' 99]', ' not [1', ' 99].\n\nIn the 1st patch', ' we reduce the range of the dst reg if the src reg is a\nconst and is exactly the edge of the dst reg For BPF_JNE.\n\nIn the 2nd patch', ' we remove reduplicated s32 casting in ""crafted_cases"".\n\nIn the 3rd patch', ' we just activate the test case for this logic in\nrange_cond()', ' which is committed by Andrii in the\ncommit 8863238993e2 (""selftests/bpf: BPF register range bounds tester"").\n\nIn the 4th patch', ' we convert the case above to a testcase and add it to\nverifier_bounds.c.\n\nChanges since v4:\n- add the 2nd patch\n- add ""{U32', ' U32', ' {0', ' U32_MAX}', ' {U32_MAX', ' U32_MAX}}"" that we missed in the\n 3rd patch\n- add some comments to the function that we add in the 4th patch\n- add reg_not_equal_const() in the 4th patch\n\nChanges since v3:\n- do some adjustment to the crafted cases that we added in the 2nd patch\n- add the 3rd patch\n\nChanges since v2:\n- fix a typo in the subject of the 1st patch\n- add some comments to the 1st patch', ' as Eduard advised\n- add some cases to the ""crafted_cases""\n\nChanges since v1:\n- simplify the code in the 1st patch\n- introduce the 2nd patch for the testing\n====================\n\nLink: https://lore.kernel.org/r/20231219134800.1550388-1-menglong8.dong@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add support for tracking BPF_JNE instruction in the eBPF verifier.,"BPF_JNE, verifier, tracking",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +463ea64eb008b7abb63245ed69446b404bf042b1,463ea64eb008b7abb63245ed69446b404bf042b1,Menglong Dong,menglong8.dong@gmail.com,1702993680,Alexei Starovoitov,ast@kernel.org,1703035136,0d1fa15dd3ee74bc0af37143406f7d19e8a3dddc,31d9cc96b1e3b28daf74938cb1233231474bbcf6,"selftests/bpf: add testcase to verifier_bounds.c for BPF_JNE + +Add testcase for the logic that the verifier tracks the BPF_JNE for regs. +The assembly function ""reg_not_equal_const()"" and ""reg_equal_const"" that +we add is exactly converted from the following case: + + u32 a = bpf_get_prandom_u32(); + u64 b = 0; + + a %= 8; + /* the ""a > 0"" here will be optimized to ""a != 0"" */ + if (a > 0) { + /* now the range of a should be [1"," 7] */ + bpf_skb_store_bytes(skb","[' 0', ' &b', ' a', ' 0);\n }\n\nSigned-off-by: Menglong Dong \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231219134800.1550388-5-menglong8.dong@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Added new test case in selftests for BPF_JNE behavior in verifier_bounds.c.,"testcase,BPF_JNE,verifier",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +31d9cc96b1e3b28daf74938cb1233231474bbcf6,31d9cc96b1e3b28daf74938cb1233231474bbcf6,Menglong Dong,menglong8.dong@gmail.com,1702993679,Alexei Starovoitov,ast@kernel.org,1703035135,6d98c10a4b818287d05d9f22f132ad77ca72c650,1de584832375d0dc4234ee406185384a58fb96ac,"selftests/bpf: activate the OP_NE logic in range_cond() + +The edge range checking for the registers is supported by the verifier +now"," so we can activate the extended logic in +tools/testing/selftests/bpf/prog_tests/reg_bounds.c/range_cond() to test +such logic. + +Besides","[' I added some cases to the ""crafted_cases"" array for this logic.\nThese cases are mainly used to test the edge of the src reg and dst reg.\n\nAll reg bounds testings has passed in the SLOW_TESTS mode:\n\n$ export SLOW_TESTS=1 && ./test_progs -t reg_bounds -j\nSummary: 65/18959832 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\nSigned-off-by: Menglong Dong \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231219134800.1550388-4-menglong8.dong@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit activates the OP_NE logic in range_cond() for testing edge range checking in the BPF verifier.,"OP_NE, range_cond, verifier",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1de584832375d0dc4234ee406185384a58fb96ac,1de584832375d0dc4234ee406185384a58fb96ac,Menglong Dong,menglong8.dong@gmail.com,1702993678,Alexei Starovoitov,ast@kernel.org,1703035135,4c5180c94ff7a7c64e7ceaa4e316ca4550a6102b,d028f87517d6775dccff4ddbca2740826f9e53f1,"selftests/bpf: remove reduplicated s32 casting in ""crafted_cases"" + +The ""S32_MIN"" is already defined with s32 casting"," so there is no need +to do it again. + +Signed-off-by: Menglong Dong +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231219134800.1550388-3-menglong8.dong@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Removed redundant s32 casting in selftests/bpf 'crafted_cases'.,"reduplicated,s32,casting",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d028f87517d6775dccff4ddbca2740826f9e53f1,d028f87517d6775dccff4ddbca2740826f9e53f1,Menglong Dong,menglong8.dong@gmail.com,1702993677,Alexei Starovoitov,ast@kernel.org,1703035135,809dc8109b72c5ec379d41ed5ff6b928e74c24ee,1728df7fc11bf09322852ff05e73908244011594,"bpf: make the verifier tracks the ""not equal"" for regs + +We can derive some new information for BPF_JNE in regs_refine_cond_op(). +Take following code for example: + + /* The type of ""a"" is u32 */ + if (a > 0 && a < 100) { + /* the range of the register for a is [0", 99],"[' not [1', ' 99]', '\n * and will cause the following error:\n *\n * invalid zero-sized read\n *\n * as a can be 0.\n */\n bpf_skb_store_bytes(skb', ' xx', ' xx', ' a', ' 0);\n }\n\nIn the code above', ' ""a > 0"" will be compiled to ""jmp xxx if a == 0"". In the\nTRUE branch', ' the dst_reg will be marked as known to 0. However', ' in the\nfallthrough(FALSE) branch', ' the dst_reg will not be handled', ' which makes\nthe [min', ' max] for a is [0', ' 99]', ' not [1', ' 99].\n\nFor BPF_JNE', ' we can reduce the range of the dst reg if the src reg is a\nconst and is exactly the edge of the dst reg.\n\nSigned-off-by: Menglong Dong \nAcked-by: Andrii Nakryiko \nAcked-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/r/20231219134800.1550388-2-menglong8.dong@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Improve the eBPF verifier to track 'not equal' conditions for register refinements.,"verifier, BPF_JNE, refine",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1728df7fc11bf09322852ff05e73908244011594,1728df7fc11bf09322852ff05e73908244011594,Paolo Abeni,pabeni@redhat.com,1703007328,Paolo Abeni,pabeni@redhat.com,1703007328,ea7b744713df95ad4abeba79cb10ef3dbd4c4730,62ed78f3baff396bd928ee77077580c5aa940149 d17aff807f845cf93926c28705216639c7279110,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-12-19 + +Hi David", hi Jakub,"[' hi Paolo', ' hi Eric', ""\n\nThe following pull-request contains BPF updates for your *net-next* tree.\n\nWe've added 2 non-merge commits during the last 1 day(s) which contain\na total of 40 files changed"", ' 642 insertions(+)', ' 2926 deletions(-).\n\nThe main changes are:\n\n1) Revert all of BPF token-related patches for now as per list discussion [0]', '\n from Andrii Nakryiko.\n\n [0] https://lore.kernel.org/bpf/CAHk-=wg7JuFYwGy=GOMbRCtOL+jwSQsdUaBsRWkDVYbxipbM5A@mail.gmail.com\n\n2) Fix a syzbot-reported use-after-free read in nla_find() triggered from\n bpf_skb_get_nlattr_nest() helper', "" from Jakub Kicinski.\n\nbpf-next-for-netdev\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next:\n Revert BPF token-related functionality\n bpf: Use nla_ok() instead of checking nla_len directly\n====================\n\nLink: https://lore.kernel.org/r/20231219170359.11035-1-daniel@iogearbox.net\nSigned-off-by: Paolo Abeni \n"", '']",Merge updates from the bpf-next branch into the main branch.,"merge,bpf-next,update",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d17aff807f845cf93926c28705216639c7279110,d17aff807f845cf93926c28705216639c7279110,Andrii Nakryiko,andrii@kernel.org,1703000255,Andrii Nakryiko,andrii@kernel.org,1703002983,2c7baaedac92384e2d4d083ddebfba920b3390ae,2130c519a401e576647040043cb46d6fdc361dcc,"Revert BPF token-related functionality + +This patch includes the following revert (one conflicting BPF FS +patch and three token patch sets"," represented by merge commits): + - revert 0f5d5454c723 ""Merge branch 'bpf-fs-mount-options-parsing-follow-ups'""; + - revert 750e785796bb ""bpf: Support uid and gid when mounting bpffs""; + - revert 733763285acf ""Merge branch 'bpf-token-support-in-libbpf-s-bpf-object'""; + - revert c35919dcce28 ""Merge branch 'bpf-token-and-bpf-fs-based-delegation'"". + +Link: https://lore.kernel.org/bpf/CAHk-=wg7JuFYwGy=GOMbRCtOL+jwSQsdUaBsRWkDVYbxipbM5A@mail.gmail.com +Signed-off-by: Andrii Nakryiko +",[''],Revert BPF token-related functionality due to conflicting changes in BPF FS and token patch sets.,"revert, BPF token, conflict",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['other'] +2130c519a401e576647040043cb46d6fdc361dcc,2130c519a401e576647040043cb46d6fdc361dcc,Jakub Kicinski,kuba@kernel.org,1702941544,Daniel Borkmann,daniel@iogearbox.net,1702995640,23eabf7884fd7854517ff7632c6667abb290fee5,f7dd48ea76be30666f0614d6a06061185ed38c60,"bpf: Use nla_ok() instead of checking nla_len directly + +nla_len may also be too short to be sane"," in which case after +recent changes nla_len() will return a wrapped value. + +Fixes: 172db56d90d2 (""netlink: Return unsigned value for nla_len()"") +Reported-by: syzbot+f43a23b6e622797c7a28@syzkaller.appspotmail.com +Signed-off-by: Jakub Kicinski +Signed-off-by: Daniel Borkmann +Reviewed-by: Simon Horman +Link: https://lore.kernel.org/bpf/20231218231904.260440-1-kuba@kernel.org +",[''],Fix issue with nlattr length checking by using nla_ok() to ensure valid checks in eBPF.,"nla_ok,nla_len,eBPF",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +624dda101e03c3a3a155d51e37a7bb7607cb760b,624dda101e03c3a3a155d51e37a7bb7607cb760b,Veronika Molnarova,vmolnaro@redhat.com,1702400348,Arnaldo Carvalho de Melo,acme@redhat.com,1702993699,065d9b9d8a84077a3c4c483c0add835734d85429,ab1c247094e323177a578b38f0325bf79f0317ac,"perf archive: Add new option '--all' to pack perf.data with DSOs + +'perf archive' has limited functionality and people from Red Hat Global +Support Services sent a request for a new feature that would pack +perf.data file together with an archive with debug symbols created by +the command 'perf archive' as customers were being confused and often +would forget to send perf.data file with the debug symbols. + +With this patch 'perf archive' now accepts an option '--all' that +generates archive 'perf.all-hostname-date-time.tar.bz2' that holds file +'perf.data' and a sub-tar 'perf.symbols.tar.bz2' with debug symbols. The +functionality of the command 'perf archive' was not changed. + +Committer testing: + +Run 'perf record' on a Intel 14900K machine"," hybrid: + + root@number:~# perf record -a sleep 5s + [ perf record: Woken up 1 times to write data ] + [ perf record: Captured and wrote 4.006 MB perf.data (15427 samples) ] + root@number:~# perf archive --all + Now please run: + + $ tar xvf perf.all-number-20231219-104854.tar.bz2 && tar xvf perf.symbols.tar.bz2 -C ~/.debug + + wherever you need to run 'perf report' on. + root@number:~# + + root@number:~# perf report --header-only + # ======== + # captured on : Tue Dec 19 10:48:48 2023 + # header version : 1 + # data offset : 1008 + # data size : 4199936 + # feat offset : 4200944 + # hostname : number + # os release : 6.6.4-200.fc39.x86_64 + # perf version : 6.7.rc6.gca90f8e17b84 + # arch : x86_64 + # nrcpus online : 28 + # nrcpus avail : 28 + # cpudesc : Intel(R) Core(TM) i7-14700K + # cpuid : GenuineIntel","['6', '183', '1\n # total memory : 32610508 kB\n # cmdline : /home/acme/bin/perf (deleted) record -a sleep 5s\n # event : name = cpu_atom/cycles/P', ' ', ' id = { 5088024', ' 5088025', ' 5088026', ' 5088027', ' 5088028', ' 5088029', ' 5088030', ' 5088031', ' 5088032', ' 5088033', ' 5088034', ' 5088035 }', ' type = 0 (PERF_TYPE_HARDWARE)', ' size>\n # event : name = cpu_core/cycles/P', ' ', ' id = { 5088036', ' 5088037', ' 5088038', ' 5088039', ' 5088040', ' 5088041', ' 5088042', ' 5088043', ' 5088044', ' 5088045', ' 5088046', ' 5088047', ' 5088048', ' 5088049', ' 5088050', ' 5088051 }', '>\n # event : name = dummy:u', ' ', ' id = { 5088052', ' 5088053', ' 5088054', ' 5088055', ' 5088056', ' 5088057', ' 5088058', ' 5088059', ' 5088060', ' 5088061', ' 5088062', ' 5088063', ' 5088064', ' 5088065', ' 5088066', ' 5088067', ' 5088068', ' 50>\n # CPU_TOPOLOGY info available', ' use -I to display\n # NUMA_TOPOLOGY info available', ' use -I to display\n # pmu mappings: cpu_atom = 10', ' cpu_core = 4', ' breakpoint = 5', ' cstate_core = 34', ' cstate_pkg = 35', ' i915 = 14', ' intel_bts = 11', ' intel_pt = 12', ' kprobe = 8', ' msr = 13', ' power = 36', ' software = 1', ' trac>\n # CACHE info available', ' use -I to display\n # time of first sample : 124739.850375\n # time of last sample : 124744.855181\n # sample duration : 5004.806 ms\n # sample duration : 5004.806 ms\n # MEM_TOPOLOGY info available', ' use -I to display\n # bpf_prog_info 2: bpf_prog_7cc47bbf07148bfe_hid_tail_call addr 0xffffffffc0000978 size 113\n # bpf_prog_info 47: bpf_prog_713a545fe0530ce7_restrict_filesystems addr 0xffffffffc0000748 size 305\n # bpf_prog_info 163: bpf_prog_bd834b0730296056 addr 0xffffffffc000df14 size 331\n # bpf_prog_info 258: bpf_prog_ee0e253c78993a24_sd_devices addr 0xffffffffc001fc08 size 264\n # bpf_prog_info 259: bpf_prog_40ddf486530245f5_sd_devices addr 0xffffffffc00204bc size 318\n # bpf_prog_info 260: bpf_prog_6deef7357e7b4530_sd_fw_egress addr 0xffffffffc0020630 size 63\n # bpf_prog_info 261: bpf_prog_6deef7357e7b4530_sd_fw_ingress addr 0xffffffffc0020688 size 63\n # bpf_prog_info 262: bpf_prog_b37200ab714f0e17_sd_devices addr 0xffffffffc002072c size 110\n # bpf_prog_info 263: bpf_prog_b90a282ee45cfed9_sd_devices addr 0xffffffffc00207d8 size 393\n # bpf_prog_info 264: bpf_prog_ee0e253c78993a24_sd_devices addr 0xffffffffc002099c size 264\n # bpf_prog_info 265: bpf_prog_6deef7357e7b4530_sd_fw_egress addr 0xffffffffc0020ad4 size 63\n # bpf_prog_info 266: bpf_prog_6deef7357e7b4530_sd_fw_ingress addr 0xffffffffc0020b50 size 63\n # bpf_prog_info 267: bpf_prog_ee0e253c78993a24_sd_devices addr 0xffffffffc002d98c size 264\n # bpf_prog_info 268: bpf_prog_be31ae23198a0378_sd_devices addr 0xffffffffc002dac8 size 297\n # bpf_prog_info 269: bpf_prog_ccbbf91f3c6979c7_sd_devices addr 0xffffffffc002dc54 size 360\n # bpf_prog_info 270: bpf_prog_3a0ef5414c2f6fca_sd_devices addr 0xffffffffc002dde8 size 456\n # bpf_prog_info 271: bpf_prog_6deef7357e7b4530_sd_fw_egress addr 0xffffffffc0020bd4 size 63\n # bpf_prog_info 272: bpf_prog_6deef7357e7b4530_sd_fw_ingress addr 0xffffffffc00299b4 size 63\n # bpf_prog_info 273: bpf_prog_ee0e253c78993a24_sd_devices addr 0xffffffffc002dfd0 size 264\n # bpf_prog_info 274: bpf_prog_6deef7357e7b4530_sd_fw_egress addr 0xffffffffc0029a3c size 63\n # bpf_prog_info 275: bpf_prog_6deef7357e7b4530_sd_fw_ingress addr 0xffffffffc002d71c size 63\n # bpf_prog_info 276: bpf_prog_6deef7357e7b4530_sd_fw_egress addr 0xffffffffc002d7a8 size 63\n # bpf_prog_info 277: bpf_prog_6deef7357e7b4530_sd_fw_ingress addr 0xffffffffc002e13c size 63\n # bpf_prog_info 278: bpf_prog_6deef7357e7b4530_sd_fw_egress addr 0xffffffffc002e1a8 size 63\n # bpf_prog_info 279: bpf_prog_6deef7357e7b4530_sd_fw_ingress addr 0xffffffffc002e234 size 63\n # bpf_prog_info 280: bpf_prog_be31ae23198a0378_sd_devices addr 0xffffffffc002e2ac size 297\n # bpf_prog_info 281: bpf_prog_6deef7357e7b4530_sd_fw_egress addr 0xffffffffc002e42c size 63\n # bpf_prog_info 282: bpf_prog_6deef7357e7b4530_sd_fw_ingress addr 0xffffffffc002e49c size 63\n # bpf_prog_info 290: bpf_prog_ee0e253c78993a24_sd_devices addr 0xffffffffc0004b18 size 264\n # bpf_prog_info 294: bpf_prog_0b1566e4b83190c5_sd_devices addr 0xffffffffc0004c50 size 360\n # bpf_prog_info 295: bpf_prog_ee0e253c78993a24_sd_devices addr 0xffffffffc001cfc8 size 264\n # bpf_prog_info 296: bpf_prog_6deef7357e7b4530_sd_fw_egress addr 0xffffffffc0013abc size 63\n # bpf_prog_info 297: bpf_prog_6deef7357e7b4530_sd_fw_ingress addr 0xffffffffc0013b24 size 63\n # btf info of id 2\n # btf info of id 52\n # HYBRID_TOPOLOGY info available', ' use -I to display\n # cpu_atom pmu capabilities: branches=32', ' max_precise=3', ' pmu_name=alderlake_hybrid\n # cpu_core pmu capabilities: branches=32', ' max_precise=3', ' pmu_name=alderlake_hybrid\n # intel_pt pmu capabilities: topa_multiple_entries=1', ' psb_cyc=1', ' single_range_output=1', ' mtc_periods=249', ' ip_filtering=1', ' output_subsys=0', ' cr3_filtering=1', ' psb_periods=3f', ' event_trace=0', ' cycl>\n # missing features: TRACING_DATA BRANCH_STACK GROUP_DESC AUXTRACE STAT CLOCKID DIR_FORMAT COMPRESSED CPU_PMU_CAPS CLOCK_DATA\n # ========\n #\n root@number:~#\n\nAnd then transferring it to a ARM64 machine', "" a Libre Computer RK3399-PC:\n\n root@number:~# scp perf.all-number-20231219-104854.tar.bz2 acme@192.168.86.114:.\n acme@192.168.86.114's password:\n perf.all-number-20231219-104854.tar.bz2 100% 145MB 85.4MB/s 00:01\n root@number:~#\n root@number:~# ssh acme@192.168.86.114\n acme@192.168.86.114's password:\n Welcome to Ubuntu 23.04 (GNU/Linux 6.1.68-12200-g1c40dda3081e aarch64)\n\n * Documentation: https://help.ubuntu.com\n * Management: https://landscape.canonical.com\n * Support: https://ubuntu.com/advantage\n Last login: Tue Dec 19 14:53:18 2023 from 192.168.86.42\n acme@roc-rk3399-pc:~$ tar xvf perf.all-number-20231219-104854.tar.bz2 && tar xvf perf.symbols.tar.bz2 -C ~/.debug\n perf.data\n perf.symbols.tar.bz2\n .build-id/ad/acc227f470409213308050b71f664322e2956c\n [kernel.kallsyms]/adacc227f470409213308050b71f664322e2956c/\n [kernel.kallsyms]/adacc227f470409213308050b71f664322e2956c/kallsyms\n [kernel.kallsyms]/adacc227f470409213308050b71f664322e2956c/probes\n .build-id/76/c91f4d62baa06bb52e07e20aba36d21a8f9797\n usr/lib64/libz.so.1.2.13/76c91f4d62baa06bb52e07e20aba36d21a8f9797/\n \n .build-id/09/d7e96bc1e3f599d15ca28b36959124b2d74410\n usr/lib64/librpm_sequoia.so.1/09d7e96bc1e3f599d15ca28b36959124b2d74410/\n usr/lib64/librpm_sequoia.so.1/09d7e96bc1e3f599d15ca28b36959124b2d74410/elf\n usr/lib64/librpm_sequoia.so.1/09d7e96bc1e3f599d15ca28b36959124b2d74410/probes\n acme@roc-rk3399-pc:~$\n acme@roc-rk3399-pc:~$ perf report --stdio | head -40\n # To display the perf.data header info"", "" please use --header/--header-only options.\n #\n # Total Lost Samples: 0\n #\n # Samples: 6K of event 'cpu_atom/cycles/P'\n # Event count (approx.): 4519946621\n #\n # Overhead Command Shared Object Symbol\n # ........ ............... .............................................. .........................................................................................................................................................\n #\n 1.73% swapper [kernel.kallsyms] [k] intel_idle\n 1.43% sh [kernel.kallsyms] [k] next_uptodate_folio\n 0.94% make ld-linux-x86-64.so.2 [.] do_lookup_x\n 0.90% sh ld-linux-x86-64.so.2 [.] do_lookup_x\n 0.82% sh [kernel.kallsyms] [k] perf_event_mmap_output\n 0.74% sh [kernel.kallsyms] [k] filemap_map_pages\n 0.72% sh ld-linux-x86-64.so.2 [.] _dl_relocate_object\n 0.69% cc1 [kernel.kallsyms] [k] clear_page_erms\n 0.61% sh [kernel.kallsyms] [k] unmap_page_range\n 0.56% swapper [kernel.kallsyms] [k] poll_idle\n 0.52% cc1 ld-linux-x86-64.so.2 [.] do_lookup_x\n 0.47% make ld-linux-x86-64.so.2 [.] _dl_relocate_object\n 0.44% cc1 cc1 [.] make_node(tree_code)\n 0.43% sh [kernel.kallsyms] [k] native_irq_return_iret\n 0.38% sh libc.so.6 [.] _int_malloc\n 0.38% cc1 cc1 [.] decl_attributes(tree_node**"", ' tree_node*', ' int', ' tree_node*)\n 0.38% sh [kernel.kallsyms] [k] clear_page_erms\n 0.37% cc1 cc1 [.] ht_lookup_with_hash(ht*', ' unsigned char const*', ' unsigned long', ' unsigned int', ' ht_lookup_option)\n 0.37% make [kernel.kallsyms] [k] perf_event_mmap_output\n 0.37% make ld-linux-x86-64.so.2 [.] _dl_lookup_symbol_x\n 0.35% sh [kernel.kallsyms] [k] _compound_head\n 0.35% make make [.] hash_find_slot\n 0.33% sh libc.so.6 [.] __strlen_avx2\n 0.33% cc1 cc1 [.] ggc_internal_alloc(unsigned long', ' void (*)(void*)', ' unsigned long', ' unsigned long)\n 0.33% sh [kernel.kallsyms] [k] perf_iterate_ctx\n 0.31% make make [.] jhash_string\n 0.31% sh [kernel.kallsyms] [k] page_remove_rmap\n 0.30% cc1 libc.so.6 [.] _int_malloc\n 0.30% make libc.so.6 [.] _int_malloc\n acme@roc-rk3399-pc:~$\n\nSigned-off-by: Veronika Molnarova \nTested-by: Arnaldo Carvalho de Melo \nCc: Michael Petlan \nLink: https://lore.kernel.org/r/20231212165909.14459-1-vmolnaro@redhat.com\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",Add '--all' option to 'perf archive' for packing perf.data with debug symbols.,perf archive option,It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +c49b292d031e385abf764ded32cd953c77e73f2d,c49b292d031e385abf764ded32cd953c77e73f2d,Jakub Kicinski,kuba@kernel.org,1702946767,Jakub Kicinski,kuba@kernel.org,1702946768,3f13748b32a3c273c5315286a3acaf45447a5437,0ee28c9ae042e77100fae2cd82a54750668aafce 8e432e6197cef6250dfd6fdffd41c06613c874ca,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Alexei Starovoitov says: + +==================== +pull-request: bpf-next 2023-12-18 + +This PR is larger than usual and contains changes in various parts +of the kernel. + +The main changes are: + +1) Fix kCFI bugs in BPF"," from Peter Zijlstra. + +End result: all forms of indirect calls from BPF into kernel +and from kernel into BPF work with CFI enabled. This allows BPF +to work with CONFIG_FINEIBT=y. + +2) Introduce BPF token object","[' from Andrii Nakryiko.\n\nIt adds an ability to delegate a subset of BPF features from privileged\ndaemon (e.g.', ' systemd) through special mount options for userns-bound\nBPF FS to a trusted unprivileged application. The design accommodates\nsuggestions from Christian Brauner and Paul Moore.\n\nExample:\n$ sudo mkdir -p /sys/fs/bpf/token\n$ sudo mount -t bpf bpffs /sys/fs/bpf/token \\\n -o delegate_cmds=prog_load:MAP_CREATE \\\n -o delegate_progs=kprobe \\\n -o delegate_attachs=xdp\n\n3) Various verifier improvements and fixes', ' from Andrii Nakryiko', ' Andrei Matei.\n\n - Complete precision tracking support for register spills\n - Fix verification of possibly-zero-sized stack accesses\n - Fix access to uninit stack slots\n - Track aligned STACK_ZERO cases as imprecise spilled registers.\n It improves the verifier ""instructions processed"" metric from single\n digit to 50-60% for some programs.\n - Fix verifier retval logic\n\n4) Support for VLAN tag in XDP hints', ' from Larysa Zaremba.\n\n5) Allocate BPF trampoline via bpf_prog_pack mechanism', ' from Song Liu.\n\nEnd result: better memory utilization and lower I$ miss for calls to BPF\nvia BPF trampoline.\n\n6) Fix race between BPF prog accessing inner map and parallel delete', '\nfrom Hou Tao.\n\n7) Add bpf_xdp_get_xfrm_state() kfunc', ' from Daniel Xu.\n\nIt allows BPF interact with IPSEC infra. The intent is to support\nsoftware RSS (via XDP) for the upcoming ipsec pcpu work.\nExperiments on AWS demonstrate single tunnel pcpu ipsec reaching\nline rate on 100G ENA nics.\n\n8) Expand bpf_cgrp_storage to support cgroup1 non-attach', ' from Yafang Shao.\n\n9) BPF file verification via fsverity', "" from Song Liu.\n\nIt allows BPF progs get fsverity digest.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (164 commits)\n bpf: Ensure precise is reset to false in __mark_reg_const_zero()\n selftests/bpf: Add more uprobe multi fail tests\n bpf: Fail uprobe multi link with negative offset\n selftests/bpf: Test the release of map btf\n s390/bpf: Fix indirect trampoline generation\n selftests/bpf: Temporarily disable dummy_struct_ops test on s390\n x86/cfi"", 'bpf: Fix bpf_exception_cb() signature\n bpf: Fix dtor CFI\n cfi: Add CFI_NOSEAL()\n x86/cfi', 'bpf: Fix bpf_struct_ops CFI\n x86/cfi', 'bpf: Fix bpf_callback_t CFI\n x86/cfi', ""bpf: Fix BPF JIT call\n cfi: Flip headers\n selftests/bpf: Add test for abnormal cnt during multi-kprobe attachment\n selftests/bpf: Don't use libbpf_get_error() in kprobe_multi_test\n selftests/bpf: Add test for abnormal cnt during multi-uprobe attachment\n bpf: Limit the number of kprobes when attaching program to multiple kprobes\n bpf: Limit the number of uprobes when attaching program to multiple uprobes\n bpf: xdp: Register generic_kfunc_set with XDP programs\n selftests/bpf: utilize string values for delegate_xxx mount options\n ...\n====================\n\nLink: https://lore.kernel.org/r/20231219000520.34178-1-alexei.starovoitov@gmail.com\nSigned-off-by: Jakub Kicinski \n"", '']",The commit merges changes including a fix for kCFI bugs and the introduction of the BPF token object.,"kCFI, BPF, token",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8e432e6197cef6250dfd6fdffd41c06613c874ca,8e432e6197cef6250dfd6fdffd41c06613c874ca,Andrii Nakryiko,andrii@kernel.org,1702920961,Daniel Borkmann,daniel@iogearbox.net,1702940061,441e472f39005b2d9a16b69dba9b6b40d726f322,6079ae6376181b49c9e4d65ef9fe954cca4974bd,"bpf: Ensure precise is reset to false in __mark_reg_const_zero() + +It is safe to always start with imprecise SCALAR_VALUE register. +Previously __mark_reg_const_zero() relied on caller to reset precise +mark"," but it's very error prone and we already missed it in a few +places. So instead make __mark_reg_const_zero() reset precision always","[""\nas it's a safe default for SCALAR_VALUE. Explanation is basically the\nsame as for why we are resetting (or rather not setting) precision in\ncurrent state. If necessary"", ' precision propagation will set it to\nprecise correctly.\n\nAs such', ' also remove a big comment about forward precision propagation\nin mark_reg_stack_read() and avoid unnecessarily setting precision to\ntrue after reading from STACK_ZERO stack. Again', ' precision propagation\nwill correctly handle this', ' if that SCALAR_VALUE register will ever be\nneeded to be precise.\n\nReported-by: Maxim Mikityanskiy \nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nAcked-by: Maxim Mikityanskiy \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20231218173601.53047-1-andrii@kernel.org\n', '']",The commit ensures precision is reset to false in __mark_reg_const_zero() to avoid error prone reliance on callers.,"precision,register,reset",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6079ae6376181b49c9e4d65ef9fe954cca4974bd,6079ae6376181b49c9e4d65ef9fe954cca4974bd,Andrii Nakryiko,andrii@kernel.org,1702921891,Andrii Nakryiko,andrii@kernel.org,1702921937,ac054e373cabd2fb9288318c7d58c34489a60c4c,e58aac1a9a179fa9dab3025ef955cdb548c439f2 f17d1a18a3dd6cc4b38a5226b0acbbad3f2063ae,"Merge branch 'bpf-add-check-for-negative-uprobe-multi-offset' + +Jiri Olsa says: + +==================== +bpf: Add check for negative uprobe multi offset + +hi"," +adding the check for negative offset for uprobe multi link. + +v2 changes: +- add more failure checks [Alan] +- move the offset retrieval/check up in the loop to be done earlier [Song] + +thanks","['\njirka\n---\n====================\n\nLink: https://lore.kernel.org/r/20231217215538.3361991-1-jolsa@kernel.org\nSigned-off-by: Andrii Nakryiko \n', '']",Add a check for negative offset in uprobe multi-links in eBPF.,"check,offset,uprobe",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +f17d1a18a3dd6cc4b38a5226b0acbbad3f2063ae,f17d1a18a3dd6cc4b38a5226b0acbbad3f2063ae,Jiri Olsa,jolsa@kernel.org,1702850138,Andrii Nakryiko,andrii@kernel.org,1702921910,ac054e373cabd2fb9288318c7d58c34489a60c4c,3983c00281d96af2ba611254d679107b5c390627,"selftests/bpf: Add more uprobe multi fail tests + +We fail to create uprobe if we pass negative offset. Add more tests +validating kernel-side error checking code. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Song Liu +Link: https://lore.kernel.org/bpf/20231217215538.3361991-3-jolsa@kernel.org +",,Add additional uprobe multi fail tests to ensure kernel-side error checking for negative offsets.,"uprobe,multi fail,tests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +3983c00281d96af2ba611254d679107b5c390627,3983c00281d96af2ba611254d679107b5c390627,Jiri Olsa,jolsa@kernel.org,1702850137,Andrii Nakryiko,andrii@kernel.org,1702921890,61813969a52053d327d24a86eb8dac978853f4a0,e58aac1a9a179fa9dab3025ef955cdb548c439f2,"bpf: Fail uprobe multi link with negative offset + +Currently the __uprobe_register will return 0 (success) when called with +negative offset. The reason is that the call to register_for_each_vma and +then build_map_info won't return error for negative offset. They just won't +do anything - no matching vma is found so there's no registered breakpoint +for the uprobe. + +I don't think we can change the behaviour of __uprobe_register and fail +for negative uprobe offset"," because apps might depend on that already. + +But I think we can still make the change and check for it on bpf multi +link syscall level. + +Also moving the __get_user call and check for the offsets to the top of +loop","[' to fail early without extra __get_user calls for ref_ctr_offset\nand cookie arrays.\n\nSigned-off-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nAcked-by: Song Liu \nLink: https://lore.kernel.org/bpf/20231217215538.3361991-2-jolsa@kernel.org\n', '']",The commit enforces error checks for negative offsets in uprobe multi link syscalls to prevent unnoticed success responses.,"uprobe,negative offset,syscall",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['kprobe/uprobe/ftrace like programs'] +e58aac1a9a179fa9dab3025ef955cdb548c439f2,e58aac1a9a179fa9dab3025ef955cdb548c439f2,Hou Tao,houtao1@huawei.com,1702698910,Daniel Borkmann,daniel@iogearbox.net,1702919749,b65884e81cb7e69ee23755fde1b1c9a34ac2582e,0c970ed2f87c058fe3ddeb4d7d8f64f72cf41d7a,"selftests/bpf: Test the release of map btf + +When there is bpf_list_head or bpf_rb_root field in map value"," the free +of map btf and the free of map value may run concurrently and there may +be use-after-free problem","[' so add two test cases to demonstrate it. And\nthe use-after-free problem can been easily reproduced by using bpf_next\ntree and a KASAN-enabled kernel.\n\nThe first test case tests the racing between the free of map btf and the\nfree of array map. It constructs the racing by releasing the array map in\nthe end after other ref-counter of map btf has been released. To delay\nthe free of array map and make it be invoked after btf_free_rcu() is\ninvoked', ' it stresses system_unbound_wq by closing multiple percpu array\nmaps before it closes the array map.\n\nThe second case tests the racing between the free of map btf and the\nfree of inner map. Beside using the similar method as the first one\ndoes', ' it uses bpf_map_delete_elem() to delete the inner map and to defer\nthe release of inner map after one RCU grace period.\n\nThe reason for using two skeletons is to prevent the release of outer\nmap and inner map in map_in_map_btf.c interfering the release of bpf\nmap in normal_map_btf.c.\n\nSigned-off-by: Hou Tao \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20231216035510.4030605-1-houtao@huaweicloud.com\n', '']",Add test cases to check for use-after-free issues in map BTF with bpf_list_head and bpf_rb_root fields.,selftests use-after-free map,It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0c970ed2f87c058fe3ddeb4d7d8f64f72cf41d7a,0c970ed2f87c058fe3ddeb4d7d8f64f72cf41d7a,Alexei Starovoitov,ast@kernel.org,1702687549,Daniel Borkmann,daniel@iogearbox.net,1702897237,fbc54c4fe55753c3fb80e6832782007a0f6ef186,42d45c45624a098a9fdc477c7a8b86167f948c77,"s390/bpf: Fix indirect trampoline generation + +The func_addr used to be NULL for indirect trampolines used by struct_ops. +Now func_addr is a valid function pointer. +Hence use BPF_TRAMP_F_INDIRECT flag to detect such condition. + +Fixes: 2cd3e3772e41 (""x86/cfi","bpf: Fix bpf_struct_ops CFI"") +Signed-off-by: Alexei Starovoitov +Signed-off-by: Daniel Borkmann +Reviewed-by: Ilya Leoshkevich +Link: https://lore.kernel.org/bpf/20231216004549.78355-1-alexei.starovoitov@gmail.com +",[''],Fixes indirect trampoline generation for struct_ops in BPF on s390 architecture.,"indirect, trampoline, struct_ops",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +117211aa739a926e6555cfea883be84bee6f1695,117211aa739a926e6555cfea883be84bee6f1695,Jiri Olsa,jolsa@kernel.org,1702681502,Andrii Nakryiko,andrii@kernel.org,1702686852,e08e8f3efb34dec198c2549985e1a22fcf40a689,2f2fee2bf74a7e31d06fc6cb7ba2bd4dd7753c99,"bpf: Add missing BPF_LINK_TYPE invocations + +Pengfei Xu reported [1] Syzkaller/KASAN issue found in bpf_link_show_fdinfo. + +The reason is missing BPF_LINK_TYPE invocation for uprobe multi +link and for several other links"," adding that. + +[1] https://lore.kernel.org/bpf/ZXptoKRSLspnk2ie@xpf.sh.intel.com/ + +Fixes: 89ae89f53d20 (""bpf: Add multi uprobe link"") +Fixes: e420bed02507 (""bpf: Add fd-based tcx multi-prog infra with link support"") +Fixes: 84601d6ee68a (""bpf: add bpf_link support for BPF_NETFILTER programs"") +Fixes: 35dfaad7188c (""netkit","[' bpf: Add bpf programmable net device"")\nReported-by: Pengfei Xu \nSigned-off-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nTested-by: Pengfei Xu \nAcked-by: Hou Tao \nLink: https://lore.kernel.org/bpf/20231215230502.2769743-1-jolsa@kernel.org\n', '']",Add missing BPF_LINK_TYPE invocations in bpf_link_show_fdinfo to fix Syzkaller/KASAN issue.,"BPF_LINK_TYPE, uprobe, Syzkaller",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['kprobe/uprobe/ftrace like programs', 'tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +42d45c45624a098a9fdc477c7a8b86167f948c77,42d45c45624a098a9fdc477c7a8b86167f948c77,Alexei Starovoitov,ast@kernel.org,1702686505,Alexei Starovoitov,ast@kernel.org,1702686505,8be166cc613e6e2675ffea9383fb21e563f36002,3c302e14bd9d7698ea24885a7eee2b44c1a014be,"selftests/bpf: Temporarily disable dummy_struct_ops test on s390 + +Temporarily disable dummy_struct_ops test on s390. +The breakage is likely due to +commit 2cd3e3772e41 (""x86/cfi","bpf: Fix bpf_struct_ops CFI""). + +Signed-off-by: Alexei Starovoitov +",[''],Temporarily disables dummy_struct_ops test on s390 architecture due to recent breakage.,"selftests,bpf,s390",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3c302e14bd9d7698ea24885a7eee2b44c1a014be,3c302e14bd9d7698ea24885a7eee2b44c1a014be,Alexei Starovoitov,ast@kernel.org,1702668291,Alexei Starovoitov,ast@kernel.org,1702686356,4599c7e80eb113dcf3bda5ea435e8c26b7e2a3bf,1467affd16b236fc86e1b8ec5eaa147e104cd2a6 852486b35f344887786d63250946dd921a05d7e8,"Merge branch 'x86-cfi-bpf-fix-cfi-vs-ebpf' + +Peter Zijlstra says: + +==================== +x86/cfi","bpf: Fix CFI vs eBPF + +Hi! + +What started with the simple observation that bpf_dispatcher_*_func() was +broken for calling CFI functions with a __nocfi calling context for FineIBT +ended up with a complete BPF wide CFI fixup. + +With these changes on the BPF selftest suite passes without crashing -- there's +still a few failures","[' but Alexei has graciously offered to look into those.\n\n(Alexei', ' I have presumed your SoB on the very last patch', ' please update\nas you see fit)\n\nChanges since v2 are numerous but include:\n - cfi_get_offset() -- as a means to communicate the offset (ast)\n - 5 new patches fixing various BPF internals to be CFI clean\n\nNote: it *might* be possible to merge the\nbpf_bpf_tcp_ca.c:unsupported_ops[] thing into the CFI stubs', ' as is\nget_info will have a NULL stub', ' unlike the others.\n---\n arch/riscv/include/asm/cfi.h | 3 +-\n arch/riscv/kernel/cfi.c | 2 +-\n arch/x86/include/asm/cfi.h | 126 +++++++++++++++++++++++++++++++++++++-\n arch/x86/kernel/alternative.c | 87 +++++++++++++++++++++++---\n arch/x86/kernel/cfi.c | 4 +-\n arch/x86/net/bpf_jit_comp.c | 134 +++++++++++++++++++++++++++++++++++------\n include/asm-generic/Kbuild | 1 +\n include/linux/bpf.h | 27 ++++++++-\n include/linux/cfi.h | 12 ++++\n kernel/bpf/bpf_struct_ops.c | 16 ++---\n kernel/bpf/core.c | 25 ++++++++\n kernel/bpf/cpumask.c | 8 ++-\n kernel/bpf/helpers.c | 18 +++++-\n net/bpf/bpf_dummy_struct_ops.c | 31 +++++++++-\n net/bpf/test_run.c | 15 ++++-\n net/ipv4/bpf_tcp_ca.c | 69 +++++++++++++++++++++\n 16 files changed', ' 528 insertions(+)', ' 50 deletions(-)\n====================\n\nLink: https://lore.kernel.org/r/20231215091216.135791411@infradead.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit fixes a compatibility issue between Control Flow Integrity (CFI) and eBPF in the x86 architecture.,"CFI,eBPF,x86",It's a bug fix.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +852486b35f344887786d63250946dd921a05d7e8,852486b35f344887786d63250946dd921a05d7e8,Alexei Starovoitov,alexei.starovoitov@gmail.com,1702631543,Alexei Starovoitov,ast@kernel.org,1702686355,4599c7e80eb113dcf3bda5ea435e8c26b7e2a3bf,e4c00339891c074c76f626ac82981963cbba5332,x86/cfi,"bpf: Fix bpf_exception_cb() signature + +As per the earlier patches","[' BPF sub-programs have bpf_callback_t\nsignature and CFI expects callers to have matching signature. This is\nviolated by bpf_prog_aux::bpf_exception_cb().\n\n[peterz: Changelog]\nReported-by: Peter Zijlstra \nSigned-off-by: Alexei Starovoitov \nSigned-off-by: Peter Zijlstra (Intel) \nLink: https://lkml.kernel.org/r/CAADnVQ+Z7UcXXBBhMubhcMM=R-dExk-uHtfOLtoLxQ1XxEpqEA@mail.gmail.com\nLink: https://lore.kernel.org/r/20231215092707.910319166@infradead.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit fixes the signature of the bpf_exception_cb function.,"bpf_exception_cb,fix,signature",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e4c00339891c074c76f626ac82981963cbba5332,e4c00339891c074c76f626ac82981963cbba5332,Peter Zijlstra,peterz@infradead.org,1702631542,Alexei Starovoitov,ast@kernel.org,1702686355,4f2231383a2360a9fa0d7e8841343c8c69e2b164,e9d13b9d2f99ccf7afeab490d97eaa5ac9846598,"bpf: Fix dtor CFI + +Ensure the various dtor functions match their prototype and retain +their CFI signatures", since they don't have their address taken,"[' they\nare prone to not getting CFI', ' making them impossible to call\nindirectly.\n\nSigned-off-by: Peter Zijlstra (Intel) \nLink: https://lore.kernel.org/r/20231215092707.799451071@infradead.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit fixes function prototypes to retain CFI signatures for destructor functions.,"Fix, CFI, dtor",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2cd3e3772e41377f32d6eea643e0590774e9187c,2cd3e3772e41377f32d6eea643e0590774e9187c,Peter Zijlstra,peterz@infradead.org,1702631540,Alexei Starovoitov,ast@kernel.org,1702686355,6731bd8786a091dbf2e2447952df2b5d908efec6,e72d88d18df4e03c80e64c2535f70c64f1dc6fc1,x86/cfi,"bpf: Fix bpf_struct_ops CFI + +BPF struct_ops uses __arch_prepare_bpf_trampoline() to write +trampolines for indirect function calls. These tramplines much have +matching CFI. + +In order to obtain the correct CFI hash for the various methods","[' add a\nmatching structure that contains stub functions', ' the compiler will\ngenerate correct CFI which we can pilfer for the trampolines.\n\nSigned-off-by: Peter Zijlstra (Intel) \nLink: https://lore.kernel.org/r/20231215092707.566977112@infradead.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes the bpf_struct_ops trampoline CFI to ensure correct indirect function call handling in x86 architecture.,"bpf_struct_ops,Cfi,trampolines",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e72d88d18df4e03c80e64c2535f70c64f1dc6fc1,e72d88d18df4e03c80e64c2535f70c64f1dc6fc1,Peter Zijlstra,peterz@infradead.org,1702631539,Alexei Starovoitov,ast@kernel.org,1702686355,b40a94832096c09289083677044e0d6c61601927,4f9087f16651aca4a5f32da840a53f6660f0579a,x86/cfi,"bpf: Fix bpf_callback_t CFI + +Where the main BPF program is expected to match bpf_func_t","['\nsub-programs are expected to match bpf_callback_t.\n\nThis fixes things like:\n\ntools/testing/selftests/bpf/progs/bloom_filter_bench.c:\n\n bpf_for_each_map_elem(&array_map', ' bloom_callback', ' &data', ' 0);\n\nSigned-off-by: Peter Zijlstra (Intel) \nLink: https://lore.kernel.org/r/20231215092707.451956710@infradead.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes a CFI issue in x86 architecture related to bpf_callback_t and bpf_func_t compatibility.,"x86, CFI, compatibility",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['other'] +4f9087f16651aca4a5f32da840a53f6660f0579a,4f9087f16651aca4a5f32da840a53f6660f0579a,Peter Zijlstra,peterz@infradead.org,1702631538,Alexei Starovoitov,ast@kernel.org,1702686355,4aae945ff81a7447ed40741a7fc3fce4fbf6fc65,4382159696c9af67ee047ed55f2dbf05480f52f6,x86/cfi,"bpf: Fix BPF JIT call + +The current BPF call convention is __nocfi","[' except when it calls !JIT things', '\nthen it calls regular C functions.\n\nIt so happens that with FineIBT the __nocfi and C calling conventions are\nincompatible. Specifically __nocfi will call at func+0', ' while FineIBT will have\nendbr-poison there', ' which is not a valid indirect target. Causing #CP.\n\nNotably this only triggers on IBT enabled hardware', "" which is probably why this\nhasn't been reported (also"", ' most people will have JIT on anyway).\n\nImplement proper CFI prologues for the BPF JIT codegen and drop __nocfi for\nx86.\n\nSigned-off-by: Peter Zijlstra (Intel) \nLink: https://lore.kernel.org/r/20231215092707.345270396@infradead.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes BPF JIT call on x86 architecture using current BPF call convention.,"BPF,JIT,x86",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1467affd16b236fc86e1b8ec5eaa147e104cd2a6,1467affd16b236fc86e1b8ec5eaa147e104cd2a6,Hou Tao,houtao1@huawei.com,1702634828,Daniel Borkmann,daniel@iogearbox.net,1702677295,4f635246979dbe7796567907dcb483e89297430e,00cdcd2900bdb9190d1e75438b39cef74cd99232,"selftests/bpf: Add test for abnormal cnt during multi-kprobe attachment + +If an abnormally huge cnt is used for multi-kprobes attachment"," the +following warning will be reported: + + ------------[ cut here ]------------ + WARNING: CPU: 1 PID: 392 at mm/util.c:632 kvmalloc_node+0xd9/0xe0 + Modules linked in: bpf_testmod(O) + CPU: 1 PID: 392 Comm: test_progs Tainted: G ...... 6.7.0-rc3+ #32 + Hardware name: QEMU Standard PC (i440FX + PIIX","[' 1996)\n ......\n RIP: 0010:kvmalloc_node+0xd9/0xe0\n ? __warn+0x89/0x150\n ? kvmalloc_node+0xd9/0xe0\n bpf_kprobe_multi_link_attach+0x87/0x670\n __sys_bpf+0x2a28/0x2bc0\n __x64_sys_bpf+0x1a/0x30\n do_syscall_64+0x36/0xb0\n entry_SYSCALL_64_after_hwframe+0x6e/0x76\n RIP: 0033:0x7fbe067f0e0d\n ......\n \n ---[ end trace 0000000000000000 ]---\n\nSo add a test to ensure the warning is fixed.\n\nSigned-off-by: Hou Tao \nSigned-off-by: Daniel Borkmann \nAcked-by: Jiri Olsa \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231215100708.2265609-6-houtao@huaweicloud.com\n', '']",Add a new test for handling abnormal count during multi-kprobe attachment in eBPF selftests.,"selftests,bpf,multi-kprobe",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +00cdcd2900bdb9190d1e75438b39cef74cd99232,00cdcd2900bdb9190d1e75438b39cef74cd99232,Hou Tao,houtao1@huawei.com,1702634827,Daniel Borkmann,daniel@iogearbox.net,1702677295,7c7977496850c4fa2e9bc22f18599886a98ee1cb,0d83786f5661154d015b498a3d23d4c37e30f6ef,"selftests/bpf: Don't use libbpf_get_error() in kprobe_multi_test + +Since libbpf v1.0"," libbpf doesn't return error code embedded into the +pointer iteself","[' libbpf_get_error() is deprecated and it is basically\nthe same as using -errno directly.\n\nSo replace the invocations of libbpf_get_error() by -errno in\nkprobe_multi_test. For libbpf_get_error() in test_attach_api_fails()', '\nsaving -errno before invoking ASSERT_xx() macros just in case that\nerrno is overwritten by these macros. However', ' the invocation of\nlibbpf_get_error() in get_syms() should be kept intact', ' because\nhashmap__new() still returns a pointer with embedded error code.\n\nSigned-off-by: Hou Tao \nSigned-off-by: Daniel Borkmann \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231215100708.2265609-5-houtao@huaweicloud.com\n', '']",Update selftests/bpf to avoid using libbpf_get_error() in kprobe_multi_test due to changes in libbpf v1.0.,"selftests,bpf,libbpf",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0d83786f5661154d015b498a3d23d4c37e30f6ef,0d83786f5661154d015b498a3d23d4c37e30f6ef,Hou Tao,houtao1@huawei.com,1702634826,Daniel Borkmann,daniel@iogearbox.net,1702677295,d118f6335c36c98b0517901f93ee471125ee8bdc,d6d1e6c17cab2dcb7b8530c599f00e7de906d380,"selftests/bpf: Add test for abnormal cnt during multi-uprobe attachment + +If an abnormally huge cnt is used for multi-uprobes attachment"," the +following warning will be reported: + + ------------[ cut here ]------------ + WARNING: CPU: 7 PID: 406 at mm/util.c:632 kvmalloc_node+0xd9/0xe0 + Modules linked in: bpf_testmod(O) + CPU: 7 PID: 406 Comm: test_progs Tainted: G ...... 6.7.0-rc3+ #32 + Hardware name: QEMU Standard PC (i440FX + PIIX","[' 1996) ......\n RIP: 0010:kvmalloc_node+0xd9/0xe0\n ......\n Call Trace:\n \n ? __warn+0x89/0x150\n ? kvmalloc_node+0xd9/0xe0\n bpf_uprobe_multi_link_attach+0x14a/0x480\n __sys_bpf+0x14a9/0x2bc0\n do_syscall_64+0x36/0xb0\n entry_SYSCALL_64_after_hwframe+0x6e/0x76\n ......\n \n ---[ end trace 0000000000000000 ]---\n\nSo add a test to ensure the warning is fixed.\n\nSigned-off-by: Hou Tao \nSigned-off-by: Daniel Borkmann \nAcked-by: Jiri Olsa \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231215100708.2265609-4-houtao@huaweicloud.com\n', '']",Add a selftest for detecting abnormal cnt during multi-uprobe attachment in eBPF.,"selftest, multi-uprobe, abnormal",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +d6d1e6c17cab2dcb7b8530c599f00e7de906d380,d6d1e6c17cab2dcb7b8530c599f00e7de906d380,Hou Tao,houtao1@huawei.com,1702634825,Daniel Borkmann,daniel@iogearbox.net,1702677295,8ec04ed42b761af3105deb4660c8ca566664e2ca,8b2efe51ba85ca83460941672afac6fca4199df6,"bpf: Limit the number of kprobes when attaching program to multiple kprobes + +An abnormally big cnt may also be assigned to kprobe_multi.cnt when +attaching multiple kprobes. It will trigger the following warning in +kvmalloc_node(): + + if (unlikely(size > INT_MAX)) { + WARN_ON_ONCE(!(flags & __GFP_NOWARN)); + return NULL; + } + +Fix the warning by limiting the maximal number of kprobes in +bpf_kprobe_multi_link_attach(). If the number of kprobes is greater than +MAX_KPROBE_MULTI_CNT"," the attachment will fail and return -E2BIG. + +Fixes: 0dcac2725406 (""bpf: Add multi kprobe link"") +Signed-off-by: Hou Tao +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231215100708.2265609-3-houtao@huaweicloud.com +",[''],Fix a warning by limiting the number of kprobes when attaching programs to multiple kprobes.,"kprobes, warning, limit",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +8b2efe51ba85ca83460941672afac6fca4199df6,8b2efe51ba85ca83460941672afac6fca4199df6,Hou Tao,houtao1@huawei.com,1702634824,Daniel Borkmann,daniel@iogearbox.net,1702677286,55651e550cb7ee3f6980a5edd33bf5ff6bf92181,7489723c2e26504573dbb49b66bbc59092840008,"bpf: Limit the number of uprobes when attaching program to multiple uprobes + +An abnormally big cnt may be passed to link_create.uprobe_multi.cnt"," +and it will trigger the following warning in kvmalloc_node(): + + if (unlikely(size > INT_MAX)) { + WARN_ON_ONCE(!(flags & __GFP_NOWARN)); + return NULL; + } + +Fix the warning by limiting the maximal number of uprobes in +bpf_uprobe_multi_link_attach(). If the number of uprobes is greater than +MAX_UPROBE_MULTI_CNT","[' the attachment will return -E2BIG.\n\nFixes: 89ae89f53d20 (""bpf: Add multi uprobe link"")\nReported-by: Xingwei Lee \nSigned-off-by: Hou Tao \nSigned-off-by: Daniel Borkmann \nAcked-by: Jiri Olsa \nAcked-by: Andrii Nakryiko \nCloses: https://lore.kernel.org/bpf/CABOYnLwwJY=yFAGie59LFsUsBAgHfroVqbzZ5edAXbFE3YiNVA@mail.gmail.com\nLink: https://lore.kernel.org/bpf/20231215100708.2265609-2-houtao@huaweicloud.com\n', '']",Fix a kvmalloc_node warning by limiting maximally allowed uprobes in bpf_uprobe_multi_link_attach.,"uprobes, warning, limit",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +ff6d413b0b59466e5acf2e42f294b1842ae130a1,ff6d413b0b59466e5acf2e42f294b1842ae130a1,Kees Cook,keescook@chromium.org,1702415860,Greg Kroah-Hartman,gregkh@linuxfoundation.org,1702657510,e0a0a6325a1a2903b0c1865c8158c3b477f457e8,5b56bf5cdb8b7c989055fe4d73fe3f409427d1d5,"kernfs: Convert kernfs_path_from_node_locked() from strlcpy() to strscpy() + +One of the last remaining users of strlcpy() in the kernel is +kernfs_path_from_node_locked()"," which passes back the problematic ""length +we _would_ have copied"" return value to indicate truncation. Convert the +chain of all callers to use the negative return value (some of which +already doing this explicitly). All callers were already also checking +for negative return values","[' so the risk to missed checks looks very low.\n\nIn this analysis', ' it was found that cgroup1_release_agent() actually\ndidn\'t handle the ""too large"" condition', "" so this is technically also a\nbug fix. :)\n\nHere's the chain of callers"", ' and resolution identifying each one as now\nhandling the correct return value:\n\nkernfs_path_from_node_locked()\n kernfs_path_from_node()\n pr_cont_kernfs_path()\n returns void\n kernfs_path()\n sysfs_warn_dup()\n return value ignored\n cgroup_path()\n blkg_path()\n bfq_bic_update_cgroup()\n return value ignored\n TRACE_IOCG_PATH()\n return value ignored\n TRACE_CGROUP_PATH()\n return value ignored\n perf_event_cgroup()\n return value ignored\n task_group_path()\n return value ignored\n damon_sysfs_memcg_path_eq()\n return value ignored\n get_mm_memcg_path()\n return value ignored\n lru_gen_seq_show()\n return value ignored\n cgroup_path_from_kernfs_id()\n return value ignored\n cgroup_show_path()\n already converted ""too large"" error to negative value\n cgroup_path_ns_locked()\n cgroup_path_ns()\n bpf_iter_cgroup_show_fdinfo()\n return value ignored\n cgroup1_release_agent()\n wasn\'t checking ""too large"" error\n proc_cgroup_show()\n already converted ""too large"" to negative value\n\nCc: Greg Kroah-Hartman \nCc: Tejun Heo \nCc: Zefan Li \nCc: Johannes Weiner \nCc: Waiman Long \nCc: \nCo-developed-by: Azeem Shaikh \nSigned-off-by: Azeem Shaikh \nLink: https://lore.kernel.org/r/20231116192127.1558276-3-keescook@chromium.org\nSigned-off-by: Kees Cook \nLink: https://lore.kernel.org/r/20231212211741.164376-3-keescook@chromium.org\nSigned-off-by: Greg Kroah-Hartman \n', '']",Convert kernfs_path_from_node_locked() from strlcpy() to strscpy() to improve truncation return value handling.,"strscpy, kernfs, truncation",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +b84d66b0fd3709e36384a2cd893fbdddfc423f1f,b84d66b0fd3709e36384a2cd893fbdddfc423f1f,David S. Miller,davem@davemloft.net,1702638303,David S. Miller,davem@davemloft.net,1702638303,001ba1c994b7b9a067f8b95c7ea31d294196a068,9ed816b106bb40be6f1254696c6887e48f2a2b8f 00e7f29d9b895cbee58b7071900dd52ed6dcec1e,"Merge branch 'mv88e6xxx-counters' + +Tobias Waldekranz says: + +==================== +net: dsa: mv88e6xxx: Add ""eth-mac"" and ""rmon"" counter group support + +The majority of the changes (2/8) are about refactoring the existing +ethtool statistics support to make it possible to read individual +counters"," rather than the whole set. + +4/8 tries to collect all information about a stat in a single place +using a mapper macro","[' which is then used to generate the original list\nof stats', ' along with a matching enum. checkpatch is less than amused\nwith this construct', ' but prior art exists (__BPF_FUNC_MAPPER in\ninclude/uapi/linux/bpf.h', ' for example).\n\nTo support the histogram counters from the ""rmon"" group', "" we have to\nchange mv88e6xxx's configuration of them. Instead of counting rx and\ntx"", ' we restrict them to rx-only. 6/8 has the details.\n\nWith that in place', ' adding the actual counter groups is pretty\nstraight forward (5', '7/8).\n\nTie it all together with a selftest (8/8).\n\nv3 -> v4:\n- Return size_t from mv88e6xxx_stats_get_stats\n- Spelling errors in commit message of 6/8\n- Improve selftest:\n - Report progress per-bucket\n - Test both ports in the pair\n - Increase MTU', ' if required\n\nv2 -> v3:\n- Added 6/8\n- Added 8/8\n\nv1 -> v2:\n- Added 1/6\n- Added 3/6\n- Changed prototype of stats operation to reflect the fact that the\n number of read stats are returned', "" no errors\n- Moved comma into MV88E6XXX_HW_STAT_MAPPER definition\n- Avoid the construction of mapping table iteration which relied on\n struct layouts outside of mv88e6xxx's control\n====================\n\nSigned-off-by: David S. Miller \n"", '']","Add ""eth-mac"" and ""rmon"" counter group support and refactor ethtool statistics for mv88e6xxx.","mv88e6xxx,counter,support",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +7489723c2e26504573dbb49b66bbc59092840008,7489723c2e26504573dbb49b66bbc59092840008,Daniel Xu,dxu@dxuuu.xyz,1702594585,Alexei Starovoitov,ast@kernel.org,1702609936,1a7a5f68c9012ebec507b80fb9c48bc456f5bb2a,0f5d5454c723d5c729d4676860a390c31c466f50,"bpf: xdp: Register generic_kfunc_set with XDP programs + +Registering generic_kfunc_set with XDP programs enables some of the +newer BPF features inside XDP -- namely tree based data structures and +BPF exceptions. + +The current motivation for this commit is to enable assertions inside +XDP bpf progs. Assertions are a standard and useful tool to encode +intent. + +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/d07d4614b81ca6aada44fcb89bb6b618fb66e4ca.1702594357.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",,Register generic_kfunc_set with XDP programs to enable assertions and newer BPF features.,"generic_kfunc_set,XDP,assertions",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['xdp like programs'] +52eda4641d041667fa059f4855c5f88dcebd8afe,52eda4641d041667fa059f4855c5f88dcebd8afe,Vladimir Oltean,vladimir.oltean@nxp.com,1702512541,Jakub Kicinski,kuba@kernel.org,1702605489,d9edd54ff64067afc1388b1c9a7a26f7a55fc07a,c7402612e2e61b76177f22e6e7f705adcbecc6fe,"net: mscc: ocelot: fix eMAC TX RMON stats for bucket 256-511 and above + +There is a typo in the driver due to which we report incorrect TX RMON +counters for the 256-511 octet bucket and all the other buckets larger +than that. + +Bug found with the selftest at +https://patchwork.kernel.org/project/netdevbpf/patch/20231211223346.2497157-9-tobias@waldekranz.com/ + +Fixes: e32036e1ae7b (""net: mscc: ocelot: add support for all sorts of standardized counters present in DSA"") +Signed-off-by: Vladimir Oltean +Reviewed-by: Florian Fainelli +Link: https://lore.kernel.org/r/20231214000902.545625-1-vladimir.oltean@nxp.com +Signed-off-by: Jakub Kicinski +",,Fixes a typo in the ocelot driver to correct TX RMON stats reporting for certain octet buckets.,fix typo stats,It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['other'] +0f5d5454c723d5c729d4676860a390c31c466f50,0f5d5454c723d5c729d4676860a390c31c466f50,Alexei Starovoitov,ast@kernel.org,1702603827,Alexei Starovoitov,ast@kernel.org,1702603827,d431629c4dcedb8f2d12df5d2ed64e96152d9855,403f3e8fda60f1a3e54741742d46aea98ecf671e f2d0ffee1f03395d9ae65f9c615b6a0ee05d0e12,"Merge branch 'bpf-fs-mount-options-parsing-follow-ups' + +Andrii Nakryiko says: + +==================== +BPF FS mount options parsing follow ups + +Original BPF token patch set ([0]) added delegate_xxx mount options which +supported only special ""any"" value and hexadecimal bitmask. This patch set +attempts to make specifying and inspecting these mount options more +human-friendly by supporting string constants matching corresponding bpf_cmd"," +bpf_map_type","[' bpf_prog_type', "" and bpf_attach_type enumerators.\n\nThis implementation relies on BTF information to find all supported symbolic\nnames. If kernel wasn't built with BTF"", ' BPF FS will still support ""any"" and\nhex-based mask.\n\n [0] https://patchwork.kernel.org/project/netdevbpf/list/?series=805707&state=*\n\nv1->v2:\n - strip BPF_', ' BPF_MAP_TYPE_', ' and BPF_PROG_TYPE_ prefixes', '\n do case-insensitive comparison', ' normalize to lower case (Alexei).\n====================\n\nLink: https://lore.kernel.org/r/20231214225016.1209867-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Improved BPF FS mount options parsing for better usability with human-friendly string constants.,"BPF, mount, parsing",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f2d0ffee1f03395d9ae65f9c615b6a0ee05d0e12,f2d0ffee1f03395d9ae65f9c615b6a0ee05d0e12,Andrii Nakryiko,andrii@kernel.org,1702594216,Alexei Starovoitov,ast@kernel.org,1702603827,d431629c4dcedb8f2d12df5d2ed64e96152d9855,c5707b2146d229691e193d5158ea70b21b8ba180,"selftests/bpf: utilize string values for delegate_xxx mount options + +Use both hex-based and string-based way to specify delegate mount +options for BPF FS. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231214225016.1209867-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Use string values for delegate mount options in BPF selftests.,"selftests,mount options,string values",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +c5707b2146d229691e193d5158ea70b21b8ba180,c5707b2146d229691e193d5158ea70b21b8ba180,Andrii Nakryiko,andrii@kernel.org,1702594215,Alexei Starovoitov,ast@kernel.org,1702603827,1a9b1faadfa46eb1172440b18d2db54ba88a79c0,403f3e8fda60f1a3e54741742d46aea98ecf671e,"bpf: support symbolic BPF FS delegation mount options + +Besides already supported special ""any"" value and hex bit mask"," support +string-based parsing of delegation masks based on exact enumerator +names. Utilize BTF information of `enum bpf_cmd`","[' `enum bpf_map_type`', '\n`enum bpf_prog_type`', ' and `enum bpf_attach_type` types to find supported\nsymbolic names (ignoring __MAX_xxx guard values and stripping repetitive\nprefixes like BPF_ for cmd and attach types', ' BPF_MAP_TYPE_ for maps', "" and\nBPF_PROG_TYPE_ for prog types). The case doesn't matter"", ' but it is\nnormalized to lower case in mount option output. So ""PROG_LOAD""', '\n""prog_load""', ' and ""MAP_create"" are all valid values to specify for\ndelegate_cmds options', ' ""array"" is among supported for map types', ' etc.\n\nBesides supporting string values', ' we also support multiple values\nspecified at the same time', "" using colon (':') separator.\n\nThere are corresponding changes on bpf_show_options side to use known\nvalues to print them in human-readable format"", ' falling back to hex mask\nprinting', "" if there are any unrecognized bits. This shouldn't be\nnecessary when enum BTF information is present"", ' but in general we should\nalways be able to fall back to this even if kernel was built without BTF.\nAs mentioned', ' emitted symbolic names are normalized to be all lower case.\n\nExample below shows various ways to specify delegate_cmds options\nthrough mount command and how mount options are printed back:\n\n12/14 14:39:07.604\nvmuser@archvm:~/local/linux/tools/testing/selftests/bpf\n$ mount | rg token\n\n $ sudo mkdir -p /sys/fs/bpf/token\n $ sudo mount -t bpf bpffs /sys/fs/bpf/token \\\n -o delegate_cmds=prog_load:MAP_CREATE \\\n -o delegate_progs=kprobe \\\n -o delegate_attachs=xdp\n $ mount | grep token\n bpffs on /sys/fs/bpf/token type bpf (rw', 'relatime', 'delegate_cmds=map_create:prog_load', 'delegate_progs=kprobe', 'delegate_attachs=xdp)\n\nAcked-by: John Fastabend \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231214225016.1209867-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Support added for symbolic BPF FS delegation mount options using BTF information.,"symbolic, delegation, options",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +403f3e8fda60f1a3e54741742d46aea98ecf671e,403f3e8fda60f1a3e54741742d46aea98ecf671e,Alexei Starovoitov,ast@kernel.org,1702602769,Alexei Starovoitov,ast@kernel.org,1702602776,f30b1ef6e9987ff5f3cb2a5d14044748c3d0a866,56925f389e152dcb8d093435d43b78a310539c23 2cd07b0eb08c0ed63b1bd0bf0114146b19a4ab1f,"Merge branch 'add-bpf_xdp_get_xfrm_state-kfunc' + +Daniel Xu says: + +==================== +Add bpf_xdp_get_xfrm_state() kfunc + +This patchset adds two kfunc helpers"," bpf_xdp_get_xfrm_state() and +bpf_xdp_xfrm_state_release() that wrap xfrm_state_lookup() and +xfrm_state_put(). The intent is to support software RSS (via XDP) for +the ongoing/upcoming ipsec pcpu work [0]. Recent experiments performed +on (hopefully) reproducible AWS testbeds indicate that single tunnel +pcpu ipsec can reach line rate on 100G ENA nics. + +Note this patchset only tests/shows generic xfrm_state access. The +""secret sauce"" (if you can really even call it that) involves accessing +a soon-to-be-upstreamed pcpu_num field in xfrm_state. Early example is +available here [1]. + +[0]: https://datatracker.ietf.org/doc/draft-ietf-ipsecme-multi-sa-performance/03/ +[1]: https://github.com/danobi/xdp-tools/blob/e89a1c617aba3b50d990f779357d6ce2863ecb27/xdp-bench/xdp_redirect_cpumap.bpf.c#L385-L406 + +Changes from v5: +* Improve kfunc doc comments +* Remove extraneous replay-window setting on selftest reverse path +* Squash two kfunc commits into one +* Rebase to bpf-next to pick up bitfield write patches +* Remove testing of opts.error in selftest prog + +Changes from v4: +* Fixup commit message for selftest +* Set opts->error -ENOENT for !x +* Revert single file xfrm + bpf + +Changes from v3: +* Place all xfrm bpf integrations in xfrm_bpf.c +* Avoid using nval as a temporary +* Rebase to bpf-next +* Remove extraneous __failure_unpriv annotation for verifier tests + +Changes from v2: +* Fix/simplify BPF_CORE_WRITE_BITFIELD() algorithm +* Added verifier tests for bitfield writes +* Fix state leakage across test_tunnel subtests + +Changes from v1: +* Move xfrm tunnel tests to test_progs +* Fix writing to opts->error when opts is invalid +* Use __bpf_kfunc_start_defs() +* Remove unused vxlanhdr definition +* Add and use BPF_CORE_WRITE_BITFIELD() macro +* Make series bisect clean + +Changes from RFCv2: +* Rebased to ipsec-next +* Fix netns leak + +Changes from RFCv1: +* Add Antony's commit tags +* Add KF_ACQUIRE and KF_RELEASE semantics +==================== + +Reviewed-by: Eyal Birger +Link: https://lore.kernel.org/r/cover.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",[''],Add bpf_xdp_get_xfrm_state and bpf_xdp_xfrm_state_release kfuncs for improved XDP support in ipsec.,"kfunc, XDP, ipsec",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['xdp like programs'] +2cd07b0eb08c0ed63b1bd0bf0114146b19a4ab1f,2cd07b0eb08c0ed63b1bd0bf0114146b19a4ab1f,Daniel Xu,dxu@dxuuu.xyz,1702594146,Alexei Starovoitov,ast@kernel.org,1702602769,f30b1ef6e9987ff5f3cb2a5d14044748c3d0a866,e7adc8291a9e9c232d600d82465cbbb682164ca3,"bpf: xfrm: Add selftest for bpf_xdp_get_xfrm_state() + +This commit extends test_tunnel selftest to test the new XDP xfrm state +lookup kfunc. + +Co-developed-by: Antony Antony +Signed-off-by: Antony Antony +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/e704e9a4332e3eac7b458e4bfdec8fcc6984cdb6.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",,The commit adds a selftest for bpf_xdp_get_xfrm_state function in the test_tunnel selftest.,"selftest,xdp,xfrm state",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['xdp like programs'] +e7adc8291a9e9c232d600d82465cbbb682164ca3,e7adc8291a9e9c232d600d82465cbbb682164ca3,Daniel Xu,dxu@dxuuu.xyz,1702594145,Alexei Starovoitov,ast@kernel.org,1702602769,c40277183677d835d38103bd9eda01d19b7e7c6b,02b4e126e6a5f5552da2ccec47a028984d2d9654,"bpf: selftests: Move xfrm tunnel test to test_progs + +test_progs is better than a shell script b/c C is a bit easier to +maintain than shell. Also it's easier to use new infra like memory +mapped global variables from C via bpf skeleton. + +Co-developed-by: Antony Antony +Signed-off-by: Antony Antony +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/a350db9e08520c64544562d88ec005a039124d9b.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",,The commit moves the xfrm tunnel test from a shell script to the test_progs framework for easier maintenance and new infrastructure compatibility.,"xfrm tunnel, test_progs, bpf skeleton",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +02b4e126e6a5f5552da2ccec47a028984d2d9654,02b4e126e6a5f5552da2ccec47a028984d2d9654,Daniel Xu,dxu@dxuuu.xyz,1702594144,Alexei Starovoitov,ast@kernel.org,1702602769,8c250a11aa648e0d71e26ae415062335b729a141,77a7a8220f0d87c44425c0a12e0a72b14962535b,"bpf: selftests: test_tunnel: Use vmlinux.h declarations + +vmlinux.h declarations are more ergnomic"," especially when working with +kfuncs. The uapi headers are often incomplete for kfunc definitions. + +This commit also switches bitfield accesses to use CO-RE helpers. +Switching to vmlinux.h definitions makes the verifier very +unhappy with raw bitfield accesses. The error is: + + ; md.u.md2.dir = direction; + 33: (69) r1 = *(u16 *)(r2 +11) + misaligned stack access off (0x0; 0x0)+-64+11 size 2 + +Fix by using CO-RE-aware bitfield reads and writes. + +Co-developed-by: Antony Antony +Signed-off-by: Antony Antony +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/884bde1d9a351d126a3923886b945ea6b1b0776b.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",[''],Refactor selftests to use vmlinux.h declarations for improved ergonomics and compatibility with kfuncs.,"vmlinux.h, kfuncs, CO-RE",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['xdp like programs', 'other']" +77a7a8220f0d87c44425c0a12e0a72b14962535b,77a7a8220f0d87c44425c0a12e0a72b14962535b,Daniel Xu,dxu@dxuuu.xyz,1702594143,Alexei Starovoitov,ast@kernel.org,1702602769,d6d8802fab0be3c12762810ffc6e026f4dbe84b1,8f0ec8c681755f523cf842bfe350ea40609b83a9,"bpf: selftests: test_tunnel: Setup fresh topology for each subtest + +This helps with determinism b/c individual setup/teardown prevents +leaking state between different subtests. + +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/0fb59fa16fb58cca7def5239df606005a3e8dd0e.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",,The commit sets up a fresh topology for each subtest in test_tunnel to ensure test determinism.,"selftests, topology, determinism",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8f0ec8c681755f523cf842bfe350ea40609b83a9,8f0ec8c681755f523cf842bfe350ea40609b83a9,Daniel Xu,dxu@dxuuu.xyz,1702594142,Alexei Starovoitov,ast@kernel.org,1702602769,09854f18f530083819738a3c283fe95d16952ee4,56925f389e152dcb8d093435d43b78a310539c23,"bpf: xfrm: Add bpf_xdp_get_xfrm_state() kfunc + +This commit adds an unstable kfunc helper to access internal xfrm_state +associated with an SA. This is intended to be used for the upcoming +IPsec pcpu work to assign special pcpu SAs to a particular CPU. In other +words: for custom software RSS. + +That being said"," the function that this kfunc wraps is fairly generic +and used for a lot of xfrm tasks. I'm sure people will find uses +elsewhere over time. + +This commit also adds a corresponding bpf_xdp_xfrm_state_release() kfunc +to release the refcnt acquired by bpf_xdp_get_xfrm_state(). The verifier +will require that all acquired xfrm_state's are released. + +Co-developed-by: Antony Antony +Signed-off-by: Antony Antony +Acked-by: Steffen Klassert +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/a29699c42f5fad456b875c98dd11c6afc3ffb707.1702593901.git.dxu@dxuuu.xyz +Signed-off-by: Alexei Starovoitov +",[''],Added bpf_xdp_get_xfrm_state() and bpf_xdp_xfrm_state_release() kfuncs for internal xfrm_state management associated with SA.,"bpf_xdp_get_xfrm_state, kfunc, xfrm_state",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['xdp like programs'] +56925f389e152dcb8d093435d43b78a310539c23,56925f389e152dcb8d093435d43b78a310539c23,Yonghong Song,yonghong.song@linux.dev,1702586300,Alexei Starovoitov,ast@kernel.org,1702602632,23441311b52d786b1d7ddd06fe92f6bd23d8fab7,59e5791f59dd83e8aa72a4e74217eabb6e8cfd90,"selftests/bpf: Remove flaky test_btf_id test + +With previous patch"," one of subtests in test_btf_id becomes +flaky and may fail. The following is a failing example: + + Error: #26 btf + Error: #26/174 btf/BTF ID + Error: #26/174 btf/BTF ID + btf_raw_create:PASS:check 0 nsec + btf_raw_create:PASS:check 0 nsec + test_btf_id:PASS:check 0 nsec + ... + test_btf_id:PASS:check 0 nsec + test_btf_id:FAIL:check BTF lingersdo_test_get_info:FAIL:check failed: -1 + +The test tries to prove a btf_id not available after the map is closed. +But btf_id is freed only after workqueue and a rcu grace period","[' compared\nto previous case just after a rcu grade period.\nDepending on system workload', ' workqueue could take quite some time\nto execute function bpf_map_free_deferred() which may cause the test failure.\nInstead of adding arbitrary delays', ' let us remove the logic to\ncheck btf_id availability after map is closed.\n\nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231214203820.1469402-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",This commit removes a flaky test from the BPF selftests related to BTF ID.,"flaky,test,BTF",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +59e5791f59dd83e8aa72a4e74217eabb6e8cfd90,59e5791f59dd83e8aa72a4e74217eabb6e8cfd90,Yonghong Song,yonghong.song@linux.dev,1702586295,Alexei Starovoitov,ast@kernel.org,1702602632,6c7ed3b9ea78d8e9ebee7262feb358b5e009cd88,04d25ccea2b3199269b7e500da33023b51418fde,"bpf: Fix a race condition between btf_put() and map_free() + +When running `./test_progs -j` in my local vm with latest kernel"," +I once hit a kasan error like below: + + [ 1887.184724] BUG: KASAN: slab-use-after-free in bpf_rb_root_free+0x1f8/0x2b0 + [ 1887.185599] Read of size 4 at addr ffff888106806910 by task kworker/u12:2/2830 + [ 1887.186498] + [ 1887.186712] CPU: 3 PID: 2830 Comm: kworker/u12:2 Tainted: G OEL 6.7.0-rc3-00699-g90679706d486-dirty #494 + [ 1887.188034] Hardware name: QEMU Standard PC (i440FX + PIIX","[' 1996)', ' BIOS rel-1.14.0-0-g155821a1990b-prebuilt.qemu.org 04/01/2014\n [ 1887.189618] Workqueue: events_unbound bpf_map_free_deferred\n [ 1887.190341] Call Trace:\n [ 1887.190666] \n [ 1887.190949] dump_stack_lvl+0xac/0xe0\n [ 1887.191423] ? nf_tcp_handle_invalid+0x1b0/0x1b0\n [ 1887.192019] ? panic+0x3c0/0x3c0\n [ 1887.192449] print_report+0x14f/0x720\n [ 1887.192930] ? preempt_count_sub+0x1c/0xd0\n [ 1887.193459] ? __virt_addr_valid+0xac/0x120\n [ 1887.194004] ? bpf_rb_root_free+0x1f8/0x2b0\n [ 1887.194572] kasan_report+0xc3/0x100\n [ 1887.195085] ? bpf_rb_root_free+0x1f8/0x2b0\n [ 1887.195668] bpf_rb_root_free+0x1f8/0x2b0\n [ 1887.196183] ? __bpf_obj_drop_impl+0xb0/0xb0\n [ 1887.196736] ? preempt_count_sub+0x1c/0xd0\n [ 1887.197270] ? preempt_count_sub+0x1c/0xd0\n [ 1887.197802] ? _raw_spin_unlock+0x1f/0x40\n [ 1887.198319] bpf_obj_free_fields+0x1d4/0x260\n [ 1887.198883] array_map_free+0x1a3/0x260\n [ 1887.199380] bpf_map_free_deferred+0x7b/0xe0\n [ 1887.199943] process_scheduled_works+0x3a2/0x6c0\n [ 1887.200549] worker_thread+0x633/0x890\n [ 1887.201047] ? __kthread_parkme+0xd7/0xf0\n [ 1887.201574] ? kthread+0x102/0x1d0\n [ 1887.202020] kthread+0x1ab/0x1d0\n [ 1887.202447] ? pr_cont_work+0x270/0x270\n [ 1887.202954] ? kthread_blkcg+0x50/0x50\n [ 1887.203444] ret_from_fork+0x34/0x50\n [ 1887.203914] ? kthread_blkcg+0x50/0x50\n [ 1887.204397] ret_from_fork_asm+0x11/0x20\n [ 1887.204913] \n [ 1887.204913] \n [ 1887.205209]\n [ 1887.205416] Allocated by task 2197:\n [ 1887.205881] kasan_set_track+0x3f/0x60\n [ 1887.206366] __kasan_kmalloc+0x6e/0x80\n [ 1887.206856] __kmalloc+0xac/0x1a0\n [ 1887.207293] btf_parse_fields+0xa15/0x1480\n [ 1887.207836] btf_parse_struct_metas+0x566/0x670\n [ 1887.208387] btf_new_fd+0x294/0x4d0\n [ 1887.208851] __sys_bpf+0x4ba/0x600\n [ 1887.209292] __x64_sys_bpf+0x41/0x50\n [ 1887.209762] do_syscall_64+0x4c/0xf0\n [ 1887.210222] entry_SYSCALL_64_after_hwframe+0x63/0x6b\n [ 1887.210868]\n [ 1887.211074] Freed by task 36:\n [ 1887.211460] kasan_set_track+0x3f/0x60\n [ 1887.211951] kasan_save_free_info+0x28/0x40\n [ 1887.212485] ____kasan_slab_free+0x101/0x180\n [ 1887.213027] __kmem_cache_free+0xe4/0x210\n [ 1887.213514] btf_free+0x5b/0x130\n [ 1887.213918] rcu_core+0x638/0xcc0\n [ 1887.214347] __do_softirq+0x114/0x37e\n\nThe error happens at bpf_rb_root_free+0x1f8/0x2b0:\n\n 00000000000034c0 :\n ; {\n 34c0: f3 0f 1e fa endbr64\n 34c4: e8 00 00 00 00 callq 0x34c9 \n 34c9: 55 pushq %rbp\n 34ca: 48 89 e5 movq %rsp', ' %rbp\n ...\n ; if (rec && rec->refcount_off >= 0 &&\n 36aa: 4d 85 ed testq %r13', ' %r13\n 36ad: 74 a9 je 0x3658 \n 36af: 49 8d 7d 10 leaq 0x10(%r13)', ' %rdi\n 36b3: e8 00 00 00 00 callq 0x36b8 \n <==== kasan function\n 36b8: 45 8b 7d 10 movl 0x10(%r13)', ' %r15d\n <==== use-after-free load\n 36bc: 45 85 ff testl %r15d', ' %r15d\n 36bf: 78 8c js 0x364d \n\nSo the problem is at rec->refcount_off in the above.\n\nI did some source code analysis and find the reason.\n CPU A CPU B\n bpf_map_put:\n ...\n btf_put with rcu callback\n ...\n bpf_map_free_deferred\n with system_unbound_wq\n ... ... ...\n ... btf_free_rcu: ...\n ... ... bpf_map_free_deferred:\n ... ...\n ... ---------> btf_struct_metas_free()\n ... | race condition ...\n ... ---------> map->ops->map_free()\n ...\n ... btf->struct_meta_tab = NULL\n\nIn the above', ' map_free() corresponds to array_map_free() and eventually\ncalling bpf_rb_root_free() which calls:\n ...\n __bpf_obj_drop_impl(obj', ' field->graph_root.value_rec', ' false);\n ...\n\nHere', "" 'value_rec' is assigned in btf_check_and_fixup_fields() with following code:\n\n meta = btf_find_struct_meta(btf"", ' btf_id);\n if (!meta)\n return -EFAULT;\n rec->fields[i].graph_root.value_rec = meta->record;\n\nSo basically', "" 'value_rec' is a pointer to the record in struct_metas_tab.\nAnd it is possible that that particular record has been freed by\nbtf_struct_metas_free() and hence we have a kasan error here.\n\nActually it is very hard to reproduce the failure with current bpf/bpf-next\ncode"", ' I only got the above error once. To increase reproducibility', ' I added\na delay in bpf_map_free_deferred() to delay map->ops->map_free()', ' which\nsignificantly increased reproducibility.\n\n diff --git a/kernel/bpf/syscall.c b/kernel/bpf/syscall.c\n index 5e43ddd1b83f..aae5b5213e93 100644\n --- a/kernel/bpf/syscall.c\n +++ b/kernel/bpf/syscall.c\n @@ -695', '6 +695', '7 @@ static void bpf_map_free_deferred(struct work_struct *work)\n struct bpf_map *map = container_of(work', ' struct bpf_map', ' work);\n struct btf_record *rec = map->record;\n\n + mdelay(100);\n security_bpf_map_free(map);\n bpf_map_release_memcg(map);\n /* implementation dependent freeing */\n\nHao also provided test cases ([1]) for easily reproducing the above issue.\n\nThere are two ways to fix the issue', ' the v1 of the patch ([2]) moving\nbtf_put() after map_free callback', ' and the v5 of the patch ([3]) using\na kptr style fix which tries to get a btf reference during\nmap_check_btf(). Each approach has its pro and cons. The first approach\ndelays freeing btf while the second approach needs to acquire reference\ndepending on context which makes logic not very elegant and may\ncomplicate things with future new data structures. Alexei\nsuggested in [4] going back to v1 which is what this patch\ntries to do.\n\nRerun \'./test_progs -j\' with the above mdelay() hack for a couple\nof times and didn\'t observe the error for the above rb_root test cases.\nRunning Hou\'s test ([1]) is also successful.\n\n [1] https://lore.kernel.org/bpf/20231207141500.917136-1-houtao@huaweicloud.com/\n [2] v1: https://lore.kernel.org/bpf/20231204173946.3066377-1-yonghong.song@linux.dev/\n [3] v5: https://lore.kernel.org/bpf/20231208041621.2968241-1-yonghong.song@linux.dev/\n [4] v4: https://lore.kernel.org/bpf/CAADnVQJ3FiXUhZJwX_81sjZvSYYKCFB3BT6P8D59RS2Gu+0Z7g@mail.gmail.com/\n\nCc: Hou Tao \nFixes: 958cf2e273f0 (""bpf: Introduce bpf_obj_new"")\nSigned-off-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231214203815.1469107-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes a race condition in bpf related to use-after-free errors in btf_put() and map_free().,"race condition, btf_put, map_free",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +04d25ccea2b3199269b7e500da33023b51418fde,04d25ccea2b3199269b7e500da33023b51418fde,Randy Dunlap,rdunlap@infradead.org,1702442255,Daniel Borkmann,daniel@iogearbox.net,1702568339,9c45da55c1977cb060f9bb8231100cc07ab0f4ff,2e1d6a04116c373fbd25beddba4267178535bc60,net," xdp: Correct grammar + +Use the correct verb form in 2 places in the XDP rx-queue comment. + +Signed-off-by: Randy Dunlap +Signed-off-by: Daniel Borkmann +Acked-by: Jesper Dangaard Brouer +Link: https://lore.kernel.org/bpf/20231213043735.30208-1-rdunlap@infradead.org +",[''],Corrects verb form in XDP rx-queue comment for improved grammar.,"grammar, XDP, comment",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,['xdp like programs'] +2e1d6a04116c373fbd25beddba4267178535bc60,2e1d6a04116c373fbd25beddba4267178535bc60,Tushar Vyavahare,tushar.vyavahare@intel.com,1702558807,Daniel Borkmann,daniel@iogearbox.net,1702566673,66ed3a51fb09661b55276001751737d0424961a8,c838fe1282df540ebf6e24e386ac34acb3ef3115,"selftests/xsk: Fix for SEND_RECEIVE_UNALIGNED test + +Fix test broken by shared umem test and framework enhancement commit. + +Correct the current implementation of pkt_stream_replace_half() by +ensuring that nb_valid_entries are not set to half"," as this is not true +for all the tests. Ensure that the expected value for valid_entries for +the SEND_RECEIVE_UNALIGNED test equals the total number of packets sent","['\nwhich is 4096.\n\nCreate a new function called pkt_stream_pkt_set() that allows for packet\nmodification to meet specific requirements while ensuring the accurate\nmaintenance of the valid packet count to prevent inconsistencies in packet\ntracking.\n\nFixes: 6d198a89c004 (""selftests/xsk: Add a test for shared umem feature"")\nReported-by: Maciej Fijalkowski \nSigned-off-by: Tushar Vyavahare \nSigned-off-by: Daniel Borkmann \nReviewed-by: Maciej Fijalkowski \nAcked-by: Magnus Karlsson \nLink: https://lore.kernel.org/bpf/20231214130007.33281-1-tushar.vyavahare@intel.com\n', '']",Fixes SEND_RECEIVE_UNALIGNED test in selftests/xsk by correcting pkt_stream_replace_half() implementation.,"selftests,xsk,unaligned",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['other'] +c838fe1282df540ebf6e24e386ac34acb3ef3115,c838fe1282df540ebf6e24e386ac34acb3ef3115,Alexei Starovoitov,ast@kernel.org,1702529351,Alexei Starovoitov,ast@kernel.org,1702530160,0b6e496130744349f7e15d3c015e7196e9bb7217,2a0c6b41eec90c2a138ea8b574836744783c67ff dc68540913ac523b46ebda3843cec179362c7a72,"Merge branch 'bpf-use-gfp_kernel-in-bpf_event_entry_gen' + +Hou Tao says: + +==================== +The simple patch set aims to replace GFP_ATOMIC by GFP_KERNEL in +bpf_event_entry_gen(). These two patches in the patch set were +preparatory patches in ""Fix the release of inner map"" patchset [1] and +are not needed for v2"," so re-post it to bpf-next tree. + +Patch #1 reduces the scope of rcu_read_lock when updating fd map and +patch #2 replaces GFP_ATOMIC by GFP_KERNEL. Please see individual +patches for more details. + +Change Log: +v3: + * patch #1: fallback to patch #1 in v1. Update comments in + bpf_fd_htab_map_update_elem() to explain the reason for + rcu_read_lock() (Alexei) + +v2: https://lore.kernel.org/bpf/20231211073843.1888058-1-houtao@huaweicloud.com/ + * patch #1: add rcu_read_lock/unlock() for bpf_fd_array_map_update_elem + as well to make it consistent with + bpf_fd_htab_map_update_elem and update commit message + accordingly (Alexei) + * patch #1/#2: collects ack tags from Yonghong + +v1: https://lore.kernel.org/bpf/20231208103357.2637299-1-houtao@huaweicloud.com/ + +[1]: https://lore.kernel.org/bpf/20231107140702.1891778-1-houtao@huaweicloud.com/ +==================== + +Link: https://lore.kernel.org/r/20231214043010.3458072-1-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Replace GFP_ATOMIC with GFP_KERNEL in bpf_event_entry_gen function to optimize memory allocation.,"GFP_KERNEL, bpf_event_entry_gen, memory",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dc68540913ac523b46ebda3843cec179362c7a72,dc68540913ac523b46ebda3843cec179362c7a72,Hou Tao,houtao1@huawei.com,1702528210,Alexei Starovoitov,ast@kernel.org,1702529351,0b6e496130744349f7e15d3c015e7196e9bb7217,8f82583f9527b3be9d70d9a5d1f33435e29d0480,"bpf: Use GFP_KERNEL in bpf_event_entry_gen() + +rcu_read_lock() is no longer held when invoking bpf_event_entry_gen() +which is called by perf_event_fd_array_get_ptr()"," so using GFP_KERNEL +instead of GFP_ATOMIC to reduce the possibility of failures due to +out-of-memory. + +Acked-by: Yonghong Song +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231214043010.3458072-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Commit changes memory allocation from GFP_ATOMIC to GFP_KERNEL in bpf_event_entry_gen to reduce out-of-memory failures.,"GFP_KERNEL,bpf_event_entry_gen,reduce failures",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8f82583f9527b3be9d70d9a5d1f33435e29d0480,8f82583f9527b3be9d70d9a5d1f33435e29d0480,Hou Tao,houtao1@huawei.com,1702528209,Alexei Starovoitov,ast@kernel.org,1702529351,f295c8b23b7beead0a0bb9a2e880b7356299769d,2a0c6b41eec90c2a138ea8b574836744783c67ff,"bpf: Reduce the scope of rcu_read_lock when updating fd map + +There is no rcu-read-lock requirement for ops->map_fd_get_ptr() or +ops->map_fd_put_ptr()"," so doesn't use rcu-read-lock for these two +callbacks. + +For bpf_fd_array_map_update_elem()","["" accessing array->ptrs doesn't need\nrcu-read-lock because array->ptrs must still be allocated. For\nbpf_fd_htab_map_update_elem()"", ' htab_map_update_elem() only requires\nrcu-read-lock to be held to avoid the WARN_ON_ONCE()', ' so only use\nrcu_read_lock() during the invocation of htab_map_update_elem().\n\nAcked-by: Yonghong Song \nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231214043010.3458072-2-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit reduces the rcu_read_lock scope when updating file descriptor maps in BPF.,"rcu_read_lock, fd map, update",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2a0c6b41eec90c2a138ea8b574836744783c67ff,2a0c6b41eec90c2a138ea8b574836744783c67ff,Hou Tao,houtao1@huawei.com,1702283687,Alexei Starovoitov,ast@kernel.org,1702515702,733a6575e6f7d0cfef20deb2cd5e3d94c38c2469,b13cddf633562b9b2c34fd63471d377019704ebe,"bpf: Update the comments in maybe_wait_bpf_programs() + +Since commit 638e4b825d52 (""bpf: Allows per-cpu maps and map-in-map in +sleepable programs"")", sleepable BPF program can also use map-in-map,"["" but\nmaybe_wait_bpf_programs() doesn't handle it accordingly. The main reason\nis that using synchronize_rcu_tasks_trace() to wait for the completions\nof these sleepable BPF programs may incur a very long delay and\nuserspace may think it is hung"", ' so the wait for sleepable BPF programs\nis skipped. Update the comments in maybe_wait_bpf_programs() to reflect\nthe reason.\n\nSigned-off-by: Hou Tao \nAcked-by: Yonghong Song \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/r/20231211083447.1921178-1-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit updates comments in the maybe_wait_bpf_programs function to reflect new capabilities for sleepable BPF programs.,"comments, maybe_wait_bpf_programs, sleepable BPF",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b13cddf633562b9b2c34fd63471d377019704ebe,b13cddf633562b9b2c34fd63471d377019704ebe,Matt Bobrowski,mattbobrowski@google.com,1702049568,Alexei Starovoitov,ast@kernel.org,1702515379,3756cd5100503ce15d097203ada907c02a514bd1,ec14325c7339bf1d40fc29bb8a0d2121cfe649aa,"bpf: add small subset of SECURITY_PATH hooks to BPF sleepable_lsm_hooks list + +security_path_* based LSM hooks appear to be generally missing from +the sleepable_lsm_hooks list. Initially add a small subset of them to +the preexisting sleepable_lsm_hooks list so that sleepable BPF helpers +like bpf_d_path() can be used from sleepable BPF LSM based programs. + +The security_path_* hooks added in this patch are similar to the +security_inode_* counterparts that already exist in the +sleepable_lsm_hooks list"," and are called in roughly similar points and +contexts. Presumably","["" making them OK to be also annotated as\nsleepable.\n\nBuilding a kernel with DEBUG_ATOMIC_SLEEP options enabled and running\nreasonable workloads stimulating activity that would be intercepted by\nsuch security hooks didn't show any splats.\n\nNotably"", "" I haven't added all the security_path_* LSM hooks that are\navailable as I don't need them at this point in time.\n\nSigned-off-by: Matt Bobrowski \nAcked-by: KP Singh \nLink: https://lore.kernel.org/r/ZXM3IHHXpNY9y82a@google.com\nSigned-off-by: Alexei Starovoitov \n"", '']",Added security_path hooks to sleepable_lsm_hooks list for BPF sleepable LSM programs.,"security_path, LSM hooks, sleepable",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['LSM like programs'] +2f2fee2bf74a7e31d06fc6cb7ba2bd4dd7753c99,2f2fee2bf74a7e31d06fc6cb7ba2bd4dd7753c99,Martin KaFai Lau,martin.lau@kernel.org,1702513313,Martin KaFai Lau,martin.lau@kernel.org,1702513997,fa6dcb7f84468e7631a8be8d1f4eb3b318d9d66f,e307b5a845c5951dabafc48d00b6424ee64716c4 50d96f05af6787a34b4eca2ee3fc1993289c4c24,"Merge branch ' bpf fix for unconnect af_unix socket' + +John Fastabend says: + +==================== +Eric reported a syzbot splat from a null ptr deref from recent fix to +resolve a use-after-free with af-unix stream sockets and BPF sockmap +usage. + +The issue is I missed is we allow unconnected af_unix STREAM sockets to +be added to the sockmap. Fix this by blocking unconnected sockets. + +v2: change sk_is_unix to sk_is_stream_unix (Eric) and remove duplicate + ASSERTS in selftests the xsocket helper already marks FAIL (Jakub) +==================== + +Signed-off-by: Martin KaFai Lau +",,Fix null pointer dereference by blocking unconnected af_unix STREAM sockets from being added to sockmap.,"af_unix, sockmap, unconnected",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['socket like programs'] +50d96f05af6787a34b4eca2ee3fc1993289c4c24,50d96f05af6787a34b4eca2ee3fc1993289c4c24,John Fastabend,john.fastabend@gmail.com,1701453699,Martin KaFai Lau,martin.lau@kernel.org,1702513981,fa6dcb7f84468e7631a8be8d1f4eb3b318d9d66f,8d6650646ce49e9a5b8c5c23eb94f74b1749f70f,bpf: sockmap," test for unconnected af_unix sock + +Add test to sockmap_basic to ensure af_unix sockets that are not connected +can not be added to the map. Ensure we keep DGRAM sockets working however +as these will not be connected typically. + +Signed-off-by: John Fastabend +Acked-by: Jakub Sitnicki +Link: https://lore.kernel.org/r/20231201180139.328529-3-john.fastabend@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Add test to ensure unconnected af_unix sockets can't be added to sockmap while keeping DGRAM sockets functional.,"test, sockmap, af_unix",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['socket like programs'] +8d6650646ce49e9a5b8c5c23eb94f74b1749f70f,8d6650646ce49e9a5b8c5c23eb94f74b1749f70f,John Fastabend,john.fastabend@gmail.com,1701453698,Martin KaFai Lau,martin.lau@kernel.org,1702513948,19c3a819ecc40da8172fdf7b3836ee8f96b8d9a2,e307b5a845c5951dabafc48d00b6424ee64716c4,"bpf: syzkaller found null ptr deref in unix_bpf proto add + +I added logic to track the sock pair for stream_unix sockets so that we +ensure lifetime of the sock matches the time a sockmap could reference +the sock (see fixes tag). I forgot though that we allow af_unix unconnected +sockets into a sock{map|hash} map. + +This is problematic because previous fixed expected sk_pair() to exist +and did not NULL check it. Because unconnected sockets have a NULL +sk_pair this resulted in the NULL ptr dereference found by syzkaller. + +BUG: KASAN: null-ptr-deref in unix_stream_bpf_update_proto+0x72/0x430 net/unix/unix_bpf.c:171 +Write of size 4 at addr 0000000000000080 by task syz-executor360/5073 +Call Trace: + + ... + sock_hold include/net/sock.h:777 [inline] + unix_stream_bpf_update_proto+0x72/0x430 net/unix/unix_bpf.c:171 + sock_map_init_proto net/core/sock_map.c:190 [inline] + sock_map_link+0xb87/0x1100 net/core/sock_map.c:294 + sock_map_update_common+0xf6/0x870 net/core/sock_map.c:483 + sock_map_update_elem_sys+0x5b6/0x640 net/core/sock_map.c:577 + bpf_map_update_value+0x3af/0x820 kernel/bpf/syscall.c:167 + +We considered just checking for the null ptr and skipping taking a ref +on the NULL peer sock. But"," if the socket is then connected() after +being added to the sockmap we can cause the original issue again. So +instead this patch blocks adding af_unix sockets that are not in the +ESTABLISHED state. + +Reported-by: Eric Dumazet +Reported-by: syzbot+e8030702aefd3444fb9e@syzkaller.appspotmail.com +Fixes: 8866730aed51 (""bpf","[' sockmap: af_unix stream sockets need to hold ref for pair sock"")\nAcked-by: Jakub Sitnicki \nSigned-off-by: John Fastabend \nLink: https://lore.kernel.org/r/20231201180139.328529-2-john.fastabend@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Fix null pointer dereference issue in unix_bpf protocol by preventing unconnected af_unix sockets from being added to sockmap.,"null pointer, sockmap, af_unix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['socket like programs'] +ec14325c7339bf1d40fc29bb8a0d2121cfe649aa,ec14325c7339bf1d40fc29bb8a0d2121cfe649aa,Alexei Starovoitov,ast@kernel.org,1702513002,Alexei Starovoitov,ast@kernel.org,1702513002,69dbb3887b907d62888bd4cad1781053d55ddd3c,733763285acfe8dffd6e39ad2ed3d1222b32a901 4c6612f6100c2d85212865dbd1a5d8a7e391d3cb,"Merge branch 'xdp-metadata-via-kfuncs-for-ice-vlan-hint' + +Larysa Zaremba says: + +==================== +XDP metadata via kfuncs for ice + VLAN hint + +This series introduces XDP hints via kfuncs [0] to the ice driver. + +Series brings the following existing hints to the ice driver: + - HW timestamp + - RX hash with type + +Series also introduces VLAN tag with protocol XDP hint"," it now be accessed by +XDP and userspace (AF_XDP) programs. They can also be checked with xdp_metadata +test and xdp_hw_metadata program. + +Impact of these patches on ice performance: +ZC: +* Full hints implementation decreases pps in ZC mode by less than 3% + (64B","[' rxdrop)\n\nskb (packets with invalid IP', ' dropped by stack):\n* Overall', ' patchset improves peak performance in skb mode by about 0.5%\n\n[0] https://patchwork.kernel.org/project/netdevbpf/cover/20230119221536.3349901-1-sdf@google.com/\n\nv7:\nhttps://lore.kernel.org/bpf/20231115175301.534113-1-larysa.zaremba@intel.com/\nv6:\nhttps://lore.kernel.org/bpf/20231012170524.21085-1-larysa.zaremba@intel.com/\nIntermediate RFC v2:\nhttps://lore.kernel.org/bpf/20230927075124.23941-1-larysa.zaremba@intel.com/\nIntermediate RFC v1:\nhttps://lore.kernel.org/bpf/20230824192703.712881-1-larysa.zaremba@intel.com/\nv5:\nhttps://lore.kernel.org/bpf/20230811161509.19722-1-larysa.zaremba@intel.com/\nv4:\nhttps://lore.kernel.org/bpf/20230728173923.1318596-1-larysa.zaremba@intel.com/\nv3:\nhttps://lore.kernel.org/bpf/20230719183734.21681-1-larysa.zaremba@intel.com/\nv2:\nhttps://lore.kernel.org/bpf/20230703181226.19380-1-larysa.zaremba@intel.com/\nv1:\nhttps://lore.kernel.org/all/20230512152607.992209-1-larysa.zaremba@intel.com/\n\nChanges since v7:\n* shorten timestamp assignment in ice\n* change first argument of ice_fill_rx_descs back to xsk_buff_pool\n* fix kernel-doc for ice_run_xdp_zc\n* add missing XSK_CHECK_PRIV_TYPE() in ice\n* resolved selftests merge conflicts with TX hints\n* AF_INET patch adds new packet generation', "" not replaces AF_XDP one\n* fix destination port in xdp_metadata\n\nChanges since v6:\n* add ability to fill cb of all xdp_buffs in xsk_buff_pool\n* place just pointer to packet context in ice_xdp_buff\n* add const qualifiers in veth implementation\n* generate uapi for VLAN hint\n\nChanges since v5:\n* drop checksum hint from the patchset entirely\n* Alex's patch that lifts the data_meta size limitation is no longer\n required in this patchset"", ' so will be sent separately\n* new patch: hide some ice hints code behind a static key\n* fix several bugs in ZC mode (ice)\n* change argument order in VLAN hint kfunc (tci', ' proto -> proto', ' tci)\n* cosmetic changes\n* analyze performance impact\n\nChanges since v4:\n* Drop the concept of partial checksum from the hint design\n* Drop the concept of checksum level from the hint design\n\nChanges since v3:\n* use XDP_CHECKSUM_VALID_LVL0 + csum_level instead of csum_level + 1\n* fix spelling mistakes\n* read XDP timestamp unconditionally\n* add TO_STR() macro\n\nChanges since v2:\n* redesign checksum hint', ' so now it gives full status\n* rename vlan_tag -> vlan_tci', ' where applicable\n* use open_netns() and close_netns() in xdp_metadata\n* improve VLAN hint documentation\n* replace CFI with DEI\n* use VLAN_VID_MASK in xdp_metadata\n* make vlan_get_tag() return -ENODATA\n* remove unused rx_ptype in ice_xsk.c\n* fix ice timestamp code division between patches\n\nChanges since v1:\n* directly return RX hash', ' RX timestamp and RX checksum status\n in skb-common functions\n* use intermediate enum value for checksum status in ice\n* get rid of ring structure dependency in ice kfunc implementation\n* make variables const', ' when possible', ' in ice implementation\n* use -ENODATA instead of -EOPNOTSUPP for driver implementation\n* instead of having 2 separate functions for c-tag and s-tag', '\n use 1 function that outputs both VLAN tag and protocol ID\n* improve documentation for introduced hints\n* update xdp_metadata selftest to test new hints\n* implement new hints in veth', ' so they can be tested in xdp_metadata\n* parse VLAN tag in xdp_hw_metadata\n====================\n\nLink: https://lore.kernel.org/r/20231205210847.28460-1-larysa.zaremba@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Introduces XDP metadata via kfuncs for ice driver including VLAN hint and timestamp.,"XDP, metadata, kfuncs",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['xdp like programs'] +4c6612f6100c2d85212865dbd1a5d8a7e391d3cb,4c6612f6100c2d85212865dbd1a5d8a7e391d3cb,Larysa Zaremba,larysa.zaremba@intel.com,1701810527,Alexei Starovoitov,ast@kernel.org,1702513001,69dbb3887b907d62888bd4cad1781053d55ddd3c,a3850af4ea25dadc8b35edf132340907d523657e,"selftests/bpf: Check VLAN tag and proto in xdp_metadata + +Verify"," whether VLAN tag and proto are set correctly. + +To simulate ""stripped"" VLAN tag on veth","[' send test packet from VLAN\ninterface.\n\nAlso', ' add TO_STR() macro for convenience.\n\nAcked-by: Stanislav Fomichev \nSigned-off-by: Larysa Zaremba \nLink: https://lore.kernel.org/r/20231205210847.28460-19-larysa.zaremba@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftests to verify VLAN tag and protocol settings in xdp_metadata for veth interfaces.,"VLAN, xdp_metadata, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['xdp like programs'] +a3850af4ea25dadc8b35edf132340907d523657e,a3850af4ea25dadc8b35edf132340907d523657e,Larysa Zaremba,larysa.zaremba@intel.com,1701810526,Alexei Starovoitov,ast@kernel.org,1702513001,4af552e922f067d4436cbc8afae10a1059821694,8e68a4beba943bdffb342c601c649223f44b7329,"selftests/bpf: Add AF_INET packet generation to xdp_metadata + +The easiest way to simulate stripped VLAN tag in veth is to send a packet +from VLAN interface", attached to veth. Unfortunately,"[' this approach is\nincompatible with AF_XDP on TX side', ' because VLAN interfaces do not have\nsuch feature.\n\nCheck both packets sent via AF_XDP TX and regular socket.\n\nAF_INET packet will also have a filled-in hash type (XDP_RSS_TYPE_L4)', '\nunlike AF_XDP packet', ' so more values can be checked.\n\nSigned-off-by: Larysa Zaremba \nAcked-by: Stanislav Fomichev \nLink: https://lore.kernel.org/r/20231205210847.28460-18-larysa.zaremba@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add AF_INET packet generation to xdp_metadata selftests in eBPF to simulate stripped VLAN tag using VLAN interface.,"AF_INET, packet generation, xdp_metadata",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['xdp like programs'] +8e68a4beba943bdffb342c601c649223f44b7329,8e68a4beba943bdffb342c601c649223f44b7329,Larysa Zaremba,larysa.zaremba@intel.com,1701810525,Alexei Starovoitov,ast@kernel.org,1702513001,0c688336ffa27af91694248f76cd4e64e1d38f8a,e71a9fa7fdb2effcaaed37c207ec4f634c8f4901,"selftests/bpf: Add flags and VLAN hint to xdp_hw_metadata + +Add VLAN hint to the xdp_hw_metadata program. + +Also", to make metadata layout more straightforward,"[' add flags field\nto pass information about validity of every separate hint separately.\n\nAcked-by: Stanislav Fomichev \nSigned-off-by: Larysa Zaremba \nLink: https://lore.kernel.org/r/20231205210847.28460-17-larysa.zaremba@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add VLAN hint and flags to improve xdp_hw_metadata program's metadata layout in selftests.,"VLAN,xdp_hw_metadata,metadata",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['xdp like programs'] +e71a9fa7fdb2effcaaed37c207ec4f634c8f4901,e71a9fa7fdb2effcaaed37c207ec4f634c8f4901,Larysa Zaremba,larysa.zaremba@intel.com,1701810524,Alexei Starovoitov,ast@kernel.org,1702513001,035b34479f63090f232980a99ed9bd5f2ecf6937,7978bad4b6b9265a1e808a5f679ee428d1dd6523,"selftests/bpf: Allow VLAN packets in xdp_hw_metadata + +Make VLAN c-tag and s-tag XDP hint testing more convenient +by not skipping VLAN-ed packets. + +Allow both 802.1ad and 802.1Q headers. + +Acked-by: Stanislav Fomichev +Signed-off-by: Larysa Zaremba +Link: https://lore.kernel.org/r/20231205210847.28460-16-larysa.zaremba@intel.com +Signed-off-by: Alexei Starovoitov +",,The commit updates selftests to include VLAN packets in xdp_hw_metadata for improved testing of XDP hints.,"VLAN,XDP,selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['xdp like programs'] +537fec0733c4a72e2a2b69fee365459c5b75d92e,537fec0733c4a72e2a2b69fee365459c5b75d92e,Larysa Zaremba,larysa.zaremba@intel.com,1701810522,Alexei Starovoitov,ast@kernel.org,1702513001,037548b81a240152a2d37ad07a9a2a3ed3e930f8,fca783799f64ac0a4f20228ff6a6d7598db11e64,"net: make vlan_get_tag() return -ENODATA instead of -EINVAL + +__vlan_hwaccel_get_tag() is used in veth XDP hints implementation"," +its return value (-EINVAL if skb is not VLAN tagged) is passed to bpf code","['\nbut XDP hints specification requires drivers to return -ENODATA', ' if a hint\ncannot be provided for a particular packet.\n\nSolve this inconsistency by changing error return value of\n__vlan_hwaccel_get_tag() from -EINVAL to -ENODATA', ' do the same thing to\n__vlan_get_tag()', ' because this function is supposed to follow the same\nconvention. This', ' in turn', ' makes -ENODATA the only non-zero value\nvlan_get_tag() can return. We can do this with no side effects', ' because\nnone of the users of the 3 above-mentioned functions rely on the exact\nvalue.\n\nSuggested-by: Jesper Dangaard Brouer \nAcked-by: Stanislav Fomichev \nSigned-off-by: Larysa Zaremba \nLink: https://lore.kernel.org/r/20231205210847.28460-14-larysa.zaremba@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Change vlan_get_tag() return value to -ENODATA in the veth XDP hints implementation.,"vlan_get_tag,ENODATA,XDP",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,['xdp like programs'] +e6795330f88b4f643c649a02662d47b779340535,e6795330f88b4f643c649a02662d47b779340535,Larysa Zaremba,larysa.zaremba@intel.com,1701810518,Alexei Starovoitov,ast@kernel.org,1702513000,b55bc96555ae1f9d60a1bb60c89e914fb0be148d,d68d707dcbbf6a9cfe378fc2eb3ffffd5b47727e,"xdp: Add VLAN tag hint + +Implement functionality that enables drivers to expose VLAN tag +to XDP code. + +VLAN tag is represented by 2 variables: +- protocol ID"," which is passed to bpf code in BE +- VLAN TCI","[' in host byte order\n\nAcked-by: Stanislav Fomichev \nSigned-off-by: Larysa Zaremba \nAcked-by: Jesper Dangaard Brouer \nLink: https://lore.kernel.org/r/20231205210847.28460-10-larysa.zaremba@intel.com\nSigned-off-by: Alexei Starovoitov \n', '']",Introduce functionality for XDP to process VLAN tag hints in drivers.,"XDP,VLAN,drivers",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['xdp like programs'] +733763285acfe8dffd6e39ad2ed3d1222b32a901,733763285acfe8dffd6e39ad2ed3d1222b32a901,Alexei Starovoitov,ast@kernel.org,1702511226,Alexei Starovoitov,ast@kernel.org,1702511226,666f0c5c466178d6b72de167c368259d011200fe,f04f2ce6018f3cb33ac96270b9153c2920ead190 322122bf8c75b1df78d6608516807a0354f6ab3c,"Merge branch 'bpf-token-support-in-libbpf-s-bpf-object' + +Andrii Nakryiko says: + +==================== +BPF token support in libbpf's BPF object + +Add fuller support for BPF token in high-level BPF object APIs. This is the +most frequently used way to work with BPF using libbpf"," so supporting BPF +token there is critical. + +Patch #1 is improving kernel-side BPF_TOKEN_CREATE behavior by rejecting to +create ""empty"" BPF token with no delegation. This seems like saner behavior +which also makes libbpf's caching better overall. If we ever want to create +BPF token with no delegate_xxx options set on BPF FS","[' we can use a new flag to\nenable that.\n\nPatches #2-#5 refactor libbpf internals', ' mostly feature detection code', ' to\nprepare it from BPF token FD.\n\nPatch #6 adds options to pass BPF token into BPF object open options. It also\nadds implicit BPF token creation logic to BPF object load step', ' even without\nany explicit involvement of the user. If the environment is setup properly', '\nBPF token will be created transparently and used implicitly. This allows for\nall existing application to gain BPF token support by just linking with\nlatest version of libbpf library. No source code modifications are required.\nAll that under assumption that privileged container management agent properly\nset up default BPF FS instance at /sys/bpf/fs to allow BPF token creation.\n\nPatches #7-#8 adds more selftests', ' validating BPF object APIs work as expected\nunder unprivileged user namespaced conditions in the presence of BPF token.\n\nPatch #9 extends libbpf with LIBBPF_BPF_TOKEN_PATH envvar knowledge', ' which can\nbe used to override custom BPF FS location used for implicit BPF token\ncreation logic without needing to adjust application code. This allows admins\nor container managers to mount BPF token-enabled BPF FS at non-standard\nlocation without the need to coordinate with applications.\nLIBBPF_BPF_TOKEN_PATH can also be used to disable BPF token implicit creation\nby setting it to an empty value. Patch #10 tests this new envvar functionality.\n\nv2->v3:\n - move some stray feature cache refactorings into patch #4 (Alexei);\n - add LIBBPF_BPF_TOKEN_PATH envvar support (Alexei);\nv1->v2:\n - remove minor code redundancies (Eduard', ' John);\n - add acks and rebase.\n====================\n\nLink: https://lore.kernel.org/r/20231213190842.3844987-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add BPF token support to high-level BPF object APIs in libbpf.,"BPF token,libbpf,support",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +322122bf8c75b1df78d6608516807a0354f6ab3c,322122bf8c75b1df78d6608516807a0354f6ab3c,Andrii Nakryiko,andrii@kernel.org,1702494522,Alexei Starovoitov,ast@kernel.org,1702511225,666f0c5c466178d6b72de167c368259d011200fe,ed54124b88056fd629c6af71664dfcd4d3b3e0b8,"selftests/bpf: add tests for LIBBPF_BPF_TOKEN_PATH envvar + +Add new subtest validating LIBBPF_BPF_TOKEN_PATH envvar semantics. +Extend existing test to validate that LIBBPF_BPF_TOKEN_PATH allows to +disable implicit BPF token creation by setting envvar to empty string. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-11-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add new subtest to validate behavior of LIBBPF_BPF_TOKEN_PATH environment variable in selftests.,"selftests,LIBBPF_BPF_TOKEN_PATH,subtest",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ed54124b88056fd629c6af71664dfcd4d3b3e0b8,ed54124b88056fd629c6af71664dfcd4d3b3e0b8,Andrii Nakryiko,andrii@kernel.org,1702494521,Alexei Starovoitov,ast@kernel.org,1702511225,e93d0fe0e46fd6111b15a3ea58afaf3c34df0875,18678cf0ee13cf19bac4ecd55665e6d1d63108b3,"libbpf: support BPF token path setting through LIBBPF_BPF_TOKEN_PATH envvar + +To allow external admin authority to override default BPF FS location +(/sys/fs/bpf) for implicit BPF token creation"," teach libbpf to recognize +LIBBPF_BPF_TOKEN_PATH envvar. If it is specified and user application +didn't explicitly specify neither bpf_token_path nor bpf_token_fd +option","[' it will be treated exactly like bpf_token_path option', '\noverriding default /sys/fs/bpf location and making BPF token mandatory.\n\nSuggested-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231213190842.3844987-10-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit adds support for setting BPF token path via LIBBPF_BPF_TOKEN_PATH environment variable in libbpf.,"libbpf,BPF token,environment variable",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +18678cf0ee13cf19bac4ecd55665e6d1d63108b3,18678cf0ee13cf19bac4ecd55665e6d1d63108b3,Andrii Nakryiko,andrii@kernel.org,1702494520,Alexei Starovoitov,ast@kernel.org,1702511225,bb34410c2c7e36319fe0849ad74c0672b95075b6,98e0eaa36adfb580a3aa43fca62847ec0f625d3f,"selftests/bpf: add tests for BPF object load with implicit token + +Add a test to validate libbpf's implicit BPF token creation from default +BPF FS location (/sys/fs/bpf). Also validate that disabling this +implicit BPF token creation works. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add selftests for BPF object load with implicit token creation in libbpf.,"selftests, BPF, libbpf",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +98e0eaa36adfb580a3aa43fca62847ec0f625d3f,98e0eaa36adfb580a3aa43fca62847ec0f625d3f,Andrii Nakryiko,andrii@kernel.org,1702494519,Alexei Starovoitov,ast@kernel.org,1702511225,5224619e77c256f19d73feee7155c5cbc851c6f8,1d0dd6ea2e38c18e1b31a8c3c59b6bdfe4f4efde,"selftests/bpf: add BPF object loading tests with explicit token passing + +Add a few tests that attempt to load BPF object containing privileged +map", program,"[' and the one requiring mandatory BTF uploading into the\nkernel (to validate token FD propagation to BPF_BTF_LOAD command).\n\nAcked-by: John Fastabend \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231213190842.3844987-8-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftests for BPF object loading with explicit token passing focusing on privileged maps.,"selftests,BPF,token",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1d0dd6ea2e38c18e1b31a8c3c59b6bdfe4f4efde,1d0dd6ea2e38c18e1b31a8c3c59b6bdfe4f4efde,Andrii Nakryiko,andrii@kernel.org,1702494518,Alexei Starovoitov,ast@kernel.org,1702511225,ef35de7393a9be3caa6619a303c799dee185d816,a75bb6a16518d4a224f24116633f3f9d5787f6d1,"libbpf: wire up BPF token support at BPF object level + +Add BPF token support to BPF object-level functionality. + +BPF token is supported by BPF object logic either as an explicitly +provided BPF token from outside (through BPF FS path or explicit BPF +token FD)"," or implicitly (unless prevented through +bpf_object_open_opts). + +Implicit mode is assumed to be the most common one for user namespaced +unprivileged workloads. The assumption is that privileged container +manager sets up default BPF FS mount point at /sys/fs/bpf with BPF token +delegation options (delegate_{cmds","['maps', 'progs', 'attachs} mount options).\nBPF object during loading will attempt to create BPF token from\n/sys/fs/bpf location', ' and pass it for all relevant operations\n(currently', ' map creation', ' BTF load', ' and program load).\n\nIn this implicit mode', ' if BPF token creation fails due to whatever\nreason (BPF FS is not mounted', "" or kernel doesn't support BPF token"", '\netc)', ' this is not considered an error. BPF object loading sequence will\nproceed with no BPF token.\n\nIn explicit BPF token mode', ' user provides explicitly either custom BPF\nFS mount point path or creates BPF token on their own and just passes\ntoken FD directly. In such case', ' BPF object will either dup() token FD\n(to not require caller to hold onto it for entire duration of BPF object\nlifetime) or will attempt to create BPF token from provided BPF FS\nlocation. If BPF token creation fails', ' that is considered a critical\nerror and BPF object load fails with an error.\n\nLibbpf provides a way to disable implicit BPF token creation', "" if it\ncauses any troubles (BPF token is designed to be completely optional and\nshouldn't cause any problems even if provided"", ' but in the world of BPF\nLSM', "" custom security logic can be installed that might change outcome\ndependin on the presence of BPF token). To disable libbpf's default BPF\ntoken creation behavior user should provide either invalid BPF token FD\n(negative)"", "" or empty bpf_token_path option.\n\nBPF token presence can influence libbpf's feature probing"", ' so if BPF\nobject has associated BPF token', ' feature probing is instructed to use\nBPF object-specific feature detection cache and token FD.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231213190842.3844987-7-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit adds BPF token support to BPF object-level functionality in libbpf.,"BPF token, BPF object, libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a75bb6a16518d4a224f24116633f3f9d5787f6d1,a75bb6a16518d4a224f24116633f3f9d5787f6d1,Andrii Nakryiko,andrii@kernel.org,1702494517,Alexei Starovoitov,ast@kernel.org,1702511225,274590f941b41c8b6565c9e1c7d99cac00062594,ab8fc393b27cd2d6dd1ced1ba2358ddcd123fc15,"libbpf: wire up token_fd into feature probing logic + +Adjust feature probing callbacks to take into account optional token_fd. +In unprivileged contexts"," some feature detectors would fail to detect +kernel support just because BPF program","[' BPF map', "" or BTF object can't be\nloaded due to privileged nature of those operations. So when BPF object\nis loaded with BPF token"", ' this token should be used for feature probing.\n\nThis patch is setting support for this scenario', "" but we don't yet pass\nnon-zero token FD. This will be added in the next patch.\n\nWe also switched BPF cookie detector from using kprobe program to\ntracepoint one"", ' as tracepoint is somewhat less dangerous BPF program\ntype and has higher likelihood of being allowed through BPF token in the\nfuture. This change has no effect on detection behavior.\n\nAcked-by: John Fastabend \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231213190842.3844987-6-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit adjusts feature probing logic to incorporate the optional token_fd in libbpf.,"libbpf, token_fd, feature",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ab8fc393b27cd2d6dd1ced1ba2358ddcd123fc15,ab8fc393b27cd2d6dd1ced1ba2358ddcd123fc15,Andrii Nakryiko,andrii@kernel.org,1702494516,Alexei Starovoitov,ast@kernel.org,1702511225,524a70762bbe40613a41701e3a1487d3b4f8f62c,29c302a2e265a356434b005155990a9e766db75d,"libbpf: move feature detection code into its own file + +It's quite a lot of well isolated code"," so it seems like a good +candidate to move it out of libbpf.c to reduce its size. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Refactored libbpf by moving feature detection code to a separate file to reduce libbpf.c size.,"libbpf, refactoring, feature detection",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +29c302a2e265a356434b005155990a9e766db75d,29c302a2e265a356434b005155990a9e766db75d,Andrii Nakryiko,andrii@kernel.org,1702494515,Alexei Starovoitov,ast@kernel.org,1702511225,e40449d783e85ca73b620a87592a13ab9b7bd0c4,c6c5be3eee975ae640966844db66d404c1de79b1,"libbpf: further decouple feature checking logic from bpf_object + +Add feat_supported() helper that accepts feature cache instead of +bpf_object. This allows low-level code in bpf.c to not know or care +about higher-level concept of bpf_object"," yet it will be able to utilize +custom feature checking in cases where BPF token might influence the +outcome. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Decouples feature checking logic from bpf_object using a feat_supported helper.,"Libbpf, feature checking, decouple",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c6c5be3eee975ae640966844db66d404c1de79b1,c6c5be3eee975ae640966844db66d404c1de79b1,Andrii Nakryiko,andrii@kernel.org,1702494514,Alexei Starovoitov,ast@kernel.org,1702511224,192b7deee31859e25e5c398eeba69b76fecde9ab,f5fdb51fb980077a4c6c78f3f775821f611fb38b,"libbpf: split feature detectors definitions from cached results + +Split a list of supported feature detectors with their corresponding +callbacks from actual cached supported/missing values. This will allow +to have more flexible per-token or per-object feature detectors in +subsequent refactorings. + +Acked-by: John Fastabend +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231213190842.3844987-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,The commit separates feature detectors definitions from cached results for more flexibility in libbpf.,"libbpf,feature detectors,refactoring",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f5fdb51fb980077a4c6c78f3f775821f611fb38b,f5fdb51fb980077a4c6c78f3f775821f611fb38b,Andrii Nakryiko,andrii@kernel.org,1702494513,Alexei Starovoitov,ast@kernel.org,1702511224,fa1e7a72820564b8bab55f1c448f446d68b0c41f,f04f2ce6018f3cb33ac96270b9153c2920ead190,"bpf: fail BPF_TOKEN_CREATE if no delegation option was set on BPF FS + +It's quite confusing in practice when it's possible to successfully +create a BPF token from BPF FS that didn't have any of delegate_xxx +mount options set up. While it's not wrong"," it's actually more +meaningful to reject BPF_TOKEN_CREATE with specific error code (-ENOENT) +to let user-space know that no token delegation is setup up. + +So","["" instead of creating empty BPF token that will be always ignored\nbecause it doesn't have any of the allow_xxx bits set"", ' reject it with\n-ENOENT. If we ever need empty BPF token to be possible', ' we can support\nthat with extra flag passed into BPF_TOKEN_CREATE.\n\nAcked-by: Christian Brauner \nAcked-by: John Fastabend \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231213190842.3844987-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit modifies BPF_TOKEN_CREATE to fail with -ENOENT if no delegation option is set on BPF FS.,"BPF_TOKEN_CREATE, delegation, ENOENT",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f04f2ce6018f3cb33ac96270b9153c2920ead190,f04f2ce6018f3cb33ac96270b9153c2920ead190,Daniel Xu,dxu@dxuuu.xyz,1702326009,Martin KaFai Lau,martin.lau@kernel.org,1702510939,ac228342dfc73df332fd8e2e6683eda4e974faba,7d19c00e9abc8ad3b3b72a1989331f45287e6bf5,"bpf: selftests: Add verifier tests for CO-RE bitfield writes + +Add some tests that exercise BPF_CORE_WRITE_BITFIELD() macro. Since some +non-trivial bit fiddling is going on"," make sure various edge cases (such +as adjacent bitfields and bitfields at the edge of structs) are +exercised. + +Acked-by: Andrii Nakryiko +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/72698a1080fa565f541d5654705255984ea2a029.1702325874.git.dxu@dxuuu.xyz +Signed-off-by: Martin KaFai Lau +",[''],Add selftests for CO-RE bitfield writes in the eBPF verifier.,"CO-RE, selftests, bitfield",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7d19c00e9abc8ad3b3b72a1989331f45287e6bf5,7d19c00e9abc8ad3b3b72a1989331f45287e6bf5,Daniel Xu,dxu@dxuuu.xyz,1702326008,Martin KaFai Lau,martin.lau@kernel.org,1702510939,43d32ff70ef9ac3c32d6069727533e8221773375,2f70803532e9b7f14897d17f8944d431755661a7,"bpf: selftests: test_loader: Support __btf_path() annotation + +This commit adds support for per-prog btf_custom_path. This is necessary +for testing CO-RE relocations on non-vmlinux types using test_loader +infrastructure. + +Acked-by: Andrii Nakryiko +Signed-off-by: Daniel Xu +Link: https://lore.kernel.org/r/660ea7f2fdbdd5103bc1af87c9fc931f05327926.1702325874.git.dxu@dxuuu.xyz +Signed-off-by: Martin KaFai Lau +",,This commit adds support for per-prog BTF custom paths for testing CO-RE relocations.,"selftests,test_loader,BTF",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2f70803532e9b7f14897d17f8944d431755661a7,2f70803532e9b7f14897d17f8944d431755661a7,Daniel Xu,dxu@dxuuu.xyz,1702326007,Martin KaFai Lau,martin.lau@kernel.org,1702510939,ab08d0b4221ea3a86efbe26efcfff7ac2b20bac7,750e785796bb72423b97cac21ecd0fa3b3b65610,"libbpf: Add BPF_CORE_WRITE_BITFIELD() macro + +=== Motivation === + +Similar to reading from CO-RE bitfields"," we need a CO-RE aware bitfield +writing wrapper to make the verifier happy. + +Two alternatives to this approach are: + +1. Use the upcoming `preserve_static_offset` [0] attribute to disable + CO-RE on specific structs. +2. Use broader byte-sized writes to write to bitfields. + +(1) is a bit hard to use. It requires specific and not-very-obvious +annotations to bpftool generated vmlinux.h. It's also not generally +available in released LLVM versions yet. + +(2) makes the code quite hard to read and write. And especially if +BPF_CORE_READ_BITFIELD() is already being used","[' it makes more sense to\nto have an inverse helper for writing.\n\n=== Implementation details ===\n\nSince the logic is a bit non-obvious', "" I thought it would be helpful\nto explain exactly what's going on.\n\nTo start"", ' it helps by explaining what LSHIFT_U64 (lshift) and RSHIFT_U64\n(rshift) is designed to mean. Consider the core of the\nBPF_CORE_READ_BITFIELD() algorithm:\n\n val <<= __CORE_RELO(s', ' field', ' LSHIFT_U64);\n val = val >> __CORE_RELO(s', ' field', ' RSHIFT_U64);\n\nBasically what happens is we lshift to clear the non-relevant (blank)\nhigher order bits. Then we rshift to bring the relevant bits (bitfield)\ndown to LSB position (while also clearing blank lower order bits). To\nillustrate:\n\n Start: ........XXX......\n Lshift: XXX......00000000\n Rshift: 00000000000000XXX\n\nwhere `.` means blank bit', ' `0` means 0 bit', ' and `X` means bitfield bit.\n\nAfter the two operations', ' the bitfield is ready to be interpreted as a\nregular integer.\n\nNext', ' we want to build an alternative (but more helpful) mental model\non lshift and rshift. That is', ' to consider:\n\n* rshift as the total number of blank bits in the u64\n* lshift as number of blank bits left of the bitfield in the u64\n\nTake a moment to consider why that is true by consulting the above\ndiagram.\n\nWith this insight', ' we can now define the following relationship:\n\n bitfield\n _\n | |\n 0.....00XXX0...00\n | | | |\n |______| | |\n lshift | |\n |____|\n (rshift - lshift)\n\nThat is', ' we know the number of higher order blank bits is just lshift.\nAnd the number of lower order blank bits is (rshift - lshift).\n\nFinally', ' we can examine the core of the write side algorithm:\n\n mask = (~0ULL << rshift) >> lshift; // 1\n val = (val & ~mask) | ((nval << rpad) & mask); // 2\n\n1. Compute a mask where the set bits are the bitfield bits. The first\n left shift zeros out exactly the number of blank bits', ' leaving a\n bitfield sized set of 1s. The subsequent right shift inserts the\n correct amount of higher order blank bits.\n\n2. On the left of the `|`', ' mask out the bitfield bits. This creates\n 0s where the new bitfield bits will go. On the right of the `|`', '\n bring nval into the correct bit position and mask out any bits\n that fall outside of the bitfield. Finally', "" by bor'ing the two\n halves"", ' we get the final set of bits to write back.\n\n[0]: https://reviews.llvm.org/D133361\nCo-developed-by: Eduard Zingerman \nSigned-off-by: Eduard Zingerman \nCo-developed-by: Jonathan Lemon \nSigned-off-by: Jonathan Lemon \nAcked-by: Andrii Nakryiko \nSigned-off-by: Daniel Xu \nLink: https://lore.kernel.org/r/4d3dd215a4fd57d980733886f9c11a45e1a9adf3.1702325874.git.dxu@dxuuu.xyz\nSigned-off-by: Martin KaFai Lau \n', '']",Add new macro BPF_CORE_WRITE_BITFIELD() in libbpf for CO-RE bitfield writing.,"macro, libbpf, bitfield",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +750e785796bb72423b97cac21ecd0fa3b3b65610,750e785796bb72423b97cac21ecd0fa3b3b65610,Jie Jiang,jiejiang@chromium.org,1702373963,Andrii Nakryiko,andrii@kernel.org,1702510662,f45a5ce7eeff2440d7a9bce98d8f584666473ed0,62d9a969f4a95219c757831e9ad66cd4dd9edee5,"bpf: Support uid and gid when mounting bpffs + +Parse uid and gid in bpf_parse_param() so that they can be passed in as +the `data` parameter when mount() bpffs. This will be useful when we +want to control which user/group has the control to the mounted bpffs"," +otherwise a separate chown() call will be needed. + +Signed-off-by: Jie Jiang +Signed-off-by: Andrii Nakryiko +Acked-by: Mike Frysinger +Acked-by: Christian Brauner +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231212093923.497838-1-jiejiang@chromium.org +",[''],The commit adds support for uid and gid when mounting bpffs to control user/group access.,"uid,gid,bpffs",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +62d9a969f4a95219c757831e9ad66cd4dd9edee5,62d9a969f4a95219c757831e9ad66cd4dd9edee5,Andrii Nakryiko,andrii@kernel.org,1702421623,Alexei Starovoitov,ast@kernel.org,1702492036,ea7d27642c644b1bdaa949b40d68de7a99b8f79d,e1ba7f64b192f083b4423644be03bb9e3dc8ae84,"selftests/bpf: fix compiler warnings in RELEASE=1 mode + +When compiling BPF selftests with RELEASE=1"," we get two new +warnings","[' which are treated as errors. Fix them.\n\nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/r/20231212225343.1723081-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit fixes compiler warnings in BPF selftests when using RELEASE=1.,"compiler, warnings, selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +43e8832fed08438e2a27afed9bac21acd0ceffe5,43e8832fed08438e2a27afed9bac21acd0ceffe5,John Hubbard,jhubbard@nvidia.com,1702087304,Andrew Morton,akpm@linux-foundation.org,1702430419,d8bc723f4f4aba6048f5262e2d879350b2aac92c,1dd11e977360ad3493812da0b05ffd9adcdd15a1,"Revert ""selftests: error out if kernel header files are not yet built"" + +This reverts commit 9fc96c7c19df (""selftests: error out if kernel header +files are not yet built""). + +It turns out that requiring the kernel headers to be built as a +prerequisite to building selftests"," does not work in many cases. For +example","[' Peter Zijlstra writes:\n\n""My biggest beef with the whole thing is that I simply do not want to use\n\'make headers\'', "" it doesn't work for me.\n\nI have a ton of output directories and I don't care to build tools into\nthe output dirs"", ' in fact some of them flat out refuse to work that way\n(bpf comes to mind)."" [1]\n\nTherefore', ' stop erroring out on the selftests build. Additional patches\nwill be required in order to change over to not requiring the kernel\nheaders.\n\n[1] https://lore.kernel.org/20231208221007.GO28727@noisy.programming.kicks-ass.net\n\nLink: https://lkml.kernel.org/r/20231209020144.244759-1-jhubbard@nvidia.com\nFixes: 9fc96c7c19df (""selftests: error out if kernel header files are not yet built"")\nSigned-off-by: John Hubbard \nCc: Anders Roxell \nCc: Muhammad Usama Anjum \nCc: David Hildenbrand \nCc: Peter Xu \nCc: Jonathan Corbet \nCc: Nathan Chancellor \nCc: Shuah Khan \nCc: Peter Zijlstra \nCc: Marcos Paulo de Souza \nCc: \nSigned-off-by: Andrew Morton \n', '']",Revert a change requiring kernel headers to be built before selftests due to compatibility issues.,"revert,selftests,headers",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +e1ba7f64b192f083b4423644be03bb9e3dc8ae84,e1ba7f64b192f083b4423644be03bb9e3dc8ae84,YiFei Zhu,zhuyifei@google.com,1702405751,Andrii Nakryiko,andrii@kernel.org,1702425214,b17c94ac4d510c0f573e4207f1ed02c046aac3cd,745e0311306507ddbe1727ac798c8f956812b810,"selftests/bpf: Relax time_tai test for equal timestamps in tai_forward + +We're observing test flakiness on an arm64 platform which might not +have timestamps as precise as x86. The test log looks like: + + test_time_tai:PASS:tai_open 0 nsec + test_time_tai:PASS:test_run 0 nsec + test_time_tai:PASS:tai_ts1 0 nsec + test_time_tai:PASS:tai_ts2 0 nsec + test_time_tai:FAIL:tai_forward unexpected tai_forward: actual 1702348135471494160 <= expected 1702348135471494160 + test_time_tai:PASS:tai_gettime 0 nsec + test_time_tai:PASS:tai_future_ts1 0 nsec + test_time_tai:PASS:tai_future_ts2 0 nsec + test_time_tai:PASS:tai_range_ts1 0 nsec + test_time_tai:PASS:tai_range_ts2 0 nsec + #199 time_tai:FAIL + +This patch changes ASSERT_GT to ASSERT_GE in the tai_forward assertion +so that equal timestamps are permitted. + +Fixes: 64e15820b987 (""selftests/bpf: Add BPF-helper test for CLOCK_TAI access"") +Signed-off-by: YiFei Zhu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231212182911.3784108-1-zhuyifei@google.com +",,Relaxed the tai_forward test assertion to allow equal timestamps to fix flakiness in ARM64 platforms.,"test, timestamps, ARM64",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +745e0311306507ddbe1727ac798c8f956812b810,745e0311306507ddbe1727ac798c8f956812b810,Andrei Matei,andreimatei1@gmail.com,1702248710,Andrii Nakryiko,andrii@kernel.org,1702424132,b21a12da3e98d9621086ab49e6d4b2c2e103db58,56c26d5ad86dfe48a76855a91b523ab4f372c003,"bpf: Comment on check_mem_size_reg + +This patch adds a comment to check_mem_size_reg -- a function whose +meaning is not very transparent. The function implicitly deals with two +registers connected by convention"," which is not obvious. + +Signed-off-by: Andrei Matei +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231210225149.67639-1-andreimatei1@gmail.com +",[''],Added comments to clarify functionality of check_mem_size_reg function in bpf code.,"comments, check_mem_size_reg, function",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5805c82513c444333efb086017be8d666336858a,5805c82513c444333efb086017be8d666336858a,Ian Rogers,irogers@google.com,1701237722,Arnaldo Carvalho de Melo,acme@redhat.com,1702403713,dccb7163cb771cc7637126d4c712fa82a3fb9c38,effe957c6bb70cac12918c0f5fd4cefb35967618,"libperf cpumap: Add for_each_cpu() that skips the ""any CPU"" case + +When iterating CPUs in a CPU map it is often desirable to skip the ""any +CPU"" (aka dummy) case. Add a helper for this and use in builtin-record. + +Reviewed-by: James Clark +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Alexandre Ghiti +Cc: Andrew Jones +Cc: André Almeida +Cc: Athira Jajeev +Cc: Atish Patra +Cc: Changbin Du +Cc: Darren Hart +Cc: Davidlohr Bueso +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: John Garry +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Mark Rutland +Cc: Mike Leach +Cc: Namhyung Kim +Cc: Nick Desaulniers +Cc: Paolo Bonzini +Cc: Paran Lee +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Suzuki Poulouse +Cc: Thomas Gleixner +Cc: Will Deacon +Cc: Yang Jihong +Cc: Yang Li +Cc: Yanteng Si +Cc: bpf@vger.kernel.org +Cc: coresight@lists.linaro.org +Cc: linux-arm-kernel@lists.infradead.org +Link: https://lore.kernel.org/r/20231129060211.1890454-6-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",,"Add a helper function for iterating CPUs in a CPU map that skips the ""any CPU"" case in libperf.","libperf, cpumap, helper",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +effe957c6bb70cac12918c0f5fd4cefb35967618,effe957c6bb70cac12918c0f5fd4cefb35967618,Ian Rogers,irogers@google.com,1701237721,Arnaldo Carvalho de Melo,acme@redhat.com,1702403713,e3c45ab066f748aec276c02f97dfbbd9fd7ffb98,923ca62a7b1edceaa61eb6ac8dc56fdac51913b8,"libperf cpumap: Replace usage of perf_cpu_map__new(NULL) with perf_cpu_map__new_online_cpus() + +Passing NULL to perf_cpu_map__new() performs +perf_cpu_map__new_online_cpus()"," just directly call +perf_cpu_map__new_online_cpus() to be more intention revealing. + +Reviewed-by: James Clark +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Alexandre Ghiti +Cc: Andrew Jones +Cc: André Almeida +Cc: Athira Jajeev +Cc: Atish Patra +Cc: Changbin Du +Cc: Darren Hart +Cc: Davidlohr Bueso +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: John Garry +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Mark Rutland +Cc: Mike Leach +Cc: Namhyung Kim +Cc: Nick Desaulniers +Cc: Paolo Bonzini +Cc: Paran Lee +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Suzuki Poulouse +Cc: Thomas Gleixner +Cc: Will Deacon +Cc: Yang Jihong +Cc: Yang Li +Cc: Yanteng Si +Cc: bpf@vger.kernel.org +Cc: coresight@lists.linaro.org +Cc: linux-arm-kernel@lists.infradead.org +Link: https://lore.kernel.org/r/20231129060211.1890454-5-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",[''],Replaces perf_cpu_map__new(NULL) with perf_cpu_map__new_online_cpus() for clearer intention in libperf cpumap.,"libperf, cpumap, intention",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +923ca62a7b1edceaa61eb6ac8dc56fdac51913b8,923ca62a7b1edceaa61eb6ac8dc56fdac51913b8,Ian Rogers,irogers@google.com,1701237720,Arnaldo Carvalho de Melo,acme@redhat.com,1702403713,4e8e184704835cbf9216d5549b772b6d4ea36443,8f60f870a9af53295ab4301da05ca453f115a6b6,"libperf cpumap: Rename perf_cpu_map__empty() to perf_cpu_map__has_any_cpu_or_is_empty() + +The name perf_cpu_map_empty is misleading as true is also returned +when the map contains an ""any"" CPU (aka dummy) map. + +Rename to perf_cpu_map__has_any_cpu_or_is_empty()"," later changes will +(re)introduce perf_cpu_map__empty() and perf_cpu_map__has_any_cpu(). + +Reviewed-by: James Clark +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Alexandre Ghiti +Cc: Andrew Jones +Cc: André Almeida +Cc: Athira Jajeev +Cc: Atish Patra +Cc: Changbin Du +Cc: Darren Hart +Cc: Davidlohr Bueso +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: John Garry +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Mark Rutland +Cc: Mike Leach +Cc: Namhyung Kim +Cc: Nick Desaulniers +Cc: Paolo Bonzini +Cc: Paran Lee +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Suzuki Poulouse +Cc: Thomas Gleixner +Cc: Will Deacon +Cc: Yang Jihong +Cc: Yang Li +Cc: Yanteng Si +Cc: bpf@vger.kernel.org +Cc: coresight@lists.linaro.org +Cc: linux-arm-kernel@lists.infradead.org +Link: https://lore.kernel.org/r/20231129060211.1890454-4-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",[''],Renamed a misleading function in libperf cpumap to improve accuracy and clarity.,"function, rename, libperf",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +8f60f870a9af53295ab4301da05ca453f115a6b6,8f60f870a9af53295ab4301da05ca453f115a6b6,Ian Rogers,irogers@google.com,1701237719,Arnaldo Carvalho de Melo,acme@redhat.com,1702403691,fe0d76023e83ba03a938c71e806e21b6297ee12f,48219b089d84f109e8a81d8a7fa1bbc2e6e5f97d,"libperf cpumap: Rename perf_cpu_map__default_new() to perf_cpu_map__new_online_cpus() and prefer sysfs + +Rename perf_cpu_map__default_new() to perf_cpu_map__new_online_cpus() to +better indicate what the implementation does. + +Read the online CPUs from /sys/devices/system/cpu/online first before +using sysconf() as it can't accurately configure holes in the CPU map. + +If sysconf() is used"," warn when the configured and online processors +disagree. + +When reading from a file","["" if the read doesn't yield a CPU map then\nreturn an empty map rather than the default online. This avoids\nrecursion but also better yields being able to detect failures.\n\nAdd more comments.\n\nReviewed-by: James Clark \nSigned-off-by: Ian Rogers \nCc: Adrian Hunter \nCc: Alexander Shishkin \nCc: Alexandre Ghiti \nCc: Andrew Jones \nCc: André Almeida \nCc: Athira Jajeev \nCc: Atish Patra \nCc: Changbin Du \nCc: Darren Hart \nCc: Davidlohr Bueso \nCc: Huacai Chen \nCc: Ingo Molnar \nCc: Jiri Olsa \nCc: John Garry \nCc: K Prateek Nayak \nCc: Kajol Jain \nCc: Kan Liang \nCc: Leo Yan \nCc: Mark Rutland \nCc: Mike Leach \nCc: Namhyung Kim \nCc: Nick Desaulniers \nCc: Paolo Bonzini \nCc: Paran Lee \nCc: Peter Zijlstra \nCc: Ravi Bangoria \nCc: Sandipan Das \nCc: Sean Christopherson \nCc: Steinar H. Gunderson \nCc: Suzuki Poulouse \nCc: Thomas Gleixner \nCc: Will Deacon \nCc: Yang Jihong \nCc: Yang Li \nCc: Yanteng Si \nCc: bpf@vger.kernel.org\nCc: coresight@lists.linaro.org\nCc: linux-arm-kernel@lists.infradead.org\nLink: https://lore.kernel.org/r/20231129060211.1890454-3-irogers@google.com\n[ s/syfs/sysfs/g typo ]\nSigned-off-by: Arnaldo Carvalho de Melo \n"", '']",The commit renames a function to better describe its function of reading online CPUs from sysfs in the libperf library.,"rename, libperf, cpumap",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +56c26d5ad86dfe48a76855a91b523ab4f372c003,56c26d5ad86dfe48a76855a91b523ab4f372c003,Yang Li,yang.lee@linux.alibaba.com,1702342476,Andrii Nakryiko,andrii@kernel.org,1702403527,4faf507a12b0dd6209e75b4b9b82a32d901c2111,f77d795618b92ac6fdb43de0d4036c6ce49f0b82,"bpf: Remove unused backtrack_state helper functions + +The function are defined in the verifier.c file"," but not called +elsewhere","["" so delete the unused function.\n\nkernel/bpf/verifier.c:3448:20: warning: unused function 'bt_set_slot'\nkernel/bpf/verifier.c:3453:20: warning: unused function 'bt_clear_slot'\nkernel/bpf/verifier.c:3488:20: warning: unused function 'bt_is_slot_set'\n\nReported-by: Abaci Robot \nSigned-off-by: Yang Li \nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20231212005436.103829-1-yang.lee@linux.alibaba.com\n\nCloses: https://bugzilla.openanolis.cn/show_bug.cgi?id=7714\n"", '']",Remove unused helper functions from verifier.c file in bpf codebase.,"unused, backtrack, helper",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f77d795618b92ac6fdb43de0d4036c6ce49f0b82,f77d795618b92ac6fdb43de0d4036c6ce49f0b82,Manu Bretelle,chantr4@gmail.com,1702318053,Andrii Nakryiko,andrii@kernel.org,1702403507,bdd7ffd7f63d34d778f1296294fd194ee2da17ec,406a6fa44bfbc8563f0612b08d43df2fa65e8bc5,"selftests/bpf: Fixes tests for filesystem kfuncs + +`fs_kfuncs.c`'s `test_xattr` would fail the test even when the +filesystem did not support xattr"," for instance when /tmp is mounted as +tmpfs. + +This change checks errno when setxattr fail. If the failure is due to +the operation being unsupported","[' we will skip the test (just like we\nwould if verity was not enabled on the FS.\n\nBefore the change', "" fs_kfuncs test would fail in test_axattr:\n\n $ vmtest -k $(make -s image_name) './tools/testing/selftests/bpf/test_progs -a fs_kfuncs'\n => bzImage\n ===> Booting\n [ 0.000000] rcu: RCU restricting CPUs from NR_CPUS=128 to\n nr_cpu_\n ===> Setting up VM\n ===> Running command\n [ 4.157491] bpf_testmod: loading out-of-tree module taints kernel.\n [ 4.161515] bpf_testmod: module verification failed: signature and/or\n required key missing - tainting kernel\n test_xattr:PASS:create_file 0 nsec\n test_xattr:FAIL:setxattr unexpected error: -1 (errno 95)\n #90/1 fs_kfuncs/xattr:FAIL\n #90/2 fs_kfuncs/fsverity:SKIP\n #90 fs_kfuncs:FAIL\n\n All error logs:\n test_xattr:PASS:create_file 0 nsec\n test_xattr:FAIL:setxattr unexpected error: -1 (errno 95)\n #90/1 fs_kfuncs/xattr:FAIL\n #90 fs_kfuncs:FAIL\n\n Summary: 0/0 PASSED"", ' 1 SKIPPED', "" 1 FAILED\n\nTest plan:\n\n $ touch tmpfs_file && truncate -s 1G tmpfs_file && mkfs.ext4 tmpfs_file\n # /tmp mounted as tmpfs\n $ vmtest -k $(make -s image_name) './tools/testing/selftests/bpf/test_progs -a fs_kfuncs'\n => bzImage\n ===> Booting\n ===> Setting up VM\n ===> Running command\n WARNING! Selftests relying on bpf_testmod.ko will be skipped.\n Can't find bpf_testmod.ko kernel module: -2\n #90/1 fs_kfuncs/xattr:SKIP\n #90/2 fs_kfuncs/fsverity:SKIP\n #90 fs_kfuncs:SKIP\n Summary: 1/0 PASSED"", ' 2 SKIPPED', "" 0 FAILED\n # /tmp mounted as ext4 with xattr enabled but not verity\n $ vmtest -k $(make -s image_name) 'mount -o loop tmpfs_file /tmp && \\\n /tools/testing/selftests/bpf/test_progs -a fs_kfuncs'\n => bzImage\n ===> Booting\n ===> Setting up VM\n ===> Running command\n [ 4.067071] loop0: detected capacity change from 0 to 2097152\n [ 4.191882] EXT4-fs (loop0): mounted filesystem\n 407ffa36-4553-4c8c-8c78-134443630f69 r/w with ordered data mode. Quota\n mode: none.\n WARNING! Selftests relying on bpf_testmod.ko will be skipped.\n Can't find bpf_testmod.ko kernel module: -2\n #90/1 fs_kfuncs/xattr:OK\n #90/2 fs_kfuncs/fsverity:SKIP\n #90 fs_kfuncs:OK (SKIP: 1/2)\n Summary: 1/1 PASSED"", ' 1 SKIPPED', ' 0 FAILED\n $ tune2fs -O verity tmpfs_file\n # /tmp as ext4 with both xattr and verity enabled\n $ vmtest -k $(make -s image_name) \'mount -o loop tmpfs_file /tmp && \\\n ./tools/testing/selftests/bpf/test_progs -a fs_kfuncs\'\n => bzImage\n ===> Booting\n ===> Setting up VM\n ===> Running command\n [ 4.291434] loop0: detected capacity change from 0 to 2097152\n [ 4.460828] EXT4-fs (loop0): recovery complete\n [ 4.468631] EXT4-fs (loop0): mounted filesystem\n 7b4a7b7f-c442-4b06-9ede-254e63cceb52 r/w with ordered data mode. Quota\n mode: none.\n [ 4.988074] fs-verity: sha256 using implementation ""sha256-generic""\n WARNING! Selftests relying on bpf_testmod.ko will be skipped.\n Can\'t find bpf_testmod.ko kernel module: -2\n #90/1 fs_kfuncs/xattr:OK\n #90/2 fs_kfuncs/fsverity:OK\n #90 fs_kfuncs:OK\n Summary: 1/2 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\nFixes: 341f06fdddf7 (""selftests/bpf: Add tests for filesystem kfuncs"")\nSigned-off-by: Manu Bretelle \nSigned-off-by: Andrii Nakryiko \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/bpf/20231211180733.763025-1-chantr4@gmail.com\n', '']",Fixes tests for filesystem kfuncs by checking errno when setxattr fails due to unsupported operations.,"fixes, filesystem, kfuncs",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +48219b089d84f109e8a81d8a7fa1bbc2e6e5f97d,48219b089d84f109e8a81d8a7fa1bbc2e6e5f97d,Ian Rogers,irogers@google.com,1701237718,Arnaldo Carvalho de Melo,acme@redhat.com,1702400507,29d8dcfadc1e834b1755cfe5002ecf10112501d4,8596ba324356a7392a6639024de8c9ae7a9fce92,"libperf cpumap: Rename perf_cpu_map__dummy_new() to perf_cpu_map__new_any_cpu() + +Rename perf_cpu_map__dummy_new() to perf_cpu_map__new_any_cpu() to +better indicate this is creating a CPU map for the perf_event_open ""any"" +CPU case. + +Reviewed-by: James Clark +Signed-off-by: Ian Rogers +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Alexandre Ghiti +Cc: Andrew Jones +Cc: André Almeida +Cc: Athira Jajeev +Cc: Atish Patra +Cc: Changbin Du +Cc: Darren Hart +Cc: Davidlohr Bueso +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: Jiri Olsa +Cc: John Garry +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Mark Rutland +Cc: Mike Leach +Cc: Namhyung Kim +Cc: Nick Desaulniers +Cc: Paolo Bonzini +Cc: Paran Lee +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Suzuki Poulouse +Cc: Thomas Gleixner +Cc: Will Deacon +Cc: Yang Jihong +Cc: Yang Li +Cc: Yanteng Si +Cc: bpf@vger.kernel.org +Cc: coresight@lists.linaro.org +Cc: linux-arm-kernel@lists.infradead.org +Link: https://lore.kernel.org/r/20231129060211.1890454-2-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",,Renamed perf_cpu_map__dummy_new() to perf_cpu_map__new_any_cpu() to clarify its purpose for 'any' CPU in perf_event_open.,"CPU map, renaming, perf_event_open",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +406a6fa44bfbc8563f0612b08d43df2fa65e8bc5,406a6fa44bfbc8563f0612b08d43df2fa65e8bc5,Andrii Nakryiko,andrii@kernel.org,1701733162,Alexei Starovoitov,ast@kernel.org,1702351417,6d216977ef78128f00c85d37d653756217906ffb,1a1ad782dcbbacd9e8d4e2e7ff1bf14d1db80727,"bpf: use bitfields for simple per-subprog bool flags + +We have a bunch of bool flags for each subprog. Instead of wasting bytes +for them"," use bitfields instead. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231204233931.49758-5-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],The commit optimizes memory usage by utilizing bitfields for subprogram boolean flags.,"bitfields, bool flags, subprog",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1a1ad782dcbbacd9e8d4e2e7ff1bf14d1db80727,1a1ad782dcbbacd9e8d4e2e7ff1bf14d1db80727,Andrii Nakryiko,andrii@kernel.org,1701733161,Alexei Starovoitov,ast@kernel.org,1702351412,2ef700bf4b474dc18dec4fcb804892f6b0887edd,22b769bb4f87060774bfdd6facbab438ed3b8453,"bpf: tidy up exception callback management a bit + +Use the fact that we are passing subprog index around and have +a corresponding struct bpf_subprog_info in bpf_verifier_env for each +subprogram. We don't need to separately pass around a flag whether +subprog is exception callback or not"," each relevant verifier function +can determine this using provided subprog index if we maintain +bpf_subprog_info properly. + +Also move out exception callback-specific logic from +btf_prepare_func_args()","[' keeping it generic. We can enforce all these\nrestriction right before exception callback verification pass. We add\nout parameter', ' arg_cnt', ' for now', ' but this will be unnecessary with\nsubsequent refactoring and will be removed.\n\nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231204233931.49758-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Refactor exception callback management using bpf_subprog_info with subprog index in bpf_verifier_env.,"exception, subprog, management",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +22b769bb4f87060774bfdd6facbab438ed3b8453,22b769bb4f87060774bfdd6facbab438ed3b8453,Andrii Nakryiko,andrii@kernel.org,1701733160,Alexei Starovoitov,ast@kernel.org,1702351282,6bf0bc18436d65f9bb2586b476c2a2c1dcb74059,1e68485d8299860e68c4e1d29589ff0d20db0287,"bpf: emit more dynptr information in verifier log + +Emit dynptr type for CONST_PTR_TO_DYNPTR register. Also emit id"," +ref_obj_id","[' and dynptr_id fields for STACK_DYNPTR stack slots.\n\nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231204233931.49758-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit enhances the verifier log by emitting more dynptr information including type and ID for CONST_PTR_TO_DYNPTR.,"dynptr,verifier log,CONST_PTR_TO_DYNPTR",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1e68485d8299860e68c4e1d29589ff0d20db0287,1e68485d8299860e68c4e1d29589ff0d20db0287,Andrii Nakryiko,andrii@kernel.org,1701733159,Alexei Starovoitov,ast@kernel.org,1702351282,f31114becd2070bb20ca79ba97020dd419c8c7e3,e72c1ccfd449598f7eda10d3bb7441d501ddcfc3,"bpf: log PTR_TO_MEM memory size in verifier log + +Emit valid memory size addressable through PTR_TO_MEM register. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231204233931.49758-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Addability to log memory size for PTR_TO_MEM in the verifier.,"PTR_TO_MEM,memory size,verifier",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e72c1ccfd449598f7eda10d3bb7441d501ddcfc3,e72c1ccfd449598f7eda10d3bb7441d501ddcfc3,Andrii Nakryiko,andrii@kernel.org,1702316491,Alexei Starovoitov,ast@kernel.org,1702350992,7a2c8fc5c837b5a8a74a5360c5129adf9a1a9b0f,2ebe81c814355d000fe49d9c4213983844dcb32b,"selftests/bpf: validate eliminated global subprog is not freplaceable + +Add selftest that establishes dead code-eliminated valid global subprog +(global_dead) and makes sure that it's not possible to freplace it"," as +it's effectively not there. This test will fail with unexpected success +before 2afae08c9dcb (""bpf: Validate global subprogs lazily""). + +v2->v3: + - add missing err assignment (Alan); + - undo unnecessary signature changes in verifier_global_subprogs.c (Eduard); +v1->v2: + - don't rely on assembly output in verifier log","[' which changes between\n compiler versions (CI).\n\nAcked-by: Eduard Zingerman \nReviewed-by: Alan Maguire \nSuggested-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: John Fastabend \nLink: https://lore.kernel.org/r/20231211174131.2324306-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftest for global subprogs to ensure non-freplaceability of dead code-eliminated subprograms.,"selftest, global subprog, freplace",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2ebe81c814355d000fe49d9c4213983844dcb32b,2ebe81c814355d000fe49d9c4213983844dcb32b,Aleksander Lobakin,aleksander.lobakin@intel.com,1701896359,Daniel Borkmann,daniel@iogearbox.net,1702307376,695a116c8cea02abc891dd2e3181e11adc48ba57,15c79c6507c0eab5ec0d4cd402ac52d42735a43e,net," xdp: Allow metadata > 32 + +32 bytes may be not enough for some custom metadata. Relax the restriction","['\nallow metadata larger than 32 bytes and make __skb_metadata_differs() work\nwith bigger lengths.\n\nNow size of metadata is only limited by the fact it is stored as u8 in\nskb_shared_info', ' so maximum possible value is 255. Size still has to be\naligned to 4', ' so the actual upper limit becomes 252. Most driver\nimplementations will offer less', ' none can offer more.\n\nOther important conditions', ' such as having enough space for xdp_frame\nbuilding', ' are already checked in bpf_xdp_adjust_meta().\n\nSigned-off-by: Aleksander Lobakin \nSigned-off-by: Larysa Zaremba \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/eb87653c-8ff8-447d-a7a1-25961f60518a@kernel.org\nLink: https://lore.kernel.org/bpf/20231206205919.404415-3-larysa.zaremba@intel.com\n', '']",The commit relaxes the metadata size restriction in XDP programs from 32 bytes to allow larger custom metadata.,"metadata,XDP,restriction",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,['xdp like programs'] +15c79c6507c0eab5ec0d4cd402ac52d42735a43e,15c79c6507c0eab5ec0d4cd402ac52d42735a43e,Larysa Zaremba,larysa.zaremba@intel.com,1701896358,Daniel Borkmann,daniel@iogearbox.net,1702307364,66d682e925a5199c0bf9e747ead7a9cd9455d8f0,5bcbdf72df88a351642627d94b93af7c9301b6e2,"selftests/bpf: Increase invalid metadata size + +Changed check expects passed data meta to be deemed invalid. After loosening +the requirement", the size of 36 bytes becomes valid. Therefore,"[' increase\ntested meta size to 256', ' so we do not get an unexpected success.\n\nSigned-off-by: Larysa Zaremba \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20231206205919.404415-2-larysa.zaremba@intel.com\n', '']",Increased invalid metadata size in selftests to ensure 36 bytes is recognized as valid.,"invalid, metadata, selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5bcbdf72df88a351642627d94b93af7c9301b6e2,5bcbdf72df88a351642627d94b93af7c9301b6e2,Alexei Starovoitov,ast@kernel.org,1702186653,Alexei Starovoitov,ast@kernel.org,1702186653,21a2ba3658473f297c164c78c15ef1ce6eedec20,5181dc08f79583c6dead80208137a97e68ff07b0 88f6047191e69bdd02cf1b9b5b514f7e514e8b86,"Merge branch 'add-new-bpf_cpumask_weight-kfunc' + +David Vernet says: + +==================== +Add new bpf_cpumask_weight() kfunc + +It can be useful to query how many bits are set in a cpumask. For +example"," if you want to perform special logic for the last remaining +core that's set in a mask. This logic is already exposed through the +main kernel's cpumask header as cpumask_weight()","[' so it would be useful\nto add a new bpf_cpumask_weight() kfunc which wraps it and does the\nsame.\n\nThis patch series was built and tested on top of commit 2146f7fe6e02\n(""Merge branch \'allocate-bpf-trampoline-on-bpf_prog_pack\'"").\n====================\n\nLink: https://lore.kernel.org/r/20231207210843.168466-1-void@manifault.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit adds a new bpf_cpumask_weight() kfunc to query the number of set bits in a cpumask.,"bpf_cpumask_weight,kfunc,cpumask",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +88f6047191e69bdd02cf1b9b5b514f7e514e8b86,88f6047191e69bdd02cf1b9b5b514f7e514e8b86,David Vernet,void@manifault.com,1701983323,Alexei Starovoitov,ast@kernel.org,1702186653,21a2ba3658473f297c164c78c15ef1ce6eedec20,a6de18f310a511278c1ff16b96eb2d500eada725,"selftests/bpf: Add test for bpf_cpumask_weight() kfunc + +The new bpf_cpumask_weight() kfunc can be used to count the number of +bits that are set in a struct cpumask* kptr. Let's add a selftest to +verify its behavior. + +Signed-off-by: David Vernet +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231207210843.168466-3-void@manifault.com +Signed-off-by: Alexei Starovoitov +",,Add a selftest for the new bpf_cpumask_weight() kfunc for verifying its functionality.,"selftest,kfunc,bpf_cpumask_weight",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a6de18f310a511278c1ff16b96eb2d500eada725,a6de18f310a511278c1ff16b96eb2d500eada725,David Vernet,void@manifault.com,1701983322,Alexei Starovoitov,ast@kernel.org,1702186653,e3a2a52d95faf82312d1e13f815fc797a4b6bf4a,5181dc08f79583c6dead80208137a97e68ff07b0,"bpf: Add bpf_cpumask_weight() kfunc + +It can be useful to query how many bits are set in a cpumask. For +example"," if you want to perform special logic for the last remaining +core that's set in a mask. Let's therefore add a new +bpf_cpumask_weight() kfunc which checks how many bits are set in a mask. + +Signed-off-by: David Vernet +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231207210843.168466-2-void@manifault.com +Signed-off-by: Alexei Starovoitov +",[''],Added a new kfunc bpf_cpumask_weight to count bits set in a cpumask.,"bpf_cpumask_weight,kfunc,cpumask",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5181dc08f79583c6dead80208137a97e68ff07b0,5181dc08f79583c6dead80208137a97e68ff07b0,Tiezhu Yang,yangtiezhu@loongson.cn,1701922131,Alexei Starovoitov,ast@kernel.org,1702186074,9473a401170286e5d0ecf3e7936fa081ca3215b6,7d8ed51bcb32716a40d71043fcd01c4118858c51,"test_bpf: Rename second ALU64_SMOD_X to ALU64_SMOD_K + +Currently"," there are two test cases with same name +""ALU64_SMOD_X: -7 % 2 = -1""","[' the first one is right', '\nthe second one should be ALU64_SMOD_K because its\ncode is BPF_ALU64 | BPF_MOD | BPF_K.\n\nBefore:\ntest_bpf: #170 ALU64_SMOD_X: -7 % 2 = -1 jited:1 4 PASS\ntest_bpf: #171 ALU64_SMOD_X: -7 % 2 = -1 jited:1 4 PASS\n\nAfter:\ntest_bpf: #170 ALU64_SMOD_X: -7 % 2 = -1 jited:1 4 PASS\ntest_bpf: #171 ALU64_SMOD_K: -7 % 2 = -1 jited:1 4 PASS\n\nFixes: daabb2b098e0 (""bpf/tests: add tests for cpuv4 instructions"")\nSigned-off-by: Tiezhu Yang \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231207040851.19730-1-yangtiezhu@loongson.cn\nSigned-off-by: Alexei Starovoitov \n', '']",This commit renames a duplicate test case in test_bpf to uniquely identify ALU64_SMOD_X operations.,"rename, test cases, ALU64_SMOD",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7d8ed51bcb32716a40d71043fcd01c4118858c51,7d8ed51bcb32716a40d71043fcd01c4118858c51,Andrii Nakryiko,andrii@kernel.org,1702084198,Alexei Starovoitov,ast@kernel.org,1702176200,767e8c161fbe31ff256f95197b9a96c615134c5d,482d548d40b0af9af730e4869903d4433e44f014,"selftests/bpf: validate fake register spill/fill precision backtracking logic + +Add two tests validating that verifier's precision backtracking logic +handles BPF_ST_MEM instructions that produce fake register spill into +register slot. This is happening when non-zero constant is written +directly to a slot", e.g.,"[' *(u64 *)(r10 -8) = 123.\n\nAdd both full 64-bit register spill', ' as well as 32-bit ""sub-spill"".\n\nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231209010958.66758-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added tests for verifier's precision backtracking logic in BPF register spill handling.,"precision, verifier, tests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +482d548d40b0af9af730e4869903d4433e44f014,482d548d40b0af9af730e4869903d4433e44f014,Andrii Nakryiko,andrii@kernel.org,1702084197,Alexei Starovoitov,ast@kernel.org,1702176200,c557d70945c6e3c8c9478df6b4ebc0639090c5bf,8477fe1de9a631d634ccfda7fe147eba90f55732,"bpf: handle fake register spill to stack with BPF_ST_MEM instruction + +When verifier validates BPF_ST_MEM instruction that stores known +constant to stack (e.g.", *(u64 *)(r10 - 8) = 123),"[' it effectively spills\na fake register with a constant (but initially imprecise) value to\na stack slot. Because read-side logic treats it as a proper register\nfill from stack slot', ' we need to mark such stack slot initialization as\nINSN_F_STACK_ACCESS instruction to stop precision backtracking from\nmissing it.\n\nFixes: 41f6f64e6999 (""bpf: support non-r10 register spill/fill to/from stack in precision tracking"")\nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231209010958.66758-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhances the eBPF verifier to correctly handle BPF_ST_MEM instruction when storing known constants to stack.,"BPF_ST_MEM, verifier, stack",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8477fe1de9a631d634ccfda7fe147eba90f55732,8477fe1de9a631d634ccfda7fe147eba90f55732,Alexei Starovoitov,ast@kernel.org,1702174354,Alexei Starovoitov,ast@kernel.org,1702174403,c83148f14906289ef86d99908011d97a4fb8aba1,32fa058398624166dd04ff4af49cfef69c94abbc 06e5c999f10269a532304e89a6adb2fbfeb0593c,"Merge branch 'bpf-fixes-for-maybe_wait_bpf_programs' + +Hou Tao says: + +==================== +The patch set aims to fix the problems found when inspecting the code +related with maybe_wait_bpf_programs(). + +Patch #1 removes unnecessary invocation of maybe_wait_bpf_programs(). +Patch #2 calls maybe_wait_bpf_programs() only once for batched update. +Patch #3 adds the missed waiting when doing batched lookup_deletion on +htab of maps. Patch #4 does wait only if the update or deletion +operation succeeds. Patch #5 fixes the value of batch.count when memory +allocation fails. +==================== + +Link: https://lore.kernel.org/r/20231208102355.2628918-1-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",,The commit addresses issues with maybe_wait_bpf_programs in batched operations and enhances memory allocation handling for eBPF maps.,"maybe_wait_bpf_programs, batched update, maps",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +06e5c999f10269a532304e89a6adb2fbfeb0593c,06e5c999f10269a532304e89a6adb2fbfeb0593c,Hou Tao,houtao1@huawei.com,1702031033,Alexei Starovoitov,ast@kernel.org,1702174354,c83148f14906289ef86d99908011d97a4fb8aba1,67ad2c73ff29b32bd09135ec07c26e59490dbb3b,"bpf: Set uattr->batch.count as zero before batched update or deletion + +generic_map_{delete","update}_batch() doesn't set uattr->batch.count as +zero before it tries to allocate memory for key. If the memory +allocation fails","[' the value of uattr->batch.count will be incorrect.\n\nFix it by setting uattr->batch.count as zero beore batched update or\ndeletion.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231208102355.2628918-6-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit sets uattr->batch.count to zero before performing memory allocations for batched updates or deletions.,"uattr, batch, update",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +67ad2c73ff29b32bd09135ec07c26e59490dbb3b,67ad2c73ff29b32bd09135ec07c26e59490dbb3b,Hou Tao,houtao1@huawei.com,1702031032,Alexei Starovoitov,ast@kernel.org,1702174354,9345409ae3b7a1e2f94272b4f60bc90d53f1767f,012772581d040607ac1f981f47f6afd2336b4580,"bpf: Only call maybe_wait_bpf_programs() when map operation succeeds + +There is no need to call maybe_wait_bpf_programs() if update or deletion +operation fails. So only call maybe_wait_bpf_programs() if update or +deletion operation succeeds. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231208102355.2628918-5-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",,Optimize bpf map operation to conditionally call maybe_wait_bpf_programs() only on success.,"bpf,map,operation",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +012772581d040607ac1f981f47f6afd2336b4580,012772581d040607ac1f981f47f6afd2336b4580,Hou Tao,houtao1@huawei.com,1702031031,Alexei Starovoitov,ast@kernel.org,1702174354,fc505f0096d9b01c5dbc856091c2d6553b253093,37ba5b59d6adfa08926acd3a833608487a18c2ef,"bpf: Add missed maybe_wait_bpf_programs() for htab of maps + +When doing batched lookup and deletion operations on htab of maps"," +maybe_wait_bpf_programs() is needed to ensure all programs don't use the +inner map after the bpf syscall returns. + +Instead of adding the wait in __htab_map_lookup_and_delete_batch()","['\nadding the wait in bpf_map_do_batch() and also removing the calling of\nmaybe_wait_bpf_programs() from generic_map_{delete', 'update}_batch().\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231208102355.2628918-4-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add maybe_wait_bpf_programs() to ensure safe usage of maps after batched operations in eBPF.,"maybe_wait_bpf_programs, htab, maps",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +37ba5b59d6adfa08926acd3a833608487a18c2ef,37ba5b59d6adfa08926acd3a833608487a18c2ef,Hou Tao,houtao1@huawei.com,1702031030,Alexei Starovoitov,ast@kernel.org,1702174353,cccd27023efa3c6f4e7e06d5a77864f14bf59391,c26f2a8901393c9f81909da0a4324587092bd3a3,"bpf: Call maybe_wait_bpf_programs() only once for generic_map_update_batch() + +Just like commit 9087c6ff8dfe (""bpf: Call maybe_wait_bpf_programs() only +once from generic_map_delete_batch()"")"," there is also no need to call +maybe_wait_bpf_programs() for each update in batched update","[' so only\ncall it once in generic_map_update_batch().\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231208102355.2628918-3-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Optimize the call to maybe_wait_bpf_programs() by executing it once for generic_map_update_batch().,"maybe_wait_bpf_programs, generic_map_update_batch, optimize",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c26f2a8901393c9f81909da0a4324587092bd3a3,c26f2a8901393c9f81909da0a4324587092bd3a3,Hou Tao,houtao1@huawei.com,1702031029,Alexei Starovoitov,ast@kernel.org,1702174353,50adfc5b3ca444245c15cc36ddc1e86ac01fade6,32fa058398624166dd04ff4af49cfef69c94abbc,"bpf: Remove unnecessary wait from bpf_map_copy_value() + +Both map_lookup_elem() and generic_map_lookup_batch() use +bpf_map_copy_value() to lookup and copy the value"," and there is no +update operation in bpf_map_copy_value()","[' so just remove the invocation\nof maybe_wait_bpf_programs() from it.\n\nFixes: 15c14a3dca42 (""bpf: Add bpf_map_{value_size', ' update_value', ' map_copy_value} functions"")\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231208102355.2628918-2-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit removes unnecessary waiting from the function bpf_map_copy_value.,"remove unnecessary wait, map_copy_value, map_lookup_elem",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b10a3ccaf6e39f6290ca29d7c24604082eacaea0,b10a3ccaf6e39f6290ca29d7c24604082eacaea0,Linus Torvalds,torvalds@linux-foundation.org,1702153556,Linus Torvalds,torvalds@linux-foundation.org,1702153556,9d79bc020f449a4304aeeb867eb72300b3dc376b,b8503b215789628d3625ef6aa252f323e32be929 e2f7b3d8b4b300956a77fa1ab084c931ba1c7421,"Merge tag 'loongarch-fixes-6.7-2' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson + +Pull LoongArch fixes from Huacai Chen: + ""Preserve syscall nr across execve()", slightly clean up drdtime(),"[' fix\n the Clang built zboot kernel', ' fix a stack unwinder bug and several bpf\n jit bugs""\n\n* tag \'loongarch-fixes-6.7-2\' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson:\n LoongArch: BPF: Fix unconditional bswap instructions\n LoongArch: BPF: Fix sign-extension mov instructions\n LoongArch: BPF: Don\'t sign extend function return value\n LoongArch: BPF: Don\'t sign extend memory load operand\n LoongArch: Preserve syscall nr across execve()\n LoongArch: Set unwind stack type to unknown rather than set error flag\n LoongArch: Slightly clean up drdtime()\n LoongArch: Apply dynamic relocations for LLD\n', '']",Merge LoongArch fixes for preserving syscall number across execve and cleaning up drdtime.,"LoongArch, syscall, fixes",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +e2f7b3d8b4b300956a77fa1ab084c931ba1c7421,e2f7b3d8b4b300956a77fa1ab084c931ba1c7421,Tiezhu Yang,yangtiezhu@loongson.cn,1702108156,Huacai Chen,chenhuacai@loongson.cn,1702108156,c678faf50b2669118ad237bd7c63959c57f8c760,772cbe948fb07389639d4e698a2d3299f8e538b8,"LoongArch: BPF: Fix unconditional bswap instructions + +We can see that ""bswap32: Takes an unsigned 32-bit number in either big- +or little-endian format and returns the equivalent number with the same +bit width but opposite endianness"" in BPF Instruction Set Specification"," +so it should clear the upper 32 bits in ""case 32:"" for both BPF_ALU and +BPF_ALU64. + +[root@linux fedora]# echo 1 > /proc/sys/net/core/bpf_jit_enable +[root@linux fedora]# modprobe test_bpf + +Before: +test_bpf: #313 BSWAP 32: 0x0123456789abcdef -> 0xefcdab89 jited:1 ret 1460850314 != -271733879 (0x5712ce8a != 0xefcdab89)FAIL (1 times) +test_bpf: #317 BSWAP 32: 0xfedcba9876543210 -> 0x10325476 jited:1 ret -1460850316 != 271733878 (0xa8ed3174 != 0x10325476)FAIL (1 times) + +After: +test_bpf: #313 BSWAP 32: 0x0123456789abcdef -> 0xefcdab89 jited:1 4 PASS +test_bpf: #317 BSWAP 32: 0xfedcba9876543210 -> 0x10325476 jited:1 4 PASS + +Fixes: 4ebf9216e7df (""LoongArch: BPF: Support unconditional bswap instructions"") +Acked-by: Hengqi Chen +Signed-off-by: Tiezhu Yang +Signed-off-by: Huacai Chen +",[''],Fix the unconditional bswap instruction bug for LoongArch BPF.,"bswap, LoongArch, fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The JIT compiler,['other'] +772cbe948fb07389639d4e698a2d3299f8e538b8,772cbe948fb07389639d4e698a2d3299f8e538b8,Tiezhu Yang,yangtiezhu@loongson.cn,1702108156,Huacai Chen,chenhuacai@loongson.cn,1702108156,c6382a817363ec69c522b955a705bdd546d86983,5d47ec2e6f4c64e30e392cfe9532df98c9beb106,"LoongArch: BPF: Fix sign-extension mov instructions + +We can see that ""Short form of movsx", dst_reg = (s8,"['s16', 's32)src_reg"" in\ninclude/linux/filter.h', ' additionally', ' for BPF_ALU64 the value of the\ndestination register is unchanged whereas for BPF_ALU the upper 32 bits\nof the destination register are zeroed', ' so it should clear the upper 32\nbits for BPF_ALU.\n\n[root@linux fedora]# echo 1 > /proc/sys/net/core/bpf_jit_enable\n[root@linux fedora]# modprobe test_bpf\n\nBefore:\ntest_bpf: #81 ALU_MOVSX | BPF_B jited:1 ret 2 != 1 (0x2 != 0x1)FAIL (1 times)\ntest_bpf: #82 ALU_MOVSX | BPF_H jited:1 ret 2 != 1 (0x2 != 0x1)FAIL (1 times)\n\nAfter:\ntest_bpf: #81 ALU_MOVSX | BPF_B jited:1 6 PASS\ntest_bpf: #82 ALU_MOVSX | BPF_H jited:1 6 PASS\n\nBy the way', ' the bpf selftest case ""./test_progs -t verifier_movsx"" can\nalso be fixed with this patch.\n\nFixes: f48012f16150 (""LoongArch: BPF: Support sign-extension mov instructions"")\nAcked-by: Hengqi Chen \nSigned-off-by: Tiezhu Yang \nSigned-off-by: Huacai Chen \n', '']",Fixes sign-extension mov instructions for LoongArch in BPF.,"LoongArch,BPF,fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5d47ec2e6f4c64e30e392cfe9532df98c9beb106,5d47ec2e6f4c64e30e392cfe9532df98c9beb106,Hengqi Chen,hengqi.chen@gmail.com,1702108156,Huacai Chen,chenhuacai@loongson.cn,1702108156,aef94a75a7ee60b5f638b7fa9afd551c8b9a015f,fe5757553bf9ebe45ae8ecab5922f6937c8d8dfc,"LoongArch: BPF: Don't sign extend function return value + +The `cls_redirect` test triggers a kernel panic like: + + # ./test_progs -t cls_redirect + Can't find bpf_testmod.ko kernel module: -2 + WARNING! Selftests relying on bpf_testmod.ko will be skipped. + [ 30.938489] CPU 3 Unable to handle kernel paging request at virtual address fffffffffd814de0", era == ffff800002009fb8,"[' ra == ffff800002009f9c\n [ 30.939331] Oops[#1]:\n [ 30.939513] CPU: 3 PID: 1260 Comm: test_progs Not tainted 6.7.0-rc2-loong-devel-g2f56bb0d2327 #35 a896aca3f4164f09cc346f89f2e09832e07be5f6\n [ 30.939732] Hardware name: QEMU QEMU Virtual Machine', ' BIOS unknown 2/2/2022\n [ 30.939901] pc ffff800002009fb8 ra ffff800002009f9c tp 9000000104da4000 sp 9000000104da7ab0\n [ 30.940038] a0 fffffffffd814de0 a1 9000000104da7a68 a2 0000000000000000 a3 9000000104da7c10\n [ 30.940183] a4 9000000104da7c14 a5 0000000000000002 a6 0000000000000021 a7 00005555904d7f90\n [ 30.940321] t0 0000000000000110 t1 0000000000000000 t2 fffffffffd814de0 t3 0004c4b400000000\n [ 30.940456] t4 ffffffffffffffff t5 00000000c3f63600 t6 0000000000000000 t7 0000000000000000\n [ 30.940590] t8 000000000006d803 u0 0000000000000020 s9 9000000104da7b10 s0 900000010504c200\n [ 30.940727] s1 fffffffffd814de0 s2 900000010504c200 s3 9000000104da7c10 s4 9000000104da7ad0\n [ 30.940866] s5 0000000000000000 s6 90000000030e65bc s7 9000000104da7b44 s8 90000000044f6fc0\n [ 30.941015] ra: ffff800002009f9c bpf_prog_846803e5ae81417f_cls_redirect+0xa0/0x590\n [ 30.941535] ERA: ffff800002009fb8 bpf_prog_846803e5ae81417f_cls_redirect+0xbc/0x590\n [ 30.941696] CRMD: 000000b0 (PLV0 -IE -DA +PG DACF=CC DACM=CC -WE)\n [ 30.942224] PRMD: 00000004 (PPLV0 +PIE -PWE)\n [ 30.942330] EUEN: 00000003 (+FPE +SXE -ASXE -BTE)\n [ 30.942453] ECFG: 00071c1c (LIE=2-4', '10-12 VS=7)\n [ 30.942612] ESTAT: 00010000 [PIL] (IS= ECode=1 EsubCode=0)\n [ 30.942764] BADV: fffffffffd814de0\n [ 30.942854] PRID: 0014c010 (Loongson-64bit', ' Loongson-3A5000)\n [ 30.942974] Modules linked in:\n [ 30.943078] Process test_progs (pid: 1260', ' threadinfo=00000000ce303226', ' task=000000007d10bb76)\n [ 30.943306] Stack : 900000010a064000 90000000044f6fc0 9000000104da7b48 0000000000000000\n [ 30.943495] 0000000000000000 9000000104da7c14 9000000104da7c10 900000010504c200\n [ 30.943626] 0000000000000001 ffff80001b88c000 9000000104da7b70 90000000030e6668\n [ 30.943785] 0000000000000000 9000000104da7b58 ffff80001b88c048 9000000003d05000\n [ 30.943936] 900000000303ac88 0000000000000000 0000000000000000 9000000104da7b70\n [ 30.944091] 0000000000000000 0000000000000001 0000000731eeab00 0000000000000000\n [ 30.944245] ffff80001b88c000 0000000000000000 0000000000000000 54b99959429f83b8\n [ 30.944402] ffff80001b88c000 90000000044f6fc0 9000000101d70000 ffff80001b88c000\n [ 30.944538] 000000000000005a 900000010504c200 900000010a064000 900000010a067000\n [ 30.944697] 9000000104da7d88 0000000000000000 9000000003d05000 90000000030e794c\n [ 30.944852] ...\n [ 30.944924] Call Trace:\n [ 30.945120] [] bpf_prog_846803e5ae81417f_cls_redirect+0xbc/0x590\n [ 30.945650] [<90000000030e6668>] bpf_test_run+0x1ec/0x2f8\n [ 30.945958] [<90000000030e794c>] bpf_prog_test_run_skb+0x31c/0x684\n [ 30.946065] [<90000000026d4f68>] __sys_bpf+0x678/0x2724\n [ 30.946159] [<90000000026d7288>] sys_bpf+0x20/0x2c\n [ 30.946253] [<90000000032dd224>] do_syscall+0x7c/0x94\n [ 30.946343] [<9000000002541c5c>] handle_syscall+0xbc/0x158\n [ 30.946492]\n [ 30.946549] Code: 0015030e 5c0009c0 5001d000 <28c00304> 02c00484 29c00304 00150009 2a42d2e4 0280200d\n [ 30.946793]\n [ 30.946971] ---[ end trace 0000000000000000 ]---\n [ 32.093225] Kernel panic - not syncing: Fatal exception in interrupt\n [ 32.093526] Kernel relocated by 0x2320000\n [ 32.093630] .text @ 0x9000000002520000\n [ 32.093725] .data @ 0x9000000003400000\n [ 32.093792] .bss @ 0x9000000004413200\n [ 34.971998] ---[ end Kernel panic - not syncing: Fatal exception in interrupt ]---\n\nThis is because we signed-extend function return values. When subprog\nmode is enabled', ' we have:\n\n cls_redirect()\n -> get_global_metrics() returns pcpu ptr 0xfffffefffc00b480\n\nThe pointer returned is later signed-extended to 0xfffffffffc00b480 at\n`BPF_JMP | BPF_EXIT`. During BPF prog run', ' this triggers unhandled page\nfault and a kernel panic.\n\nDrop the unnecessary signed-extension on return values like other\narchitectures do.\n\nWith this change', "" we have:\n\n # ./test_progs -t cls_redirect\n Can't find bpf_testmod.ko kernel module: -2\n WARNING! Selftests relying on bpf_testmod.ko will be skipped.\n #51/1 cls_redirect/cls_redirect_inlined:OK\n #51/2 cls_redirect/IPv4 TCP accept unknown (no hops"", ' flags: SYN):OK\n #51/3 cls_redirect/IPv6 TCP accept unknown (no hops', ' flags: SYN):OK\n #51/4 cls_redirect/IPv4 TCP accept unknown (no hops', ' flags: ACK):OK\n #51/5 cls_redirect/IPv6 TCP accept unknown (no hops', ' flags: ACK):OK\n #51/6 cls_redirect/IPv4 TCP forward unknown (one hop', ' flags: ACK):OK\n #51/7 cls_redirect/IPv6 TCP forward unknown (one hop', ' flags: ACK):OK\n #51/8 cls_redirect/IPv4 TCP accept known (one hop', ' flags: ACK):OK\n #51/9 cls_redirect/IPv6 TCP accept known (one hop', ' flags: ACK):OK\n #51/10 cls_redirect/IPv4 UDP accept unknown (no hops', ' flags: none):OK\n #51/11 cls_redirect/IPv6 UDP accept unknown (no hops', ' flags: none):OK\n #51/12 cls_redirect/IPv4 UDP forward unknown (one hop', ' flags: none):OK\n #51/13 cls_redirect/IPv6 UDP forward unknown (one hop', ' flags: none):OK\n #51/14 cls_redirect/IPv4 UDP accept known (one hop', ' flags: none):OK\n #51/15 cls_redirect/IPv6 UDP accept known (one hop', ' flags: none):OK\n #51/16 cls_redirect/cls_redirect_subprogs:OK\n #51/17 cls_redirect/IPv4 TCP accept unknown (no hops', ' flags: SYN):OK\n #51/18 cls_redirect/IPv6 TCP accept unknown (no hops', ' flags: SYN):OK\n #51/19 cls_redirect/IPv4 TCP accept unknown (no hops', ' flags: ACK):OK\n #51/20 cls_redirect/IPv6 TCP accept unknown (no hops', ' flags: ACK):OK\n #51/21 cls_redirect/IPv4 TCP forward unknown (one hop', ' flags: ACK):OK\n #51/22 cls_redirect/IPv6 TCP forward unknown (one hop', ' flags: ACK):OK\n #51/23 cls_redirect/IPv4 TCP accept known (one hop', ' flags: ACK):OK\n #51/24 cls_redirect/IPv6 TCP accept known (one hop', ' flags: ACK):OK\n #51/25 cls_redirect/IPv4 UDP accept unknown (no hops', ' flags: none):OK\n #51/26 cls_redirect/IPv6 UDP accept unknown (no hops', ' flags: none):OK\n #51/27 cls_redirect/IPv4 UDP forward unknown (one hop', ' flags: none):OK\n #51/28 cls_redirect/IPv6 UDP forward unknown (one hop', ' flags: none):OK\n #51/29 cls_redirect/IPv4 UDP accept known (one hop', ' flags: none):OK\n #51/30 cls_redirect/IPv6 UDP accept known (one hop', ' flags: none):OK\n #51/31 cls_redirect/cls_redirect_dynptr:OK\n #51/32 cls_redirect/IPv4 TCP accept unknown (no hops', ' flags: SYN):OK\n #51/33 cls_redirect/IPv6 TCP accept unknown (no hops', ' flags: SYN):OK\n #51/34 cls_redirect/IPv4 TCP accept unknown (no hops', ' flags: ACK):OK\n #51/35 cls_redirect/IPv6 TCP accept unknown (no hops', ' flags: ACK):OK\n #51/36 cls_redirect/IPv4 TCP forward unknown (one hop', ' flags: ACK):OK\n #51/37 cls_redirect/IPv6 TCP forward unknown (one hop', ' flags: ACK):OK\n #51/38 cls_redirect/IPv4 TCP accept known (one hop', ' flags: ACK):OK\n #51/39 cls_redirect/IPv6 TCP accept known (one hop', ' flags: ACK):OK\n #51/40 cls_redirect/IPv4 UDP accept unknown (no hops', ' flags: none):OK\n #51/41 cls_redirect/IPv6 UDP accept unknown (no hops', ' flags: none):OK\n #51/42 cls_redirect/IPv4 UDP forward unknown (one hop', ' flags: none):OK\n #51/43 cls_redirect/IPv6 UDP forward unknown (one hop', ' flags: none):OK\n #51/44 cls_redirect/IPv4 UDP accept known (one hop', ' flags: none):OK\n #51/45 cls_redirect/IPv6 UDP accept known (one hop', ' flags: none):OK\n #51 cls_redirect:OK\n Summary: 1/45 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\nFixes: 5dc615520c4d (""LoongArch: Add BPF JIT support"")\nSigned-off-by: Hengqi Chen \nSigned-off-by: Huacai Chen \n', '']",Fixes a kernel panic issue on LoongArch architecture by preventing sign extension of function return value in BPF.,"LoongArch, kernel panic, BPF",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['tc/netfilter like programs'] +fe5757553bf9ebe45ae8ecab5922f6937c8d8dfc,fe5757553bf9ebe45ae8ecab5922f6937c8d8dfc,Hengqi Chen,hengqi.chen@gmail.com,1702108156,Huacai Chen,chenhuacai@loongson.cn,1702108156,1e495be87bfbc610d5ad9011658b30acd0b543fe,d6c5f06e46a836e6a70c7cfd95bb38a67d9252ec,"LoongArch: BPF: Don't sign extend memory load operand + +The `cgrp_local_storage` test triggers a kernel panic like: + + # ./test_progs -t cgrp_local_storage + Can't find bpf_testmod.ko kernel module: -2 + WARNING! Selftests relying on bpf_testmod.ko will be skipped. + [ 550.930632] CPU 1 Unable to handle kernel paging request at virtual address 0000000000000080", era == ffff80000200be34,"[' ra == ffff80000200be00\n [ 550.931781] Oops[#1]:\n [ 550.931966] CPU: 1 PID: 1303 Comm: test_progs Not tainted 6.7.0-rc2-loong-devel-g2f56bb0d2327 #35 a896aca3f4164f09cc346f89f2e09832e07be5f6\n [ 550.932215] Hardware name: QEMU QEMU Virtual Machine', ' BIOS unknown 2/2/2022\n [ 550.932403] pc ffff80000200be34 ra ffff80000200be00 tp 9000000108350000 sp 9000000108353dc0\n [ 550.932545] a0 0000000000000000 a1 0000000000000517 a2 0000000000000118 a3 00007ffffbb15558\n [ 550.932682] a4 00007ffffbb15620 a5 90000001004e7700 a6 0000000000000021 a7 0000000000000118\n [ 550.932824] t0 ffff80000200bdc0 t1 0000000000000517 t2 0000000000000517 t3 00007ffff1c06ee0\n [ 550.932961] t4 0000555578ae04d0 t5 fffffffffffffff8 t6 0000000000000004 t7 0000000000000020\n [ 550.933097] t8 0000000000000040 u0 00000000000007b8 s9 9000000108353e00 s0 90000001004e7700\n [ 550.933241] s1 9000000004005000 s2 0000000000000001 s3 0000000000000000 s4 0000555555eb2ec8\n [ 550.933379] s5 00007ffffbb15bb8 s6 00007ffff1dafd60 s7 000055555663f610 s8 00007ffff1db0050\n [ 550.933520] ra: ffff80000200be00 bpf_prog_98f1b9e767be2a84_on_enter+0x40/0x200\n [ 550.933911] ERA: ffff80000200be34 bpf_prog_98f1b9e767be2a84_on_enter+0x74/0x200\n [ 550.934105] CRMD: 000000b0 (PLV0 -IE -DA +PG DACF=CC DACM=CC -WE)\n [ 550.934596] PRMD: 00000004 (PPLV0 +PIE -PWE)\n [ 550.934712] EUEN: 00000003 (+FPE +SXE -ASXE -BTE)\n [ 550.934836] ECFG: 00071c1c (LIE=2-4', '10-12 VS=7)\n [ 550.934976] ESTAT: 00010000 [PIL] (IS= ECode=1 EsubCode=0)\n [ 550.935097] BADV: 0000000000000080\n [ 550.935181] PRID: 0014c010 (Loongson-64bit', ' Loongson-3A5000)\n [ 550.935291] Modules linked in:\n [ 550.935391] Process test_progs (pid: 1303', ' threadinfo=000000006c3b1c41', ' task=0000000061f84a55)\n [ 550.935643] Stack : 00007ffffbb15bb8 0000555555eb2ec8 0000000000000000 0000000000000001\n [ 550.935844] 9000000004005000 ffff80001b864000 00007ffffbb15450 90000000029aa034\n [ 550.935990] 0000000000000000 9000000108353ec0 0000000000000118 d07d9dfb09721a09\n [ 550.936175] 0000000000000001 0000000000000000 9000000108353ec0 0000000000000118\n [ 550.936314] 9000000101d46ad0 900000000290abf0 000055555663f610 0000000000000000\n [ 550.936479] 0000000000000003 9000000108353ec0 00007ffffbb15450 90000000029d7288\n [ 550.936635] 00007ffff1dafd60 000055555663f610 0000000000000000 0000000000000003\n [ 550.936779] 9000000108353ec0 90000000035dd1f0 00007ffff1dafd58 9000000002841c5c\n [ 550.936939] 0000000000000119 0000555555eea5a8 00007ffff1d78780 00007ffffbb153e0\n [ 550.937083] ffffffffffffffda 00007ffffbb15518 0000000000000040 00007ffffbb15558\n [ 550.937224] ...\n [ 550.937299] Call Trace:\n [ 550.937521] [] bpf_prog_98f1b9e767be2a84_on_enter+0x74/0x200\n [ 550.937910] [<90000000029aa034>] bpf_trace_run2+0x90/0x154\n [ 550.938105] [<900000000290abf0>] syscall_trace_enter.isra.0+0x1cc/0x200\n [ 550.938224] [<90000000035dd1f0>] do_syscall+0x48/0x94\n [ 550.938319] [<9000000002841c5c>] handle_syscall+0xbc/0x158\n [ 550.938477]\n [ 550.938607] Code: 580009ae 50016000 262402e4 <28c20085> 14092084 03a00084 16000024 03240084 00150006\n [ 550.938851]\n [ 550.939021] ---[ end trace 0000000000000000 ]---\n\nFurther investigation shows that this panic is triggered by memory\nload operations:\n\n ptr = bpf_cgrp_storage_get(&map_a', ' task->cgroups->dfl_cgrp', ' 0', '\n BPF_LOCAL_STORAGE_GET_F_CREATE);\n\nThe expression `task->cgroups->dfl_cgrp` involves two memory load.\nSince the field offset fits in imm12 or imm14', ' we use ldd or ldptrd\ninstructions. But both instructions have the side effect that it will\nsigned-extended the imm operand. Finally', ' we got the wrong addresses\nand panics is inevitable.\n\nUse a generic ldxd instruction to avoid this kind of issues.\n\nWith this change', "" we have:\n\n # ./test_progs -t cgrp_local_storage\n Can't find bpf_testmod.ko kernel module: -2\n WARNING! Selftests relying on bpf_testmod.ko will be skipped.\n test_cgrp_local_storage:PASS:join_cgroup /cgrp_local_storage 0 nsec\n #48/1 cgrp_local_storage/tp_btf:OK\n test_attach_cgroup:PASS:skel_open 0 nsec\n test_attach_cgroup:PASS:prog_attach 0 nsec\n test_attach_cgroup:PASS:prog_attach 0 nsec\n libbpf: prog 'update_cookie_tracing': failed to attach: ERROR: strerror_r(-524)=22\n test_attach_cgroup:FAIL:prog_attach unexpected error: -524\n #48/2 cgrp_local_storage/attach_cgroup:FAIL\n test_recursion:PASS:skel_open_and_load 0 nsec\n libbpf: prog 'on_lookup': failed to attach: ERROR: strerror_r(-524)=22\n libbpf: prog 'on_lookup': failed to auto-attach: -524\n test_recursion:FAIL:skel_attach unexpected error: -524 (errno 524)\n #48/3 cgrp_local_storage/recursion:FAIL\n #48/4 cgrp_local_storage/negative:OK\n #48/5 cgrp_local_storage/cgroup_iter_sleepable:OK\n test_yes_rcu_lock:PASS:skel_open 0 nsec\n test_yes_rcu_lock:PASS:skel_load 0 nsec\n libbpf: prog 'yes_rcu_lock': failed to attach: ERROR: strerror_r(-524)=22\n libbpf: prog 'yes_rcu_lock': failed to auto-attach: -524\n test_yes_rcu_lock:FAIL:skel_attach unexpected error: -524 (errno 524)\n #48/6 cgrp_local_storage/yes_rcu_lock:FAIL\n #48/7 cgrp_local_storage/no_rcu_lock:OK\n #48 cgrp_local_storage:FAIL\n\n All error logs:\n test_cgrp_local_storage:PASS:join_cgroup /cgrp_local_storage 0 nsec\n test_attach_cgroup:PASS:skel_open 0 nsec\n test_attach_cgroup:PASS:prog_attach 0 nsec\n test_attach_cgroup:PASS:prog_attach 0 nsec\n libbpf: prog 'update_cookie_tracing': failed to attach: ERROR: strerror_r(-524)=22\n test_attach_cgroup:FAIL:prog_attach unexpected error: -524\n #48/2 cgrp_local_storage/attach_cgroup:FAIL\n test_recursion:PASS:skel_open_and_load 0 nsec\n libbpf: prog 'on_lookup': failed to attach: ERROR: strerror_r(-524)=22\n libbpf: prog 'on_lookup': failed to auto-attach: -524\n test_recursion:FAIL:skel_attach unexpected error: -524 (errno 524)\n #48/3 cgrp_local_storage/recursion:FAIL\n test_yes_rcu_lock:PASS:skel_open 0 nsec\n test_yes_rcu_lock:PASS:skel_load 0 nsec\n libbpf: prog 'yes_rcu_lock': failed to attach: ERROR: strerror_r(-524)=22\n libbpf: prog 'yes_rcu_lock': failed to auto-attach: -524\n test_yes_rcu_lock:FAIL:skel_attach unexpected error: -524 (errno 524)\n #48/6 cgrp_local_storage/yes_rcu_lock:FAIL\n #48 cgrp_local_storage:FAIL\n Summary: 0/4 PASSED"", ' 0 SKIPPED', ' 1 FAILED\n\nNo panics any more (The test still failed because lack of BPF trampoline\nwhich I am actively working on).\n\nFixes: 5dc615520c4d (""LoongArch: Add BPF JIT support"")\nSigned-off-by: Hengqi Chen \nSigned-off-by: Huacai Chen \n', '']",Fixes kernel panic issue by modifying memory load operand behavior on LoongArch architecture.,"LoongArch,memory load,kernel panic",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +32fa058398624166dd04ff4af49cfef69c94abbc,32fa058398624166dd04ff4af49cfef69c94abbc,Sergei Trofimovich,slyich@gmail.com,1702072260,Andrii Nakryiko,andrii@kernel.org,1702084278,f32cdfd1ffa633a2877467d11fa9a87a187c50b7,09115c33e6ec4a98a0609ac5fa702b7fe566d8f9,"libbpf: Add pr_warn() for EINVAL cases in linker_sanity_check_elf + +Before the change on `i686-linux` `systemd` build failed as: + + $ bpftool gen object src/core/bpf/socket_bind/socket-bind.bpf.o src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o + Error: failed to link 'src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o': Invalid argument (22) + +After the change it fails as: + + $ bpftool gen object src/core/bpf/socket_bind/socket-bind.bpf.o src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o + libbpf: ELF section #9 has inconsistent alignment addr=8 != d=4 in src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o + Error: failed to link 'src/core/bpf/socket_bind/socket-bind.bpf.unstripped.o': Invalid argument (22) + +Now it's slightly easier to figure out what is wrong with an ELF file. + +Signed-off-by: Sergei Trofimovich +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231208215100.435876-1-slyich@gmail.com +",,The commit enhances libbpf by adding a pr_warn() for better error reporting on EINVAL cases during linker sanity check of ELF files.,"libbpf, pr_warn, EINVAL",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +09115c33e6ec4a98a0609ac5fa702b7fe566d8f9,09115c33e6ec4a98a0609ac5fa702b7fe566d8f9,Martin KaFai Lau,martin.lau@kernel.org,1702081586,Martin KaFai Lau,martin.lau@kernel.org,1702084099,1400435b0ce3665facbd964528234417d9117ec8,1720c42b90c8f14ffcb2f2f39a1abafc82a5b22e a2c6380b17b6339bfedc98d253b6d85e7014953b,"Merge branch 'bpf: Expand bpf_cgrp_storage to support cgroup1 non-attach case' + +Yafang Shao says: + +==================== +In the current cgroup1 environment"," associating operations between a cgroup +and applications in a BPF program requires storing a mapping of cgroup_id +to application either in a hash map or maintaining it in userspace. +However","[' by enabling bpf_cgrp_storage for cgroup1', ' it becomes possible to\nconveniently store application-specific information in cgroup-local storage\nand utilize it within BPF programs. Furthermore', ' enabling this feature for\ncgroup1 involves minor modifications for the non-attach case', ' streamlining\nthe process.\n\nHowever', ' when it comes to enabling this functionality for the cgroup1\nattach case', ' it presents challenges. Therefore', ' the decision is to focus on\nenabling it solely for the cgroup1 non-attach case at present. If\nattempting to attach to a cgroup1 fd', ' the operation will simply fail with\nthe error code -EBADF.\n\nChanges:\n- RFC -> v1:\n - Collect acked-by\n - Avoid unnecessary is_cgroup1 check (Yonghong)\n - Keep the code patterns consistent (Yonghong)\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",This commit expands the bpf_cgrp_storage to support non-attach cases in cgroup1.,bpf_cgrp_storage cgroup1 non-attach,It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['cgroup like programs'] +a2c6380b17b6339bfedc98d253b6d85e7014953b,a2c6380b17b6339bfedc98d253b6d85e7014953b,Yafang Shao,laoar.shao@gmail.com,1701863606,Martin KaFai Lau,martin.lau@kernel.org,1702084098,1400435b0ce3665facbd964528234417d9117ec8,f4199271dae12ae407fa739e7012914ea6b3f37b,"selftests/bpf: Add selftests for cgroup1 local storage + +Expanding the test coverage from cgroup2 to include cgroup1. The result +as follows"," + +Already existing test cases for cgroup2: + #48/1 cgrp_local_storage/tp_btf:OK + #48/2 cgrp_local_storage/attach_cgroup:OK + #48/3 cgrp_local_storage/recursion:OK + #48/4 cgrp_local_storage/negative:OK + #48/5 cgrp_local_storage/cgroup_iter_sleepable:OK + #48/6 cgrp_local_storage/yes_rcu_lock:OK + #48/7 cgrp_local_storage/no_rcu_lock:OK + +Expanded test cases for cgroup1: + #48/8 cgrp_local_storage/cgrp1_tp_btf:OK + #48/9 cgrp_local_storage/cgrp1_recursion:OK + #48/10 cgrp_local_storage/cgrp1_negative:OK + #48/11 cgrp_local_storage/cgrp1_iter_sleepable:OK + #48/12 cgrp_local_storage/cgrp1_yes_rcu_lock:OK + #48/13 cgrp_local_storage/cgrp1_no_rcu_lock:OK + +Summary: + #48 cgrp_local_storage:OK + Summary: 1/13 PASSED","[' 0 SKIPPED', ' 0 FAILED\n\nSigned-off-by: Yafang Shao \nAcked-by: Tejun Heo \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231206115326.4295-4-laoar.shao@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Add selftests for cgroup1 local storage by expanding test coverage from cgroup2.,"selftests,cgroup1,test coverage",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['cgroup like programs'] +f4199271dae12ae407fa739e7012914ea6b3f37b,f4199271dae12ae407fa739e7012914ea6b3f37b,Yafang Shao,laoar.shao@gmail.com,1701863605,Martin KaFai Lau,martin.lau@kernel.org,1702084098,f45ea4d4106916951d18033bbe40d446916a779f,73d9eb340d2b95e0e86a656a7f3157c137f10129,"selftests/bpf: Add a new cgroup helper open_classid() + +This new helper allows us to obtain the fd of a net_cls cgroup"," which will +be utilized in the subsequent patch. + +Signed-off-by: Yafang Shao +Acked-by: Tejun Heo +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231206115326.4295-3-laoar.shao@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Add a new cgroup helper to obtain the file descriptor of a net_cls cgroup.,"cgroup,helper,net_cls",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['cgroup like programs'] +73d9eb340d2b95e0e86a656a7f3157c137f10129,73d9eb340d2b95e0e86a656a7f3157c137f10129,Yafang Shao,laoar.shao@gmail.com,1701863604,Martin KaFai Lau,martin.lau@kernel.org,1702084098,a442aeae6b760b983992eda002e9adce995eea10,1720c42b90c8f14ffcb2f2f39a1abafc82a5b22e,"bpf: Enable bpf_cgrp_storage for cgroup1 non-attach case + +In the current cgroup1 environment"," associating operations between cgroups +and applications in a BPF program requires storing a mapping of cgroup_id +to application either in a hash map or maintaining it in userspace. +However","[' by enabling bpf_cgrp_storage for cgroup1', ' it becomes possible to\nconveniently store application-specific information in cgroup-local storage\nand utilize it within BPF programs. Furthermore', ' enabling this feature for\ncgroup1 involves minor modifications for the non-attach case', ' streamlining\nthe process.\n\nHowever', ' when it comes to enabling this functionality for the cgroup1\nattach case', ' it presents challenges. Therefore', ' the decision is to focus on\nenabling it solely for the cgroup1 non-attach case at present. If\nattempting to attach to a cgroup1 fd', ' the operation will simply fail with\nthe error code -EBADF.\n\nSigned-off-by: Yafang Shao \nAcked-by: Tejun Heo \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231206115326.4295-2-laoar.shao@gmail.com\nSigned-off-by: Martin KaFai Lau \n', '']",Enable cgroup storage support for BPF programs in cgroup1 non-attach mode.,"bpf,cgroup1,storage",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['cgroup like programs'] +1720c42b90c8f14ffcb2f2f39a1abafc82a5b22e,1720c42b90c8f14ffcb2f2f39a1abafc82a5b22e,Andrii Nakryiko,andrii@kernel.org,1702078228,Alexei Starovoitov,ast@kernel.org,1702083050,95c5a7d05e387c553ca5c09fd35be2478baaee16,4af20ab9edee62aa2bb5b6f31b7f029de14e0756,"selftests/bpf: fix timer/test_bad_ret subtest on test_progs-cpuv4 flavor + +Because test_bad_ret main program is not written in assembly"," we don't +control instruction indices in timer_cb_ret_bad() subprog. This bites us +in timer/test_bad_ret subtest","[' where we see difference between cpuv4 and\nother flavors.\n\nFor now', ' make __msg() expectations not rely on instruction indices by\nanchoring them around bpf_get_prandom_u32 call. Once we have regex/glob\nsupport for __msg()', ' this can be expressed a bit more nicely', ' but for\nnow just mitigating the problem with available means.\n\nFixes: e02dea158dda (""selftests/bpf: validate async callback return value check correctness"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231208233028.3412690-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes the issue with timer/test_bad_ret subtest on the test_progs-cpuv4 by handling instruction indices in non-assembly code.,"selftests,bpf,test",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +4af20ab9edee62aa2bb5b6f31b7f029de14e0756,4af20ab9edee62aa2bb5b6f31b7f029de14e0756,Andrii Nakryiko,andrii@kernel.org,1702073940,Andrii Nakryiko,andrii@kernel.org,1702073941,fc1c424f93e93746a902718f4a0284e6fd002822,8b7b0e5fe47de90ba6c350f9abece589fb637f79 2929bfac006d8f8e22b307d04e0d71bcb84db698,"Merge branch 'bpf-fix-accesses-to-uninit-stack-slots' + +Andrei Matei says: + +==================== +bpf: fix accesses to uninit stack slots + +Fix two related issues issues around verifying stack accesses: +1. accesses to uninitialized stack memory was allowed inconsistently +2. the maximum stack depth needed for a program was not always +maintained correctly + +The two issues are fixed together in one commit because the code for one +affects the other. + +V4 to V5: +- target bpf-next (Alexei) + +V3 to V4: +- minor fixup to comment in patch 1 (Eduard) +- C89-style in patch 3 (Andrii) + +V2 to V3: +- address review comments from Andrii and Eduard +- drop new verifier tests in favor of editing existing tests to check + for stack depth +- append a patch with a bit of cleanup coming out of the previous review +==================== + +Link: https://lore.kernel.org/r/20231208032519.260451-1-andreimatei1@gmail.com +Signed-off-by: Andrii Nakryiko +",,Fixes issues with verifying accesses to uninitialized stack slots and maintaining maximum stack depth in bpf programs.,"uninitialized,stack,depth",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2929bfac006d8f8e22b307d04e0d71bcb84db698,2929bfac006d8f8e22b307d04e0d71bcb84db698,Andrei Matei,andreimatei1@gmail.com,1702005919,Andrii Nakryiko,andrii@kernel.org,1702073940,fc1c424f93e93746a902718f4a0284e6fd002822,6b4a64bafd107e521c01eec3453ce94a3fb38529,"bpf: Minor cleanup around stack bounds + +Push the rounding up of stack offsets into the function responsible for +growing the stack"," rather than relying on all the callers to do it. +Uncertainty about whether the callers did it or not tripped up people in +a previous review. + +Signed-off-by: Andrei Matei +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231208032519.260451-4-andreimatei1@gmail.com +",[''],The commit refactors stack offset rounding into the stack growing function for cleaner code.,"cleanup, stack, bounds",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6b4a64bafd107e521c01eec3453ce94a3fb38529,6b4a64bafd107e521c01eec3453ce94a3fb38529,Andrei Matei,andreimatei1@gmail.com,1702005918,Andrii Nakryiko,andrii@kernel.org,1702073940,413fad563de5cfb78b40f9f067d563e4dcfa4221,92e1567ee3e3f6f160e320890ac77eec50bf8e7d,"bpf: Fix accesses to uninit stack slots + +Privileged programs are supposed to be able to read uninitialized stack +memory (ever since 6715df8d5) but", before this patch,"[' these accesses\nwere permitted inconsistently. In particular', ' accesses were permitted\nabove state->allocated_stack', ' but not below it. In other words', ' if the\nstack was already ""large enough""', ' the access was permitted', ' but\notherwise the access was rejected instead of being allowed to ""grow the\nstack"". This undesired rejection was happening in two places:\n- in check_stack_slot_within_bounds()\n- in check_stack_range_initialized()\nThis patch arranges for these accesses to be permitted. A bunch of tests\nthat were relying on the old rejection had to change; all of them were\nchanged to add also run unprivileged', "" in which case the old behavior\npersists. One tests couldn't be updated - global_func16 - because it\ncan't run unprivileged for other reasons.\n\nThis patch also fixes the tracking of the stack size for variable-offset\nreads. This second fix is bundled in the same commit as the first one\nbecause they're inter-related. Before this patch"", ' writes to the stack\nusing registers containing a variable offset (as opposed to registers\nwith fixed', "" known values) were not properly contributing to the\nfunction's needed stack size. As a result"", ' it was possible for a program\nto verify', ' but then to attempt to read out-of-bounds data at runtime\nbecause a too small stack had been allocated for it.\n\nEach function tracks the size of the stack it needs in\nbpf_subprog_info.stack_depth', ' which is maintained by\nupdate_stack_depth(). For regular memory accesses', ' check_mem_access()\nwas calling update_state_depth() but it was passing in only the fixed\npart of the offset register', ' ignoring the variable offset. This was\nincorrect; the minimum possible value of that register should be used\ninstead.\n\nThis tracking is now fixed by centralizing the tracking of stack size in\ngrow_stack_state()', ' and by lifting the calls to grow_stack_state() to\ncheck_stack_access_within_bounds() as suggested by Andrii. The code is\nnow simpler and more convincingly tracks the correct maximum stack size.\ncheck_stack_range_initialized() can now rely on enough stack having been\nallocated for the access; this helps with the fix for the first issue.\n\nA few tests were changed to also check the stack depth computation. The\none that fails without this patch is verifier_var_off:stack_write_priv_vs_unpriv.\n\nFixes: 01f810ace9ed3 (""bpf: Allow variable-offset stack access"")\nReported-by: Hao Sun \nSigned-off-by: Andrei Matei \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231208032519.260451-3-andreimatei1@gmail.com\n\nCloses: https://lore.kernel.org/bpf/CABWLsev9g8UP_c3a=1qbuZUi20tGoUXoU07FPf-5FLvhOKOY+Q@mail.gmail.com/\n', '']",Fixes issue with privileged programs accessing uninitialized stack memory in eBPF.,"fix,uninitialized,stack",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +92e1567ee3e3f6f160e320890ac77eec50bf8e7d,92e1567ee3e3f6f160e320890ac77eec50bf8e7d,Andrei Matei,andreimatei1@gmail.com,1702005917,Andrii Nakryiko,andrii@kernel.org,1702073940,69bda1ccd633fd5d04916f39eea25e8004fe9cf7,8b7b0e5fe47de90ba6c350f9abece589fb637f79,"bpf: Add some comments to stack representation + +Add comments to the datastructure tracking the stack state"," as the +mapping between each stack slot and where its state is stored is not +entirely obvious. + +Signed-off-by: Andrei Matei +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231208032519.260451-2-andreimatei1@gmail.com +",[''],Added comments to clarify the stack representation and state tracking in eBPF.,"comments, stack, representation",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8b7b0e5fe47de90ba6c350f9abece589fb637f79,8b7b0e5fe47de90ba6c350f9abece589fb637f79,David Vernet,void@manifault.com,1702016223,Andrii Nakryiko,andrii@kernel.org,1702057139,905614ac22caa6c66c12122ac46f8181ca105d0e,483af466e4ee3326d150877ea0626e95c67a395e,"bpf: Load vmlinux btf for any struct_ops map + +In libbpf", when determining whether we need to load vmlinux btf,"["" we're\ncurrently (among other things) checking whether there is any struct_ops\nprogram present in the object. This works for most realistic struct_ops\nmaps"", ' as a struct_ops map is of course typically composed of one or more\nstruct_ops programs. However', ' that technically need not be the case. A\nstruct_ops interface could be defined which allows a map to be specified\nwhich one or more non-prog fields', ' and which provides default behavior\nif no struct_ops progs is actually provided otherwise. For sched_ext', '\nfor example', ' you technically only need to specify the name of the\nscheduler in the struct_ops map', ' with the core scheduler logic providing\ndefault behavior if no prog is actually specified.\n\nIf we were to define and try to load such a struct_ops map', ' we would\ncrash in libbpf when initializing it as obj->btf_vmlinux will be NULL:\n\nReading symbols from minimal...\n(gdb) r\nStarting program: minimal_example\n[Thread debugging using libthread_db enabled]\nUsing host libthread_db library ""/usr/lib/libthread_db.so.1"".\n\nProgram received signal SIGSEGV', ' Segmentation fault.\n0x000055555558308c in btf__type_cnt (btf=0x0) at btf.c:612\n612 return btf->start_id + btf->nr_types;\n(gdb) bt\n type_name=0x5555555d99e3 ""sched_ext_ops""', ' kind=4) at btf.c:914\n kind=4) at btf.c:942\n type=0x7fffffffe558', ' type_id=0x7fffffffe548', ' ...\n data_member=0x7fffffffe568) at libbpf.c:948\n kern_btf=0x0) at libbpf.c:1017\n at libbpf.c:8059\n\nSo as to account for such bare-bones struct_ops maps', "" let's update\nobj_needs_vmlinux_btf() to also iterate over an obj's maps and check\nwhether any of them are struct_ops maps.\n\nSigned-off-by: David Vernet \nSigned-off-by: Andrii Nakryiko \nReviewed-by: Alan Maguire \nLink: https://lore.kernel.org/bpf/20231208061704.400463-1-void@manifault.com\n"", '']",The commit updates libbpf to load vmlinux BTF for any struct_ops map.,"libbpf,vmlinux,struct_ops",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5e3f5b81de80c98338bcb47c233aebefee5a4801,5e3f5b81de80c98338bcb47c233aebefee5a4801,Linus Torvalds,torvalds@linux-foundation.org,1701997453,Linus Torvalds,torvalds@linux-foundation.org,1701997453,21b4ee9f1d4ff54e810f5c9d0d29638348b1b4dd,9ace34a8e446c1a566f3b0a3e0c4c483987e39a6 b0a930e8d90caf66a94fee7a9d0b8472bc3e7561,"Merge tag 'net-6.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + ""Including fixes from bpf and netfilter. + + Current release - regressions: + + - veth: fix packet segmentation in veth_convert_skb_to_xdp_buff + + Current release - new code bugs: + + - tcp: assorted fixes to the new Auth Option support + + Older releases - regressions: + + - tcp: fix mid stream window clamp + + - tls: fix incorrect splice handling + + - ipv4: ip_gre: handle skb_pull() failure in ipgre_xmit() + + - dsa: mv88e6xxx: restore USXGMII support for 6393X + + - arcnet: restore support for multiple Sohard Arcnet cards + + Older releases - always broken: + + - tcp: do not accept ACK of bytes we never sent + + - require admin privileges to receive packet traces via netlink + + - packet: move reference count in packet_sock to atomic_long_t + + - bpf: + - fix incorrect branch offset comparison with cpu=v4 + - fix prog_array_map_poke_run map poke update + + - netfilter: + - three fixes for crashes on bad admin commands + - xt_owner: fix race accessing sk->sk_socket"," TOCTOU null-deref + - nf_tables: fix 'exist' matching on bigendian arches + + - leds: netdev: fix RTNL handling to prevent potential deadlock + + - eth: tg3: prevent races in error/reset handling + + - eth: r8169: fix rtl8125b PAUSE storm when suspended + + - eth: r8152: improve reset and surprise removal handling + + - eth: hns: fix race between changing features and sending + + - eth: nfp: fix sleep in atomic for bonding offload"" + +* tag 'net-6.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (62 commits) + vsock/virtio: fix ""comparison of distinct pointer types lacks a cast"" warning + net/smc: fix missing byte order conversion in CLC handshake + net: dsa: microchip: provide a list of valid protocols for xmit handler + drop_monitor: Require 'CAP_SYS_ADMIN' when joining ""events"" group + psample: Require 'CAP_NET_ADMIN' when joining ""packets"" group + bpf: sockmap","[' updating the sg structure should also update curr\n net: tls', "" update curr on splice as well\n nfp: flower: fix for take a mutex lock in soft irq context and rcu lock\n net: dsa: mv88e6xxx: Restore USXGMII support for 6393X\n tcp: do not accept ACK of bytes we never sent\n selftests/bpf: Add test for early update in prog_array_map_poke_run\n bpf: Fix prog_array_map_poke_run map poke update\n netfilter: xt_owner: Fix for unsafe access of sk->sk_socket\n netfilter: nf_tables: validate family when identifying table via handle\n netfilter: nf_tables: bail out on mismatching dynset and set expressions\n netfilter: nf_tables: fix 'exist' matching on bigendian arches\n netfilter: nft_set_pipapo: skip inactive elements during set walk\n netfilter: bpf: fix bad registration on nf_defrag\n leds: trigger: netdev: fix RTNL handling to prevent potential deadlock\n octeontx2-af: Update Tx link register range\n ...\n"", '']",The commit merges networking and eBPF related fixes for various issues in recent and older Linux kernel releases.,"networking, eBPF, fixes",It's a bug fix.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', ""It's not related to any of the above.""]" +483af466e4ee3326d150877ea0626e95c67a395e,483af466e4ee3326d150877ea0626e95c67a395e,Andrii Nakryiko,andrii@kernel.org,1701975456,Andrii Nakryiko,andrii@kernel.org,1701986294,ceead968fb8ab47e59d6c55e3bc087a68736c8a8,2146f7fe6e028a3905f0658a1a0d8ef7c115d6c1 1d38a9ee81570c4bd61f557832dead4d6f816760,"Merge branch 'bpf-fix-verification-of-indirect-var-off-stack-access' + +Andrei Matei says: + +==================== +bpf: fix verification of indirect var-off stack access + +V4 to V5: + - split the test into a separate patch + +V3 to V4: + - include a test per Eduard's request + - target bpf-next per Alexei's request (patches didn't change) + +V2 to V3: + - simplify checks for max_off (don't call + check_stack_slot_within_bounds for it) + - append a commit to protect against overflow in the addition of the + register and the offset + +V1 to V2: + - fix max_off calculation for access size = 0 +==================== + +Link: https://lore.kernel.org/r/20231207041150.229139-1-andreimatei1@gmail.com +Signed-off-by: Andrii Nakryiko +",,The commit fixes the verification of indirect variable offset stack access in the eBPF verifier.,"verification, indirect, stack",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1d38a9ee81570c4bd61f557832dead4d6f816760,1d38a9ee81570c4bd61f557832dead4d6f816760,Andrei Matei,andreimatei1@gmail.com,1701922310,Andrii Nakryiko,andrii@kernel.org,1701986290,ceead968fb8ab47e59d6c55e3bc087a68736c8a8,e28bd359bcc8eb849aaa475f3c3f9705fba26d6e,"bpf: Guard stack limits against 32bit overflow + +This patch promotes the arithmetic around checking stack bounds to be +done in the 64-bit domain"," instead of the current 32bit. The arithmetic +implies adding together a 64-bit register with a int offset. The +register was checked to be below 1<<29 when it was variable","[' but not\nwhen it was fixed. The offset either comes from an instruction (in which\ncase it is 16 bit)', ' from another register (in which case the caller\nchecked it to be below 1<<29 [1])', ' or from the size of an argument to a\nkfunc (in which case it can be a u32 [2]). Between the register being\ninconsistently checked to be below 1<<29', ' and the offset being up to an\nu32', ' it appears that we were open to overflowing the `int`s which were\ncurrently used for arithmetic.\n\n[1] https://github.com/torvalds/linux/blob/815fb87b753055df2d9e50f6cd80eb10235fe3e9/kernel/bpf/verifier.c#L7494-L7498\n[2] https://github.com/torvalds/linux/blob/815fb87b753055df2d9e50f6cd80eb10235fe3e9/kernel/bpf/verifier.c#L11904\n\nReported-by: Andrii Nakryiko \nSigned-off-by: Andrei Matei \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231207041150.229139-4-andreimatei1@gmail.com\n', '']",The commit updates stack checks to use 64-bit arithmetic to prevent potential overflow issues.,"stack,overflow,arithmetic",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e28bd359bcc8eb849aaa475f3c3f9705fba26d6e,e28bd359bcc8eb849aaa475f3c3f9705fba26d6e,Andrei Matei,andreimatei1@gmail.com,1701922309,Andrii Nakryiko,andrii@kernel.org,1701986282,593ce4a11490e2ee7e459dd6f639af64da28ad85,a833a17aeac73b33f79433d7cee68d5cafd71e4f,"bpf: Add verifier regression test for previous patch + +Add a regression test for var-off zero-sized reads. + +Signed-off-by: Andrei Matei +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231207041150.229139-3-andreimatei1@gmail.com +",,Added a regression test for zero-sized reads in the BPF verifier.,"verifier,regression,test",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a833a17aeac73b33f79433d7cee68d5cafd71e4f,a833a17aeac73b33f79433d7cee68d5cafd71e4f,Andrei Matei,andreimatei1@gmail.com,1701922308,Andrii Nakryiko,andrii@kernel.org,1701986273,9d0560315fa76d7656e4b951f989c1a699ded1ed,2146f7fe6e028a3905f0658a1a0d8ef7c115d6c1,"bpf: Fix verification of indirect var-off stack access + +This patch fixes a bug around the verification of possibly-zero-sized +stack accesses. When the access was done through a var-offset stack +pointer"," check_stack_access_within_bounds was incorrectly computing the +maximum-offset of a zero-sized read to be the same as the register's min +offset. Instead","["" we have to take in account the register's maximum\npossible value. The patch also simplifies how the max offset is checked;\nthe check is now simpler than for min offset.\n\nThe bug was allowing accesses to erroneously pass the\ncheck_stack_access_within_bounds() checks"", ' only to later crash in\ncheck_stack_range_initialized() when all the possibly-affected stack\nslots are iterated (this time with a correct max offset).\ncheck_stack_range_initialized() is relying on\ncheck_stack_access_within_bounds() for its accesses to the\nstack-tracking vector to be within bounds; in the case of zero-sized\naccesses', "" we were essentially only verifying that the lowest possible\nslot was within bounds. We would crash when the max-offset of the stack\npointer was >= 0 (which shouldn't pass verification"", ' and hopefully is\nnot something anyone\'s code attempts to do in practice).\n\nThanks Hao for reporting!\n\nFixes: 01f810ace9ed3 (""bpf: Allow variable-offset stack access"")\nReported-by: Hao Sun \nSigned-off-by: Andrei Matei \nSigned-off-by: Andrii Nakryiko \nAcked-by: Eduard Zingerman \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231207041150.229139-2-andreimatei1@gmail.com\n\nCloses: https://lore.kernel.org/bpf/CACkBjsZGEUaRCHsmaX=h-efVogsRfK1FPxmkgb0Os_frnHiNdw@mail.gmail.com/\n', '']",Fixes a bug in eBPF verifier for incorrect computation of max offset in indirect variable-offset stack access.,"bug fix,verification,stack access",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +bb9aefde5bbaf6c168c77ba635c155b4980c2287,bb9aefde5bbaf6c168c77ba635c155b4980c2287,John Fastabend,john.fastabend@gmail.com,1701905226,Jakub Kicinski,kuba@kernel.org,1701971549,590a28c3a75f9f88fee7c1077f38b5f6996b5958,c5a595000e2677e865a39f249c056bc05d6e55fd,bpf: sockmap," updating the sg structure should also update curr + +Curr pointer should be updated when the sg structure is shifted. + +Fixes: 7246d8ed4dcce (""bpf: helper to pop data from messages"") +Signed-off-by: John Fastabend +Link: https://lore.kernel.org/r/20231206232706.374377-3-john.fastabend@gmail.com +Signed-off-by: Jakub Kicinski +",[''],This commit fixes a curr pointer update issue in the sockmap when the sg structure is shifted.,"sockmap,curr pointer,fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['socket like programs'] +4de75d3e6b0ece518a2e6e48c2716f1b223716d3,4de75d3e6b0ece518a2e6e48c2716f1b223716d3,Jakub Kicinski,kuba@kernel.org,1701971009,Jakub Kicinski,kuba@kernel.org,1701971010,ed1191903a9064f5363d278e824dfa0329ba0b18,c85e5594b7456d55103fa1f1bde47cd4e002e7fb 7ae836a3d630e146b732fe8ef7d86b243748751f,"Merge tag 'nf-23-12-06' of git://git.kernel.org/pub/scm/linux/kernel/git/netfilter/nf + +Pablo Neira Ayuso says: + +==================== +Netfilter fixes for net + +The following patchset contains Netfilter fixes for net: + +1) Incorrect nf_defrag registration for bpf link infra"," from D. Wythe. + +2) Skip inactive elements in pipapo set backend walk to avoid double + deactivation","[' from Florian Westphal.\n\n3) Fix NFT_*_F_PRESENT check with big endian arch', ' also from Florian.\n\n4) Bail out if number of expressions in NFTA_DYNSET_EXPRESSIONS mismatch\n stateful expressions in set declaration.\n\n5) Honor family in table lookup by handle. Broken since 4.16.\n\n6) Use sk_callback_lock to protect access to sk->sk_socket in xt_owner.\n sock_orphan() might zap this pointer', "" from Phil Sutter.\n\nAll of these fixes address broken stuff for several releases.\n\n* tag 'nf-23-12-06' of git://git.kernel.org/pub/scm/linux/kernel/git/netfilter/nf:\n netfilter: xt_owner: Fix for unsafe access of sk->sk_socket\n netfilter: nf_tables: validate family when identifying table via handle\n netfilter: nf_tables: bail out on mismatching dynset and set expressions\n netfilter: nf_tables: fix 'exist' matching on bigendian arches\n netfilter: nft_set_pipapo: skip inactive elements during set walk\n netfilter: bpf: fix bad registration on nf_defrag\n====================\n\nLink: https://lore.kernel.org/r/20231206180357.959930-1-pablo@netfilter.org\nSigned-off-by: Jakub Kicinski \n"", '']",Merge Netfilter fixes for net including nf_defrag registration update for BPF link infra.,"Netfilter,BPF link,fixes",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c85e5594b7456d55103fa1f1bde47cd4e002e7fb,c85e5594b7456d55103fa1f1bde47cd4e002e7fb,Jakub Kicinski,kuba@kernel.org,1701970343,Jakub Kicinski,kuba@kernel.org,1701970344,1c0a09fc3833761d00c051008ebd92eedddab4b1,0ad722bd9ee3a9bdfca9613148645e4c9b7f26cf ffed24eff9e0e52d8e74df1c18db8ed43b4666e6,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-12-06 + +We've added 4 non-merge commits during the last 6 day(s) which contain +a total of 7 files changed", 185 insertions(+),"["" 55 deletions(-).\n\nThe main changes are:\n\n1) Fix race found by syzkaller on prog_array_map_poke_run when\n a BPF program's kallsym symbols were still missing"", "" from Jiri Olsa.\n\n2) Fix BPF verifier's branch offset comparison for BPF_JMP32 | BPF_JA"", ""\n from Yonghong Song.\n\n3) Fix xsk's poll handling to only set mask on bound xsk sockets"", ""\n from Yewon Choi.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n selftests/bpf: Add test for early update in prog_array_map_poke_run\n bpf: Fix prog_array_map_poke_run map poke update\n xsk: Skip polling event check for unbound socket\n bpf: Fix a verifier bug due to incorrect branch offset comparison with cpu=v4\n====================\n\nLink: https://lore.kernel.org/r/20231206220528.12093-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n"", '']",Merge commit for updates in bpf subsystem containing changes to 7 files with 185 insertions.,"merge, bpf, updates",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2146f7fe6e028a3905f0658a1a0d8ef7c115d6c1,2146f7fe6e028a3905f0658a1a0d8ef7c115d6c1,Alexei Starovoitov,ast@kernel.org,1701911841,Alexei Starovoitov,ast@kernel.org,1701911841,9ed227cd85ea4549462a4fecca5b1bada101d3c1,7065eefb38f16c91e9ace36fb7c873e4c9857c27 3ba026fca8786161b0c4d75be396e61d6816e0a1,"Merge branch 'allocate-bpf-trampoline-on-bpf_prog_pack' + +Song Liu says: + +==================== +Allocate bpf trampoline on bpf_prog_pack + +This set enables allocating bpf trampoline from bpf_prog_pack on x86. The +majority of this work", however,"[' is the refactoring of trampoline code.\nThis is needed because we need to handle 4 archs and 2 users (trampoline\nand struct_ops).\n\n1/7 through 6/7 refactors trampoline code. A few helpers are added.\n7/7 finally let bpf trampoline on x86 use bpf_prog_pack.\n\nChanges in v7:\n1. Use kvmalloc for rw_image in x86/arch_prepare_bpf_trampoline. (Alexei)\n2. Add comment to explain why we cannot use kvmalloc in\n x86/arch_bpf_trampoline_size. (Alexei)\n\nChanges in v6:\n1. Rebase.\n2. Add Acked-by and Tested-by from Jiri Olsa and Björn Töpel.\n\nChanges in v5:\n1. Adjust size of trampoline ksym. (Jiri)\n2. Use ""unsigned int size"" arg in image management helpers.(Daniel)\n\nChanges in v4:\n1. Dropped 1/8 in v3', ' which is already merged in bpf-next.\n2. Add Reviewed-by from Björn Töpel.\n\nChanges in v3:\n1. Fix bug in s390. (Thanks to Ilya Leoshkevich).\n2. Fix build error in riscv. (kernel test robot).\n\nChanges in v2:\n1. Add missing changes in net/bpf/bpf_dummy_struct_ops.c.\n2. Reduce one dry run in arch_prepare_bpf_trampoline. (Xu Kuohai)\n3. Other small fixes.\n====================\n\nLink: https://lore.kernel.org/r/20231206224054.492250-1-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit enables allocating BPF trampolines from bpf_prog_pack on x86.,"BPF trampolines, bpf_prog_pack, x86",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3ba026fca8786161b0c4d75be396e61d6816e0a1,3ba026fca8786161b0c4d75be396e61d6816e0a1,Song Liu,song@kernel.org,1701902454,Alexei Starovoitov,ast@kernel.org,1701911841,9ed227cd85ea4549462a4fecca5b1bada101d3c1,26ef208c209a0e6eed8942a5d191b39dccfa6e38,x86," bpf: Use bpf_prog_pack for bpf trampoline + +There are three major changes here: + +1. Add arch_[alloc|free]_bpf_trampoline based on bpf_prog_pack; +2. Let arch_prepare_bpf_trampoline handle ROX input image","[' this requires\n arch_prepare_bpf_trampoline allocating a temporary RW buffer;\n3. Update __arch_prepare_bpf_trampoline() to handle a RW buffer (rw_image)\n and a ROX buffer (image). This part is similar to the image/rw_image\n logic in bpf_int_jit_compile().\n\nSigned-off-by: Song Liu \nAcked-by: Ilya Leoshkevich \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/r/20231206224054.492250-8-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit adds arch_alloc and free_bpf_trampoline based on bpf_prog_pack and modifies arch_prepare_bpf_trampoline for ROX input image.,"bpf_prog_pack, bpf_trampoline, ROX",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +26ef208c209a0e6eed8942a5d191b39dccfa6e38,26ef208c209a0e6eed8942a5d191b39dccfa6e38,Song Liu,song@kernel.org,1701902453,Alexei Starovoitov,ast@kernel.org,1701911840,8db20d8a07885449ac7805d3c8829d1d4697773f,96d1b7c081c0c96cbe8901045f4ff15a2e9974a2,"bpf: Use arch_bpf_trampoline_size + +Instead of blindly allocating PAGE_SIZE for each trampoline"," check the size +of the trampoline with arch_bpf_trampoline_size(). This size is saved in +bpf_tramp_image->size","[' and used for modmem charge/uncharge. The fallback\narch_alloc_bpf_trampoline() still allocates a whole page because we need to\nuse set_memory_* to protect the memory.\n\nstruct_ops trampoline still uses a whole page for multiple trampolines.\n\nWith this size check at caller (regular trampoline and struct_ops\ntrampoline)', ' remove arch_bpf_trampoline_size() from\narch_prepare_bpf_trampoline() in archs.\n\nAlso', ' update bpf_image_ksym_add() to handle symbol of different sizes.\n\nSigned-off-by: Song Liu \nAcked-by: Ilya Leoshkevich \nTested-by: Ilya Leoshkevich # on s390x\nAcked-by: Jiri Olsa \nAcked-by: Björn Töpel \nTested-by: Björn Töpel # on riscv\nLink: https://lore.kernel.org/r/20231206224054.492250-7-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Optimize trampoline allocation in BPF by using arch_bpf_trampoline_size instead of default PAGE_SIZE.,"trampoline, allocation, BPF",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +96d1b7c081c0c96cbe8901045f4ff15a2e9974a2,96d1b7c081c0c96cbe8901045f4ff15a2e9974a2,Song Liu,song@kernel.org,1701902452,Alexei Starovoitov,ast@kernel.org,1701911840,1c42f14146f5308976355f4d3d84b4cb4e91a420,38b8b58ae776bf748bd1bd7a24c3fd1d10f76f45,"bpf: Add arch_bpf_trampoline_size() + +This helper will be used to calculate the size of the trampoline before +allocating the memory. + +arch_prepare_bpf_trampoline() for arm64 and riscv64 can use +arch_bpf_trampoline_size() to check the trampoline fits in the image. + +OTOH"," arch_prepare_bpf_trampoline() for s390 has to call the JIT process +twice","[' so it cannot use arch_bpf_trampoline_size().\n\nSigned-off-by: Song Liu \nAcked-by: Ilya Leoshkevich \nTested-by: Ilya Leoshkevich # on s390x\nAcked-by: Jiri Olsa \nAcked-by: Björn Töpel \nTested-by: Björn Töpel # on riscv\nLink: https://lore.kernel.org/r/20231206224054.492250-6-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit adds a helper to calculate trampoline size before memory allocation for arm64 and riscv64 architectures.,"trampoline, arm64, riscv64",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +38b8b58ae776bf748bd1bd7a24c3fd1d10f76f45,38b8b58ae776bf748bd1bd7a24c3fd1d10f76f45,Song Liu,song@kernel.org,1701902451,Alexei Starovoitov,ast@kernel.org,1701911840,af31897df3062fe16cfd7962d0e5dab0a3767be6,82583daa2efc2e336962b231a46bad03a280b3e0,bpf," x86: Adjust arch_prepare_bpf_trampoline return value + +x86's implementation of arch_prepare_bpf_trampoline() requires +BPF_INSN_SAFETY buffer space between end of program and image_end. OTOH","[""\nthe return value does not include BPF_INSN_SAFETY. This doesn't cause any\nreal issue at the moment. However"", ' ""image"" of size retval is not enough for\narch_prepare_bpf_trampoline(). This will cause confusion when we introduce\na new helper arch_bpf_trampoline_size(). To avoid future confusion', ' adjust\nthe return value to include BPF_INSN_SAFETY.\n\nSigned-off-by: Song Liu \nAcked-by: Ilya Leoshkevich \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/r/20231206224054.492250-5-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Adjust return value of arch_prepare_bpf_trampoline on x86 to ensure buffer space for BPF_INSN_SAFETY.,"x86, bpf trampoline, buffer space",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +82583daa2efc2e336962b231a46bad03a280b3e0,82583daa2efc2e336962b231a46bad03a280b3e0,Song Liu,song@kernel.org,1701902450,Alexei Starovoitov,ast@kernel.org,1701911840,2d4dbd41a6b3f940756a29355ecda952753beff1,7a3d9a159b178e87306a6e989071ed9a114a1a31,"bpf: Add helpers for trampoline image management + +As BPF trampoline of different archs moves from bpf_jit_[alloc|free]_exec() +to bpf_prog_pack_[alloc|free]()", we need to use different _alloc,"[' _free for\ndifferent archs during the transition. Add the following helpers for this\ntransition:\n\nvoid *arch_alloc_bpf_trampoline(unsigned int size);\nvoid arch_free_bpf_trampoline(void *image', ' unsigned int size);\nvoid arch_protect_bpf_trampoline(void *image', ' unsigned int size);\nvoid arch_unprotect_bpf_trampoline(void *image', ' unsigned int size);\n\nThe fallback version of these helpers require size <= PAGE_SIZE', ' but they\nare only called with size == PAGE_SIZE. They will be called with size <\nPAGE_SIZE when arch_bpf_trampoline_size() helper is introduced later.\n\nSigned-off-by: Song Liu \nAcked-by: Ilya Leoshkevich \nTested-by: Ilya Leoshkevich # on s390x\nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/r/20231206224054.492250-4-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add helpers for managing trampoline images in BPF by transitioning from bpf_jit to bpf_prog_pack.,"trampoline, helpers, management",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7a3d9a159b178e87306a6e989071ed9a114a1a31,7a3d9a159b178e87306a6e989071ed9a114a1a31,Song Liu,song@kernel.org,1701902449,Alexei Starovoitov,ast@kernel.org,1701911840,1b447beb17e72ffcf7eef17b14131ef786f7d181,f08a1c658257c73697a819c4ded3a84b6f0ead74,"bpf: Adjust argument names of arch_prepare_bpf_trampoline() + +We are using ""im"" for ""struct bpf_tramp_image"" and ""tr"" for ""struct +bpf_trampoline"" in most of the code base. The only exception is the +prototype and fallback version of arch_prepare_bpf_trampoline(). Update +them to match the rest of the code base. + +We mix ""orig_call"" and ""func_addr"" for the argument in different versions +of arch_prepare_bpf_trampoline(). s/orig_call/func_addr/g so they match. + +Signed-off-by: Song Liu +Acked-by: Ilya Leoshkevich +Tested-by: Ilya Leoshkevich # on s390x +Acked-by: Jiri Olsa +Link: https://lore.kernel.org/r/20231206224054.492250-3-song@kernel.org +Signed-off-by: Alexei Starovoitov +",,Update argument names in arch_prepare_bpf_trampoline() for consistency across code base.,"argument, names, consistency",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f08a1c658257c73697a819c4ded3a84b6f0ead74,f08a1c658257c73697a819c4ded3a84b6f0ead74,Song Liu,song@kernel.org,1701902448,Alexei Starovoitov,ast@kernel.org,1701911840,447d1a173b1f692cb45d232801e1d855adf315fc,7065eefb38f16c91e9ace36fb7c873e4c9857c27,"bpf: Let bpf_prog_pack_free handle any pointer + +Currently"," bpf_prog_pack_free only can only free pointer to struct +bpf_binary_header","[' which is not flexible. Add a size argument to\nbpf_prog_pack_free so that it can handle any pointer.\n\nSigned-off-by: Song Liu \nAcked-by: Ilya Leoshkevich \nTested-by: Ilya Leoshkevich # on s390x\nReviewed-by: Björn Töpel \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/r/20231206224054.492250-2-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhanced bpf_prog_pack_free to handle any pointer instead of just bpf_binary_header.,"bpf_prog_pack_free,pointer,enhancement",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7065eefb38f16c91e9ace36fb7c873e4c9857c27,7065eefb38f16c91e9ace36fb7c873e4c9857c27,Andrii Nakryiko,andrii@kernel.org,1701889760,Alexei Starovoitov,ast@kernel.org,1701902476,1b866cccb8f0b22271b857ef62062a03d4c5b12b,c35919dcce2855d68cf45ffa427b8ea78e4f7c68,"bpf: rename MAX_BPF_LINK_TYPE into __MAX_BPF_LINK_TYPE for consistency + +To stay consistent with the naming pattern used for similar cases in BPF +UAPI (__MAX_BPF_ATTACH_TYPE", etc),"[' rename MAX_BPF_LINK_TYPE into\n__MAX_BPF_LINK_TYPE.\n\nAlso similar to MAX_BPF_ATTACH_TYPE and MAX_BPF_REG', ' add:\n\n #define MAX_BPF_LINK_TYPE __MAX_BPF_LINK_TYPE\n\nNot all __MAX_xxx enums have such #define', "" so I'm not sure if we should\nadd it or not"", "" but I figured I'll start with a completely backwards\ncompatible way"", ' and we can drop that', ' if necessary.\n\nAlso adjust a selftest that used MAX_BPF_LINK_TYPE enum.\n\nSuggested-by: Alexei Starovoitov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231206190920.1651226-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Renamed MAX_BPF_LINK_TYPE to __MAX_BPF_LINK_TYPE for naming consistency.,"rename, consistency, UAPI",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ffed24eff9e0e52d8e74df1c18db8ed43b4666e6,ffed24eff9e0e52d8e74df1c18db8ed43b4666e6,Jiri Olsa,jolsa@kernel.org,1701851441,Daniel Borkmann,daniel@iogearbox.net,1701898843,7c0495e6f3bd9983db78a626ca27cb07f3b4cf25,4b7de801606e504e69689df71475d27e35336fb3,"selftests/bpf: Add test for early update in prog_array_map_poke_run + +Adding test that tries to trigger the BUG_IN during early map update +in prog_array_map_poke_run function. + +The idea is to share prog array map between thread that constantly +updates it and another one loading a program that uses that prog +array. + +Eventually we will hit a place where the program is ok to be updated +(poke->tailcall_target_stable check) but the address is still not +registered in kallsyms"," so the bpf_arch_text_poke returns -EINVAL +and cause imbalance for the next tail call update check","[' which will\nfail with -EBUSY in bpf_arch_text_poke as described in previous fix.\n\nSigned-off-by: Jiri Olsa \nSigned-off-by: Daniel Borkmann \nAcked-by: Ilya Leoshkevich \nLink: https://lore.kernel.org/bpf/20231206083041.1306660-3-jolsa@kernel.org\n', '']",Add test to selftests/bpf for early map update in prog_array_map_poke_run function.,"test, early update, prog_array_map_poke_run",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4b7de801606e504e69689df71475d27e35336fb3,4b7de801606e504e69689df71475d27e35336fb3,Jiri Olsa,jolsa@kernel.org,1701851440,Daniel Borkmann,daniel@iogearbox.net,1701898816,1ab3b1d4f0d0bad6e845121d2cee745cb32d064e,e4d008d49a7135214e0ee70537405b6a069e3a3f,"bpf: Fix prog_array_map_poke_run map poke update + +Lee pointed out issue found by syscaller [0] hitting BUG in prog array +map poke update in prog_array_map_poke_run function due to error value +returned from bpf_arch_text_poke function. + +There's race window where bpf_arch_text_poke can fail due to missing +bpf program kallsym symbols"," which is accounted for with check for +-EINVAL in that BUG_ON call. + +The problem is that in such case we won't update the tail call jump +and cause imbalance for the next tail call update check which will +fail with -EBUSY in bpf_arch_text_poke. + +I'm hitting following race during the program load: + + CPU 0 CPU 1 + + bpf_prog_load + bpf_check + do_misc_fixups + prog_array_map_poke_track + + map_update_elem + bpf_fd_array_map_update_elem + prog_array_map_poke_run + + bpf_arch_text_poke returns -EINVAL + + bpf_prog_kallsyms_add + +After bpf_arch_text_poke (CPU 1) fails to update the tail call jump","[' the next\npoke update fails on expected jump instruction check in bpf_arch_text_poke\nwith -EBUSY and triggers the BUG_ON in prog_array_map_poke_run.\n\nSimilar race exists on the program unload.\n\nFixing this by moving the update to bpf_arch_poke_desc_update function which\nmakes sure we call __bpf_arch_text_poke that skips the bpf address check.\n\nEach architecture has slightly different approach wrt looking up bpf address\nin bpf_arch_text_poke', "" so instead of splitting the function or adding new\n'checkip' argument in previous version"", ' it seems best to move the whole\nmap_poke_run update as arch specific code.\n\n [0] https://syzkaller.appspot.com/bug?extid=97a4fe20470e9bc30810\n\nFixes: ebf7d1f508a7 (""bpf', ' x64: rework pro/epilogue and tailcall handling in JIT"")\nReported-by: syzbot+97a4fe20470e9bc30810@syzkaller.appspotmail.com\nSigned-off-by: Jiri Olsa \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nCc: Lee Jones \nCc: Maciej Fijalkowski \nLink: https://lore.kernel.org/bpf/20231206083041.1306660-2-jolsa@kernel.org\n', '']",Fixes a bug in prog_array_map_poke_run to handle race conditions during bpf_arch_text_poke failures.,"bug,race condition,update",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c35919dcce2855d68cf45ffa427b8ea78e4f7c68,c35919dcce2855d68cf45ffa427b8ea78e4f7c68,Alexei Starovoitov,ast@kernel.org,1701885780,Alexei Starovoitov,ast@kernel.org,1701885781,b25a269f54206b8652cf64b002d7d589d505a8c1,3aee2bf9c49be2144460d7267560232e3d45d367 36fb94944b35062db15ab3059f4123048cac658c,"Merge branch 'bpf-token-and-bpf-fs-based-delegation' + +Andrii Nakryiko says: + +==================== +BPF token and BPF FS-based delegation + +This patch set introduces an ability to delegate a subset of BPF subsystem +functionality from privileged system-wide daemon (e.g."," systemd or any other +container manager) through special mount options for userns-bound BPF FS to +a *trusted* unprivileged application. Trust is the key here. This +functionality is not about allowing unconditional unprivileged BPF usage. +Establishing trust","[' though', ' is completely up to the discretion of respective\nprivileged application that would create and mount a BPF FS instance with\ndelegation enabled', ' as different production setups can and do achieve it\nthrough a combination of different means (signing', ' LSM', ' code reviews', ' etc)', ""\nand it's undesirable and infeasible for kernel to enforce any particular way\nof validating trustworthiness of particular process.\n\nThe main motivation for this work is a desire to enable containerized BPF\napplications to be used together with user namespaces. This is currently\nimpossible"", ' as CAP_BPF', ' required for BPF subsystem usage', ' cannot be namespaced\nor sandboxed', ' as a general rule. E.g.', ' tracing BPF programs', ' thanks to BPF\nhelpers like bpf_probe_read_kernel() and bpf_probe_read_user() can safely read\narbitrary memory', "" and it's impossible to ensure that they only read memory of\nprocesses belonging to any given namespace. This means that it's impossible to\nhave a mechanically verifiable namespace-aware CAP_BPF capability"", ' and as such\nanother mechanism to allow safe usage of BPF functionality is necessary.BPF FS\ndelegation mount options and BPF token derived from such BPF FS instance is\nsuch a mechanism. Kernel makes no assumption about what ""trusted"" constitutes\nin any particular case', "" and it's up to specific privileged applications and\ntheir surrounding infrastructure to decide that. What kernel provides is a set\nof APIs to setup and mount special BPF FS instanecs and derive BPF tokens from\nit. BPF FS and BPF token are both bound to its owning userns and in such a way\nare constrained inside intended container. Users can then pass BPF token FD to\nprivileged bpf() syscall commands"", ' like BPF map creation and BPF program\nloading', ' to perform such operations without having init userns privileged.\n\nThis version incorporates feedback and suggestions ([3]) received on v3 of\nthis patch set', ' and instead of allowing to create BPF tokens directly assuming\ncapable(CAP_SYS_ADMIN)', ' we instead enhance BPF FS to accept a few new\ndelegation mount options. If these options are used and BPF FS itself is\nproperly created', ' set up', ' and mounted inside the user namespaced container', '\nuser application is able to derive a BPF token object from BPF FS instance', '\nand pass that token to bpf() syscall. As explained in patch #3', "" BPF token\nitself doesn't grant access to BPF functionality"", ' but instead allows kernel to\ndo namespaced capabilities checks (ns_capable() vs capable()) for CAP_BPF', '\nCAP_PERFMON', ' CAP_NET_ADMIN', ' and CAP_SYS_ADMIN', ' as applicable. So it forms one\nhalf of a puzzle and allows container managers and sys admins to have safe and\nflexible configuration options: determining which containers get delegation of\nBPF functionality through BPF FS', ' and then which applications within such\ncontainers are allowed to perform bpf() commands', ' based on namespaces\ncapabilities.\n\nPrevious attempt at addressing this very same problem ([0]) attempted to\nutilize authoritative LSM approach', ' but was conclusively rejected by upstream\nLSM maintainers. BPF token concept is not changing anything about LSM\napproach', ' but can be combined with LSM hooks for very fine-grained security\npolicy. Some ideas about making BPF token more convenient to use with LSM (in\nparticular custom BPF LSM programs) was briefly described in recent LSF/MM/BPF\n2023 presentation ([1]). E.g.', ' an ability to specify user-provided data\n(context)', ' which in combination with BPF LSM would allow implementing a very\ndynamic and fine-granular custom security policies on top of BPF token. In the\ninterest of minimizing API surface area and discussions this was relegated to\nfollow up patches', "" as it's not essential to the fundamental concept of\ndelegatable BPF token.\n\nIt should be noted that BPF token is conceptually quite similar to the idea of\n/dev/bpf device file"", ' proposed by Song a while ago ([2]). The biggest\ndifference is the idea of using virtual anon_inode file to hold BPF token and\nallowing multiple independent instances of them', ' each (potentially) with its\nown set of restrictions. And also', ' crucially', ' BPF token approach is not using\nany special stateful task-scoped flags. Instead', ' bpf() syscall accepts\ntoken_fd parameters explicitly for each relevant BPF command. This addresses\nmain concerns brought up during the /dev/bpf discussion', ' and fits better with\noverall BPF subsystem design.\n\nThis patch set adds a basic minimum of functionality to make BPF token idea\nuseful and to discuss API and functionality. Currently only low-level libbpf\nAPIs support creating and passing BPF token around', ' allowing to test kernel\nfunctionality', ' but for the most part is not sufficient for real-world\napplications', ' which typically use high-level libbpf APIs based on `struct\nbpf_object` type. This was done with the intent to limit the size of patch set\nand concentrate on mostly kernel-side changes. All the necessary plumbing for\nlibbpf will be sent as a separate follow up patch set kernel support makes it\nupstream.\n\nAnother part that should happen once kernel-side BPF token is established', ' is\na set of conventions between applications (e.g.', ' systemd)', ' tools (e.g.', '\nbpftool)', ' and libraries (e.g.', "" libbpf) on exposing delegatable BPF FS\ninstance(s) at well-defined locations to allow applications take advantage of\nthis in automatic fashion without explicit code changes on BPF application's\nside. But I'd like to postpone this discussion to after BPF token concept\nlands.\n\n [0] https://lore.kernel.org/bpf/20230412043300.360803-1-andrii@kernel.org/\n [1] http://vger.kernel.org/bpfconf2023_material/Trusted_unprivileged_BPF_LSFMM2023.pdf\n [2] https://lore.kernel.org/bpf/20190627201923.2589391-2-songliubraving@fb.com/\n [3] https://lore.kernel.org/bpf/20230704-hochverdient-lehne-eeb9eeef785e@brauner/\n\nv11->v12:\n - enforce exact userns match in bpf_token_capable() and\n bpf_token_allow_cmd() checks"", ' for added strictness (Christian);\nv10->v11:\n - fix BPF FS root check to disallow using bind-mounted subdirectory of BPF\n FS instance (Christian);\n - further restrict BPF_TOKEN_CREATE command to be executed from inside\n exactly the same user namespace as the one used to create BPF FS instance\n (Christian);\nv9->v10:\n - slight adjustments in LSM parts (Paul);\n - setting delegate_xxx options require capable(CAP_SYS_ADMIN) (Christian);\n - simplify BPF_TOKEN_CREATE UAPI by accepting BPF FS FD directly (Christian);\nv8->v9:\n - fix issue in selftests due to sys/mount.h header (Jiri);\n - fix warning in doc comments in LSM hooks (kernel test robot);\nv7->v8:\n - add bpf_token_allow_cmd and bpf_token_capable hooks (Paul);\n - inline bpf_token_alloc() into bpf_token_create() to prevent accidental\n divergence with security_bpf_token_create() hook (Paul);\nv6->v7:\n - separate patches to refactor bpf_prog_alloc/bpf_map_alloc LSM hooks', ' as\n discussed with Paul', ' and now they also accept struct bpf_token;\n - added bpf_token_create/bpf_token_free to allow LSMs (SELinux', '\n specifically) to set up security LSM blob (Paul);\n - last patch also wires bpf_security_struct setup by SELinux', "" similar to how\n it's done for BPF map/prog"", "" though I'm not sure if that's enough"", "" so worst\n case it's easy to drop this patch if more full fledged SELinux\n implementation will be done separately;\n - small fixes for issues caught by code reviews (Jiri"", "" Hou);\n - fix for test_maps test that doesn't use LIBBPF_OPTS() macro (CI);\nv5->v6:\n - fix possible use of uninitialized variable in selftests (CI);\n - don't use anon_inode"", "" instead create one from BPF FS instance (Christian);\n - don't store bpf_token inside struct bpf_map"", ' instead pass it explicitly to\n map_check_btf(). We do store bpf_token inside prog->aux', "" because it's used\n during verification and even can be checked during attach time for some\n program types;\n - LSM hooks are left intact pending the conclusion of discussion with Paul\n Moore; I'd prefer to do LSM-related changes as a follow up patch set\n anyways;\nv4->v5:\n - add pre-patch unifying CAP_NET_ADMIN handling inside kernel/bpf/syscall.c\n (Paul Moore);\n - fix build warnings and errors in selftests and kernel"", "" detected by CI and\n kernel test robot;\nv3->v4:\n - add delegation mount options to BPF FS;\n - BPF token is derived from the instance of BPF FS and associates itself\n with BPF FS' owning userns;\n - BPF token doesn't grant BPF functionality directly"", "" it just turns\n capable() checks into ns_capable() checks within BPF FS' owning user;\n - BPF token cannot be pinned;\nv2->v3:\n - make BPF_TOKEN_CREATE pin created BPF token in BPF FS"", ' and disallow\n BPF_OBJ_PIN for BPF token;\nv1->v2:\n - fix build failures on Kconfig with CONFIG_BPF_SYSCALL unset;\n - drop BPF_F_TOKEN_UNKNOWN_* flags and simplify UAPI (Stanislav).\n====================\n\nLink: https://lore.kernel.org/r/20231130185229.2688956-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit introduces BPF token and BPF FS-based delegation to unprivileged applications via trusted system-wide daemons.,"BPF token, delegation, unprivileged",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +36fb94944b35062db15ab3059f4123048cac658c,36fb94944b35062db15ab3059f4123048cac658c,Andrii Nakryiko,andrii@kernel.org,1701370349,Alexei Starovoitov,ast@kernel.org,1701885780,b25a269f54206b8652cf64b002d7d589d505a8c1,dc5196fac40c2cb96330bcb98eef868a7fd225b3,bpf,"selinux: allocate bpf_security_struct per BPF token + +Utilize newly added bpf_token_create/bpf_token_free LSM hooks to +allocate struct bpf_security_struct for each BPF token object in +SELinux. This just follows similar pattern for BPF prog and map. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-18-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Allocate bpf_security_struct for each BPF token in SELinux using new LSM hooks.,"LSM hooks, BPF token, SELinux",It's a security fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['cgroup like programs', 'LSM like programs']" +dc5196fac40c2cb96330bcb98eef868a7fd225b3,dc5196fac40c2cb96330bcb98eef868a7fd225b3,Andrii Nakryiko,andrii@kernel.org,1701370348,Alexei Starovoitov,ast@kernel.org,1701885780,adfd0beabe2cf3afa09142802dab5eea60323f27,1571740a9ba036f26cc5211a86021199987219e8,"selftests/bpf: add BPF token-enabled tests + +Add a selftest that attempts to conceptually replicate intended BPF +token use cases inside user namespaced container. + +Child process is forked. It is then put into its own userns and mountns. +Child creates BPF FS context object. This ensures child userns is +captured as the owning userns for this instance of BPF FS. Given setting +delegation mount options is privileged operation"," we ensure that child +cannot set them. + +This context is passed back to privileged parent process through Unix +socket","[' where parent sets up delegation options', ' creates', ' and mounts it\nas a detached mount. This mount FD is passed back to the child to be\nused for BPF token creation', ' which allows otherwise privileged BPF\noperations to succeed inside userns.\n\nWe validate that all of token-enabled privileged commands (BPF_BTF_LOAD', '\nBPF_MAP_CREATE', ' and BPF_PROG_LOAD) work as intended. They should only\nsucceed inside the userns if a) BPF token is provided with proper\nallowed sets of commands and types; and b) namespaces CAP_BPF and other\nprivileges are set. Lacking a) or b) should lead to -EPERM failures.\n\nBased on suggested workflow by Christian Brauner ([0]).\n\n [0] https://lore.kernel.org/bpf/20230704-hochverdient-lehne-eeb9eeef785e@brauner/\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-17-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftests for BPF token use cases in user namespaced containers.,BPF token selftests,It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1571740a9ba036f26cc5211a86021199987219e8,1571740a9ba036f26cc5211a86021199987219e8,Andrii Nakryiko,andrii@kernel.org,1701370347,Alexei Starovoitov,ast@kernel.org,1701885780,a1c154e2a1c4845c848d183eddd0055e56cf5fe5,1a8df7fa00aac35aff9ef1941c5334b3a01d09e4,"libbpf: add BPF token support to bpf_prog_load() API + +Wire through token_fd into bpf_prog_load(). + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-16-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add BPF token support to bpf_prog_load API in libbpf.,"BPF, token, libbpf",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1a8df7fa00aac35aff9ef1941c5334b3a01d09e4,1a8df7fa00aac35aff9ef1941c5334b3a01d09e4,Andrii Nakryiko,andrii@kernel.org,1701370346,Alexei Starovoitov,ast@kernel.org,1701885780,59d1151a9cfb1cf98a61ab9ed845ed2873e2128c,37891cea6699200fb83eae464ebe1c0f73040474,"libbpf: add BPF token support to bpf_btf_load() API + +Allow user to specify token_fd for bpf_btf_load() API that wraps +kernel's BPF_BTF_LOAD command. This allows loading BTF from unprivileged +process as long as it has BPF token allowing BPF_BTF_LOAD command"," which +can be created and delegated by privileged process. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-15-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Added support for BPF token in bpf_btf_load() API to allow BTF loading from unprivileged processes.,"BPF token,BTF loading,unprivileged",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +37891cea6699200fb83eae464ebe1c0f73040474,37891cea6699200fb83eae464ebe1c0f73040474,Andrii Nakryiko,andrii@kernel.org,1701370345,Alexei Starovoitov,ast@kernel.org,1701885780,ce8e64399d02a500998496f74e02231122fe1ce3,ecd435143eb03611e25694141bf59d1c04ad5b9e,"libbpf: add BPF token support to bpf_map_create() API + +Add ability to provide token_fd for BPF_MAP_CREATE command through +bpf_map_create() API. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-14-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add BPF token support to the bpf_map_create() API in libbpf.,"BPF, token, libbpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ecd435143eb03611e25694141bf59d1c04ad5b9e,ecd435143eb03611e25694141bf59d1c04ad5b9e,Andrii Nakryiko,andrii@kernel.org,1701370344,Alexei Starovoitov,ast@kernel.org,1701885780,bdf126a236403522427e17dfb69c834f9248d76a,d734ca7b33dbf60eb15dcf7c44f3da7073356777,"libbpf: add bpf_token_create() API + +Add low-level wrapper API for BPF_TOKEN_CREATE command in bpf() syscall. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-13-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Introduces a new API bpf_token_create() for BPF_TOKEN_CREATE command in the bpf() syscall.,"API, bpf_token_create, syscall",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d734ca7b33dbf60eb15dcf7c44f3da7073356777,d734ca7b33dbf60eb15dcf7c44f3da7073356777,Andrii Nakryiko,andrii@kernel.org,1701370343,Alexei Starovoitov,ast@kernel.org,1701885780,094194f17a60f5e22567a26ba3ae537556a54456,66d636d70a79c1d37e3eea67ab50969e6aaef983,bpf,"lsm: add BPF token LSM hooks + +Wire up bpf_token_create and bpf_token_free LSM hooks","[' which allow to\nallocate LSM security blob (we add `void *security` field to struct\nbpf_token for that)', "" but also control who can instantiate BPF token.\nThis follows existing pattern for BPF map and BPF prog.\n\nAlso add security_bpf_token_allow_cmd() and security_bpf_token_capable()\nLSM hooks that allow LSM implementation to control and negate (if\nnecessary) BPF token's delegation of a specific bpf_cmd and capability"", '\nrespectively.\n\nAcked-by: Paul Moore \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-12-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added LSM hooks for BPF token creation and deletion in the BPF subsystem.,"LSM hooks, BPF token, creation",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['LSM like programs'] +66d636d70a79c1d37e3eea67ab50969e6aaef983,66d636d70a79c1d37e3eea67ab50969e6aaef983,Andrii Nakryiko,andrii@kernel.org,1701370342,Alexei Starovoitov,ast@kernel.org,1701885779,eb838d10ef24f65149fd1984d73d6b7a755156b8,c3dd6e94df7193f33f45d33303f5e85afb2a72dc,bpf,"lsm: refactor bpf_map_alloc/bpf_map_free LSM hooks + +Similarly to bpf_prog_alloc LSM hook","[' rename and extend bpf_map_alloc\nhook into bpf_map_create', ' taking not just struct bpf_map', ' but also\nbpf_attr and bpf_token', ' to give a fuller context to LSMs.\n\nUnlike bpf_prog_alloc', ' there is no need to move the hook around', ' as it\ncurrently is firing right before allocating BPF map ID and FD', ' which\nseems to be a sweet spot.\n\nBut like bpf_prog_alloc/bpf_prog_free combo', ' make sure that bpf_map_free\nLSM hook is called even if bpf_map_create hook returned error', ' as if few\nLSMs are combined together it could be that one LSM successfully\nallocated security blob for its needs', ' while subsequent LSM rejected BPF\nmap creation. The former LSM would still need to free up LSM blob', ' so we\nneed to ensure security_bpf_map_free() is called regardless of the\noutcome.\n\nAcked-by: Paul Moore \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-11-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Refactor the bpf_map_alloc and bpf_map_free LSM hooks.,"refactor, LSM hooks, bpf_map",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['LSM like programs'] +c3dd6e94df7193f33f45d33303f5e85afb2a72dc,c3dd6e94df7193f33f45d33303f5e85afb2a72dc,Andrii Nakryiko,andrii@kernel.org,1701370341,Alexei Starovoitov,ast@kernel.org,1701885779,59dbdb263ff295fd81294b57ef45d72d11ada98e,8062fb12de99b2da33754c6a3be1bfc30d9a35f4,bpf,"lsm: refactor bpf_prog_alloc/bpf_prog_free LSM hooks + +Based on upstream discussion ([0])","[' rework existing\nbpf_prog_alloc_security LSM hook. Rename it to bpf_prog_load and instead\nof passing bpf_prog_aux', ' pass proper bpf_prog pointer for a full BPF\nprogram struct. Also', ' we pass bpf_attr union with all the user-provided\narguments for BPF_PROG_LOAD command. This will give LSMs as much\ninformation as we can basically provide.\n\nThe hook is also BPF token-aware now', ' and optional bpf_token struct is\npassed as a third argument. bpf_prog_load LSM hook is called after\na bunch of sanity checks were performed', ' bpf_prog and bpf_prog_aux were\nallocated and filled out', ' but right before performing full-fledged BPF\nverification step.\n\nbpf_prog_free LSM hook is now accepting struct bpf_prog argument', ' for\nconsistency. SELinux code is adjusted to all new names', ' types', ' and\nsignatures.\n\nNote', ' given that bpf_prog_load (previously bpf_prog_alloc) hook can be\nused by some LSMs to allocate extra security blob', ' but also by other\nLSMs to reject BPF program loading', "" we need to make sure that\nbpf_prog_free LSM hook is called after bpf_prog_load/bpf_prog_alloc one\n*even* if the hook itself returned error. If we don't do that"", ' we run\nthe risk of leaking memory. This seems to be possible today when\ncombining SELinux and BPF LSM', ' as one example', ' depending on their\nrelative ordering.\n\nAlso', ' for BPF LSM setup', ' add bpf_prog_load and bpf_prog_free to\nsleepable LSM hooks list', ' as they are both executed in sleepable\ncontext. Also drop bpf_prog_load hook from untrusted', ' as there is no\nissue with refcount or anything else anymore', ' that originally forced us\nto add it to untrusted list in c0c852dd1876 (""bpf: Do not mark certain LSM\nhook arguments as trusted""). We now trigger this hook much later and it\nshould not be an issue anymore.\n\n [0] https://lore.kernel.org/bpf/9fe88aef7deabbe87d3fc38c4aea3c69.paul@paul-moore.com/\n\nAcked-by: Paul Moore \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-10-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Refactor Linux Security Module (LSM) hooks for bpf_prog_alloc and bpf_prog_free functions.,"refactor,LSM hooks,bpf_prog_alloc",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['LSM like programs'] +8062fb12de99b2da33754c6a3be1bfc30d9a35f4,8062fb12de99b2da33754c6a3be1bfc30d9a35f4,Andrii Nakryiko,andrii@kernel.org,1701370340,Alexei Starovoitov,ast@kernel.org,1701885779,5c70426f65a08c9b76c69c95fe98f1e44ef05b5e,4cbb270e115bc197ff2046aeb54cc951666b16ec,"bpf: consistently use BPF token throughout BPF verifier logic + +Remove remaining direct queries to perfmon_capable() and bpf_capable() +in BPF verifier logic and instead use BPF token (if available) to make +decisions about privileges. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,The commit updates the BPF verifier logic to consistently use BPF token instead of direct capability checks.,"BPF verifier,BPF token,privileges",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4cbb270e115bc197ff2046aeb54cc951666b16ec,4cbb270e115bc197ff2046aeb54cc951666b16ec,Andrii Nakryiko,andrii@kernel.org,1701370339,Alexei Starovoitov,ast@kernel.org,1701885779,649b1a6a47043000dff55125dc5a91ad91fd24b7,e1cef620f598853a90f17701fcb1057a6768f7b8,"bpf: take into account BPF token when fetching helper protos + +Instead of performing unconditional system-wide bpf_capable() and +perfmon_capable() calls inside bpf_base_func_proto() function (and other +similar ones) to determine eligibility of a given BPF helper for a given +program"," use previously recorded BPF token during BPF_PROG_LOAD command +handling to inform the decision. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-8-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],The commit optimizes BPF helper protos fetching by using recorded BPF token rather than system-wide capability checks.,"BPF token, helper protos, bpf_capable",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e1cef620f598853a90f17701fcb1057a6768f7b8,e1cef620f598853a90f17701fcb1057a6768f7b8,Andrii Nakryiko,andrii@kernel.org,1701370338,Alexei Starovoitov,ast@kernel.org,1701885779,95d4f672f64ffeba968c3f8b8174783e52b093cb,ee54b1a910e4d49c9a104f31ae3f5b979131adf8,"bpf: add BPF token support to BPF_PROG_LOAD command + +Add basic support of BPF token to BPF_PROG_LOAD. Wire through a set of +allowed BPF program types and attach types"," derived from BPF FS at BPF +token creation time. Then make sure we perform bpf_token_capable() +checks everywhere where it's relevant. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231130185229.2688956-7-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],"Add BPF token support to the BPF_PROG_LOAD command, allowing specific BPF program types and attach types.","BPF token,BPF_PROG_LOAD,support",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ee54b1a910e4d49c9a104f31ae3f5b979131adf8,ee54b1a910e4d49c9a104f31ae3f5b979131adf8,Andrii Nakryiko,andrii@kernel.org,1701370337,Alexei Starovoitov,ast@kernel.org,1701885779,e194d7f010b8356f8530f8c923b899418b6befb7,688b7270b3cb75e8ac78123d719967db40336e5b,"bpf: add BPF token support to BPF_BTF_LOAD command + +Accept BPF token FD in BPF_BTF_LOAD command to allow BTF data loading +through delegated BPF token. BTF loading is a pretty straightforward +operation"," so as long as BPF token is created with allow_cmds granting +BPF_BTF_LOAD command","[' kernel proceeds to parsing BTF data and creating\nBTF object.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-6-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added BPF token support to the BPF_BTF_LOAD command for delegated BTF data loading.,"BPF token, BPF_BTF_LOAD, BTF data",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +688b7270b3cb75e8ac78123d719967db40336e5b,688b7270b3cb75e8ac78123d719967db40336e5b,Andrii Nakryiko,andrii@kernel.org,1701370336,Alexei Starovoitov,ast@kernel.org,1701885779,7b15d6aa33bc38a102899cc813bf825cbfe73f6e,4527358b76861dfd64ee34aba45d81648fbc8a61,"bpf: add BPF token support to BPF_MAP_CREATE command + +Allow providing token_fd for BPF_MAP_CREATE command to allow controlled +BPF map creation from unprivileged process through delegated BPF token. + +Wire through a set of allowed BPF map types to BPF token"," derived from +BPF FS at BPF token creation time. This","[' in combination with allowed_cmds\nallows to create a narrowly-focused BPF token (controlled by privileged\nagent) with a restrictive set of BPF maps that application can attempt\nto create.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Introduce BPF token support for controlled map creation by unprivileged processes using BPF_MAP_CREATE command.,"BPF token support, map creation, unprivileged process",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['cgroup like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4527358b76861dfd64ee34aba45d81648fbc8a61,4527358b76861dfd64ee34aba45d81648fbc8a61,Andrii Nakryiko,andrii@kernel.org,1701370335,Alexei Starovoitov,ast@kernel.org,1701885779,950b40c3026b6596139539d2d33135e742218ff6,40bba140c60fbb3ee8df6203c82fbd3de9f19d95,"bpf: introduce BPF token object + +Add new kind of BPF kernel object"," BPF token. BPF token is meant to +allow delegating privileged BPF functionality","[' like loading a BPF\nprogram or creating a BPF map', ' from privileged process to a *trusted*\nunprivileged process', ' all while having a good amount of control over which\nprivileged operations could be performed using provided BPF token.\n\nThis is achieved through mounting BPF FS instance with extra delegation\nmount options', ' which determine what operations are delegatable', ' and also\nconstraining it to the owning user namespace (as mentioned in the\nprevious patch).\n\nBPF token itself is just a derivative from BPF FS and can be created\nthrough a new bpf() syscall command', ' BPF_TOKEN_CREATE', ' which accepts BPF\nFS FD', ' which can be attained through open() API by opening BPF FS mount\npoint. Currently', ' BPF token ""inherits"" delegated command', ' map types', '\nprog type', ' and attach type bit sets from BPF FS as is. In the future', '\nhaving an BPF token as a separate object with its own FD', "" we can allow\nto further restrict BPF token's allowable set of things either at the\ncreation time or after the fact"", ' allowing the process to guard itself\nfurther from unintentionally trying to load undesired kind of BPF\nprograms. But for now we keep things simple and just copy bit sets as is.\n\nWhen BPF token is created from BPF FS mount', "" we take reference to the\nBPF super block's owning user namespace"", ' and then use that namespace for\nchecking all the {CAP_BPF', ' CAP_PERFMON', ' CAP_NET_ADMIN', ' CAP_SYS_ADMIN}\ncapabilities that are normally only checked against init userns (using\ncapable())', ' but now we check them using ns_capable() instead (if BPF\ntoken is provided). See bpf_token_capable() for details.\n\nSuch setup means that BPF token in itself is not sufficient to grant BPF\nfunctionality. User namespaced process has to *also* have necessary\ncombination of capabilities inside that user namespace. So while\npreviously CAP_BPF was useless when granted within user namespace', ' now\nit gains a meaning and allows container managers and sys admins to have\na flexible control over which processes can and need to use BPF\nfunctionality within the user namespace (i.e.', ' container in practice).\nAnd BPF FS delegation mount options and derived BPF tokens serve as\na per-container ""flag"" to grant overall ability to use bpf() (plus further\nrestrict on which parts of bpf() syscalls are treated as namespaced).\n\nNote also', ' BPF_TOKEN_CREATE command itself requires ns_capable(CAP_BPF)\nwithin the BPF FS owning user namespace', ' rounding up the ns_capable()\nstory of BPF token.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Introduce BPF token object for delegating privileged BPF functionality.,"BPF,token,delegating",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"[""It's an experimental feature that doesn't fit into existing categories.""]" +40bba140c60fbb3ee8df6203c82fbd3de9f19d95,40bba140c60fbb3ee8df6203c82fbd3de9f19d95,Andrii Nakryiko,andrii@kernel.org,1701370334,Alexei Starovoitov,ast@kernel.org,1701885778,de7e3c52bb326cc848119c90a045e016a5874080,909fa05dd3c181e5b403912889057f7cdbf3906c,"bpf: add BPF token delegation mount options to BPF FS + +Add few new mount options to BPF FS that allow to specify that a given +BPF FS instance allows creation of BPF token (added in the next patch)"," +and what sort of operations are allowed under BPF token. As such","[' we get\n4 new mount options', ' each is a bit mask\n - `delegate_cmds` allow to specify which bpf() syscall commands are\n allowed with BPF token derived from this BPF FS instance;\n - if BPF_MAP_CREATE command is allowed', ' `delegate_maps` specifies\n a set of allowable BPF map types that could be created with BPF token;\n - if BPF_PROG_LOAD command is allowed', ' `delegate_progs` specifies\n a set of allowable BPF program types that could be loaded with BPF token;\n - if BPF_PROG_LOAD command is allowed', ' `delegate_attachs` specifies\n a set of allowable BPF program attach types that could be loaded with\n BPF token; delegate_progs and delegate_attachs are meant to be used\n together', ' as full BPF program type is', ' in general', ' determined\n through both program type and program attach type.\n\nCurrently', ' these mount options accept the following forms of values:\n - a special value ""any""', ' that enables all possible values of a given\n bit set;\n - numeric value (decimal or hexadecimal', ' determined by kernel\n automatically) that specifies a bit mask value directly;\n - all the values for a given mount option are combined', ' if specified\n multiple times. E.g.', ' `mount -t bpf nodev /path/to/mount -o\n delegate_maps=0x1 -o delegate_maps=0x2` will result in a combined 0x3\n mask.\n\nIdeally', ' more convenient (for humans) symbolic form derived from\ncorresponding UAPI enums would be accepted (e.g.', ' `-o\ndelegate_progs=kprobe|tracepoint`) and I intend to implement this', ' but\nit requires a bunch of UAPI header churn', ' so I postponed it until this\nfeature lands upstream or at least there is a definite consensus that\nthis feature is acceptable and is going to make it', ' just to minimize\namount of wasted effort and not increase amount of non-essential code to\nbe reviewed.\n\nAttentive reader will notice that BPF FS is now marked as\nFS_USERNS_MOUNT', ' which theoretically makes it mountable inside non-init\nuser namespace as long as the process has sufficient *namespaced*\ncapabilities within that user namespace. But in reality we still\nrestrict BPF FS to be mountable only by processes with CAP_SYS_ADMIN *in\ninit userns* (extra check in bpf_fill_super()). FS_USERNS_MOUNT is added\nto allow creating BPF FS context object (i.e.', ' fsopen(""bpf"")) from\ninside unprivileged process inside non-init userns', ' to capture that\nuserns as the owning userns. It will still be required to pass this\ncontext object back to privileged process to instantiate and mount it.\n\nThis manipulation is important', ' because capturing non-init userns as the\nowning userns of BPF FS instance (super block) allows to use that userns\nto constraint BPF token to that userns later on (see next patch). So\ncreating BPF FS with delegation inside unprivileged userns will restrict\nderived BPF token objects to only ""work"" inside that intended userns', '\nmaking it scoped to a intended ""container"". Also', ' setting these\ndelegation options requires capable(CAP_SYS_ADMIN)', ' so unprivileged\nprocess cannot set this up without involvement of a privileged process.\n\nThere is a set of selftests at the end of the patch set that simulates\nthis sequence of steps and validates that everything works as intended.\nBut careful review is requested to make sure there are no missed gaps in\nthe implementation and testing.\n\nThis somewhat subtle set of aspects is the result of previous\ndiscussions ([0]) about various user namespace implications and\ninteractions with BPF token functionality and is necessary to contain\nBPF token inside intended user namespace.\n\n [0] https://lore.kernel.org/bpf/20230704-hochverdient-lehne-eeb9eeef785e@brauner/\n\nAcked-by: Christian Brauner \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add new mount options to BPF FS for BPF token delegation.,"BPF token, mount options, delegation",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","[""It's not related to any of the above.""]" +909fa05dd3c181e5b403912889057f7cdbf3906c,909fa05dd3c181e5b403912889057f7cdbf3906c,Andrii Nakryiko,andrii@kernel.org,1701370333,Alexei Starovoitov,ast@kernel.org,1701885778,58ce7e83ddf09f631a85dc19aa9c5703d853996c,3aee2bf9c49be2144460d7267560232e3d45d367,"bpf: align CAP_NET_ADMIN checks with bpf_capable() approach + +Within BPF syscall handling code CAP_NET_ADMIN checks stand out a bit +compared to CAP_BPF and CAP_PERFMON checks. For the latter"," CAP_BPF or +CAP_PERFMON are checked first","[' but if they are not set', ' CAP_SYS_ADMIN\ntakes over and grants whatever part of BPF syscall is required.\n\nSimilar kind of checks that involve CAP_NET_ADMIN are not so consistent.\nOne out of four uses does follow CAP_BPF/CAP_PERFMON model: during\nBPF_PROG_LOAD', ' if the type of BPF program is ""network-related"" either\nCAP_NET_ADMIN or CAP_SYS_ADMIN is required to proceed.\n\nBut in three other cases CAP_NET_ADMIN is required even if CAP_SYS_ADMIN\nis set:\n - when creating DEVMAP/XDKMAP/CPU_MAP maps;\n - when attaching CGROUP_SKB programs;\n - when handling BPF_PROG_QUERY command.\n\nThis patch is changing the latter three cases to follow BPF_PROG_LOAD\nmodel', ' that is allowing to proceed under either CAP_NET_ADMIN or\nCAP_SYS_ADMIN.\n\nThis also makes it cleaner in subsequent BPF token patches to switch\nwholesomely to a generic bpf_token_capable(int cap) check', ' that always\nfalls back to CAP_SYS_ADMIN if requested capability is missing.\n\nCc: Jakub Kicinski \nAcked-by: Yafang Shao \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231130185229.2688956-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Align CAP_NET_ADMIN checks with bpf_capable() approach in BPF syscall handling.,"CAP_NET_ADMIN,bpf_capable,BPF",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1834d62ae88500f37cba4439c3237aa85242272e,1834d62ae88500f37cba4439c3237aa85242272e,D. Wythe,alibuda@linux.alibaba.com,1701329003,Pablo Neira Ayuso,pablo@netfilter.org,1701879266,14d75d7076afade73ea6945190bc860655c2a7a0,54d4434da824460a190d547404530eff12a7907d,"netfilter: bpf: fix bad registration on nf_defrag + +We should pass a pointer to global_hook to the get_proto_defrag_hook() +instead of its value"," since the passed value won't be updated even if +the request module was loaded successfully. + +Log: + +[ 54.915713] nf_defrag_ipv4 has bad registration +[ 54.915779] WARNING: CPU: 3 PID: 6323 at net/netfilter/nf_bpf_link.c:62 get_proto_defrag_hook+0x137/0x160 +[ 54.915835] CPU: 3 PID: 6323 Comm: fentry Kdump: loaded Tainted: G E 6.7.0-rc2+ #35 +[ 54.915839] Hardware name: QEMU Standard PC (i440FX + PIIX","[' 1996)', ' BIOS rel-1.15.0-0-g2dd4b9b3f840-prebuilt.qemu.org 04/01/2014\n[ 54.915841] RIP: 0010:get_proto_defrag_hook+0x137/0x160\n[ 54.915844] Code: 4f 8c e8 2c cf 68 ff 80 3d db 83 9a 01 00 0f 85 74 ff ff ff 48 89 ee 48 c7 c7 8f 12 4f 8c c6 05 c4 83 9a 01 01 e8 09 ee 5f ff <0f> 0b e9 57 ff ff ff 49 8b 3c 24 4c 63 e5 e8 36 28 6c ff 4c 89 e0\n[ 54.915849] RSP: 0018:ffffb676003fbdb0 EFLAGS: 00010286\n[ 54.915852] RAX: 0000000000000023 RBX: ffff9596503d5600 RCX: ffff95996fce08c8\n[ 54.915854] RDX: 00000000ffffffd8 RSI: 0000000000000027 RDI: ffff95996fce08c0\n[ 54.915855] RBP: ffffffff8c4f12de R08: 0000000000000000 R09: 00000000fffeffff\n[ 54.915859] R10: ffffb676003fbc70 R11: ffffffff8d363ae8 R12: 0000000000000000\n[ 54.915861] R13: ffffffff8e1f75c0 R14: ffffb676003c9000 R15: 00007ffd15e78ef0\n[ 54.915864] FS: 00007fb6e9cab740(0000) GS:ffff95996fcc0000(0000) knlGS:0000000000000000\n[ 54.915867] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033\n[ 54.915868] CR2: 00007ffd15e75c40 CR3: 0000000101e62006 CR4: 0000000000360ef0\n[ 54.915870] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000\n[ 54.915871] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400\n[ 54.915873] Call Trace:\n[ 54.915891] \n[ 54.915894] ? __warn+0x84/0x140\n[ 54.915905] ? get_proto_defrag_hook+0x137/0x160\n[ 54.915908] ? __report_bug+0xea/0x100\n[ 54.915925] ? report_bug+0x2b/0x80\n[ 54.915928] ? handle_bug+0x3c/0x70\n[ 54.915939] ? exc_invalid_op+0x18/0x70\n[ 54.915942] ? asm_exc_invalid_op+0x1a/0x20\n[ 54.915948] ? get_proto_defrag_hook+0x137/0x160\n[ 54.915950] bpf_nf_link_attach+0x1eb/0x240\n[ 54.915953] link_create+0x173/0x290\n[ 54.915969] __sys_bpf+0x588/0x8f0\n[ 54.915974] __x64_sys_bpf+0x20/0x30\n[ 54.915977] do_syscall_64+0x45/0xf0\n[ 54.915989] entry_SYSCALL_64_after_hwframe+0x6e/0x76\n[ 54.915998] RIP: 0033:0x7fb6e9daa51d\n[ 54.916001] Code: 00 c3 66 2e 0f 1f 84 00 00 00 00 00 90 f3 0f 1e fa 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 2b 89 0c 00 f7 d8 64 89 01 48\n[ 54.916003] RSP: 002b:00007ffd15e78ed8 EFLAGS: 00000246 ORIG_RAX: 0000000000000141\n[ 54.916006] RAX: ffffffffffffffda RBX: 00007ffd15e78fc0 RCX: 00007fb6e9daa51d\n[ 54.916007] RDX: 0000000000000040 RSI: 00007ffd15e78ef0 RDI: 000000000000001c\n[ 54.916009] RBP: 000000000000002d R08: 00007fb6e9e73a60 R09: 0000000000000001\n[ 54.916010] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000006\n[ 54.916012] R13: 0000000000000006 R14: 0000000000000000 R15: 0000000000000000\n[ 54.916014] \n[ 54.916015] ---[ end trace 0000000000000000 ]---\n\nFixes: 91721c2d02d3 (""netfilter: bpf: Support BPF_F_NETFILTER_IP_DEFRAG in netfilter link"")\nSigned-off-by: D. Wythe \nAcked-by: Daniel Xu \nReviewed-by: Simon Horman \nSigned-off-by: Pablo Neira Ayuso \n', '']",Fix bad registration in nf_defrag by passing a pointer to global_hook in netfilter BPF.,"netfilter, registration, nf_defrag",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tc/netfilter like programs'] +3aee2bf9c49be2144460d7267560232e3d45d367,3aee2bf9c49be2144460d7267560232e3d45d367,Alexei Starovoitov,ast@kernel.org,1701812421,Alexei Starovoitov,ast@kernel.org,1701812494,fa3c0247846db9c119d29a1b24960c7674188d61,5ffb260f754bf838507fe0c23d05254b33e2bf3d 064e0bea19b356c5d5f48a4549d80a3c03ce898b,"Merge branch 'complete-bpf-verifier-precision-tracking-support-for-register-spills' + +Andrii Nakryiko says: + +==================== +Complete BPF verifier precision tracking support for register spills + +Add support to BPF verifier to track and support register spill/fill to/from +stack regardless if it was done through read-only R10 register (which is the +only form supported today)"," or through a general register after copying R10 +into it","[' while also potentially modifying offset.\n\nOnce we add register this generic spill/fill support to precision\nbacktracking', ' we can take advantage of it to stop doing eager STACK_ZERO\nconversion on register spill. Instead we can rely on (im)precision of spilled\nconst zero register to improve verifier state pruning efficiency. This\nsituation of using const zero register to initialize stack slots is very\ncommon with __builtin_memset() usage or just zero-initializing variables on\nthe stack', ' and it causes unnecessary state duplication', ' as that STACK_ZERO\nknowledge is often not necessary for correctness', ' as those zero values are\nnever used in precise context. Thus', ' relying on register imprecision helps\ntremendously', ' especially in real-world BPF programs.\n\nTo make spilled const zero register behave completely equivalently to\nSTACK_ZERO', ' we need to improve few other small pieces', ' which is done in the\nsecond part of the patch set. See individual patches for details. There are\nalso two small bug fixes spotted during STACK_ZERO debugging.\n\nThe patch set consists of logically three changes:\n - patch #1 (and corresponding tests in patch #2) is fixing/impoving precision\n propagation for stack spills/fills. This can be landed as a stand-alone\n improvement;\n - patches #3 through #9 is improving verification scalability by utilizing\n register (im)precision instead of eager STACK_ZERO. These changes depend\n on patch #1.\n - patch #10 is a memory efficiency improvement to how instruction/jump\n history is tracked and maintained. It depends on patch #1', ' but is not\n strictly speaking required', "" even though I believe it's a good long-term\n solution to have a path-dependent per-instruction information. Kind\n of like a path-dependent counterpart to path-agnostic insn_aux array.\n\nv3->v3:\n - fixed up Fixes tag (Alexei);\n - fixed few more selftests to not use BPF_ST instruction in inline asm\n directly"", ' checked with CI', ' it was happy (CI);\nv2->v3:\n - BPF_ST instruction workaround (Eduard);\n - force dereference in added tests to catch problems (Eduard);\n - some commit message massaging (Alexei);\nv1->v2:\n - clean ups', ' WARN_ONCE()', ' insn_flags helpers added (Eduard);\n - added more selftests for STACK_ZERO/STACK_MISC cases (Eduard);\n - a bit more detailed explanation of effect of avoiding STACK_ZERO in favor\n of register spill in patch #8 commit (Alexei);\n - global shared instruction history refactoring moved to be the last patch\n in the series to make it easier to revert it', ' if applied (Alexei).\n====================\n\nLink: https://lore.kernel.org/r/20231205184248.1502704-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhances BPF verifier with precision tracking for register spills and fills to/from stack.,"verifier, precision, register",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +064e0bea19b356c5d5f48a4549d80a3c03ce898b,064e0bea19b356c5d5f48a4549d80a3c03ce898b,Andrii Nakryiko,andrii@kernel.org,1701801767,Alexei Starovoitov,ast@kernel.org,1701812421,fa3c0247846db9c119d29a1b24960c7674188d61,18a433b62061e3d787bfc3e670fa711fecbd7cb4,"selftests/bpf: validate precision logic in partial_stack_load_preserves_zeros + +Enhance partial_stack_load_preserves_zeros subtest with detailed +precision propagation log checks. We know expect fp-16 to be spilled"," +initially imprecise","[' zero const register', ' which is later marked as\nprecise even when partial stack slot load is performed', "" even if it's not\na register fill (!).\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231205184248.1502704-10-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",Enhance BPF self-tests with precision propagation checks for partial stack load operations.,"selftests, precision, stack",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +18a433b62061e3d787bfc3e670fa711fecbd7cb4,18a433b62061e3d787bfc3e670fa711fecbd7cb4,Andrii Nakryiko,andrii@kernel.org,1701801766,Alexei Starovoitov,ast@kernel.org,1701812421,fd87e3195e34d3a935f659293ddc44e32b85c10f,add1cd7f22e61756987865ada9fe95cd86569025,"bpf: track aligned STACK_ZERO cases as imprecise spilled registers + +Now that precision backtracing is supporting register spill/fill to/from +stack"," there is another oportunity to be exploited here: minimizing +precise STACK_ZERO cases. With a simple code change we can rely on +initially imprecise register spill tracking for cases when register +spilled to stack was a known zero. + +This is a very common case for initializing on the stack variables","['\nincluding rather large structures. Often times zero has no special\nmeaning for the subsequent BPF program logic and is often overwritten\nwith non-zero values soon afterwards. But due to STACK_ZERO vs\nSTACK_MISC tracking', ' such initial zero initialization actually causes\nduplication of verifier states as STACK_ZERO is clearly different than\nSTACK_MISC or spilled SCALAR_VALUE register.\n\nThe effect of this (now) trivial change is huge', ' as can be seen below.\nThese are differences between BPF selftests', ' Cilium', ' and Meta-internal\nBPF object files relative to previous patch in this series. You can see\nimprovements ranging from single-digit percentage improvement for\ninstructions and states', ' all the way to 50-60% reduction for some of\nMeta-internal host agent programs', ' and even some Cilium programs.\n\nFor Meta-internal ones I left only the differences for largest BPF\nobject files by states/instructions', ' as there were too many differences\nin the overall output. All the differences were improvements', ' reducting\nnumber of states and thus instructions validated.\n\nNote', ' Meta-internal BPF object file names are not printed below.\nMany copies of balancer_ingress are actually many different\nconfigurations of Katran', ' so they are different BPF programs', ' which\nexplains state reduction going from -16% all the way to 31%', "" depending\non BPF program logic complexity.\n\nI also tooked a closer look at a few small-ish BPF programs to validate\nthe behavior. Let's take bpf_iter_netrlink.bpf.o (first row below).\nWhile it's just 8 vs 5 states"", ' verifier log is still pretty long to\ninclude it here. But the reduction in states is due to the following\npiece of C code:\n\n unsigned long ino;\n\n\t...\n\n sk = s->sk_socket;\n if (!sk) {\n ino = 0;\n } else {\n inode = SOCK_INODE(sk);\n bpf_probe_read_kernel(&ino', ' sizeof(ino)', ' &inode->i_ino);\n }\n BPF_SEQ_PRINTF(seq', ' ""%-8u %-8lu\\n""', ' s->sk_drops.counter', ' ino);\n\treturn 0;\n\nYou can see that in some situations `ino` is zero-initialized', "" while in\nothers it's unknown value filled out by bpf_probe_read_kernel(). Before\nthis change code after if/else branches have to be validated twice. Once\nwith (precise) ino == 0"", ' due to eager STACK_ZERO logic', "" and then again\nfor when ino is just STACK_MISC. But BPF_SEQ_PRINTF() doesn't care about\nprecise value of ino"", ' so with the change in this patch verifier is able\nto prune states from after one of the branches', ' reducing number of total\nstates (and instructions) required for successful validation.\n\nSimilar principle applies to bigger real-world applications', ' just at\na much larger scale.\n\nSELFTESTS\n=========\nFile Program Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n--------------------------------------- ----------------------- --------- --------- --------------- ---------- ---------- -------------\nbpf_iter_netlink.bpf.linked3.o dump_netlink 148 104 -44 (-29.73%) 8 5 -3 (-37.50%)\nbpf_iter_unix.bpf.linked3.o dump_unix 8474 8404 -70 (-0.83%) 151 147 -4 (-2.65%)\nbpf_loop.bpf.linked3.o stack_check 560 324 -236 (-42.14%) 42 24 -18 (-42.86%)\nlocal_storage_bench.bpf.linked3.o get_local 120 77 -43 (-35.83%) 9 6 -3 (-33.33%)\nloop6.bpf.linked3.o trace_virtqueue_add_sgs 10167 9868 -299 (-2.94%) 226 206 -20 (-8.85%)\npyperf600_bpf_loop.bpf.linked3.o on_event 4872 3423 -1449 (-29.74%) 322 229 -93 (-28.88%)\nstrobemeta.bpf.linked3.o on_event 180697 176036 -4661 (-2.58%) 4780 4734 -46 (-0.96%)\ntest_cls_redirect.bpf.linked3.o cls_redirect 65594 65401 -193 (-0.29%) 4230 4212 -18 (-0.43%)\ntest_global_func_args.bpf.linked3.o test_cls 145 136 -9 (-6.21%) 10 9 -1 (-10.00%)\ntest_l4lb.bpf.linked3.o balancer_ingress 4760 2612 -2148 (-45.13%) 113 102 -11 (-9.73%)\ntest_l4lb_noinline.bpf.linked3.o balancer_ingress 4845 4877 +32 (+0.66%) 219 221 +2 (+0.91%)\ntest_l4lb_noinline_dynptr.bpf.linked3.o balancer_ingress 2072 2087 +15 (+0.72%) 97 98 +1 (+1.03%)\ntest_seg6_loop.bpf.linked3.o __add_egr_x 12440 9975 -2465 (-19.82%) 364 353 -11 (-3.02%)\ntest_tcp_hdr_options.bpf.linked3.o estab 2558 2572 +14 (+0.55%) 179 180 +1 (+0.56%)\ntest_xdp_dynptr.bpf.linked3.o _xdp_tx_iptunnel 645 596 -49 (-7.60%) 26 24 -2 (-7.69%)\ntest_xdp_noinline.bpf.linked3.o balancer_ingress_v6 3520 3516 -4 (-0.11%) 216 216 +0 (+0.00%)\nxdp_synproxy_kern.bpf.linked3.o syncookie_tc 82661 81241 -1420 (-1.72%) 5073 5155 +82 (+1.62%)\nxdp_synproxy_kern.bpf.linked3.o syncookie_xdp 84964 82297 -2667 (-3.14%) 5130 5157 +27 (+0.53%)\n\nMETA-INTERNAL\n=============\nProgram Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n-------------------------------------- --------- --------- ----------------- ---------- ---------- ---------------\nbalancer_ingress 27925 23608 -4317 (-15.46%) 1488 1482 -6 (-0.40%)\nbalancer_ingress 31824 27546 -4278 (-13.44%) 1658 1652 -6 (-0.36%)\nbalancer_ingress 32213 27935 -4278 (-13.28%) 1689 1683 -6 (-0.36%)\nbalancer_ingress 32213 27935 -4278 (-13.28%) 1689 1683 -6 (-0.36%)\nbalancer_ingress 31824 27546 -4278 (-13.44%) 1658 1652 -6 (-0.36%)\nbalancer_ingress 38647 29562 -9085 (-23.51%) 2069 1835 -234 (-11.31%)\nbalancer_ingress 38647 29562 -9085 (-23.51%) 2069 1835 -234 (-11.31%)\nbalancer_ingress 40339 30792 -9547 (-23.67%) 2193 1934 -259 (-11.81%)\nbalancer_ingress 37321 29055 -8266 (-22.15%) 1972 1795 -177 (-8.98%)\nbalancer_ingress 38176 29753 -8423 (-22.06%) 2008 1831 -177 (-8.81%)\nbalancer_ingress 29193 20910 -8283 (-28.37%) 1599 1422 -177 (-11.07%)\nbalancer_ingress 30013 21452 -8561 (-28.52%) 1645 1447 -198 (-12.04%)\nbalancer_ingress 28691 24290 -4401 (-15.34%) 1545 1531 -14 (-0.91%)\nbalancer_ingress 34223 28965 -5258 (-15.36%) 1984 1875 -109 (-5.49%)\nbalancer_ingress 35481 26158 -9323 (-26.28%) 2095 1806 -289 (-13.79%)\nbalancer_ingress 35481 26158 -9323 (-26.28%) 2095 1806 -289 (-13.79%)\nbalancer_ingress 35868 26455 -9413 (-26.24%) 2140 1827 -313 (-14.63%)\nbalancer_ingress 35868 26455 -9413 (-26.24%) 2140 1827 -313 (-14.63%)\nbalancer_ingress 35481 26158 -9323 (-26.28%) 2095 1806 -289 (-13.79%)\nbalancer_ingress 35481 26158 -9323 (-26.28%) 2095 1806 -289 (-13.79%)\nbalancer_ingress 34844 29485 -5359 (-15.38%) 2036 1918 -118 (-5.80%)\nfbflow_egress 3256 2652 -604 (-18.55%) 218 192 -26 (-11.93%)\nfbflow_ingress 1026 944 -82 (-7.99%) 70 63 -7 (-10.00%)\nsslwall_tc_egress 8424 7360 -1064 (-12.63%) 498 458 -40 (-8.03%)\nsyar_accept_protect 15040 9539 -5501 (-36.58%) 364 220 -144 (-39.56%)\nsyar_connect_tcp_v6 15036 9535 -5501 (-36.59%) 360 216 -144 (-40.00%)\nsyar_connect_udp_v4 15039 9538 -5501 (-36.58%) 361 217 -144 (-39.89%)\nsyar_connect_connect4_protect4 24805 15833 -8972 (-36.17%) 756 480 -276 (-36.51%)\nsyar_lsm_file_open 167772 151813 -15959 (-9.51%) 1836 1667 -169 (-9.20%)\nsyar_namespace_create_new 14805 9304 -5501 (-37.16%) 353 209 -144 (-40.79%)\nsyar_python3_detect 17531 12030 -5501 (-31.38%) 391 247 -144 (-36.83%)\nsyar_ssh_post_fork 16412 10911 -5501 (-33.52%) 405 261 -144 (-35.56%)\nsyar_enter_execve 14728 9227 -5501 (-37.35%) 345 201 -144 (-41.74%)\nsyar_enter_execveat 14728 9227 -5501 (-37.35%) 345 201 -144 (-41.74%)\nsyar_exit_execve 16622 11121 -5501 (-33.09%) 376 232 -144 (-38.30%)\nsyar_exit_execveat 16622 11121 -5501 (-33.09%) 376 232 -144 (-38.30%)\nsyar_syscalls_kill 15288 9787 -5501 (-35.98%) 398 254 -144 (-36.18%)\nsyar_task_enter_pivot_root 14898 9397 -5501 (-36.92%) 357 213 -144 (-40.34%)\nsyar_syscalls_setreuid 16678 11177 -5501 (-32.98%) 429 285 -144 (-33.57%)\nsyar_syscalls_setuid 16678 11177 -5501 (-32.98%) 429 285 -144 (-33.57%)\nsyar_syscalls_process_vm_readv 14959 9458 -5501 (-36.77%) 364 220 -144 (-39.56%)\nsyar_syscalls_process_vm_writev 15757 10256 -5501 (-34.91%) 390 246 -144 (-36.92%)\ndo_uprobe 15519 10018 -5501 (-35.45%) 373 229 -144 (-38.61%)\nedgewall 179715 55783 -123932 (-68.96%) 12607 3999 -8608 (-68.28%)\nbictcp_state 7570 4131 -3439 (-45.43%) 496 269 -227 (-45.77%)\ncubictcp_state 7570 4131 -3439 (-45.43%) 496 269 -227 (-45.77%)\ntcp_rate_skb_delivered 447 272 -175 (-39.15%) 29 18 -11 (-37.93%)\nkprobe__bbr_set_state 4566 2615 -1951 (-42.73%) 209 124 -85 (-40.67%)\nkprobe__bictcp_state 4566 2615 -1951 (-42.73%) 209 124 -85 (-40.67%)\ninet_sock_set_state 1501 1337 -164 (-10.93%) 93 85 -8 (-8.60%)\ntcp_retransmit_skb 1145 981 -164 (-14.32%) 67 59 -8 (-11.94%)\ntcp_retransmit_synack 1183 951 -232 (-19.61%) 67 55 -12 (-17.91%)\nbpf_tcptuner 1459 1187 -272 (-18.64%) 99 80 -19 (-19.19%)\ntw_egress 801 776 -25 (-3.12%) 69 66 -3 (-4.35%)\ntw_ingress 795 770 -25 (-3.14%) 69 66 -3 (-4.35%)\nttls_tc_ingress 19025 19383 +358 (+1.88%) 470 465 -5 (-1.06%)\nttls_nat_egress 490 299 -191 (-38.98%) 33 20 -13 (-39.39%)\nttls_nat_ingress 448 285 -163 (-36.38%) 32 21 -11 (-34.38%)\ntw_twfw_egress 511127 212071 -299056 (-58.51%) 16733 8504 -8229 (-49.18%)\ntw_twfw_ingress 500095 212069 -288026 (-57.59%) 16223 8504 -7719 (-47.58%)\ntw_twfw_tc_eg 511113 212064 -299049 (-58.51%) 16732 8504 -8228 (-49.18%)\ntw_twfw_tc_in 500095 212069 -288026 (-57.59%) 16223 8504 -7719 (-47.58%)\ntw_twfw_egress 12632 12435 -197 (-1.56%) 276 260 -16 (-5.80%)\ntw_twfw_ingress 12631 12454 -177 (-1.40%) 278 261 -17 (-6.12%)\ntw_twfw_tc_eg 12595 12435 -160 (-1.27%) 274 259 -15 (-5.47%)\ntw_twfw_tc_in 12631 12454 -177 (-1.40%) 278 261 -17 (-6.12%)\ntw_xdp_dump 266 209 -57 (-21.43%) 9 8 -1 (-11.11%)\n\nCILIUM\n=========\nFile Program Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n------------- -------------------------------- --------- --------- ---------------- ---------- ---------- --------------\nbpf_host.o cil_to_netdev 6047 4578 -1469 (-24.29%) 362 249 -113 (-31.22%)\nbpf_host.o handle_lxc_traffic 2227 1585 -642 (-28.83%) 156 103 -53 (-33.97%)\nbpf_host.o tail_handle_ipv4_from_netdev 2244 1458 -786 (-35.03%) 163 106 -57 (-34.97%)\nbpf_host.o tail_handle_nat_fwd_ipv4 21022 10479 -10543 (-50.15%) 1289 670 -619 (-48.02%)\nbpf_host.o tail_handle_nat_fwd_ipv6 15433 11375 -4058 (-26.29%) 905 643 -262 (-28.95%)\nbpf_host.o tail_ipv4_host_policy_ingress 2219 1367 -852 (-38.40%) 161 96 -65 (-40.37%)\nbpf_host.o tail_nodeport_nat_egress_ipv4 22460 19862 -2598 (-11.57%) 1469 1293 -176 (-11.98%)\nbpf_host.o tail_nodeport_nat_ingress_ipv4 5526 3534 -1992 (-36.05%) 366 243 -123 (-33.61%)\nbpf_host.o tail_nodeport_nat_ingress_ipv6 5132 4256 -876 (-17.07%) 241 219 -22 (-9.13%)\nbpf_host.o tail_nodeport_nat_ipv6_egress 3702 3542 -160 (-4.32%) 215 205 -10 (-4.65%)\nbpf_lxc.o tail_handle_nat_fwd_ipv4 21022 10479 -10543 (-50.15%) 1289 670 -619 (-48.02%)\nbpf_lxc.o tail_handle_nat_fwd_ipv6 15433 11375 -4058 (-26.29%) 905 643 -262 (-28.95%)\nbpf_lxc.o tail_ipv4_ct_egress 5073 3374 -1699 (-33.49%) 262 172 -90 (-34.35%)\nbpf_lxc.o tail_ipv4_ct_ingress 5093 3385 -1708 (-33.54%) 262 172 -90 (-34.35%)\nbpf_lxc.o tail_ipv4_ct_ingress_policy_only 5093 3385 -1708 (-33.54%) 262 172 -90 (-34.35%)\nbpf_lxc.o tail_ipv6_ct_egress 4593 3878 -715 (-15.57%) 194 151 -43 (-22.16%)\nbpf_lxc.o tail_ipv6_ct_ingress 4606 3891 -715 (-15.52%) 194 151 -43 (-22.16%)\nbpf_lxc.o tail_ipv6_ct_ingress_policy_only 4606 3891 -715 (-15.52%) 194 151 -43 (-22.16%)\nbpf_lxc.o tail_nodeport_nat_ingress_ipv4 5526 3534 -1992 (-36.05%) 366 243 -123 (-33.61%)\nbpf_lxc.o tail_nodeport_nat_ingress_ipv6 5132 4256 -876 (-17.07%) 241 219 -22 (-9.13%)\nbpf_overlay.o tail_handle_nat_fwd_ipv4 20524 10114 -10410 (-50.72%) 1271 638 -633 (-49.80%)\nbpf_overlay.o tail_nodeport_nat_egress_ipv4 22718 19490 -3228 (-14.21%) 1475 1275 -200 (-13.56%)\nbpf_overlay.o tail_nodeport_nat_ingress_ipv4 5526 3534 -1992 (-36.05%) 366 243 -123 (-33.61%)\nbpf_overlay.o tail_nodeport_nat_ingress_ipv6 5132 4256 -876 (-17.07%) 241 219 -22 (-9.13%)\nbpf_overlay.o tail_nodeport_nat_ipv6_egress 3638 3548 -90 (-2.47%) 209 203 -6 (-2.87%)\nbpf_overlay.o tail_rev_nodeport_lb4 4368 3820 -548 (-12.55%) 248 215 -33 (-13.31%)\nbpf_overlay.o tail_rev_nodeport_lb6 2867 2428 -439 (-15.31%) 167 140 -27 (-16.17%)\nbpf_sock.o cil_sock6_connect 1718 1703 -15 (-0.87%) 100 99 -1 (-1.00%)\nbpf_xdp.o tail_handle_nat_fwd_ipv4 12917 12443 -474 (-3.67%) 875 849 -26 (-2.97%)\nbpf_xdp.o tail_handle_nat_fwd_ipv6 13515 13264 -251 (-1.86%) 715 702 -13 (-1.82%)\nbpf_xdp.o tail_lb_ipv4 39492 36367 -3125 (-7.91%) 2430 2251 -179 (-7.37%)\nbpf_xdp.o tail_lb_ipv6 80441 78058 -2383 (-2.96%) 3647 3523 -124 (-3.40%)\nbpf_xdp.o tail_nodeport_ipv6_dsr 1038 901 -137 (-13.20%) 61 55 -6 (-9.84%)\nbpf_xdp.o tail_nodeport_nat_egress_ipv4 13027 12096 -931 (-7.15%) 868 809 -59 (-6.80%)\nbpf_xdp.o tail_nodeport_nat_ingress_ipv4 7617 5900 -1717 (-22.54%) 522 413 -109 (-20.88%)\nbpf_xdp.o tail_nodeport_nat_ingress_ipv6 7575 7395 -180 (-2.38%) 383 374 -9 (-2.35%)\nbpf_xdp.o tail_rev_nodeport_lb4 6808 6739 -69 (-1.01%) 403 396 -7 (-1.74%)\nbpf_xdp.o tail_rev_nodeport_lb6 16173 15847 -326 (-2.02%) 1010 990 -20 (-1.98%)\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231205184248.1502704-9-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit enhances register spill tracking for STACK_ZERO cases as imprecise spilled registers in eBPF.,"aligned, STACK_ZERO, registers",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +add1cd7f22e61756987865ada9fe95cd86569025,add1cd7f22e61756987865ada9fe95cd86569025,Andrii Nakryiko,andrii@kernel.org,1701801765,Alexei Starovoitov,ast@kernel.org,1701812421,4a3a28c109d0c6d293cead323e1b26c883ee70bf,e322f0bcb8d371f4606eaf141c7f967e1a79bcb7,"selftests/bpf: validate zero preservation for sub-slot loads + +Validate that 1-", 2-,"[' and 4-byte loads from stack slots not aligned on\n8-byte boundary still preserve zero', ' when loading from all-STACK_ZERO\nsub-slots', ' or when stack sub-slots are covered by spilled register with\nknown constant zero value.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231205184248.1502704-8-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftests for validating zero preservation for sub-slot loads in eBPF.,"selftests,zero preservation,sub-slot loads",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e322f0bcb8d371f4606eaf141c7f967e1a79bcb7,e322f0bcb8d371f4606eaf141c7f967e1a79bcb7,Andrii Nakryiko,andrii@kernel.org,1701801764,Alexei Starovoitov,ast@kernel.org,1701812421,465b4dead3816fce4a5b27dafd7f566fb5b75da4,b33ceb6a3d2ee07fdd836373383a6d4783581324,"bpf: preserve constant zero when doing partial register restore + +Similar to special handling of STACK_ZERO"," when reading 1/2/4 bytes from +stack from slot that has register spilled into it and that register has +a constant value zero","[' preserve that zero and mark spilled register as\nprecise for that. This makes spilled const zero register and STACK_ZERO\ncases equivalent in their behavior.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231205184248.1502704-7-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit ensures that constant zero values are maintained during partial register restorations in the eBPF verifier.,"constant, register, restore",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b33ceb6a3d2ee07fdd836373383a6d4783581324,b33ceb6a3d2ee07fdd836373383a6d4783581324,Andrii Nakryiko,andrii@kernel.org,1701801763,Alexei Starovoitov,ast@kernel.org,1701812420,6a50eb07c53d941a7aa676db95e91721f883d839,eaf18febd6ebc381aeb61543705148b3e28c7c47,"selftests/bpf: validate STACK_ZERO is preserved on subreg spill + +Add tests validating that STACK_ZERO slots are preserved when slot is +partially overwritten with subregister spill. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231205184248.1502704-6-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Added tests to validate STACK_ZERO preservation on subregister spill in bpf selftests.,"STACK_ZERO, subregister, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +eaf18febd6ebc381aeb61543705148b3e28c7c47,eaf18febd6ebc381aeb61543705148b3e28c7c47,Andrii Nakryiko,andrii@kernel.org,1701801762,Alexei Starovoitov,ast@kernel.org,1701812420,b3f296260d280b9473b456c33da8c9f0af649fd2,ab125ed3ec1c10ccc36bc98c7a4256ad114a3dae,"bpf: preserve STACK_ZERO slots on partial reg spills + +Instead of always forcing STACK_ZERO slots to STACK_MISC"," preserve it in +situations where this is possible. E.g.","[' when spilling register as\n1/2/4-byte subslots on the stack', ' all the remaining bytes in the stack\nslot do not automatically become unknown. If we knew they contained\nzeroes', ' we can preserve those STACK_ZERO markers.\n\nAdd a helper mark_stack_slot_misc()', ' similar to scrub_spilled_slot()', ""\nbut that doesn't overwrite either STACK_INVALID nor STACK_ZERO. Note\nthat we need to take into account possibility of being in unprivileged\nmode"", ' in which case STACK_INVALID is forced to STACK_MISC for correctness', '\nas treating STACK_INVALID as equivalent STACK_MISC is only enabled in\nprivileged mode.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231205184248.1502704-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit preserves STACK_ZERO slots during partial register spills in the eBPF verifier.,"STACK_ZERO,register spills,verifier",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ab125ed3ec1c10ccc36bc98c7a4256ad114a3dae,ab125ed3ec1c10ccc36bc98c7a4256ad114a3dae,Andrii Nakryiko,andrii@kernel.org,1701801761,Alexei Starovoitov,ast@kernel.org,1701812420,0c4185c31afa6f73b9a5f0ef6b9f9c9621cc662c,876301881c436bf38e83a2c0d276a24b642e4aab,"bpf: fix check for attempt to corrupt spilled pointer + +When register is spilled onto a stack as a 1/2/4-byte register"," we set +slot_type[BPF_REG_SIZE - 1] (plus potentially few more below it","['\ndepending on actual spill size). So to check if some stack slot has\nspilled register we need to consult slot_type[7]', ' not slot_type[0].\n\nTo avoid the need to remember and double-check this in the future', ' just\nuse is_spilled_reg() helper.\n\nFixes: 27113c59b6d0 (""bpf: Check the other end of slot_type for STACK_SPILL"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231205184248.1502704-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes a check for attempts to corrupt spilled pointers in the eBPF verifier.,"fix,corrupt,pointer",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +876301881c436bf38e83a2c0d276a24b642e4aab,876301881c436bf38e83a2c0d276a24b642e4aab,Andrii Nakryiko,andrii@kernel.org,1701801760,Alexei Starovoitov,ast@kernel.org,1701812420,dcac49d7f85b37e4f999fd1d3cf382036eaf565d,41f6f64e6999a837048b1bd13a2f8742964eca6b,"selftests/bpf: add stack access precision test + +Add a new selftests that validates precision tracking for stack access +instruction"," using both r10-based and non-r10-based accesses. For +non-r10 ones we also make sure to have non-zero var_off to validate that +final stack offset is tracked properly in instruction history +information inside verifier. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231205184248.1502704-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add a selftest to validate precision tracking for stack access instructions in bpf verifier.,"selftest, stack access, precision",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +41f6f64e6999a837048b1bd13a2f8742964eca6b,41f6f64e6999a837048b1bd13a2f8742964eca6b,Andrii Nakryiko,andrii@kernel.org,1701801759,Alexei Starovoitov,ast@kernel.org,1701812420,b0ec4c4bfd2ae8fc83461d3d92e3292bd265f068,5ffb260f754bf838507fe0c23d05254b33e2bf3d,"bpf: support non-r10 register spill/fill to/from stack in precision tracking + +Use instruction (jump) history to record instructions that performed +register spill/fill to/from stack"," regardless if this was done through +read-only r10 register","[' or any other register after copying r10 into it\n*and* potentially adjusting offset.\n\nTo make this work reliably', ' we push extra per-instruction flags into\ninstruction history', "" encoding stack slot index (spi) and stack frame\nnumber in extra 10 bit flags we take away from prev_idx in instruction\nhistory. We don't touch idx field for maximum performance"", "" as it's\nchecked most frequently during backtracking.\n\nThis change removes basically the last remaining practical limitation of\nprecision backtracking logic in BPF verifier. It fixes known\ndeficiencies"", ' but also opens up new opportunities to reduce number of\nverified states', "" explored in the subsequent patches.\n\nThere are only three differences in selftests' BPF object files\naccording to veristat"", ' all in the positive direction (less states).\n\nFile Program Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n-------------------------------------- ------------- --------- --------- ------------- ---------- ---------- -------------\ntest_cls_redirect_dynptr.bpf.linked3.o cls_redirect 2987 2864 -123 (-4.12%) 240 231 -9 (-3.75%)\nxdp_synproxy_kern.bpf.linked3.o syncookie_tc 82848 82661 -187 (-0.23%) 5107 5073 -34 (-0.67%)\nxdp_synproxy_kern.bpf.linked3.o syncookie_xdp 85116 84964 -152 (-0.18%) 5162 5130 -32 (-0.62%)\n\nNote', "" I avoided renaming jmp_history to more generic insn_hist to\nminimize number of lines changed and potential merge conflicts between\nbpf and bpf-next trees.\n\nNotice also cur_hist_entry pointer reset to NULL at the beginning of\ninstruction verification loop. This pointer avoids the problem of\nrelying on last jump history entry's insn_idx to determine whether we\nalready have entry for current instruction or not. It can happen that we\nadded jump history entry because current instruction is_jmp_point()"", ' but\nalso we need to add instruction flags for stack access. In this case', "" we\ndon't want to entries"", ' so we need to reuse last added entry', ' if it is\npresent.\n\nRelying on insn_idx comparison has the same ambiguity problem as the one\nthat was fixed recently in [0]', ' so we avoid that.\n\n [0] https://patchwork.kernel.org/project/netdevbpf/patch/20231110002638.4168352-3-andrii@kernel.org/\n\nAcked-by: Eduard Zingerman \nReported-by: Tao Lyu \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231205184248.1502704-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add support for non-r10 register spill/fill in precision tracking for bpf.,"register, spill, precision",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5ffb260f754bf838507fe0c23d05254b33e2bf3d,5ffb260f754bf838507fe0c23d05254b33e2bf3d,Stanislav Fomichev,sdf@google.com,1701711863,Daniel Borkmann,daniel@iogearbox.net,1701785484,7f8ad0d113c75357f2f759c58aec83cbf185be84,5c399ae080ae507954f6f2efefc7349f8ed0e051,"selftests/bpf: Make sure we trigger metadata kfuncs for dst 8080 + +xdp_metadata test is flaky sometimes: + + verify_xsk_metadata:FAIL:rx_hash_type unexpected rx_hash_type: actual 8 != expected 0 + +Where 8 means XDP_RSS_TYPE_L4_ANY and is exported from veth driver only when +'skb->l4_hash' condition is met. This makes me think that the program is +triggering again for some other packet. + +Let's have a filter", similar to xdp_hw_metadata,"[' where we trigger XDP kfuncs\nonly for UDP packets destined to port 8080.\n\nSigned-off-by: Stanislav Fomichev \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20231204174423.3460052-1-sdf@google.com\n', '']",Fix flaky xdp_metadata test by ensuring kfuncs are triggered for destination port 8080.,"xdp_metadata,test,kfuncs",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['xdp like programs'] +5c399ae080ae507954f6f2efefc7349f8ed0e051,5c399ae080ae507954f6f2efefc7349f8ed0e051,Stanislav Fomichev,sdf@google.com,1701711751,Daniel Borkmann,daniel@iogearbox.net,1701785330,ef36fb602f7598747f4825cc2aa60218614912fa,1b4c7e20bfd6cfe0efbc51756d930a9406d41ea7,"xsk: Add missing SPDX to AF_XDP TX metadata documentation + +Not sure how I missed that. I even acknowledged it explicitly +in the changelog [0]. Add the tag for real now. + + [0] https://lore.kernel.org/bpf/20231127190319.1190813-1-sdf@google.com/ + +Fixes: 11614723af26 (""xsk: Add option to calculate TX checksum in SW"") +Suggested-by: Simon Horman +Signed-off-by: Stanislav Fomichev +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231204174231.3457705-1-sdf@google.com +",,Added missing SPDX license tag to AF_XDP TX metadata documentation.,"SPDX, AF_XDP, documentation",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['socket like programs'] +1b4c7e20bfd6cfe0efbc51756d930a9406d41ea7,1b4c7e20bfd6cfe0efbc51756d930a9406d41ea7,Dave Marchevsky,davemarchevsky@fb.com,1701724642,Daniel Borkmann,daniel@iogearbox.net,1701785207,039941b0e3e680eb0957a1cc32f62f43012a19bd,ce3c49da11d77aa7d53cd549d308eb5f7fed8576,"selftests/bpf: Test bpf_kptr_xchg stashing of bpf_rb_root + +There was some confusion amongst Meta sched_ext folks regarding whether +stashing bpf_rb_root - the tree itself"," rather than a single node - was +supported. This patch adds a small test which demonstrates this +functionality: a local kptr with rb_root is created","[' a node is created\nand added to the tree', "" then the tree is kptr_xchg'd into a mapval.\n\nSigned-off-by: Dave Marchevsky \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/bpf/20231204211722.571346-1-davemarchevsky@fb.com\n"", '']",The commit adds a test for stashing bpf_rb_root in bpf_kptr_xchg.,"bpf_rb_root,test,stashing",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e4d008d49a7135214e0ee70537405b6a069e3a3f,e4d008d49a7135214e0ee70537405b6a069e3a3f,Yewon Choi,woni9911@gmail.com,1701411052,Daniel Borkmann,daniel@iogearbox.net,1701780223,49a625866ba1bff1b71d541004e9045816a92b6c,dfce9cb3140592b886838e06f3e0c25fea2a9cae,"xsk: Skip polling event check for unbound socket + +In xsk_poll()"," checking available events and setting mask bits should +be executed only when a socket has been bound. Setting mask bits for +unbound socket is meaningless. + +Currently","[' it checks events even when xsk_check_common() failed.\nTo prevent this', ' we move goto location (skip_tx) after that checking.\n\nFixes: 1596dae2f17e (""xsk: check IFF_UP earlier in Tx path"")\nSigned-off-by: Yewon Choi \nSigned-off-by: Daniel Borkmann \nAcked-by: Magnus Karlsson \nLink: https://lore.kernel.org/bpf/20231201061048.GA1510@libra05\n', '']",The commit optimizes xsk_poll by skipping polling for unbound sockets.,"xsk, polling, sockets",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['socket like programs'] +a931c6816078af3e306e0f444f492396ce40de31,a931c6816078af3e306e0f444f492396ce40de31,JP Kobryn,inwardvessel@gmail.com,1701721400,Dominique Martinet,asmadeus@codewreck.org,1701778724,3a79667cd35a6f8f8ea58331c648c835034f4440,2cc14f52aeb78ce3f29677c2de1f06c0e91471ab,"9p: prevent read overrun in protocol dump tracepoint + +An out of bounds read can occur within the tracepoint 9p_protocol_dump. In +the fast assign"," there is a memcpy that uses a constant size of 32 (macro +named P9_PROTO_DUMP_SZ). When the copy is invoked","[' the source buffer is not\nguaranteed match this size. It was found that in some cases the source\nbuffer size is less than 32', ' resulting in a read that overruns.\n\nThe size of the source buffer seems to be known at the time of the\ntracepoint being invoked. The allocations happen within p9_fcall_init()', '\nwhere the capacity field is set to the allocated size of the payload\nbuffer. This patch tries to fix the overrun by changing the fixed array to\na dynamically sized array and using the minimum of the capacity value or\nP9_PROTO_DUMP_SZ as its length. The trace log statement is adjusted to\naccount for this. Note that the trace log no longer splits the payload on\nthe first 16 bytes. The full payload is now logged to a single line.\n\nTo repro the orignal problem', ' operations to a plan 9 managed resource can\nbe used. The simplest approach might just be mounting a shared filesystem\n(between host and guest vm) using the plan 9 protocol while the tracepoint\nis enabled.\n\nmount -t 9p -o trans=virtio \n\nThe bpftrace program below can be used to show the out of bounds read.\nNote that a recent version of bpftrace is needed for the raw tracepoint\nsupport. The script was tested using v0.19.0.\n\n/* from include/net/9p/9p.h */\nstruct p9_fcall {\n u32 size;\n u8 id;\n u16 tag;\n size_t offset;\n size_t capacity;\n struct kmem_cache *cache;\n u8 *sdata;\n bool zc;\n};\n\ntracepoint:9p:9p_protocol_dump\n{\n /* out of bounds read can happen when this tracepoint is enabled */\n}\n\nrawtracepoint:9p_protocol_dump\n{\n $pdu = (struct p9_fcall *)arg1;\n $dump_sz = (uint64)32;\n\n if ($dump_sz > $pdu->capacity) {\n printf(""reading %zu bytes from src buffer of %zu bytes\\n""', '\n $dump_sz', ' $pdu->capacity);\n }\n}\n\nSigned-off-by: JP Kobryn \nMessage-ID: <20231204202321.22730-1-inwardvessel@gmail.com>\nFixes: 60ece0833b6c (""net/9p: allocate appropriate reduced message buffers"")\nCc: stable@vger.kernel.org\nReviewed-by: Christian Schoenebeck \nSigned-off-by: Dominique Martinet \n', '']",The commit prevents an out of bounds read in the 9p_protocol_dump tracepoint.,"read overrun, tracepoint, 9p_protocol_dump",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +ce3c49da11d77aa7d53cd549d308eb5f7fed8576,ce3c49da11d77aa7d53cd549d308eb5f7fed8576,Alexei Starovoitov,ast@kernel.org,1701741027,Alexei Starovoitov,ast@kernel.org,1701741027,b00bb98c69f23ce4e8e9ca2b06d056c07bef5b12,153de60e8bfb4501e1462a2f74cb787c137b996c e3dd40828534a67931e0dd00fcd35846271fd4e8,"Merge branch 'bpf-fix-the-release-of-inner-map' + +Hou Tao says: + +==================== +bpf: Fix the release of inner map + +From: Hou Tao + +Hi"," + +The patchset aims to fix the release of inner map in map array or map +htab. The release of inner map is different with normal map. For normal +map","[' the map is released after the bpf program which uses the map is\ndestroyed', ' because the bpf program tracks the used maps. However bpf\nprogram can not track the used inner map because these inner map may be\nupdated or deleted dynamically', ' and for now the ref-counter of inner map\nis decreased after the inner map is remove from outer map', ' so the inner\nmap may be freed before the bpf program', ' which is accessing the inner\nmap', ' exits and there will be use-after-free problem as demonstrated by\npatch #6.\n\nThe patchset fixes the problem by deferring the release of inner map.\nThe freeing of inner map is deferred according to the sleepable\nattributes of the bpf programs which own the outer map. Patch #1 fixes\nthe warning when running the newly-added selftest under interpreter\nmode. Patch #2 adds more parameters to .map_fd_put_ptr() to prepare for\nthe fix. Patch #3 fixes the incorrect value of need_defer when freeing\nthe fd array. Patch #4 fixes the potential use-after-free problem by\nusing call_rcu_tasks_trace() and call_rcu() to wait for one tasks trace\nRCU GP and one RCU GP unconditionally. Patch #5 optimizes the free of\ninner map by removing the unnecessary RCU GP waiting. Patch #6 adds a\nselftest to demonstrate the potential use-after-free problem. Patch #7\nupdates a selftest to update outer map in syscall bpf program.\n\nPlease see individual patches for more details. And comments are always\nwelcome.\n\nChange Log:\nv5:\n * patch #3: rename fd_array_map_delete_elem_with_deferred_free() to\n __fd_array_map_delete_elem() (Alexei)\n * patch #5: use atomic64_t instead of atomic_t to prevent potential\n overflow (Alexei)\n * patch #7: use ptr_to_u64() helper instead of force casting to initialize\n pointers in bpf_attr (Alexei)\n\nv4: https://lore.kernel.org/bpf/20231130140120.1736235-1-houtao@huaweicloud.com\n * patch #2: don\'t use ""deferred""', ' use ""need_defer"" uniformly\n * patch #3: newly-added', "" fix the incorrect value of need_defer during\n fd array free.\n * patch #4: doesn't consider the case in which bpf map is not used by\n any bpf program and only use sleepable_refcnt to remove\n\t unnecessary tasks trace RCU GP (Alexei)\n * patch #4: remove memory barriers added due to cautiousness (Alexei)\n\nv3: https://lore.kernel.org/bpf/20231124113033.503338-1-houtao@huaweicloud.com\n * multiple variable renamings (Martin)\n * define BPF_MAP_RCU_GP/BPF_MAP_RCU_TT_GP as bit (Martin)\n * use call_rcu() and its variants instead of synchronize_rcu() (Martin)\n * remove unnecessary mask in bpf_map_free_deferred() (Martin)\n * place atomic_or() and the related smp_mb() together (Martin)\n * add patch #6 to demonstrate that updating outer map in syscall\n program is dead-lock free (Alexei)\n * update comments about the memory barrier in bpf_map_fd_put_ptr()\n * update commit message for patch #3 and #4 to describe more details\n\nv2: https://lore.kernel.org/bpf/20231113123324.3914612-1-houtao@huaweicloud.com\n * defer the invocation of ops->map_free() instead of bpf_map_put() (Martin)\n * update selftest to make it being reproducible under JIT mode (Martin)\n * remove unnecessary preparatory patches\n\nv1: https://lore.kernel.org/bpf/20231107140702.1891778-1-houtao@huaweicloud.com\n====================\n\nLink: https://lore.kernel.org/r/20231204140425.1480317-1-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n"", '']",Fix the release mechanism for inner maps within map arrays and hash tables in eBPF.,"release,inner map,fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e3dd40828534a67931e0dd00fcd35846271fd4e8,e3dd40828534a67931e0dd00fcd35846271fd4e8,Hou Tao,houtao1@huawei.com,1701698665,Alexei Starovoitov,ast@kernel.org,1701741027,b00bb98c69f23ce4e8e9ca2b06d056c07bef5b12,1624918be84a8bcc4f592e55635bc4fe4a96460a,"selftests/bpf: Test outer map update operations in syscall program + +Syscall program is running with rcu_read_lock_trace being held"," so if +bpf_map_update_elem() or bpf_map_delete_elem() invokes +synchronize_rcu_tasks_trace() when operating on an outer map","[' there will\nbe dead-lock', ' so add a test to guarantee that it is dead-lock free.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231204140425.1480317-8-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit tests outer map update operations in syscall programs under rcu_read_lock_trace conditions.,"outer map update, syscall program, rcu_read_lock_trace",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1624918be84a8bcc4f592e55635bc4fe4a96460a,1624918be84a8bcc4f592e55635bc4fe4a96460a,Hou Tao,houtao1@huawei.com,1701698664,Alexei Starovoitov,ast@kernel.org,1701741027,8dfffc1a7125853b34753aac9dd5e51931110cfd,af66bfd3c8538ed21cf72af18426fc4a408665cf,"selftests/bpf: Add test cases for inner map + +Add test cases to test the race between the destroy of inner map due to +map-in-map update and the access of inner map in bpf program. The +following 4 combinations are added: +(1) array map in map array + bpf program +(2) array map in map array + sleepable bpf program +(3) array map in map htab + bpf program +(4) array map in map htab + sleepable bpf program + +Before applying the fixes", when running `./test_prog -a map_in_map`,"[' the\nfollowing error was reported:\n\n ==================================================================\n BUG: KASAN: slab-use-after-free in array_map_update_elem+0x48/0x3e0\n Read of size 4 at addr ffff888114f33824 by task test_progs/1858\n\n CPU: 1 PID: 1858 Comm: test_progs Tainted: G O 6.6.0+ #7\n Hardware name: QEMU Standard PC (i440FX + PIIX', ' 1996) ......\n Call Trace:\n \n dump_stack_lvl+0x4a/0x90\n print_report+0xd2/0x620\n kasan_report+0xd1/0x110\n __asan_load4+0x81/0xa0\n array_map_update_elem+0x48/0x3e0\n bpf_prog_be94a9f26772f5b7_access_map_in_array+0xe6/0xf6\n trace_call_bpf+0x1aa/0x580\n kprobe_perf_func+0xdd/0x430\n kprobe_dispatcher+0xa0/0xb0\n kprobe_ftrace_handler+0x18b/0x2e0\n 0xffffffffc02280f7\n RIP: 0010:__x64_sys_getpgid+0x1/0x30\n ......\n \n\n Allocated by task 1857:\n kasan_save_stack+0x26/0x50\n kasan_set_track+0x25/0x40\n kasan_save_alloc_info+0x1e/0x30\n __kasan_kmalloc+0x98/0xa0\n __kmalloc_node+0x6a/0x150\n __bpf_map_area_alloc+0x141/0x170\n bpf_map_area_alloc+0x10/0x20\n array_map_alloc+0x11f/0x310\n map_create+0x28a/0xb40\n __sys_bpf+0x753/0x37c0\n __x64_sys_bpf+0x44/0x60\n do_syscall_64+0x36/0xb0\n entry_SYSCALL_64_after_hwframe+0x6e/0x76\n\n Freed by task 11:\n kasan_save_stack+0x26/0x50\n kasan_set_track+0x25/0x40\n kasan_save_free_info+0x2b/0x50\n __kasan_slab_free+0x113/0x190\n slab_free_freelist_hook+0xd7/0x1e0\n __kmem_cache_free+0x170/0x260\n kfree+0x9b/0x160\n kvfree+0x2d/0x40\n bpf_map_area_free+0xe/0x20\n array_map_free+0x120/0x2c0\n bpf_map_free_deferred+0xd7/0x1e0\n process_one_work+0x462/0x990\n worker_thread+0x370/0x670\n kthread+0x1b0/0x200\n ret_from_fork+0x3a/0x70\n ret_from_fork_asm+0x1b/0x30\n\n Last potentially related work creation:\n kasan_save_stack+0x26/0x50\n __kasan_record_aux_stack+0x94/0xb0\n kasan_record_aux_stack_noalloc+0xb/0x20\n __queue_work+0x331/0x950\n queue_work_on+0x75/0x80\n bpf_map_put+0xfa/0x160\n bpf_map_fd_put_ptr+0xe/0x20\n bpf_fd_array_map_update_elem+0x174/0x1b0\n bpf_map_update_value+0x2b7/0x4a0\n __sys_bpf+0x2551/0x37c0\n __x64_sys_bpf+0x44/0x60\n do_syscall_64+0x36/0xb0\n entry_SYSCALL_64_after_hwframe+0x6e/0x76\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231204140425.1480317-7-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add test cases to evaluate race conditions in inner map handling with map-in-map updates in bpf programs.,"test cases, inner map, race",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +af66bfd3c8538ed21cf72af18426fc4a408665cf,af66bfd3c8538ed21cf72af18426fc4a408665cf,Hou Tao,houtao1@huawei.com,1701698663,Alexei Starovoitov,ast@kernel.org,1701741026,3171b12b303ea941f111d3f6769257e44fc08104,876673364161da50eed6b472d746ef88242b2368,"bpf: Optimize the free of inner map + +When removing the inner map from the outer map"," the inner map will be +freed after one RCU grace period and one RCU tasks trace grace +period","[' so it is certain that the bpf program', ' which may access the\ninner map', ' has exited before the inner map is freed.\n\nHowever there is no need to wait for one RCU tasks trace grace period if\nthe outer map is only accessed by non-sleepable program. So adding\nsleepable_refcnt in bpf_map and increasing sleepable_refcnt when adding\nthe outer map into env->used_maps for sleepable program. Although the\nmax number of bpf program is INT_MAX - 1', ' the number of bpf programs\nwhich are being loaded may be greater than INT_MAX', ' so using atomic64_t\ninstead of atomic_t for sleepable_refcnt. When removing the inner map\nfrom the outer map', ' using sleepable_refcnt to decide whether or not a\nRCU tasks trace grace period is needed before freeing the inner map.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231204140425.1480317-6-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit optimizes the deallocation process for inner maps in eBPF by using RCU grace periods.,"optimize, inner map, RCU",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +876673364161da50eed6b472d746ef88242b2368,876673364161da50eed6b472d746ef88242b2368,Hou Tao,houtao1@huawei.com,1701698662,Alexei Starovoitov,ast@kernel.org,1701741026,784f4476fe01dda46f6ee631a95a42f1abff3dd0,79d93b3c6ffd79abcd8e43345980aa1e904879c4,"bpf: Defer the free of inner map when necessary + +When updating or deleting an inner map in map array or map htab"," the map +may still be accessed by non-sleepable program or sleepable program. +However bpf_map_fd_put_ptr() decreases the ref-counter of the inner map +directly through bpf_map_put()","[' if the ref-counter is the last one\n(which is true for most cases)', ' the inner map will be freed by\nops->map_free() in a kworker. But for now', "" most .map_free() callbacks\ndon't use synchronize_rcu() or its variants to wait for the elapse of a\nRCU grace period"", ' so after the invocation of ops->map_free completes', '\nthe bpf program which is accessing the inner map may incur\nuse-after-free problem.\n\nFix the free of inner map by invoking bpf_map_free_deferred() after both\none RCU grace period and one tasks trace RCU grace period if the inner\nmap has been removed from the outer map before. The deferment is\naccomplished by using call_rcu() or call_rcu_tasks_trace() when\nreleasing the last ref-counter of bpf map. The newly-added rcu_head\nfield in bpf_map shares the same storage space with work field to\nreduce the size of bpf_map.\n\nFixes: bba1dc0b55ac (""bpf: Remove redundant synchronize_rcu."")\nFixes: 638e4b825d52 (""bpf: Allows per-cpu maps and map-in-map in sleepable programs"")\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231204140425.1480317-5-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Defer free of inner map to ensure safe access by non-sleepable or sleepable programs.,"defer, free, map",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +79d93b3c6ffd79abcd8e43345980aa1e904879c4,79d93b3c6ffd79abcd8e43345980aa1e904879c4,Hou Tao,houtao1@huawei.com,1701698661,Alexei Starovoitov,ast@kernel.org,1701741026,3410665d3a66d115e32defd5244e6319f93c6d39,20c20bd11a0702ce4dc9300c3da58acf551d9725,"bpf: Set need_defer as false when clearing fd array during map free + +Both map deletion operation"," map release and map free operation use +fd_array_map_delete_elem() to remove the element from fd array and +need_defer is always true in fd_array_map_delete_elem(). For the map +deletion operation and map release operation","[' need_defer=true is\nnecessary', ' because the bpf program', ' which accesses the element in fd\narray', ' may still alive. However for map free operation', ' it is certain\nthat the bpf program which owns the fd array has already been exited', ' so\nsetting need_defer as false is appropriate for map free operation.\n\nSo fix it by adding need_defer parameter to bpf_fd_array_map_clear() and\nadding a new helper __fd_array_map_delete_elem() to handle the map\ndeletion', ' map release and map free operations correspondingly.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231204140425.1480317-4-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Set need_defer as false when clearing fd array during map deletion in eBPF.,"need_defer,fd_array,map_deletion",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,['tc/netfilter like programs'] +20c20bd11a0702ce4dc9300c3da58acf551d9725,20c20bd11a0702ce4dc9300c3da58acf551d9725,Hou Tao,houtao1@huawei.com,1701698660,Alexei Starovoitov,ast@kernel.org,1701741026,4ab874508a5b0c40f1f9671eaf6218ac5241fb5f,169410eba271afc9f0fb476d996795aa26770c6d,"bpf: Add map and need_defer parameters to .map_fd_put_ptr() + +map is the pointer of outer map"," and need_defer needs some explanation. +need_defer tells the implementation to defer the reference release of +the passed element and ensure that the element is still alive before +the bpf program","[' which may manipulate it', ' exits.\n\nThe following three cases will invoke map_fd_put_ptr() and different\nneed_defer values will be passed to these callers:\n\n1) release the reference of the old element in the map during map update\n or map deletion. The release must be deferred', ' otherwise the bpf\n program may incur use-after-free problem', ' so need_defer needs to be\n true.\n2) release the reference of the to-be-added element in the error path of\n map update. The to-be-added element is not visible to any bpf\n program', ' so it is OK to pass false for need_defer parameter.\n3) release the references of all elements in the map during map release.\n Any bpf program which has access to the map must have been exited and\n released', ' so need_defer=false will be OK.\n\nThese two parameters will be used by the following patches to fix the\npotential use-after-free problem for map-in-map.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231204140425.1480317-3-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add map and need_defer parameters to .map_fd_put_ptr() to manage reference release in BPF programs.,"map, need_defer, reference",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +169410eba271afc9f0fb476d996795aa26770c6d,169410eba271afc9f0fb476d996795aa26770c6d,Hou Tao,houtao1@huawei.com,1701698659,Alexei Starovoitov,ast@kernel.org,1701741026,c4849605f0aa32546c38760e4ec09fdf6eb8a4a5,153de60e8bfb4501e1462a2f74cb787c137b996c,"bpf: Check rcu_read_lock_trace_held() before calling bpf map helpers + +These three bpf_map_{lookup",update,"['delete}_elem() helpers are also\navailable for sleepable bpf program', ' so add the corresponding lock\nassertion for sleepable bpf program', ' otherwise the following warning\nwill be reported when a sleepable bpf program manipulates bpf map under\ninterpreter mode (aka bpf_jit_enable=0):\n\n WARNING: CPU: 3 PID: 4985 at kernel/bpf/helpers.c:40 ......\n CPU: 3 PID: 4985 Comm: test_progs Not tainted 6.6.0+ #2\n Hardware name: QEMU Standard PC (i440FX + PIIX', ' 1996) ......\n RIP: 0010:bpf_map_lookup_elem+0x54/0x60\n ......\n Call Trace:\n \n ? __warn+0xa5/0x240\n ? bpf_map_lookup_elem+0x54/0x60\n ? report_bug+0x1ba/0x1f0\n ? handle_bug+0x40/0x80\n ? exc_invalid_op+0x18/0x50\n ? asm_exc_invalid_op+0x1b/0x20\n ? __pfx_bpf_map_lookup_elem+0x10/0x10\n ? rcu_lockdep_current_cpu_online+0x65/0xb0\n ? rcu_is_watching+0x23/0x50\n ? bpf_map_lookup_elem+0x54/0x60\n ? __pfx_bpf_map_lookup_elem+0x10/0x10\n ___bpf_prog_run+0x513/0x3b70\n __bpf_prog_run32+0x9d/0xd0\n ? __bpf_prog_enter_sleepable_recur+0xad/0x120\n ? __bpf_prog_enter_sleepable_recur+0x3e/0x120\n bpf_trampoline_6442580665+0x4d/0x1000\n __x64_sys_getpgid+0x5/0x30\n ? do_syscall_64+0x36/0xb0\n entry_SYSCALL_64_after_hwframe+0x6e/0x76\n \n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231204140425.1480317-2-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add checks for RCU read lock before calling BPF map helpers to ensure safety.,"RCU, lock, helper",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +153de60e8bfb4501e1462a2f74cb787c137b996c,153de60e8bfb4501e1462a2f74cb787c137b996c,Colin Ian King,colin.i.king@gmail.com,1701682780,Daniel Borkmann,daniel@iogearbox.net,1701701982,1e09226260771ebff82d41cd6957cd1a3e24b601,5bd90cdc65ef9ef5e13c9ff23620079db5c608a0,"selftests/bpf: Fix spelling mistake ""get_signaure_size"" -> ""get_signature_size"" + +There is a spelling mistake in an ASSERT_GT message. Fix it. + +Signed-off-by: Colin Ian King +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231204093940.2611954-1-colin.i.king@gmail.com +",,Fixed spelling mistake in selftests related to signature size assertion.,"spelling, selftests, bpf",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +5bd90cdc65ef9ef5e13c9ff23620079db5c608a0,5bd90cdc65ef9ef5e13c9ff23620079db5c608a0,Andrei Matei,andreimatei1@gmail.com,1701652368,Daniel Borkmann,daniel@iogearbox.net,1701701847,765b13f5eb37979fd4aa064425af740489731742,90679706d486d3cb202d1b377a230f1f22edaf00,"bpf: Minor logging improvement + +One place where we were logging a register was only logging the variable +part"," not also the fixed part. + +Signed-off-by: Andrei Matei +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231204011248.2040084-1-andreimatei1@gmail.com +",[''],The commit improves logging by including both variable and fixed parts of a register.,"logging, register, improvement",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +90679706d486d3cb202d1b377a230f1f22edaf00,90679706d486d3cb202d1b377a230f1f22edaf00,Alexei Starovoitov,ast@kernel.org,1701545811,Alexei Starovoitov,ast@kernel.org,1701545811,e236cae5c30d8c1f05346f4eb167109a433a1db6,6685aadcab8f170ae3e4d508989a85c1b8a58dba 81eff2e36481c5cf4a2ac906ae56c3fbd3e6f305,"Merge branch 'bpf-verifier-retval-logic-fixes' + +Andrii Nakryiko says: + +==================== +BPF verifier retval logic fixes + +This patch set fixes BPF verifier logic around validating and enforcing return +values for BPF programs that have specific range of expected return values. +Both sync and async callbacks have similar logic and are fixes as well. +A few tests are added that would fail without the fixes in this patch set. + +Also", while at it,"[' we update retval checking logic to use smin/smax range\ninstead of tnum', ' avoiding future potential issues if expected range cannot be\nrepresented precisely by tnum (e.g.', ' [0', ' 2] is not representable by tnum and\nis treated as [0', ' 3]).\n\nThere is a little bit of refactoring to unify async callback and program exit\nlogic to avoid duplication of checks as much as possible.\n\nv4->v5:\n - fix timer_bad_ret test on no-alu32 flavor (CI);\nv3->v4:\n - add back bpf_func_state rearrangement patch;\n - simplified patch #4 as suggested (Shung-Hsi);\nv2->v3:\n - more carefullly switch from umin/umax to smin/smax;\nv1->v2:\n - drop tnum from retval checks (Eduard);\n - use smin/smax instead of umin/umax (Alexei).\n====================\n\nLink: https://lore.kernel.org/r/20231202175705.885270-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']","The commit addresses logic fixes for BPF verifier return value validation and enforcement, including tests.","BPF, verifier, fixes",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +81eff2e36481c5cf4a2ac906ae56c3fbd3e6f305,81eff2e36481c5cf4a2ac906ae56c3fbd3e6f305,Andrii Nakryiko,andrii@kernel.org,1701539825,Alexei Starovoitov,ast@kernel.org,1701545811,e236cae5c30d8c1f05346f4eb167109a433a1db6,5c19e1d05e9e71b42d8e779f41959254239709da,"bpf: simplify tnum output if a fully known constant + +Emit tnum representation as just a constant if all bits are known. +Use decimal-vs-hex logic to determine exact format of emitted +constant value"," just like it's done for register range values. +For that move tnum_strn() to kernel/bpf/log.c to reuse decimal-vs-hex +determination logic and constants. + +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-12-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Simplify tnum output to emit constants directly if all bits are known.,"tnum,constant,output",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5c19e1d05e9e71b42d8e779f41959254239709da,5c19e1d05e9e71b42d8e779f41959254239709da,Andrii Nakryiko,andrii@kernel.org,1701539824,Alexei Starovoitov,ast@kernel.org,1701545811,c62d07d54307d750de319df7214292eb9c2548d8,e02dea158ddaebe6e725be715e0009923b96ec8e,"selftests/bpf: adjust global_func15 test to validate prog exit precision + +Add one more subtest to global_func15 selftest to validate that +verifier properly marks r0 as precise and avoids erroneous state pruning +of the branch that has return value outside of expected [0"," 1] value. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-11-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Added a subtest to global_func15 selftest for verifying exit precision in the eBPF verifier.,"selftest, verifier, precision",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e02dea158ddaebe6e725be715e0009923b96ec8e,e02dea158ddaebe6e725be715e0009923b96ec8e,Andrii Nakryiko,andrii@kernel.org,1701539823,Alexei Starovoitov,ast@kernel.org,1701545811,188fa71703b207c98697a36cc1f76984493a22d2,eabe518de533a4291996020977054a7a7b78c7d3,"selftests/bpf: validate async callback return value check correctness + +Adjust timer/timer_ret_1 test to validate more carefully verifier logic +of enforcing async callback return value. This test will pass only if +return result is marked precise and read. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-10-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Improves selftests/bpf by validating correctness of async callback return value checks.,"selftests,bpf,async",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +eabe518de533a4291996020977054a7a7b78c7d3,eabe518de533a4291996020977054a7a7b78c7d3,Andrii Nakryiko,andrii@kernel.org,1701539822,Alexei Starovoitov,ast@kernel.org,1701545811,a07050432051b4354f9e6ad2d932405c036f3d9b,0ef24c8dfae24a4b8aa2e92eac20faecdc5502e5,"bpf: enforce precision of R0 on program/async callback return + +Given we enforce a valid range for program and async callback return +value"," we must mark R0 as precise to avoid incorrect state pruning. + +Fixes: b5dc0163d8fd (""bpf: precise scalar_value tracking"") +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],The commit enforces precision of R0 for program and async callback return values to prevent incorrect state pruning.,"precision,R0,return",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0ef24c8dfae24a4b8aa2e92eac20faecdc5502e5,0ef24c8dfae24a4b8aa2e92eac20faecdc5502e5,Andrii Nakryiko,andrii@kernel.org,1701539821,Alexei Starovoitov,ast@kernel.org,1701545810,d5bddc2016d33b132d23ee00f072cc34015c55b0,c871d0e00f0e8c207ce8ff89025e35cc49a8a3c3,"bpf: unify async callback and program retval checks + +Use common logic to verify program return values and async callback +return values. This allows to avoid duplication of any extra steps +necessary", like precision marking,"[' which will be added in the next\npatch.\n\nAcked-by: Eduard Zingerman \nAcked-by: Shung-Hsi Yu \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231202175705.885270-8-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit unifies the logic for verifying program return values and async callback return values in bpf.,"async,callback,retval",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c871d0e00f0e8c207ce8ff89025e35cc49a8a3c3,c871d0e00f0e8c207ce8ff89025e35cc49a8a3c3,Andrii Nakryiko,andrii@kernel.org,1701539820,Alexei Starovoitov,ast@kernel.org,1701545810,c76f08bf825c02b74107045d7e012413ed565936,60a6b2c78c62d0a99ccb7ad5edc950f79e56306a,"bpf: enforce precise retval range on program exit + +Similarly to subprog/callback logic"," enforce return value of BPF program +using more precise smin/smax range. + +We need to adjust a bunch of tests due to a changed format of an error +message. + +Acked-by: Eduard Zingerman +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-7-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],"The commit enforces precise return value ranges for BPF program exits, requiring test adjustments.","precise, retval, tests",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +60a6b2c78c62d0a99ccb7ad5edc950f79e56306a,60a6b2c78c62d0a99ccb7ad5edc950f79e56306a,Andrii Nakryiko,andrii@kernel.org,1701539819,Alexei Starovoitov,ast@kernel.org,1701545810,79f713f33847013456174f352d42e936941bfb18,8fa4ecd49b81ccd9d1d87f1c8b2260e218644878,"selftests/bpf: add selftest validating callback result is enforced + +BPF verifier expects callback subprogs to return values from specified +range (typically [0"," 1]). This requires that r0 at exit is both precise +(because we rely on specific value range) and is marked as read +(otherwise state comparison will ignore such register as unimportant). + +Add a simple test that validates that all these conditions are enforced. + +Acked-by: Eduard Zingerman +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-6-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],This commit adds a selftest for validating callback result enforcement in BPF verifier.,"selftest, callback, verifier",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8fa4ecd49b81ccd9d1d87f1c8b2260e218644878,8fa4ecd49b81ccd9d1d87f1c8b2260e218644878,Andrii Nakryiko,andrii@kernel.org,1701539818,Alexei Starovoitov,ast@kernel.org,1701545810,6c677d87b16c5c361795841d024fb1a5f81c9944,0acd03a5bd188b0c501d285d938439618bd855c4,"bpf: enforce exact retval range on subprog/callback exit + +Instead of relying on potentially imprecise tnum representation of +expected return value range for callbacks and subprogs"," validate that +smin/smax range satisfy exact expected range of return values. + +E.g.","[' if callback would need to return [0', ' 2] range', "" tnum can't\nrepresent this precisely and instead will allow [0"", ' 3] range. By\nchecking smin/smax range', ' we can make sure that subprog/callback indeed\nreturns only valid [0', ' 2] range.\n\nAcked-by: Eduard Zingerman \nAcked-by: Shung-Hsi Yu \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231202175705.885270-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit enforces exact return value range verification for subprograms and callbacks in BPF.,"retval,subprog,callbacks",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0acd03a5bd188b0c501d285d938439618bd855c4,0acd03a5bd188b0c501d285d938439618bd855c4,Andrii Nakryiko,andrii@kernel.org,1701539817,Alexei Starovoitov,ast@kernel.org,1701545810,2922aa43c9b81c4f7925db4abf022cd041f1dcc0,5fad52bee30414270104525e3a0266327a6e9d11,"bpf: enforce precision of R0 on callback return + +Given verifier checks actual value", r0 has to be precise,"[' so we need to\npropagate precision properly. r0 also has to be marked as read', '\notherwise subsequent state comparisons will ignore such register as\nunimportant and precision won\'t really help here.\n\nFixes: 69c087ba6225 (""bpf: Add bpf_for_each_map_elem() helper"")\nAcked-by: Eduard Zingerman \nAcked-by: Shung-Hsi Yu \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231202175705.885270-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enforces precision checks on the return value of R0 in callbacks within the eBPF verifier.,"precision,R0,verifier",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5fad52bee30414270104525e3a0266327a6e9d11,5fad52bee30414270104525e3a0266327a6e9d11,Andrii Nakryiko,andrii@kernel.org,1701539816,Alexei Starovoitov,ast@kernel.org,1701545810,ba9a79b5a1a6390bfebb5a70aa86af65e7f45df0,45b5623f2d721c25d1a2fdc8c4600fb4b7b61c75,"bpf: provide correct register name for exception callback retval check + +bpf_throw() is checking R1"," so let's report R1 in the log. + +Acked-by: Eduard Zingerman +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231202175705.885270-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Fix incorrect register name reported in bpf_throw() exception callback log.,"register, exception, bpf_throw",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +45b5623f2d721c25d1a2fdc8c4600fb4b7b61c75,45b5623f2d721c25d1a2fdc8c4600fb4b7b61c75,Andrii Nakryiko,andrii@kernel.org,1701539815,Alexei Starovoitov,ast@kernel.org,1701545810,f98ea693a0976bed8837a69d895798359b14a2cf,6685aadcab8f170ae3e4d508989a85c1b8a58dba,"bpf: rearrange bpf_func_state fields to save a bit of memory + +It's a trivial rearrangement saving 8 bytes. We have 4 bytes of padding +at the end which can be filled with another field without increasing +struct bpf_func_state. + +copy_func_state() logic remains correct without any further changes. + +BEFORE +====== +struct bpf_func_state { + struct bpf_reg_state regs[11]; /* 0 1320 */ + /* --- cacheline 20 boundary (1280 bytes) was 40 bytes ago --- */ + int callsite; /* 1320 4 */ + u32 frameno; /* 1324 4 */ + u32 subprogno; /* 1328 4 */ + u32 async_entry_cnt; /* 1332 4 */ + bool in_callback_fn; /* 1336 1 */ + + /* XXX 7 bytes hole"," try to pack */ + + /* --- cacheline 21 boundary (1344 bytes) --- */ + struct tnum callback_ret_range; /* 1344 16 */ + bool in_async_callback_fn; /* 1360 1 */ + bool in_exception_callback_fn; /* 1361 1 */ + + /* XXX 2 bytes hole","[' try to pack */\n\n int acquired_refs; /* 1364 4 */\n struct bpf_reference_state * refs; /* 1368 8 */\n int allocated_stack; /* 1376 4 */\n\n /* XXX 4 bytes hole', ' try to pack */\n\n struct bpf_stack_state * stack; /* 1384 8 */\n\n /* size: 1392', ' cachelines: 22', ' members: 13 */\n /* sum members: 1379', ' holes: 3', ' sum holes: 13 */\n /* last cacheline: 48 bytes */\n};\n\nAFTER\n=====\nstruct bpf_func_state {\n struct bpf_reg_state regs[11]; /* 0 1320 */\n /* --- cacheline 20 boundary (1280 bytes) was 40 bytes ago --- */\n int callsite; /* 1320 4 */\n u32 frameno; /* 1324 4 */\n u32 subprogno; /* 1328 4 */\n u32 async_entry_cnt; /* 1332 4 */\n struct tnum callback_ret_range; /* 1336 16 */\n /* --- cacheline 21 boundary (1344 bytes) was 8 bytes ago --- */\n bool in_callback_fn; /* 1352 1 */\n bool in_async_callback_fn; /* 1353 1 */\n bool in_exception_callback_fn; /* 1354 1 */\n\n /* XXX 1 byte hole', ' try to pack */\n\n int acquired_refs; /* 1356 4 */\n struct bpf_reference_state * refs; /* 1360 8 */\n struct bpf_stack_state * stack; /* 1368 8 */\n int allocated_stack; /* 1376 4 */\n\n /* size: 1384', ' cachelines: 22', ' members: 13 */\n /* sum members: 1379', ' holes: 1', ' sum holes: 1 */\n /* padding: 4 */\n /* last cacheline: 40 bytes */\n};\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231202175705.885270-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Rearrange fields in struct bpf_func_state to optimize memory usage by eliminating padding.,"rearrange,memory,optimization",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6685aadcab8f170ae3e4d508989a85c1b8a58dba,6685aadcab8f170ae3e4d508989a85c1b8a58dba,Alexei Starovoitov,ast@kernel.org,1701476463,Alexei Starovoitov,ast@kernel.org,1701476463,0d7e27c7ea846503b8b95abaee14a85242a98347,b6a3451e0847d5d70fb5fa2b2a80ab9f80bf2c7b 1030e9154258b54e3c7dc07c39e7b6dcf24bc3d2,"Merge branch 'bpf-file-verification-with-lsm-and-fsverity' + +Song Liu says: + +==================== +bpf: File verification with LSM and fsverity + +Changes v14 => v15: +1. Fix selftest build without CONFIG_FS_VERITY. (Alexei) +2. Add Acked-by from KP. + +Changes v13 => v14: +1. Add ""static"" for bpf_fs_kfunc_set. +2. Add Acked-by from Christian Brauner. + +Changes v12 => v13: +1. Only keep 4/9 through 9/9 of v12"," as the first 3 patches already + applied; +2. Use new macro __bpf_kfunc_[start|end]_defs(). + +Changes v11 => v12: +1. Fix typo (data_ptr => sig_ptr) in bpf_get_file_xattr(). + +Changes v10 => v11: +1. Let __bpf_dynptr_data() return const void *. (Andrii) +2. Optimize code to reuse output from __bpf_dynptr_size(). (Andrii) +3. Add __diag_ignore_all(""-Wmissing-declarations"") for kfunc definition. +4. Fix an off indentation. (Andrii) + +Changes v9 => v10: +1. Remove WARN_ON_ONCE() from check_reg_const_str. (Alexei) + +Changes v8 => v9: +1. Fix test_progs kfunc_dynptr_param/dynptr_data_null. + +Changes v7 => v8: +1. Do not use bpf_dynptr_slice* in the kernel. Add __bpf_dynptr_data* and + use them in ther kernel. (Andrii) + +Changes v6 => v7: +1. Change ""__const_str"" annotation to ""__str"". (Alexei","[' Andrii)\n2. Add KF_TRUSTED_ARGS flag for both new kfuncs. (KP)\n3. Only allow bpf_get_file_xattr() to read xattr with ""user."" prefix.\n4. Add Acked-by from Eric Biggers.\n\nChanges v5 => v6:\n1. Let fsverity_init_bpf() return void. (Eric Biggers)\n2. Sort things in alphabetic orders. (Eric Biggers)\n\nChanges v4 => v5:\n1. Revise commit logs. (Alexei)\n\nChanges v3 => v4:\n1. Fix error reported by CI.\n2. Update comments of bpf_dynptr_slice* that they may return error pointer.\n\nChanges v2 => v3:\n1. Rebase and resolve conflicts.\n\nChanges v1 => v2:\n1. Let bpf_get_file_xattr() use const string for arg ""name"". (Alexei)\n2. Add recursion prevention with allowlist. (Alexei)\n3. Let bpf_get_file_xattr() use __vfs_getxattr() to avoid recursion', '\n as vfs_getxattr() calls into other LSM hooks.\n4. Do not use dynptr->data directly', ' use helper insteadd. (Andrii)\n5. Fixes with bpf_get_fsverity_digest. (Eric Biggers)\n6. Add documentation. (Eric Biggers)\n7. Fix some compile warnings. (kernel test robot)\n\nThis set enables file verification with BPF LSM and fsverity.\n\nIn this solution', ' fsverity is used to provide reliable and efficient hash\nof files; and BPF LSM is used to implement signature verification (against\nasymmetric keys)', ' and to enforce access control.\n\nThis solution can be used to implement access control in complicated cases.\nFor example: only signed python binary and signed python script and access\nspecial files/devices/ports.\n\nThanks', '\nSong\n====================\n\nLink: https://lore.kernel.org/r/20231129234417.856536-1-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']","Integrate file verification using LSM and fsverity in the BPF subsystem, with multiple incremental fixes and optimizations.","file verification, LSM, fsverity",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1030e9154258b54e3c7dc07c39e7b6dcf24bc3d2,1030e9154258b54e3c7dc07c39e7b6dcf24bc3d2,Song Liu,song@kernel.org,1701301457,Alexei Starovoitov,ast@kernel.org,1701476463,0d7e27c7ea846503b8b95abaee14a85242a98347,341f06fdddf72cd60a10945152f69f0f1d614519,"selftests/bpf: Add test that uses fsverity and xattr to sign a file + +This selftests shows a proof of concept method to use BPF LSM to enforce +file signature. This test is added to verify_pkcs7_sig"," so that some +existing logic can be reused. + +This file signature method uses fsverity","[' which provides reliable and\nefficient hash (known as digest) of the file. The file digest is signed\nwith asymmetic key', ' and the signature is stored in xattr. At the run time', '\nBPF LSM reads file digest and the signature', ' and then checks them against\nthe public key.\n\nNote that this solution does NOT require FS_VERITY_BUILTIN_SIGNATURES.\nfsverity is only used to provide file digest. The signature verification\nand access control is all implemented in BPF LSM.\n\nSigned-off-by: Song Liu \nLink: https://lore.kernel.org/r/20231129234417.856536-7-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add a selftest to demonstrate using BPF LSM for file signature enforcement with fsverity and xattr.,"selftests,BPF LSM,fsverity",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['LSM like programs'] +341f06fdddf72cd60a10945152f69f0f1d614519,341f06fdddf72cd60a10945152f69f0f1d614519,Song Liu,song@kernel.org,1701301456,Alexei Starovoitov,ast@kernel.org,1701476463,0b17fcf04dd1fc3dd848eee2d9c2421b310c6587,6b0ae4566aba566a2ab4a2de9c59ab3d7f4b43c2,"selftests/bpf: Add tests for filesystem kfuncs + +Add selftests for two new filesystem kfuncs: + 1. bpf_get_file_xattr + 2. bpf_get_fsverity_digest + +These tests simply make sure the two kfuncs work. Another selftest will be +added to demonstrate how to use these kfuncs to verify file signature. + +CONFIG_FS_VERITY is added to selftests config. However"," this is not +sufficient to guarantee bpf_get_fsverity_digest works. This is because +fsverity need to be enabled at file system level (for example","["" with tune2fs\non ext4). If local file system doesn't have this feature enabled"", ' just skip\nthe test.\n\nSigned-off-by: Song Liu \nLink: https://lore.kernel.org/r/20231129234417.856536-6-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add selftests for two new filesystem kfuncs: bpf_get_file_xattr and bpf_get_fsverity_digest.,"selftests,kfuncs,filesystem",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +6b0ae4566aba566a2ab4a2de9c59ab3d7f4b43c2,6b0ae4566aba566a2ab4a2de9c59ab3d7f4b43c2,Song Liu,song@kernel.org,1701301455,Alexei Starovoitov,ast@kernel.org,1701476463,36d3e8acaa5a6f6a5c69984487ef954e275ed870,0de267d9ec6574536ec5ea2f2242df5c92bcdd4b,"selftests/bpf: Sort config in alphabetic order + +Move CONFIG_VSOCKETS up"," so the CONFIGs are in alphabetic order. + +Signed-off-by: Song Liu +Link: https://lore.kernel.org/r/20231129234417.856536-5-song@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],The commit sorts the selftests/bpf configuration in alphabetical order by moving CONFIG_VSOCKETS up.,"selftests, configuration, alphabetic",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +0de267d9ec6574536ec5ea2f2242df5c92bcdd4b,0de267d9ec6574536ec5ea2f2242df5c92bcdd4b,Song Liu,song@kernel.org,1701301454,Alexei Starovoitov,ast@kernel.org,1701476463,bdc5dd0be0ca62d766798b4f94a92bd6ac1795b9,67814c00de3161181cddd06c77aeaf86ac4cc584,"Documentation/bpf: Add documentation for filesystem kfuncs + +Add a brief introduction for file system kfuncs: + + bpf_get_file_xattr() + bpf_get_fsverity_digest() + +The documentation highlights the strategy to avoid recursions of these +kfuncs. + +Signed-off-by: Song Liu +Link: https://lore.kernel.org/r/20231129234417.856536-4-song@kernel.org +Signed-off-by: Alexei Starovoitov +",,"The commit adds documentation for filesystem kfuncs, specifically bpf_get_file_xattr() and bpf_get_fsverity_digest().","documentation, filesystem, kfuncs",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +67814c00de3161181cddd06c77aeaf86ac4cc584,67814c00de3161181cddd06c77aeaf86ac4cc584,Song Liu,song@kernel.org,1701301453,Alexei Starovoitov,ast@kernel.org,1701476463,ec467b83873691b94b7e4ded55a4abdfa46ef41c,ac9c05e0e453cfcab2866f6d28f257590e4f66e5,bpf," fsverity: Add kfunc bpf_get_fsverity_digest + +fsverity provides fast and reliable hash of files","[' namely fsverity_digest.\nThe digest can be used by security solutions to verify file contents.\n\nAdd new kfunc bpf_get_fsverity_digest() so that we can access fsverity from\nBPF LSM programs. This kfunc is added to fs/verity/measure.c because some\ndata structure used in the function is private to fsverity\n(fs/verity/fsverity_private.h).\n\nTo avoid recursion', ' bpf_get_fsverity_digest is only allowed in BPF LSM\nprograms.\n\nSigned-off-by: Song Liu \nAcked-by: Eric Biggers \nLink: https://lore.kernel.org/r/20231129234417.856536-3-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add kfunc bpf_get_fsverity_digest for fast and reliable file hash in fsverity.,"fsverity,kfunc,hash",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ac9c05e0e453cfcab2866f6d28f257590e4f66e5,ac9c05e0e453cfcab2866f6d28f257590e4f66e5,Song Liu,song@kernel.org,1701301452,Alexei Starovoitov,ast@kernel.org,1701476463,aebe277c80b949f0a40681bdb8244ae7ba2b0a8f,b6a3451e0847d5d70fb5fa2b2a80ab9f80bf2c7b,"bpf: Add kfunc bpf_get_file_xattr + +It is common practice for security solutions to store tags/labels in +xattrs. To implement similar functionalities in BPF LSM"," add new kfunc +bpf_get_file_xattr(). + +The first use case of bpf_get_file_xattr() is to implement file +verifications with asymmetric keys. Specificially","[' security applications\ncould use fsverity for file hashes and use xattr to store file signatures.\n(kfunc for fsverity hash will be added in a separate commit.)\n\nCurrently', ' only xattrs with ""user."" prefix can be read with kfunc\nbpf_get_file_xattr(). As use cases evolve', ' we may add a dedicated prefix\nfor bpf_get_file_xattr().\n\nTo avoid recursion', ' bpf_get_file_xattr can be only called from LSM hooks.\n\nSigned-off-by: Song Liu \nAcked-by: Christian Brauner \nAcked-by: KP Singh \nLink: https://lore.kernel.org/r/20231129234417.856536-2-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add new kfunc bpf_get_file_xattr to support file verifications with BPF LSM.,"kfunc,xattr,LSM",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['LSM like programs'] +dfce9cb3140592b886838e06f3e0c25fea2a9cae,dfce9cb3140592b886838e06f3e0c25fea2a9cae,Yonghong Song,yonghong.song@linux.dev,1701398800,Andrii Nakryiko,andrii@kernel.org,1701474110,e3e3996806c2f48fb223715059d780f66af89db6,830139e7b6911266a84a77e1f18abf758995cc89,"bpf: Fix a verifier bug due to incorrect branch offset comparison with cpu=v4 + +Bpf cpu=v4 support is introduced in [1] and Commit 4cd58e9af8b9 +(""bpf: Support new 32bit offset jmp instruction"") added support for new +32bit offset jmp instruction. Unfortunately"," in function +bpf_adj_delta_to_off()","[' for new branch insn with 32bit offset', ' the offset\n(plus/minor a small delta) compares to 16-bit offset bound\n[S16_MIN', ' S16_MAX]', "" which caused the following verification failure:\n $ ./test_progs-cpuv4 -t verif_scale_pyperf180\n ...\n insn 10 cannot be patched due to 16-bit range\n ...\n libbpf: failed to load object 'pyperf180.bpf.o'\n scale_test:FAIL:expect_success unexpected error: -12 (errno 12)\n #405 verif_scale_pyperf180:FAIL\n\nNote that due to recent llvm18 development"", ' the patch [2] (already applied\nin bpf-next) needs to be applied to bpf tree for testing purpose.\n\nThe fix is rather simple. For 32bit offset branch insn', ' the adjusted\noffset compares to [S32_MIN', ' S32_MAX] and then verification succeeded.\n\n [1] https://lore.kernel.org/all/20230728011143.3710005-1-yonghong.song@linux.dev\n [2] https://lore.kernel.org/bpf/20231110193644.3130906-1-yonghong.song@linux.dev\n\nFixes: 4cd58e9af8b9 (""bpf: Support new 32bit offset jmp instruction"")\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231201024640.3417057-1-yonghong.song@linux.dev\n', '']",Fixes a verifier bug related to incorrect branch offset comparison for CPU version v4 in eBPF.,"verifier, bug, offset",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b6a3451e0847d5d70fb5fa2b2a80ab9f80bf2c7b,b6a3451e0847d5d70fb5fa2b2a80ab9f80bf2c7b,Jeroen van Ingen Schenau,jeroen.vaningenschenau@novoserve.com,1701345833,Daniel Borkmann,daniel@iogearbox.net,1701443565,49e0a5f9345088f240b5bff686f8978b4589e8fe,15bc81212f593fbd7bda787598418b931842dc14,"selftests/bpf: Fix erroneous bitmask operation + +xdp_synproxy_kern.c is a BPF program that generates SYN cookies on +allowed TCP ports and sends SYNACKs to clients"," accelerating synproxy +iptables module. + +Fix the bitmask operation when checking the status of an existing +conntrack entry within tcp_lookup() function. Do not AND with the bit +position number","[' but with the bitmask value to check whether the entry\nfound has the IPS_CONFIRMED flag set.\n\nFixes: fb5cd0ce70d4 (""selftests/bpf: Add selftests for raw syncookie helpers"")\nSigned-off-by: Jeroen van Ingen Schenau \nSigned-off-by: Daniel Borkmann \nTested-by: Minh Le Hoang \nLink: https://lore.kernel.org/xdp-newbies/CAAi1gX7owA+Tcxq-titC-h-KPM7Ri-6ZhTNMhrnPq5gmYYwKow@mail.gmail.com/T/#u\nLink: https://lore.kernel.org/bpf/20231130120353.3084-1-jeroen.vaningenschenau@novoserve.com\n', '']",This commit fixes an erroneous bitmask operation in the xdp_synproxy_kern BPF program for tracking TCP connections.,"bitmask, synproxy, conntrack",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['xdp like programs', 'socket like programs']" +753c8608f3e579307493a63b9242667aee35a751,753c8608f3e579307493a63b9242667aee35a751,Jakub Kicinski,kuba@kernel.org,1701392169,Jakub Kicinski,kuba@kernel.org,1701392322,4197358069e8db7bc0d36a474612f7ffefc7ba72,975f2d73a99f35b57ffa2ad7bff8562225cdcfcb f690ff9122d2ca8e38769f3bcf217bd3df681a36,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-11-30 + +We've added 30 non-merge commits during the last 7 day(s) which contain +a total of 58 files changed", 1598 insertions(+),"[' 154 deletions(-).\n\nThe main changes are:\n\n1) Add initial TX metadata implementation for AF_XDP with support in mlx5\n and stmmac drivers. Two types of offloads are supported right now', ' that\n is', ' TX timestamp and TX checksum offload', ' from Stanislav Fomichev with\n stmmac implementation from Song Yoong Siang.\n\n2) Change BPF verifier logic to validate global subprograms lazily instead\n of unconditionally before the main program', ' so they can be guarded using\n BPF CO-RE techniques', ' from Andrii Nakryiko.\n\n3) Add BPF link_info support for uprobe multi link along with bpftool\n integration for the latter', ' from Jiri Olsa.\n\n4) Use pkg-config in BPF selftests to determine ld flags which is\n in particular needed for linking statically', ' from Akihiko Odaki.\n\n5) Fix a few BPF selftest failures to adapt to the upcoming LLVM18', '\n from Yonghong Song.\n\n* tag \'for-netdev\' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (30 commits)\n bpf/tests: Remove duplicate JSGT tests\n selftests/bpf: Add TX side to xdp_hw_metadata\n selftests/bpf: Convert xdp_hw_metadata to XDP_USE_NEED_WAKEUP\n selftests/bpf: Add TX side to xdp_metadata\n selftests/bpf: Add csum helpers\n selftests/xsk: Support tx_metadata_len\n xsk: Add option to calculate TX checksum in SW\n xsk: Validate xsk_tx_metadata flags\n xsk: Document tx_metadata_len layout\n net: stmmac: Add Tx HWTS support to XDP ZC\n net/mlx5e: Implement AF_XDP TX timestamp and checksum offload\n tools: ynl: Print xsk-features from the sample\n xsk: Add TX timestamp and TX checksum offload support\n xsk: Support tx_metadata_len\n selftests/bpf: Use pkg-config for libelf\n selftests/bpf: Override PKG_CONFIG for static builds\n selftests/bpf: Choose pkg-config for the target\n bpftool: Add support to display uprobe_multi links\n selftests/bpf: Add link_info test for uprobe_multi link\n selftests/bpf: Use bpf_link__destroy in fill_link_info tests\n ...\n====================\n\nConflicts:\n\nDocumentation/netlink/specs/netdev.yaml:\n 839ff60df3ab (""net: page_pool: add nlspec for basic access to page pools"")\n 48eb03dd2630 (""xsk: Add TX timestamp and TX checksum offload support"")\nhttps://lore.kernel.org/all/20231201094705.1ee3cab8@canb.auug.org.au/\n\nWhile at it also regen', ' tree is dirty after:\n 48eb03dd2630 (""xsk: Add TX timestamp and TX checksum offload support"")\nlooks like code wasn\'t re-rendered after ""render-max"" was removed.\n\nLink: https://lore.kernel.org/r/20231130145708.32573-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merged branch 'for-netdev' containing multiple eBPF related changes into the main tree.,"merge,eBPF,changes",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6172a5180fcc65170bfa2d49e55427567860f2a7,6172a5180fcc65170bfa2d49e55427567860f2a7,Linus Torvalds,torvalds@linux-foundation.org,1701386686,Linus Torvalds,torvalds@linux-foundation.org,1701386686,54617c32c60bdbd06ab0cde16f8c56d913ef68ba,e8f60209d6cf652a9cfda64371acea69f62770aa 777f245eec8152926b411e3d4f4545310f52cbed,"Merge tag 'net-6.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + ""Including fixes from bpf and wifi. + + Current release - regressions: + + - neighbour: fix __randomize_layout crash in struct neighbour + + - r8169: fix deadlock on RTL8125 in jumbo mtu mode + + Previous releases - regressions: + + - wifi: + - mac80211: fix warning at station removal time + - cfg80211: fix CQM for non-range use + + - tools: ynl-gen: fix unexpected response handling + + - octeontx2-af: fix possible buffer overflow + + - dpaa2: recycle the RX buffer only after all processing done + + - rswitch: fix missing dev_kfree_skb_any() in error path + + Previous releases - always broken: + + - ipv4: fix uaf issue when receiving igmp query packet + + - wifi: mac80211: fix debugfs deadlock at device removal time + + - bpf: + - sockmap: af_unix stream sockets need to hold ref for pair sock + - netdevsim: don't accept device bound programs + + - selftests: fix a char signedness issue + + - dsa: mv88e6xxx: fix marvell 6350 probe crash + + - octeontx2-pf: restore TC ingress police rules when interface is up + + - wangxun: fix memory leak on msix entry + + - ravb: keep reverse order of operations in ravb_remove()"" + +* tag 'net-6.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (51 commits) + net: ravb: Keep reverse order of operations in ravb_remove() + net: ravb: Stop DMA in case of failures on ravb_open() + net: ravb: Start TX queues after HW initialization succeeded + net: ravb: Make write access to CXR35 first before accessing other EMAC registers + net: ravb: Use pm_runtime_resume_and_get() + net: ravb: Check return value of reset_control_deassert() + net: libwx: fix memory leak on msix entry + ice: Fix VF Reset paths when interface in a failed over aggregate + bpf"," sockmap: Add af_unix test with both sockets in map + bpf","["" sockmap: af_unix stream sockets need to hold ref for pair sock\n tools: ynl-gen: always construct struct ynl_req_state\n ethtool: don't propagate EOPNOTSUPP from dumps\n ravb: Fix races between ravb_tx_timeout_work() and net related ops\n r8169: prevent potential deadlock in rtl8169_close\n r8169: fix deadlock on RTL8125 in jumbo mtu mode\n neighbour: Fix __randomize_layout crash in struct neighbour\n octeontx2-pf: Restore TC ingress police rules when interface is up\n octeontx2-pf: Fix adding mbox work queue entry when num_vfs > 64\n net: stmmac: xgmac: Disable FPE MMC interrupts\n octeontx2-af: Fix possible buffer overflow\n ...\n"", '']","Merge networking fixes for various components including bpf, wifi, and others.","networking, fixes, bpf",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', 'other']" +f9893fdac319bb2817e5e7818870264d7fb2eb02,f9893fdac319bb2817e5e7818870264d7fb2eb02,Eric Dumazet,edumazet@google.com,1701336179,Jakub Kicinski,kuba@kernel.org,1701368098,112a72a1ec47a1d0c1db138d2592001805031538,7e0222686316f5506e51182f02c1d83ecc34c471,"net: page_pool: fix general protection fault in page_pool_unlist + +syzbot was able to trigger a crash [1] in page_pool_unlist() + +page_pool_list() only inserts a page pool into a netdev page pool list +if a netdev was set in params. + +Even if the kzalloc() call in page_pool_create happens to initialize +pool->user.list"," I chose to be more explicit in page_pool_list() +adding one INIT_HLIST_NODE(). + +We could test in page_pool_unlist() if netdev was set","['\nbut since netdev can be changed to lo', ' it seems more robust to\ncheck if pool->user.list is hashed before calling hlist_del().\n\n[1]\n\nIllegal XDP return value 4294946546 on prog (id 2) dev N/A', ' expect packet loss!\ngeneral protection fault', ' probably for non-canonical address 0xdffffc0000000000: 0000 [#1] PREEMPT SMP KASAN\nKASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007]\nCPU: 0 PID: 5064 Comm: syz-executor391 Not tainted 6.7.0-rc2-syzkaller-00533-ga379972973a8 #0\nHardware name: Google Google Compute Engine/Google Compute Engine', ' BIOS Google 11/10/2023\nRIP: 0010:__hlist_del include/linux/list.h:988 [inline]\nRIP: 0010:hlist_del include/linux/list.h:1002 [inline]\nRIP: 0010:page_pool_unlist+0xd1/0x170 net/core/page_pool_user.c:342\nCode: df 48 89 fa 48 c1 ea 03 80 3c 02 00 0f 85 90 00 00 00 4c 8b a3 f0 06 00 00 48 b8 00 00 00 00 00 fc ff df 4c 89 e2 48 c1 ea 03 <80> 3c 02 00 75 68 48 85 ed 49 89 2c 24 74 24 e8 1b ca 07 f9 48 8d\nRSP: 0018:ffffc900039ff768 EFLAGS: 00010246\nRAX: dffffc0000000000 RBX: ffff88814ae02000 RCX: 0000000000000000\nRDX: 0000000000000000 RSI: 0000000000000004 RDI: ffff88814ae026f0\nRBP: 0000000000000000 R08: 0000000000000000 R09: fffffbfff1d57fdc\nR10: ffffffff8eabfee3 R11: ffffffff8aa0008b R12: 0000000000000000\nR13: ffff88814ae02000 R14: dffffc0000000000 R15: 0000000000000001\nFS: 000055555717a380(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000\nCS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033\nCR2: 0000000002555398 CR3: 0000000025044000 CR4: 00000000003506f0\nDR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000\nDR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400\nCall Trace:\n \n __page_pool_destroy net/core/page_pool.c:851 [inline]\n page_pool_release+0x507/0x6b0 net/core/page_pool.c:891\n page_pool_destroy+0x1ac/0x4c0 net/core/page_pool.c:956\n xdp_test_run_teardown net/bpf/test_run.c:216 [inline]\n bpf_test_run_xdp_live+0x1578/0x1af0 net/bpf/test_run.c:388\n bpf_prog_test_run_xdp+0x827/0x1530 net/bpf/test_run.c:1254\n bpf_prog_test_run kernel/bpf/syscall.c:4041 [inline]\n __sys_bpf+0x11bf/0x4920 kernel/bpf/syscall.c:5402\n __do_sys_bpf kernel/bpf/syscall.c:5488 [inline]\n __se_sys_bpf kernel/bpf/syscall.c:5486 [inline]\n __x64_sys_bpf+0x78/0xc0 kernel/bpf/syscall.c:5486\n\nFixes: 083772c9f972 (""net: page_pool: record pools per netdev"")\nReported-and-tested-by: syzbot+f9f8efb58a4db2ca98d0@syzkaller.appspotmail.com\nSigned-off-by: Eric Dumazet \nTested-by: Andrew Lunn \nLink: https://lore.kernel.org/r/20231130092259.3797753-1-edumazet@google.com\nSigned-off-by: Jakub Kicinski \n', '']",Fix protection fault issue in page_pool_unlist caused by missing netdev initialization.,"net, page_pool, fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['tc/netfilter like programs'] +f690ff9122d2ca8e38769f3bcf217bd3df681a36,f690ff9122d2ca8e38769f3bcf217bd3df681a36,Yujie Liu,yujie.liu@intel.com,1701315618,Daniel Borkmann,daniel@iogearbox.net,1701343053,50e26a16ffd821ff4715c363f22e9e230a4da3c7,b5145153a7f33e33f729ee67a11a8901a5609064,"bpf/tests: Remove duplicate JSGT tests + +It seems unnecessary that JSGT is tested twice (one before JSGE and one +after JSGE) since others are tested only once. Remove the duplicate JSGT +tests. + +Fixes: 0bbaa02b4816 (""bpf/tests: Add tests to check source register zero-extension"") +Signed-off-by: Yujie Liu +Signed-off-by: Daniel Borkmann +Acked-by: Johan Almbladh +Link: https://lore.kernel.org/bpf/20231130034018.2144963-1-yujie.liu@intel.com +",,The commit removes duplicate JSGT tests in the BPF test suite to avoid redundancy.,"JSGT,tests,duplicate",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0d47fa5cc91b9c8a0c90833bf1705048b2295714,0d47fa5cc91b9c8a0c90833bf1705048b2295714,Jakub Kicinski,kuba@kernel.org,1701315604,Jakub Kicinski,kuba@kernel.org,1701315604,d90f72f17b5c75dbdd67c344859984c8b8a1ec34,83f2df9d66bc9e1e0dbd5d5586a701088f6a1d42 51354f700d400e55b329361e1386b04695e6e5c1,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-11-30 + +We've added 5 non-merge commits during the last 7 day(s) which contain +a total of 10 files changed", 66 insertions(+),"[' 15 deletions(-).\n\nThe main changes are:\n\n1) Fix AF_UNIX splat from use after free in BPF sockmap', '\n from John Fastabend.\n\n2) Fix a syzkaller splat in netdevsim by properly handling offloaded\n programs (and not device-bound ones)', ' from Stanislav Fomichev.\n\n3) Fix bpf_mem_cache_alloc_flags() to initialize the allocation hint', '\n from Hou Tao.\n\n4) Fix netkit by rejecting IFLA_NETKIT_PEER_INFO in changelink', ""\n from Daniel Borkmann.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n bpf"", ' sockmap: Add af_unix test with both sockets in map\n bpf', "" sockmap: af_unix stream sockets need to hold ref for pair sock\n netkit: Reject IFLA_NETKIT_PEER_INFO in netkit_change_link\n bpf: Add missed allocation hint for bpf_mem_cache_alloc_flags()\n netdevsim: Don't accept device bound programs\n====================\n\nLink: https://lore.kernel.org/r/20231129234916.16128-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n"", '']",Merge a series of bpf updates from the last 7 days with changes to 10 files.,"merge, updates, bpf",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +51354f700d400e55b329361e1386b04695e6e5c1,51354f700d400e55b329361e1386b04695e6e5c1,John Fastabend,john.fastabend@gmail.com,1701221157,Daniel Borkmann,daniel@iogearbox.net,1701300325,608c6dca192498fb00374a535ad1083b0efa2ca1,8866730aed5100f06d3d965c22f1c61f74942541,bpf," sockmap: Add af_unix test with both sockets in map + +This adds a test where both pairs of a af_unix paired socket are put into a +BPF map. This ensures that when we tear down the af_unix pair we don't have +any issues on sockmap side with ordering and reference counting. + +Signed-off-by: John Fastabend +Signed-off-by: Daniel Borkmann +Reviewed-by: Jakub Sitnicki +Link: https://lore.kernel.org/bpf/20231129012557.95371-3-john.fastabend@gmail.com +",[''],Add a test for af_unix socket pairs in a BPF map to ensure no ordering or reference counting issues.,"af_unix,bpf map,sockmap",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +8866730aed5100f06d3d965c22f1c61f74942541,8866730aed5100f06d3d965c22f1c61f74942541,John Fastabend,john.fastabend@gmail.com,1701221156,Daniel Borkmann,daniel@iogearbox.net,1701300316,66fd1fbd894a628549f2c42e841f43b89e4bce1e,0bad281d0ecdf8391b0f42678b663336e7c3ceb0,bpf," sockmap: af_unix stream sockets need to hold ref for pair sock + +AF_UNIX stream sockets are a paired socket. So sending on one of the pairs +will lookup the paired socket as part of the send operation. It is possible +however to put just one of the pairs in a BPF map. This currently increments +the refcnt on the sock in the sockmap to ensure it is not free'd by the +stack before sockmap cleans up its state and stops any skbs being sent/recv'd +to that socket. + +But we missed a case. If the peer socket is closed it will be free'd by the +stack. However","["" the paired socket can still be referenced from BPF sockmap\nside because we hold a reference there. Then if we are sending traffic through\nBPF sockmap to that socket it will try to dereference the free'd pair in its\nsend logic creating a use after free. And following splat:\n\n [59.900375] BUG: KASAN: slab-use-after-free in sk_wake_async+0x31/0x1b0\n [59.901211] Read of size 8 at addr ffff88811acbf060 by task kworker/1:2/954\n [...]\n [59.905468] Call Trace:\n [59.905787] \n [59.906066] dump_stack_lvl+0x130/0x1d0\n [59.908877] print_report+0x16f/0x740\n [59.910629] kasan_report+0x118/0x160\n [59.912576] sk_wake_async+0x31/0x1b0\n [59.913554] sock_def_readable+0x156/0x2a0\n [59.914060] unix_stream_sendmsg+0x3f9/0x12a0\n [59.916398] sock_sendmsg+0x20e/0x250\n [59.916854] skb_send_sock+0x236/0xac0\n [59.920527] sk_psock_backlog+0x287/0xaa0\n\nTo fix let BPF sockmap hold a refcnt on both the socket in the sockmap and its\npaired socket. It wasn't obvious how to contain the fix to bpf_unix logic. The\nprimarily problem with keeping this logic in bpf_unix was: In the sock close()\nwe could handle the deref by having a close handler. But"", ' when we are destroying\nthe psock through a map delete operation we wouldn\'t have gotten any signal\nthorugh the proto struct other than it being replaced. If we do the deref from\nthe proto replace its too early because we need to deref the sk_pair after the\nbacklog worker has been stopped.\n\nGiven all this it seems best to just cache it at the end of the psock and eat 8B\nfor the af_unix and vsock users. Notice dgram sockets are OK because they handle\nlocking already.\n\nFixes: 94531cfcbe79 (""af_unix: Add unix_stream_proto for sockmap"")\nSigned-off-by: John Fastabend \nSigned-off-by: Daniel Borkmann \nReviewed-by: Jakub Sitnicki \nLink: https://lore.kernel.org/bpf/20231129012557.95371-2-john.fastabend@gmail.com\n', '']",Fix issue with AF_UNIX stream sockets in sockmap by handling peer socket closure.,"AF_UNIX, sockmap, refcnt",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['socket like programs'] +b5145153a7f33e33f729ee67a11a8901a5609064,b5145153a7f33e33f729ee67a11a8901a5609064,Alexei Starovoitov,ast@kernel.org,1701298781,Alexei Starovoitov,ast@kernel.org,1701298781,a20ef3fd347f9419cbf9006016b3b3bf7358381c,40d0eb0259ae77ace3e81d7454d1068c38bc95c2 60523115c1b10c8855492d84c1ba88af452e221c,"Merge branch 'xsk-tx-metadata' + +Stanislav Fomichev says: + +==================== +xsk: TX metadata + +This series implements initial TX metadata (offloads) for AF_XDP. +See patch #2 for the main implementation and mlx5/stmmac ones for the +example on how to consume the metadata on the device side. + +Starting with two types of offloads: +- request TX timestamp (and write it back into the metadata area) +- request TX checksum offload + +Changes since v5: +- preserve xsk_tx_metadata flags across tx and completion by moving + them out of 'request' union (Jesper) +- fix xdp_metadata checksum failure in big endian (Alexei) +- add SPDX to xdp-rx-metadata.rst (Simon) + +v5: https://lore.kernel.org/bpf/20231102225837.1141915-1-sdf@google.com/ + +Performance (mlx5): + +I've implemented a small xskgen tool to try to saturate single tx queue: +https://github.com/fomichev/xskgen/tree/master + +Here are the performance numbers with some analysis. + +1. Baseline. Running with commit eb62e6aef940 (""Merge branch 'bpf: +Support bpf_get_func_ip helper in uprobes'"")"," nothing from this series: + +- with 1400 bytes of payload: 98 gbps","[' 8 mpps\n./xskgen -s 1400 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 116960000000 bits', ' took 1.189130 sec', ' 98.357623 gbps 8.409509 mpps\n\n- with 200 bytes of payload: 49 gbps', ' 23 mpps\n./xskgen -s 200 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000064 packets 20960134144 bits', ' took 0.422235 sec', ' 49.640921 gbps 23.683645 mpps\n\n2. Adding single commit that supports reserving tx_metadata_len\n changes nothing numbers-wise.\n\n- baseline for 1400\n./xskgen -s 1400 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 116960000000 bits', ' took 1.189247 sec', ' 98.347946 gbps 8.408682 mpps\n\n- baseline for 200\n./xskgen -s 200 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 20960000000 bits', ' took 0.421248 sec', ' 49.756913 gbps 23.738985 mpps\n\n3. Adding -M flag causes xskgen to reserve the metadata and fill it', "" but\n doesn't set XDP_TX_METADATA descriptor option.\n\n- new baseline for 1400 (with only filling the metadata)\n./xskgen -M -s 1400 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 116960000000 bits"", ' took 1.188767 sec', ' 98.387657 gbps 8.412077 mpps\n\n- new baseline for 200 (with only filling the metadata)\n./xskgen -M -s 200 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 20960000000 bits', ' took 0.410213 sec', ' 51.095407 gbps 24.377579 mpps\n(the numbers go sligtly up here', ' not really sure why', ' maybe some cache-related\nside-effects?\n\n4. Next', ' I\'m running the same test but with the commit that adds actual\n general infra to parse XDP_TX_METADATA (but no driver support).\n Essentially applying ""xsk: add TX timestamp and TX checksum offload support""\n from this series. Numbers are the same.\n\n- fill metadata for 1400\n./xskgen -M -s 1400 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 116960000000 bits', ' took 1.188430 sec', ' 98.415557 gbps 8.414463 mpps\n\n- fill metadata for 200\n./xskgen -M -s 200 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 20960000000 bits', ' took 0.411559 sec', ' 50.928299 gbps 24.297853 mpps\n\n- request metadata for 1400\n./xskgen -m -s 1400 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 116960000000 bits', ' took 1.188723 sec', ' 98.391299 gbps 8.412389 mpps\n\n- request metadata for 200\n./xskgen -m -s 200 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000064 packets 20960134144 bits', ' took 0.411240 sec', ' 50.968131 gbps 24.316856 mpps\n\n5. Now', ' for the most interesting part', "" I'm adding mlx5 driver support.\n The mpps for 200 bytes case goes down from 23 mpps to 19 mpps"", ' but\n _only_ when I enable the metadata. This looks like a side effect\n of me pushing extra metadata pointer via mlx5e_xdpi_fifo_push.\n Hence', "" this part is wrapped into 'if (xp_tx_metadata_enabled)'\n to not affect the existing non-metadata use-cases. Since this is not\n regressing existing workloads"", "" I'm not spending any time trying to\n optimize it more (and leaving it up to mlx owners to purse if\n they see any good way to do it).\n\n- same baseline\n./xskgen -s 1400 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 116960000000 bits"", ' took 1.189434 sec', ' 98.332484 gbps 8.407360 mpps\n\n./xskgen -s 200 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000128 packets 20960268288 bits', ' took 0.425254 sec', ' 49.288821 gbps 23.515659 mpps\n\n- fill metadata for 1400\n./xskgen -M -s 1400 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 116960000000 bits', ' took 1.189528 sec', ' 98.324714 gbps 8.406696 mpps\n\n- fill metadata for 200\n./xskgen -M -s 200 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000128 packets 20960268288 bits', ' took 0.519085 sec', ' 40.379260 gbps 19.264914 mpps\n\n- request metadata for 1400\n./xskgen -m -s 1400 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000000 packets 116960000000 bits', ' took 1.189329 sec', ' 98.341165 gbps 8.408102 mpps\n\n- request metadata for 200\n./xskgen -m -s 200 -b eth3 10:70:fd:48:10:77 10:70:fd:48:10:87 fe80::1270:fdff:fe48:1077 fe80::1270:fdff:fe48:1087 1 1\nsent 10000128 packets 20960268288 bits', ' took 0.519929 sec', ' 40.313713 gbps 19.233642 mpps\n\nAcked-by: Magnus Karlsson \nAcked-by: Jakub Kicinski \n====================\n\nLink: https://lore.kernel.org/r/20231127190319.1190813-1-sdf@google.com\nSigned-off-by: Alexei Starovoitov \n', '']",Implements initial TX metadata offloads for AF_XDP including TX timestamp and checksum offloads.,"TX metadata, offloads, AF_XDP",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['xdp like programs'] +60523115c1b10c8855492d84c1ba88af452e221c,60523115c1b10c8855492d84c1ba88af452e221c,Stanislav Fomichev,sdf@google.com,1701111799,Alexei Starovoitov,ast@kernel.org,1701298781,a20ef3fd347f9419cbf9006016b3b3bf7358381c,12b4b7963d3cca253db3c31aa7611b988699e30f,"selftests/bpf: Add TX side to xdp_hw_metadata + +When we get a packet on port 9091"," we swap src/dst and send it out. +At this point we also request the timestamp and checksum offloads. + +Checksum offload is verified by looking at the tcpdump on the other side. +The tool prints pseudo-header csum and the final one it expects. +The final checksum actually matches the incoming packets checksum +because we only flip the src/dst and don't change the payload. + +Some other related changes: +- switched to zerocopy mode by default; new flag can be used to force + old behavior +- request fixed tx_metadata_len headroom +- some other small fixes (umem size","[' fill idx+i', ' etc)\n\nmvbz3:~# ./xdp_hw_metadata eth3\n...\nxsk_ring_cons__peek: 1\n0x19546f8: rx_desc[0]->addr=80100 addr=80100 comp_addr=80100\nrx_hash: 0x80B7EA8B with RSS type:0x2A\nrx_timestamp: 1697580171852147395 (sec:1697580171.8521)\nHW RX-time: 1697580171852147395 (sec:1697580171.8521)', ' delta to User RX-time sec:0.2797 (279673.082 usec)\nXDP RX-time: 1697580172131699047 (sec:1697580172.1317)', ' delta to User RX-time sec:0.0001 (121.430 usec)\n0x19546f8: ping-pong with csum=3b8e (want d862) csum_start=54 csum_offset=6\n0x19546f8: complete tx idx=0 addr=8\ntx_timestamp: 1697580172056756493 (sec:1697580172.0568)\nHW TX-complete-time: 1697580172056756493 (sec:1697580172.0568)', ' delta to User TX-complete-time sec:0.0852 (85175.537 usec)\nXDP RX-time: 1697580172131699047 (sec:1697580172.1317)', ' delta to User TX-complete-time sec:0.0102 (10232.983 usec)\nHW RX-time: 1697580171852147395 (sec:1697580171.8521)', ' delta to HW TX-complete-time sec:0.2046 (204609.098 usec)\n0x19546f8: complete rx idx=128 addr=80100\n\nmvbz4:~# nc -Nu -q1 ${MVBZ3_LINK_LOCAL_IP}%eth3 9091\n\nmvbz4:~# tcpdump -vvx -i eth3 udp\n tcpdump: listening on eth3', ' link-type EN10MB (Ethernet)', ' snapshot length 262144 bytes\n12:26:09.301074 IP6 (flowlabel 0x35fa5', ' hlim 127', ' next-header UDP (17) payload length: 11) fe80::1270:fdff:fe48:1087.55807 > fe80::1270:fdff:fe48:1077.9091: [bad udp cksum 0x3b8e -> 0xde7e!] UDP', ' length 3\n 0x0000: 6003 5fa5 000b 117f fe80 0000 0000 0000\n 0x0010: 1270 fdff fe48 1087 fe80 0000 0000 0000\n 0x0020: 1270 fdff fe48 1077 d9ff 2383 000b 3b8e\n 0x0030: 7864 70\n12:26:09.301976 IP6 (flowlabel 0x35fa5', ' hlim 127', ' next-header UDP (17) payload length: 11) fe80::1270:fdff:fe48:1077.9091 > fe80::1270:fdff:fe48:1087.55807: [udp sum ok] UDP', ' length 3\n 0x0000: 6003 5fa5 000b 117f fe80 0000 0000 0000\n 0x0010: 1270 fdff fe48 1077 fe80 0000 0000 0000\n 0x0020: 1270 fdff fe48 1087 2383 d9ff 000b de7e\n 0x0030: 7864 70\n\nSigned-off-by: Stanislav Fomichev \nLink: https://lore.kernel.org/r/20231127190319.1190813-14-sdf@google.com\nSigned-off-by: Alexei Starovoitov \n', '']","This commit adds TX functionality to xdp_hw_metadata selftests, including swapping src/dst and verifying checksum offloads.","xdp_hw_metadata,checksum,zerocopy",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['xdp like programs'] +12b4b7963d3cca253db3c31aa7611b988699e30f,12b4b7963d3cca253db3c31aa7611b988699e30f,Stanislav Fomichev,sdf@google.com,1701111798,Alexei Starovoitov,ast@kernel.org,1701298781,aea3b91f9f7e44a5a5a0ee22f40e3a4fe0bf162f,40808a237d9c8fcaa3eaeefe2ac59e4733907478,"selftests/bpf: Convert xdp_hw_metadata to XDP_USE_NEED_WAKEUP + +This is the recommended way to run AF_XDP"," so let's use it in the test. + +Also","[' some unrelated changes to now blow up the log too much:\n- change default mode to zerocopy and add -c to use copy mode\n- small fixes for the flags/sizes/prints\n- add print_tstamp_delta to print timestamp + reference\n\nSigned-off-by: Stanislav Fomichev \nLink: https://lore.kernel.org/r/20231127190319.1190813-13-sdf@google.com\nSigned-off-by: Alexei Starovoitov \n', '']",Convert selftests of xdp_hw_metadata to use XDP_USE_NEED_WAKEUP for AF_XDP.,"selftests, xdp_hw_metadata, XDP_USE_NEED_WAKEUP",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['xdp like programs'] +40808a237d9c8fcaa3eaeefe2ac59e4733907478,40808a237d9c8fcaa3eaeefe2ac59e4733907478,Stanislav Fomichev,sdf@google.com,1701111797,Alexei Starovoitov,ast@kernel.org,1701298781,0630bec77c29dfa97741ff59a7e8d067777865ba,f6642de0c3e94d3ef6f44e127d11fcf4138873f7,"selftests/bpf: Add TX side to xdp_metadata + +Request TX timestamp and make sure it's not empty. +Request TX checksum offload (SW-only) and make sure it's resolved +to the correct one. + +Signed-off-by: Stanislav Fomichev +Link: https://lore.kernel.org/r/20231127190319.1190813-12-sdf@google.com +Signed-off-by: Alexei Starovoitov +",,Add transmission side handling to xdp_metadata selftests and verify TX timestamp and checksum offload.,"xdp_metadata, TX timestamp, checksum offload",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['xdp like programs'] +f6642de0c3e94d3ef6f44e127d11fcf4138873f7,f6642de0c3e94d3ef6f44e127d11fcf4138873f7,Stanislav Fomichev,sdf@google.com,1701111796,Alexei Starovoitov,ast@kernel.org,1701298781,ed3f7280ac39e5502e48c08bbfff99e16467e896,df3ed0003ec4994ce8ed4818c435c481281df89e,"selftests/bpf: Add csum helpers + +Checksum helpers will be used to calculate pseudo-header checksum in +AF_XDP metadata selftests. + +The helpers are mirroring existing kernel ones: +- csum_tcpudp_magic : IPv4 pseudo header csum +- csum_ipv6_magic : IPv6 pseudo header csum +- csum_fold : fold csum and do one's complement + +Signed-off-by: Stanislav Fomichev +Link: https://lore.kernel.org/r/20231127190319.1190813-11-sdf@google.com +Signed-off-by: Alexei Starovoitov +",,Add checksum helpers for AF_XDP metadata selftests in BPF.,"checksum, helpers, AF_XDP",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['socket like programs'] +1347b419318d6afa1c86d7865d82ca0a6cdf30ce,1347b419318d6afa1c86d7865d82ca0a6cdf30ce,Song Yoong Siang,yoong.siang.song@intel.com,1701111791,Alexei Starovoitov,ast@kernel.org,1701298780,bde2e77272746023942585a6e19a6b8975e99db0,ec706a860eba99bf934d59f74b5db90af44e882e,"net: stmmac: Add Tx HWTS support to XDP ZC + +This patch enables transmit hardware timestamp support to XDP zero copy +via XDP Tx metadata framework. + +This patchset is tested with tools/testing/selftests/bpf/xdp_hw_metadata +on Intel Tiger Lake platform. Below are the test steps and results. + +Command on DUT: +sudo ./xdp_hw_metadata +sudo hwstamp_ctl -i -t 1 -r 1 + +Command on Link Partner: +echo -n xdp | nc -u -q1 9091 + +Result: +xsk_ring_cons__peek: 1 +0x55bbbf08b6d0: rx_desc[2]->addr=8c100 addr=8c100 comp_addr=8c100 EoP +No rx_hash err=-95 +rx_timestamp: 1677762688429141540 (sec:1677762688.4291) +HW RX-time: 1677762688429141540 (sec:1677762688.4291) delta to User RX-time sec:0.0003 (250.665 usec) +XDP RX-time: 1677762688429375597 (sec:1677762688.4294) delta to User RX-time sec:0.0000 (16.608 usec) +0x55bbbf08b6d0: ping-pong with csum=561c (want f488) csum_start=34 csum_offset=6 +0x55bbbf08b6d0: complete tx idx=2 addr=2008 +tx_timestamp: 1677762688431127273 (sec:1677762688.4311) +HW TX-complete-time: 1677762688431127273 (sec:1677762688.4311) delta to User TX-complete-time sec:0.0083 (8331.655 usec) +XDP RX-time: 1677762688429375597 (sec:1677762688.4294) delta to User TX-complete-time sec:0.0101 (10083.331 usec) +HW RX-time: 1677762688429141540 (sec:1677762688.4291) delta to HW TX-complete-time sec:0.0020 (1985.733 usec) +0x55bbbf08b6d0: complete rx idx=130 addr=8c100 + +Signed-off-by: Song Yoong Siang +Signed-off-by: Stanislav Fomichev +Link: https://lore.kernel.org/r/20231127190319.1190813-6-sdf@google.com +Signed-off-by: Alexei Starovoitov +",,The commit adds transmit hardware timestamp support to XDP zero copy in the stmmac driver.,"XDP,timestamp,stmmac",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['xdp like programs'] +40d0eb0259ae77ace3e81d7454d1068c38bc95c2,40d0eb0259ae77ace3e81d7454d1068c38bc95c2,Andrii Nakryiko,andrii@kernel.org,1701238529,Andrii Nakryiko,andrii@kernel.org,1701238530,0ce3896096bf17db577b084f544e8aa5b69335f1,d4e7dd4842b190e87a5b7179a460f54b13da3ac4 8998a479fd96b0b209dcb2feb468eba7eddb4ddb,"Merge branch 'selftests-bpf-use-pkg-config-to-determine-ld-flags' + +Akihiko Odaki says: + +==================== +selftests/bpf: Use pkg-config to determine ld flags + +When linking statically"," libraries may require other dependencies to be +included to ld flags. In particular","[' libelf may require libzstd. Use\npkg-config to determine such dependencies.\n\nV4 -> V5: Introduced variables LIBELF_CFLAGS and LIBELF_LIBS.\n (Daniel Borkmann)\n Added patch ""selftests/bpf: Choose pkg-config for the target"".\nV3 -> V4: Added ""2> /dev/null"".\nV2 -> V3: Added missing ""echo"".\nV1 -> V2: Implemented fallback', ' referring to HOSTPKG_CONFIG.\n====================\n\nLink: https://lore.kernel.org/r/20231125084253.85025-1-akihiko.odaki@daynix.com\nSigned-off-by: Andrii Nakryiko \n', '']",Use pkg-config for determining ld flags in selftests/bpf linking process.,"pkg-config, ld flags, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +8998a479fd96b0b209dcb2feb468eba7eddb4ddb,8998a479fd96b0b209dcb2feb468eba7eddb4ddb,Akihiko Odaki,akihiko.odaki@daynix.com,1700901772,Andrii Nakryiko,andrii@kernel.org,1701238529,0ce3896096bf17db577b084f544e8aa5b69335f1,18f6f9de98d1d0f7040e6e6c39fce8939f55520f,"selftests/bpf: Use pkg-config for libelf + +When linking statically"," libraries may require other dependencies to be +included to ld flags. In particular","[' libelf may require libzstd. Use\npkg-config to determine such dependencies.\n\nSigned-off-by: Akihiko Odaki \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231125084253.85025-4-akihiko.odaki@daynix.com\n', '']",The commit updates selftests/bpf to use pkg-config for obtaining libelf dependencies when linking statically.,"selftests,bpf,libelf",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +18f6f9de98d1d0f7040e6e6c39fce8939f55520f,18f6f9de98d1d0f7040e6e6c39fce8939f55520f,Akihiko Odaki,akihiko.odaki@daynix.com,1700901771,Andrii Nakryiko,andrii@kernel.org,1701238529,fbf3c868350fef8bbf5d167b133d499a9d348fa1,2ce344b6891618063c0bebe22d9cdf9c086e0aa8,"selftests/bpf: Override PKG_CONFIG for static builds + +A library may need to depend on additional archive files for static +builds so pkg-config should be instructed to list them. + +Signed-off-by: Akihiko Odaki +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231125084253.85025-3-akihiko.odaki@daynix.com +",,Override PKG_CONFIG for static builds in selftests for enhanced library dependency handling.,"static, PKG_CONFIG, selftests",It's a build system or CI/CD change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +2ce344b6891618063c0bebe22d9cdf9c086e0aa8,2ce344b6891618063c0bebe22d9cdf9c086e0aa8,Akihiko Odaki,akihiko.odaki@daynix.com,1700901770,Andrii Nakryiko,andrii@kernel.org,1701238529,044a6da576331c259cbb5941fb66cf451928e2cc,d4e7dd4842b190e87a5b7179a460f54b13da3ac4,"selftests/bpf: Choose pkg-config for the target + +pkg-config is used to build sign-file executable. It should use the +library for the target instead of the host as it is called during tests. + +Signed-off-by: Akihiko Odaki +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231125084253.85025-2-akihiko.odaki@daynix.com +",,The commit updates selftests to use pkg-config for the target during tests instead of the host.,"selftests,pkg-config,target",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +d4e7dd4842b190e87a5b7179a460f54b13da3ac4,d4e7dd4842b190e87a5b7179a460f54b13da3ac4,Andrii Nakryiko,andrii@kernel.org,1701237010,Andrii Nakryiko,andrii@kernel.org,1701237010,d7b96a4e60e1de0d7d151849a505efc0b4c705f2,cf9791631027a476f7cdb0e1b3ac6add16eff264 a7795698f8b6c48283fa4334eb313bc1350b2864,"Merge branch 'bpf-add-link_info-support-for-uprobe-multi-link' + +Jiri Olsa says: + +==================== +bpf: Add link_info support for uprobe multi link + +hi"," +this patchset adds support to get bpf_link_info details for +uprobe_multi links and adding support for bpftool link to +display them. + +v4 changes: + - move flags field up in bpf_uprobe_multi_link [Andrii] + - include zero terminating byte in path_size [Andrii] + - return d_path error directly [Yonghong] + - use SEC("".probes"") for semaphores [Yonghong] + - fix ref_ctr_offsets leak in test [Yonghong] + - other smaller fixes [Yonghong] + +thanks","['\njirka\n---\n====================\n\nLink: https://lore.kernel.org/r/20231125193130.834322-1-jolsa@kernel.org\nSigned-off-by: Andrii Nakryiko \n', '']",Enhances bpf_link_info with support for uprobe multi-link and updates bpftool link display.,"uprobe, bpf_link_info, bpftool",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +a7795698f8b6c48283fa4334eb313bc1350b2864,a7795698f8b6c48283fa4334eb313bc1350b2864,Jiri Olsa,jolsa@kernel.org,1700940690,Andrii Nakryiko,andrii@kernel.org,1701237009,d7b96a4e60e1de0d7d151849a505efc0b4c705f2,147c69307bcf67f1f01246f9acb794da9837f299,"bpftool: Add support to display uprobe_multi links + +Adding support to display details for uprobe_multi links"," +both plain: + + # bpftool link -p + ... + 24: uprobe_multi prog 126 + uprobe.multi path /home/jolsa/bpf/test_progs func_cnt 3 pid 4143 + offset ref_ctr_offset cookies + 0xd1f88 0xf5d5a8 0xdead + 0xd1f8f 0xf5d5aa 0xbeef + 0xd1f96 0xf5d5ac 0xcafe + +and json: + + # bpftool link -p + [{ + ... + }","['{\n ""id"": 24', '\n ""type"": ""uprobe_multi""', '\n ""prog_id"": 126', '\n ""retprobe"": false', '\n ""path"": ""/home/jolsa/bpf/test_progs""', '\n ""func_cnt"": 3', '\n ""pid"": 4143', '\n ""funcs"": [{\n ""offset"": 860040', '\n ""ref_ctr_offset"": 16111016', '\n ""cookie"": 57005\n }', '{\n ""offset"": 860047', '\n ""ref_ctr_offset"": 16111018', '\n ""cookie"": 48879\n }', '{\n ""offset"": 860054', '\n ""ref_ctr_offset"": 16111020', '\n ""cookie"": 51966\n }\n ]\n }\n ]\n\nSigned-off-by: Jiri Olsa \nSigned-off-by: Andrii Nakryiko \nReviewed-by: Quentin Monnet \nAcked-by: Song Liu \nLink: https://lore.kernel.org/bpf/20231125193130.834322-7-jolsa@kernel.org\n', '']",Added support in bpftool to display details for uprobe_multi links.,"bpftool, uprobe_multi, links",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,['kprobe/uprobe/ftrace like programs'] +147c69307bcf67f1f01246f9acb794da9837f299,147c69307bcf67f1f01246f9acb794da9837f299,Jiri Olsa,jolsa@kernel.org,1700940689,Andrii Nakryiko,andrii@kernel.org,1701237009,d0c2e8df90ff8558fb0b081b24ba227d426cf80d,1703612885723869064f18e8816c6f3f87987748,"selftests/bpf: Add link_info test for uprobe_multi link + +Adding fill_link_info test for uprobe_multi link. + +Setting up uprobes with bogus ref_ctr_offsets and cookie values +to test all the bpf_link_info::uprobe_multi fields. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Song Liu +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20231125193130.834322-6-jolsa@kernel.org +",,Add and test link_info for uprobe_multi link in BPF selftests.,"uprobe_multi, bpf_link_info, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +1703612885723869064f18e8816c6f3f87987748,1703612885723869064f18e8816c6f3f87987748,Jiri Olsa,jolsa@kernel.org,1700940688,Andrii Nakryiko,andrii@kernel.org,1701237009,8fb956a4f362b70c73e4cd71d5b803bb1a5ec151,e56fdbfb06e26a7066b070967badef4148528df2,"selftests/bpf: Use bpf_link__destroy in fill_link_info tests + +The fill_link_info test keeps skeleton open and just creates +various links. We are wrongly calling bpf_link__detach after +each test to close them"," we need to call bpf_link__destroy. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: Yafang Shao +Link: https://lore.kernel.org/bpf/20231125193130.834322-5-jolsa@kernel.org +",[''],The commit updates fill_link_info tests to use bpf_link__destroy instead of bpf_link__detach to properly close links.,"test update, bpf_link__destroy, fill_link_info",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e56fdbfb06e26a7066b070967badef4148528df2,e56fdbfb06e26a7066b070967badef4148528df2,Jiri Olsa,jolsa@kernel.org,1700940687,Andrii Nakryiko,andrii@kernel.org,1701237009,beb6f242eaecc16d3f1db0732fdaae0618df552e,4930b7f53a298533bc31d7540b6ea8b79a000331,"bpf: Add link_info support for uprobe multi link + +Adding support to get uprobe_link details through bpf_link_info +interface. + +Adding new struct uprobe_multi to struct bpf_link_info to carry +the uprobe_multi link details. + +The uprobe_multi.count is passed from user space to denote size +of array fields (offsets/ref_ctr_offsets/cookies). The actual +array size is stored back to uprobe_multi.count (allowing user +to find out the actual array size) and array fields are populated +up to the user passed size. + +All the non-array fields (path/count/flags/pid) are always set. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/bpf/20231125193130.834322-4-jolsa@kernel.org +",,Added support for uprobe multi link details in bpf_link_info interface.,"uprobe,multi link,bpf_link_info",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +4930b7f53a298533bc31d7540b6ea8b79a000331,4930b7f53a298533bc31d7540b6ea8b79a000331,Jiri Olsa,jolsa@kernel.org,1700940686,Andrii Nakryiko,andrii@kernel.org,1701237009,9356c7fa6715d3c6c50b4d0b403cec9706cb8333,48f0dfd8d3e212ab27b6db147ed10407ff6aaa88,"bpf: Store ref_ctr_offsets values in bpf_uprobe array + +We will need to return ref_ctr_offsets values through link_info +interface in following change"," so we need to keep them around. + +Storing ref_ctr_offsets values directly into bpf_uprobe array. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Acked-by: Song Liu +Link: https://lore.kernel.org/bpf/20231125193130.834322-3-jolsa@kernel.org +",[''],The commit stores ref_ctr_offsets values in the bpf_uprobe array for future link_info interface usage.,"ref_ctr_offsets, bpf_uprobe, link_info",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['kprobe/uprobe/ftrace like programs'] +48f0dfd8d3e212ab27b6db147ed10407ff6aaa88,48f0dfd8d3e212ab27b6db147ed10407ff6aaa88,Jiri Olsa,jolsa@kernel.org,1700940685,Andrii Nakryiko,andrii@kernel.org,1701237009,346ef8da903564feb9d80aba778b6a8684ea69cf,cf9791631027a476f7cdb0e1b3ac6add16eff264,"libbpf: Add st_type argument to elf_resolve_syms_offsets function + +We need to get offsets for static variables in following changes"," +so making elf_resolve_syms_offsets to take st_type value as argument +and passing it to elf_sym_iter_new. + +Signed-off-by: Jiri Olsa +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Acked-by: Song Liu +Link: https://lore.kernel.org/bpf/20231125193130.834322-2-jolsa@kernel.org +",[''],Add st_type argument to elf_resolve_syms_offsets in libbpf for static variable offsets.,"libbpf, elf_resolve_syms_offsets, st_type",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a79d8ba734bdbd2574ad16dd1b96506e5f642c4a,a79d8ba734bdbd2574ad16dd1b96506e5f642c4a,Pedro Tammela,pctammela@mojatatu.com,1700840564,Jakub Kicinski,kuba@kernel.org,1701137742,1b4bb920a3b6025c6444bcf1b41078be6d3b2b51,cae0de45c8fd62612e1ee429134fd82c2c0e335e,"selftests: tc-testing: remove buildebpf plugin + +As tdc only tests loading/deleting and anything more complicated is +better left to the ebpf test suite"," provide a pre-compiled version of +'action.c' and don't bother compiling it in kselftests or on the fly +at all. + +Cc: Davide Caratti +Signed-off-by: Pedro Tammela +Acked-by: Jamal Hadi Salim +Link: https://lore.kernel.org/r/20231124154248.315470-2-pctammela@mojatatu.com +Signed-off-by: Jakub Kicinski +",[''],Remove buildebpf plugin from tc-testing as complex tasks are handled by the ebpf test suite.,"buildebpf, tc-testing, selftests",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tc/netfilter like programs'] +cf9791631027a476f7cdb0e1b3ac6add16eff264,cf9791631027a476f7cdb0e1b3ac6add16eff264,Stanislav Fomichev,sdf@google.com,1701109257,Martin KaFai Lau,martin.lau@kernel.org,1701131024,6db3e1c51b10b4e9c53a7451319d02bcebf70eba,876843ce1e4897e8ceade50bfa3d9a4ec483abf3,"selftests/bpf: update test_offload to use new orphaned property + +- filter orphaned programs by default +- when trying to query orphaned program"," don't expect bpftool failure + +Cc: netdev@vger.kernel.org +Signed-off-by: Stanislav Fomichev +Link: https://lore.kernel.org/r/20231127182057.1081138-2-sdf@google.com +Signed-off-by: Martin KaFai Lau +",[''],Update selftests to use a new orphaned property for offload testing in BPF.,"selftests, offload, orphaned",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +876843ce1e4897e8ceade50bfa3d9a4ec483abf3,876843ce1e4897e8ceade50bfa3d9a4ec483abf3,Stanislav Fomichev,sdf@google.com,1701109256,Martin KaFai Lau,martin.lau@kernel.org,1701131018,ecf7a17de846ca0963c22ed2ad89bc4709245956,b16904fd9f01b580db357ef2b1cc9e86d89576c2,"bpftool: mark orphaned programs during prog show + +Commit ef01f4e25c17 (""bpf: restore the ebpf program ID for BPF_AUDIT_UNLOAD +and PERF_BPF_EVENT_PROG_UNLOAD"") stopped removing program's id from +idr when the offloaded/bound netdev goes away. I was supposed to +take a look and check in [0]"," but apparently I did not. + +Martin points out it might be useful to keep it that way for +observability sake","[' but we at least need to mark those programs as\nunusable.\n\nMark those programs as \'orphaned\' and keep printing the list when\nwe encounter ENODEV.\n\n0: unspec tag 0000000000000000\n xlated 0B not jited memlock 4096B orphaned\n\n[0]: https://lore.kernel.org/all/CAKH8qBtyR20ZWAc11z1-6pGb3Hd47AQUTbE_cfoktG59TqaJ7Q@mail.gmail.com/\n\nv3:\n* use two spaces for "" orphaned"" (Quentin)\n\nCc: netdev@vger.kernel.org\nFixes: ef01f4e25c17 (""bpf: restore the ebpf program ID for BPF_AUDIT_UNLOAD and PERF_BPF_EVENT_PROG_UNLOAD"")\nSigned-off-by: Stanislav Fomichev \nReviewed-by: Quentin Monnet \nLink: https://lore.kernel.org/r/20231127182057.1081138-1-sdf@google.com\nSigned-off-by: Martin KaFai Lau \n', '']",This commit marks orphaned programs during 'prog show' in bpftool for improved observability.,"orphaned, bpftool, observability",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0bad281d0ecdf8391b0f42678b663336e7c3ceb0,0bad281d0ecdf8391b0f42678b663336e7c3ceb0,Daniel Borkmann,daniel@iogearbox.net,1701115533,Martin KaFai Lau,martin.lau@kernel.org,1701130054,d6a13a746e74f4a8f848216427f189e79b4db30c,75a442581d05edaee168222ffbe00d4389785636,"netkit: Reject IFLA_NETKIT_PEER_INFO in netkit_change_link + +The IFLA_NETKIT_PEER_INFO attribute can only be used during device +creation"," but not via changelink callback. Hence reject it there. + +Fixes: 35dfaad7188c (""netkit","[' bpf: Add bpf programmable net device"")\nSigned-off-by: Daniel Borkmann \nAcked-by: Nikolay Aleksandrov \nCc: Jakub Kicinski \nReviewed-by: Jakub Kicinski \nLink: https://lore.kernel.org/r/e86a277a1e8d3b19890312779e42f790b0605ea4.1701115314.git.daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']",Reject inappropriate use of IFLA_NETKIT_PEER_INFO in netkit_change_link.,"netkit, ifla_netkit_peer_info, changelink",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1638b11ef8156c8551f5aaa5799069633593c5fe,1638b11ef8156c8551f5aaa5799069633593c5fe,Athira Rajeev,atrajeev@linux.vnet.ibm.com,1700755352,Arnaldo Carvalho de Melo,acme@redhat.com,1701096513,b3e6e94e8957720fe2304f630396b80dba582569,5ebe2f4bf0a8fe8cceb5664a7dea4c17e2cf8477,"perf tools: Add perf binary dependent rule for shellcheck log in Makefile.perf + +Add rule in new Makefile ""tests/Makefile.tests"" for running shellcheck +on shell test scripts. This automates below shellcheck into the build. + + $ for F in $(find tests/shell/ -perm -o=x -name '*.sh'); do shellcheck -S warning $F; done + +Condition for shellcheck is added in Makefile.perf to avoid build +breakage in the absence of shellcheck binary. Update Makefile.perf to +contain new rule for ""SHELLCHECK_TEST"" which is for making shellcheck +test as a dependency on perf binary. + +Added ""tests/Makefile.tests"" to run shellcheck on shellscripts in +tests/shell. The make rule ""SHLLCHECK_RUN"" ensures that"," every time +during make","[' shellcheck will be run only on modified files during\nsubsequent invocations. By this', ' if any newly added shell scripts or\nfixes in existing scripts breaks coding/formatting style', ' it will get\ncaptured during the perf build.\n\nExample build failure by modifying probe_vfs_getname.sh in tests/shell:\n\n\tIn tests/shell/probe_vfs_getname.sh line 8:\n\t. $(dirname $0)/lib/probe.sh\n\t ^-----------^ SC2046 (warning): Quote this to prevent word splitting.\n\n\tFor more information:\n\t https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt...\n\tmake[3]: *** [/root/athira/perf-tools-next/tools/perf/tests/Makefile.tests:18: tests/shell/.probe_vfs_getname.sh.shellcheck_log] Error 1\n\tmake[2]: *** [Makefile.perf:686: SHELLCHECK_TEST] Error 2\n\tmake[2]: *** Waiting for unfinished jobs....\n\tmake[1]: *** [Makefile.perf:244: sub-make] Error 2\n\tmake: *** [Makefile:70: all] Error 2\n\nHere', ' like other files which gets created during compilation (ex:\n.builtin-bench.o.cmd or .perf.o.cmd )', ' create .shellcheck_log also as a\nhidden file. Example: tests/shell/.probe_vfs_getname.sh.shellcheck_log\nshellcheck is re-run if any of the script gets modified based on its\ndependency of this log file.\n\nAfter this', ' for testing', ' changed ""tests/shell/trace+probe_vfs_getname.sh"" to\nbreak shellcheck format. In the next make run', ' it is also captured:\n\n\tIn tests/shell/probe_vfs_getname.sh line 8:\n\t. $(dirname $0)/lib/probe.sh\n\t ^-----------^ SC2046 (warning): Quote this to prevent word splitting.\n\n\tFor more information:\n\t https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt...\n\tmake[3]: *** [/root/athira/perf-tools-next/tools/perf/tests/Makefile.tests:18: tests/shell/.probe_vfs_getname.sh.shellcheck_log] Error 1\n\tmake[3]: *** Waiting for unfinished jobs....\n\n\tIn tests/shell/trace+probe_vfs_getname.sh line 14:\n\t. $(dirname $0)/lib/probe.sh\n\t ^-----------^ SC2046 (warning): Quote this to prevent word splitting.\n\n\tFor more information:\n\t https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt...\n\tmake[3]: *** [/root/athira/perf-tools-next/tools/perf/tests/Makefile.tests:18: tests/shell/.trace+probe_vfs_getname.sh.shellcheck_log] Error 1\n\tmake[2]: *** [Makefile.perf:686: SHELLCHECK_TEST] Error 2\n\tmake[2]: *** Waiting for unfinished jobs....\n\tmake[1]: *** [Makefile.perf:244: sub-make] Error 2\n\tmake: *** [Makefile:70: all] Error 2\n\nFailure log can be found in the stdout of make itself.\n\nThis is reported at build time. To be able to go ahead with the build or\ndisable shellcheck even though it is known that some test is broken', ' add\na ""NO_SHELLCHECK"" option. Example:\n\n make NO_SHELLCHECK=1\n\n\t INSTALL libsubcmd_headers\n\t INSTALL libsymbol_headers\n\t INSTALL libapi_headers\n\t INSTALL libperf_headers\n\t INSTALL libbpf_headers\n\t LINK perf\n\nNote:\n\nThis is tested on RHEL and also SLES. Use below check:\n""$(shell which shellcheck 2> /dev/null)"" to look for presence\nof shellcheck binary. The approach ""shell command -v"" is not\nused here. In some of the distros(RHEL)', ' command is available\nas executable file (/usr/bin/command). But in some distros(SLES)', '\nit is a shell builtin and not available as executable file.\n\nCommitter testing:\n\n $ type shellcheck\n shellcheck is hashed (/usr/bin/shellcheck)\n $ rpm -qf /usr/bin/shellcheck\n ShellCheck-0.9.0-2.fc38.x86_64\n $\n $ alias m\n $ git diff\n diff --git a/tools/perf/tests/shell/probe_vfs_getname.sh b/tools/perf/tests/shell/probe_vfs_getname.sh\n index 554e12e83c55fd56..dbc14634678e2bf6 100755\n --- a/tools/perf/tests/shell/probe_vfs_getname.sh\n +++ b/tools/perf/tests/shell/probe_vfs_getname.sh\n @@ -5', '7 +5', '7 @@\n # Arnaldo Carvalho de Melo ', ' 2017\n\n # shellcheck source=lib/probe.sh\n -. ""$(dirname $0)""/lib/probe.sh\n +. $(dirname $0)/lib/probe.sh\n\n skip_if_no_perf_probe || exit 2\n\n alias m=\'rm -rf ~/libexec/perf-core/ ; make -k CORESIGHT=1 O=/tmp/build/$(basename $PWD) -C tools/perf install-bin && perf test python\'\n $ m\n make: Entering directory \'/home/acme/git/perf-tools-next/tools/perf\'\n BUILD: Doing \'make -j32\' parallel build\n\n INSTALL libbpf_headers\n\n In tests/shell/probe_vfs_getname.sh line 8:\n . $(dirname $0)/lib/probe.sh\n ^-----------^ SC2046 (warning): Quote this to prevent word splitting.\n\n For more information:\n https://www.shellcheck.net/wiki/SC2046 -- Quote this to prevent word splitt...\n make[3]: *** [/home/acme/git/perf-tools-next/tools/perf/tests/Makefile.tests:18: tests/shell/.probe_vfs_getname.sh.shellcheck_log] Error 1\n make[2]: *** [Makefile.perf:686: SHELLCHECK_TEST] Error 2\n make[2]: *** Waiting for unfinished jobs....\n make[1]: *** [Makefile.perf:244: sub-make] Error 2\n make: *** [Makefile:113: install-bin] Error 2\n make: Leaving directory \'/home/acme/git/perf-tools-next/tools/perf\'\n $\n\nReviewed-by: James Clark \nSigned-off-by: Athira Jajeev \nTested-by: Arnaldo Carvalho de Melo \nCc: Adrian Hunter \nCc: Disha Goel \nCc: Ian Rogers \nCc: Jiri Olsa \nCc: Kajol Jain \nCc: Madhavan Srinivasan \nCc: Namhyung Kim \nCc: linuxppc-dev@lists.ozlabs.org\nLink: https://lore.kernel.org/r/20231123160232.94253-1-atrajeev@linux.vnet.ibm.com\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",Added a rule in Makefile to run shellcheck on shell scripts and prevent build breakage if the shellcheck binary is missing.,"shellcheck, Makefile, tests",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +b16904fd9f01b580db357ef2b1cc9e86d89576c2,b16904fd9f01b580db357ef2b1cc9e86d89576c2,Yonghong Song,yonghong.song@linux.dev,1701061422,Daniel Borkmann,daniel@iogearbox.net,1701093219,d09f1e29a712d5b694f206b2b6023fe2fbe1dc34,e8a339b5235e294f29153149ea7cf26a9a87dbea,"bpf: Fix a few selftest failures due to llvm18 change + +With latest upstream llvm18"," the following test cases failed: + + $ ./test_progs -j + #13/2 bpf_cookie/multi_kprobe_link_api:FAIL + #13/3 bpf_cookie/multi_kprobe_attach_api:FAIL + #13 bpf_cookie:FAIL + #77 fentry_fexit:FAIL + #78/1 fentry_test/fentry:FAIL + #78 fentry_test:FAIL + #82/1 fexit_test/fexit:FAIL + #82 fexit_test:FAIL + #112/1 kprobe_multi_test/skel_api:FAIL + #112/2 kprobe_multi_test/link_api_addrs:FAIL + [...] + #112 kprobe_multi_test:FAIL + #356/17 test_global_funcs/global_func17:FAIL + #356 test_global_funcs:FAIL + +Further analysis shows llvm upstream patch [1] is responsible for the above +failures. For example","[' for function bpf_fentry_test7() in net/bpf/test_run.c', '\nwithout [1]', ' the asm code is:\n\n 0000000000000400 :\n 400: f3 0f 1e fa endbr64\n 404: e8 00 00 00 00 callq 0x409 \n 409: 48 89 f8 movq %rdi', ' %rax\n 40c: c3 retq\n 40d: 0f 1f 00 nopl (%rax)\n\n... and with [1]', ' the asm code is:\n\n 0000000000005d20 :\n 5d20: e8 00 00 00 00 callq 0x5d25 \n 5d25: c3 retq\n\n... and is called instead of \nand this caused test failures for #13/#77 etc. except #356.\n\nFor test case #356/17', ' with [1] (progs/test_global_func17.c))', "" the main prog\nlooks like:\n\n 0000000000000000 :\n 0: b4 00 00 00 2a 00 00 00 w0 = 0x2a\n 1: 95 00 00 00 00 00 00 00 exit\n\n... which passed verification while the test itself expects a verification\nfailure.\n\nLet us add 'barrier_var' style asm code in both places to prevent function\nspecialization which caused selftests failure.\n\n [1] https://github.com/llvm/llvm-project/pull/72903\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20231127050342.1945270-1-yonghong.song@linux.dev\n"", '']",Fixes selftest failures caused by llvm18 changes in the Linux eBPF subsystem.,"bpf,selftest,llvm18",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +75a442581d05edaee168222ffbe00d4389785636,75a442581d05edaee168222ffbe00d4389785636,Hou Tao,houtao1@huawei.com,1699677501,Alexei Starovoitov,ast@kernel.org,1701050426,6e7f8564ef1db21b3c0ab3e335142df1d53a6065,c0c6bde586c7dce82719b4ff32a2db6af9ee3d65,"bpf: Add missed allocation hint for bpf_mem_cache_alloc_flags() + +bpf_mem_cache_alloc_flags() may call __alloc() directly when there is no +free object in free list"," but it doesn't initialize the allocation hint +for the returned pointer. It may lead to bad memory dereference when +freeing the pointer","[' so fix it by initializing the allocation hint.\n\nFixes: 822fb26bdb55 (""bpf: Add a hint to allocated objects."")\nSigned-off-by: Hou Tao \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231111043821.2258513-1-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add an allocation hint to bpf_mem_cache_alloc_flags() to prevent bad memory dereference.,"allocation,memory,dereference",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e8a339b5235e294f29153149ea7cf26a9a87dbea,e8a339b5235e294f29153149ea7cf26a9a87dbea,Andrii Nakryiko,andrii@kernel.org,1700798377,Daniel Borkmann,daniel@iogearbox.net,1700818806,11c36122a9d80c9c3ad9525f47973326ae348c30,2afae08c9dcb8ac648414277cec70c2fe6a34d9e,"selftests/bpf: Add lazy global subprog validation tests + +Add a few test that validate BPF verifier's lazy approach to validating +global subprogs. + +We check that global subprogs that are called transitively through +another global subprog is validated. + +We also check that invalid global subprog is not validated"," if it's not +called from the main program. + +And we also check that main program is always validated first","[' before\nany of the subprogs.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Eduard Zingerman \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20231124035937.403208-4-andrii@kernel.org\n', '']",Add selftests for validating the BPF verifier's lazy approach to global subprog validation.,"selftests,BPF verifier,validation",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2afae08c9dcb8ac648414277cec70c2fe6a34d9e,2afae08c9dcb8ac648414277cec70c2fe6a34d9e,Andrii Nakryiko,andrii@kernel.org,1700798376,Daniel Borkmann,daniel@iogearbox.net,1700818806,e6cdbe3962bbf30de73715d3b501a744c5b6df97,491dd8edecbc5027ee317f3f1e7e9800fb66d88f,"bpf: Validate global subprogs lazily + +Slightly change BPF verifier logic around eagerness and order of global +subprog validation. Instead of going over every global subprog eagerly +and validating it before main (entry) BPF program is verified"," turn it +around. Validate main program first","[' mark subprogs that were called from\nmain program for later verification', ' but otherwise assume it is valid.\nAfterwards', ' go over marked global subprogs and validate those', ""\npotentially marking some more global functions as being called. Continue\nthis process until all (transitively) callable global subprogs are\nvalidated. It's a BFS traversal at its heart and will always converge.\n\nThis is an important change because it allows to feature-gate some\nsubprograms that might not be verifiable on some older kernel"", ' depending\non supported set of features.\n\nE.g.', ' at some point', ' global functions were allowed to accept a pointer\nto memory', ' which size is identified by user-provided type.\nUnfortunately', "" older kernels don't support this feature. With BPF CO-RE\napproach"", "" the natural way would be to still compile BPF object file once\nand guard calls to this global subprog with some CO-RE check or using\n.rodata variables. That's what people do to guard usage of new helpers\nor kfuncs"", "" and any other new BPF-side feature that might be missing on\nold kernels.\n\nThat's currently impossible to do with global subprogs"", ' unfortunately', '\nbecause they are eagerly and unconditionally validated. This patch set\naims to change this', ' so that in the future when global funcs gain new\nfeatures', "" those can be guarded using BPF CO-RE techniques in the same\nfashion as any other new kernel feature.\n\nTwo selftests had to be adjusted in sync with these changes.\n\ntest_global_func12 relied on eager global subprog validation failing\nbefore main program failure is detected (unknown return value). Fix by\nmaking sure that main program is always valid.\n\nverifier_subprog_precision's parent_stack_slot_precise subtest relied on\nverifier checkpointing heuristic to do a checkpoint at instruction #5"", ""\nbut that's no longer true because we don't have enough jumps validated\nbefore reaching insn #5 due to global subprogs being validated later.\n\nOther than that"", ' no changes', ' as one would expect.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Eduard Zingerman \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20231124035937.403208-3-andrii@kernel.org\n', '']","This commit changes the BPF verifier's approach to validate global subprograms lazily, focusing first on the main program.","BPF verifier, global subprogs, validation",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +491dd8edecbc5027ee317f3f1e7e9800fb66d88f,491dd8edecbc5027ee317f3f1e7e9800fb66d88f,Andrii Nakryiko,andrii@kernel.org,1700798375,Daniel Borkmann,daniel@iogearbox.net,1700818806,01a62066f165441f5cb4db1b0a7267b4fab811eb,b8d78cb2e24d92352878a9f6525aec002c891528,"bpf: Emit global subprog name in verifier logs + +We have the name"," instead of emitting just func#N to identify global +subprog","[' augment verifier log messages with actual function name to make\nit more user-friendly.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Eduard Zingerman \nAcked-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/20231124035937.403208-2-andrii@kernel.org\n', '']",Emit global subprogram names in eBPF verifier logs for better identification.,"verifier,logs,subprog",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b8d78cb2e24d92352878a9f6525aec002c891528,b8d78cb2e24d92352878a9f6525aec002c891528,Eduard Zingerman,eddyz87@gmail.com,1700697879,Daniel Borkmann,daniel@iogearbox.net,1700776181,f4ca61a4565a67953930b4445555d12223d5636b,45c226dde742a92e22dcd65b96bf7e02620a9c19,"libbpf: Start v1.4 development cycle + +Bump libbpf.map to v1.4.0 to start a new libbpf version cycle. + +Signed-off-by: Eduard Zingerman +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231123000439.12025-1-eddyz87@gmail.com +",,Bump libbpf.map to v1.4.0 to start a new libbpf version cycle.,"libbpf, version, development",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"[""It's not related to any of the above.""]" +c0c6bde586c7dce82719b4ff32a2db6af9ee3d65,c0c6bde586c7dce82719b4ff32a2db6af9ee3d65,Stanislav Fomichev,sdf@google.com,1699937692,Alexei Starovoitov,ast@kernel.org,1700773444,fa3610ce4bae16c4ea1ab3fa962ad79b6bb275da,d3fa86b1a7b4cdc4367acacea16b72e0a200b3d7,"netdevsim: Don't accept device bound programs + +Commit 2b3486bc2d23 (""bpf: Introduce device-bound XDP programs"") introduced +device-bound programs by largely reusing existing offloading infrastructure. +This changed the semantics of 'prog->aux->offload' a bit. Now"," it's non-NULL +for both offloaded and device-bound programs. + +Instead of looking at 'prog->aux->offload' let's call bpf_prog_is_offloaded +which should be true iff the program is offloaded and not merely device-bound. + +Fixes: 2b3486bc2d23 (""bpf: Introduce device-bound XDP programs"") +Reported-by: syzbot+44c2416196b7c607f226@syzkaller.appspotmail.com +Signed-off-by: Stanislav Fomichev +Signed-off-by: Daniel Borkmann +Reviewed-by: Jakub Kicinski +Cc: Dipendra Khadka +Link: https://lore.kernel.org/bpf/20231114045453.1816995-2-sdf@google.com +Signed-off-by: Alexei Starovoitov +",[''],This commit prevents netdevsim from accepting device-bound XDP programs by correctly checking program offloading status.,"netdevsim, XDP program, offloading",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['xdp like programs'] +45c226dde742a92e22dcd65b96bf7e02620a9c19,45c226dde742a92e22dcd65b96bf7e02620a9c19,Jakub Kicinski,kuba@kernel.org,1700770789,Jakub Kicinski,kuba@kernel.org,1700770858,abaedb7f2ddf75914659c7b9a48af34ca89a9208,c5b9f4792ea6b9abfcfb9486ba256f55e296aaa7 d3fa86b1a7b4cdc4367acacea16b72e0a200b3d7,"Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Cross-merge networking fixes after downstream PR. + +Conflicts: + +drivers/net/ethernet/intel/ice/ice_main.c + c9663f79cd82 (""ice: adjust switchdev rebuild path"") + 7758017911a4 (""ice: restore timestamp configuration after device reset"") +https://lore.kernel.org/all/20231121211259.3348630-1-anthony.l.nguyen@intel.com/ + +Adjacent changes: + +kernel/bpf/verifier.c + bb124da69c47 (""bpf: keep track of max number of bpf_loop callback iterations"") + 5f99f312bd3b (""bpf: add register bounds sanity checks and sanitization"") + +Signed-off-by: Jakub Kicinski +",,Cross-merge of networking fixes including changes to ethernet and eBPF verifier subsystems.,"networking, merge, fixes",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d3fa86b1a7b4cdc4367acacea16b72e0a200b3d7,d3fa86b1a7b4cdc4367acacea16b72e0a200b3d7,Linus Torvalds,torvalds@linux-foundation.org,1700764813,Linus Torvalds,torvalds@linux-foundation.org,1700764813,fd40e9d155e34998831dc46c70dbda3d09bd6da6,9b6de136b5f0158c60844f85286a593cb70fb364 39f04b1406b23fcc129a67e70d6205d5a7322f38,"Merge tag 'net-6.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + ""Including fixes from bpf. + + Current release - regressions: + + - Revert ""net: r8169: Disable multicast filter for RTL8168H and + RTL8107E"" + + - kselftest: rtnetlink: fix ip route command typo + + Current release - new code bugs: + + - s390/ism: make sure ism driver implies smc protocol in kconfig + + - two build fixes for tools/net + + Previous releases - regressions: + + - rxrpc: couple of ACK/PING/RTT handling fixes + + Previous releases - always broken: + + - bpf: verify bpf_loop() callbacks as if they are called unknown + number of times + + - improve stability of auto-bonding with Hyper-V + + - account BPF-neigh-redirected traffic in interface statistics + + Misc: + + - net: fill in some more MODULE_DESCRIPTION()s"" + +* tag 'net-6.7-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (58 commits) + tools: ynl: fix duplicate op name in devlink + tools: ynl: fix header path for nfsd + net: ipa: fix one GSI register field width + tls: fix NULL deref on tls_sw_splice_eof() with empty record + net: axienet: Fix check for partial TX checksum + vsock/test: fix SEQPACKET message bounds test + i40e: Fix adding unsupported cloud filters + ice: restore timestamp configuration after device reset + ice: unify logic for programming PFINT_TSYN_MSK + ice: remove ptp_tx ring parameter flag + amd-xgbe: propagate the correct speed and duplex status + amd-xgbe: handle the corner-case during tx completion + amd-xgbe: handle corner-case during sfp hotplug + net: veth: fix ethtool stats reporting + octeontx2-pf: Fix ntuple rule creation to direct packet to VF with higher Rx queue than its PF + net: usb: qmi_wwan: claim interface 4 for ZTE MF290 + Revert ""net: r8169: Disable multicast filter for RTL8168H and RTL8107E"" + net/smc: avoid data corruption caused by decline + nfc: virtual_ncidev: Add variable to check if ndev is running + dpll: Fix potential msg memleak when genlmsg_put_reply failed + ... +",,Merge networking fixes that include BPF-related improvements and bug resolutions.,"networking,BPF,fixes",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +53475287dad9b314ef477fc9a27b48b6999da053,53475287dad9b314ef477fc9a27b48b6999da053,Jakub Kicinski,kuba@kernel.org,1700617969,Jakub Kicinski,kuba@kernel.org,1700618000,879406230b20e986706aa37dacd999c63494328b,340bf2dbb11b4d2d44055fa5851d75fd335e3d45 3cbbf9192abdc9183eb215b5e8b06c778e5c2214,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-11-21 + +We've added 85 non-merge commits during the last 12 day(s) which contain +a total of 63 files changed", 4464 insertions(+),"[' 1484 deletions(-).\n\nThe main changes are:\n\n1) Huge batch of verifier changes to improve BPF register bounds logic\n and range support along with a large test suite', ' and verifier log\n improvements', ' all from Andrii Nakryiko.\n\n2) Add a new kfunc which acquires the associated cgroup of a task within\n a specific cgroup v1 hierarchy where the latter is identified by its id', '\n from Yafang Shao.\n\n3) Extend verifier to allow bpf_refcount_acquire() of a map value field\n obtained via direct load which is a use-case needed in sched_ext', '\n from Dave Marchevsky.\n\n4) Fix bpf_get_task_stack() helper to add the correct crosstask check\n for the get_perf_callchain()', ' from Jordan Rome.\n\n5) Fix BPF task_iter internals where lockless usage of next_thread()\n was wrong. The rework also simplifies the code', ' from Oleg Nesterov.\n\n6) Fix uninitialized tail padding via LIBBPF_OPTS_RESET', ' and another\n fix for certain BPF UAPI structs to fix verifier failures seen\n in bpf_dynptr usage', ' from Yonghong Song.\n\n7) Add BPF selftest fixes for map_percpu_stats flakes due to per-CPU BPF\n memory allocator not being able to allocate per-CPU pointer successfully', '\n from Hou Tao.\n\n8) Add prep work around dynptr and string handling for kfuncs which\n is later going to be used by file verification via BPF LSM and fsverity', '\n from Song Liu.\n\n9) Improve BPF selftests to update multiple prog_tests to use ASSERT_*\n macros', ' from Yuran Pereira.\n\n10) Optimize LPM trie lookup to check prefixlen before walking the trie', '\n from Florian Lehner.\n\n11) Consolidate virtio/9p configs from BPF selftests in config.vm file\n given they are needed consistently across archs', ' from Manu Bretelle.\n\n12) Small BPF verifier refactor to remove register_is_const()', ""\n from Shung-Hsi Yu.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (85 commits)\n selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in vmlinux\n selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bpf_obj_id\n selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bind_perm\n selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bpf_tcp_ca\n selftests/bpf: reduce verboseness of reg_bounds selftest logs\n bpf: bpf_iter_task_next: use next_task(kit->task) rather than next_task(kit->pos)\n bpf: bpf_iter_task_next: use __next_thread() rather than next_thread()\n bpf: task_group_seq_get_next: use __next_thread() rather than next_thread()\n bpf: emit frameno for PTR_TO_STACK regs if it differs from current one\n bpf: smarter verifier log number printing logic\n bpf: omit default off=0 and imm=0 in register state log\n bpf: emit map name in register state if applicable and available\n bpf: print spilled register state in stack slot\n bpf: extract register state printing\n bpf: move verifier state printing code to kernel/bpf/log.c\n bpf: move verbose_linfo() into kernel/bpf/log.c\n bpf: rename BPF_F_TEST_SANITY_STRICT to BPF_F_TEST_REG_INVARIANTS\n bpf: Remove test for MOVSX32 with offset=32\n selftests/bpf: add iter test requiring range x range logic\n veristat: add ability to set BPF_F_TEST_SANITY_STRICT flag with -r flag\n ...\n====================\n\nLink: https://lore.kernel.org/r/20231122000500.28126-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n"", '']","Merge branch 'for-netdev' with updates from bpf-next into the main project, including 85 non-merge commits affecting 63 files.","merge, bpf-next, non-merge",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b2d66643dcf2c395207f9373c624e0ab32166e57,b2d66643dcf2c395207f9373c624e0ab32166e57,Jakub Kicinski,kuba@kernel.org,1700610570,Jakub Kicinski,kuba@kernel.org,1700610571,a9be214abb19a9f0f41a6ad2c8b42a39a64bd363,495ec91b48e489afefb2ad714f0d9b68c3016c6c acb12c859ac7c36d6d7632280fd1e263188cb07f,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-11-21 + +We've added 19 non-merge commits during the last 4 day(s) which contain +a total of 18 files changed", 1043 insertions(+),"[' 416 deletions(-).\n\nThe main changes are:\n\n1) Fix BPF verifier to validate callbacks as if they are called an unknown\n number of times in order to fix not detecting some unsafe programs', '\n from Eduard Zingerman.\n\n2) Fix bpf_redirect_peer() handling which missed proper stats accounting\n for veth and netkit and also generally fix missing stats for the latter', '\n from Peilin Ye', "" Daniel Borkmann et al.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n selftests/bpf: check if max number of bpf_loop iterations is tracked\n bpf: keep track of max number of bpf_loop callback iterations\n selftests/bpf: test widening for iterating callbacks\n bpf: widening for callback iterators\n selftests/bpf: tests for iterating callbacks\n bpf: verify callbacks as if they are called unknown number of times\n bpf: extract setup_func_entry() utility function\n bpf: extract __check_reg_arg() utility function\n selftests/bpf: fix bpf_loop_bench for new callback verification scheme\n selftests/bpf: track string payload offset as scalar in strobemeta\n selftests/bpf: track tcp payload offset as scalar in xdp_synproxy\n selftests/bpf: Add netkit to tc_redirect selftest\n selftests/bpf: De-veth-ize the tc_redirect test case\n bpf"", "" netkit: Add indirect call wrapper for fetching peer dev\n bpf: Fix dev's rx stats for bpf_redirect_peer traffic\n veth: Use tstats per-CPU traffic counters\n netkit: Add tstats per-CPU traffic counters\n net: Move {l"", 't', 'd}stats allocation to core and convert veth & vrf\n net', ' vrf: Move dstats structure to core\n====================\n\nLink: https://lore.kernel.org/r/20231121193113.11796-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merged 'for-netdev' tag containing 19 non-merge commits into the bpf tree.,"merge, commits, bpf",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3cbbf9192abdc9183eb215b5e8b06c778e5c2214,3cbbf9192abdc9183eb215b5e8b06c778e5c2214,Andrii Nakryiko,andrii@kernel.org,1700592183,Andrii Nakryiko,andrii@kernel.org,1700592326,44db270715ffcdfdf3c099a61d5b3c5e0106dd25,57b97ecb40caeb116c22451bbdaaa9a1d12c0b43 3ece0e85f679c23d2a5128993846c58a2f5f890e,"Merge branch 'selftests-bpf-update-multiple-prog_tests-to-use-assert_-macros' + +Yuran Pereira says: + +==================== +selftests/bpf: Update multiple prog_tests to use ASSERT_ macros + +Multiple files/programs in `tools/testing/selftests/bpf/prog_tests/` still +heavily use the `CHECK` macro"," even when better `ASSERT_` alternatives are +available. + +As it was already pointed out by Yonghong Song [1] in the bpf selftests the use +of the ASSERT_* series of macros is preferred over the CHECK macro. + +This patchset replaces the usage of `CHECK(` macros to the equivalent `ASSERT_` +family of macros in the following prog_tests: +- bind_perm.c +- bpf_obj_id.c +- bpf_tcp_ca.c +- vmlinux.c + +[1] https://lore.kernel.org/lkml/0a142924-633c-44e6-9a92-2dc019656bf2@linux.dev + +Changes in v3: +- Addressed the following points mentioned by Yonghong Song +- Improved `bpf_map_lookup_elem` assertion in bpf_tcp_ca. +- Replaced assertion introduced in v2 with one that checks `thread_ret` + instead of `pthread_join`. This ensures that `server`'s return value + (thread_ret) is the one being checked","["" as oposed to `pthread_join`'s\n return value"", ' since the latter one is less likely to fail.\n\nChanges in v2:\n- Fixed pthread_join assertion that broke the previous test\n\nPrevious version:\nv2 - https://lore.kernel.org/lkml/GV1PR10MB6563AECF8E94798A1E5B36A4E8B6A@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM\nv1 - https://lore.kernel.org/lkml/GV1PR10MB6563FCFF1C5DEBE84FEA985FE8B0A@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM\n====================\n\nLink: https://lore.kernel.org/r/GV1PR10MB6563BEFEA4269E1DDBC264B1E8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM\nSigned-off-by: Andrii Nakryiko \n', '']",Update multiple BPF selftests to use ASSERT_ macros instead of CHECK.,"selftests, ASSERT_ macros, prog_tests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3ece0e85f679c23d2a5128993846c58a2f5f890e,3ece0e85f679c23d2a5128993846c58a2f5f890e,Yuran Pereira,yuran.pereira@hotmail.com,1700525441,Andrii Nakryiko,andrii@kernel.org,1700592326,44db270715ffcdfdf3c099a61d5b3c5e0106dd25,f125d09b99fc0ee43f865810390f10b8f23a2c98,"selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in vmlinux + +vmlinux.c uses the `CHECK` calls even though the use of ASSERT_ series +of macros is preferred in the bpf selftests. + +This patch replaces all `CHECK` calls for equivalent `ASSERT_` +macro calls. + +Signed-off-by: Yuran Pereira +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/GV1PR10MB6563ED1023A2A3AEF30BDA5DE8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM +",,This commit replaces CHECK calls with ASSERT macros in vmlinux bpf selftests.,"bpf,selftests,macros",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f125d09b99fc0ee43f865810390f10b8f23a2c98,f125d09b99fc0ee43f865810390f10b8f23a2c98,Yuran Pereira,yuran.pereira@hotmail.com,1700525365,Andrii Nakryiko,andrii@kernel.org,1700592324,b8c5a66cc6120605a5c7a110d05ed01be3a47f2d,3ec1114a97457398077e45b231d502d1cc30439d,"selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bpf_obj_id + +bpf_obj_id uses the `CHECK` calls even though the use of +ASSERT_ series of macros is preferred in the bpf selftests. + +This patch replaces all `CHECK` calls for equivalent `ASSERT_` +macro calls. + +Signed-off-by: Yuran Pereira +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/GV1PR10MB65639AA3A10B4BBAA79952C7E8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM +",,Replaced CHECK calls with ASSERT macros in bpf_obj_id selftests for better consistency.,"selftests,ASSERT,macros",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3ec1114a97457398077e45b231d502d1cc30439d,3ec1114a97457398077e45b231d502d1cc30439d,Yuran Pereira,yuran.pereira@hotmail.com,1700525263,Andrii Nakryiko,andrii@kernel.org,1700592183,7b34819126ba133a7f55209e83ecdd32af7cf447,b0e2a0395312f4e53504ae84eeb5902e5518d1d7,"selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bind_perm + +bind_perm uses the `CHECK` calls even though the use of +ASSERT_ series of macros is preferred in the bpf selftests. + +This patch replaces all `CHECK` calls for equivalent `ASSERT_` +macro calls. + +Signed-off-by: Yuran Pereira +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/GV1PR10MB656314F467E075A106CA02BFE8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM +",,Replaced CHECK calls with ASSERT_ macros in the bind_perm bpf selftests.,"ASSERT, CHECK, selftests",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +b0e2a0395312f4e53504ae84eeb5902e5518d1d7,b0e2a0395312f4e53504ae84eeb5902e5518d1d7,Yuran Pereira,yuran.pereira@hotmail.com,1700525139,Andrii Nakryiko,andrii@kernel.org,1700592183,e2b324248b2a501fef66ed7507015deb9fcf31c0,57b97ecb40caeb116c22451bbdaaa9a1d12c0b43,"selftests/bpf: Replaces the usage of CHECK calls for ASSERTs in bpf_tcp_ca + +bpf_tcp_ca uses the `CHECK` calls even though the use of +ASSERT_ series of macros is preferred in the bpf selftests. + +This patch replaces all `CHECK` calls for equivalent `ASSERT_` +macro calls. + +Signed-off-by: Yuran Pereira +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/GV1PR10MB6563F180C0F2BB4F6CFA5130E8BBA@GV1PR10MB6563.EURPRD10.PROD.OUTLOOK.COM +",,Refactors selftests by replacing CHECK calls with ASSERT macros in bpf_tcp_ca.,"selftests, ASSERT, bpf_tcp_ca",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +29b8e94dcf2575c17541f843741ee96691ff1ded,29b8e94dcf2575c17541f843741ee96691ff1ded,Yang Jihong,yangjihong1@huawei.com,1700275737,Namhyung Kim,namhyung@kernel.org,1700589758,b7965c350dce54c8a63b51a7e51ef213d5e19228,a6dda77a752d918b35ef4a3f94e6b8c7d7ba4a73,"perf lock contention: Fix a build error on 32-bit + +Fix a build error on 32-bit system: + + util/bpf_lock_contention.c: In function 'lock_contention_get_name': + util/bpf_lock_contention.c:253:50: error: format '%lu' expects argument of type 'long unsigned int'"," but argument 4 has type 'u64 {aka long long unsigned int}' [-Werror=format=] + snprintf(name_buf","[' sizeof(name_buf)', ' ""cgroup:%lu""', ' cgrp_id);\n ~~^\n %llu\n cc1: all warnings being treated as errors\n\nFixes: d0c502e46e97 (""perf lock contention: Prepare to handle cgroups"")\nSigned-off-by: Yang Jihong \nAcked-by: Namhyung Kim \nCc: avagin@google.com\nCc: daniel.diaz@linaro.org\nLink: https://lore.kernel.org/r/20231118024858.1567039-3-yangjihong1@huawei.com\nSigned-off-by: Namhyung Kim \n', '']",Fix a build error related to format specifier on 32-bit systems in perf lock contention code.,"build,error,32-bit",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['other'] +acb12c859ac7c36d6d7632280fd1e263188cb07f,acb12c859ac7c36d6d7632280fd1e263188cb07f,Alexei Starovoitov,ast@kernel.org,1700534016,Alexei Starovoitov,ast@kernel.org,1700534201,807b0cdc43a76fe532c17fc31e96413c82161e1a,fcb905d831336ee0a67dd953837a904173cf7390 57e2a52deeb12ab84c15c6d0fb93638b5b94001b,"Merge branch 'verify-callbacks-as-if-they-are-called-unknown-number-of-times' + +Eduard Zingerman says: + +==================== +verify callbacks as if they are called unknown number of times + +This series updates verifier logic for callback functions handling. +Current master simulates callback body execution exactly once"," +which leads to verifier not detecting unsafe programs like below: + + static int unsafe_on_zero_iter_cb(__u32 idx","[' struct num_context *ctx)\n {\n ctx->i = 0;\n return 0;\n }\n\n SEC(""?raw_tp"")\n int unsafe_on_zero_iter(void *unused)\n {\n struct num_context loop_ctx = { .i = 32 };\n __u8 choice_arr[2] = { 0', ' 1 };\n\n bpf_loop(100', ' unsafe_on_zero_iter_cb', ' &loop_ctx', ' 0);\n return choice_arr[loop_ctx.i];\n }\n\nThis was reported previously in [0].\nThe basic idea of the fix is to schedule callback entry state for\nverification in env->head until some identical', ' previously visited\nstate in current DFS state traversal is found. Same logic as with open\ncoded iterators', ' and builds on top recent fixes [1] for those.\n\nThe series is structured as follows:\n- patches #1', '2', '3 update strobemeta', ' xdp_synproxy selftests and\n bpf_loop_bench benchmark to allow convergence of the bpf_loop\n callback states;\n- patches #4', '5 just shuffle the code a bit;\n- patch #6 is the main part of the series;\n- patch #7 adds test cases for #6;\n- patch #8 extend patch #6 with same speculative scalar widening\n logic', ' as used for open coded iterators;\n- patch #9 adds test cases for #8;\n- patch #10 extends patch #6 to track maximal number of callback\n executions specifically for bpf_loop();\n- patch #11 adds test cases for #10.\n\nVeristat results comparing this series to master+patches #1', '2', '3 using selftests\nshow the following difference:\n\nFile Program States (A) States (B) States (DIFF)\n------------------------- ------------- ---------- ---------- -------------\nbpf_loop_bench.bpf.o benchmark 1 2 +1 (+100.00%)\npyperf600_bpf_loop.bpf.o on_event 322 407 +85 (+26.40%)\nstrobemeta_bpf_loop.bpf.o on_event 113 151 +38 (+33.63%)\nxdp_synproxy_kern.bpf.o syncookie_tc 341 291 -50 (-14.66%)\nxdp_synproxy_kern.bpf.o syncookie_xdp 344 301 -43 (-12.50%)\n\nVeristat results comparing this series to master using Tetragon BPF\nfiles [2] also show some differences.\nStates diff varies from +2% to +15% on 23 programs out of 186', '\nno new failures.\n\nChangelog:\n- V3 [5] -> V4', "" changes suggested by Andrii:\n - validate mark_chain_precision() result in patch #10;\n - renaming s/cumulative_callback_depth/callback_unroll_depth/.\n- V2 [4] -> V3:\n - fixes in expected log messages for test cases:\n - callback_result_precise;\n - parent_callee_saved_reg_precise_with_callback;\n - parent_stack_slot_precise_with_callback;\n - renamings (suggested by Alexei):\n - s/callback_iter_depth/cumulative_callback_depth/\n - s/is_callback_iter_next/calls_callback/\n - s/mark_callback_iter_next/mark_calls_callback/\n - prepare_func_exit() updated to exit with -EFAULT when\n callee->in_callback_fn is true but calls_callback() is not true\n for callsite;\n - test case 'bpf_loop_iter_limit_nested' rewritten to use return\n value check instead of verifier log message checks\n (suggested by Alexei).\n- V1 [3] -> V2"", "" changes suggested by Andrii:\n - small changes for error handling code in __check_func_call();\n - callback body processing log is now matched in relevant\n verifier_subprog_precision.c tests;\n - R1 passed to bpf_loop() is now always marked as precise;\n - log level 2 message for bpf_loop() iteration termination instead of\n iteration depth messages;\n - __no_msg macro removed;\n - bpf_loop_iter_limit_nested updated to avoid using __no_msg;\n - commit message for patch #3 updated according to Alexei's request.\n\n[0] https://lore.kernel.org/bpf/CA+vRuzPChFNXmouzGG+wsy=6eMcfr1mFG0F3g7rbg-sedGKW3w@mail.gmail.com/\n[1] https://lore.kernel.org/bpf/20231024000917.12153-1-eddyz87@gmail.com/\n[2] git@github.com:cilium/tetragon.git\n[3] https://lore.kernel.org/bpf/20231116021803.9982-1-eddyz87@gmail.com/T/#t\n[4] https://lore.kernel.org/bpf/20231118013355.7943-1-eddyz87@gmail.com/T/#t\n[5] https://lore.kernel.org/bpf/20231120225945.11741-1-eddyz87@gmail.com/T/#t\n====================\n\nLink: https://lore.kernel.org/r/20231121020701.26440-1-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n"", '']",Update verifier logic to handle callbacks as being called an unknown number of times.,"verifier,callbacks,logic",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +57e2a52deeb12ab84c15c6d0fb93638b5b94001b,57e2a52deeb12ab84c15c6d0fb93638b5b94001b,Eduard Zingerman,eddyz87@gmail.com,1700532421,Alexei Starovoitov,ast@kernel.org,1700534200,807b0cdc43a76fe532c17fc31e96413c82161e1a,bb124da69c47dd98d69361ec13244ece50bec63e,"selftests/bpf: check if max number of bpf_loop iterations is tracked + +Check that even if bpf_loop() callback simulation does not converge to +a specific state"," verification could proceed via ""brute force"" +simulation of maximal number of callback calls. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231121020701.26440-12-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Add a test to verify if the maximum number of bpf_loop iterations is correctly tracked in selftests.,"bpf_loop,selftests,iterations",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +bb124da69c47dd98d69361ec13244ece50bec63e,bb124da69c47dd98d69361ec13244ece50bec63e,Eduard Zingerman,eddyz87@gmail.com,1700532420,Alexei Starovoitov,ast@kernel.org,1700534200,471ffe5db4c4853832fd01de3a5113715b14f715,9f3330aa644d6d979eb064c46e85c62d4b4eac75,"bpf: keep track of max number of bpf_loop callback iterations + +In some cases verifier can't infer convergence of the bpf_loop() +iteration. E.g. for the following program: + + static int cb(__u32 idx"," struct num_context* ctx) + { + ctx->i++; + return 0; + } + + SEC(""?raw_tp"") + int prog(void *_) + { + struct num_context ctx = { .i = 0 }; + __u8 choice_arr[2] = { 0","[' 1 };\n\n bpf_loop(2', ' cb', ' &ctx', "" 0);\n return choice_arr[ctx.i];\n }\n\nEach 'cb' simulation would eventually return to 'prog' and reach\n'return choice_arr[ctx.i]' statement. At which point ctx.i would be\nmarked precise"", ' thus forcing verifier to track multitude of separate\nstates with {.i=0}', ' {.i=1}', ' ... at bpf_loop() callback entry.\n\nThis commit allows ""brute force"" handling for such cases by limiting\nnumber of callback body simulations using \'umax\' value of the first\nbpf_loop() parameter.\n\nFor this', "" extend bpf_func_state with 'callback_depth' field.\nIncrement this field when callback visiting state is pushed to states\ntraversal stack. For frame #N it's 'callback_depth' field counts how\nmany times callback with frame depth N+1 had been executed.\nUse bpf_func_state specifically to allow independent tracking of\ncallback depths when multiple nested bpf_loop() calls are present.\n\nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231121020701.26440-11-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n"", '']",The commit enhances the verifier to track the maximum number of iterations for bpf_loop callbacks.,"bpf,verifier,loop",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9f3330aa644d6d979eb064c46e85c62d4b4eac75,9f3330aa644d6d979eb064c46e85c62d4b4eac75,Eduard Zingerman,eddyz87@gmail.com,1700532419,Alexei Starovoitov,ast@kernel.org,1700534200,339ae1382e4f1ac5b3f2939a3b7431e6c6a9347d,cafe2c21508a38cdb3ed22708842e957b2572c3e,"selftests/bpf: test widening for iterating callbacks + +A test case to verify that imprecise scalars widening is applied to +callback entering state"," when callback call is simulated repeatedly. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231121020701.26440-10-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],This commit adds a test case to ensure imprecise scalars are widened in callback entering states during repeated simulations.,"test,widening,callback",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cafe2c21508a38cdb3ed22708842e957b2572c3e,cafe2c21508a38cdb3ed22708842e957b2572c3e,Eduard Zingerman,eddyz87@gmail.com,1700532418,Alexei Starovoitov,ast@kernel.org,1700534200,b93ff2494a5347ae9e13f76e51dbba0147560cbe,958465e217dbf5fc6677d42d8827fb3073d86afd,"bpf: widening for callback iterators + +Callbacks are similar to open coded iterators"," so add imprecise +widening logic for callback body processing. This makes callback based +loops behave identically to open coded iterators","[' e.g. allowing to\nverify programs like below:\n\n struct ctx { u32 i; };\n int cb(u32 idx', ' struct ctx* ctx)\n {\n ++ctx->i;\n return 0;\n }\n ...\n struct ctx ctx = { .i = 0 };\n bpf_loop(100', ' cb', ' &ctx', ' 0);\n ...\n\nAcked-by: Andrii Nakryiko \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231121020701.26440-9-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add imprecise widening logic for callback iterators in eBPF to match open coded iterators.,"callback,iterators,widening",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +958465e217dbf5fc6677d42d8827fb3073d86afd,958465e217dbf5fc6677d42d8827fb3073d86afd,Eduard Zingerman,eddyz87@gmail.com,1700532417,Alexei Starovoitov,ast@kernel.org,1700534200,f7d2e4937e28bd7157da6815ca29fea42be3c284,ab5cfac139ab8576fb54630d4cca23c3e690ee90,"selftests/bpf: tests for iterating callbacks + +A set of test cases to check behavior of callback handling logic"," +check if verifier catches the following situations: +- program not safe on second callback iteration; +- program not safe on zero callback iterations; +- infinite loop inside a callback. + +Verify that callback logic works for bpf_loop","[' bpf_for_each_map_elem', '\nbpf_user_ringbuf_drain', ' bpf_find_vma.\n\nAcked-by: Andrii Nakryiko \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231121020701.26440-8-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Adds test cases for verifying callback handling logic in selftests for BPF.,"test cases, callback, iteration",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ab5cfac139ab8576fb54630d4cca23c3e690ee90,ab5cfac139ab8576fb54630d4cca23c3e690ee90,Eduard Zingerman,eddyz87@gmail.com,1700532416,Alexei Starovoitov,ast@kernel.org,1700534144,897259c37acdd692a381d54633514ca83e3aa6d3,58124a98cb8eda69d248d7f1de954c8b2767c945,"bpf: verify callbacks as if they are called unknown number of times + +Prior to this patch callbacks were handled as regular function calls"," +execution of callback body was modeled exactly once. +This patch updates callbacks handling logic as follows: +- introduces a function push_callback_call() that schedules callback + body verification in env->head stack; +- updates prepare_func_exit() to reschedule callback body verification + upon BPF_EXIT; +- as calls to bpf_*_iter_next()","[' calls to callback invoking functions\n are marked as checkpoints;\n- is_state_visited() is updated to stop callback based iteration when\n some identical parent state is found.\n\nPaths with callback function invoked zero times are now verified first', '\nwhich leads to necessity to modify some selftests:\n- the following negative tests required adding release/unlock/drop\n calls to avoid previously masked unrelated error reports:\n - cb_refs.c:underflow_prog\n - exceptions_fail.c:reject_rbtree_add_throw\n - exceptions_fail.c:reject_with_cp_reference\n- the following precision tracking selftests needed change in expected\n log trace:\n - verifier_subprog_precision.c:callback_result_precise\n (note: r0 precision is no longer propagated inside callback and\n I think this is a correct behavior)\n - verifier_subprog_precision.c:parent_callee_saved_reg_precise_with_callback\n - verifier_subprog_precision.c:parent_stack_slot_precise_with_callback\n\nReported-by: Andrew Werner \nCloses: https://lore.kernel.org/bpf/CA+vRuzPChFNXmouzGG+wsy=6eMcfr1mFG0F3g7rbg-sedGKW3w@mail.gmail.com/\nAcked-by: Andrii Nakryiko \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231121020701.26440-7-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Update callback handling in eBPF to verify as called unknown number of times.,"callbacks, verification, bpf",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +58124a98cb8eda69d248d7f1de954c8b2767c945,58124a98cb8eda69d248d7f1de954c8b2767c945,Eduard Zingerman,eddyz87@gmail.com,1700532415,Alexei Starovoitov,ast@kernel.org,1700534015,b11131ec02dcffa6d6a53e6a0e1f3bdabc534c11,683b96f9606ab7308ffb23c46ab43cecdef8a241,"bpf: extract setup_func_entry() utility function + +Move code for simulated stack frame creation to a separate utility +function. This function would be used in the follow-up change for +callbacks handling. + +Acked-by: Andrii Nakryiko +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231121020701.26440-6-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",,The commit refactors code by extracting simulated stack frame creation to a separate utility function setup_func_entry.,"utility function, stack frame, refactoring",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +683b96f9606ab7308ffb23c46ab43cecdef8a241,683b96f9606ab7308ffb23c46ab43cecdef8a241,Eduard Zingerman,eddyz87@gmail.com,1700532414,Alexei Starovoitov,ast@kernel.org,1700534015,de0eccbd211f39fe44075f6ef5012a502735117d,f40bfd1679446b22d321e64a1fa98b7d07d2be08,"bpf: extract __check_reg_arg() utility function + +Split check_reg_arg() into two utility functions: +- check_reg_arg() operating on registers from current verifier state; +- __check_reg_arg() operating on a specific set of registers passed as + a parameter; + +The __check_reg_arg() function would be used by a follow-up change for +callbacks handling. + +Acked-by: Andrii Nakryiko +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231121020701.26440-5-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",,Refactors check_reg_arg into two functions for better handling of register arguments in the eBPF verifier.,"utility function,refactor,verifier",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f40bfd1679446b22d321e64a1fa98b7d07d2be08,f40bfd1679446b22d321e64a1fa98b7d07d2be08,Eduard Zingerman,eddyz87@gmail.com,1700532413,Alexei Starovoitov,ast@kernel.org,1700534015,b945d735226e100b89d9b9e39e5c0fa0f010d1ba,87eb0152bcc102ecbda866978f4e54db5a3be1ef,"selftests/bpf: fix bpf_loop_bench for new callback verification scheme + +This is a preparatory change. A follow-up patch ""bpf: verify callbacks +as if they are called unknown number of times"" changes logic for +callbacks handling. While previously callbacks were verified as a +single function call"," new scheme takes into account that callbacks +could be executed unknown number of times. + +This has dire implications for bpf_loop_bench: + + SEC(""fentry/"" SYS_PREFIX ""sys_getpgid"") + int benchmark(void *ctx) + { + for (int i = 0; i < 1000; i++) { + bpf_loop(nr_loops","[' empty_callback', ' NULL', ' 0);\n __sync_add_and_fetch(&hits', ' nr_loops);\n }\n return 0;\n }\n\nW/o callbacks change verifier sees it as a 1000 calls to\nempty_callback(). However', ' with callbacks change things become\nexponential:\n- i=0: state exploring empty_callback is scheduled with i=0 (a);\n- i=1: state exploring empty_callback is scheduled with i=1;\n ...\n- i=999: state exploring empty_callback is scheduled with i=999;\n- state (a) is popped from stack;\n- i=1: state exploring empty_callback is scheduled with i=1;\n ...\n\nAvoid this issue by rewriting outer loop as bpf_loop().\nUnfortunately', ' this adds a function call to a loop at runtime', ' which\nnegatively affects performance:\n\n throughput latency\n before: 149.919 ± 0.168 M ops/s', ' 6.670 ns/op\n after : 137.040 ± 0.187 M ops/s', ' 7.297 ns/op\n\nAcked-by: Andrii Nakryiko \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231121020701.26440-4-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes bpf_loop_bench for the new callback verification mechanism in selftests.,"selftests, bpf, callback",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +87eb0152bcc102ecbda866978f4e54db5a3be1ef,87eb0152bcc102ecbda866978f4e54db5a3be1ef,Eduard Zingerman,eddyz87@gmail.com,1700532412,Alexei Starovoitov,ast@kernel.org,1700534015,25716ce657f2157c4a6fdf1dd0ecce6a1279f23b,977bc146d4eb7070118d8a974919b33bb52732b4,"selftests/bpf: track string payload offset as scalar in strobemeta + +This change prepares strobemeta for update in callbacks verification +logic. To allow bpf_loop() verification converge when multiple +callback iterations are considered: +- track offset inside strobemeta_payload->payload directly as scalar + value; +- at each iteration make sure that remaining + strobemeta_payload->payload capacity is sufficient for execution of + read_{map","str}_var functions; +- make sure that offset is tracked as unbound scalar between + iterations","["" otherwise verifier won't be able infer that bpf_loop\n callback reaches identical states.\n\nAcked-by: Andrii Nakryiko \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231121020701.26440-3-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n"", '']",Track scalar offset of string payload in strobemeta for bpf_loop() iteration verification.,"strobemeta,scalar,offset",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +977bc146d4eb7070118d8a974919b33bb52732b4,977bc146d4eb7070118d8a974919b33bb52732b4,Eduard Zingerman,eddyz87@gmail.com,1700532411,Alexei Starovoitov,ast@kernel.org,1700534015,98441b21f88cf103aa0d88ba0f5c6ae3992b0d5b,fcb905d831336ee0a67dd953837a904173cf7390,"selftests/bpf: track tcp payload offset as scalar in xdp_synproxy + +This change prepares syncookie_{tc","xdp} for update in callbakcs +verification logic. To allow bpf_loop() verification converge when +multiple callback itreations are considered: +- track offset inside TCP payload explicitly","[' not as a part of the\n pointer;\n- make sure that offset does not exceed MAX_PACKET_OFF enforced by\n verifier;\n- make sure that offset is tracked as unbound scalar between\n iterations', "" otherwise verifier won't be able infer that bpf_loop\n callback reaches identical states.\n\nAcked-by: Andrii Nakryiko \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231121020701.26440-2-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n"", '']",Track TCP payload offset as a scalar in xdp_synproxy to improve bpf_loop() verification logic.,"tcp,payload,offset",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['xdp like programs', 'tc/netfilter like programs']" +57b97ecb40caeb116c22451bbdaaa9a1d12c0b43,57b97ecb40caeb116c22451bbdaaa9a1d12c0b43,Andrii Nakryiko,andrii@kernel.org,1700503492,Alexei Starovoitov,ast@kernel.org,1700513644,334ed292b96538b019c78471dcc594325f66025d,3e124aa6cb5e74308f5997f63ebd3e5badb5c4e7,"selftests/bpf: reduce verboseness of reg_bounds selftest logs + +Reduce verboseness of test_progs' output in reg_bounds set of tests with +two changes. + +First", instead of each different operator (<,"[' <=', ' >', "" ...) being it's own\nsubtest"", ' combine all different ops for the same (x', ' y', ' init_t', ' cond_t)\nvalues into single subtest. Instead of getting 6 subtests', ' we get one\ngeneric one', ' e.g.:\n\n #192/53 reg_bounds_crafted/(s64)[0xffffffffffffffff; 0] (s64) 0xffffffff00000000:OK\n\nSecond', ' for random generated test cases', "" treat all of them as a single\ntest to eliminate very verbose output with random values in them. So now\nwe'll just get one line per each combination of (init_t"", ' cond_t)', '\ninstead of 6 x 25 = 150 subtests before this change:\n\n #225 reg_bounds_rand_consts_s32_s32:OK\n\nGiven we reduce verboseness so much', ' it makes sense to do a bit more\nrandom testing', ' so we also bump default number of random tests to 100', ""\nup from 25. This doesn't increase runtime significantly"", ' especially in\nparallelized mode.\n\nWith all the above changes we still make sure that we have all the\ninformation necessary for reproducing test case if it happens to fail.\nThat includes reporting random seed and specific operator that is\nfailing. Those will only be printed to console if related test/subtest\nfails', "" so it doesn't have any added verboseness implications.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231120180452.145849-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",Reduce verbosity of reg_bounds selftest logs in bpf selftests.,"reduce verbosity,selftests,reg_bounds",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fcb905d831336ee0a67dd953837a904173cf7390,fcb905d831336ee0a67dd953837a904173cf7390,Martin KaFai Lau,martin.lau@kernel.org,1700504117,Martin KaFai Lau,martin.lau@kernel.org,1700504192,b9365cd2f303f48ceebf15bcb03b5e44fc6d735b,76df934c6d5f5c93ba7a0112b1818620ddc10b19 adfeae2d243d9e5b83d094af481d189156b11779,"Merge branch 'bpf_redirect_peer fixes' + +Daniel Borkmann says: + +==================== +This fixes bpf_redirect_peer stats accounting for veth and netkit"," +and adds tstats in the first place for the latter. Utilise indirect +call wrapper for bpf_redirect_peer","[' and improve test coverage of the\nlatter also for netkit devices. Details in the patches', ' thanks!\n\nThe series was targeted at bpf originally', ' and is done here as well', '\nso it can trigger BPF CI. Jakub', ' if you think directly going via net\nis better since the majority of the diff touches net anyway', ' that is\nfine', ' too.\n\nThanks!\n\nv2 -> v3:\n - Add kdoc for pcpu_stat_type (Simon)\n - Reject invalid type value in netdev_do_alloc_pcpu_stats (Simon)\n - Add Reviewed-by tags from list\nv1 -> v2:\n - Move stats allocation/freeing into net core (Jakub)\n - As prepwork for the above', "" move vrf's dstats over into the core\n - Add a check into stats alloc to enforce tstats upon\n implementing ndo_get_peer_dev\n - Add Acked-by tags from list\n\nDaniel Borkmann (6):\n net"", ' vrf: Move dstats structure to core\n net: Move {l', 't', 'd}stats allocation to core and convert veth & vrf\n netkit: Add tstats per-CPU traffic counters\n bpf', ' netkit: Add indirect call wrapper for fetching peer dev\n selftests/bpf: De-veth-ize the tc_redirect test case\n selftests/bpf: Add netkit to tc_redirect selftest\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",Fixes bpf_redirect_peer stats accounting and adds tstats for veth and netkit.,"bpf_redirect_peer,veth,tstats",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +adfeae2d243d9e5b83d094af481d189156b11779,adfeae2d243d9e5b83d094af481d189156b11779,Daniel Borkmann,daniel@iogearbox.net,1699922540,Martin KaFai Lau,martin.lau@kernel.org,1700504116,b9365cd2f303f48ceebf15bcb03b5e44fc6d735b,eee82da79f036bb49ff80d3088b9530e3c2e57eb,"selftests/bpf: Add netkit to tc_redirect selftest + +Extend the existing tc_redirect selftest to also cover netkit devices +for exercising the bpf_redirect_peer() code paths"," so that we have both +veth as well as netkit covered","[' all tests still pass after this change.\n\nSigned-off-by: Daniel Borkmann \nAcked-by: Stanislav Fomichev \nReviewed-by: Nikolay Aleksandrov \nLink: https://lore.kernel.org/r/20231114004220.6495-9-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']",Extend tc_redirect selftest to include netkit devices for bpf_redirect_peer() path coverage.,"tc_redirect,selftests,netkit",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tc/netfilter like programs'] +eee82da79f036bb49ff80d3088b9530e3c2e57eb,eee82da79f036bb49ff80d3088b9530e3c2e57eb,Daniel Borkmann,daniel@iogearbox.net,1699922539,Martin KaFai Lau,martin.lau@kernel.org,1700504116,9a3932c60b5b02cc4a12eaa0e89109c037b684b8,2c225425704078282e152ba692649237f78b3d7a,"selftests/bpf: De-veth-ize the tc_redirect test case + +No functional changes to the test case", but just renaming various functions,"['\nvariables', ' etc', ' to remove veth part of their name for making it more generic\nand reusable later on (e.g. for netkit).\n\nSigned-off-by: Daniel Borkmann \nAcked-by: Stanislav Fomichev \nReviewed-by: Nikolay Aleksandrov \nLink: https://lore.kernel.org/r/20231114004220.6495-8-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']",Renamed functions in the tc_redirect test case without functional changes.,"selftests,bpf,tc_redirect",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tc/netfilter like programs'] +2c225425704078282e152ba692649237f78b3d7a,2c225425704078282e152ba692649237f78b3d7a,Daniel Borkmann,daniel@iogearbox.net,1699922538,Martin KaFai Lau,martin.lau@kernel.org,1700504116,4e96deef285ebb130c3d8904010d2920c81160c2,024ee930cb3c9ae49e4266aee89cfde0ebb407e1,bpf," netkit: Add indirect call wrapper for fetching peer dev + +ndo_get_peer_dev is used in tcx BPF fast path","[' therefore make use of\nindirect call wrapper and therefore optimize the bpf_redirect_peer()\ninternal handling a bit. Add a small skb_get_peer_dev() wrapper which\nutilizes the INDIRECT_CALL_1() macro instead of open coding.\n\nFuture work could potentially add a peer pointer directly into struct\nnet_device in future and convert veth and netkit over to use it so\nthat eventually ndo_get_peer_dev can be removed.\n\nCo-developed-by: Nikolay Aleksandrov \nSigned-off-by: Nikolay Aleksandrov \nSigned-off-by: Daniel Borkmann \nAcked-by: Stanislav Fomichev \nLink: https://lore.kernel.org/r/20231114004220.6495-7-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']",Add indirect call wrapper for fetching peer device in tcx BPF fast path.,"indirect, call, peer",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['tc/netfilter like programs'] +024ee930cb3c9ae49e4266aee89cfde0ebb407e1,024ee930cb3c9ae49e4266aee89cfde0ebb407e1,Peilin Ye,peilin.ye@bytedance.com,1699922537,Martin KaFai Lau,martin.lau@kernel.org,1700504116,06be9235f5eaf8e273fdaf855b488b83effb846d,6f2684bf2b4460c84d0d34612a939f78b96b03fc,"bpf: Fix dev's rx stats for bpf_redirect_peer traffic + +Traffic redirected by bpf_redirect_peer() (used by recent CNIs like Cilium) +is not accounted for in the RX stats of supported devices (that is"," veth +and netkit)","[' confusing user space metrics collectors such as cAdvisor [0]', '\nas reported by Youlun.\n\nFix it by calling dev_sw_netstats_rx_add() in skb_do_redirect()', ' to update\nRX traffic counters. Devices that support ndo_get_peer_dev _must_ use the\n@tstats per-CPU counters (instead of @lstats', ' or @dstats).\n\nTo make this more fool-proof', ' error out when ndo_get_peer_dev is set but\n@tstats are not selected.\n\n [0] Specifically', ' the ""container_network_receive_{byte', 'packet}s_total""\n counters are affected.\n\nFixes: 9aa1206e8f48 (""bpf: Add redirect_peer helper"")\nReported-by: Youlun Zhang \nSigned-off-by: Peilin Ye \nCo-developed-by: Daniel Borkmann \nSigned-off-by: Daniel Borkmann \nReviewed-by: Nikolay Aleksandrov \nLink: https://lore.kernel.org/r/20231114004220.6495-6-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']",Fixes RX stats accounting for traffic redirected by bpf_redirect_peer on supported devices.,"bpf_redirect_peer,RX stats,traffic",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tc/netfilter like programs'] +6f2684bf2b4460c84d0d34612a939f78b96b03fc,6f2684bf2b4460c84d0d34612a939f78b96b03fc,Peilin Ye,peilin.ye@bytedance.com,1699922536,Martin KaFai Lau,martin.lau@kernel.org,1700504116,83be66f79bbe1a74d7681580f68868a37fdccadf,ae1658272c6491a31ac968e39882fc569f312ac3,"veth: Use tstats per-CPU traffic counters + +Currently veth devices use the lstats per-CPU traffic counters"," which only +cover TX traffic. veth_get_stats64() actually populates RX stats of a veth +device from its peer's TX counters","[' based on the assumption that a veth\ndevice can _only_ receive packets from its peer', ' which is no longer true:\n\nFor example', "" recent CNIs (like Cilium) can use the bpf_redirect_peer() BPF\nhelper to redirect traffic from NIC's tc ingress to veth's tc ingress (in\na different netns)"", "" skipping veth's peer device. Unfortunately"", "" this kind\nof traffic isn't currently accounted for in veth's RX stats.\n\nIn preparation for the fix"", "" use tstats (instead of lstats) to maintain\nboth RX and TX counters for each veth device. We'll use RX counters for\nbpf_redirect_peer() traffic"", ' and keep using TX counters for the usual\n""peer-to-peer"" traffic. In veth_get_stats64()', "" calculate RX stats by\n_adding_ RX count to peer's TX count"", ' in order to cover both kinds of\ntraffic.\n\nveth_stats_rx() might need a name change (perhaps to ""veth_stats_xdp()"")\nfor less confusion', "" but let's leave it to another patch to keep the fix\nminimal.\n\nSigned-off-by: Peilin Ye \nCo-developed-by: Daniel Borkmann \nSigned-off-by: Daniel Borkmann \nReviewed-by: Nikolay Aleksandrov \nLink: https://lore.kernel.org/r/20231114004220.6495-5-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n"", '']",Improve veth device traffic statistics by using tstats per-CPU counters for RX and TX.,"veth, per-CPU, traffic",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +3e124aa6cb5e74308f5997f63ebd3e5badb5c4e7,3e124aa6cb5e74308f5997f63ebd3e5badb5c4e7,Alexei Starovoitov,ast@kernel.org,1700423025,Alexei Starovoitov,ast@kernel.org,1700423032,03207b5d4cbc3593a51decfb3dac6b755636f5b4,16b3129e14bf2e7505512568b11c437c840a0c19 ac8148d957f50434411a0c15a2e4f352b5bb4ff2,"Merge branch 'bpf-kernel-bpf-task_iter-c-don-t-abuse-next_thread' + +Oleg Nesterov says: + +==================== +bpf: kernel/bpf/task_iter.c: don't abuse next_thread() + +Compile tested. + +Every lockless usage of next_thread() was wrong"," bpf/task_iter.c is +the last user and is no exception. + +==================== + +Link: https://lore.kernel.org/r/20231114163211.GA874@redhat.com +Signed-off-by: Alexei Starovoitov +",[''],Fixes incorrect lockless usage of next_thread() in bpf/task_iter.c.,"bpf,task_iter,next_thread",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ac8148d957f50434411a0c15a2e4f352b5bb4ff2,ac8148d957f50434411a0c15a2e4f352b5bb4ff2,Oleg Nesterov,oleg@redhat.com,1699979559,Alexei Starovoitov,ast@kernel.org,1700423024,03207b5d4cbc3593a51decfb3dac6b755636f5b4,5a34f9dabd9aa567e2d37e1aa27a67f80acfaa1c,"bpf: bpf_iter_task_next: use next_task(kit->task) rather than next_task(kit->pos) + +This looks more clear and simplifies the code. While at it"," remove the +unnecessary initialization of pos/task at the start of bpf_iter_task_new(). + +Note that we can even kill kit->task","[' we can just use pos->group_leader', ""\nbut I don't understand the BUILD_BUG_ON() checks in bpf_iter_task_new().\n\nSigned-off-by: Oleg Nesterov \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231114163239.GA903@redhat.com\nSigned-off-by: Alexei Starovoitov \n"", '']",Simplifies bpf_iter_task_next by using next_task(kit->task) and removing unnecessary initialization.,"simplifies,next_task,initialization",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +5a34f9dabd9aa567e2d37e1aa27a67f80acfaa1c,5a34f9dabd9aa567e2d37e1aa27a67f80acfaa1c,Oleg Nesterov,oleg@redhat.com,1699979557,Alexei Starovoitov,ast@kernel.org,1700423024,c070c12042571603f0516ae4a95be695cb98dc00,2d1618054f25e11c44d189dbff4a60342a4cfb4b,"bpf: bpf_iter_task_next: use __next_thread() rather than next_thread() + +Lockless use of next_thread() should be avoided"," kernel/bpf/task_iter.c +is the last user and the usage is wrong. + +bpf_iter_task_next() can loop forever","[' ""kit->pos == kit->task"" can never\nhappen if kit->pos execs. Change this code to use __next_thread().\n\nWith or without this change the usage of kit->pos/task and next_task()\ndoesn\'t look nice', ' see the next patch.\n\nSigned-off-by: Oleg Nesterov \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231114163237.GA897@redhat.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit replaces next_thread() with __next_thread() in bpf_iter_task_next to prevent infinite loops.,"bpf_iter_task_next, next_thread, lockless",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2d1618054f25e11c44d189dbff4a60342a4cfb4b,2d1618054f25e11c44d189dbff4a60342a4cfb4b,Oleg Nesterov,oleg@redhat.com,1699979554,Alexei Starovoitov,ast@kernel.org,1700423024,f801475761d64aa6bdaed25a183a7cc23efbce55,16b3129e14bf2e7505512568b11c437c840a0c19,"bpf: task_group_seq_get_next: use __next_thread() rather than next_thread() + +Lockless use of next_thread() should be avoided"," kernel/bpf/task_iter.c +is the last user and the usage is wrong. + +task_group_seq_get_next() can return the group leader twice if it races +with mt-thread exec which changes the group->leader's pid. + +Change the main loop to use __next_thread()","[' kill ""next_tid == common->pid""\ncheck.\n\n__next_thread() can\'t loop forever', ' we can also change this code to retry\nif next_tid == 0.\n\nSigned-off-by: Oleg Nesterov \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231114163234.GA890@redhat.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit changes task_group_seq_get_next to use __next_thread() for thread iterating in BPF task iterator.,"next_thread, lockless, task_group_seq_get_next",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +16b3129e14bf2e7505512568b11c437c840a0c19,16b3129e14bf2e7505512568b11c437c840a0c19,Alexei Starovoitov,ast@kernel.org,1700336399,Alexei Starovoitov,ast@kernel.org,1700336400,c9df3007d849646ad84684b894fa8350a6d8e949,ff8867af01daa7ea770bebf5f91199b7434b74e5 46862ee854b4f5a315d63b677ca3af14a89aefeb,"Merge branch 'bpf-verifier-log-improvements' + +Andrii Nakryiko says: + +==================== +BPF verifier log improvements + +This patch set moves a big chunk of verifier log related code from gigantic +verifier.c file into more focused kernel/bpf/log.c. This is not essential to +the rest of functionality in this patch set", so I can undo it,"["" but it felt\nlike it's good to start chipping away from 20K+ verifier.c whenever we can.\n\nThe main purpose of the patch set"", ' though', "" is in improving verifier log\nfurther.\n\nPatches #3-#4 start printing out register state even if that register is\nspilled into stack slot. Previously we'd get only spilled register type"", ' but\nno additional information', "" like SCALAR_VALUE's ranges. Super limiting during\ndebugging. For cases of register spills smaller than 8 bytes"", ' we also print\nout STACK_MISC/STACK_ZERO/STACK_INVALID markers. This', ' among other things', '\nwill make it easier to write tests for these mixed spill/misc cases.\n\nPatch #5 prints map name for PTR_TO_MAP_VALUE/PTR_TO_MAP_KEY/CONST_PTR_TO_MAP\nregisters. In big production BPF programs', "" it's important to map assembly to\nactual map"", "" and it's often non-trivial. Having map name helps.\n\nPatch #6 just removes visual noise in form of ubiquitous imm=0 and off=0. They\nare default values"", ' omit them.\n\nPatch #7 is probably the most controversial', ' but it reworks how verifier log\nprints numbers. For small valued integers we use decimals', ' but for large ones\nwe switch to hexadecimal. From personal experience this is a much more useful\nconvention. We can tune what consitutes ""small value""', "" for now it's 16-bit\nrange.\n\nPatch #8 prints frame number for PTR_TO_CTX registers"", ' if that frame is\ndifferent from the ""current"" one. This removes ambiguity and confusion', '\nespecially in complicated cases with multiple subprogs passing around\npointers.\n\nv2->v3:\n - adjust reg_bounds tester to parse hex form of reg state as well;\n - print reg->range as unsigned (Alexei);\nv1->v2:\n - use verbose_snum() for range and offset in register state (Eduard);\n - fixed typos and added acks from Eduard and Stanislav.\n====================\n\nLink: https://lore.kernel.org/r/20231118034623.3320920-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Refactor verifier logs into separate log.c file for better code organization.,"verifier, log, refactor",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +46862ee854b4f5a315d63b677ca3af14a89aefeb,46862ee854b4f5a315d63b677ca3af14a89aefeb,Andrii Nakryiko,andrii@kernel.org,1700279183,Alexei Starovoitov,ast@kernel.org,1700336399,c9df3007d849646ad84684b894fa8350a6d8e949,0f8dbdbc641b45a5fa31d497f9fc83ffe1174fa3,"bpf: emit frameno for PTR_TO_STACK regs if it differs from current one + +It's possible to pass a pointer to parent's stack to child subprogs. In +such case verifier state output is ambiguous not showing whether +register container a pointer to ""current"" stack"," belonging to current +subprog (frame)","["" or it's actually a pointer to one of parent frames.\n\nSo emit this information if frame number differs between the state which\nregister is part of. E.g."", ' if current state is in frame 2 and it has\na register pointing to stack in grand parent state (frame #0)', "" we'll see\nsomething like 'R1=fp[0]-16'"", ' while ""local stack pointer"" will be just\n\'R2=fp-16\'.\n\nAcked-by: Eduard Zingerman \nAcked-by: Stanislav Fomichev \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231118034623.3320920-9-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Emit frame number for PTR_TO_STACK registers when it differs from the current frame in eBPF verifier.,"PTR_TO_STACK,verifier,frame",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0f8dbdbc641b45a5fa31d497f9fc83ffe1174fa3,0f8dbdbc641b45a5fa31d497f9fc83ffe1174fa3,Andrii Nakryiko,andrii@kernel.org,1700279182,Alexei Starovoitov,ast@kernel.org,1700336399,61c1b84c3d0a9bf8c43a17438d126b24d53cbd8c,1db747d75b1dbe17bf4283ed87bd3b7a92010f34,"bpf: smarter verifier log number printing logic + +Instead of always printing numbers as either decimals (and in some +cases"," like for ""imm=%llx""","[' in hexadecimals)', ' decide the form based on\nactual values. For numbers in a reasonably small range (currently', '\n[0', ' U16_MAX] for unsigned values', ' and [S16_MIN', ' S16_MAX] for signed ones)', '\nemit them as decimals. In all other cases', ' even for signed values', ""\nemit them in hexadecimals.\n\nFor large values hex form is often times way more useful: it's easier to\nsee an exact difference between 0xffffffff80000000 and 0xffffffff7fffffff"", '\nthan between 18446744071562067966 and 18446744071562067967', ' as one\nparticular example.\n\nSmall values representing small pointer offsets or application\nconstants', ' on the other hand', ' are way more useful to be represented in\ndecimal notation.\n\nAdjust reg_bounds register state parsing logic to take into account this\nchange.\n\nAcked-by: Eduard Zingerman \nAcked-by: Stanislav Fomichev \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231118034623.3320920-8-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Improve verifier log number printing logic for better readability and understanding.,"verifier,log,printing",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1db747d75b1dbe17bf4283ed87bd3b7a92010f34,1db747d75b1dbe17bf4283ed87bd3b7a92010f34,Andrii Nakryiko,andrii@kernel.org,1700279181,Alexei Starovoitov,ast@kernel.org,1700336399,d266e1595982f440d336448b39d0a3c26974ea6a,0c95c9fdb696f35c7864785ba84cb9a50152daff,"bpf: omit default off=0 and imm=0 in register state log + +Simplify BPF verifier log further by omitting default (and frequently +irrelevant) off=0 and imm=0 parts for non-SCALAR_VALUE registers. As can +be seen from fixed tests"," this is often a visual noise for PTR_TO_CTX +register and even for PTR_TO_PACKET registers. + +Omitting default values follows the rest of register state logic: we +omit default values to keep verifier log succinct and to highlight +interesting state that deviates from default one. E.g.","[' we do the same\nfor var_off', "" when it's unknown"", ' which gives no additional information.\n\nAcked-by: Eduard Zingerman \nAcked-by: Stanislav Fomichev \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231118034623.3320920-7-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Simplified BPF verifier log by omitting default off=0 and imm=0 for non-SCALAR_VALUE registers.,"BPF verifier, default, registers",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0c95c9fdb696f35c7864785ba84cb9a50152daff,0c95c9fdb696f35c7864785ba84cb9a50152daff,Andrii Nakryiko,andrii@kernel.org,1700279180,Alexei Starovoitov,ast@kernel.org,1700336399,909fcb7acbc43862d80a67c68c62e4b41b09b16d,67d43dfbb42d6575304daea67733c88fbf536a1c,"bpf: emit map name in register state if applicable and available + +In complicated real-world applications"," whenever debugging some +verification error through verifier log","[' it often would be very useful\nto see map name for PTR_TO_MAP_VALUE register. Usually this needs to be\ninferred from key/value sizes and maybe trying to guess C code location', ""\nbut it's not always clear.\n\nGiven verifier has the name"", "" and it's never too long"", "" let's just emit it\nfor ptr_to_map_key"", ' ptr_to_map_value', ' and const_ptr_to_map registers. We\nreshuffle the order a bit', ' so that map name', ' key size', ' and value size\nappear before offset and immediate values', ' which seems like a more\nlogical order.\n\nCurrent output:\n\n R1_w=map_ptr(map=array_map', 'ks=4', 'vs=8', 'off=0', ""imm=0)\n\nBut we'll get rid of useless off=0 and imm=0 parts in the next patch.\n\nAcked-by: Eduard Zingerman \nAcked-by: Stanislav Fomichev \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231118034623.3320920-6-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",Emit the map name in the register state for better debugging in verifier logs.,"map name, register state, verifier",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +67d43dfbb42d6575304daea67733c88fbf536a1c,67d43dfbb42d6575304daea67733c88fbf536a1c,Andrii Nakryiko,andrii@kernel.org,1700279179,Alexei Starovoitov,ast@kernel.org,1700336399,0d7c2a45e9b36277fa9e1b6f0b09f5735b74617d,009f5465be3636e9ce795cfbd5d3109d8978774d,"bpf: print spilled register state in stack slot + +Print the same register state representation when printing stack state"," +as we do for normal registers. Note that if stack slot contains +subregister spill (1","[' 2', ' or 4 byte long)', ' we\'ll still emit ""m0?"" mask\nfor those bytes that are not part of spilled register.\n\nWhile means we can get something like fp-8=0000scalar() for a 4-byte\nspill with other 4 bytes still being STACK_ZERO.\n\nSome example before and after', ' taken from the log of\npyperf_subprogs.bpf.o:\n\n49: (7b) *(u64 *)(r10 -256) = r1 ; frame1: R1_w=ctx(off=0', 'imm=0) R10=fp0 fp-256_w=ctx\n49: (7b) *(u64 *)(r10 -256) = r1 ; frame1: R1_w=ctx(off=0', 'imm=0) R10=fp0 fp-256_w=ctx(off=0', 'imm=0)\n\n150: (7b) *(u64 *)(r10 -264) = r0 ; frame1: R0_w=map_value_or_null(id=6', 'off=0', 'ks=192', 'vs=4', 'imm=0) R10=fp0 fp-264_w=map_value_or_null\n150: (7b) *(u64 *)(r10 -264) = r0 ; frame1: R0_w=map_value_or_null(id=6', 'off=0', 'ks=192', 'vs=4', 'imm=0) R10=fp0 fp-264_w=map_value_or_null(id=6', 'off=0', 'ks=192', 'vs=4', 'imm=0)\n\n5192: (61) r1 = *(u32 *)(r10 -272) ; frame1: R1_w=scalar(smin=smin32=0', 'smax=umax=smax32=umax32=15', 'var_off=(0x0; 0xf)) R10=fp0 fp-272=\n5192: (61) r1 = *(u32 *)(r10 -272) ; frame1: R1_w=scalar(smin=smin32=0', 'smax=umax=smax32=umax32=15', 'var_off=(0x0; 0xf)) R10=fp0 fp-272=????scalar(smin=smin32=0', 'smax=umax=smax32=umax32=15', 'var_off=(0x0; 0xf))\n\nWhile at it', ' do a few other simple clean ups:\n - skip slot if it\'s not scratched before detecting whether it\'s valid;\n - move taking spilled_reg pointer outside of switch (only DYNPTR has\n to adjust that to get to the ""main"" slot);\n - don\'t recalculate types_buf second time for MISC/ZERO/default case.\n\nAcked-by: Eduard Zingerman \nAcked-by: Stanislav Fomichev \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231118034623.3320920-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Improve stack slot state printing in bpf to match register state representation.,"register, printing, stack",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +009f5465be3636e9ce795cfbd5d3109d8978774d,009f5465be3636e9ce795cfbd5d3109d8978774d,Andrii Nakryiko,andrii@kernel.org,1700279178,Alexei Starovoitov,ast@kernel.org,1700336399,002d13a634eec591e43f86ef1c86db862dd26eec,42feb6620accded89cad5f455665e21281813d79,"bpf: extract register state printing + +Extract printing register state representation logic into a separate +helper"," as we are going to reuse it for spilled register state printing +in the next patch. This also nicely reduces code nestedness. + +No functional changes. + +Acked-by: Eduard Zingerman +Acked-by: Stanislav Fomichev +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231118034623.3320920-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Extract register state printing logic into a helper for reuse and code clarity.,"printing, helper, state",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +42feb6620accded89cad5f455665e21281813d79,42feb6620accded89cad5f455665e21281813d79,Andrii Nakryiko,andrii@kernel.org,1700279177,Alexei Starovoitov,ast@kernel.org,1700336399,10e86130a1ca8f75d94808db3f03ca7d14e06749,db840d389bad60ce6f3aadc1079da13e7e993a16,"bpf: move verifier state printing code to kernel/bpf/log.c + +Move a good chunk of code from verifier.c to log.c: verifier state +verbose printing logic. This is an important and very much +logging/debugging oriented code. It fits the overlall log.c's focus on +verifier logging"," and moving it allows to keep growing it without +unnecessarily adding to verifier.c code that otherwise contains a core +verification logic. + +There are not many shared dependencies between this code and the rest of +verifier.c code","[' except a few single-line helpers for various register\ntype checks and a bit of state ""scratching"" helpers. We move all such\ntrivial helpers into include/bpf/bpf_verifier.h as static inlines.\n\nNo functional changes in this patch.\n\nAcked-by: Eduard Zingerman \nAcked-by: Stanislav Fomichev \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231118034623.3320920-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Refactor verifier state verbose printing logic from verifier.c to log.c to improve focus on verifier logging without adding complexity.,"verifier, logging, refactor",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +db840d389bad60ce6f3aadc1079da13e7e993a16,db840d389bad60ce6f3aadc1079da13e7e993a16,Andrii Nakryiko,andrii@kernel.org,1700279176,Alexei Starovoitov,ast@kernel.org,1700336398,e9a49caa3606ba2d29c27cc6fc891be2b1656187,ff8867af01daa7ea770bebf5f91199b7434b74e5,"bpf: move verbose_linfo() into kernel/bpf/log.c + +verifier.c is huge. Let's try to move out parts that are logging-related +into log.c"," as we previously did with bpf_log() and other related stuff. +This patch moves line info verbose output routines: it's pretty +self-contained and isolated code","[' so there is no problem with this.\n\nAcked-by: Eduard Zingerman \nAcked-by: Stanislav Fomichev \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231118034623.3320920-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Moved verbose logging functions from verifier.c to log.c to reduce file size.,"verbose logging, log, bpf",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ff8867af01daa7ea770bebf5f91199b7434b74e5,ff8867af01daa7ea770bebf5f91199b7434b74e5,Andrii Nakryiko,andrii@kernel.org,1700241244,Alexei Starovoitov,ast@kernel.org,1700245802,d298636c0a548e3c27bc8c18a645745f456c4fa2,5fa201f37c2ef58a0f821e656d794af89b3a1738,"bpf: rename BPF_F_TEST_SANITY_STRICT to BPF_F_TEST_REG_INVARIANTS + +Rename verifier internal flag BPF_F_TEST_SANITY_STRICT to more neutral +BPF_F_TEST_REG_INVARIANTS. This is a follow up to [0]. + +A few selftests and veristat need to be adjusted in the same patch as +well. + + [0] https://patchwork.kernel.org/project/netdevbpf/patch/20231112010609.848406-5-andrii@kernel.org/ + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231117171404.225508-1-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,The commit renames an internal verifier flag and updates related selftests and veristat.,"rename, verifier, flag",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e9cdebbe23f1aa9a1caea169862f479ab3fa2773,e9cdebbe23f1aa9a1caea169862f479ab3fa2773,Jordan Rife,jrife@google.com,1699305878,David Teigland,teigland@redhat.com,1700157522,b27945908a655317eb50fbb3b459dc45b63eb686,b85ea95d086471afb4ad062012a4d73cd328fa86,"dlm: use kernel_connect() and kernel_bind() + +Recent changes to kernel_connect() and kernel_bind() ensure that +callers are insulated from changes to the address parameter made by BPF +SOCK_ADDR hooks. This patch wraps direct calls to ops->connect() and +ops->bind() with kernel_connect() and kernel_bind() to protect callers +in such cases. + +Link: https://lore.kernel.org/netdev/9944248dba1bce861375fcce9de663934d933ba9.camel@redhat.com/ +Fixes: d74bad4e74ee (""bpf: Hooks for sys_connect"") +Fixes: 4fbac77d2d09 (""bpf: Hooks for sys_bind"") +Cc: stable@vger.kernel.org +Signed-off-by: Jordan Rife +Signed-off-by: David Teigland +",,Wraps direct calls to connect and bind operations with kernel_connect and kernel_bind for address parameter protection.,"kernel_connect,kernel_bind,BPF",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['socket like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7475e51b87969e01a6812eac713a1c8310372e8a,7475e51b87969e01a6812eac713a1c8310372e8a,Linus Torvalds,torvalds@linux-foundation.org,1700139086,Linus Torvalds,torvalds@linux-foundation.org,1700139086,350f6dcea18fb09fdb70179e8e7ae3e40d470896,6eb1acd9766a0dc9d85927843d85787408395e15 cff088d924df871296412e6b819823f42d1bb9a5,"Merge tag 'net-6.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + ""Including fixes from BPF and netfilter. + + Current release - regressions: + + - core: fix undefined behavior in netdev name allocation + + - bpf: do not allocate percpu memory at init stage + + - netfilter: nf_tables: split async and sync catchall in two + functions + + - mptcp: fix possible NULL pointer dereference on close + + Current release - new code bugs: + + - eth: ice: dpll: fix initial lock status of dpll + + Previous releases - regressions: + + - bpf: fix precision backtracking instruction iteration + + - af_unix: fix use-after-free in unix_stream_read_actor() + + - tipc: fix kernel-infoleak due to uninitialized TLV value + + - eth: bonding: stop the device in bond_setup_by_slave() + + - eth: mlx5: + - fix double free of encap_header + - avoid referencing skb after free-ing in drop path + + - eth: hns3: fix VF reset + + - eth: mvneta: fix calls to page_pool_get_stats + + Previous releases - always broken: + + - core: set SOCK_RCU_FREE before inserting socket into hashtable + + - bpf: fix control-flow graph checking in privileged mode + + - eth: ppp: limit MRU to 64K + + - eth: stmmac: avoid rx queue overrun + + - eth: icssg-prueth: fix error cleanup on failing initialization + + - eth: hns3: fix out-of-bounds access may occur when coalesce info is + read via debugfs + + - eth: cortina: handle large frames + + Misc: + + - selftests: gso: support CONFIG_MAX_SKB_FRAGS up to 45"" + +* tag 'net-6.7-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (78 commits) + macvlan: Don't propagate promisc change to lower dev in passthru + net: sched: do not offload flows with a helper in act_ct + net/mlx5e: Check return value of snprintf writing to fw_version buffer for representors + net/mlx5e: Check return value of snprintf writing to fw_version buffer + net/mlx5e: Reduce the size of icosq_str + net/mlx5: Increase size of irq name buffer + net/mlx5e: Update doorbell for port timestamping CQ before the software counter + net/mlx5e: Track xmit submission to PTP WQ after populating metadata map + net/mlx5e: Avoid referencing skb after free-ing in drop path of mlx5e_sq_xmit_wqe + net/mlx5e: Don't modify the peer sent-to-vport rules for IPSec offload + net/mlx5e: Fix pedit endianness + net/mlx5e: fix double free of encap_header in update funcs + net/mlx5e: fix double free of encap_header + net/mlx5: Decouple PHC .adjtime and .adjphase implementations + net/mlx5: DR"," Allow old devices to use multi destination FTE + net/mlx5: Free used cpus mask when an IRQ is released + Revert ""net/mlx5: DR","[' Supporting inline WQE when possible""\n bpf: Do not allocate percpu memory at init stage\n net: Fix undefined behavior in netdev name allocation\n dt-bindings: net: ethernet-controller: Fix formatting error\n ...\n', '']","This commit merges networking fixes including BPF, netfilter, and other network driver issues.","networking, fixes, BPF",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a6a6a0a9fdb03af10513b5bb48e5419563f54413,a6a6a0a9fdb03af10513b5bb48e5419563f54413,Jakub Kicinski,kuba@kernel.org,1700116082,Jakub Kicinski,kuba@kernel.org,1700116082,08f030e7683a615060f4e43f86f6f508d73018e4,674e318089468ece99aef4796eaef7add57f36b2 1fda5bb66ad8fb24ecb3858e61a13a6548428898,"Merge https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Alexei Starovoitov says: + +==================== +pull-request: bpf 2023-11-15 + +We've added 7 non-merge commits during the last 6 day(s) which contain +a total of 9 files changed", 200 insertions(+),"[' 49 deletions(-).\n\nThe main changes are:\n\n1) Do not allocate bpf specific percpu memory unconditionally', ' from Yonghong.\n\n2) Fix precision backtracking instruction iteration', ' from Andrii.\n\n3) Fix control flow graph checking', ' from Andrii.\n\n4) Fix xskxceiver selftest build', ' from Anders.\n\n* https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n bpf: Do not allocate percpu memory at init stage\n selftests/bpf: add more test cases for check_cfg()\n bpf: fix control-flow graph checking in privileged mode\n selftests/bpf: add edge case backtracking logic test\n bpf: fix precision backtracking instruction iteration\n bpf: handle ldimm64 properly in check_cfg()\n selftests: bpf: xskxceiver: ksft_print_msg: fix format type error\n====================\n\nLink: https://lore.kernel.org/r/20231115214949.48854-1-alexei.starovoitov@gmail.com\nSigned-off-by: Jakub Kicinski \n', '']",Merge pull request integrating 7 non-merge commits into BPF tree.,"merge,BPF,commits",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5fa201f37c2ef58a0f821e656d794af89b3a1738,5fa201f37c2ef58a0f821e656d794af89b3a1738,Puranjay Mohan,puranjay12@gmail.com,1699638710,Alexei Starovoitov,ast@kernel.org,1700081187,5e9c2c4777548cfeb8e111d7f71b6729b0be4284,9cea90c01f4bddfb4cea12a9c23eef6414714503,"bpf: Remove test for MOVSX32 with offset=32 + +MOVSX32 only supports sign extending 8-bit and 16-bit operands into 32 +bit operands. The ""ALU_MOVSX | BPF_W"" test tries to sign extend a 32 bit +operand into a 32 bit operand which is equivalent to a normal BPF_MOV. + +Remove this test as it tries to run an invalid instruction. + +Fixes: daabb2b098e0 (""bpf/tests: add tests for cpuv4 instructions"") +Signed-off-by: Puranjay Mohan +Reported-by: kernel test robot +Closes: https://lore.kernel.org/oe-lkp/202310111838.46ff5b6a-oliver.sang@intel.com +Acked-by: Stanislav Fomichev +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231110175150.87803-1-puranjay12@gmail.com +Signed-off-by: Alexei Starovoitov +",,Removed a test for an invalid MOVSX32 instruction with offset in BPF.,"MOVSX32, test, invalid",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9cea90c01f4bddfb4cea12a9c23eef6414714503,9cea90c01f4bddfb4cea12a9c23eef6414714503,Alexei Starovoitov,ast@kernel.org,1700078623,Alexei Starovoitov,ast@kernel.org,1700078623,53c9ef81ba24ac689a43f5309b6b4630df2eaefd,81427a62a22148cdc85db38a6fbe487d0d2044b6 882e3d873c2d8a2aebbc6c192aa1a2990b9d5b27,"Merge branch 'bpf-register-bounds-range-vs-range-support' + +Andrii Nakryiko says: + +==================== +BPF register bounds range vs range support + +This patch set is a continuation of work started in [0]. It adds a big set of +manual", auto-generated,"["" and now also random test cases validating BPF\nverifier's register bounds tracking and deduction logic.\n\nFirst few patches generalize verifier's logic to handle conditional jumps and\ncorresponding range adjustments in case when two non-const registers are\ncompared to each other. Patch #1 generalizes reg_set_min_max() portion"", ' while\npatch #2 does the same for is_branch_taken() part of the overall solution.\n\nPatch #3 improves equality and inequality for cases when BPF program code\nmixes 64-bit and 32-bit uses of the same register. Depending on specific\nsequence', "" it's possible to get to the point where u64/s64 bounds will be very\ngeneric (e.g."", ' after signed 32-bit comparison)', ' while we still keep pretty\ntight u32/s32 bounds. If in such state we proceed with 32-bit equality or\ninequality comparison', "" reg_set_min_max() might have to deal with adjusting s32\nbounds for two registers that don't overlap"", "" which breaks reg_set_min_max().\nThis doesn't manifest in vs cases"", ' because if that happens\nreg_set_min_max() in effect will force s32 bounds to be a new ""impossible""\nconstant (from original smin32/smax32 bounds point of view). Things get tricky\nwhen we have vs adjustments', ' so instead of trying to somehow\nmake sense out of such situations', "" it's best to detect such impossible\nsituations and prune the branch that can't be taken in is_branch_taken()\nlogic. This equality/inequality was the only such category of situations with\nauto-generated tests added later in the patch set.\n\nBut when we start mixing arithmetic operations in different numeric domains\nand conditionals"", ' things get even hairier. So', ' patch #4 adds sanity checking\nlogic after all ALU/ALU64', ' JMP/JMP32', ' and LDX operations. By default', ' instead\nof failing verification', ' we conservatively reset range bounds to unknown\nvalues', ' reporting violation in verifier log (if verbose logs are requested).\nBut to aid development', ' detection', ' and debugging', ' we also introduce a new test\nflag', ' BPF_F_TEST_SANITY_STRICT', ' which triggers verification failure on range\nsanity violation.\n\nPatch #11 sets BPF_F_TEST_SANITY_STRICT by default for test_progs and\ntest_verifier. Patch #12 adds support for controlling this in veristat for\ntesting with production BPF object files.\n\nGetting back to BPF verifier', "" patches #5 and #6 complete verifier's range\ntracking logic clean up. See respective patches for details.\n\nWith kernel-side taken care of"", ' we move to testing. We start with building\na tester that validates existing vs verifier logic for range\nbounds. Patch #7 implements an initial version of such a tester. We guard\nmillions of generated tests behind SLOW_TESTS=1 envvar requirement', ' but also\nhave a relatively small number of tricky cases that came up during development\nand debugging of this work. Those will be executed as part of a normal\ntest_progs run.\n\nPatch #8 simulates more nuanced JEQ/JNE logic we added to verifier in patch #3.\nPatch #9 adds vs ""slow tests"".\n\nPatch #10 is a completely new one', ' it adds a bunch of randomly generated cases\nto be run normally', ' without SLOW_TESTS=1 guard. This should help to get\na bunch of cover', ' and hopefully find some remaining latent problems if\nverifier proactively as part of normal BPF CI runs.\n\nFinally', ' a tiny test which was', ' amazingly', ' an initial motivation for this\nwhole work', ' is added in lucky patch #13', "" demonstrating how verifier is now\nsmart enough to track actual number of elements in the array and won't require\nadditional checks on loop iteration variable inside the bpf_for() open-coded\niterator loop.\n\n [0] https://patchwork.kernel.org/project/netdevbpf/list/?series=798308&state=*\n\nv1->v2:\n - use x < y => y > x property to minimize reg_set_min_max (Eduard);\n - fix for JEQ/JNE logic in reg_bounds.c (Eduard);\n - split BPF_JSET and !BPF_JSET cases handling (Shung-Hsi);\n - adjustments to reg_bounds.c to make it easier to follow (Alexei);\n - added acks (Eduard"", ' Shung-Hsi).\n====================\n\nLink: https://lore.kernel.org/r/20231112010609.848406-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Merges changes related to BPF register bounds and range support.,"register bounds,range support,merge",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +882e3d873c2d8a2aebbc6c192aa1a2990b9d5b27,882e3d873c2d8a2aebbc6c192aa1a2990b9d5b27,Andrii Nakryiko,andrii@kernel.org,1699751169,Alexei Starovoitov,ast@kernel.org,1700078623,53c9ef81ba24ac689a43f5309b6b4630df2eaefd,a5c57f81eb2b5d6de4f46e47fd85be50d179bfd8,"selftests/bpf: add iter test requiring range x range logic + +Add a simple verifier test that requires deriving reg bounds for one +register from another register that's not a constant. This is +a realistic example of iterating elements of an array with fixed maximum +number of elements"," but smaller actual number of elements. + +This small example was an original motivation for doing this whole patch +set in the first place","[' yes.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231112010609.848406-14-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add a verifier test for range x range logic in selftests for BPF.,"verifier,test,selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8c5677f8b31e92b57be7d5d0fbb1ac66eedf4f91,8c5677f8b31e92b57be7d5d0fbb1ac66eedf4f91,Andrii Nakryiko,andrii@kernel.org,1699751167,Alexei Starovoitov,ast@kernel.org,1700078622,411aa72cc5b0e5744fc11a1b7dee8b7bcc2f8d21,dab16659c50e8c9c7c5d9584beacec28c769dcca,"selftests/bpf: set BPF_F_TEST_SANITY_SCRIPT by default + +Make sure to set BPF_F_TEST_SANITY_STRICT program flag by default across +most verifier tests (and a bunch of others that set custom prog flags). + +There are currently two tests that do fail validation"," if enforced +strictly: verifier_bounds/crossing_64_bit_signed_boundary_2 and +verifier_bounds/crossing_32_bit_signed_boundary_2. To accommodate them","['\nwe teach test_loader a flag negation:\n\n__flag(!) will *clear* specified flag', ' allowing easy opt-out.\n\nWe apply __flag(!BPF_F_TEST_SANITY_STRICT) to these to tests.\n\nAlso sprinkle BPF_F_TEST_SANITY_STRICT everywhere where we already set\ntest-only BPF_F_TEST_RND_HI32 flag', ' for completeness.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231112010609.848406-12-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']","Default BPF_F_TEST_SANITY_STRICT flag across most verifier tests, except for two specific cases.","verifier, tests, flag",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dab16659c50e8c9c7c5d9584beacec28c769dcca,dab16659c50e8c9c7c5d9584beacec28c769dcca,Andrii Nakryiko,andrii@kernel.org,1699751166,Alexei Starovoitov,ast@kernel.org,1700078622,dfa59728581e7002275803c164274e5f3e735580,2b0d204e368b306d4db894749947ed591b667ec5,"selftests/bpf: add randomized reg_bounds tests + +Add random cases generation to reg_bounds.c and run them without +SLOW_TESTS=1 to increase a chance of BPF CI catching latent issues. + +Suggested-by: Alexei Starovoitov +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231112010609.848406-11-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add randomized test case generation to reg_bounds.c for better BPF CI coverage.,"randomized,reg_bounds,tests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2b0d204e368b306d4db894749947ed591b667ec5,2b0d204e368b306d4db894749947ed591b667ec5,Andrii Nakryiko,andrii@kernel.org,1699751165,Alexei Starovoitov,ast@kernel.org,1700078622,945d7b212d428d0d4100a89db98f5d8db96849b1,774f94c5e74d86d554c4fd1e97c517a1a7ee7fe0,"selftests/bpf: add range x range test to reg_bounds + +Now that verifier supports range vs range bounds adjustments"," validate +that by checking each generated range against every other generated +range","["" across all supported operators (everything by JSET).\n\nWe also add few cases that were problematic during development either\nfor verifier or for selftest's range tracking implementation.\n\nNote that we utilize the same trick with splitting everything into\nmultiple independent parallelizable tests"", ' but init_t and cond_t. This\nbrings down verification time in parallel mode from more than 8 hours\ndown to less that 1.5 hours. 106 million cases were successfully\nvalidate for range vs range logic', ' in addition to about 7 million range\nvs const cases', ' added in earlier patch.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231112010609.848406-10-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added a new range x range test case for reg_bounds in selftests to verify new verifier support.,"range,test,verifier",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +774f94c5e74d86d554c4fd1e97c517a1a7ee7fe0,774f94c5e74d86d554c4fd1e97c517a1a7ee7fe0,Andrii Nakryiko,andrii@kernel.org,1699751164,Alexei Starovoitov,ast@kernel.org,1700078622,b7a6bc96ec3eea83c9cd15bb719d98e1ae34483e,8863238993e23ccc6d5a9d4ff9f1c043f88f692e,"selftests/bpf: adjust OP_EQ/OP_NE handling to use subranges for branch taken + +Similar to kernel-side BPF verifier logic enhancements"," use 32-bit +subrange knowledge for is_branch_taken() logic in reg_bounds selftests. + +Signed-off-by: Andrii Nakryiko +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231112010609.848406-9-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Adjusted BPF selftests to use subrange logic for branch conditions similar to kernel verifier.,"BPF selftests, subrange logic, verifier",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8863238993e23ccc6d5a9d4ff9f1c043f88f692e,8863238993e23ccc6d5a9d4ff9f1c043f88f692e,Andrii Nakryiko,andrii@kernel.org,1699751163,Alexei Starovoitov,ast@kernel.org,1700078622,465cff98a7ef8c4cd681b44cad142ca035b66b32,cf5fe3c71c5a34ac0108afc550407c672d0a032d,"selftests/bpf: BPF register range bounds tester + +Add test to validate BPF verifier's register range bounds tracking logic. + +The main bulk is a lot of auto-generated tests based on a small set of +seed values for lower and upper 32 bits of full 64-bit values. +Currently we validate only range vs const comparisons"," but the idea is +to start validating range over range comparisons in subsequent patch set. + +When setting up initial register ranges we treat registers as one of +u64/s64/u32/s32 numeric types","[' and then independently perform conditional\ncomparisons based on a potentially different u64/s64/u32/s32 types. This\ntests lots of tricky cases of deriving bounds information across\ndifferent numeric domains.\n\nGiven there are lots of auto-generated cases', ' we guard them behind\nSLOW_TESTS=1 envvar requirement', ' and skip them altogether otherwise.\nWith current full set of upper/lower seed value', ' all supported\ncomparison operators and all the combinations of u64/s64/u32/s32 number\ndomains', ' we get about 7.7 million tests', ' which run in about 35 minutes\non my local qemu instance without parallelization. But we also split\nthose tests by init/cond numeric types', "" which allows to rely on\ntest_progs's parallelization of tests with `-j` option"", "" getting run time\ndown to about 5 minutes on 8 cores. It's still something that shouldn't\nbe run during normal test_progs run. But we can run it a reasonable\ntime"", ' and so perhaps a nightly CI test run (once we have it) would be\na good option for this.\n\nWe also add a small set of tricky conditions that came up during\ndevelopment and triggered various bugs or corner cases in either\nselftest\'s reimplementation of range bounds logic or in verifier\'s logic\nitself. These are fast enough to be run as part of normal test_progs\ntest run and are great for a quick sanity checking.\n\nLet\'s take a look at test output to understand what\'s going on:\n\n $ sudo ./test_progs -t reg_bounds_crafted\n #191/1 reg_bounds_crafted/(u64)[0; 0xffffffff] (u64)< 0:OK\n ...\n #191/115 reg_bounds_crafted/(u64)[0; 0x17fffffff] (s32)< 0:OK\n ...\n #191/137 reg_bounds_crafted/(u64)[0xffffffff; 0x100000000] (u64)== 0:OK\n\nEach test case is uniquely and fully described by this generated string.\nE.g.: ""(u64)[0; 0x17fffffff] (s32)< 0"". This means that we\ninitialize a register (R6) in such a way that verifier knows that it can\nhave a value in [(u64)0; (u64)0x17fffffff] range. Another\nregister (R7) is also set up as u64', "" but this time a constant (zero in\nthis case). They then are compared using 32-bit signed < operation.\nResulting TRUE/FALSE branches are evaluated (including cases where it's\nknown that one of the branches will never be taken"", "" in which case we\nvalidate that verifier also determines this as a dead code). Test\nvalidates that verifier's final register state matches expected state\nbased on selftest's own reg_state logic"", ' implemented from scratch for\ncross-checking purposes.\n\nThese test names can be conveniently used for further debugging', ' and if -vv\nverboseness is requested we can get a corresponding verifier log (with\nmark_precise logs filtered out as irrelevant and distracting). Example below is\nslightly redacted for brevity', ' omitting irrelevant register output in\nsome places', "" marked with [...].\n\n $ sudo ./test_progs -a 'reg_bounds_crafted/(u32)[0; U32_MAX] (s32)< -1' -vv\n ...\n VERIFIER LOG:\n ========================\n func#0 @0\n 0: R1=ctx(off=0"", 'imm=0) R10=fp0\n 0: (05) goto pc+2\n 3: (85) call bpf_get_current_pid_tgid#14 ; R0_w=scalar()\n 4: (bc) w6 = w0 ; R0_w=scalar() R6_w=scalar(smin=0', 'smax=umax=4294967295', 'var_off=(0x0; 0xffffffff))\n 5: (85) call bpf_get_current_pid_tgid#14 ; R0_w=scalar()\n 6: (bc) w7 = w0 ; R0_w=scalar() R7_w=scalar(smin=0', 'smax=umax=4294967295', 'var_off=(0x0; 0xffffffff))\n 7: (b4) w1 = 0 ; R1_w=0\n 8: (b4) w2 = -1 ; R2=4294967295\n 9: (ae) if w6 < w1 goto pc-9\n 9: R1=0 R6=scalar(smin=0', 'smax=umax=4294967295', 'var_off=(0x0; 0xffffffff))\n 10: (2e) if w6 > w2 goto pc-10\n 10: R2=4294967295 R6=scalar(smin=0', 'smax=umax=4294967295', 'var_off=(0x0; 0xffffffff))\n 11: (b4) w1 = -1 ; R1_w=4294967295\n 12: (b4) w2 = -1 ; R2_w=4294967295\n 13: (ae) if w7 < w1 goto pc-13 ; R1_w=4294967295 R7=4294967295\n 14: (2e) if w7 > w2 goto pc-14\n 14: R2_w=4294967295 R7=4294967295\n 15: (bc) w0 = w6 ; [...] R6=scalar(id=1', 'smin=0', 'smax=umax=4294967295', 'var_off=(0x0; 0xffffffff))\n 16: (bc) w0 = w7 ; [...] R7=4294967295\n 17: (ce) if w6 s< w7 goto pc+3 ; R6=scalar(id=1', 'smin=0', 'smax=umax=4294967295', 'smin32=-1', 'var_off=(0x0; 0xffffffff)) R7=4294967295\n 18: (bc) w0 = w6 ; [...] R6=scalar(id=1', 'smin=0', 'smax=umax=4294967295', 'smin32=-1', 'var_off=(0x0; 0xffffffff))\n 19: (bc) w0 = w7 ; [...] R7=4294967295\n 20: (95) exit\n\n from 17 to 21: [...]\n 21: (bc) w0 = w6 ; [...] R6=scalar(id=1', 'smin=umin=umin32=2147483648', 'smax=umax=umax32=4294967294', 'smax32=-2', 'var_off=(0x80000000; 0x7fffffff))\n 22: (bc) w0 = w7 ; [...] R7=4294967295\n 23: (95) exit\n\n from 13 to 1: [...]\n 1: [...]\n 1: (b7) r0 = 0 ; R0_w=0\n 2: (95) exit\n processed 24 insns (limit 1000000) max_states_per_insn 0 total_states 2 peak_states 2 mark_read 1\n =====================\n\nVerifier log above is for `(u32)[0; U32_MAX] (s32)< -1` use cases', ' where u32\nrange is used for initialization', ' followed by signed < operator. Note\nhow we use w6/w7 in this case for register initialization (it would be\nR6/R7 for 64-bit types) and then `if w6 s< w7` for comparison at\ninstruction #17. It will be `if R6 < R7` for 64-bit unsigned comparison.\nAbove example gives a good impression of the overall structure of a BPF\nprograms generated for reg_bounds tests.\n\nIn the future', ' this ""framework"" can be extended to test not just\nconditional jumps', ' but also arithmetic operations. Adding randomized\ntesting is another possibility.\n\nSome implementation notes. We basically have our own generics-like\noperations on numbers', ' where all the numbers are stored in u64', ' but how\nthey are interpreted is passed as runtime argument enum num_t. Further', '\n`struct range` represents a bounds range', ' and those are collected\ntogether into a minimal `struct reg_state`', ' which collects range bounds\nacross all four numberical domains: u64', ' s64', ' u32', ' s64.\n\nBased on these primitives and `enum op` representing possible\nconditional operation (<', ' <=', ' >', ' >=', ' ==', ' !=)', ' there is a set of generic\nhelpers to perform ""range arithmetics""', ' which is used to maintain struct\nreg_state. We simulate what verifier will do for reg bounds of R6 and R7\nregisters using these range and reg_state primitives. Simulated\ninformation is used to determine branch taken conclusion and expected\nexact register state across all four number domains.\n\nImplementation of ""range arithmetics"" is more generic than what verifier\nis currently performing: it allows range over range comparisons and\nadjustments. This is the intended end goal of this patch set overall and verifier\nlogic is enhanced in subsequent patches in this series to handle range\nvs range operations', "" at which point selftests are extended to validate\nthese conditions as well. For now it's range vs const cases only.\n\nNote that tests are split into multiple groups by their numeric types\nfor initialization of ranges and for comparison operation. This allows\nto use test_progs's -j parallelization to speed up tests"", ' as we now have\n16 groups of parallel running tests. Overall reduction of running time\nthat allows is pretty good', ' we go down from more than 30 minutes to\nslightly less than 5 minutes running time.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nAcked-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/r/20231112010609.848406-8-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add a selftest for BPF verifier to test register range bounds logic.,"selftests, BPF, verifier",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cf5fe3c71c5a34ac0108afc550407c672d0a032d,cf5fe3c71c5a34ac0108afc550407c672d0a032d,Andrii Nakryiko,andrii@kernel.org,1699751162,Alexei Starovoitov,ast@kernel.org,1700078622,e17967dade20f1734fcf5b357f76acb87152e752,3cf98cf594ea923b8b1e0385b580d3d8aae68c06,bpf: make __reg{32,"64}_deduce_bounds logic more robust + +This change doesn't seem to have any effect on selftests and production +BPF object files","[' but we preemptively try to make it more robust.\n\nFirst', ' ""learn sign from signed bounds"" comment is misleading', ' as we are\nlearning not just sign', ' but also values.\n\nSecond', ' we simplify the check for determining whether entire range is\npositive or negative similarly to other checks added earlier', ' using\nappropriate u32/u64 cast and single comparisons. As explain in comments\nin __reg64_deduce_bounds()', ' the checks are equivalent.\n\nLast but not least', ' smin/smax and s32_min/s32_max reassignment based on\nmin/max of both umin/umax and smin/smax (and 32-bit equivalents) is hard\nto explain and justify. We are updating unsigned bounds from signed\nbounds', ' why would we update signed bounds at the same time? This might\nbe correct', "" but it's far from obvious why and the code or comments don't\ntry to justify this. Given we've added a separate deduction of signed\nbounds from unsigned bounds earlier"", ' this seems at least redundant', ' if\nnot just wrong.\n\nIn short', ' we remove doubtful pieces', ' and streamline the rest to follow\nthe logic and approach of the rest of reg_bounds_sync() checks.\n\nAcked-by: Shung-Hsi Yu \nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231112010609.848406-7-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']","The commit enhances the __reg{32, 64}_deduce_bounds logic for robustness without affecting existing tests and BPF object files.","robustness, deduction, logic",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3cf98cf594ea923b8b1e0385b580d3d8aae68c06,3cf98cf594ea923b8b1e0385b580d3d8aae68c06,Andrii Nakryiko,andrii@kernel.org,1699751161,Alexei Starovoitov,ast@kernel.org,1700078622,9a7b6da6a2bd2a9f6ca22b92a768151b5ce78acb,5f99f312bd3bedb3b266b0d26376a8c500cdc97f,bpf: remove redundant s{32,64} -> u{32,"['64} deduction logic\n\nEquivalent checks were recently added in more succinct and', ' arguably', '\nsafer form in:\n - f188765f23a5 (""bpf: derive smin32/smax32 from umin32/umax32 bounds"");\n - 2e74aef782d3 (""bpf: derive smin/smax from umin/max bounds"").\n\nThe checks we are removing in this patch set do similar checks to detect\nif entire u32/u64 range has signed bit set or not set', ' but does it with\ntwo separate checks.\n\nFurther', ' we forcefully overwrite either smin or smax (and 32-bit equvalents)\nwithout applying normal min/max intersection logic. It\'s not clear why\nthat would be correct in all cases and seems to work by accident. This\nlogic is also ""gated"" by previous signed -> unsigned derivation', ' which\nreturns early.\n\nAll this is quite confusing and seems error-prone', ' while we already have\nat least equivalent checks happening earlier. So remove this duplicate\nand error-prone logic to simplify things a bit.\n\nAcked-by: Shung-Hsi Yu \nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231112010609.848406-6-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit removes redundant code by replacing s32 with u32.,"remove,redundant,replace",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +5f99f312bd3bedb3b266b0d26376a8c500cdc97f,5f99f312bd3bedb3b266b0d26376a8c500cdc97f,Andrii Nakryiko,andrii@kernel.org,1699751160,Alexei Starovoitov,ast@kernel.org,1700078622,a76c53d6907a08551bb8ab200365e61c34123a03,be41a203bb9e0159099e189e510388fe61962eb8,"bpf: add register bounds sanity checks and sanitization + +Add simple sanity checks that validate well-formed ranges (min <= max) +across u64", s64,"[' u32', ' and s32 ranges. Also for cases when the value is\nconstant (either 64-bit or 32-bit)', ' we validate that ranges and tnums\nare in agreement.\n\nThese bounds checks are performed at the end of BPF_ALU/BPF_ALU64\noperations', ' on conditional jumps', ' and for LDX instructions (where subreg\nzero/sign extension is probably the most important to check). This\ncovers most of the interesting cases.\n\nAlso', ' we validate the sanity of the return register when manually\nadjusting it for some special helpers.\n\nBy default', ' sanity violation will trigger a warning in verifier log and\nresetting register bounds to ""unbounded"" ones. But to aid development\nand debugging', ' BPF_F_TEST_SANITY_STRICT flag is added', ' which will\ntrigger hard failure of verification with -EFAULT on register bounds\nviolations. This allows selftests to catch such issues. veristat will\nalso gain a CLI option to enable this behavior.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nAcked-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/r/20231112010609.848406-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add sanity checks for register bounds to ensure well-formed ranges in u64.,"sanity, register, bounds",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +be41a203bb9e0159099e189e510388fe61962eb8,be41a203bb9e0159099e189e510388fe61962eb8,Andrii Nakryiko,andrii@kernel.org,1699751159,Alexei Starovoitov,ast@kernel.org,1700078622,f9a8178efe938167f5d297d0976fb54ff81607a3,96381879a370425a30b810906946f64c0726450e,"bpf: enhance BPF_JEQ/BPF_JNE is_branch_taken logic + +Use 32-bit subranges to prune some 64-bit BPF_JEQ/BPF_JNE conditions +that otherwise would be ""inconclusive"" (i.e."," is_branch_taken() would +return -1). This can happen","[' for example', ' when registers are initialized\nas 64-bit u64/s64', ' then compared for inequality as 32-bit subregisters', '\nand then followed by 64-bit equality/inequality check. That 32-bit\ninequality can establish some pattern for lower 32 bits of a register\n(e.g.', ' s< 0 condition determines whether the bit #31 is zero or not)', '\nwhile overall 64-bit value could be anything (according to a value range\nrepresentation).\n\nThis is not a fancy quirky special case', "" but actually a handling that's\nnecessary to prevent correctness issue with BPF verifier's range\ntracking: set_range_min_max() assumes that register ranges are\nnon-overlapping"", ' and if that condition is not guaranteed by\nis_branch_taken() we can end up with invalid ranges', ' where min > max.\n\n [0] https://lore.kernel.org/bpf/CACkBjsY2q1_fUohD7hRmKGqv1MV=eP2f6XK8kjkYNw7BaiF8iQ@mail.gmail.com/\n\nAcked-by: Shung-Hsi Yu \nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231112010609.848406-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhance the is_branch_taken logic for BPF_JEQ/BPF_JNE using 32-bit subranges to handle inconclusive conditions more effectively.,"BPF_JEQ,subranges,inconclusive",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +96381879a370425a30b810906946f64c0726450e,96381879a370425a30b810906946f64c0726450e,Andrii Nakryiko,andrii@kernel.org,1699751158,Alexei Starovoitov,ast@kernel.org,1700078621,39e967f766aef108d7709c951218a98a7bd5dbbb,67420501e8681ae18f9f0ea0a69cd2f432100e70,"bpf: generalize is_scalar_branch_taken() logic + +Generalize is_branch_taken logic for SCALAR_VALUE register to handle +cases when both registers are not constants. Previously supported + vs cases are a natural subset of more generic +vs set of cases. + +Generalized logic relies on straightforward segment intersection checks. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Acked-by: Shung-Hsi Yu +Link: https://lore.kernel.org/r/20231112010609.848406-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Generalize SCALAR_VALUE branch logic to handle non-constant registers in the eBPF verifier.,"generalize, SCALAR_VALUE, verifier",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +67420501e8681ae18f9f0ea0a69cd2f432100e70,67420501e8681ae18f9f0ea0a69cd2f432100e70,Andrii Nakryiko,andrii@kernel.org,1699751157,Alexei Starovoitov,ast@kernel.org,1700078621,379e259defda2c18d782b7cb5eba596a914ca2bb,81427a62a22148cdc85db38a6fbe487d0d2044b6,"bpf: generalize reg_set_min_max() to handle non-const register comparisons + +Generalize bounds adjustment logic of reg_set_min_max() to handle not +just register vs constant case"," but in general any register vs any +register cases. For most of the operations it's trivial extension based +on range vs range comparison logic","[' we just need to properly pick\nmin/max of a range to compare against min/max of the other range.\n\nFor BPF_JSET we keep the original capabilities', ' just make sure JSET is\nintegrated in the common framework. This is manifested in the\ninternal-only BPF_JSET + BPF_X ""opcode"" to allow for simpler and more\nuniform rev_opcode() handling. See the code for details. This allows to\nreuse the same code exactly both for TRUE and FALSE branches without\nexplicitly handling both conditions with custom code.\n\nNote also that now we don\'t need a special handling of BPF_JEQ/BPF_JNE\ncase none of the registers are constants. This is now just a normal\ngeneric case handled by reg_set_min_max().\n\nTo make tnum handling cleaner', ' tnum_with_subreg() helper is added', "" as\nthat's a common operator when dealing with 32-bit subregister bounds.\nThis keeps the overall logic much less noisy when it comes to tnums.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nAcked-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/r/20231112010609.848406-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",Generalize reg_set_min_max() to handle register comparisons beyond constant comparisons in BPF.,"generalize, reg_set_min_max, register",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1fda5bb66ad8fb24ecb3858e61a13a6548428898,1fda5bb66ad8fb24ecb3858e61a13a6548428898,Yonghong Song,yonghong.song@linux.dev,1699666768,Alexei Starovoitov,ast@kernel.org,1700063466,056e9b6892e0f9f1299c143d85ec95554033c432,e2e57d637aa5da0a2f49d83ad44e9febf95df7b4,"bpf: Do not allocate percpu memory at init stage + +Kirill Shutemov reported significant percpu memory consumption increase after +booting in 288-cpu VM ([1]) due to commit 41a5db8d8161 (""bpf: Add support for +non-fix-size percpu mem allocation""). The percpu memory consumption is +increased from 111MB to 969MB. The number is from /proc/meminfo. + +I tried to reproduce the issue with my local VM which at most supports upto +255 cpus. With 252 cpus", without the above commit,"[' the percpu memory\nconsumption immediately after boot is 57MB while with the above commit the\npercpu memory consumption is 231MB.\n\nThis is not good since so far percpu memory from bpf memory allocator is not\nwidely used yet. Let us change pre-allocation in init stage to on-demand\nallocation when verifier detects there is a need of percpu memory for bpf\nprogram. With this change', ' percpu memory consumption after boot can be reduced\nsignicantly.\n\n [1] https://lore.kernel.org/lkml/20231109154934.4saimljtqx625l3v@box.shutemov.name/\n\nFixes: 41a5db8d8161 (""bpf: Add support for non-fix-size percpu mem allocation"")\nReported-and-tested-by: Kirill A. Shutemov \nSigned-off-by: Yonghong Song \nAcked-by: Hou Tao \nLink: https://lore.kernel.org/r/20231111013928.948838-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",The commit addresses excessive percpu memory usage by avoiding allocation at the initialization stage.,"percpu, memory, optimization",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +81427a62a22148cdc85db38a6fbe487d0d2044b6,81427a62a22148cdc85db38a6fbe487d0d2044b6,Alexei Starovoitov,ast@kernel.org,1699981016,Alexei Starovoitov,ast@kernel.org,1699981183,b01a069094a5238f3a5e6dcf828870c7a3b6d4dd,727a92d62fd6a382b4c5972008e45667e707b0e4 360769233cc9c921e90ae387d167ea3cd3cbb04c,"Merge branch 'bpf-add-support-for-cgroup1-bpf-part' + +Yafang Shao says: + +==================== +bpf: Add support for cgroup1"," BPF part + +This is the BPF part of the series ""bpf","[' cgroup: Add BPF support for\ncgroup1 hierarchy"" with adjustment in the last two patches compared\nto the previous one.\n\nv3->v4:\n - use subsys_name instead of cgrp_name in get_cgroup_hierarchy_id()\n (Tejun)\n - use local bpf_link instead of modifying the skeleton in the\n selftests\nv3: https://lwn.net/Articles/949264/\n====================\n\nLink: https://lore.kernel.org/r/20231111090034.4248-1-laoar.shao@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add support for cgroup1 in BPF subsystem.,"support,cgroup1,BPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['cgroup like programs'] +360769233cc9c921e90ae387d167ea3cd3cbb04c,360769233cc9c921e90ae387d167ea3cd3cbb04c,Yafang Shao,laoar.shao@gmail.com,1699693234,Alexei Starovoitov,ast@kernel.org,1699981163,b01a069094a5238f3a5e6dcf828870c7a3b6d4dd,bf47300b186facc8ae66a0e2aa89073565f82bb3,"selftests/bpf: Add selftests for cgroup1 hierarchy + +Add selftests for cgroup1 hierarchy. +The result as follows"," + + $ tools/testing/selftests/bpf/test_progs --name=cgroup1_hierarchy + #36/1 cgroup1_hierarchy/test_cgroup1_hierarchy:OK + #36/2 cgroup1_hierarchy/test_root_cgid:OK + #36/3 cgroup1_hierarchy/test_invalid_level:OK + #36/4 cgroup1_hierarchy/test_invalid_cgid:OK + #36/5 cgroup1_hierarchy/test_invalid_hid:OK + #36/6 cgroup1_hierarchy/test_invalid_cgrp_name:OK + #36/7 cgroup1_hierarchy/test_invalid_cgrp_name2:OK + #36/8 cgroup1_hierarchy/test_sleepable_prog:OK + #36 cgroup1_hierarchy:OK + Summary: 1/8 PASSED","[' 0 SKIPPED', ' 0 FAILED\n\nBesides', ' I also did some stress test similar to the patch #2 in this\nseries', ' as follows (with CONFIG_PROVE_RCU_LIST enabled):\n\n- Continuously mounting and unmounting named cgroups in some tasks', '\n for example:\n\n cgrp_name=$1\n while true\n do\n mount -t cgroup -o none', 'name=$cgrp_name none /$cgrp_name\n umount /$cgrp_name\n done\n\n- Continuously run this selftest concurrently', '\n while true; do ./test_progs --name=cgroup1_hierarchy; done\n\nThey can ran successfully without any RCU warnings in dmesg.\n\nSigned-off-by: Yafang Shao \nLink: https://lore.kernel.org/r/20231111090034.4248-7-laoar.shao@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit adds selftests for the cgroup1 hierarchy in the BPF selftests.,"selftests,cgroup1,hierarchy",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['cgroup like programs'] +bf47300b186facc8ae66a0e2aa89073565f82bb3,bf47300b186facc8ae66a0e2aa89073565f82bb3,Yafang Shao,laoar.shao@gmail.com,1699693233,Alexei Starovoitov,ast@kernel.org,1699981016,8f0984c7aca61bf4943026890864568a0c41c065,c1dcc050aa648bb3b831030d547c3fcc1c68140c,"selftests/bpf: Add a new cgroup helper get_cgroup_hierarchy_id() + +A new cgroup helper function", get_cgroup1_hierarchy_id(),"[' has been\nintroduced to obtain the ID of a cgroup1 hierarchy based on the provided\ncgroup name. This cgroup name can be obtained from the /proc/self/cgroup\nfile.\n\nSigned-off-by: Yafang Shao \nLink: https://lore.kernel.org/r/20231111090034.4248-6-laoar.shao@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit introduces a new cgroup helper function for obtaining cgroup hierarchy ID in selftests.,"cgroup, helper function, selftests",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['cgroup like programs'] +c1dcc050aa648bb3b831030d547c3fcc1c68140c,c1dcc050aa648bb3b831030d547c3fcc1c68140c,Yafang Shao,laoar.shao@gmail.com,1699693232,Alexei Starovoitov,ast@kernel.org,1699981016,62fdc34855b8766b75200f068a76bf8f2f0826e6,f744d35ecf46f111bf9b54bfdbc89a28ee8b928a,"selftests/bpf: Add a new cgroup helper get_classid_cgroup_id() + +Introduce a new helper function to retrieve the cgroup ID from a net_cls +cgroup directory. + +Signed-off-by: Yafang Shao +Link: https://lore.kernel.org/r/20231111090034.4248-5-laoar.shao@gmail.com +Signed-off-by: Alexei Starovoitov +",,Introduce a new helper function to retrieve the cgroup ID from a net_cls cgroup directory in selftests/bpf.,"cgroup, helper, ID",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['cgroup like programs'] +f744d35ecf46f111bf9b54bfdbc89a28ee8b928a,f744d35ecf46f111bf9b54bfdbc89a28ee8b928a,Yafang Shao,laoar.shao@gmail.com,1699693231,Alexei Starovoitov,ast@kernel.org,1699981016,39232ed4ba0c9950a71741bbc426703936f0834e,4849775587844e44d215289c425bcd70f315efe7,"selftests/bpf: Add parallel support for classid + +Include the current pid in the classid cgroup path. This way"," different +testers relying on classid-based configurations will have distinct classid +cgroup directories","[' enabling them to run concurrently. Additionally', ' we\nleverage the current pid as the classid', ' ensuring unique identification.\n\nSigned-off-by: Yafang Shao \nLink: https://lore.kernel.org/r/20231111090034.4248-4-laoar.shao@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add parallel support for classid by including current pid in cgroup path for distinct configurations.,"parallel,classid,cgroup",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['cgroup like programs'] +4849775587844e44d215289c425bcd70f315efe7,4849775587844e44d215289c425bcd70f315efe7,Yafang Shao,laoar.shao@gmail.com,1699693230,Alexei Starovoitov,ast@kernel.org,1699981016,1c62c8b620c6e86fbd9c23c2086d1b6e355fa151,fe977716b40cb98cf9c91a66454adf3dc2f8c59a,"selftests/bpf: Fix issues in setup_classid_environment() + +If the net_cls subsystem is already mounted"," attempting to mount it again +in setup_classid_environment() will result in a failure with the error code +EBUSY. Despite this","[' tmpfs will have been successfully mounted at\n/sys/fs/cgroup/net_cls. Consequently', ' the /sys/fs/cgroup/net_cls directory\nwill be empty', "" causing subsequent setup operations to fail.\n\nHere's an error log excerpt illustrating the issue when net_cls has already\nbeen mounted at /sys/fs/cgroup/net_cls prior to running\nsetup_classid_environment():\n\n- Before that change\n\n $ tools/testing/selftests/bpf/test_progs --name=cgroup_v1v2\n test_cgroup_v1v2:PASS:server_fd 0 nsec\n test_cgroup_v1v2:PASS:client_fd 0 nsec\n test_cgroup_v1v2:PASS:cgroup_fd 0 nsec\n test_cgroup_v1v2:PASS:server_fd 0 nsec\n run_test:PASS:skel_open 0 nsec\n run_test:PASS:prog_attach 0 nsec\n test_cgroup_v1v2:PASS:cgroup-v2-only 0 nsec\n (cgroup_helpers.c:248: errno: No such file or directory) Opening Cgroup Procs: /sys/fs/cgroup/net_cls/cgroup.procs\n (cgroup_helpers.c:540: errno: No such file or directory) Opening cgroup classid: /sys/fs/cgroup/net_cls/cgroup-test-work-dir/net_cls.classid\n run_test:PASS:skel_open 0 nsec\n run_test:PASS:prog_attach 0 nsec\n (cgroup_helpers.c:248: errno: No such file or directory) Opening Cgroup Procs: /sys/fs/cgroup/net_cls/cgroup-test-work-dir/cgroup.procs\n run_test:FAIL:join_classid unexpected error: 1 (errno 2)\n test_cgroup_v1v2:FAIL:cgroup-v1v2 unexpected error: -1 (errno 2)\n (cgroup_helpers.c:248: errno: No such file or directory) Opening Cgroup Procs: /sys/fs/cgroup/net_cls/cgroup.procs\n #44 cgroup_v1v2:FAIL\n Summary: 0/0 PASSED"", ' 0 SKIPPED', ' 1 FAILED\n\n- After that change\n $ tools/testing/selftests/bpf/test_progs --name=cgroup_v1v2\n #44 cgroup_v1v2:OK\n Summary: 1/0 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\nSigned-off-by: Yafang Shao \nLink: https://lore.kernel.org/r/20231111090034.4248-3-laoar.shao@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fix issues in setup_classid_environment by handling EBUSY error when net_cls is already mounted in selftests.,"selftests,bpf,setup_classid_environment",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tc/netfilter like programs'] +fe977716b40cb98cf9c91a66454adf3dc2f8c59a,fe977716b40cb98cf9c91a66454adf3dc2f8c59a,Yafang Shao,laoar.shao@gmail.com,1699693229,Alexei Starovoitov,ast@kernel.org,1699981016,928fa01e194fc04f3471c9e908d7c3fcd95e479b,727a92d62fd6a382b4c5972008e45667e707b0e4,"bpf: Add a new kfunc for cgroup1 hierarchy + +A new kfunc is added to acquire cgroup1 of a task: + +- bpf_task_get_cgroup1 + Acquires the associated cgroup of a task whithin a specific cgroup1 + hierarchy. The cgroup1 hierarchy is identified by its hierarchy ID. + +This new kfunc enables the tracing of tasks within a designated +container or cgroup directory in BPF programs. + +Suggested-by: Tejun Heo +Signed-off-by: Yafang Shao +Acked-by: Tejun Heo +Link: https://lore.kernel.org/r/20231111090034.4248-2-laoar.shao@gmail.com +Signed-off-by: Alexei Starovoitov +",,A new kfunc for acquiring cgroup1 hierarchy of a task is added to BPF.,"kfunc,cgroup1,task",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['tracepoints like programs', 'kprobe/uprobe/ftrace like programs', 'cgroup like programs']" +727a92d62fd6a382b4c5972008e45667e707b0e4,727a92d62fd6a382b4c5972008e45667e707b0e4,Jordan Rome,linux@jordanrome.com,1699756210,Andrii Nakryiko,andrii@kernel.org,1699929578,bdf6000120c9329940c8ca3bca6fe8412bc340e9,100888fb6d8a185866b1520031ee7e3182b173de,"selftests/bpf: Add assert for user stacks in test_task_stack + +This is a follow up to: +commit b8e3a87a627b (""bpf: Add crosstask check to __bpf_get_stack""). + +This test ensures that the task iterator only gets a single +user stack (for the current task). + +Signed-off-by: Jordan Rome +Signed-off-by: Andrii Nakryiko +Acked-by: Stanislav Fomichev +Link: https://lore.kernel.org/bpf/20231112023010.144675-1-linux@jordanrome.com +",,Add assertion for user stack checks in BPF selftests.,"selftests, BPF, user stack",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tracepoints like programs'] +4eeee6636af819454d7c43702e77ec7857a63000,4eeee6636af819454d7c43702e77ec7857a63000,Linus Torvalds,torvalds@linux-foundation.org,1699815488,Linus Torvalds,torvalds@linux-foundation.org,1699815488,c3e3a4cb30f36e686c059d2cca646d208eabb6d4,5dd2020f335a7a60c154375a168791a2b87f35b5 1d375d65466e5c8d7a9406826d80d475a22e8c6d,"Merge tag 'loongarch-6.7' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson + +Pull LoongArch updates from Huacai Chen: + + - support PREEMPT_DYNAMIC with static keys + + - relax memory ordering for atomic operations + + - support BPF CPU v4 instructions for LoongArch + + - some build and runtime warning fixes + +* tag 'loongarch-6.7' of git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson: + selftests/bpf: Enable cpu v4 tests for LoongArch + LoongArch: BPF: Support signed mod instructions + LoongArch: BPF: Support signed div instructions + LoongArch: BPF: Support 32-bit offset jmp instructions + LoongArch: BPF: Support unconditional bswap instructions + LoongArch: BPF: Support sign-extension mov instructions + LoongArch: BPF: Support sign-extension load instructions + LoongArch: Add more instruction opcodes and emit_* helpers + LoongArch/smp: Call rcutree_report_cpu_starting() earlier + LoongArch: Relax memory ordering for atomic operations + LoongArch: Mark __percpu functions as always inline + LoongArch: Disable module from accessing external data directly + LoongArch: Support PREEMPT_DYNAMIC with static keys +",,"Merge LoongArch updates to support new BPF CPU instructions, PREEMPT_DYNAMIC with static keys, and fix build warnings.","LoongArch,BPF instructions,PREEMPT_DYNAMIC",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +100888fb6d8a185866b1520031ee7e3182b173de,100888fb6d8a185866b1520031ee7e3182b173de,Yonghong Song,yonghong.song@linux.dev,1699645004,Andrii Nakryiko,andrii@kernel.org,1699733890,c899ca1b643264736455ba764f9c92c9c445ef7a,b8e3a87a627b575896e448021e5c2f8a3bc19931,"selftests/bpf: Fix pyperf180 compilation failure with clang18 + +With latest clang18 (main branch of llvm-project repo)", when building bpf selftests,"['\n [~/work/bpf-next (master)]$ make -C tools/testing/selftests/bpf LLVM=1 -j\n\nThe following compilation error happens:\n fatal error: error in backend: Branch target out of insn range\n ...\n Stack dump:\n 0. Program arguments: clang -g -Wall -Werror -D__TARGET_ARCH_x86 -mlittle-endian\n -I/home/yhs/work/bpf-next/tools/testing/selftests/bpf/tools/include\n -I/home/yhs/work/bpf-next/tools/testing/selftests/bpf -I/home/yhs/work/bpf-next/tools/include/uapi\n -I/home/yhs/work/bpf-next/tools/testing/selftests/usr/include -idirafter\n /home/yhs/work/llvm-project/llvm/build.18/install/lib/clang/18/include -idirafter /usr/local/include\n -idirafter /usr/include -Wno-compare-distinct-pointer-types -DENABLE_ATOMICS_TESTS -O2 --target=bpf\n -c progs/pyperf180.c -mcpu=v3 -o /home/yhs/work/bpf-next/tools/testing/selftests/bpf/pyperf180.bpf.o\n 1. parser at end of file\n 2. Code generation\n ...\n\nThe compilation failure only happens to cpu=v2 and cpu=v3. cpu=v4 is okay\nsince cpu=v4 supports 32-bit branch target offset.\n\nThe above failure is due to upstream llvm patch [1] where some inlining behavior\nare changed in clang18.\n\nTo workaround the issue', ' previously all 180 loop iterations are fully unrolled.\nThe bpf macro __BPF_CPU_VERSION__ (implemented in clang18 recently) is used to avoid\nunrolling changes if cpu=v4. If __BPF_CPU_VERSION__ is not available and the\ncompiler is clang18', ' the unrollng amount is unconditionally reduced.\n\n [1] https://github.com/llvm/llvm-project/commit/1a2e77cf9e11dbf56b5720c607313a566eebb16e\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nTested-by: Alan Maguire \nLink: https://lore.kernel.org/bpf/20231110193644.3130906-1-yonghong.song@linux.dev\n', '']",Fixes a compilation failure in BPF selftests with pyperf180 using clang18.,"fix, pyperf180, clang18",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +b8e3a87a627b575896e448021e5c2f8a3bc19931,b8e3a87a627b575896e448021e5c2f8a3bc19931,Jordan Rome,jordalgo@meta.com,1699442614,Andrii Nakryiko,andrii@kernel.org,1699643170,1c1e6a05755fd36882c88249a9522848f5a3a861,92411764e3106f38ac815d2fb1ae011e7bbe2abc,"bpf: Add crosstask check to __bpf_get_stack + +Currently get_perf_callchain only supports user stack walking for +the current task. Passing the correct *crosstask* param will return +0 frames if the task passed to __bpf_get_stack isn't the current +one instead of a single incorrect frame/address. This change +passes the correct *crosstask* param but also does a preemptive +check in __bpf_get_stack if the task is current and returns +-EOPNOTSUPP if it is not. + +This issue was found using bpf_get_task_stack inside a BPF +iterator (""iter/task"")"," which iterates over all tasks. +bpf_get_task_stack works fine for fetching kernel stacks +but because get_perf_callchain relies on the caller to know +if the requested *task* is the current one (via *crosstask*) +it was failing in a confusing way. + +It might be possible to get user stacks for all tasks utilizing +something like access_process_vm but that requires the bpf +program calling bpf_get_task_stack to be sleepable and would +therefore be a breaking change. + +Fixes: fa28dcb82a38 (""bpf: Introduce helper bpf_get_task_stack()"") +Signed-off-by: Jordan Rome +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231108112334.3433136-1-jordalgo@meta.com +",[''],Add crosstask parameter check to bpf_get_task_stack for accurate user stack walking.,"crosstask, __bpf_get_stack, user stack",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +92411764e3106f38ac815d2fb1ae011e7bbe2abc,92411764e3106f38ac815d2fb1ae011e7bbe2abc,Alexei Starovoitov,ast@kernel.org,1699635733,Alexei Starovoitov,ast@kernel.org,1699635733,57ad832f318d1416d080c643b84cf4b57570503d,689b097a06bafb461ec162fc3b3ecc9765cea67b aecd408b7e50742868b3305c24325a89024e2a30,"Merge branch 'for-6.8-bpf' of https://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup into bpf-next + +Merge cgroup prerequisite patches. + +Link: https://lore.kernel.org/bpf/20231029061438.4215-1-laoar.shao@gmail.com/ + +Signed-off-by: Alexei Starovoitov +",,Merged cgroup prerequisite patches from branch 'for-6.8-bpf'.,"merge,cgroup,prerequisite",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +689b097a06bafb461ec162fc3b3ecc9765cea67b,689b097a06bafb461ec162fc3b3ecc9765cea67b,Yafang Shao,laoar.shao@gmail.com,1699240682,Alexei Starovoitov,ast@kernel.org,1699631599,b9d3b805cc81b2528bb1f533fb4e9dd6c3800f1f,155addf0814a92d08fce26a11b27e3315cdba977,"compiler-gcc: Suppress -Wmissing-prototypes warning for all supported GCC + +The kernel supports a minimum GCC version of 5.1.0 for building. However"," +the ""__diag_ignore_all"" directive only suppresses the +""-Wmissing-prototypes"" warning for GCC versions >= 8.0.0. As a result","[' when\nbuilding the kernel with older GCC versions', "" warnings may be triggered. The\nexample below illustrates the warnings reported by the kernel test robot\nusing GCC 7.5.0:\n\n compiler: gcc-7 (Ubuntu 7.5.0-6ubuntu2) 7.5.0\n All warnings (new ones prefixed by >>):\n\n kernel/bpf/helpers.c:1893:19: warning: no previous prototype for 'bpf_obj_new_impl' [-Wmissing-prototypes]\n __bpf_kfunc void *bpf_obj_new_impl(u64 local_type_id__k"", "" void *meta__ign)\n ^~~~~~~~~~~~~~~~\n kernel/bpf/helpers.c:1907:19: warning: no previous prototype for 'bpf_percpu_obj_new_impl' [-Wmissing-prototypes]\n __bpf_kfunc void *bpf_percpu_obj_new_impl(u64 local_type_id__k"", ' void *meta__ign)\n [...]\n\nTo address this', ' we should also suppress the ""-Wmissing-prototypes"" warning\nfor older GCC versions. ""#pragma GCC diagnostic push"" is supported as\nof GCC 4.6', ' and both ""-Wmissing-prototypes"" and ""-Wmissing-declarations""\nare supported for all the GCC versions that we currently support.\nTherefore', ' it is reasonable to suppress these warnings for all supported\nGCC versions.\n\nWith this adjustment', ' it\'s important to note that after implementing\n""__diag_ignore_all""', ' it will effectively suppress warnings for all the\nsupported GCC versions.\n\nIn the future', ' if you wish to suppress warnings that are only supported on\nhigher GCC versions', ' it is advisable to explicitly use ""__diag_ignore"" to\nspecify the GCC version you are targeting.\n\nReported-by: kernel test robot \nCloses: https://lore.kernel.org/oe-kbuild-all/202311031651.A7crZEur-lkp@intel.com/\nSuggested-by: Arnd Bergmann \nSigned-off-by: Yafang Shao \nCc: Kumar Kartikeya Dwivedi \nCc: Arnd Bergmann \nAcked-by: Arnd Bergmann \nLink: https://lore.kernel.org/r/20231106031802.4188-1-laoar.shao@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Suppress -Wmissing-prototypes warning for all supported GCC versions in the kernel build system.,"suppress, GCC, warnings",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +871019b22d1bcc9fab2d1feba1b9a564acbb6e99,871019b22d1bcc9fab2d1feba1b9a564acbb6e99,Stanislav Fomichev,sdf@google.com,1699478005,David S. Miller,davem@davemloft.net,1699605429,bf9b093f9a016bad95b1ec384123e6a4ab3d3555,8a4f030dbced6fc255cbe67b2d0a129947e18493,"net: set SOCK_RCU_FREE before inserting socket into hashtable + +We've started to see the following kernel traces: + + WARNING: CPU: 83 PID: 0 at net/core/filter.c:6641 sk_lookup+0x1bd/0x1d0 + + Call Trace: + + __bpf_skc_lookup+0x10d/0x120 + bpf_sk_lookup+0x48/0xd0 + bpf_sk_lookup_tcp+0x19/0x20 + bpf_prog_+0x37c/0x16a3 + cls_bpf_classify+0x205/0x2e0 + tcf_classify+0x92/0x160 + __netif_receive_skb_core+0xe52/0xf10 + __netif_receive_skb_list_core+0x96/0x2b0 + napi_complete_done+0x7b5/0xb70 + _poll+0x94/0xb0 + net_rx_action+0x163/0x1d70 + __do_softirq+0xdc/0x32e + asm_call_irq_on_stack+0x12/0x20 + + do_softirq_own_stack+0x36/0x50 + do_softirq+0x44/0x70 + +__inet_hash can race with lockless (rcu) readers on the other cpus: + + __inet_hash + __sk_nulls_add_node_rcu + <- (bpf triggers here) + sock_set_flag(SOCK_RCU_FREE) + +Let's move the SOCK_RCU_FREE part up a bit"," before we are inserting +the socket into hashtables. Note","["" that the race is really harmless;\nthe bpf callers are handling this situation (where listener socket\ndoesn't have SOCK_RCU_FREE set) correctly"", ' so the only\nannoyance is a WARN_ONCE.\n\nMore details from Eric regarding SOCK_RCU_FREE timeline:\n\nCommit 3b24d854cb35 (""tcp/dccp: do not touch listener sk_refcnt under\nsynflood"") added SOCK_RCU_FREE. At that time', ' the precise location of\nsock_set_flag(sk', ' SOCK_RCU_FREE) did not matter', ' because the thread calling\n__inet_hash() owns a reference on sk. SOCK_RCU_FREE was only tested\nat dismantle time.\n\nCommit 6acc9b432e67 (""bpf: Add helper to retrieve socket in BPF"")\nstarted checking SOCK_RCU_FREE _after_ the lookup to infer whether\nthe refcount has been taken care of.\n\nFixes: 6acc9b432e67 (""bpf: Add helper to retrieve socket in BPF"")\nReviewed-by: Eric Dumazet \nSigned-off-by: Stanislav Fomichev \nReviewed-by: Kuniyuki Iwashima \nSigned-off-by: David S. Miller \n', '']",Set SOCK_RCU_FREE before inserting socket into hashtable to prevent kernel trace warnings.,"SOCK_RCU_FREE, socket, hashtable",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['tc/netfilter like programs'] +e2e57d637aa5da0a2f49d83ad44e9febf95df7b4,e2e57d637aa5da0a2f49d83ad44e9febf95df7b4,Andrii Nakryiko,andrii@kernel.org,1699596851,Alexei Starovoitov,ast@kernel.org,1699599445,ceeeeee21f97b54a1901c97164463d1879503b48,10e14e9652bf9e8104151bfd9200433083deae3d,"selftests/bpf: add more test cases for check_cfg() + +Add a few more simple cases to validate proper privileged vs unprivileged +loop detection behavior. conditional_loop2 is the one reported by Hao +Sun that triggered this set of fixes. + +Acked-by: Eduard Zingerman +Suggested-by: Hao Sun +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231110061412.2995786-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Add more test cases for privileged vs unprivileged loop detection in BPF selftests.,"selftests,bpf,loop",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +10e14e9652bf9e8104151bfd9200433083deae3d,10e14e9652bf9e8104151bfd9200433083deae3d,Andrii Nakryiko,andrii@kernel.org,1699596850,Alexei Starovoitov,ast@kernel.org,1699599444,10b9609fd07778761b26a896197bf7fc9af8a4aa,8c74b27f4b30cd896ccf387102410a65b4a35c25,"bpf: fix control-flow graph checking in privileged mode + +When BPF program is verified in privileged mode"," BPF verifier allows +bounded loops. This means that from CFG point of view there are +definitely some back-edges. Original commit adjusted check_cfg() logic +to not detect back-edges in control flow graph if they are resulting +from conditional jumps","[' which the idea that subsequent full BPF\nverification process will determine whether such loops are bounded or\nnot', "" and either accept or reject the BPF program. At least that's my\nreading of the intent.\n\nUnfortunately"", "" the implementation of this idea doesn't work correctly in\nall possible situations. Conditional jump might not result in immediate\nback-edge"", ' but just a few unconditional instructions later we can arrive\nat back-edge. In such situations check_cfg() would reject BPF program\neven in privileged mode', ' despite it might be bounded loop. Next patch\nadds one simple program demonstrating such scenario.\n\nTo keep things simple', ' instead of trying to detect back edges in\nprivileged mode', ' just assume every back edge is valid and let subsequent\nBPF verification prove or reject bounded loops.\n\nNote a few test changes. For unknown reason', ' we have a few tests that\nare specified to detect a back-edge in a privileged mode', ' but looking at\ntheir code it seems like the right outcome is passing check_cfg() and\nletting subsequent verification to make a decision about bounded or not\nbounded looping.\n\nBounded recursion case is also interesting. The example should pass', "" as\nrecursion is limited to just a few levels and so we never reach maximum\nnumber of nested frames and never exhaust maximum stack depth. But the\nway that max stack depth logic works today it falsely detects this as\nexceeding max nested frame count. This patch series doesn't attempt to\nfix this orthogonal problem"", ' so we just adjust expected verifier failure.\n\nSuggested-by: Alexei Starovoitov \nFixes: 2589726d12a1 (""bpf: introduce bounded loops"")\nReported-by: Hao Sun \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231110061412.2995786-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes control-flow graph checking for BPF programs in privileged mode by adjusting treatment of back-edges from conditional jumps.,"control-flow, privileged, back-edges",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8c74b27f4b30cd896ccf387102410a65b4a35c25,8c74b27f4b30cd896ccf387102410a65b4a35c25,Alexei Starovoitov,ast@kernel.org,1699589480,Alexei Starovoitov,ast@kernel.org,1699589480,ef2e9a422ae611e616fd521fc59a6b3b1cb97db3,fe69a1b1b6ed9ffc2c578c63f526026a8ab74f0c 62ccdb11d3c63dc697dea1fd92b3496fe43dcc1e,"Merge branch 'bpf-control-flow-graph-and-precision-backtrack-fixes' + +Andrii Nakryiko says: + +==================== +BPF control flow graph and precision backtrack fixes + +A small fix to BPF verifier's CFG logic around handling and reporting ldimm64 +instructions. Patch #1 was previously submitted separately ([0])"," and so this +patch set supersedes that patch. + +Second patch is fixing obscure corner case in mark_chain_precise() logic. See +patch for details. Patch #3 adds a dedicated test","[' however fragile it might.\n\n [0] https://patchwork.kernel.org/project/netdevbpf/patch/20231101205626.119243-1-andrii@kernel.org/\n====================\n\nLink: https://lore.kernel.org/r/20231110002638.4168352-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit merges fixes for BPF verifier's control flow graph and precision backtracking logic.,"BPF verifier, control flow, fixes",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +62ccdb11d3c63dc697dea1fd92b3496fe43dcc1e,62ccdb11d3c63dc697dea1fd92b3496fe43dcc1e,Andrii Nakryiko,andrii@kernel.org,1699575998,Alexei Starovoitov,ast@kernel.org,1699589480,ef2e9a422ae611e616fd521fc59a6b3b1cb97db3,4bb7ea946a370707315ab774432963ce47291946,"selftests/bpf: add edge case backtracking logic test + +Add a dedicated selftests to try to set up conditions to have a state +with same first and last instruction index"," but it actually is a loop +3->4->1->2->3. This confuses mark_chain_precision() if verifier doesn't +take into account jump history. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231110002638.4168352-4-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Add a selftest to verify edge case handling in eBPF verifier regarding jump history and state consistency.,"selftest, edge case, verifier",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4bb7ea946a370707315ab774432963ce47291946,4bb7ea946a370707315ab774432963ce47291946,Andrii Nakryiko,andrii@kernel.org,1699575997,Alexei Starovoitov,ast@kernel.org,1699589480,c4aeda8d7dec289c11b5e7799567e07da7bf612d,3feb263bb516ee7e1da0acd22b15afbb9a7daa19,"bpf: fix precision backtracking instruction iteration + +Fix an edge case in __mark_chain_precision() which prematurely stops +backtracking instructions in a state if it happens that state's first +and last instruction indexes are the same. This situations doesn't +necessarily mean that there were no instructions simulated in a state"," +but rather that we starting from the instruction","[' jumped around a bit', '\nand then ended up at the same instruction before checkpointing or\nmarking precision.\n\nTo distinguish between these two possible situations', ' we need to consult\njump history. If it\'s empty or contain a single record ""bridging"" parent\nstate and first instruction of processed state', ' then we indeed\nbacktracked all instructions in this state. But if history is not empty', '\nwe are definitely not done yet.\n\nMove this logic inside get_prev_insn_idx() to contain it more nicely.\nUse -ENOENT return code to denote ""we are out of instructions""\nsituation.\n\nThis bug was exposed by verifier_loop1.c\'s bounded_recursion subtest', ' once\nthe next fix in this patch set is applied.\n\nAcked-by: Eduard Zingerman \nFixes: b5dc0163d8fd (""bpf: precise scalar_value tracking"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231110002638.4168352-3-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes an edge case in the bpf verifier's precision backtracking logic.,"precision, backtracking, edge case",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3feb263bb516ee7e1da0acd22b15afbb9a7daa19,3feb263bb516ee7e1da0acd22b15afbb9a7daa19,Andrii Nakryiko,andrii@kernel.org,1699575996,Alexei Starovoitov,ast@kernel.org,1699589480,b29c0f1447aad1aca146c40769a05a39d420d71a,fe69a1b1b6ed9ffc2c578c63f526026a8ab74f0c,"bpf: handle ldimm64 properly in check_cfg() + +ldimm64 instructions are 16-byte long"," and so have to be handled +appropriately in check_cfg()","[' just like the rest of BPF verifier does.\n\nThis has implications in three places:\n - when determining next instruction for non-jump instructions;\n - when determining next instruction for callback address ldimm64\n instructions (in visit_func_call_insn());\n - when checking for unreachable instructions', ' where second half of\n ldimm64 is expected to be unreachable;\n\nWe take this also as an opportunity to report jump into the middle of\nldimm64. And adjust few test_verifier tests accordingly.\n\nAcked-by: Eduard Zingerman \nReported-by: Hao Sun \nFixes: 475fb78fbf48 (""bpf: verifier (add branch/goto checks)"")\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231110002638.4168352-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fix handling of ldimm64 instructions in check_cfg function for proper configuration checks.,"ldimm64,check_cfg,instructions",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fe69a1b1b6ed9ffc2c578c63f526026a8ab74f0c,fe69a1b1b6ed9ffc2c578c63f526026a8ab74f0c,Anders Roxell,anders.roxell@linaro.org,1699551808,Alexei Starovoitov,ast@kernel.org,1699586292,2447ed60aede14e0b8f34f398764b6d86f5c0555,89cdf9d556016a54ff6ddd62324aa5ec790c05cc,"selftests: bpf: xskxceiver: ksft_print_msg: fix format type error + +Crossbuilding selftests/bpf for architecture arm64"," format specifies +type error show up like. + +xskxceiver.c:912:34: error: format specifies type 'int' but the argument +has type '__u64' (aka 'unsigned long long') [-Werror","['-Wformat]\n ksft_print_msg(""[%s] expected meta_count [%d]', ' got meta_count [%d]\\n""', '\n ~~\n %llu\n __func__', ' pkt->pkt_nb', "" meta->count);\n ^~~~~~~~~~~\nxskxceiver.c:929:55: error: format specifies type 'unsigned long long' but\n the argument has type 'u64' (aka 'unsigned long') [-Werror"", '-Wformat]\n ksft_print_msg(""Frag invalid addr: %llx len: %u\\n""', ' addr', ' len);\n ~~~~ ^~~~\n\nFixing the issues by casting to (unsigned long long) and changing the\nspecifiers to be %llu from %d and %u', ' since with u64s it might be %llx\nor %lx', ' depending on architecture.\n\nSigned-off-by: Anders Roxell \nLink: https://lore.kernel.org/r/20231109174328.1774571-1-anders.roxell@linaro.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes a format type error in the ksft_print_msg function of the xskxceiver selftest for arm64 architecture.,"format, ksft_print_msg, xskxceiver",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +155addf0814a92d08fce26a11b27e3315cdba977,155addf0814a92d08fce26a11b27e3315cdba977,Yonghong Song,yonghong.song@linux.dev,1699066140,Alexei Starovoitov,ast@kernel.org,1699585672,512cfc25c827d1ccb5958cca42fe67a65f782c2d,3f6d04d742d9fbd492a79e28e7cfe4e2a97c66e5,"bpf: Use named fields for certain bpf uapi structs + +Martin and Vadim reported a verifier failure with bpf_dynptr usage. +The issue is mentioned but Vadim workarounded the issue with source +change ([1]). The below describes what is the issue and why there +is a verification failure. + + int BPF_PROG(skb_crypto_setup) { + struct bpf_dynptr algo"," key; + ... + + bpf_dynptr_from_mem(...","[' ...', ' 0', ' &algo);\n ...\n }\n\nThe bpf program is using vmlinux.h', ' so we have the following definition in\nvmlinux.h:\n struct bpf_dynptr {\n long: 64;\n long: 64;\n };\nNote that in uapi header bpf.h', ' we have\n struct bpf_dynptr {\n long: 64;\n long: 64;\n} __attribute__((aligned(8)));\n\nSo we lost alignment information for struct bpf_dynptr by using vmlinux.h.\nLet us take a look at a simple program below:\n $ cat align.c\n typedef unsigned long long __u64;\n struct bpf_dynptr_no_align {\n __u64 :64;\n __u64 :64;\n };\n struct bpf_dynptr_yes_align {\n __u64 :64;\n __u64 :64;\n } __attribute__((aligned(8)));\n\n void bar(void *', ' void *);\n int foo() {\n struct bpf_dynptr_no_align a;\n struct bpf_dynptr_yes_align b;\n bar(&a', ' &b);\n return 0;\n }\n $ clang --target=bpf -O2 -S -emit-llvm align.c\n\nLook at the generated IR file align.ll:\n ...\n %a = alloca %struct.bpf_dynptr_no_align', ' align 1\n %b = alloca %struct.bpf_dynptr_yes_align', ' align 8\n ...\n\nThe compiler dictates the alignment for struct bpf_dynptr_no_align is 1 and\nthe alignment for struct bpf_dynptr_yes_align is 8. So theoretically compiler\ncould allocate variable %a with alignment 1 although in reallity the compiler\nmay choose a different alignment by considering other local variables.\n\nIn [1]', "" the verification failure happens because variable 'algo' is allocated\non the stack with alignment 4 (fp-28). But the verifer wants its alignment\nto be 8.\n\nTo fix the issue"", "" the RFC patch ([1]) tried to add '__attribute__((aligned(8)))'\nto struct bpf_dynptr plus other similar structs. Andrii suggested that\nwe could directly modify uapi struct with named fields like struct 'bpf_iter_num':\n struct bpf_iter_num {\n /* opaque iterator state; having __u64 here allows to preserve correct\n * alignment requirements in vmlinux.h"", ' generated from BTF\n */\n __u64 __opaque[1];\n } __attribute__((aligned(8)));\n\nIndeed', ' adding named fields for those affected structs in this patch can preserve\nalignment when bpf program references them in vmlinux.h. With this patch', '\nthe verification failure in [1] can also be resolved.\n\n [1] https://lore.kernel.org/bpf/1b100f73-7625-4c1f-3ae5-50ecf84d3ff0@linux.dev/\n [2] https://lore.kernel.org/bpf/20231103055218.2395034-1-yonghong.song@linux.dev/\n\nCc: Vadim Fedorenko \nCc: Martin KaFai Lau \nSuggested-by: Andrii Nakryiko \nSigned-off-by: Yonghong Song \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231104024900.1539182-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes a verifier failure by using named fields in certain bpf uapi structs.,"verifier failure, bpf_dynptr, uapi structs",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3f6d04d742d9fbd492a79e28e7cfe4e2a97c66e5,3f6d04d742d9fbd492a79e28e7cfe4e2a97c66e5,Alexei Starovoitov,ast@kernel.org,1699555545,Alexei Starovoitov,ast@kernel.org,1699585672,c234716003d73512a51a9e4e43b0a3cecf0c38ef,82ce364c6087e31ff9837380a4641a856284064c e9ed8df7187cfdce1075d0ee591544ac15d072f1,"Merge branch 'allow-bpf_refcount_acquire-of-mapval-obtained-via-direct-ld' + +Dave Marchevsky says: + +==================== +Allow bpf_refcount_acquire of mapval obtained via direct LD + +Consider this BPF program: + + struct cgv_node { + int d; + struct bpf_refcount r; + struct bpf_rb_node rb; + }; + + struct val_stash { + struct cgv_node __kptr *v; + }; + + struct { + __uint(type"," BPF_MAP_TYPE_ARRAY); + __type(key","[' int);\n __type(value', ' struct val_stash);\n __uint(max_entries', ' 10);\n } array_map SEC("".maps"");\n\n long bpf_program(void *ctx)\n {\n struct val_stash *mapval;\n struct cgv_node *p;\n int idx = 0;\n\n mapval = bpf_map_lookup_elem(&array_map', ' &idx);\n if (!mapval || !mapval->v) { /* omitted */ }\n\n p = bpf_refcount_acquire(mapval->v); /* Verification FAILs here */\n\n /* Add p to some tree */\n return 0;\n }\n\nVerification fails on the refcount_acquire:\n\n 160: (79) r1 = *(u64 *)(r8 +8) ; R1_w=untrusted_ptr_or_null_cgv_node(id=11', 'off=0', 'imm=0) R8_w=map_value(id=10', 'off=0', 'ks=8', 'vs=16', ""imm=0) refs=6\n 161: (b7) r2 = 0 ; R2_w=0 refs=6\n 162: (85) call bpf_refcount_acquire_impl#117824\n arg#0 is neither owning or non-owning ref\n\nThe above verifier dump is actually from sched_ext's scx_flatcg [0]"", ""\nwhich is the motivating usecase for this series' changes. Specifically"", '\nscx_flatcg stashes a rb_node type w/ cgroup-specific info (struct\ncgv_node) in a map when the cgroup is created', "" then later puts that\ncgroup's node in a rbtree in .enqueue . Making struct cgv_node\nrefcounted would simplify the code a bit by virtue of allowing us to\nremove the kptr_xchg's"", ' but ""later puts that cgroups node in a rbtree""\nis not possible without a refcount_acquire', ' which suffers from the above\nverification failure.\n\nIf we get rid of PTR_UNTRUSTED flag', ' and add MEM_ALLOC | NON_OWN_REF', '\nmapval->v would be a non-owning ref and verification would succeed. Due\nto the most recent set of refcount changes [1]', "" which modified\nbpf_obj_drop behavior to not reuse refcounted graph node's underlying\nmemory until after RCU grace period"", ' this is safe to do. Once mapval->v\nhas the correct flags it _is_ a non-owning reference and verification of\nthe motivating example will succeed.\n\n [0]: https://github.com/sched-ext/sched_ext/blob/52911e1040a0f94b9c426dddcc00be5364a7ae9f/tools/sched_ext/scx_flatcg.bpf.c#L275\n [1]: https://lore.kernel.org/bpf/20230821193311.3290257-1-davemarchevsky@fb.com/\n\nSummary of patches:\n * Patch 1 fixes an issue with bpf_refcount_acquire verification\n letting MAYBE_NULL ptrs through\n * Patch 2 tests Patch 1\'s fix\n * Patch 3 broadens the use of ""free only after RCU GP"" to all\n user-allocated types\n * Patch 4 is a small nonfunctional refactoring\n * Patch 5 changes verifier to mark direct LD of stashed graph node\n kptr as non-owning ref\n * Patch 6 tests Patch 5\'s verifier changes\n\nChangelog:\n\nv1 -> v2: https://lore.kernel.org/bpf/20231025214007.2920506-1-davemarchevsky@fb.com/\n\nSeries title changed to ""Allow bpf_refcount_acquire of mapval obtained via\ndirect LD"". V1\'s title was mistakenly truncated.\n\n * Patch 5 (""bpf: Mark direct ld of stashed bpf_{rb', 'list}_node as non-owning ref"")\n * Direct LD of percpu kptr should not have MEM_ALLOC flag (Yonghong)\n * Patch 6 (""selftests/bpf: Test bpf_refcount_acquire of node obtained via direct ld"")\n * Test read from stashed value as well\n====================\n\nLink: https://lore.kernel.org/r/20231107085639.3016113-1-davemarchevsky@fb.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit merges changes to allow bpf_refcount_acquire of map values obtained via direct load.,"bpf_refcount_acquire,mapval,direct LD",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +82ce364c6087e31ff9837380a4641a856284064c,82ce364c6087e31ff9837380a4641a856284064c,Shung-Hsi Yu,shung-hsi.yu@suse.com,1699452041,Alexei Starovoitov,ast@kernel.org,1699585671,4e57f84858fd1fa44c45412ad9f553c0d3dfb726,27007fae704eb12547b9b5c7b1005e11640d4f19,"bpf: replace register_is_const() with is_reg_const() + +The addition of is_reg_const() in commit 171de12646d2 (""bpf: generalize +is_branch_taken to handle all conditional jumps in one place"") has made the +register_is_const() redundant. Give the former has more feature"," plus the +fact the latter is only used in one place","[' replace register_is_const() with\nis_reg_const()', ' and remove the definition of register_is_const.\n\nThis requires moving the definition of is_reg_const() further up. And since\nthe comment of reg_const_value() reference is_reg_const()', ' move it up as\nwell.\n\nSigned-off-by: Shung-Hsi Yu \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231108140043.12282-1-shung-hsi.yu@suse.com\nSigned-off-by: Alexei Starovoitov \n', '']",Replaced redundant register_is_const() with is_reg_const() for handling conditional jumps in eBPF.,register replacement redundancy,It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e9ed8df7187cfdce1075d0ee591544ac15d072f1,e9ed8df7187cfdce1075d0ee591544ac15d072f1,Dave Marchevsky,davemarchevsky@fb.com,1699347399,Alexei Starovoitov,ast@kernel.org,1699585671,c234716003d73512a51a9e4e43b0a3cecf0c38ef,1b12171533a9bb23cf6fba7262b479028b65e1e8,"selftests/bpf: Test bpf_refcount_acquire of node obtained via direct ld + +This patch demonstrates that verifier changes earlier in this series +result in bpf_refcount_acquire(mapval->stashed_kptr) passing +verification. The added test additionally validates that stashing a kptr +in mapval and - in a separate BPF program - refcount_acquiring the kptr +without unstashing works as expected at runtime. + +Signed-off-by: Dave Marchevsky +Link: https://lore.kernel.org/r/20231107085639.3016113-7-davemarchevsky@fb.com +Signed-off-by: Alexei Starovoitov +",,Add test for verifier behavior with bpf_refcount_acquire on stashed kptr in selftests.,"bpf_refcount_acquire,selftests,verifier",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +27007fae704eb12547b9b5c7b1005e11640d4f19,27007fae704eb12547b9b5c7b1005e11640d4f19,Andrii Nakryiko,andrii@kernel.org,1699420470,Alexei Starovoitov,ast@kernel.org,1699585671,0b3c49f593dfae7c48163885366ed52bb5e03507,5d4a7aaca1ebcc7c864caec13203662a061c4f4f,"veristat: add ability to filter top N results + +Add ability to filter top B results"," both in replay/verifier mode and +comparison mode. Just adding `-n10` will emit only first 10 rows","[' or\nless', ' if there is not enough rows.\n\nThis is not just a shortcut instead of passing veristat output through\n`head`', ' though. Filtering out all the other rows influences final table\nformatting', ' as table column widths are calculated based on actual\nemitted test.\n\nTo demonstrate the difference', ' compare two ""equivalent"" forms below', ' one\nusing head and another using -n argument.\n\nTOP N FEATURE\n=============\n[vmuser@archvm bpf]$ sudo ./veristat -C ~/baseline-results-selftests.csv ~/sanity2-results-selftests.csv -e file', 'prog', 'insns', ""states -s '|insns_diff|' -n10\nFile Program Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n---------------------------------------- --------------------- --------- --------- ------------ ---------- ---------- -------------\ntest_seg6_loop.bpf.linked3.o __add_egr_x 12440 12360 -80 (-0.64%) 364 357 -7 (-1.92%)\nasync_stack_depth.bpf.linked3.o async_call_root_check 145 145 +0 (+0.00%) 3 3 +0 (+0.00%)\nasync_stack_depth.bpf.linked3.o pseudo_call_check 139 139 +0 (+0.00%) 3 3 +0 (+0.00%)\natomic_bounds.bpf.linked3.o sub 7 7 +0 (+0.00%) 0 0 +0 (+0.00%)\nbench_local_storage_create.bpf.linked3.o kmalloc 5 5 +0 (+0.00%) 0 0 +0 (+0.00%)\nbench_local_storage_create.bpf.linked3.o sched_process_fork 22 22 +0 (+0.00%) 2 2 +0 (+0.00%)\nbench_local_storage_create.bpf.linked3.o socket_post_create 23 23 +0 (+0.00%) 2 2 +0 (+0.00%)\nbind4_prog.bpf.linked3.o bind_v4_prog 358 358 +0 (+0.00%) 33 33 +0 (+0.00%)\nbind6_prog.bpf.linked3.o bind_v6_prog 429 429 +0 (+0.00%) 37 37 +0 (+0.00%)\nbind_perm.bpf.linked3.o bind_v4_prog 15 15 +0 (+0.00%) 1 1 +0 (+0.00%)\n\nPIPING TO HEAD\n==============\n[vmuser@archvm bpf]$ sudo ./veristat -C ~/baseline-results-selftests.csv ~/sanity2-results-selftests.csv -e file"", 'prog', 'insns', 'states -s \'|insns_diff|\' | head -n12\nFile Program Insns (A) Insns (B) Insns (DIFF) States (A) States (B) States (DIFF)\n----------------------------------------------------- ---------------------------------------------------- --------- --------- ------------ ---------- ---------- -------------\ntest_seg6_loop.bpf.linked3.o __add_egr_x 12440 12360 -80 (-0.64%) 364 357 -7 (-1.92%)\nasync_stack_depth.bpf.linked3.o async_call_root_check 145 145 +0 (+0.00%) 3 3 +0 (+0.00%)\nasync_stack_depth.bpf.linked3.o pseudo_call_check 139 139 +0 (+0.00%) 3 3 +0 (+0.00%)\natomic_bounds.bpf.linked3.o sub 7 7 +0 (+0.00%) 0 0 +0 (+0.00%)\nbench_local_storage_create.bpf.linked3.o kmalloc 5 5 +0 (+0.00%) 0 0 +0 (+0.00%)\nbench_local_storage_create.bpf.linked3.o sched_process_fork 22 22 +0 (+0.00%) 2 2 +0 (+0.00%)\nbench_local_storage_create.bpf.linked3.o socket_post_create 23 23 +0 (+0.00%) 2 2 +0 (+0.00%)\nbind4_prog.bpf.linked3.o bind_v4_prog 358 358 +0 (+0.00%) 33 33 +0 (+0.00%)\nbind6_prog.bpf.linked3.o bind_v6_prog 429 429 +0 (+0.00%) 37 37 +0 (+0.00%)\nbind_perm.bpf.linked3.o bind_v4_prog 15 15 +0 (+0.00%) 1 1 +0 (+0.00%)\n\nNote all the wasted whitespace in the ""PIPING TO HEAD"" variant.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231108051430.1830950-2-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Added functionality to filter and display top N results in veristat.,"veristat,filter,top",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +1b12171533a9bb23cf6fba7262b479028b65e1e8,1b12171533a9bb23cf6fba7262b479028b65e1e8,Dave Marchevsky,davemarchevsky@fb.com,1699347398,Alexei Starovoitov,ast@kernel.org,1699585671,0dda88d7b7b23c360fafb186fb98762867bde06e,790ce3cfefb1b768dccd4eee324ddef0f0ce3db4,bpf: Mark direct ld of stashed bpf_{rb,"list}_node as non-owning ref + +This patch enables the following pattern: + + /* mapval contains a __kptr pointing to refcounted local kptr */ + mapval = bpf_map_lookup_elem(&map","["" &idx);\n if (!mapval || !mapval->some_kptr) { /* omitted */ }\n\n p = bpf_refcount_acquire(&mapval->some_kptr);\n\nCurrently this doesn't work because bpf_refcount_acquire expects an\nowning or non-owning ref. The verifier defines non-owning ref as a type:\n\n PTR_TO_BTF_ID | MEM_ALLOC | NON_OWN_REF\n\nwhile mapval->some_kptr is PTR_TO_BTF_ID | PTR_UNTRUSTED. It's possible\nto do the refcount_acquire by first bpf_kptr_xchg'ing mapval->some_kptr\ninto a temp kptr"", ' refcount_acquiring that', "" and xchg'ing back into\nmapval"", "" but this is unwieldy and shouldn't be necessary.\n\nThis patch modifies btf_ld_kptr_type such that user-allocated types are\nmarked MEM_ALLOC and if those types have a bpf_{rb"", ""list}_node they're\nmarked NON_OWN_REF as well. Additionally"", ' due to changes to\nbpf_obj_drop_impl earlier in this series', ' rcu_protected_object now\nreturns true for all user-allocated types', "" resulting in\nmapval->some_kptr being marked MEM_RCU.\n\nAfter this patch's changes"", ' mapval->some_kptr is now:\n\n PTR_TO_BTF_ID | MEM_ALLOC | NON_OWN_REF | MEM_RCU\n\nwhich results in it passing the non-owning ref test', ' and the motivating\nexample passing verification.\n\nFuture work will likely get rid of special non-owning ref lifetime logic\nin the verifier', "" at which point we'll be able to delete the NON_OWN_REF\nflag entirely.\n\nSigned-off-by: Dave Marchevsky \nLink: https://lore.kernel.org/r/20231107085639.3016113-6-davemarchevsky@fb.com\nSigned-off-by: Alexei Starovoitov \n"", '']",This commit marks direct load of stashed bpf_map elements' node as non-owning references for eBPF programs.,"direct ld, non-owning ref, bpf_map",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +790ce3cfefb1b768dccd4eee324ddef0f0ce3db4,790ce3cfefb1b768dccd4eee324ddef0f0ce3db4,Dave Marchevsky,davemarchevsky@fb.com,1699347397,Alexei Starovoitov,ast@kernel.org,1699585671,a5fbb1da79ee98320e2d7622179b7fcd70ed05b0,649924b76ab151a96bdd22a97a993fb0421f134c,bpf: Move GRAPH_{ROOT,"NODE}_MASK macros into btf_field_type enum + +This refactoring patch removes the unused BPF_GRAPH_NODE_OR_ROOT +btf_field_type and moves BPF_GRAPH_{NODE","['ROOT} macros into the\nbtf_field_type enum. Further patches in the series will use\nBPF_GRAPH_NODE', "" so let's move this useful definition out of btf.c.\n\nSigned-off-by: Dave Marchevsky \nLink: https://lore.kernel.org/r/20231107085639.3016113-5-davemarchevsky@fb.com\nSigned-off-by: Alexei Starovoitov \n"", '']",The commit refactors the code by moving certain macros into the btf_field_type enum and removing unused types.,"refactoring, macros, btf_field_type",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7f7c43693c1b46652cfafb7af67ba31726d6ec4e,7f7c43693c1b46652cfafb7af67ba31726d6ec4e,Yonghong Song,yonghong.song@linux.dev,1699388111,Alexei Starovoitov,ast@kernel.org,1699585671,229d54097510914a62b75a0bd050312769d58975,b0d1c7294671af02369d7a4feaa5a9bb472372c6,"libbpf: Fix potential uninitialized tail padding with LIBBPF_OPTS_RESET + +Martin reported that there is a libbpf complaining of non-zero-value tail +padding with LIBBPF_OPTS_RESET macro if struct bpf_netkit_opts is modified +to have a 4-byte tail padding. This only happens to clang compiler. +The commend line is: ./test_progs -t tc_netkit_multi_links +Martin and I did some investigation and found this indeed the case and +the following are the investigation details. + +Clang: + clang version 18.0.0 + + +tools/lib/bpf/libbpf_common.h: + #define LIBBPF_OPTS_RESET(NAME"," ...) \ + do { \ + memset(&NAME","[' 0', ' sizeof(NAME)); \\\n NAME = (typeof(NAME)) { \\\n .sz = sizeof(NAME)', ' \\\n __VA_ARGS__ \\\n }; \\\n } while (0)\n\n #endif\n\ntools/lib/bpf/libbpf.h:\n struct bpf_netkit_opts {\n /* size of this struct', ' for forward/backward compatibility */\n size_t sz;\n __u32 flags;\n __u32 relative_fd;\n __u32 relative_id;\n __u64 expected_revision;\n size_t :0;\n };\n #define bpf_netkit_opts__last_field expected_revision\nIn the above struct bpf_netkit_opts', ' there is no tail padding.\n\nprog_tests/tc_netkit.c:\n static void serial_test_tc_netkit_multi_links_target(int mode', ' int target)\n {\n ...\n LIBBPF_OPTS(bpf_netkit_opts', ' optl);\n ...\n LIBBPF_OPTS_RESET(optl', '\n .flags = BPF_F_BEFORE', '\n .relative_fd = bpf_program__fd(skel->progs.tc1)', '\n );\n ...\n }\n\nLet us make the following source change', ' note that we have a 4-byte\ntailing padding now.\n diff --git a/tools/lib/bpf/libbpf.h b/tools/lib/bpf/libbpf.h\n index 6cd9c501624f..0dd83910ae9a 100644\n --- a/tools/lib/bpf/libbpf.h\n +++ b/tools/lib/bpf/libbpf.h\n @@ -803', '13 +803', '13 @@ bpf_program__attach_tcx(const struct bpf_program *prog', ' int ifindex', '\n struct bpf_netkit_opts {\n /* size of this struct', ' for forward/backward compatibility */\n size_t sz;\n - __u32 flags;\n __u32 relative_fd;\n __u32 relative_id;\n __u64 expected_revision;\n + __u32 flags;\n size_t :0;\n };\n -#define bpf_netkit_opts__last_field expected_revision\n +#define bpf_netkit_opts__last_field flags\n\nThe clang 18 generated asm code looks like below:\n ; LIBBPF_OPTS_RESET(optl', '\n 55e3: 48 8d 7d 98 leaq -0x68(%rbp)', ' %rdi\n 55e7: 31 f6 xorl %esi', ' %esi\n 55e9: ba 20 00 00 00 movl $0x20', ' %edx\n 55ee: e8 00 00 00 00 callq 0x55f3 \n 55f3: 48 c7 85 10 fd ff ff 20 00 00 00 movq $0x20', ' -0x2f0(%rbp)\n 55fe: 48 8b 85 68 ff ff ff movq -0x98(%rbp)', ' %rax\n 5605: 48 8b 78 18 movq 0x18(%rax)', ' %rdi\n 5609: e8 00 00 00 00 callq 0x560e \n 560e: 89 85 18 fd ff ff movl %eax', ' -0x2e8(%rbp)\n 5614: c7 85 1c fd ff ff 00 00 00 00 movl $0x0', ' -0x2e4(%rbp)\n 561e: 48 c7 85 20 fd ff ff 00 00 00 00 movq $0x0', ' -0x2e0(%rbp)\n 5629: c7 85 28 fd ff ff 08 00 00 00 movl $0x8', ' -0x2d8(%rbp)\n 5633: 48 8b 85 10 fd ff ff movq -0x2f0(%rbp)', ' %rax\n 563a: 48 89 45 98 movq %rax', ' -0x68(%rbp)\n 563e: 48 8b 85 18 fd ff ff movq -0x2e8(%rbp)', ' %rax\n 5645: 48 89 45 a0 movq %rax', ' -0x60(%rbp)\n 5649: 48 8b 85 20 fd ff ff movq -0x2e0(%rbp)', ' %rax\n 5650: 48 89 45 a8 movq %rax', ' -0x58(%rbp)\n 5654: 48 8b 85 28 fd ff ff movq -0x2d8(%rbp)', ' %rax\n 565b: 48 89 45 b0 movq %rax', ' -0x50(%rbp)\n ; link = bpf_program__attach_netkit(skel->progs.tc2', ' ifindex', ' &optl);\n\nAt -O0 level', "" the clang compiler creates an intermediate copy.\nWe have below to store 'flags' with 4-byte store and leave another 4 byte\nin the same 8-byte-aligned storage undefined"", '\n 5629: c7 85 28 fd ff ff 08 00 00 00 movl $0x8', "" -0x2d8(%rbp)\nand later we store 8-byte to the original zero'ed buffer\n 5654: 48 8b 85 28 fd ff ff movq -0x2d8(%rbp)"", ' %rax\n 565b: 48 89 45 b0 movq %rax', ' -0x50(%rbp)\n\nThis caused a problem as the 4-byte value at [%rbp-0x2dc', ' %rbp-0x2e0)\nmay be garbage.\n\ngcc (gcc 11.4) does not have this issue as it does zeroing struct first before\ndoing assignments:\n ; LIBBPF_OPTS_RESET(optl', '\n 50fd: 48 8d 85 40 fc ff ff leaq -0x3c0(%rbp)', ' %rax\n 5104: ba 20 00 00 00 movl $0x20', ' %edx\n 5109: be 00 00 00 00 movl $0x0', ' %esi\n 510e: 48 89 c7 movq %rax', ' %rdi\n 5111: e8 00 00 00 00 callq 0x5116 \n 5116: 48 8b 45 f0 movq -0x10(%rbp)', ' %rax\n 511a: 48 8b 40 18 movq 0x18(%rax)', ' %rax\n 511e: 48 89 c7 movq %rax', ' %rdi\n 5121: e8 00 00 00 00 callq 0x5126 \n 5126: 48 c7 85 40 fc ff ff 00 00 00 00 movq $0x0', ' -0x3c0(%rbp)\n 5131: 48 c7 85 48 fc ff ff 00 00 00 00 movq $0x0', ' -0x3b8(%rbp)\n 513c: 48 c7 85 50 fc ff ff 00 00 00 00 movq $0x0', ' -0x3b0(%rbp)\n 5147: 48 c7 85 58 fc ff ff 00 00 00 00 movq $0x0', ' -0x3a8(%rbp)\n 5152: 48 c7 85 40 fc ff ff 20 00 00 00 movq $0x20', ' -0x3c0(%rbp)\n 515d: 89 85 48 fc ff ff movl %eax', ' -0x3b8(%rbp)\n 5163: c7 85 58 fc ff ff 08 00 00 00 movl $0x8', ' -0x3a8(%rbp)\n ; link = bpf_program__attach_netkit(skel->progs.tc2', ' ifindex', ' &optl);\n\nIt is not clear how to resolve the compiler code generation as the compiler\ngenerates correct code w.r.t. how to handle unnamed padding in C standard.\nSo this patch changed LIBBPF_OPTS_RESET macro to avoid uninitialized tail\npadding. We already knows LIBBPF_OPTS macro works on both gcc and clang', '\neven with tail padding. So LIBBPF_OPTS_RESET is changed to be a\nLIBBPF_OPTS followed by a memcpy()', ' thus avoiding uninitialized tail padding.\n\nThe below is asm code generated with this patch and with clang compiler:\n ; LIBBPF_OPTS_RESET(optl', '\n 55e3: 48 8d bd 10 fd ff ff leaq -0x2f0(%rbp)', ' %rdi\n 55ea: 31 f6 xorl %esi', ' %esi\n 55ec: ba 20 00 00 00 movl $0x20', ' %edx\n 55f1: e8 00 00 00 00 callq 0x55f6 \n 55f6: 48 c7 85 10 fd ff ff 20 00 00 00 movq $0x20', ' -0x2f0(%rbp)\n 5601: 48 8b 85 68 ff ff ff movq -0x98(%rbp)', ' %rax\n 5608: 48 8b 78 18 movq 0x18(%rax)', ' %rdi\n 560c: e8 00 00 00 00 callq 0x5611 \n 5611: 89 85 18 fd ff ff movl %eax', ' -0x2e8(%rbp)\n 5617: c7 85 1c fd ff ff 00 00 00 00 movl $0x0', ' -0x2e4(%rbp)\n 5621: 48 c7 85 20 fd ff ff 00 00 00 00 movq $0x0', ' -0x2e0(%rbp)\n 562c: c7 85 28 fd ff ff 08 00 00 00 movl $0x8', ' -0x2d8(%rbp)\n 5636: 48 8b 85 10 fd ff ff movq -0x2f0(%rbp)', ' %rax\n 563d: 48 89 45 98 movq %rax', ' -0x68(%rbp)\n 5641: 48 8b 85 18 fd ff ff movq -0x2e8(%rbp)', ' %rax\n 5648: 48 89 45 a0 movq %rax', ' -0x60(%rbp)\n 564c: 48 8b 85 20 fd ff ff movq -0x2e0(%rbp)', ' %rax\n 5653: 48 89 45 a8 movq %rax', ' -0x58(%rbp)\n 5657: 48 8b 85 28 fd ff ff movq -0x2d8(%rbp)', ' %rax\n 565e: 48 89 45 b0 movq %rax', ' -0x50(%rbp)\n ; link = bpf_program__attach_netkit(skel->progs.tc2', ' ifindex', ' &optl);\n\nIn the above code', ' a temporary buffer is zeroed and then has proper value assigned.\nFinally', ' values in temporary buffer are copied to the original variable buffer', '\nhence tail padding is guaranteed to be 0.\n\nSigned-off-by: Yonghong Song \nSigned-off-by: Andrii Nakryiko \nTested-by: Martin KaFai Lau \nLink: https://lore.kernel.org/bpf/20231107201511.2548645-1-yonghong.song@linux.dev\nSigned-off-by: Alexei Starovoitov \n', '']",Fix uninitialized tail padding issue in libbpf when using LIBBPF_OPTS_RESET macro with clang compiler.,"libbpf, uninitialized, clang",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +649924b76ab151a96bdd22a97a993fb0421f134c,649924b76ab151a96bdd22a97a993fb0421f134c,Dave Marchevsky,davemarchevsky@fb.com,1699347396,Alexei Starovoitov,ast@kernel.org,1699585671,fbe3b9142af1969a7597d03cb57261d23534f6ef,f460e7bdb027d1da93f0c5090b239889cd46a33d,"bpf: Use bpf_mem_free_rcu when bpf_obj_dropping non-refcounted nodes + +The use of bpf_mem_free_rcu to free refcounted local kptrs was added +in commit 7e26cd12ad1c (""bpf: Use bpf_mem_free_rcu when +bpf_obj_dropping refcounted nodes""). In the cover letter for the +series containing that patch [0] I commented: + + Perhaps it makes sense to move to mem_free_rcu for _all_ + non-owning refs in the future"," not just refcounted. This might + allow custom non-owning ref lifetime + invalidation logic to be + entirely subsumed by MEM_RCU handling. IMO this needs a bit more + thought and should be tackled outside of a fix series","[' so it\'s not\n attempted here.\n\nIt\'s time to start moving in the ""non-owning refs have MEM_RCU\nlifetime"" direction. As mentioned in that comment', "" using\nbpf_mem_free_rcu for all local kptrs - not just refcounted - is\nnecessarily the first step towards that goal. This patch does so.\n\nAfter this patch the memory pointed to by all local kptrs will not be\nreused until RCU grace period elapses. The verifier's understanding of\nnon-owning ref validity and the clobbering logic it uses to enforce\nthat understanding are not changed here"", "" that'll happen gradually in\nfuture work"", ' including further patches in the series.\n\n [0]: https://lore.kernel.org/all/20230821193311.3290257-1-davemarchevsky@fb.com/\n\nSigned-off-by: Dave Marchevsky \nLink: https://lore.kernel.org/r/20231107085639.3016113-4-davemarchevsky@fb.com\nSigned-off-by: Alexei Starovoitov \n', '']",Utilize bpf_mem_free_rcu for freeing non-refcounted nodes in bpf_obj_dropping to potentially streamline reference handling.,"bpf_mem_free_rcu,non-refcounted,nodes",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f460e7bdb027d1da93f0c5090b239889cd46a33d,f460e7bdb027d1da93f0c5090b239889cd46a33d,Dave Marchevsky,davemarchevsky@fb.com,1699347395,Alexei Starovoitov,ast@kernel.org,1699585671,463f36a4f1d9048c1710da3fe469a9dda318ae32,1500a5d9f49cb66906d3ea1c9158df25cc41dd40,"selftests/bpf: Add test passing MAYBE_NULL reg to bpf_refcount_acquire + +The test added in this patch exercises the logic fixed in the previous +patch in this series. Before the previous patch's changes"," +bpf_refcount_acquire accepts MAYBE_NULL local kptrs; after the change +the verifier correctly rejects the such a call. + +Signed-off-by: Dave Marchevsky +Link: https://lore.kernel.org/r/20231107085639.3016113-3-davemarchevsky@fb.com +Signed-off-by: Alexei Starovoitov +",[''],Added a selftest for bpf_refcount_acquire handling of MAYBE_NULL reg in eBPF.,"selftest,bpf_refcount_acquire,MAYBE_NULL",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1500a5d9f49cb66906d3ea1c9158df25cc41dd40,1500a5d9f49cb66906d3ea1c9158df25cc41dd40,Dave Marchevsky,davemarchevsky@fb.com,1699347394,Alexei Starovoitov,ast@kernel.org,1699585671,e0fbb55fc5153e5187e424e4db11f2eb5aa889f4,82ce364c6087e31ff9837380a4641a856284064c,"bpf: Add KF_RCU flag to bpf_refcount_acquire_impl + +Refcounted local kptrs are kptrs to user-defined types with a +bpf_refcount field. Recent commits ([0]"," [1]) modified the lifetime of +refcounted local kptrs such that the underlying memory is not reused +until RCU grace period has elapsed. + +Separately","[' verification of bpf_refcount_acquire calls currently\nsucceeds for MAYBE_NULL non-owning reference input', ' which is a problem\nas bpf_refcount_acquire_impl has no handling for this case.\n\nThis patch takes advantage of aforementioned lifetime changes to tag\nbpf_refcount_acquire_impl kfunc KF_RCU', ' thereby preventing MAYBE_NULL\ninput to the kfunc. The KF_RCU flag applies to all kfunc params; it\'s\nfine for it to apply to the void *meta__ign param as that\'s populated by\nthe verifier and is tagged __ign regardless.\n\n [0]: commit 7e26cd12ad1c (""bpf: Use bpf_mem_free_rcu when\n bpf_obj_dropping refcounted nodes"") is the actual change to\n allocation behaivor\n [1]: commit 0816b8c6bf7f (""bpf: Consider non-owning refs to refcounted\n nodes RCU protected"") modified verifier understanding of\n refcounted local kptrs to match [0]\'s changes\n\nSigned-off-by: Dave Marchevsky \nFixes: 7c50b1cb76ac (""bpf: Add bpf_refcount_acquire kfunc"")\nLink: https://lore.kernel.org/r/20231107085639.3016113-2-davemarchevsky@fb.com\nSigned-off-by: Alexei Starovoitov \n', '']",Added KF_RCU flag to bpf_refcount_acquire_impl for refcounted local kptr memory handling.,"KF_RCU, bpf_refcount, kptrs",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b0d1c7294671af02369d7a4feaa5a9bb472372c6,b0d1c7294671af02369d7a4feaa5a9bb472372c6,Andrii Nakryiko,andrii@kernel.org,1699380278,Alexei Starovoitov,ast@kernel.org,1699585664,c43ffde215600c1540057a1cb6680d5ac23e90fd,9b75dbeb36fcd9fc7ed51d370310d0518a387769 045edee19d591e59ed53772bf6dfc9b1ed9577eb,"Merge branch 'bpf: __bpf_dynptr_data* and __str annotation' + +Song Liu says: + +==================== +This set contains the first 3 patches of set [1]. Currently"," [1] is waiting +for [3] to be merged to bpf-next tree. So send these 3 patches first to +unblock other works","[' such as [2]. This set is verified with new version of\n[1] in CI run [4].\n\nChanges since v12 of [1]:\n1. Reuse bpf_dynptr_slice() in __bpf_dynptr_data(). (Andrii)\n2. Add Acked-by from Vadim Fedorenko.\n\n[1] https://lore.kernel.org/bpf/20231104001313.3538201-1-song@kernel.org/\n[2] https://lore.kernel.org/bpf/20231031134900.1432945-1-vadfed@meta.com/\n[3] https://lore.kernel.org/bpf/20231031215625.2343848-1-davemarchevsky@fb.com/\n[4] https://github.com/kernel-patches/bpf/actions/runs/6779945063/job/18427926114\n====================\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \n', '']",Merges initial set of patches related to __bpf_dynptr_data and __str annotation to unblock further developments.,"__bpf_dynptr_data, __str annotation, patches",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9b75dbeb36fcd9fc7ed51d370310d0518a387769,9b75dbeb36fcd9fc7ed51d370310d0518a387769,Florian Lehner,dev@der-flo.net,1699174681,Alexei Starovoitov,ast@kernel.org,1699585658,d7a194a3c697a90c9b404db8c9f4d000c00021de,f2d2c7e1b7c9e8847478769d6e1f8a76b5e91952,bpf," lpm: Fix check prefixlen before walking trie + +When looking up an element in LPM trie","["" the condition 'matchlen ==\ntrie->max_prefixlen' will never return true"", ' if key->prefixlen is larger\nthan trie->max_prefixlen. Consequently all elements in the LPM trie will\nbe visited and no element is returned in the end.\n\nTo resolve this', ' check key->prefixlen first before walking the LPM trie.\n\nFixes: b95a5c4db09b (""bpf: add a longest prefix match trie map implementation"")\nSigned-off-by: Florian Lehner \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231105085801.3742-1-dev@der-flo.net\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes prefix length check before traversing LPM trie in eBPF.,"prefixlen, trie, fix",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['tc/netfilter like programs'] +045edee19d591e59ed53772bf6dfc9b1ed9577eb,045edee19d591e59ed53772bf6dfc9b1ed9577eb,Song Liu,song@kernel.org,1699333045,Alexei Starovoitov,ast@kernel.org,1699585658,c43ffde215600c1540057a1cb6680d5ac23e90fd,0b51940729150e807fc4b7767164e6bb6cf4f7dd,"bpf: Introduce KF_ARG_PTR_TO_CONST_STR + +Similar to ARG_PTR_TO_CONST_STR for BPF helpers"," KF_ARG_PTR_TO_CONST_STR +specifies kfunc args that point to const strings. Annotation ""__str"" is +used to specify kfunc arg of type KF_ARG_PTR_TO_CONST_STR. Also","[' add\ndocumentation for the ""__str"" annotation.\n\nbpf_get_file_xattr() will be the first kfunc that uses this type.\n\nSigned-off-by: Song Liu \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nAcked-by: Vadim Fedorenko \nLink: https://lore.kernel.org/bpf/20231107045725.2278852-4-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Introduce KF_ARG_PTR_TO_CONST_STR for specifying kfunc args pointing to constant strings in BPF.,"KF_ARG_PTR_TO_CONST_STR, kfunc, const strings",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f2d2c7e1b7c9e8847478769d6e1f8a76b5e91952,f2d2c7e1b7c9e8847478769d6e1f8a76b5e91952,Anders Roxell,anders.roxell@linaro.org,1699049352,Alexei Starovoitov,ast@kernel.org,1699585658,2c9f1ce28a74ed27676996dbf02342b531719c28,a46afaa03f6db8c65492302ffdafcb2e769e5667,"selftests/bpf: Disable CONFIG_DEBUG_INFO_REDUCED in config.aarch64 + +Building an arm64 kernel and seftests/bpf with defconfig + +selftests/bpf/config and selftests/bpf/config.aarch64 the fragment +CONFIG_DEBUG_INFO_REDUCED is enabled in arm64's defconfig"," it should be +disabled in file sefltests/bpf/config.aarch64 since if its not disabled +CONFIG_DEBUG_INFO_BTF wont be enabled. + +Signed-off-by: Anders Roxell +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231103220912.333930-1-anders.roxell@linaro.org +Signed-off-by: Alexei Starovoitov +",[''],Disable CONFIG_DEBUG_INFO_REDUCED in config.aarch64 to ensure CONFIG_DEBUG_INFO_BTF can be enabled for selftests/bpf.,"selftests, CONFIG_DEBUG_INFO, aarch64",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0b51940729150e807fc4b7767164e6bb6cf4f7dd,0b51940729150e807fc4b7767164e6bb6cf4f7dd,Song Liu,song@kernel.org,1699333044,Alexei Starovoitov,ast@kernel.org,1699585658,4937cbe0b7a90c82ccf94fefa34244db49e3fa1e,74523c06ae20b83c5508a98af62393ac34913362,"bpf: Factor out helper check_reg_const_str() + +ARG_PTR_TO_CONST_STR is used to specify constant string args for BPF +helpers. The logic that verifies a reg is ARG_PTR_TO_CONST_STR is +implemented in check_func_arg(). + +As we introduce kfuncs with constant string args"," it is necessary to +do the same check for kfuncs (in check_kfunc_args). Factor out the logic +for ARG_PTR_TO_CONST_STR to a new check_reg_const_str() so that it can be +reused. + +check_func_arg() ensures check_reg_const_str() is only called with reg of +type PTR_TO_MAP_VALUE. Add a redundent type check in check_reg_const_str() +to avoid misuse in the future. Other than this redundent check","[' there is\nno change in behavior.\n\nSigned-off-by: Song Liu \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nAcked-by: Vadim Fedorenko \nLink: https://lore.kernel.org/bpf/20231107045725.2278852-3-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit refactors code to introduce a reusable function for constant string argument verification in BPF helpers and kfuncs.,"helper, check, refactor",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a46afaa03f6db8c65492302ffdafcb2e769e5667,a46afaa03f6db8c65492302ffdafcb2e769e5667,Artem Savkov,asavkov@redhat.com,1698999086,Alexei Starovoitov,ast@kernel.org,1699585658,7690701120b8ae403b9801c07a048bc14aa2aafe,b0cf0dcde8cae24571b1f382e81328229e475604,"bpftool: Fix prog object type in manpage + +bpftool's man page lists ""program"" as one of possible values for OBJECT"," +while in fact bpftool accepts ""prog"" instead. + +Reported-by: Jerry Snitselaar +Signed-off-by: Artem Savkov +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/bpf/20231103081126.170034-1-asavkov@redhat.com +Signed-off-by: Alexei Starovoitov +",[''],"Corrects the bpftool man page to reflect the correct object type ""prog"" instead of ""program"".","bpftool,manpage,prog",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +74523c06ae20b83c5508a98af62393ac34913362,74523c06ae20b83c5508a98af62393ac34913362,Song Liu,song@kernel.org,1699333043,Alexei Starovoitov,ast@kernel.org,1699585658,fed41c7eb41d0ded5f654e08fc939648363ddae9,9b75dbeb36fcd9fc7ed51d370310d0518a387769,"bpf: Add __bpf_dynptr_data* for in kernel use + +Different types of bpf dynptr have different internal data storage. +Specifically"," SKB and XDP type of dynptr may have non-continuous data. +Therefore","[' it is not always safe to directly access dynptr->data.\n\nAdd __bpf_dynptr_data and __bpf_dynptr_data_rw to replace direct access to\ndynptr->data.\n\nUpdate bpf_verify_pkcs7_signature to use __bpf_dynptr_data instead of\ndynptr->data.\n\nSigned-off-by: Song Liu \nSigned-off-by: Andrii Nakryiko \nAcked-by: Vadim Fedorenko \nLink: https://lore.kernel.org/bpf/20231107045725.2278852-2-song@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Add __bpf_dynptr_data* function for internal kernel use to handle bpf dynptr with non-continuous data storage.,"bpf,dynptr,kernel",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['xdp like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b0cf0dcde8cae24571b1f382e81328229e475604,b0cf0dcde8cae24571b1f382e81328229e475604,Manu Bretelle,chantr4@gmail.com,1698787637,Alexei Starovoitov,ast@kernel.org,1699585658,26980381c594711ab0e258deec05e2c30238816d,e3499962d836af085a621f005978fee20fc87276,"selftests/bpf: Consolidate VIRTIO/9P configs in config.vm file + +Those configs are needed to be able to run VM somewhat consistently. +For instance", ATM,"[' s390x is missing the `CONFIG_VIRTIO_CONSOLE` which\nprevents s390x kernels built in CI to leverage qemu-guest-agent.\n\nBy moving them to `config', 'vm`', "" we should have selftest kernels which are\nequal in term of VM functionalities when they include this file.\n\nThe set of config unabled were picked using\n\n grep -h -E '(_9P|_VIRTIO)' config.x86_64 config | sort | uniq\n\nadded to `config.vm` and then\n grep -vE '(_9P|_VIRTIO)' config.{x86_64"", 'aarch64', 's390x}\n\nas a side-effect', ' some config may have disappeared to the aarch64 and\ns390x kernels', ' but they should not be needed. CI will tell.\n\nSigned-off-by: Manu Bretelle \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231031212717.4037892-1-chantr4@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Consolidate VIRTIO and 9P configuration settings in the config.vm file for consistent VM execution.,"configs, VM, VIRTIO",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +e3499962d836af085a621f005978fee20fc87276,e3499962d836af085a621f005978fee20fc87276,Andrii Nakryiko,andrii@kernel.org,1698943661,Alexei Starovoitov,ast@kernel.org,1699585583,989e0be5c06e56cf68317fbd3614ed9e2423d5b2,cd9c127069c040d6b022f1ff32fed4b52b9a4017 2f553b032cad4993969cab356b3b0e306fcd1cd1,"Merge branch 'selftests/bpf: Fixes for map_percpu_stats test' + +Hou Tao says: + +==================== +From: Hou Tao + +Hi"," + +BPF CI failed due to map_percpu_stats_percpu_hash from time to time [1]. +It seems that the failure reason is per-cpu bpf memory allocator may not +be able to allocate per-cpu pointer successfully and it can not refill +free llist timely","[' and bpf_map_update_elem() will return -ENOMEM.\n\nPatch #1 fixes the size of value passed to per-cpu map update API. The\nproblem was found when fixing the ENOMEM problem', ' so also post it in\nthis patchset. Patch #2 & #3 mitigates the ENOMEM problem by retrying\nthe update operation for non-preallocated per-cpu map.\n\nPlease see individual patches for more details. And comments are always\nwelcome.\n\nRegards', '\nTao\n\n[1]: https://github.com/kernel-patches/bpf/actions/runs/6713177520/job/18244865326?pr=5909\n====================\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Alexei Starovoitov \n', '']",Fixes allocation issues in map_percpu_stats test to address BPF CI failures.,"map_percpu_stats,test,allocation",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cd9c127069c040d6b022f1ff32fed4b52b9a4017,cd9c127069c040d6b022f1ff32fed4b52b9a4017,Alexei Starovoitov,ast@kernel.org,1698940745,Alexei Starovoitov,ast@kernel.org,1699585120,61c346feb4d979fc120c6802a38104f14f948551,bf4a64b9323f181df8aba32d66cb37b9fa5df959 4621202adc5bc0d1006af37fe8b9aca131387d3c,"Merge branch 'bpf-register-bounds-logic-and-testing-improvements' + +Andrii Nakryiko says: + +==================== +BPF register bounds logic and testing improvements + +This patch set adds a big set of manual and auto-generated test cases +validating BPF verifier's register bounds tracking and deduction logic. See +details in the last patch. + +We start with building a tester that validates existing vs +verifier logic for range bounds. To make all this work"," BPF verifier's logic +needed a bunch of improvements to handle some cases that previously were not +covered. This had no implications as to correctness of verifier logic","[' but it\nwas incomplete enough to cause significant disagreements with alternative\nimplementation of register bounds logic that tests in this patch set\nimplement. So we need BPF verifier logic improvements to make all the tests\npass. This is what we do in patches #3 through #9.\n\nThe end goal of this work', ' though', ' is to extend BPF verifier range state\ntracking such as to allow to derive new range bounds when comparing non-const\nregisters. There is some more investigative work required to investigate and\nfix existing potential issues with range tracking as part of ALU/ALU64\noperations', ' so x part of v5 patch set ([0]) is dropped until\nthese issues are sorted out.\n\nFor now', ' we include preparatory refactorings and clean ups', ' that set up BPF\nverifier code base to extend the logic to vs logic in\nsubsequent patch set. Patches #10-#16 perform preliminary refactorings without\nfunctionally changing anything. But they do clean up check_cond_jmp_op() logic\nand generalize a bunch of other pieces in is_branch_taken() logic.\n\n [0] https://patchwork.kernel.org/project/netdevbpf/list/?series=797178&state=*\n\nv5->v6:\n - dropped vs patches (original patches #18 through #23) to\n add more register range sanity checks and fix preexisting issues;\n - comments improvements', ' addressing other feedback on first 17 patches\n (Eduard', ' Alexei);\nv4->v5:\n - added entirety of verifier reg bounds tracking changes', ' now handling\n vs cases (Alexei);\n - added way more comments trying to explain why deductions added are\n correct', ' hopefully they are useful and clarify things a bit (Daniel', '\n Shung-Hsi);\n - added two preliminary selftests fixes necessary for RELEASE=1 build to\n work again', ' it keeps breaking.\nv3->v4:\n - improvements to reg_bounds tester (progress report', ' split 32-bit and\n 64-bit ranges', ' fix various verbosity output issues', ' etc);\nv2->v3:\n - fix a subtle little-endianness assumption inside parge_reg_state() (CI);\nv1->v2:\n - fix compilation when building selftests with llvm-16 toolchain (CI).\n====================\n\nLink: https://lore.kernel.org/r/20231102033759.2541186-1-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Improves BPF verifier's register bounds logic and adds extensive testing.,"verifier,bounds,testing",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2f553b032cad4993969cab356b3b0e306fcd1cd1,2f553b032cad4993969cab356b3b0e306fcd1cd1,Hou Tao,houtao1@huawei.com,1698809095,Alexei Starovoitov,ast@kernel.org,1699585120,989e0be5c06e56cf68317fbd3614ed9e2423d5b2,b9b79553163788d3fc42e25c2662c0a46dc9a3c5,"selftsets/bpf: Retry map update for non-preallocated per-cpu map + +BPF CI failed due to map_percpu_stats_percpu_hash from time to time [1]. +It seems that the failure reason is per-cpu bpf memory allocator may not +be able to allocate per-cpu pointer successfully and it can not refill +free llist timely"," and bpf_map_update_elem() will return -ENOMEM. + +So mitigate the problem by retrying the update operation for +non-preallocated per-cpu map. + +[1]: https://github.com/kernel-patches/bpf/actions/runs/6713177520/job/18244865326?pr=5909 + +Signed-off-by: Hou Tao +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231101032455.3808547-4-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Retry map update for non-preallocated per-cpu map to mitigate allocation failure issues.,"non-preallocated,map update,retry",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4621202adc5bc0d1006af37fe8b9aca131387d3c,4621202adc5bc0d1006af37fe8b9aca131387d3c,Andrii Nakryiko,andrii@kernel.org,1698896279,Alexei Starovoitov,ast@kernel.org,1699585120,61c346feb4d979fc120c6802a38104f14f948551,811476e9cc578cb6c776627ac069dc45a8431791,"bpf: generalize reg_set_min_max() to handle two sets of two registers + +Change reg_set_min_max() to take FALSE/TRUE sets of two registers each"," +instead of assuming that we are always comparing to a constant. For now +we still assume that right-hand side registers are constants (and make +sure that's the case by swapping src/dst regs","[' if necessary)', ' but\nsubsequent patches will remove this limitation.\n\nreg_set_min_max() is now called unconditionally for any register\ncomparison', ' so that might include pointer vs pointer. This makes it\nconsistent with is_branch_taken() generality. But we currently only\nsupport adjustments based on SCALAR vs SCALAR comparisons', ' so\nreg_set_min_max() has to guard itself againts pointers.\n\nTaking two by two registers allows to further unify and simplify\ncheck_cond_jmp_op() logic. We utilize fake register for BPF_K\nconditional jump case', ' just like with is_branch_taken() part.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231102033759.2541186-18-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Enhance reg_set_min_max to handle two register sets instead of constants in BPF.,"reg_set_min_max,registers,BPF",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b9b79553163788d3fc42e25c2662c0a46dc9a3c5,b9b79553163788d3fc42e25c2662c0a46dc9a3c5,Hou Tao,houtao1@huawei.com,1698809094,Alexei Starovoitov,ast@kernel.org,1699585120,91c95c77cc400268ee2518600f1add72c9f0357f,d79924ca579c647d5dc55f605899c98f7ea04d0f,"selftests/bpf: Export map_update_retriable() + +Export map_update_retriable() to make it usable for other map_test +cases. These cases may only need retry for specific errno"," so add +a new callback parameter to let map_update_retriable() decide whether or +not the errno is retriable. + +Signed-off-by: Hou Tao +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231101032455.3808547-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Exported map_update_retriable() for use in other test cases with a new callback for custom errno retries.,"map_update_retriable, export, errno",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +811476e9cc578cb6c776627ac069dc45a8431791,811476e9cc578cb6c776627ac069dc45a8431791,Andrii Nakryiko,andrii@kernel.org,1698896278,Alexei Starovoitov,ast@kernel.org,1699585120,ddf66079d40143a52af6daa840aa17390d8d6cd7,4d345887d2e5a1915600cb5d37b16c4088c6ee1c,"bpf: prepare reg_set_min_max for second set of registers + +Similarly to is_branch_taken()-related refactorings"," start preparing +reg_set_min_max() to handle more generic case of two non-const +registers. Start with renaming arguments to accommodate later addition +of second register as an input argument. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-17-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Refactoring reg_set_min_max function to accommodate handling two non-const registers.,"refactoring, reg_set_min_max, registers",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d79924ca579c647d5dc55f605899c98f7ea04d0f,d79924ca579c647d5dc55f605899c98f7ea04d0f,Hou Tao,houtao1@huawei.com,1698809093,Alexei Starovoitov,ast@kernel.org,1699585120,cebfdf98a2a67fd0a9dc9150db3e723e0c8dfa70,cd9c127069c040d6b022f1ff32fed4b52b9a4017,"selftests/bpf: Use value with enough-size when updating per-cpu map + +When updating per-cpu map in map_percpu_stats test"," patch_map_thread() +only passes 4-bytes-sized value to bpf_map_update_elem(). The expected +size of the value is 8 * num_possible_cpus()","[' so fix it by passing a\nvalue with enough-size for per-cpu map update.\n\nSigned-off-by: Hou Tao \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231101032455.3808547-2-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes the update of per-cpu map with correct value size in selftests for bpf.,"per-cpu map,bpf_map_update_elem,selftests",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tracepoints like programs'] +4d345887d2e5a1915600cb5d37b16c4088c6ee1c,4d345887d2e5a1915600cb5d37b16c4088c6ee1c,Andrii Nakryiko,andrii@kernel.org,1698896277,Alexei Starovoitov,ast@kernel.org,1699585120,1a5b19342db6db72b1f6b5d2054ce9ad0a6ad193,b74c2a842bba941945279027083fcee1e9aaa73f,"bpf: unify 32-bit and 64-bit is_branch_taken logic + +Combine 32-bit and 64-bit is_branch_taken logic for SCALAR_VALUE +registers. It makes it easier to see parallels between two domains +(32-bit and 64-bit)"," and makes subsequent refactoring more +straightforward. + +No functional changes. + +Acked-by: Eduard Zingerman +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-16-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Combine 32-bit and 64-bit is_branch_taken logic for SCALAR_VALUE registers.,"unify, is_branch_taken, SCALAR_VALUE",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b74c2a842bba941945279027083fcee1e9aaa73f,b74c2a842bba941945279027083fcee1e9aaa73f,Andrii Nakryiko,andrii@kernel.org,1698896276,Alexei Starovoitov,ast@kernel.org,1699585120,b74a08de9ced5f5a686a7cbf080296652d03421b,c697289efe4ef38bc5c62f119cb74433f784b826,"bpf: generalize is_branch_taken to handle all conditional jumps in one place + +Make is_branch_taken() a single entry point for branch pruning decision +making", handling both pointer vs pointer,"[' pointer vs scalar', ' and scalar\nvs scalar cases in one place. This also nicely cleans up check_cond_jmp_op().\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231102033759.2541186-15-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Generalized is_branch_taken function to handle all conditional jumps for branch pruning in BPF.,"is_branch_taken, branch, conditional",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c697289efe4ef38bc5c62f119cb74433f784b826,c697289efe4ef38bc5c62f119cb74433f784b826,Andrii Nakryiko,andrii@kernel.org,1698896275,Alexei Starovoitov,ast@kernel.org,1699585119,8d0218e3e7fb02b1647586e03d5ca0a01c133934,c31534267c180f7ed00288d239a501b554885300,"bpf: move is_branch_taken() down + +Move is_branch_taken() slightly down. In subsequent patched we'll need +both flip_opcode() and is_pkt_ptr_branch_taken() for is_branch_taken()"," +but instead of sprinkling forward declarations around","[' it makes more\nsense to move is_branch_taken() lower below is_pkt_ptr_branch_taken()', '\nand also keep it closer to very tightly related reg_set_min_max()', ' as\nthey are two critical parts of the same SCALAR range tracking logic.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231102033759.2541186-14-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Refactor to move is_branch_taken() function down for improved code organization.,"bpf,refactor,branching",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c31534267c180f7ed00288d239a501b554885300,c31534267c180f7ed00288d239a501b554885300,Andrii Nakryiko,andrii@kernel.org,1698896274,Alexei Starovoitov,ast@kernel.org,1699585119,a3ff31f785879c916863516a1f7aac825c2b9af3,c2a3ab094683ddc154879a1364fc7cb0228f96a6,"bpf: generalize is_branch_taken() to work with two registers + +While still assuming that second register is a constant"," generalize +is_branch_taken-related code to accept two registers instead of register +plus explicit constant value. This also","[' as a side effect', ' allows to\nsimplify check_cond_jmp_op() by unifying BPF_K case with BPF_X case', "" for\nwhich we use a fake register to represent BPF_K's imm constant as\na register.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nAcked-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/r/20231102033759.2541186-13-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n"", '']",The commit generalizes the is_branch_taken() function to work with two registers instead of a register plus a constant.,"generalize, is_branch_taken, registers",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c2a3ab094683ddc154879a1364fc7cb0228f96a6,c2a3ab094683ddc154879a1364fc7cb0228f96a6,Andrii Nakryiko,andrii@kernel.org,1698896273,Alexei Starovoitov,ast@kernel.org,1699585119,321bea65b64e63097448f28288a2415342884092,9e314f5d8682e1fe6ac214fb34580a238b6fd3c4,"bpf: rename is_branch_taken reg arguments to prepare for the second one + +Just taking mundane refactoring bits out into a separate patch. No +functional changes. + +Signed-off-by: Andrii Nakryiko +Acked-by: Shung-Hsi Yu +Link: https://lore.kernel.org/r/20231102033759.2541186-12-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Refactor bpf function is_branch_taken by renaming register arguments for future enhancements.,"refactor,bpf,function",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9e314f5d8682e1fe6ac214fb34580a238b6fd3c4,9e314f5d8682e1fe6ac214fb34580a238b6fd3c4,Andrii Nakryiko,andrii@kernel.org,1698896271,Alexei Starovoitov,ast@kernel.org,1699585119,eecf7eb66fe76017e0d040fb815a8dc9513e5d74,d7f00873817129e62f8c70891cb13c8eafe9feef,bpf: drop knowledge-losing __reg_combine_{32,64}_into_{64,"['32} logic\n\nWhen performing 32-bit conditional operation operating on lower 32 bits\nof a full 64-bit register', "" register full value isn't changed. We just\npotentially gain new knowledge about that register's lower 32 bits.\n\nUnfortunately"", ' __reg_combine_{32', '64}_into_{64', '32} logic that\nreg_set_min_max() performs as a last step', "" can lose information in some\ncases due to __mark_reg64_unbounded() and __reg_assign_32_into_64().\nThat's bad and completely unnecessary. Especially __reg_assign_32_into_64()\nlooks completely out of place here"", ' because we are not performing\nzero-extending subregister assignment during conditional jump.\n\nSo this patch replaced __reg_combine_* with just a normal\nreg_bounds_sync() which will do a proper job of deriving u64/s64 bounds\nfrom u32/s32', ' and vice versa (among all other combinations).\n\n__reg_combine_64_into_32() is also used in one more place', '\ncoerce_reg_to_size()', ' while handling 1- and 2-byte register loads.\nLooking into this', ' it seems like besides marking subregister as\nunbounded before performing reg_bounds_sync()', "" we were also performing\ndeduction of smin32/smax32 and umin32/umax32 bounds from respective\nsmin/smax and umin/umax bounds. It's now redundant as reg_bounds_sync()\nperforms all the same logic more generically (e.g."", ' without unnecessary\nassumption that upper 32 bits of full register should be zero).\n\nLong story short', ' we remove __reg_combine_64_into_32() completely', ' and\ncoerce_reg_to_size() now only does resetting subreg to unbounded and then\nperforming reg_bounds_sync() to recover as much information as possible\nfrom 64-bit umin/umax and smin/smax bounds', ' set explicitly in\ncoerce_reg_to_size() earlier.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nAcked-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/r/20231102033759.2541186-10-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Removed unnecessary knowledge-losing reg combine functions in eBPF verifier.,"knowledge-losing, reg combine, eBPF verifier",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d7f00873817129e62f8c70891cb13c8eafe9feef,d7f00873817129e62f8c70891cb13c8eafe9feef,Andrii Nakryiko,andrii@kernel.org,1698896270,Alexei Starovoitov,ast@kernel.org,1699585119,f3c7aaa04cdcf0cae9f89d0af97451977bffe74d,c51d5ad6543cc36334ef1fcd762d0df767a0bf7e,"bpf: try harder to deduce register bounds from different numeric domains + +There are cases (caught by subsequent reg_bounds tests in selftests/bpf) +where performing one round of __reg_deduce_bounds() doesn't propagate +all the information from", say,"[' s32 to u32 bounds and than from newly\nlearned u32 bounds back to u64 and s64. So perform __reg_deduce_bounds()\ntwice to make sure such derivations are propagated fully after\nreg_bounds_sync().\n\nOne such example is test `(s64)[0xffffffff00000001; 0] (u64)<\n0xffffffff00000000` from selftest patch from this patch set. It demonstrates an\nintricate dance of u64 -> s64 -> u64 -> u32 bounds adjustments', ' which requires\ntwo rounds of __reg_deduce_bounds(). Here are corresponding refinement log from\nselftest', ' showing evolution of knowledge.\n\nREFINING (FALSE R1) (u64)SRC=[0xffffffff00000000; U64_MAX] (u64)DST_OLD=[0; U64_MAX] (u64)DST_NEW=[0xffffffff00000000; U64_MAX]\nREFINING (FALSE R1) (u64)SRC=[0xffffffff00000000; U64_MAX] (s64)DST_OLD=[0xffffffff00000001; 0] (s64)DST_NEW=[0xffffffff00000001; -1]\nREFINING (FALSE R1) (s64)SRC=[0xffffffff00000001; -1] (u64)DST_OLD=[0xffffffff00000000; U64_MAX] (u64)DST_NEW=[0xffffffff00000001; U64_MAX]\nREFINING (FALSE R1) (u64)SRC=[0xffffffff00000001; U64_MAX] (u32)DST_OLD=[0; U32_MAX] (u32)DST_NEW=[1; U32_MAX]\n\nR1 initially has smin/smax set to [0xffffffff00000001; -1]', ' while umin/umax is\nunknown. After (u64)< comparison', "" in FALSE branch we gain knowledge that\numin/umax is [0xffffffff00000000; U64_MAX]. That causes smin/smax to learn that\nzero can't happen and upper bound is -1. Then smin/smax is adjusted from\numin/umax improving lower bound from 0xffffffff00000000 to 0xffffffff00000001.\nAnd then eventually umin32/umax32 bounds are drived from umin/umax and become\n[1; U32_MAX].\n\nSelftest in the last patch is actually implementing a multi-round fixed-point\nconvergence logic"", ' but so far all the tests are handled by two rounds of\nreg_bounds_sync() on the verifier state', ' so we keep it simple for now.\n\nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231102033759.2541186-9-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Improve register bounds deduction in eBPF by enhancing boundary information propagation between numeric domains.,"register,bounds,reg_deduce_bounds",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c51d5ad6543cc36334ef1fcd762d0df767a0bf7e,c51d5ad6543cc36334ef1fcd762d0df767a0bf7e,Andrii Nakryiko,andrii@kernel.org,1698896269,Alexei Starovoitov,ast@kernel.org,1699585119,400e30036ffb1509ed621b4a781d87bdec4239e5,6593f2e6741f03b49bffc9d55ddd4c1c47853c39,"bpf: improve deduction of 64-bit bounds from 32-bit bounds + +Add a few interesting cases in which we can tighten 64-bit bounds based +on newly learnt information about 32-bit bounds. E.g."," when full u64/s64 +registers are used in BPF program","["" and then eventually compared as\nu32/s32. The latter comparison doesn't change the value of full\nregister"", ' but it does impose new restrictions on possible lower 32 bits\nof such full registers. And we can use that to derive additional full\nregister bounds information.\n\nAcked-by: Eduard Zingerman \nSigned-off-by: Andrii Nakryiko \nAcked-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/r/20231102033759.2541186-8-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit improves deduction of 64-bit bounds from 32-bit bounds in BPF programs.,"bounds, 64-bit, 32-bit",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6593f2e6741f03b49bffc9d55ddd4c1c47853c39,6593f2e6741f03b49bffc9d55ddd4c1c47853c39,Andrii Nakryiko,andrii@kernel.org,1698896268,Alexei Starovoitov,ast@kernel.org,1699585119,07cd7d8ed54f76f13af7e6e856ab24ba4624ba36,c1efab6468fd5ef541d47d81dbb62cca27f8db3b,"bpf: add special smin32/smax32 derivation from 64-bit bounds + +Add a special case where we can derive valid s32 bounds from umin/umax +or smin/smax by stitching together negative s32 subrange and +non-negative s32 subrange. That requires upper 32 bits to form a [N"," N+1] +range in u32 domain (taking into account wrap around","[' so 0xffffffff\nto 0x00000000 is a valid [N', ' N+1] range in this sense). See code comment\nfor concrete examples.\n\nEduard Zingerman also provided an alternative explanation ([0]) for more\nmathematically inclined readers:\n\nSuppose:\n. there are numbers a', ' b', ' c\n. 2**31 <= b < 2**32\n. 0 <= c < 2**31\n. umin = 2**32 * a + b\n. umax = 2**32 * (a + 1) + c\n\nThe number of values in the range represented by [umin; umax] is:\n. N = umax - umin + 1 = 2**32 + c - b + 1\n. min(N) = 2**32 + 0 - (2**32-1) + 1 = 2', ' with b = 2**32-1', ' c = 0\n. max(N) = 2**32 + (2**31 - 1) - 2**31 + 1 = 2**32', ' with b = 2**31', ' c = 2**31-1\n\nHence [(s32)b; (s32)c] forms a valid range.\n\n [0] https://lore.kernel.org/bpf/d7af631802f0cfae20df77fe70068702d24bbd31.camel@gmail.com/\n\nAcked-by: Eduard Zingerman \nAcked-by: Shung-Hsi Yu \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231102033759.2541186-7-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",This commit introduces special handling to derive 32-bit bounds from 64-bit bounds using negative and non-negative subranges in the BPF verifier.,"smin32,smax32,64-bit",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c1efab6468fd5ef541d47d81dbb62cca27f8db3b,c1efab6468fd5ef541d47d81dbb62cca27f8db3b,Andrii Nakryiko,andrii@kernel.org,1698896267,Alexei Starovoitov,ast@kernel.org,1699585119,2c94b1de813a6efbcfc76a724d2ee9c4f313b1b1,d540517990a9d105bf0312760665964916ac044f,"bpf: derive subreg bounds from full bounds when upper 32 bits are constant + +Comments in code try to explain the idea behind why this is correct. +Please check the code and comments. + +Acked-by: Eduard Zingerman +Acked-by: Shung-Hsi Yu +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-6-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Improve subreg bounds derivation from full bounds when upper 32 bits are constant in BPF.,"subreg, bounds, constant",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d540517990a9d105bf0312760665964916ac044f,d540517990a9d105bf0312760665964916ac044f,Andrii Nakryiko,andrii@kernel.org,1698896266,Alexei Starovoitov,ast@kernel.org,1699585119,74d542816412d7d12aaf80c6ae442013ded48196,93f7378734b595fb61e89b802002fb7e3a1267d2,"bpf: derive smin32/smax32 from umin32/umax32 bounds + +All the logic that applies to u64 vs s64"," equally applies for u32 vs s32 +relationships (just taken in a smaller 32-bit numeric space). So do the +same deduction of smin32/smax32 from umin32/umax32","[' if we can.\n\nAcked-by: Eduard Zingerman \nAcked-by: Shung-Hsi Yu \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231102033759.2541186-5-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit derives smin32/smax32 bounds from umin32/umax32 for 32-bit calculations.,"smin32, smax32, bounds",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +93f7378734b595fb61e89b802002fb7e3a1267d2,93f7378734b595fb61e89b802002fb7e3a1267d2,Andrii Nakryiko,andrii@kernel.org,1698896265,Alexei Starovoitov,ast@kernel.org,1699585119,4b91f51e3eb45a4ef49478481e261ed6d9529a1d,f4c7e887324f5776eef6e6e47a90e0ac8058a7a8,"bpf: derive smin/smax from umin/max bounds + +Add smin/smax derivation from appropriate umin/umax values. Previously the +logic was surprisingly asymmetric"," trying to derive umin/umax from smin/smax +(if possible)","[' but not trying to do the same in the other direction. A simple\naddition to __reg64_deduce_bounds() fixes this.\n\nAdded also generic comment about u64/s64 ranges and their relationship.\nHopefully that helps readers to understand all the bounds deductions\na bit better.\n\nAcked-by: Eduard Zingerman \nAcked-by: Shung-Hsi Yu \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231102033759.2541186-4-andrii@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",The commit improves the logic for deriving signed minimum and maximum from unsigned bounds in eBPF verifier.,"smin, smax, bounds",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +bf4a64b9323f181df8aba32d66cb37b9fa5df959,bf4a64b9323f181df8aba32d66cb37b9fa5df959,Yuran Pereira,yuran.pereira@hotmail.com,1698470654,Alexei Starovoitov,ast@kernel.org,1699585118,493a8cb1eef21a668f7533858d443663e0431a72,fac85c291e141a67fce46bdce01f9ee33aafabfe,"selftests/bpf: Add malloc failure checks in bpf_iter + +Since some malloc calls in bpf_iter may at times fail"," +this patch adds the appropriate fail checks","[' and ensures that\nany previously allocated resource is appropriately destroyed\nbefore returning the function.\n\nSigned-off-by: Yuran Pereira \nAcked-by: Yonghong Song \nAcked-by: Kui-Feng Lee \nLink: https://lore.kernel.org/r/DB3PR10MB6835F0ECA792265FA41FC39BE8A3A@DB3PR10MB6835.EURPRD10.PROD.OUTLOOK.COM\nSigned-off-by: Alexei Starovoitov \n', '']",The commit adds malloc failure checks to bpf_iter in selftests/bpf.,"malloc,failure,bpf_iter",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f4c7e887324f5776eef6e6e47a90e0ac8058a7a8,f4c7e887324f5776eef6e6e47a90e0ac8058a7a8,Andrii Nakryiko,andrii@kernel.org,1698896264,Alexei Starovoitov,ast@kernel.org,1699585118,c1f833d8ed02da325f5344ccd38c2705a217f6a2,2b62aa59d02ed281fa4fc218df3ca91b773e1e62,"selftests/bpf: satisfy compiler by having explicit return in btf test + +Some compilers complain about get_pprint_mapv_size() not returning value +in some code paths. Fix with explicit return. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-3-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Added an explicit return statement in btf test to satisfy compiler requirements.,"compiler, return, btf",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fac85c291e141a67fce46bdce01f9ee33aafabfe,fac85c291e141a67fce46bdce01f9ee33aafabfe,Yuran Pereira,yuran.pereira@hotmail.com,1698470653,Alexei Starovoitov,ast@kernel.org,1699585118,d0878b9c891a817a0eaf9b0046239f37d338574f,89cdf9d556016a54ff6ddd62324aa5ec790c05cc,"selftests/bpf: Convert CHECK macros to ASSERT_* macros in bpf_iter + +As it was pointed out by Yonghong Song [1]"," in the bpf selftests the use +of the ASSERT_* series of macros is preferred over the CHECK macro. +This patch replaces all CHECK calls in bpf_iter with the appropriate +ASSERT_* macros. + +[1] https://lore.kernel.org/lkml/0a142924-633c-44e6-9a92-2dc019656bf2@linux.dev + +Suggested-by: Yonghong Song +Signed-off-by: Yuran Pereira +Acked-by: Yonghong Song +Acked-by: Kui-Feng Lee +Link: https://lore.kernel.org/r/DB3PR10MB6835E9C8DFCA226DD6FEF914E8A3A@DB3PR10MB6835.EURPRD10.PROD.OUTLOOK.COM +Signed-off-by: Alexei Starovoitov +",[''],Convert CHECK macros to ASSERT_* macros in bpf_iter selftests.,"selftests,bpf_iter,macros",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2b62aa59d02ed281fa4fc218df3ca91b773e1e62,2b62aa59d02ed281fa4fc218df3ca91b773e1e62,Andrii Nakryiko,andrii@kernel.org,1698896263,Alexei Starovoitov,ast@kernel.org,1699585118,686aacd80499a6a90b0418246cf7baab1be1b59f,bf4a64b9323f181df8aba32d66cb37b9fa5df959,"selftests/bpf: fix RELEASE=1 build for tc_opts + +Compiler complains about malloc(). We also don't need to dynamically +allocate anything"," so make the life easier by using statically sized +buffer. + +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231102033759.2541186-2-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",[''],Fix static buffer allocation issue for tc_opts in bpf selftests to address malloc() compiler complaints.,"selftests,bpf,static buffer",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +89cdf9d556016a54ff6ddd62324aa5ec790c05cc,89cdf9d556016a54ff6ddd62324aa5ec790c05cc,Linus Torvalds,torvalds@linux-foundation.org,1699578575,Linus Torvalds,torvalds@linux-foundation.org,1699578575,5b5e5102c0d5f2977d4855b7761ed9efcecec2d3,3b220413438184b352b297e7cf593fa56999b5b3 83b9dda8afa4e968d9cce253f390b01c0612a2a5,"Merge tag 'net-6.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + ""Including fixes from netfilter and bpf. + + Current release - regressions: + + - sched: fix SKB_NOT_DROPPED_YET splat under debug config + + Current release - new code bugs: + + - tcp: + - fix usec timestamps with TCP fastopen + - fix possible out-of-bounds reads in tcp_hash_fail() + - fix SYN option room calculation for TCP-AO + + - tcp_sigpool: fix some off by one bugs + + - bpf: fix compilation error without CGROUPS + + - ptp: + - ptp_read() should not release queue + - fix tsevqs corruption + + Previous releases - regressions: + + - llc: verify mac len before reading mac header + + Previous releases - always broken: + + - bpf: + - fix check_stack_write_fixed_off() to correctly spill imm + - fix precision tracking for BPF_ALU | BPF_TO_BE | BPF_END + - check map->usercnt after timer->timer is assigned + + - dsa: lan9303: consequently nested-lock physical MDIO + + - dccp/tcp: call security_inet_conn_request() after setting IP addr + + - tg3: fix the TX ring stall due to incorrect full ring handling + + - phylink: initialize carrier state at creation + + - ice: fix direction of VF rules in switchdev mode + + Misc: + + - fill in a bunch of missing MODULE_DESCRIPTION()s"," more to come"" + +* tag 'net-6.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (84 commits) + net: ti: icss-iep: fix setting counter value + ptp: fix corrupted list in ptp_open + ptp: ptp_read should not release queue + net_sched: sch_fq: better validate TCA_FQ_WEIGHTS and TCA_FQ_PRIOMAP + net: kcm: fill in MODULE_DESCRIPTION() + net/sched: act_ct: Always fill offloading tuple iifidx + netfilter: nat: fix ipv6 nat redirect with mapped and scoped addresses + netfilter: xt_recent: fix (increase) ipv6 literal buffer length + ipvs: add missing module descriptions + netfilter: nf_tables: remove catchall element in GC sync path + netfilter: add missing module descriptions + drivers/net/ppp: use standard array-copy-function + net: enetc: shorten enetc_setup_xdp_prog() error message to fit NETLINK_MAX_FMTMSG_LEN + virtio/vsock: Fix uninit-value in virtio_transport_recv_pkt() + r8169: respect userspace disabling IFF_MULTICAST + selftests/bpf: get trusted cgrp from bpf_iter__cgroup directly + bpf: Let verifier consider {task","['cgroup} is trusted in bpf_iter_reg\n net: phylink: initialize carrier state at creation\n test/vsock: add dobule bind connect test\n test/vsock: refactor vsock_accept\n ...\n', '']","Merge networking fixes addressing regressions and bugs for netfilter, bpf, and tcp subsystems.","networking, fixes, bpf",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0008454e8fd30ed0017a9a35b8dd708f168931b8,0008454e8fd30ed0017a9a35b8dd708f168931b8,Yafang Shao,laoar.shao@gmail.com,1698560071,Tejun Heo,tj@kernel.org,1699572347,e1b0837749fe5823497f5206df8ebac983d1fe0d,9067d90006df089b9a1da0d74f0cad232a5d726a,"cgroup: Add annotation for holding namespace_sem in current_cgns_cgroup_from_root() + +When I initially examined the function current_cgns_cgroup_from_root()"," I +was perplexed by its lack of holding cgroup_mutex. However","[' after Michal\nexplained the reason[0] to me', ' I realized that it already holds the\nnamespace_sem. I believe this intricacy could also confuse others', ' so it\nwould be advisable to include an annotation for clarification.\n\nAfter we replace the cgroup_mutex with RCU read lock', "" if current doesn't\nhold the namespace_sem"", "" the root cgroup will be NULL. So let's add a\nWARN_ON_ONCE() for it.\n\n[0]. https://lore.kernel.org/bpf/afdnpo3jz2ic2ampud7swd6so5carkilts2mkygcaw67vbw6yh@5b5mncf7qyet\n\nSigned-off-by: Yafang Shao \nCc: Michal Koutny \nSigned-off-by: Tejun Heo \n"", '']",Added annotation for holding namespace_sem in the cgroup function current_cgns_cgroup_from_root().,"annotation, cgroup, namespace_sem",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['cgroup like programs'] +6512b6aa237db36d881a81cc312db39668e61853,6512b6aa237db36d881a81cc312db39668e61853,Ian Rogers,irogers@google.com,1698947814,Arnaldo Carvalho de Melo,acme@redhat.com,1699548573,c0776e9fde47d0c7f03b0f4b5c07d877e1ba80e3,6aad765d10c5cd8a62b258c359bae643ab2d45da,"perf bpf: Don't synthesize BPF events when disabled + +If BPF sideband events are disabled on the command line"," don't +synthesize BPF events too. + +Signed-off-by: Ian Rogers +Acked-by: Song Liu +Cc: Adrian Hunter +Cc: Alexander Shishkin +Cc: Andi Kleen +Cc: Athira Jajeev +Cc: Changbin Du +Cc: Colin Ian King +Cc: Dmitrii Dolgov <9erthalion6@gmail.com> +Cc: German Gomez +Cc: Huacai Chen +Cc: Ingo Molnar +Cc: James Clark +Cc: Jiri Olsa +Cc: K Prateek Nayak +Cc: Kajol Jain +Cc: Kan Liang +Cc: Leo Yan +Cc: Li Dong +Cc: Liam Howlett +Cc: Mark Rutland +Cc: Masami Hiramatsu +Cc: Miguel Ojeda +Cc: Ming Wang +Cc: Namhyung Kim +Cc: Nick Terrell +Cc: Paolo Bonzini +Cc: Peter Zijlstra +Cc: Ravi Bangoria +Cc: Sandipan Das +Cc: Sean Christopherson +Cc: Steinar H. Gunderson +Cc: Vincent Whitchurch +Cc: Wenyu Liu +Cc: Yang Jihong +Link: https://lore.kernel.org/r/20231102175735.2272696-13-irogers@google.com +Signed-off-by: Arnaldo Carvalho de Melo +",[''],Disable synthesis of BPF events in perf tool when sideband events are disabled via command line.,"BPF,perf,events",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +942b8b38de3fd38de1476b2abca562e729caa03d,942b8b38de3fd38de1476b2abca562e729caa03d,Jakub Kicinski,kuba@kernel.org,1699494973,Jakub Kicinski,kuba@kernel.org,1699494974,24c3eb7380b578562f307a09ad495391566e53bb,9bc64bd0cd765f696fcd40fc98909b1f7c73b2ba 8e1b802503bb630eafc3e97b2daf755368ec96e1,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf + +Daniel Borkmann says: + +==================== +pull-request: bpf 2023-11-08 + +We've added 16 non-merge commits during the last 6 day(s) which contain +a total of 30 files changed", 341 insertions(+),"[' 130 deletions(-).\n\nThe main changes are:\n\n1) Fix a BPF verifier issue in precision tracking for BPF_ALU | BPF_TO_BE |\n BPF_END where the source register was incorrectly marked as precise', '\n from Shung-Hsi Yu.\n\n2) Fix a concurrency issue in bpf_timer where the former could still have\n been alive after an application releases or unpins the map', ' from Hou Tao.\n\n3) Fix a BPF verifier issue where immediates are incorrectly cast to u32\n before being spilled and therefore losing sign information', ' from Hao Sun.\n\n4) Fix a misplaced BPF_TRACE_ITER in check_css_task_iter_allowlist which\n incorrectly compared bpf_prog_type with bpf_attach_type', ' from Chuyi Zhou.\n\n5) Add __bpf_hook_{start', 'end} as well as __bpf_kfunc_{start', 'end}_defs macros', '\n migrate all BPF-related __diag callsites over to it', ' and add a new\n __diag_ignore_all for -Wmissing-declarations to the macros to address\n recent build warnings', ' from Dave Marchevsky.\n\n6) Fix broken BPF selftest build of xdp_hw_metadata test on architectures\n where char is not signed', ' from Björn Töpel.\n\n7) Fix test_maps selftest to properly use LIBBPF_OPTS() macro to initialize\n the bpf_map_create_opts', ' from Andrii Nakryiko.\n\n8) Fix bpffs selftest to avoid unmounting /sys/kernel/debug as it may have\n been mounted and used by other applications already', ' from Manu Bretelle.\n\n9) Fix a build issue without CONFIG_CGROUPS wrt css_task open-coded\n iterators', "" from Matthieu Baerts.\n\n* tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf:\n selftests/bpf: get trusted cgrp from bpf_iter__cgroup directly\n bpf: Let verifier consider {task"", ""cgroup} is trusted in bpf_iter_reg\n selftests/bpf: Fix broken build where char is unsigned\n selftests/bpf: precision tracking test for BPF_NEG and BPF_END\n bpf: Fix precision tracking for BPF_ALU | BPF_TO_BE | BPF_END\n selftests/bpf: Add test for using css_task iter in sleepable progs\n selftests/bpf: Add tests for css_task iter combining with cgroup iter\n bpf: Relax allowlist for css_task iter\n selftests/bpf: fix test_maps' use of bpf_map_create_opts\n bpf: Check map->usercnt after timer->timer is assigned\n bpf: Add __bpf_hook_{start"", 'end} macros\n bpf: Add __bpf_kfunc_{start', 'end}_defs macros\n selftests/bpf: fix test_bpffs\n selftests/bpf: Add test for immediate spilled to stack\n bpf: Fix check_stack_write_fixed_off() to correctly spill imm\n bpf: fix compilation error without CGROUPS\n====================\n\nLink: https://lore.kernel.org/r/20231108132448.1970-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",The commit merges the 'for-netdev' branch containing non-merge commits affecting 30 files into the main branch.,"merge, for-netdev, files",It's other type of commit.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1d375d65466e5c8d7a9406826d80d475a22e8c6d,1d375d65466e5c8d7a9406826d80d475a22e8c6d,Hengqi Chen,hengqi.chen@gmail.com,1699423941,Huacai Chen,chenhuacai@loongson.cn,1699423941,bbf1828064f0a2e4e88fca85f0dbedf1af5bb487,7b6b13d32965ad7f1eb889d1a7058868a88eb29f,"selftests/bpf: Enable cpu v4 tests for LoongArch + +Enable the cpu v4 tests for LoongArch. Currently"," we don't have BPF +trampoline in LoongArch JIT","[' so the fentry test `test_ptr_struct_arg`\nstill failed', ' will followup.\n\nTest result attached below:\n\n # ./test_progs -t verifier_sdiv', 'verifier_movsx', 'verifier_ldsx', 'verifier_gotol', 'verifier_bswap\n #316/1 verifier_bswap/BSWAP', ' 16:OK\n #316/2 verifier_bswap/BSWAP', ' 16 @unpriv:OK\n #316/3 verifier_bswap/BSWAP', ' 32:OK\n #316/4 verifier_bswap/BSWAP', ' 32 @unpriv:OK\n #316/5 verifier_bswap/BSWAP', ' 64:OK\n #316/6 verifier_bswap/BSWAP', ' 64 @unpriv:OK\n #316 verifier_bswap:OK\n #330/1 verifier_gotol/gotol', ' small_imm:OK\n #330/2 verifier_gotol/gotol', ' small_imm @unpriv:OK\n #330 verifier_gotol:OK\n #338/1 verifier_ldsx/LDSX', ' S8:OK\n #338/2 verifier_ldsx/LDSX', ' S8 @unpriv:OK\n #338/3 verifier_ldsx/LDSX', ' S16:OK\n #338/4 verifier_ldsx/LDSX', ' S16 @unpriv:OK\n #338/5 verifier_ldsx/LDSX', ' S32:OK\n #338/6 verifier_ldsx/LDSX', ' S32 @unpriv:OK\n #338/7 verifier_ldsx/LDSX', ' S8 range checking', ' privileged:OK\n #338/8 verifier_ldsx/LDSX', ' S16 range checking:OK\n #338/9 verifier_ldsx/LDSX', ' S16 range checking @unpriv:OK\n #338/10 verifier_ldsx/LDSX', ' S32 range checking:OK\n #338/11 verifier_ldsx/LDSX', ' S32 range checking @unpriv:OK\n #338 verifier_ldsx:OK\n #349/1 verifier_movsx/MOV32SX', ' S8:OK\n #349/2 verifier_movsx/MOV32SX', ' S8 @unpriv:OK\n #349/3 verifier_movsx/MOV32SX', ' S16:OK\n #349/4 verifier_movsx/MOV32SX', ' S16 @unpriv:OK\n #349/5 verifier_movsx/MOV64SX', ' S8:OK\n #349/6 verifier_movsx/MOV64SX', ' S8 @unpriv:OK\n #349/7 verifier_movsx/MOV64SX', ' S16:OK\n #349/8 verifier_movsx/MOV64SX', ' S16 @unpriv:OK\n #349/9 verifier_movsx/MOV64SX', ' S32:OK\n #349/10 verifier_movsx/MOV64SX', ' S32 @unpriv:OK\n #349/11 verifier_movsx/MOV32SX', ' S8', ' range_check:OK\n #349/12 verifier_movsx/MOV32SX', ' S8', ' range_check @unpriv:OK\n #349/13 verifier_movsx/MOV32SX', ' S16', ' range_check:OK\n #349/14 verifier_movsx/MOV32SX', ' S16', ' range_check @unpriv:OK\n #349/15 verifier_movsx/MOV32SX', ' S16', ' range_check 2:OK\n #349/16 verifier_movsx/MOV32SX', ' S16', ' range_check 2 @unpriv:OK\n #349/17 verifier_movsx/MOV64SX', ' S8', ' range_check:OK\n #349/18 verifier_movsx/MOV64SX', ' S8', ' range_check @unpriv:OK\n #349/19 verifier_movsx/MOV64SX', ' S16', ' range_check:OK\n #349/20 verifier_movsx/MOV64SX', ' S16', ' range_check @unpriv:OK\n #349/21 verifier_movsx/MOV64SX', ' S32', ' range_check:OK\n #349/22 verifier_movsx/MOV64SX', ' S32', ' range_check @unpriv:OK\n #349/23 verifier_movsx/MOV64SX', ' S16', ' R10 Sign Extension:OK\n #349/24 verifier_movsx/MOV64SX', ' S16', ' R10 Sign Extension @unpriv:OK\n #349 verifier_movsx:OK\n #361/1 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 1:OK\n #361/2 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 1 @unpriv:OK\n #361/3 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 2:OK\n #361/4 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 2 @unpriv:OK\n #361/5 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 3:OK\n #361/6 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 3 @unpriv:OK\n #361/7 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 4:OK\n #361/8 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 4 @unpriv:OK\n #361/9 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 5:OK\n #361/10 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 5 @unpriv:OK\n #361/11 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 6:OK\n #361/12 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 6 @unpriv:OK\n #361/13 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 7:OK\n #361/14 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 7 @unpriv:OK\n #361/15 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 8:OK\n #361/16 verifier_sdiv/SDIV32', ' non-zero imm divisor', ' check 8 @unpriv:OK\n #361/17 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 1:OK\n #361/18 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 1 @unpriv:OK\n #361/19 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 2:OK\n #361/20 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 2 @unpriv:OK\n #361/21 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 3:OK\n #361/22 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 3 @unpriv:OK\n #361/23 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 4:OK\n #361/24 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 4 @unpriv:OK\n #361/25 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 5:OK\n #361/26 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 5 @unpriv:OK\n #361/27 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 6:OK\n #361/28 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 6 @unpriv:OK\n #361/29 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 7:OK\n #361/30 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 7 @unpriv:OK\n #361/31 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 8:OK\n #361/32 verifier_sdiv/SDIV32', ' non-zero reg divisor', ' check 8 @unpriv:OK\n #361/33 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 1:OK\n #361/34 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 1 @unpriv:OK\n #361/35 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 2:OK\n #361/36 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 2 @unpriv:OK\n #361/37 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 3:OK\n #361/38 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 3 @unpriv:OK\n #361/39 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 4:OK\n #361/40 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 4 @unpriv:OK\n #361/41 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 5:OK\n #361/42 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 5 @unpriv:OK\n #361/43 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 6:OK\n #361/44 verifier_sdiv/SDIV64', ' non-zero imm divisor', ' check 6 @unpriv:OK\n #361/45 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 1:OK\n #361/46 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 1 @unpriv:OK\n #361/47 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 2:OK\n #361/48 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 2 @unpriv:OK\n #361/49 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 3:OK\n #361/50 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 3 @unpriv:OK\n #361/51 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 4:OK\n #361/52 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 4 @unpriv:OK\n #361/53 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 5:OK\n #361/54 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 5 @unpriv:OK\n #361/55 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 6:OK\n #361/56 verifier_sdiv/SDIV64', ' non-zero reg divisor', ' check 6 @unpriv:OK\n #361/57 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 1:OK\n #361/58 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 1 @unpriv:OK\n #361/59 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 2:OK\n #361/60 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 2 @unpriv:OK\n #361/61 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 3:OK\n #361/62 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 3 @unpriv:OK\n #361/63 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 4:OK\n #361/64 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 4 @unpriv:OK\n #361/65 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 5:OK\n #361/66 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 5 @unpriv:OK\n #361/67 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 6:OK\n #361/68 verifier_sdiv/SMOD32', ' non-zero imm divisor', ' check 6 @unpriv:OK\n #361/69 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 1:OK\n #361/70 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 1 @unpriv:OK\n #361/71 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 2:OK\n #361/72 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 2 @unpriv:OK\n #361/73 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 3:OK\n #361/74 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 3 @unpriv:OK\n #361/75 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 4:OK\n #361/76 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 4 @unpriv:OK\n #361/77 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 5:OK\n #361/78 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 5 @unpriv:OK\n #361/79 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 6:OK\n #361/80 verifier_sdiv/SMOD32', ' non-zero reg divisor', ' check 6 @unpriv:OK\n #361/81 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 1:OK\n #361/82 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 1 @unpriv:OK\n #361/83 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 2:OK\n #361/84 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 2 @unpriv:OK\n #361/85 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 3:OK\n #361/86 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 3 @unpriv:OK\n #361/87 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 4:OK\n #361/88 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 4 @unpriv:OK\n #361/89 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 5:OK\n #361/90 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 5 @unpriv:OK\n #361/91 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 6:OK\n #361/92 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 6 @unpriv:OK\n #361/93 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 7:OK\n #361/94 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 7 @unpriv:OK\n #361/95 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 8:OK\n #361/96 verifier_sdiv/SMOD64', ' non-zero imm divisor', ' check 8 @unpriv:OK\n #361/97 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 1:OK\n #361/98 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 1 @unpriv:OK\n #361/99 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 2:OK\n #361/100 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 2 @unpriv:OK\n #361/101 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 3:OK\n #361/102 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 3 @unpriv:OK\n #361/103 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 4:OK\n #361/104 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 4 @unpriv:OK\n #361/105 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 5:OK\n #361/106 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 5 @unpriv:OK\n #361/107 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 6:OK\n #361/108 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 6 @unpriv:OK\n #361/109 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 7:OK\n #361/110 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 7 @unpriv:OK\n #361/111 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 8:OK\n #361/112 verifier_sdiv/SMOD64', ' non-zero reg divisor', ' check 8 @unpriv:OK\n #361/113 verifier_sdiv/SDIV32', ' zero divisor:OK\n #361/114 verifier_sdiv/SDIV32', ' zero divisor @unpriv:OK\n #361/115 verifier_sdiv/SDIV64', ' zero divisor:OK\n #361/116 verifier_sdiv/SDIV64', ' zero divisor @unpriv:OK\n #361/117 verifier_sdiv/SMOD32', ' zero divisor:OK\n #361/118 verifier_sdiv/SMOD32', ' zero divisor @unpriv:OK\n #361/119 verifier_sdiv/SMOD64', ' zero divisor:OK\n #361/120 verifier_sdiv/SMOD64', ' zero divisor @unpriv:OK\n #361 verifier_sdiv:OK\n Summary: 5/163 PASSED', ' 0 SKIPPED', "" 0 FAILED\n\n # ./test_progs -t ldsx_insn\n test_map_val_and_probed_memory:PASS:test_ldsx_insn__open 0 nsec\n test_map_val_and_probed_memory:PASS:test_ldsx_insn__load 0 nsec\n libbpf: prog 'test_ptr_struct_arg': failed to attach: ERROR: strerror_r(-524)=22\n libbpf: prog 'test_ptr_struct_arg': failed to auto-attach: -524\n test_map_val_and_probed_memory:FAIL:test_ldsx_insn__attach unexpected error: -524 (errno 524)\n #116/1 ldsx_insn/map_val and probed_memory:FAIL\n #116/2 ldsx_insn/ctx_member_sign_ext:OK\n #116/3 ldsx_insn/ctx_member_narrow_sign_ext:OK\n #116 ldsx_insn:FAIL\n\n All error logs:\n test_map_val_and_probed_memory:PASS:test_ldsx_insn__open 0 nsec\n test_map_val_and_probed_memory:PASS:test_ldsx_insn__load 0 nsec\n libbpf: prog 'test_ptr_struct_arg': failed to attach: ERROR: strerror_r(-524)=22\n libbpf: prog 'test_ptr_struct_arg': failed to auto-attach: -524\n test_map_val_and_probed_memory:FAIL:test_ldsx_insn__attach unexpected error: -524 (errno 524)\n #116/1 ldsx_insn/map_val and probed_memory:FAIL\n #116 ldsx_insn:FAIL\n Summary: 0/2 PASSED"", ' 0 SKIPPED', ' 1 FAILED\n\nSigned-off-by: Hengqi Chen \nSigned-off-by: Huacai Chen \n', '']",Enable cpu v4 tests for LoongArch in the BPF selftests.,"cpu v4, LoongArch, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +8e1b802503bb630eafc3e97b2daf755368ec96e1,8e1b802503bb630eafc3e97b2daf755368ec96e1,Martin KaFai Lau,martin.lau@kernel.org,1699392363,Martin KaFai Lau,martin.lau@kernel.org,1699399686,3de609f4f0ac0e64b1684ce0007776d92833b703,d84b139f53e8fa8048f16814c6b2a53d7bc15c3d 3c5864ba9cf912ff9809f315d28f296f21563cce,Merge branch 'Let BPF verifier consider {task,"cgroup} is trusted in bpf_iter_reg' + +Chuyi Zhou says: + +==================== +The patchset aims to let the BPF verivier consider +bpf_iter__cgroup->cgroup and bpf_iter__task->task is trusted suggested by +Alexei[1]. + +Please see individual patches for more details. And comments are always +welcome. + +Link[1]:https://lore.kernel.org/bpf/20231022154527.229117-1-zhouchuyi@bytedance.com/T/#mb57725edc8ccdd50a1b165765c7619b4d65ed1b0 + +v2->v1: + * Patch #1: Add Yonghong's ack and add description of similar case in + log. + * Patch #2: Add Yonghong's ack +==================== + +Signed-off-by: Martin KaFai Lau +",[''],Enhances the BPF verifier to trust specific cgroup and task iterators in bpf_iter_reg.,"BPF verifier, trusted, iterators",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3c5864ba9cf912ff9809f315d28f296f21563cce,3c5864ba9cf912ff9809f315d28f296f21563cce,Chuyi Zhou,zhouchuyi@bytedance.com,1699363324,Martin KaFai Lau,martin.lau@kernel.org,1699399686,3de609f4f0ac0e64b1684ce0007776d92833b703,0de4f50de25af79c2a46db55d70cdbd8f985c6d1,"selftests/bpf: get trusted cgrp from bpf_iter__cgroup directly + +Commit f49843afde (selftests/bpf: Add tests for css_task iter combining +with cgroup iter) added a test which demonstrates how css_task iter can be +combined with cgroup iter. That test used bpf_cgroup_from_id() to convert +bpf_iter__cgroup->cgroup to a trusted ptr which is pointless now"," since +with the previous fix","[' we can get a trusted cgroup directly from\nbpf_iter__cgroup.\n\nSigned-off-by: Chuyi Zhou \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231107132204.912120-3-zhouchuyi@bytedance.com\nSigned-off-by: Martin KaFai Lau \n', '']",The commit updates the test to retrieve the trusted cgroup from bpf_iter__cgroup directly.,"trusted cgroup, bpf_iter, selftests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['cgroup like programs'] +0de4f50de25af79c2a46db55d70cdbd8f985c6d1,0de4f50de25af79c2a46db55d70cdbd8f985c6d1,Chuyi Zhou,zhouchuyi@bytedance.com,1699363323,Martin KaFai Lau,martin.lau@kernel.org,1699399465,02dcfa685f6f84672356ac0c8f1fe8716160eb77,d84b139f53e8fa8048f16814c6b2a53d7bc15c3d,bpf: Let verifier consider {task,"cgroup} is trusted in bpf_iter_reg + +BTF_TYPE_SAFE_TRUSTED(struct bpf_iter__task) in verifier.c wanted to +teach BPF verifier that bpf_iter__task -> task is a trusted ptr. But it +doesn't work well. + +The reason is","["" bpf_iter__task -> task would go through btf_ctx_access()\nwhich enforces the reg_type of 'task' is ctx_arg_info->reg_type"", ' and in\ntask_iter.c', ' we actually explicitly declare that the\nctx_arg_info->reg_type is PTR_TO_BTF_ID_OR_NULL.\n\nActually we have a previous case like this[1] where PTR_TRUSTED is added to\nthe arg flag for map_iter.\n\nThis patch sets ctx_arg_info->reg_type is PTR_TO_BTF_ID_OR_NULL |\nPTR_TRUSTED in task_reg_info.\n\nSimilarly', ' bpf_cgroup_reg_info -> cgroup is also PTR_TRUSTED since we are\nunder the protection of cgroup_mutex and we would check cgroup_is_dead()\nin __cgroup_iter_seq_show().\n\nThis patch is to improve the user experience of the newly introduced\nbpf_iter_css_task kfunc before hitting the mainline. The Fixes tag is\npointing to the commit introduced the bpf_iter_css_task kfunc.\n\nLink[1]:https://lore.kernel.org/all/20230706133932.45883-3-aspsk@isovalent.com/\n\nFixes: 9c66dc94b62a (""bpf: Introduce css_task open-coded iterator kfuncs"")\nSigned-off-by: Chuyi Zhou \nAcked-by: Yonghong Song \nLink: https://lore.kernel.org/r/20231107132204.912120-2-zhouchuyi@bytedance.com\nSigned-off-by: Martin KaFai Lau \n', '']",Fix BPF verifier to correctly trust the task pointer in bpf_iter__task context.,"BPF verifier, trusted pointer, bpf_iter__task",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +707df298cbde200b939c70be2577b20775fe3345,707df298cbde200b939c70be2577b20775fe3345,Linus Torvalds,torvalds@linux-foundation.org,1699042059,Linus Torvalds,torvalds@linux-foundation.org,1699042059,b29f663dac88ac45d4f1d1465133c85439febe6c,6bdfe2d88b9ff8b0cce32ce87cd47c0e9d665f48 303d77a6e1707498f09c9d8ee91b1dc07ca315a5,"Merge tag 'powerpc-6.7-1' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux + +Pull powerpc updates from Michael Ellerman: + + - Add support for KVM running as a nested hypervisor under development + versions of PowerVM"," using the new PAPR nested virtualisation API + + - Add support for the BPF prog pack allocator + + - A rework of the non-server MMU handling to support execute-only on + all platforms + + - Some optimisations & cleanups for the powerpc qspinlock code + + - Various other small features and fixes + +Thanks to Aboorva Devarajan","[' Aditya Gupta', ' Amit Machhiwal', ' Benjamin\nGray', ' Christophe Leroy', ' Dr. David Alan Gilbert', ' Gaurav Batra', ' Gautam\nMenghani', ' Geert Uytterhoeven', ' Haren Myneni', ' Hari Bathini', ' Joel Stanley', '\nJordan Niethe', ' Julia Lawall', ' Kautuk Consul', ' Kuan-Wei Chiu', ' Michael\nNeuling', ' Minjie Du', ' Muhammad Muzammil', ' Naveen N Rao', ' Nicholas Piggin', '\nNick Child', ' Nysal Jan K.A', ' Peter Lafreniere', ' Rob Herring', ' Sachin Sant', '\nSebastian Andrzej Siewior', ' Shrikanth Hegde', ' Srikar Dronamraju', ' Stanislav\nKinsburskii', ' Vaibhav Jain', ' Wang Yufen', ' Yang Yingliang', ' and Yuan Tan.\n\n* tag \'powerpc-6.7-1\' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux: (100 commits)\n powerpc/vmcore: Add MMU information to vmcoreinfo\n Revert ""powerpc: add `cur_cpu_spec` symbol to vmcoreinfo""\n powerpc/bpf: use bpf_jit_binary_pack_[alloc|finalize|free]\n powerpc/bpf: rename powerpc64_jit_data to powerpc_jit_data\n powerpc/bpf: implement bpf_arch_text_invalidate for bpf_prog_pack\n powerpc/bpf: implement bpf_arch_text_copy\n powerpc/code-patching: introduce patch_instructions()\n powerpc/32s: Implement local_flush_tlb_page_psize()\n powerpc/pseries: use kfree_sensitive() in plpks_gen_password()\n powerpc/code-patching: Perform hwsync in __patch_instruction() in case of failure\n powerpc/fsl_msi: Use device_get_match_data()\n powerpc: Remove cpm_dp...() macros\n powerpc/qspinlock: Rename yield_propagate_owner tunable\n powerpc/qspinlock: Propagate sleepy if previous waiter is preempted\n powerpc/qspinlock: don\'t propagate the not-sleepy state\n powerpc/qspinlock: propagate owner preemptedness rather than CPU number\n powerpc/qspinlock: stop queued waiters trying to set lock sleepy\n powerpc/perf: Fix disabling BHRB and instruction sampling\n powerpc/trace: Add support for HAVE_FUNCTION_ARG_ACCESS_API\n powerpc/tools: Pass -mabi=elfv2 to gcc-check-mprofile-kernel.sh\n ...\n', '']","This commit merges powerpc updates including nested KVM support, BPF prog pack allocator, MMU rework, and qspinlock optimizations.","nested KVM,BPF prog,optimizations",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,['other'] +7ab89417ed235f56d84c7893d38d4905e38d2692,7ab89417ed235f56d84c7893d38d4905e38d2692,Linus Torvalds,torvalds@linux-foundation.org,1699035458,Linus Torvalds,torvalds@linux-foundation.org,1699035458,0980734f4e492a09e68d820fedce20465c69e3df,31e5f934ff962820995c82a6953176a1c7d18ff5 fed3a1be6433e15833068c701bfde7b422d8b988,"Merge tag 'perf-tools-for-v6.7-1-2023-11-01' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools + +Pull perf tools updates from Namhyung Kim: + ""Build: + + - Compile BPF programs by default if clang (>= 12.0.1) is available + to enable more features like kernel lock contention"," off-cpu + profiling","[' kwork', ' sample filtering and so on.\n\n This can be disabled by passing BUILD_BPF_SKEL=0 to make.\n\n - Produce better error messages for bison on debug build (make\n DEBUG=1) by defining YYDEBUG symbol internally.\n\n perf record:\n\n - Track sideband events (like FORK/MMAP) from all CPUs even if perf\n record targets a subset of CPUs only (using -C option). Otherwise\n it may lose some information happened on a CPU out of the target\n list.\n\n - Fix checking raw sched_switch tracepoint argument using system BTF.\n This affects off-cpu profiling which attaches a BPF program to the\n raw tracepoint.\n\n perf lock contention:\n\n - Add --lock-cgroup option to see contention by cgroups. This should\n be used with BPF only (using -b option).\n\n $ sudo perf lock con -ab --lock-cgroup -- sleep 1\n contended total wait max wait avg wait cgroup\n\n 835 14.06 ms 41.19 us 16.83 us /system.slice/led.service\n 25 122.38 us 13.77 us 4.89 us /\n 44 23.73 us 3.87 us 539 ns /user.slice/user-657345.slice/session-c4.scope\n 1 491 ns 491 ns 491 ns /system.slice/connectd.service\n\n - Add -G/--cgroup-filter option to see contention only for given\n cgroups.\n\n This can be useful when you identified a cgroup in the above\n command and want to investigate more on it. It also works with\n other output options like -t/--threads and -l/--lock-addr.\n\n $ sudo perf lock con -ab -G /user.slice/user-657345.slice/session-c4.scope -- sleep 1\n contended total wait max wait avg wait type caller\n\n 8 77.11 us 17.98 us 9.64 us spinlock futex_wake+0xc8\n 2 24.56 us 14.66 us 12.28 us spinlock tick_do_update_jiffies64+0x25\n 1 4.97 us 4.97 us 4.97 us spinlock futex_q_lock+0x2a\n\n - Use per-cpu array for better spinlock tracking. This is to improve\n performance of the BPF program and to avoid nested contention on a\n lock in the BPF hash map.\n\n - Update callstack check for PowerPC. To find a representative caller\n of a lock', ' it needs to look up the call stacks. It ends the lookup\n when it sees 0 in the call stack buffer. However', "" PowerPC call\n stacks can have 0 values in the beginning so skip them when it\n expects valid call stacks after.\n\n perf kwork:\n\n - Support 'sched' class (for -k option) so that it can see task\n scheduling event (using sched_switch tracepoint) as well as irq and\n workqueue items.\n\n - Add perf kwork top subcommand to show more accurate cpu utilization\n with sched class above. It works both with a recorded data (using\n perf kwork record command) and BPF (using -b option). Unlike perf\n top command"", ' it does not support interactive mode (yet).\n\n $ sudo perf kwork top -b -k sched\n Starting trace', ' Hit to stop and report\n ^C\n Total : 160702.425 ms', ' 8 cpus\n %Cpu(s): 36.00% id', ' 0.00% hi', ' 0.00% si\n %Cpu0 [|||||||||||||||||| 61.66%]\n %Cpu1 [|||||||||||||||||| 61.27%]\n %Cpu2 [||||||||||||||||||| 66.40%]\n %Cpu3 [|||||||||||||||||| 61.28%]\n %Cpu4 [|||||||||||||||||| 61.82%]\n %Cpu5 [||||||||||||||||||||||| 77.41%]\n %Cpu6 [|||||||||||||||||| 61.73%]\n %Cpu7 [|||||||||||||||||| 63.25%]\n\n PID SPID %CPU RUNTIME COMMMAND\n -------------------------------------------------------------\n 0 0 38.72 8089.463 ms [swapper/1]\n 0 0 38.71 8084.547 ms [swapper/3]\n 0 0 38.33 8007.532 ms [swapper/0]\n 0 0 38.26 7992.985 ms [swapper/6]\n 0 0 38.17 7971.865 ms [swapper/4]\n 0 0 36.74 7447.765 ms [swapper/7]\n 0 0 33.59 6486.942 ms [swapper/2]\n 0 0 22.58 3771.268 ms [swapper/5]\n 9545 9351 2.48 447.136 ms sched-messaging\n 9574 9351 2.09 418.583 ms sched-messaging\n 9724 9351 2.05 372.407 ms sched-messaging\n 9531 9351 2.01 368.804 ms sched-messaging\n 9512 9351 2.00 362.250 ms sched-messaging\n 9514 9351 1.95 357.767 ms sched-messaging\n 9538 9351 1.86 384.476 ms sched-messaging\n 9712 9351 1.84 386.490 ms sched-messaging\n 9723 9351 1.83 380.021 ms sched-messaging\n 9722 9351 1.82 382.738 ms sched-messaging\n 9517 9351 1.81 354.794 ms sched-messaging\n 9559 9351 1.79 344.305 ms sched-messaging\n 9725 9351 1.77 365.315 ms sched-messaging\n \n\n - Add hard/soft-irq statistics to perf kwork top. This will show the\n total CPU utilization with IRQ stats like below:\n\n $ sudo perf kwork top -b -k sched', 'irq', 'softirq\n Starting trace', ' Hit to stop and report\n ^C\n Total : 12554.889 ms', ' 8 cpus\n %Cpu(s): 96.23% id', ' 0.10% hi', ' 0.19% si <---- here\n %Cpu0 [| 4.60%]\n %Cpu1 [| 4.59%]\n %Cpu2 [ 2.73%]\n %Cpu3 [| 3.81%]\n \n\n perf bench:\n\n - Add -G/--cgroups option to perf bench sched pipe. The pipe bench is\n good to measure context switch overhead. With this option', ' it puts\n the reader and writer tasks in separate cgroups to enforce context\n switch between two different cgroups.\n\n Also it needs to set CPU affinity of the tasks in a CPU to\n accurately measure the impact of cgroup context switches.\n\n $ sudo perf stat -e context-switches', ""cgroup-switches -- \\\n > taskset -c 0 perf bench sched pipe -l 100000\n # Running 'sched/pipe' benchmark:\n # Executed 100000 pipe operations between two processes\n\n Total time: 0.307 [sec]\n\n 3.078180 usecs/op\n 324867 ops/sec\n\n Performance counter stats for 'taskset -c 0 perf bench sched pipe -l 100000':\n\n 200"", '026 context-switches\n 63 cgroup-switches\n\n 0.321637922 seconds time elapsed\n\n You can see small number of cgroup-switches because both write and\n read tasks are in the same cgroup.\n\n $ sudo mkdir /sys/fs/cgroup/{AAA', 'BBB}\n\n $ sudo perf stat -e context-switches', 'cgroup-switches -- \\\n > taskset -c 0 perf bench sched pipe -l 100000 -G AAA', ""BBB\n # Running 'sched/pipe' benchmark:\n # Executed 100000 pipe operations between two processes\n\n Total time: 0.351 [sec]\n\n 3.512990 usecs/op\n 284657 ops/sec\n\n Performance counter stats for 'taskset -c 0 perf bench sched pipe -l 100000 -G AAA"", ""BBB':\n\n 200"", '020 context-switches\n 200', ""019 cgroup-switches\n\n 0.365034567 seconds time elapsed\n\n Now context-switches and cgroup-switches are almost same. And you\n can see the pipe operation took little more.\n\n - Kill child processes when perf bench sched messaging exited\n abnormally. Otherwise it'd leave the child doing unnecessary work.\n\n perf test:\n\n - Fix various shellcheck issues on the tests written in shell script.\n\n - Skip tests when condition is not satisfied:\n - object code reading test for non-text section addresses.\n - CoreSight test if cs_etm// event is not available.\n - lock contention test if not enough CPUs.\n\n Event parsing:\n\n - Make PMU alias name loading lazy to reduce the startup time in the\n event parsing code for perf record"", ' stat and others in the general\n case.\n\n - Lazily compute PMU default config. In the same sense', "" delay PMU\n initialization until it's really needed to reduce the startup cost.\n\n - Fix event term values that are raw events. The event specification\n can have several terms including event name. But sometimes it\n clashes with raw event encoding which starts with 'r' and has\n hex-digits.\n\n For example"", "" an event named 'read' should be processed as a normal\n event but it was mis-treated as a raw encoding and caused a\n failure.\n\n $ perf stat -e 'uncore_imc_free_running/event=read/' -a sleep 1\n event syntax error: '..nning/event=read/'\n \\___ parser error\n Run 'perf list' for a list of valid events\n\n Usage: perf stat [] []\n\n -e"", ' --event event selector. use \'perf list\' to list available events\n\n Event metrics:\n\n - Add ""Compat"" regex to match event with multiple identifiers.\n\n - Usual updates for Intel', ' Power10', ' Arm telemetry/CMN and AmpereOne.\n\n Misc:\n\n - Assorted memory leak fixes and footprint reduction.\n\n - Add ""bpf_skeletons"" to perf version --build-options so that users\n can check whether their perf tools have BPF support easily.\n\n - Fix unaligned access in Intel-PT packet decoder found by\n undefined-behavior sanitizer.\n\n - Avoid frequency mode for the dummy event. Surprisingly it\'d impact\n kernel timer tick handler performance by force iterating all PMU\n events.\n\n - Update bash shell completion for events and metrics""\n\n* tag \'perf-tools-for-v6.7-1-2023-11-01\' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools: (187 commits)\n perf vendor events intel: Update tsx_cycles_per_elision metrics\n perf vendor events intel: Update bonnell version number to v5\n perf vendor events intel: Update westmereex events to v4\n perf vendor events intel: Update meteorlake events to v1.06\n perf vendor events intel: Update knightslanding events to v16\n perf vendor events intel: Add typo fix for ivybridge FP\n perf vendor events intel: Update a spelling in haswell/haswellx\n perf vendor events intel: Update emeraldrapids to v1.01\n perf vendor events intel: Update alderlake/alderlake events to v1.23\n perf build: Disable BPF skeletons if clang version is < 12.0.1\n perf callchain: Fix spelling mistake ""statisitcs"" -> ""statistics""\n perf report: Fix spelling mistake ""heirachy"" -> ""hierarchy""\n perf python: Fix binding linkage due to rename and move of evsel__increase_rlimit()\n perf tests: test_arm_coresight: Simplify source iteration\n perf vendor events intel: Add tigerlake two metrics\n perf vendor events intel: Add broadwellde two metrics\n perf vendor events intel: Fix broadwellde tma_info_system_dram_bw_use metric\n perf mem_info: Add and use map_symbol__exit and addr_map_symbol__exit\n perf callchain: Minor layout changes to callchain_list\n perf callchain: Make brtype_stat in callchain_list optional\n ...\n', '']",Merge updates to perf tools for enabling BPF program compilation with clang if available.,"perf tools, BPF, clang",It's a build system or CI/CD change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"['tracepoints like programs', 'profile like programs']" +851bbccf6b0c152d98ecf0ec83d75fc97aebf43c,851bbccf6b0c152d98ecf0ec83d75fc97aebf43c,Arnaldo Carvalho de Melo,acme@redhat.com,1697058892,Arnaldo Carvalho de Melo,acme@redhat.com,1699025158,105cee1261cb0773b3626609643b824fd7b99f7d,c8e3ade38bc6545faece71cc6c642ad744d4cea3,"perf build: Warn about missing libelf before warning about missing libbpf + +As libelf is a requirement for libbpf if it is not available"," as in some +container build tests where NO_LIBELF=1 is used","[' then better warn about\nthe most basic library first.\n\nDitto for libz', ' check its availability before libbpf too.\n\nCc: Adrian Hunter \nCc: Ian Rogers \nCc: Jiri Olsa \nCc: Namhyung Kim \nLink: https://lore.kernel.org/lkml/ZUEehyDk0FkPnvMR@kernel.org\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",Update perf build script to warn about missing libelf before missing libbpf.,"perf,libelf,libbpf",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +d84b139f53e8fa8048f16814c6b2a53d7bc15c3d,d84b139f53e8fa8048f16814c6b2a53d7bc15c3d,Björn Töpel,bjorn@rivosinc.com,1698921337,Alexei Starovoitov,ast@kernel.org,1698937041,7a2fe59a181f0c1ac1070327cc757bbbfbbdeb51,94e88b8a3e50d3e60c3ba6a5c316729587595210,"selftests/bpf: Fix broken build where char is unsigned + +There are architectures where char is not signed. If so"," the following +error is triggered: + + | xdp_hw_metadata.c:435:42: error: result of comparison of constant -1 \ + | with expression of type 'char' is always true \ + | [-Werror","['-Wtautological-constant-out-of-range-compare]\n | 435 | while ((opt = getopt(argc', ' argv', ' ""mh"")) != -1) {\n | | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~\n | 1 error generated.\n\nCorrect by changing the char to int.\n\nFixes: bb6a88885fde (""selftests/bpf: Add options and frags to xdp_hw_metadata"")\nSigned-off-by: Björn Töpel \nAcked-by: Larysa Zaremba \nTested-by: Anders Roxell \nLink: https://lore.kernel.org/r/20231102103537.247336-1-bjorn@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fix build error in selftests/bpf due to unsigned char architecture issue.,"selftests,bpf,unsigned",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['xdp like programs', 'other']" +94e88b8a3e50d3e60c3ba6a5c316729587595210,94e88b8a3e50d3e60c3ba6a5c316729587595210,Alexei Starovoitov,ast@kernel.org,1698904468,Alexei Starovoitov,ast@kernel.org,1698904468,168c8cc8161f049ccfa8fb6f39ff3f6a0d8454bf,698b8c5e3b5505ac00102caf9e4843b71192b586 3c41971550f58f2e006c58aa71e8c23ad312110f,"Merge branch 'bpf-fix-precision-tracking-for-bpf_alu-bpf_to_be-bpf_end' + +Shung-Hsi Yu says: + +==================== +bpf: Fix precision tracking for BPF_ALU | BPF_TO_BE | BPF_END + +Changes since v1: +- add test for negation and bswap (Alexei"," Eduard) +- add test for BPF_TO_LE as well to cover all types of BPF_END opcode +- remove vals map and trigger backtracking with jump instead","["" based of\n Eduard's code\n- v1 at https://lore.kernel.org/bpf/20231030132145.20867-1-shung-hsi.yu@suse.com\n\nThis patchset fixes and adds selftest for the issue reported by Mohamed\nMahmoud and Toke Høiland-Jørgensen where the kernel can run into a\nverifier bug during backtracking of BPF_ALU | BPF_TO_BE | BPF_END\ninstruction[0]. As seen in the verifier log below"", "" r0 was incorrectly\nmarked as precise even tough its value was not being used.\n\nPatch 1 fixes the issue based on Andrii's analysis"", ' and patch 2 adds a\nselftest for such case using inline assembly. Please see individual\npatch for detail.\n\n ...\n\tmark_precise: frame2: regs=r2 stack= before 1891: (77) r2 >>= 56\n\tmark_precise: frame2: regs=r2 stack= before 1890: (dc) r2 = be64 r2\n\tmark_precise: frame2: regs=r0', 'r2 stack= before 1889: (73) *(u8 *)(r1 +47) = r3\n\t...\n\tmark_precise: frame2: regs=r0 stack= before 212: (85) call pc+1617\n\tBUG regs 1\n\tprocessed 5112 insns (limit 1000000) max_states_per_insn 4 total_states 92 peak_states 90 mark_read 20\n\n0: https://lore.kernel.org/r/87jzrrwptf.fsf@toke.dk\n\nShung-Hsi Yu (2):\n bpf: Fix precision tracking for BPF_ALU | BPF_TO_BE | BPF_END\n selftests/bpf: precision tracking test for BPF_NEG and BPF_END\n\n kernel/bpf/verifier.c | 7 +-\n .../selftests/bpf/prog_tests/verifier.c | 2 +\n .../selftests/bpf/progs/verifier_precision.c | 93 +++++++++++++++++++\n 3 files changed', ' 101 insertions(+)', ' 1 deletion(-)\n create mode 100644 tools/testing/selftests/bpf/progs/verifier_precision.c\n\nbase-commit: c17cda15cc86e65e9725641daddcd7a63cc9ad01\n====================\n\nLink: https://lore.kernel.org/r/20231102053913.12004-1-shung-hsi.yu@suse.com\nSigned-off-by: Alexei Starovoitov \n', '']","The commit fixes precision tracking for BPF_ALU, BPF_TO_BE, BPF_END and adds relevant tests.","precision, BPF_ALU, BPF_END",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3c41971550f58f2e006c58aa71e8c23ad312110f,3c41971550f58f2e006c58aa71e8c23ad312110f,Shung-Hsi Yu,shung-hsi.yu@suse.com,1698903545,Alexei Starovoitov,ast@kernel.org,1698904468,168c8cc8161f049ccfa8fb6f39ff3f6a0d8454bf,291d044fd51f8484066300ee42afecf8c8db7b3a,"selftests/bpf: precision tracking test for BPF_NEG and BPF_END + +As seen from previous commit that fix backtracking for BPF_ALU | BPF_TO_BE +| BPF_END"," both BPF_NEG and BPF_END require special handling. Add tests +written with inline assembly to check that the verifier does not incorrecly +use the src_reg field of BPF_NEG and BPF_END (including bswap added in v4). + +Suggested-by: Eduard Zingerman +Signed-off-by: Shung-Hsi Yu +Link: https://lore.kernel.org/r/20231102053913.12004-4-shung-hsi.yu@suse.com +Signed-off-by: Alexei Starovoitov +",[''],Add tests for precision tracking of BPF_NEG and BPF_END handling in verifier.,"precision tracking,test cases,BPF_NEG",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +291d044fd51f8484066300ee42afecf8c8db7b3a,291d044fd51f8484066300ee42afecf8c8db7b3a,Shung-Hsi Yu,shung-hsi.yu@suse.com,1698903543,Alexei Starovoitov,ast@kernel.org,1698904467,c89109320ecb69c5eea9fdb3cd4580dbf031ddae,698b8c5e3b5505ac00102caf9e4843b71192b586,"bpf: Fix precision tracking for BPF_ALU | BPF_TO_BE | BPF_END + +BPF_END and BPF_NEG has a different specification for the source bit in +the opcode compared to other ALU/ALU64 instructions"," and is either +reserved or use to specify the byte swap endianness. In both cases the +source bit does not encode source operand location","[' and src_reg is a\nreserved field.\n\nbacktrack_insn() currently does not differentiate BPF_END and BPF_NEG\nfrom other ALU/ALU64 instructions', ' which leads to r0 being incorrectly\nmarked as precise when processing BPF_ALU | BPF_TO_BE | BPF_END\ninstructions. This commit teaches backtrack_insn() to correctly mark\nprecision for such case.\n\nWhile precise tracking of BPF_NEG and other BPF_END instructions are\ncorrect and does not need fixing', ' this commit opt to process all BPF_NEG\nand BPF_END instructions within the same if-clause to better align with\ncurrent convention used in the verifier (e.g. check_alu_op).\n\nFixes: b5dc0163d8fd (""bpf: precise scalar_value tracking"")\nCc: stable@vger.kernel.org\nReported-by: Mohamed Mahmoud \nCloses: https://lore.kernel.org/r/87jzrrwptf.fsf@toke.dk\nTested-by: Toke Høiland-Jørgensen \nTested-by: Tao Lyu \nAcked-by: Eduard Zingerman \nSigned-off-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/r/20231102053913.12004-2-shung-hsi.yu@suse.com\nSigned-off-by: Alexei Starovoitov \n', '']","Fixed precision tracking for BPF_ALU, BPF_TO_BE, and BPF_END instructions in eBPF.","precision tracking, BPF_ALU, BPF_END",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +698b8c5e3b5505ac00102caf9e4843b71192b586,698b8c5e3b5505ac00102caf9e4843b71192b586,Alexei Starovoitov,ast@kernel.org,1698904160,Alexei Starovoitov,ast@kernel.org,1698904160,b34584327520a6b746403e0b2583fd875f29d177,9af3775962afa8b5cd0cc30c1e454405a650c1f3 d8234d47c4aa494d789b85562fa90e837b4575f9,"Merge branch 'relax-allowlist-for-open-coded-css_task-iter' + +Chuyi Zhou says: + +==================== +Relax allowlist for open-coded css_task iter + +Hi"," +The patchset aims to relax the allowlist for open-coded css_task iter +suggested by Alexei[1]. + +Please see individual patches for more details. And comments are always +welcome. + +Patch summary: + * Patch #1: Relax the allowlist and let css_task iter can be used in + bpf iters and any sleepable progs. + * Patch #2: Add a test in cgroup_iters.c which demonstrates how + css_task iters can be combined with cgroup iter. + * Patch #3: Add a test to prove css_task iter can be used in normal + * sleepable progs. +link[1]:https://lore.kernel.org/lkml/CAADnVQKafk_junRyE=-FVAik4hjTRDtThymYGEL8hGTuYoOGpA@mail.gmail.com/ +--- + +Changes in v2: + * Fix the incorrect logic in check_css_task_iter_allowlist. Use + expected_attach_type to check whether we are using bpf_iters. + * Link to v1:https://lore.kernel.org/bpf/20231022154527.229117-1-zhouchuyi@bytedance.com/T/#m946f9cde86b44a13265d9a44c5738a711eb578fd +Changes in v3: + * Add a testcase to prove css_task can be used in fentry.s + * Link to v2:https://lore.kernel.org/bpf/20231024024240.42790-1-zhouchuyi@bytedance.com/T/#m14a97041ff56c2df21bc0149449abd275b73f6a3 +Changes in v4: + * Add Yonghong's ack for patch #1 and patch #2. + * Solve Yonghong's comments for patch #2 + * Move prog 'iter_css_task_for_each_sleep' from iters_task_failure.c to + iters_css_task.c. Use RUN_TESTS to prove we can load this prog. + * Link to v3:https://lore.kernel.org/bpf/20231025075914.30979-1-zhouchuyi@bytedance.com/T/#m3200d8ad29af4ffab97588e297361d0a45d7585d + +--- +==================== + +Link: https://lore.kernel.org/r/20231031050438.93297-1-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov +",[''],The commit relaxes the allowlist for open-coded css_task iter in BPF iters and introduces associated tests.,"allowlist, css_task, bpf iters",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['cgroup like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d8234d47c4aa494d789b85562fa90e837b4575f9,d8234d47c4aa494d789b85562fa90e837b4575f9,Chuyi Zhou,zhouchuyi@bytedance.com,1698728678,Alexei Starovoitov,ast@kernel.org,1698904160,b34584327520a6b746403e0b2583fd875f29d177,f49843afde6771ef6ed5d021eacafacfc98a58bf,"selftests/bpf: Add test for using css_task iter in sleepable progs + +This Patch add a test to prove css_task iter can be used in normal +sleepable progs. + +Signed-off-by: Chuyi Zhou +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231031050438.93297-4-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov +",,Adds a test to validate the use of css_task iter in sleepable eBPF programs.,"selftests, css_task, sleepable",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', ""It's not related to any of the above.""]" +f49843afde6771ef6ed5d021eacafacfc98a58bf,f49843afde6771ef6ed5d021eacafacfc98a58bf,Chuyi Zhou,zhouchuyi@bytedance.com,1698728677,Alexei Starovoitov,ast@kernel.org,1698904160,0cb994bfda2cbc5b435bff4513c41ae622264af2,3091b667498b0a212e760e1033e5f9b8c33a948f,"selftests/bpf: Add tests for css_task iter combining with cgroup iter + +This patch adds a test which demonstrates how css_task iter can be combined +with cgroup iter and it won't cause deadlock"," though cgroup iter is not +sleepable. + +Signed-off-by: Chuyi Zhou +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231031050438.93297-3-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov +",[''],Add selftests demonstrating the combination of css_task iter with cgroup iter to avoid deadlock.,"css_task iter,cgroup iter,selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['cgroup like programs'] +3091b667498b0a212e760e1033e5f9b8c33a948f,3091b667498b0a212e760e1033e5f9b8c33a948f,Chuyi Zhou,zhouchuyi@bytedance.com,1698728676,Alexei Starovoitov,ast@kernel.org,1698904160,64e1da0f69e939ed6c28ea8b5d32ee3b35033549,9af3775962afa8b5cd0cc30c1e454405a650c1f3,"bpf: Relax allowlist for css_task iter + +The newly added open-coded css_task iter would try to hold the global +css_set_lock in bpf_iter_css_task_new"," so the bpf side has to be careful in +where it allows to use this iter. The mainly concern is dead locking on +css_set_lock. check_css_task_iter_allowlist() in verifier enforced css_task +can only be used in bpf_lsm hooks and sleepable bpf_iter. + +This patch relax the allowlist for css_task iter. Any lsm and any iter +(even non-sleepable) and any sleepable are safe since they would not hold +the css_set_lock before entering BPF progs context. + +This patch also fixes the misused BPF_TRACE_ITER in +check_css_task_iter_allowlist which compared bpf_prog_type with +bpf_attach_type. + +Fixes: 9c66dc94b62ae (""bpf: Introduce css_task open-coded iterator kfuncs"") +Signed-off-by: Chuyi Zhou +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231031050438.93297-2-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov +",[''],The commit relaxes the allowlist for css_task iterator to prevent deadlocks on css_set_lock in BPF programs.,relax allowlist css_task,It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['LSM like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9af3775962afa8b5cd0cc30c1e454405a650c1f3,9af3775962afa8b5cd0cc30c1e454405a650c1f3,Andrii Nakryiko,andrii@kernel.org,1698542109,Alexei Starovoitov,ast@kernel.org,1698903758,582bbd2b8038cd7d5403059664349cc503d87742,fd381ce60a2d79cc967506208085336d3d268ae0,"selftests/bpf: fix test_maps' use of bpf_map_create_opts + +Use LIBBPF_OPTS() macro to properly initialize bpf_map_create_opts in +test_maps' tests. + +Signed-off-by: Andrii Nakryiko +Acked-by: Yonghong Song +Link: https://lore.kernel.org/r/20231029011509.2479232-1-andrii@kernel.org +Signed-off-by: Alexei Starovoitov +",,Fixes initialization of bpf_map_create_opts in selftests/bpf using LIBBPF_OPTS() macro.,"selftests,bpf,LIBBPF_OPTS",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +fd381ce60a2d79cc967506208085336d3d268ae0,fd381ce60a2d79cc967506208085336d3d268ae0,Hou Tao,houtao1@huawei.com,1698647776,Alexei Starovoitov,ast@kernel.org,1698903451,fe69f57901645c230fa71f0a90e8d9644492165e,15fb6f2b6c4c3c129adc2412ae12ec15e60a6adb,"bpf: Check map->usercnt after timer->timer is assigned + +When there are concurrent uref release and bpf timer init operations"," +the following sequence diagram is possible. It will break the guarantee +provided by bpf_timer: bpf_timer will still be alive after userspace +application releases or unpins the map. It also will lead to kmemleak +for old kernel version which doesn't release bpf_timer when map is +released. + +bpf program X: + +bpf_timer_init() + lock timer->lock + read timer->timer as NULL + read map->usercnt != 0 + + process Y: + + close(map_fd) + // put last uref + bpf_map_put_uref() + atomic_dec_and_test(map->usercnt) + array_map_free_timers() + bpf_timer_cancel_and_free() + // just return + read timer->timer is NULL + + t = bpf_map_kmalloc_node() + timer->timer = t + unlock timer->lock + +Fix the problem by checking map->usercnt after timer->timer is assigned","['\nso when there are concurrent uref release and bpf timer init', ' either\nbpf_timer_cancel_and_free() from uref release reads a no-NULL timer\nor the newly-added atomic64_read() returns a zero usercnt.\n\nBecause atomic_dec_and_test(map->usercnt) and READ_ONCE(timer->timer)\nin bpf_timer_cancel_and_free() are not protected by a lock', ' so add\na memory barrier to guarantee the order between map->usercnt and\ntimer->timer. Also use WRITE_ONCE(timer->timer', ' x) to match the lockless\nread of timer->timer in bpf_timer_cancel_and_free().\n\nReported-by: Hsin-Wei Hung \nCloses: https://lore.kernel.org/bpf/CABcoxUaT2k9hWsS1tNgXyoU3E-=PuOgMn737qK984fbFmfYixQ@mail.gmail.com\nFixes: b00628b1c7d5 (""bpf: Introduce bpf timers."")\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231030063616.1653024-1-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes a race condition between BPF timer initialization and user reference release leading to memory leak in bpf programs.,"bpf,timer,map",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +15fb6f2b6c4c3c129adc2412ae12ec15e60a6adb,15fb6f2b6c4c3c129adc2412ae12ec15e60a6adb,Dave Marchevsky,davemarchevsky@fb.com,1698789385,Alexei Starovoitov,ast@kernel.org,1698903233,03f6aca296ff77a4608cbb68663a7415b72f29b1,391145ba2accc48b596f3d438af1a6255b62a555,bpf: Add __bpf_hook_{start,"end} macros + +Not all uses of __diag_ignore_all(...) in BPF-related code in order to +suppress warnings are wrapping kfunc definitions. Some ""hook point"" +definitions - small functions meant to be used as attach points for +fentry and similar BPF progs - need to suppress -Wmissing-declarations. + +We could use __bpf_kfunc_{start","['end}_defs added in the previous patch in\nsuch cases', ' but this might be confusing to someone unfamiliar with BPF\ninternals. Instead', ' this patch adds __bpf_hook_{start', 'end} macros', '\ncurrently having the same effect as __bpf_kfunc_{start', 'end}_defs', ' then\nuses them to suppress warnings for two hook points in the kernel itself\nand some bpf_testmod hook points as well.\n\nSigned-off-by: Dave Marchevsky \nCc: Yafang Shao \nAcked-by: Jiri Olsa \nAcked-by: Yafang Shao \nLink: https://lore.kernel.org/r/20231031215625.2343848-2-davemarchevsky@fb.com\nSigned-off-by: Alexei Starovoitov \n', '']",Add macros for suppressing missing declaration warnings in BPF-related hook point definitions.,"macros,suppress,warnings",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['kprobe/uprobe/ftrace like programs'] +391145ba2accc48b596f3d438af1a6255b62a555,391145ba2accc48b596f3d438af1a6255b62a555,Dave Marchevsky,davemarchevsky@fb.com,1698789384,Alexei Starovoitov,ast@kernel.org,1698903233,f529f9f2ea3b0c8ad83a4e37a10c00cafa511295,cd60f410ddc0cd663045d15936155421b6f708fd,bpf: Add __bpf_kfunc_{start,"end}_defs macros + +BPF kfuncs are meant to be called from BPF programs. Accordingly","[' most\nkfuncs are not called from anywhere in the kernel', ' which the\n-Wmissing-prototypes warning is unhappy about. We\'ve peppered\n__diag_ignore_all(""-Wmissing-prototypes""', ' ... everywhere kfuncs are\ndefined in the codebase to suppress this warning.\n\nThis patch adds two macros meant to bound one or many kfunc definitions.\nAll existing kfunc definitions which use these __diag calls to suppress\n-Wmissing-prototypes are migrated to use the newly-introduced macros.\nA new __diag_ignore_all - for ""-Wmissing-declarations"" - is added to the\n__bpf_kfunc_start_defs macro based on feedback from Andrii on an earlier\nversion of this patch [0] and another recent mailing list thread [1].\n\nIn the future we might need to ignore different warnings or do other\nkfunc-specific things. This change will make it easier to make such\nmodifications for all kfunc defs.\n\n [0]: https://lore.kernel.org/bpf/CAEf4BzaE5dRWtK6RPLnjTW-MW9sx9K3Fn6uwqCTChK2Dcb1Xig@mail.gmail.com/\n [1]: https://lore.kernel.org/bpf/ZT+2qCc%2FaXep0%2FLf@krava/\n\nSigned-off-by: Dave Marchevsky \nSuggested-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nCc: Jiri Olsa \nAcked-by: Jiri Olsa \nAcked-by: David Vernet \nAcked-by: Yafang Shao \nLink: https://lore.kernel.org/r/20231031215625.2343848-1-davemarchevsky@fb.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit introduces macros for BPF kfunc definitions to support calling them from BPF programs.,"kfuncs,macros,BPF",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cd60f410ddc0cd663045d15936155421b6f708fd,cd60f410ddc0cd663045d15936155421b6f708fd,Manu Bretelle,chantr4@gmail.com,1698791766,Alexei Starovoitov,ast@kernel.org,1698903101,4cecd389d12844b66902c0d784b39f726698dfd6,b479d38ba959a8e3ffc4d9f760a9f2e4b9027e66,"selftests/bpf: fix test_bpffs + +Currently this tests tries to umount /sys/kernel/debug (TDIR) but the +system it is running on may have mounts below. + +For example"," danobi/vmtest [0] VMs have + mount -t tracefs tracefs /sys/kernel/debug/tracing +as part of their init. + +This change instead creates a ""random"" directory under /tmp and uses this +as TDIR. +If the directory already exists","[' ignore the error and keep moving on.\n\nTest:\n\nOriginally:\n\n $ vmtest -k $KERNEL_REPO/arch/x86_64/boot/bzImage ""./test_progs -vv -a test_bpffs""\n => bzImage\n ===> Booting\n ===> Setting up VM\n ===> Running command\n [ 2.138818] bpf_testmod: loading out-of-tree module taints kernel.\n [ 2.140913] bpf_testmod: module verification failed: signature and/or required key missing - tainting kernel\n bpf_testmod.ko is already unloaded.\n Loading bpf_testmod.ko...\n Successfully loaded bpf_testmod.ko.\n test_test_bpffs:PASS:clone 0 nsec\n fn:PASS:unshare 0 nsec\n fn:PASS:mount / 0 nsec\n fn:FAIL:umount /sys/kernel/debug unexpected error: -1 (errno 16)\n bpf_testmod.ko is already unloaded.\n Loading bpf_testmod.ko...\n Successfully loaded bpf_testmod.ko.\n test_test_bpffs:PASS:clone 0 nsec\n test_test_bpffs:PASS:waitpid 0 nsec\n test_test_bpffs:FAIL:bpffs test failed 255#282 test_bpffs:FAIL\n Summary: 0/0 PASSED', ' 0 SKIPPED', "" 1 FAILED\n Successfully unloaded bpf_testmod.ko.\n Command failed with exit code: 1\n\nAfter this change:\n\n $ vmtest -k $(make image_name) 'cd tools/testing/selftests/bpf && ./test_progs -vv -a test_bpffs'\n => bzImage\n ===> Booting\n ===> Setting up VM\n ===> Running command\n [ 2.295696] bpf_testmod: loading out-of-tree module taints kernel.\n [ 2.296468] bpf_testmod: module verification failed: signature and/or required key missing - tainting kernel\n bpf_testmod.ko is already unloaded.\n Loading bpf_testmod.ko...\n Successfully loaded bpf_testmod.ko.\n test_test_bpffs:PASS:clone 0 nsec\n fn:PASS:unshare 0 nsec\n fn:PASS:mount / 0 nsec\n fn:PASS:mount tmpfs 0 nsec\n fn:PASS:mkdir /tmp/test_bpffs_testdir/fs1 0 nsec\n fn:PASS:mkdir /tmp/test_bpffs_testdir/fs2 0 nsec\n fn:PASS:mount bpffs /tmp/test_bpffs_testdir/fs1 0 nsec\n fn:PASS:mount bpffs /tmp/test_bpffs_testdir/fs2 0 nsec\n fn:PASS:reading /tmp/test_bpffs_testdir/fs1/maps.debug 0 nsec\n fn:PASS:reading /tmp/test_bpffs_testdir/fs2/progs.debug 0 nsec\n fn:PASS:creating /tmp/test_bpffs_testdir/fs1/a 0 nsec\n fn:PASS:creating /tmp/test_bpffs_testdir/fs1/a/1 0 nsec\n fn:PASS:creating /tmp/test_bpffs_testdir/fs1/b 0 nsec\n fn:PASS:create_map(ARRAY) 0 nsec\n fn:PASS:pin map 0 nsec\n fn:PASS:stat(/tmp/test_bpffs_testdir/fs1/a) 0 nsec\n fn:PASS:renameat2(/fs1/a"", ' /fs1/b', "" RENAME_EXCHANGE) 0 nsec\n fn:PASS:stat(/tmp/test_bpffs_testdir/fs1/b) 0 nsec\n fn:PASS:b should have a's inode 0 nsec\n fn:PASS:access(/tmp/test_bpffs_testdir/fs1/b/1) 0 nsec\n fn:PASS:stat(/tmp/test_bpffs_testdir/fs1/map) 0 nsec\n fn:PASS:renameat2(/fs1/c"", ' /fs1/b', "" RENAME_EXCHANGE) 0 nsec\n fn:PASS:stat(/tmp/test_bpffs_testdir/fs1/b) 0 nsec\n fn:PASS:b should have c's inode 0 nsec\n fn:PASS:access(/tmp/test_bpffs_testdir/fs1/c/1) 0 nsec\n fn:PASS:renameat2(RENAME_NOREPLACE) 0 nsec\n fn:PASS:access(/tmp/test_bpffs_testdir/fs1/b) 0 nsec\n bpf_testmod.ko is already unloaded.\n Loading bpf_testmod.ko...\n Successfully loaded bpf_testmod.ko.\n test_test_bpffs:PASS:clone 0 nsec\n test_test_bpffs:PASS:waitpid 0 nsec\n test_test_bpffs:PASS:bpffs test 0 nsec\n #282 test_bpffs:OK\n Summary: 1/0 PASSED"", ' 0 SKIPPED', ' 0 FAILED\n Successfully unloaded bpf_testmod.ko.\n\n[0] https://github.com/danobi/vmtest\n\nThis is a follow-up of https://lore.kernel.org/bpf/20231024201852.1512720-1-chantr4@gmail.com/T/\n\nv1 -> v2:\n - use a TDIR name that is related to test\n - use C-style comments\n\nSigned-off-by: Manu Bretelle \nAcked-by: Jiri Olsa \nLink: https://lore.kernel.org/r/20231031223606.2927976-1-chantr4@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes the test_bpffs by using a temporary directory instead of umounting /sys/kernel/debug.,"selftests,bpf,test_bpffs",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b479d38ba959a8e3ffc4d9f760a9f2e4b9027e66,b479d38ba959a8e3ffc4d9f760a9f2e4b9027e66,Alexei Starovoitov,ast@kernel.org,1698903027,Alexei Starovoitov,ast@kernel.org,1698903028,fb460b6b1633d37877ab1ffe856a8d9ca5b30d21,05670f81d1287c40ec861186e4c4e3401013e7fb 85eb035e6cfd615071256592e1dbe72c1d99c24b,"Merge branch 'bpf-fix-incorrect-immediate-spill' + +Hao Sun says: + +==================== +bpf: Fix incorrect immediate spill + +Immediate is incorrectly cast to u32 before being spilled"," losing sign +information. The range information is incorrect after load again. Fix +immediate spill by remove the cast. The second patch add a test case +for this. + +Signed-off-by: Hao Sun +--- +Changes in v3: +- Change the expected log to fix the test case +- Link to v2: https://lore.kernel.org/r/20231101-fix-check-stack-write-v2-0-cb7c17b869b0@gmail.com + +Changes in v2: +- Add fix and cc tags. +- Link to v1: https://lore.kernel.org/r/20231026-fix-check-stack-write-v1-0-6b325ef3ce7e@gmail.com + +--- +==================== + +Link: https://lore.kernel.org/r/20231101-fix-check-stack-write-v3-0-f05c2b1473d5@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],This commit fixes an issue with immediate value spill and adds a test case to validate the correction.,"fix, immediate, spill",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +85eb035e6cfd615071256592e1dbe72c1d99c24b,85eb035e6cfd615071256592e1dbe72c1d99c24b,Hao Sun,sunhao.th@gmail.com,1698842032,Alexei Starovoitov,ast@kernel.org,1698903027,fb460b6b1633d37877ab1ffe856a8d9ca5b30d21,811c363645b33e6e22658634329e95f383dfc705,"selftests/bpf: Add test for immediate spilled to stack + +Add a test to check if the verifier correctly reason about the sign +of an immediate spilled to stack by BPF_ST instruction. + +Signed-off-by: Hao Sun +Link: https://lore.kernel.org/r/20231101-fix-check-stack-write-v3-2-f05c2b1473d5@gmail.com +Signed-off-by: Alexei Starovoitov +",,Add a test case to verify immediate spill to stack in eBPF selftests.,"test, immediate, stack",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +811c363645b33e6e22658634329e95f383dfc705,811c363645b33e6e22658634329e95f383dfc705,Hao Sun,sunhao.th@gmail.com,1698842031,Alexei Starovoitov,ast@kernel.org,1698903027,48076af7e2c013e22f467140a05fe89fc61cd29c,05670f81d1287c40ec861186e4c4e3401013e7fb,"bpf: Fix check_stack_write_fixed_off() to correctly spill imm + +In check_stack_write_fixed_off()"," imm value is cast to u32 before being +spilled to the stack. Therefore","[' the sign information is lost', ' and the\nrange information is incorrect when load from the stack again.\n\nFor the following prog:\n0: r2 = r10\n1: *(u64*)(r2 -40) = -44\n2: r0 = *(u64*)(r2 - 40)\n3: if r0 s<= 0xa goto +2\n4: r0 = 1\n5: exit\n6: r0 = 0\n7: exit\n\nThe verifier gives:\nfunc#0 @0\n0: R1=ctx(off=0', 'imm=0) R10=fp0\n0: (bf) r2 = r10 ; R2_w=fp0 R10=fp0\n1: (7a) *(u64 *)(r2 -40) = -44 ; R2_w=fp0 fp-40_w=4294967252\n2: (79) r0 = *(u64 *)(r2 -40) ; R0_w=4294967252 R2_w=fp0\nfp-40_w=4294967252\n3: (c5) if r0 s< 0xa goto pc+2\nmark_precise: frame0: last_idx 3 first_idx 0 subseq_idx -1\nmark_precise: frame0: regs=r0 stack= before 2: (79) r0 = *(u64 *)(r2 -40)\n3: R0_w=4294967252\n4: (b7) r0 = 1 ; R0_w=1\n5: (95) exit\nverification time 7971 usec\nstack depth 40\nprocessed 6 insns (limit 1000000) max_states_per_insn 0 total_states 0\npeak_states 0 mark_read 0\n\nSo remove the incorrect cast', ' since imm field is declared as s32', ' and\n__mark_reg_known() takes u64', ' so imm would be correctly sign extended\nby compiler.\n\nFixes: ecdf985d7615 (""bpf: track immediate values written to stack by BPF_ST instruction"")\nCc: stable@vger.kernel.org\nSigned-off-by: Hao Sun \nAcked-by: Shung-Hsi Yu \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231101-fix-check-stack-write-v3-1-f05c2b1473d5@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixed the check_stack_write_fixed_off function to properly cast and spill imm values to the stack.,"bpf, fix, spill",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +05670f81d1287c40ec861186e4c4e3401013e7fb,05670f81d1287c40ec861186e4c4e3401013e7fb,Matthieu Baerts,matttbe@kernel.org,1698862561,Alexei Starovoitov,ast@kernel.org,1698902905,f8b1c7408591fccad68ac32a2a7bee01c52fc64c,2b7ac0c87d985c92e519995853c52b9649ea4b07,"bpf: fix compilation error without CGROUPS + +Our MPTCP CI complained [1] -- and KBuild too -- that it was no longer +possible to build the kernel without CONFIG_CGROUPS: + + kernel/bpf/task_iter.c: In function 'bpf_iter_css_task_new': + kernel/bpf/task_iter.c:919:14: error: 'CSS_TASK_ITER_PROCS' undeclared (first use in this function) + 919 | case CSS_TASK_ITER_PROCS | CSS_TASK_ITER_THREADED: + | ^~~~~~~~~~~~~~~~~~~ + kernel/bpf/task_iter.c:919:14: note: each undeclared identifier is reported only once for each function it appears in + kernel/bpf/task_iter.c:919:36: error: 'CSS_TASK_ITER_THREADED' undeclared (first use in this function) + 919 | case CSS_TASK_ITER_PROCS | CSS_TASK_ITER_THREADED: + | ^~~~~~~~~~~~~~~~~~~~~~ + kernel/bpf/task_iter.c:927:60: error: invalid application of 'sizeof' to incomplete type 'struct css_task_iter' + 927 | kit->css_it = bpf_mem_alloc(&bpf_global_ma"," sizeof(struct css_task_iter)); + | ^~~~~~ + kernel/bpf/task_iter.c:930:9: error: implicit declaration of function 'css_task_iter_start'; did you mean 'task_seq_start'? [-Werror=implicit-function-declaration] + 930 | css_task_iter_start(css","[' flags', "" kit->css_it);\n | ^~~~~~~~~~~~~~~~~~~\n | task_seq_start\n kernel/bpf/task_iter.c: In function 'bpf_iter_css_task_next':\n kernel/bpf/task_iter.c:940:16: error: implicit declaration of function 'css_task_iter_next'; did you mean 'class_dev_iter_next'? [-Werror=implicit-function-declaration]\n 940 | return css_task_iter_next(kit->css_it);\n | ^~~~~~~~~~~~~~~~~~\n | class_dev_iter_next\n kernel/bpf/task_iter.c:940:16: error: returning 'int' from a function with return type 'struct task_struct *' makes pointer from integer without a cast [-Werror=int-conversion]\n 940 | return css_task_iter_next(kit->css_it);\n | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n kernel/bpf/task_iter.c: In function 'bpf_iter_css_task_destroy':\n kernel/bpf/task_iter.c:949:9: error: implicit declaration of function 'css_task_iter_end' [-Werror=implicit-function-declaration]\n 949 | css_task_iter_end(kit->css_it);\n | ^~~~~~~~~~~~~~~~~\n\nThis patch simply surrounds with a #ifdef the new code requiring CGroups\nsupport. It seems enough for the compiler and this is similar to\nbpf_iter_css_{new"", 'next', 'destroy}() functions where no other #ifdef have\nbeen added in kernel/bpf/helpers.c and in the selftests.\n\nFixes: 9c66dc94b62a (""bpf: Introduce css_task open-coded iterator kfuncs"")\nLink: https://github.com/multipath-tcp/mptcp_net-next/actions/runs/6665206927\nReported-by: kernel test robot \nCloses: https://lore.kernel.org/oe-kbuild-all/202310260528.aHWgVFqq-lkp@intel.com/\nSigned-off-by: Matthieu Baerts \n[ added missing ifdefs for BTF_ID cgroup definitions ]\nSigned-off-by: Jiri Olsa \nLink: https://lore.kernel.org/r/20231101181601.1493271-1-jolsa@kernel.org\nSigned-off-by: Alexei Starovoitov \n', '']",Fix compilation error in BPF task iterator when CONFIG_CGROUPS is not enabled in kernel build.,"BPF, compilation, CONFIG_CGROUPS",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f5277ad1e9768dbd05b1ae8dcdba690215d8c5b7,f5277ad1e9768dbd05b1ae8dcdba690215d8c5b7,Linus Torvalds,torvalds@linux-foundation.org,1698873394,Linus Torvalds,torvalds@linux-foundation.org,1698873394,ea59567723c4892f202596efeeaaaa6aafb72808,ffa059b262ba72571e7fefe7fa2b4ebb6776b277 b9ec913212e6e91efa5a0a612c4a8ec4cf5da896,"Merge tag 'for-6.7/io_uring-sockopt-2023-10-30' of git://git.kernel.dk/linux + +Pull io_uring {get","set}sockopt support from Jens Axboe: + ""This adds support for using getsockopt and setsockopt via io_uring. + + The main use cases for this is to enable use of direct descriptors","['\n rather than first instantiating a normal file descriptor', ' doing the\n option tweaking needed', ' then turning it into a direct descriptor. With\n this support', ' we can avoid needing a regular file descriptor\n completely.\n\n The net and bpf bits have been signed off on their side""\n\n* tag \'for-6.7/io_uring-sockopt-2023-10-30\' of git://git.kernel.dk/linux:\n selftests/bpf/sockopt: Add io_uring support\n io_uring/cmd: Introduce SOCKET_URING_OP_SETSOCKOPT\n io_uring/cmd: Introduce SOCKET_URING_OP_GETSOCKOPT\n io_uring/cmd: return -EOPNOTSUPP if net is disabled\n selftests/net: Extract uring helpers to be reusable\n tools headers: Grab copy of io_uring.h\n io_uring/cmd: Pass compat mode in issue_flags\n net/socket: Break down __sys_getsockopt\n net/socket: Break down __sys_setsockopt\n bpf: Add sockptr support for setsockopt\n bpf: Add sockptr support for getsockopt\n', '']",Merge io_uring getsockopt and setsockopt support for direct descriptors.,"io_uring, getsockopt, setsockopt",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a6bdc082ad1c91d389a6ba0c7a1945818f732114,a6bdc082ad1c91d389a6ba0c7a1945818f732114,Huacai Chen,chenhuacai@loongson.cn,1698807300,Huacai Chen,chenhuacai@loongson.cn,1698807300,fa630701d5d2a8bc1ab8c4abf759663bbb81aeeb,ffc253263a1375a65fa6c9f62a893e9767fbebfa 99c9991f4e5d77328187187d0c921a3b62bfa998,"Merge 'bpf-next 2023-10-16' into loongarch-next + +LoongArch architecture changes for 6.7 (BPF CPU v4 support) depend on +the bpf changes to fix conflictions in selftests and work"," so merge them +to create a base. +",[''],Merge LoongArch architecture changes with bpf-next tree for conflict resolution in selftests.,"Merge, LoongArch, selftests",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +89ed67ef126c4160349c1b96fdb775ea6170ac90,89ed67ef126c4160349c1b96fdb775ea6170ac90,Linus Torvalds,torvalds@linux-foundation.org,1698765011,Linus Torvalds,torvalds@linux-foundation.org,1698765011,98caaf8bba44b21f9345a0af1dd2bd9987764e27,5a6a09e97199d6600d31383055f9d43fbbcbe86f f1c73396133cb3d913e2075298005644ee8dfade,"Merge tag 'net-next-6.7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next + +Pull networking updates from Jakub Kicinski: + ""Core & protocols: + + - Support usec resolution of TCP timestamps"," enabled selectively by a + route attribute. + + - Defer regular TCP ACK while processing socket backlog","[' try to send\n a cumulative ACK at the end. Increase single TCP flow performance\n on a 200Gbit NIC by 20% (100Gbit -> 120Gbit).\n\n - The Fair Queuing (FQ) packet scheduler:\n - add built-in 3 band prio / WRR scheduling\n - support bypass if the qdisc is mostly idle (5% speed up for TCP RR)\n - improve inactive flow reporting\n - optimize the layout of structures for better cache locality\n\n - Support TCP Authentication Option (RFC 5925', ' TCP-AO)', ' a more modern\n replacement for the old MD5 option.\n\n - Add more retransmission timeout (RTO) related statistics to\n TCP_INFO.\n\n - Support sending fragmented skbs over vsock sockets.\n\n - Make sure we send SIGPIPE for vsock sockets if socket was\n shutdown().\n\n - Add sysctl for ignoring lower limit on lifetime in Router\n Advertisement PIO', ' based on an in-progress IETF draft.\n\n - Add sysctl to control activation of TCP ping-pong mode.\n\n - Add sysctl to make connection timeout in MPTCP configurable.\n\n - Support rcvlowat and notsent_lowat on MPTCP sockets', ' to help apps\n limit the number of wakeups.\n\n - Support netlink GET for MDB (multicast forwarding)', ' allowing user\n space to request a single MDB entry instead of dumping the entire\n table.\n\n - Support selective FDB flushing in the VXLAN tunnel driver.\n\n - Allow limiting learned FDB entries in bridges', ' prevent OOM attacks.\n\n - Allow controlling via configfs netconsole targets which were\n created via the kernel cmdline at boot', ' rather than via configfs at\n runtime.\n\n - Support multiple PTP timestamp event queue readers with different\n filters.\n\n - MCTP over I3C.\n\n BPF:\n\n - Add new veth-like netdevice where BPF program defines the logic of\n the xmit routine. It can operate in L3 and L2 mode.\n\n - Support exceptions - allow asserting conditions which should never\n be true but are hard for the verifier to infer. With some extra\n flexibility around handling of the exit / failure:\n\n https://lwn.net/Articles/938435/\n\n - Add support for local per-cpu kptr', ' allow allocating and storing\n per-cpu objects in maps. Access to those objects operates on the\n value for the current CPU.\n\n This allows to deprecate local one-off implementations of per-CPU\n storage like BPF_MAP_TYPE_PERCPU_CGROUP_STORAGE maps.\n\n - Extend cgroup BPF sockaddr hooks for UNIX sockets. The use case is\n for systemd to re-implement the LogNamespace feature which allows\n running multiple instances of systemd-journald to process the logs\n of different services.\n\n - Enable open-coded task_vma iteration', ' after maple tree conversion\n made it hard to directly walk VMAs in tracing programs.\n\n - Add open-coded task', ' css_task and css iterator support. One of the\n use cases is customizable OOM victim selection via BPF.\n\n - Allow source address selection with bpf_*_fib_lookup().\n\n - Add ability to pin BPF timer to the current CPU.\n\n - Prevent creation of infinite loops by combining tail calls and\n fentry/fexit programs.\n\n - Add missed stats for kprobes to retrieve the number of missed\n kprobe executions and subsequent executions of BPF programs.\n\n - Inherit system settings for CPU security mitigations.\n\n - Add BPF v4 CPU instruction support for arm32 and s390x.\n\n Changes to common code:\n\n - overflow: add DEFINE_FLEX() for on-stack definition of structs with\n flexible array members.\n\n - Process doc update with more guidance for reviewers.\n\n Driver API:\n\n - Simplify locking in WiFi (cfg80211 and mac80211 layers)', ' use wiphy\n mutex in most places and remove a lot of smaller locks.\n\n - Create a common DPLL configuration API. Allow configuring and\n querying state of PLL circuits used for clock syntonization', ' in\n network time distribution.\n\n - Unify fragmented and full page allocation APIs in page pool code.\n Let drivers be ignorant of PAGE_SIZE.\n\n - Rework PHY state machine to avoid races with calls to phy_stop().\n\n - Notify DSA drivers of MAC address changes on user ports', ' improve\n correctness of offloads which depend on matching port MAC\n addresses.\n\n - Allow antenna control on injected WiFi frames.\n\n - Reduce the number of variants of napi_schedule().\n\n - Simplify error handling when composing devlink health messages.\n\n Misc:\n\n - A lot of KCSAN data race ""fixes""', ' from Eric.\n\n - A lot of __counted_by() annotations', ' from Kees.\n\n - A lot of strncpy -> strscpy and printf format fixes.\n\n - Replace master/slave terminology with conduit/user in DSA drivers.\n\n - Handful of KUnit tests for netdev and WiFi core.\n\n Removed:\n\n - AppleTalk COPS.\n\n - AppleTalk ipddp.\n\n - TI AR7 CPMAC Ethernet driver.\n\n Drivers:\n\n - Ethernet high-speed NICs:\n - Intel (100G', ' ice', ' idpf):\n - add a driver for the Intel E2000 IPUs\n - make CRC/FCS stripping configurable\n - cross-timestamping for E823 devices\n - basic support for E830 devices\n - use aux-bus for managing client drivers\n - i40e: report firmware versions via devlink\n - nVidia/Mellanox:\n - support 4-port NICs\n - increase max number of channels to 256\n - optimize / parallelize SF creation flow\n - Broadcom (bnxt):\n - enhance NIC temperature reporting\n - support PAM4 speeds and lane configuration\n - Marvell OcteonTX2:\n - PTP pulse-per-second output support\n - enable hardware timestamping for VFs\n - Solarflare/AMD:\n - conntrack NAT offload and offload for tunnels\n - Wangxun (ngbe/txgbe):\n - expose HW statistics\n - Pensando/AMD:\n - support PCI level reset\n - narrow down the condition under which skbs are linearized\n - Netronome/Corigine (nfp):\n - support CHACHA20-POLY1305 crypto in IPsec offload\n\n - Ethernet NICs embedded', ' slower', ' virtual:\n - Synopsys (stmmac):\n - add Loongson-1 SoC support\n - enable use of HW queues with no offload capabilities\n - enable PPS input support on all 5 channels\n - increase TX coalesce timer to 5ms\n - RealTek USB (r8152): improve efficiency of Rx by using GRO frags\n - xen: support SW packet timestamping\n - add drivers for implementations based on TI\'s PRUSS (AM64x EVM)\n\n - nVidia/Mellanox Ethernet datacenter switches:\n - avoid poor HW resource use on Spectrum-4 by better block\n selection for IPv6 multicast forwarding and ordering of blocks\n in ACL region\n\n - Ethernet embedded switches:\n - Microchip:\n - support configuring the drive strength for EMI compliance\n - ksz9477: partial ACL support\n - ksz9477: HSR offload\n - ksz9477: Wake on LAN\n - Realtek:\n - rtl8366rb: respect device tree config of the CPU port\n\n - Ethernet PHYs:\n - support Broadcom BCM5221 PHYs\n - TI dp83867: support hardware LED blinking\n\n - CAN:\n - add support for Linux-PHY based CAN transceivers\n - at91_can: clean up and use rx-offload helpers\n\n - WiFi:\n - MediaTek (mt76):\n - new sub-driver for mt7925 USB/PCIe devices\n - HW wireless <> Ethernet bridging in MT7988 chips\n - mt7603/mt7628 stability improvements\n - Qualcomm (ath12k):\n - WCN7850:\n - enable 320 MHz channels in 6 GHz band\n - hardware rfkill support\n - enable IEEE80211_HW_SINGLE_SCAN_ON_ALL_BANDS to\n make scan faster\n - read board data variant name from SMBIOS\n - QCN9274: mesh support\n - RealTek (rtw89):\n - TDMA-based multi-channel concurrency (MCC)\n - Silicon Labs (wfx):\n - Remain-On-Channel (ROC) support\n\n - Bluetooth:\n - ISO: many improvements for broadcast support\n - mark BCM4378/BCM4387 as BROKEN_LE_CODED\n - add support for QCA2066\n - btmtksdio: enable Bluetooth wakeup from suspend""\n\n* tag \'net-next-6.7\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next: (1816 commits)\n net: pcs: xpcs: Add 2500BASE-X case in get state for XPCS drivers\n net: bpf: Use sockopt_lock_sock() in ip_sock_set_tos()\n net: mana: Use xdp_set_features_flag instead of direct assignment\n vxlan: Cleanup IFLA_VXLAN_PORT_RANGE entry in vxlan_get_size()\n iavf: delete the iavf client interface\n iavf: add a common function for undoing the interrupt scheme\n iavf: use unregister_netdev\n iavf: rely on netdev\'s own registered state\n iavf: fix the waiting time for initial reset\n iavf: in iavf_down', ' don\'t queue watchdog_task if comms failed\n iavf: simplify mutex_trylock+sleep loops\n iavf: fix comments about old bit locks\n doc/netlink: Update schema to support cmd-cnt-name and cmd-max-name\n tools: ynl: introduce option to process unknown attributes or types\n ipvlan: properly track tx_errors\n netdevsim: Block until all devices are released\n nfp: using napi_build_skb() to replace build_skb()\n net: dsa: microchip: ksz9477: Fix spelling mistake ""Enery"" -> ""Energy""\n net: dsa: microchip: Ensure Stable PME Pin State for Wake-on-LAN\n net: dsa: microchip: Refactor switch shutdown routine for WoL preparation\n ...\n', '']",Merge networking updates including TCP timestamp resolution enhancements.,"networking,TCP,updates",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,['socket like programs'] +14ab6d425e80674b6a0145f05719b11e82e64824,14ab6d425e80674b6a0145f05719b11e82e64824,Linus Torvalds,torvalds@linux-foundation.org,1698695233,Linus Torvalds,torvalds@linux-foundation.org,1698695233,77384bc0eb40848f3df30f0d6f9d05e2d9c68627,7352a6765cf5d95888b3952ac89efbb817b4c3cf 12cd44023651666bd44baa36a5c999698890debb,"Merge tag 'vfs-6.7.ctime' of gitolite.kernel.org:pub/scm/linux/kernel/git/vfs/vfs + +Pull vfs inode time accessor updates from Christian Brauner: + ""This finishes the conversion of all inode time fields to accessor + functions as discussed on list. Changing timestamps manually as we + used to do before is error prone. Using accessors function makes this + robust. + + It does not contain the switch of the time fields to discrete 64 bit + integers to replace struct timespec and free up space in struct inode. + But after this"," the switch can be trivially made and the patch should + only affect the vfs if we decide to do it"" + +* tag 'vfs-6.7.ctime' of gitolite.kernel.org:pub/scm/linux/kernel/git/vfs/vfs: (86 commits) + fs: rename inode i_atime and i_mtime fields + security: convert to new timestamp accessors + selinux: convert to new timestamp accessors + apparmor: convert to new timestamp accessors + sunrpc: convert to new timestamp accessors + mm: convert to new timestamp accessors + bpf: convert to new timestamp accessors + ipc: convert to new timestamp accessors + linux: convert to new timestamp accessors + zonefs: convert to new timestamp accessors + xfs: convert to new timestamp accessors + vboxsf: convert to new timestamp accessors + ufs: convert to new timestamp accessors + udf: convert to new timestamp accessors + ubifs: convert to new timestamp accessors + tracefs: convert to new timestamp accessors + sysv: convert to new timestamp accessors + squashfs: convert to new timestamp accessors + server: convert to new timestamp accessors + client: convert to new timestamp accessors + ... +",[''],"This merge updates inode time fields to use accessor functions, enhancing robustness and reducing errors.","inode,timestamp,accessors",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1768d3a0144c7aae55b9cee66dabf94946eec01e,1768d3a0144c7aae55b9cee66dabf94946eec01e,Arnaldo Carvalho de Melo,acme@kernel.org,1698416327,Namhyung Kim,namhyung@kernel.org,1698460053,7f5cda791e29d327821e3462fed1a9d391a3d632,ee40490dd7cdcda38ece6d081f63ecddd3fdbe25,"perf build: Disable BPF skeletons if clang version is < 12.0.1 + +While building on a wide range of distros and clang versions it was +noticed that at least version 12.0.1 (noticed on Alpine 3.15 with +""Alpine clang version 12.0.1"") is needed to not fail with BTF generation +errors such as: + +Debian:10 + + Debian clang version 11.0.1-2~deb10u1: + + CLANG /tmp/build/perf/util/bpf_skel/.tmp/sample_filter.bpf.o + + GENSKEL /tmp/build/perf/util/bpf_skel/sample_filter.skel.h + libbpf: failed to find BTF for extern 'bpf_cast_to_kern_ctx' [21] section: -2 + Error: failed to open BPF object file: No such file or directory + make[2]: *** [Makefile.perf:1121: /tmp/build/perf/util/bpf_skel/sample_filter.skel.h] Error 254 + make[2]: *** Deleting file '/tmp/build/perf/util/bpf_skel/sample_filter.skel.h' + +Amazon Linux 2: + + clang version 11.1.0 (Amazon Linux 2 11.1.0-1.amzn2.0.2) + + GENSKEL /tmp/build/perf/util/bpf_skel/sample_filter.skel.h + libbpf: elf: skipping unrecognized data section(18) .eh_frame + libbpf: elf: skipping relo section(19) .rel.eh_frame for section(18) .eh_frame + libbpf: failed to find BTF for extern 'bpf_cast_to_kern_ctx' [21] section: -2 + Error: failed to open BPF object file: No such file or directory + make[2]: *** [/tmp/build/perf/util/bpf_skel/sample_filter.skel.h] Error 254 + make[2]: *** Deleting file `/tmp/build/perf/util/bpf_skel/sample_filter.skel.h' + +Ubuntu 20.04: + + clang version 10.0.0-4ubuntu1 + + CLANG /tmp/build/perf/util/bpf_skel/.tmp/augmented_raw_syscalls.bpf.o + GENSKEL /tmp/build/perf/util/bpf_skel/bench_uprobe.skel.h + GENSKEL /tmp/build/perf/util/bpf_skel/bperf_leader.skel.h + libbpf: sec '.reluprobe': corrupted symbol #27 pointing to invalid section #65522 for relo #0 + GENSKEL /tmp/build/perf/util/bpf_skel/bperf_follower.skel.h + Error: failed to open BPF object file: BPF object format invalid + make[2]: *** [Makefile.perf:1121: /tmp/build/perf/util/bpf_skel/bench_uprobe.skel.h] Error 95 + make[2]: *** Deleting file '/tmp/build/perf/util/bpf_skel/bench_uprobe.skel.h' + +So check if the version is at least 12.0.1 otherwise disable building +BPF skels and provide a message about it"," continuing the build. + +The message","[' when running on amazonlinux:2:\n\n Makefile.config:698: Warning: Disabled BPF skeletons as reliable BTF generation needs at least clang version 12.0.1\n\nSigned-off-by: Arnaldo Carvalho de Melo \nReviewed-by: Ian Rogers \nLink: https://lore.kernel.org/r/ZTvGx/Ou6BVnYBqi@kernel.org\nSigned-off-by: Namhyung Kim \n', '']",Disable building BPF skeletons in perf if using a clang version older than 12.0.1 to avoid BTF generation errors.,"BPF skeletons, clang version, BTF errors",It's a build system or CI/CD change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"[""It's not related to any of the above.""]" +06497763c8f15d08c0e356e651a61f2930a8987c,06497763c8f15d08c0e356e651a61f2930a8987c,Yonghong Song,yonghong.song@linux.dev,1698431064,Jakub Kicinski,kuba@kernel.org,1698446488,99b59e9c88460e2d61a4ef42a6feac4f37943c4b,f5247a6ed5b5bbaa609f97049de868974eb7a7c2,"net: bpf: Use sockopt_lock_sock() in ip_sock_set_tos() + +With latest sync from net-next tree"," bpf-next has a bpf selftest failure: + [root@arch-fb-vm1 bpf]# ./test_progs -t setget_sockopt + ... + [ 76.194349] ============================================ + [ 76.194682] WARNING: possible recursive locking detected + [ 76.195039] 6.6.0-rc7-g37884503df08-dirty #67 Tainted: G W OE + [ 76.195518] -------------------------------------------- + [ 76.195852] new_name/154 is trying to acquire lock: + [ 76.196159] ffff8c3e06ad8d30 (sk_lock-AF_INET){+.+.}-{0:0}","[' at: ip_sock_set_tos+0x19/0x30\n [ 76.196669]\n [ 76.196669] but task is already holding lock:\n [ 76.197028] ffff8c3e06ad8d30 (sk_lock-AF_INET){+.+.}-{0:0}', ' at: inet_listen+0x21/0x70\n [ 76.197517]\n [ 76.197517] other info that might help us debug this:\n [ 76.197919] Possible unsafe locking scenario:\n [ 76.197919]\n [ 76.198287] CPU0\n [ 76.198444] ----\n [ 76.198600] lock(sk_lock-AF_INET);\n [ 76.198831] lock(sk_lock-AF_INET);\n [ 76.199062]\n [ 76.199062] *** DEADLOCK ***\n [ 76.199062]\n [ 76.199420] May be due to missing lock nesting notation\n [ 76.199420]\n [ 76.199879] 2 locks held by new_name/154:\n [ 76.200131] #0: ffff8c3e06ad8d30 (sk_lock-AF_INET){+.+.}-{0:0}', ' at: inet_listen+0x21/0x70\n [ 76.200644] #1: ffffffff90f96a40 (rcu_read_lock){....}-{1:2}', ' at: __cgroup_bpf_run_filter_sock_ops+0x55/0x290\n [ 76.201268]\n [ 76.201268] stack backtrace:\n [ 76.201538] CPU: 4 PID: 154 Comm: new_name Tainted: G W OE 6.6.0-rc7-g37884503df08-dirty #67\n [ 76.202134] Hardware name: QEMU Standard PC (i440FX + PIIX', ' 1996)', ' BIOS 1.13.0-1ubuntu1.1 04/01/2014\n [ 76.202699] Call Trace:\n [ 76.202858] \n [ 76.203002] dump_stack_lvl+0x4b/0x80\n [ 76.203239] __lock_acquire+0x740/0x1ec0\n [ 76.203503] lock_acquire+0xc1/0x2a0\n [ 76.203766] ? ip_sock_set_tos+0x19/0x30\n [ 76.204050] ? sk_stream_write_space+0x12a/0x230\n [ 76.204389] ? lock_release+0xbe/0x260\n [ 76.204661] lock_sock_nested+0x32/0x80\n [ 76.204942] ? ip_sock_set_tos+0x19/0x30\n [ 76.205208] ip_sock_set_tos+0x19/0x30\n [ 76.205452] do_ip_setsockopt+0x4b3/0x1580\n [ 76.205719] __bpf_setsockopt+0x62/0xa0\n [ 76.205963] bpf_sock_ops_setsockopt+0x11/0x20\n [ 76.206247] bpf_prog_630217292049c96e_bpf_test_sockopt_int+0xbc/0x123\n [ 76.206660] bpf_prog_493685a3bae00bbd_bpf_test_ip_sockopt+0x49/0x4b\n [ 76.207055] bpf_prog_b0bcd27f269aeea0_skops_sockopt+0x44c/0xec7\n [ 76.207437] __cgroup_bpf_run_filter_sock_ops+0xda/0x290\n [ 76.207829] __inet_listen_sk+0x108/0x1b0\n [ 76.208122] inet_listen+0x48/0x70\n [ 76.208373] __sys_listen+0x74/0xb0\n [ 76.208630] __x64_sys_listen+0x16/0x20\n [ 76.208911] do_syscall_64+0x3f/0x90\n [ 76.209174] entry_SYSCALL_64_after_hwframe+0x6e/0xd8\n ...\n\nBoth ip_sock_set_tos() and inet_listen() calls lock_sock(sk) which\ncaused a dead lock.\n\nTo fix the issue', ' use sockopt_lock_sock() in ip_sock_set_tos()\ninstead. sockopt_lock_sock() will avoid lock_sock() if it is in bpf\ncontext.\n\nFixes: 878d951c6712 (""inet: lock the socket in ip_sock_set_tos()"")\nSuggested-by: Martin KaFai Lau \nSigned-off-by: Yonghong Song \nReviewed-by: Eric Dumazet \nLink: https://lore.kernel.org/r/20231027182424.1444845-1-yonghong.song@linux.dev\nSigned-off-by: Jakub Kicinski \n', '']",The commit updates the net bpf code to use sockopt_lock_sock in ip_sock_set_tos to avoid recursive locking issues.,"sockopt_lock_sock, ip_sock_set_tos, recursive locking",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['socket like programs', 'other']" +c6f9b7138bf5c6b826175c9e0ad5f5dbfff4fa36,c6f9b7138bf5c6b826175c9e0ad5f5dbfff4fa36,Jakub Kicinski,kuba@kernel.org,1698375760,Jakub Kicinski,kuba@kernel.org,1698375761,c7bf02f5524d49f829258fbda2cedab62e25efbd,cc33a80b816406f900a53c7f98a50f6eacdd2e31 ea41b880cc85f0a992571f66e4554a69f7806246,"Merge tag 'for-netdev' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-10-26 + +We've added 51 non-merge commits during the last 10 day(s) which contain +a total of 75 files changed", 5037 insertions(+),"[' 200 deletions(-).\n\nThe main changes are:\n\n1) Add open-coded task', ' css_task and css iterator support.\n One of the use cases is customizable OOM victim selection via BPF', ""\n from Chuyi Zhou.\n\n2) Fix BPF verifier's iterator convergence logic to use exact states\n comparison for convergence checks"", ' from Eduard Zingerman', '\n Andrii Nakryiko and Alexei Starovoitov.\n\n3) Add BPF programmable net device where bpf_mprog defines the logic\n of its xmit routine. It can operate in L3 and L2 mode', '\n from Daniel Borkmann and Nikolay Aleksandrov.\n\n4) Batch of fixes for BPF per-CPU kptr and re-enable unit_size checking\n for global per-CPU allocator', ' from Hou Tao.\n\n5) Fix libbpf which eagerly assumed that SHT_GNU_verdef ELF section\n was going to be present whenever a binary has SHT_GNU_versym section', '\n from Andrii Nakryiko.\n\n6) Fix BPF ringbuf correctness to fold smp_mb__before_atomic() into\n atomic_set_release()', ' from Paul E. McKenney.\n\n7) Add a warning if NAPI callback missed xdp_do_flush() under\n CONFIG_DEBUG_NET which helps checking if drivers were missing\n the former', ' from Sebastian Andrzej Siewior.\n\n8) Fix missed RCU read-lock in bpf_task_under_cgroup() which was throwing\n a warning under sleepable programs', ' from Yafang Shao.\n\n9) Avoid unnecessary -EBUSY from htab_lock_bucket by disabling IRQ before\n checking map_locked', ' from Song Liu.\n\n10) Make BPF CI linked_list failure test more robust', '\n from Kumar Kartikeya Dwivedi.\n\n11) Enable samples/bpf to be built as PIE in Fedora', ' from Viktor Malik.\n\n12) Fix xsk starving when multiple xsk sockets were associated with\n a single xsk_buff_pool', ' from Albert Huang.\n\n13) Clarify the signed modulo implementation for the BPF ISA standardization\n document that it uses truncated division', "" from Dave Thaler.\n\n14) Improve BPF verifier's JEQ/JNE branch taken logic to also consider\n signed bounds knowledge"", ' from Andrii Nakryiko.\n\n15) Add an option to XDP selftests to use multi-buffer AF_XDP\n xdp_hw_metadata and mark used XDP programs as capable to use frags', ""\n from Larysa Zaremba.\n\n16) Fix bpftool's BTF dumper wrt printing a pointer value and another\n one to fix struct_ops dump in an array"", "" from Manu Bretelle.\n\n* tag 'for-netdev' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (51 commits)\n netkit: Remove explicit active/peer ptr initialization\n selftests/bpf: Fix selftests broken by mitigations=off\n samples/bpf: Allow building with custom bpftool\n samples/bpf: Fix passing LDFLAGS to libbpf\n samples/bpf: Allow building with custom CFLAGS/LDFLAGS\n bpf: Add more WARN_ON_ONCE checks for mismatched alloc and free\n selftests/bpf: Add selftests for netkit\n selftests/bpf: Add netlink helper library\n bpftool: Extend net dump with netkit progs\n bpftool: Implement link show support for netkit\n libbpf: Add link-based API for netkit\n tools: Sync if_link uapi header\n netkit"", ' bpf: Add bpf programmable net device\n bpf: Improve JEQ/JNE branch taken logic\n bpf: Fold smp_mb__before_atomic() into atomic_set_release()\n bpf: Fix unnecessary -EBUSY from htab_lock_bucket\n xsk: Avoid starving the xsk further down the list\n bpf: print full verifier states on infinite loop detection\n selftests/bpf: test if state loops are detected in a tricky case\n bpf: correct loop detection for iterators convergence\n ...\n====================\n\nLink: https://lore.kernel.org/r/20231026150509.2824-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merge commit integrating 51 non-merge commits from bpf-next branch.,"merge, bpf-next, commits",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ea41b880cc85f0a992571f66e4554a69f7806246,ea41b880cc85f0a992571f66e4554a69f7806246,Nikolay Aleksandrov,razor@blackwall.org,1698313265,Daniel Borkmann,daniel@iogearbox.net,1698328719,4da532cc1563b5b01e1b792438edcd0cbc7301d8,399f6185a1c02f39bcadb8749bc2d9d48685816f,"netkit: Remove explicit active/peer ptr initialization + +Remove the explicit NULLing of active/peer pointers and rely on the +implicit one done at net device allocation. + +Suggested-by: Jiri Pirko +Signed-off-by: Nikolay Aleksandrov +Signed-off-by: Daniel Borkmann +Reviewed-by: Jiri Pirko +Acked-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231026094106.1505892-2-razor@blackwall.org +",,The commit removes explicit pointer initialization and relies on implicit initialization during net device allocation.,"pointer initialization, net device, implicit nulling",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +399f6185a1c02f39bcadb8749bc2d9d48685816f,399f6185a1c02f39bcadb8749bc2d9d48685816f,Yafang Shao,laoar.shao@gmail.com,1698203504,Daniel Borkmann,daniel@iogearbox.net,1698327723,8e0f5a2c26af71dadb9713ce7cf2c65d8da398fb,37db10bc247d5d0b448babd7ff386f092246e732,"selftests/bpf: Fix selftests broken by mitigations=off + +When we configure the kernel command line with 'mitigations=off' and set +the sysctl knob 'kernel.unprivileged_bpf_disabled' to 0"," the commit +bc5bc309db45 (""bpf: Inherit system settings for CPU security mitigations"") +causes issues in the execution of `test_progs -t verifier`. This is +because 'mitigations=off' bypasses Spectre v1 and Spectre v4 protections. + +Currently","[' when a program requests to run in unprivileged mode\n(kernel.unprivileged_bpf_disabled = 0)', "" the BPF verifier may prevent\nit from running due to the following conditions not being enabled:\n\n - bypass_spec_v1\n - bypass_spec_v4\n - allow_ptr_leaks\n - allow_uninit_stack\n\nWhile 'mitigations=off' enables the first two conditions"", ' it does not\nenable the latter two. As a result', "" some test cases in\n'test_progs -t verifier' that were expected to fail to run may run\nsuccessfully"", ' while others still fail but with different error messages.\nThis makes it challenging to address them comprehensively.\n\nMoreover', ' in the future', ' we may introduce more fine-grained control over\nCPU mitigations', ' such as enabling only bypass_spec_v1 or bypass_spec_v4.\n\nGiven the complexity of the situation', ' rather than fixing each broken test\ncase individually', "" it's preferable to skip them when 'mitigations=off' is\nin effect and introduce specific test cases for the new 'mitigations=off'\nscenario. For instance"", "" we can introduce new BTF declaration tags like\n'__failure__nospec'"", "" '__failure_nospecv1' and '__failure_nospecv4'.\n\nIn this patch"", "" the approach is to simply skip the broken test cases when\n'mitigations=off' is enabled. The result of `test_progs -t verifier` as\nfollows after this commit"", ""\n\nBefore this commit\n==================\n\n- without 'mitigations=off'\n - kernel.unprivileged_bpf_disabled = 2\n Summary: 74/948 PASSED"", ' 388 SKIPPED', ' 0 FAILED\n - kernel.unprivileged_bpf_disabled = 0\n Summary: 74/1336 PASSED', ' 0 SKIPPED', "" 0 FAILED <<<<\n- with 'mitigations=off'\n - kernel.unprivileged_bpf_disabled = 2\n Summary: 74/948 PASSED"", ' 388 SKIPPED', ' 0 FAILED\n - kernel.unprivileged_bpf_disabled = 0\n Summary: 63/1276 PASSED', ' 0 SKIPPED', "" 11 FAILED <<<< 11 FAILED\n\nAfter this commit\n=================\n\n- without 'mitigations=off'\n - kernel.unprivileged_bpf_disabled = 2\n Summary: 74/948 PASSED"", ' 388 SKIPPED', ' 0 FAILED\n - kernel.unprivileged_bpf_disabled = 0\n Summary: 74/1336 PASSED', ' 0 SKIPPED', ' 0 FAILED <<<<\n- with this patch', "" with 'mitigations=off'\n - kernel.unprivileged_bpf_disabled = 2\n Summary: 74/948 PASSED"", ' 388 SKIPPED', ' 0 FAILED\n - kernel.unprivileged_bpf_disabled = 0\n Summary: 74/948 PASSED', ' 388 SKIPPED', ' 0 FAILED <<<< SKIPPED\n\nFixes: bc5bc309db45 (""bpf: Inherit system settings for CPU security mitigations"")\nReported-by: Alexei Starovoitov \nSigned-off-by: Yafang Shao \nSigned-off-by: Daniel Borkmann \nAcked-by: Yonghong Song \nCloses: https://lore.kernel.org/bpf/CAADnVQKUBJqg+hHtbLeeC2jhoJAWqnmRAzXW3hmUCNSV9kx4sQ@mail.gmail.com\nLink: https://lore.kernel.org/bpf/20231025031144.5508-1-laoar.shao@gmail.com\n', '']",Fixes broken eBPF selftests when kernel configured with 'mitigations=off' affecting test execution.,"selftests, mitigations, verifier",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +37db10bc247d5d0b448babd7ff386f092246e732,37db10bc247d5d0b448babd7ff386f092246e732,Viktor Malik,vmalik@redhat.com,1698214754,Daniel Borkmann,daniel@iogearbox.net,1698327133,571972ac5c029ce9bc18352630b1de1084a751a0,f56bcfadf7d6d56b099726df4fc262b76486b0e0,"samples/bpf: Allow building with custom bpftool + +samples/bpf build its own bpftool boostrap to generate vmlinux.h as well +as some BPF objects. This is a redundant step if bpftool has been +already built"," so update samples/bpf/Makefile such that it accepts a +path to bpftool passed via the BPFTOOL variable. The approach is +practically the same as tools/testing/selftests/bpf/Makefile uses. + +Signed-off-by: Viktor Malik +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/bd746954ac271b02468d8d951ff9f11e655d485b.1698213811.git.vmalik@redhat.com +",[''],This commit allows samples/bpf to build with a custom bpftool by modifying the Makefile.,"samples,bpf,Makefile",It's a build system or CI/CD change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"[""It's not related to any of the above.""]" +f56bcfadf7d6d56b099726df4fc262b76486b0e0,f56bcfadf7d6d56b099726df4fc262b76486b0e0,Viktor Malik,vmalik@redhat.com,1698214753,Daniel Borkmann,daniel@iogearbox.net,1698327133,98811e1bdf503a94fcb7ec28ef1ce5e3736bc6e0,870f09f1ba3014e2c157b14299c172b4bb716638,"samples/bpf: Fix passing LDFLAGS to libbpf + +samples/bpf/Makefile passes LDFLAGS=$(TPROGS_LDFLAGS) to libbpf build +without surrounding quotes"," which may cause compilation errors when +passing custom TPROGS_USER_LDFLAGS. + +For example: + + $ make -C samples/bpf/ TPROGS_USER_LDFLAGS=""-Wl","['--as-needed -specs=/usr/lib/gcc/x86_64-redhat-linux/13/libsanitizer.spec""\n make: Entering directory \'./samples/bpf\'\n make -C ../../ M=./samples/bpf BPF_SAMPLES_PATH=./samples/bpf\n make[1]: Entering directory \'.\'\n make -C ./samples/bpf/../../tools/lib/bpf RM=\'rm -rf\' EXTRA_CFLAGS=""-Wall -O2 -Wmissing-prototypes -Wstrict-prototypes -I./usr/include -I./tools/testing/selftests/bpf/ -I./samples/bpf/libbpf/include -I./tools/include -I./tools/perf -I./tools/lib -DHAVE_ATTR_TEST=0"" \\\n LDFLAGS=-Wl', ""--as-needed -specs=/usr/lib/gcc/x86_64-redhat-linux/13/libsanitizer.spec srctree=./samples/bpf/../../ \\\n O= OUTPUT=./samples/bpf/libbpf/ DESTDIR=./samples/bpf/libbpf prefix= \\\n ./samples/bpf/libbpf/libbpf.a install_headers\n make: invalid option -- 'c'\n make: invalid option -- '='\n make: invalid option -- '/'\n make: invalid option -- 'u'\n make: invalid option -- '/'\n [...]\n\nFix the error by properly quoting $(TPROGS_LDFLAGS).\n\nSuggested-by: Donald Zickus \nSigned-off-by: Viktor Malik \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/c690de6671cc6c983d32a566d33fd7eabd18b526.1698213811.git.vmalik@redhat.com\n"", '']",Fixes LDFLAGS passing issue in samples/bpf Makefile to prevent compilation errors.,"LDFLAGS, Makefile, compilation",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +870f09f1ba3014e2c157b14299c172b4bb716638,870f09f1ba3014e2c157b14299c172b4bb716638,Viktor Malik,vmalik@redhat.com,1698214752,Daniel Borkmann,daniel@iogearbox.net,1698327132,eccba13e343802ae0bef8d186d918062e1634396,c421c12586b3f00fb96b5c9af15c9a051a9090b1,"samples/bpf: Allow building with custom CFLAGS/LDFLAGS + +Currently"," it is not possible to specify custom flags when building +samples/bpf. The flags are defined in TPROGS_CFLAGS/TPROGS_LDFLAGS +variables","[' however', ' when trying to override those from the make command', '\ncompilation fails.\n\nFor example', ' when trying to build with PIE:\n\n $ make -C samples/bpf TPROGS_CFLAGS=""-fpie"" TPROGS_LDFLAGS=""-pie""\n\nThis is because samples/bpf/Makefile updates these variables', ' especially\nappends include paths to TPROGS_CFLAGS and these updates are overridden\nby setting the variables from the make command.\n\nThis patch introduces variables TPROGS_USER_CFLAGS/TPROGS_USER_LDFLAGS\nfor this purpose', ' which can be set from the make command and their\nvalues are propagated to TPROGS_CFLAGS/TPROGS_LDFLAGS.\n\nSigned-off-by: Viktor Malik \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/2d81100b830a71f0e72329cc7781edaefab75f62.1698213811.git.vmalik@redhat.com\n', '']",The commit allows building samples/bpf with custom CFLAGS/LDFLAGS.,custom CFLAGS LDFLAGS,It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +c421c12586b3f00fb96b5c9af15c9a051a9090b1,c421c12586b3f00fb96b5c9af15c9a051a9090b1,Hou Tao,houtao1@huawei.com,1697852999,Daniel Borkmann,daniel@iogearbox.net,1698323013,93527c11d4684d0c5dc602a575bd7dc90d2cf320,22360fad5889cbefe1eca695b0cc0273ab280b56,"bpf: Add more WARN_ON_ONCE checks for mismatched alloc and free + +There are two possible mismatched alloc and free cases in BPF memory +allocator: + +1) allocate from cache X but free by cache Y with a different unit_size +2) allocate from per-cpu cache but free by kmalloc cache or vice versa + +So add more WARN_ON_ONCE checks in free_bulk() and __free_by_rcu() to +spot these mismatched alloc and free early. + +Signed-off-by: Hou Tao +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/bpf/20231021014959.3563841-1-houtao@huaweicloud.com +",,Add checks to detect mismatched allocation and freeing in the BPF memory allocator.,memory allocator checks,It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e56808fef8f71a192b2740c0b6ea8be7ab865d54,e56808fef8f71a192b2740c0b6ea8be7ab865d54,Roman Gushchin,roman.gushchin@linux.dev,1697756026,Andrew Morton,akpm@linux-foundation.org,1698277631,e33f1ca3bd268eb5e707e0cb801aaf7cd3d4d02e,c63b835d0eafc956c43b8c6605708240ac52b8cd,"mm: kmem: reimplement get_obj_cgroup_from_current() + +Reimplement get_obj_cgroup_from_current() using current_obj_cgroup(). +get_obj_cgroup_from_current() and current_obj_cgroup() share 80% of the +code"," so the new implementation is almost trivial. + +get_obj_cgroup_from_current() is a convenient function used by the +bpf subsystem","[' so there is no reason to get rid of it completely.\n\nLink: https://lkml.kernel.org/r/20231019225346.1822282-7-roman.gushchin@linux.dev\nSigned-off-by: Roman Gushchin (Cruise) \nReviewed-by: Vlastimil Babka \nAcked-by: Shakeel Butt \nCc: David Rientjes \nCc: Dennis Zhou \nCc: Johannes Weiner \nCc: Michal Hocko \nCc: Muchun Song \nCc: Naresh Kamboju \nSigned-off-by: Andrew Morton \n', '']",Reimplemented get_obj_cgroup_from_current() using existing common code in current_obj_cgroup() to reduce redundancy.,"reimplement, obj_cgroup, bpf",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b5711042a1c8cc88ed40a5ebf612b36e83a4e2e4,b5711042a1c8cc88ed40a5ebf612b36e83a4e2e4,Namhyung Kim,namhyung@kernel.org,1697834861,Namhyung Kim,namhyung@kernel.org,1698253375,d2c57c3531da558d0d3c94ceee311c29e03f38e7,6a070573f290f99a6129ac3e13b9df521a1a65de,"perf lock contention: Use per-cpu array map for spinlocks + +Currently lock contention timestamp is maintained in a hash map keyed by +pid. That means it needs to get and release a map element (which is +proctected by spinlock!) on each contention begin and end pair. This +can impact on performance if there are a lot of contention (usually from +spinlocks). + +It used to go with task local storage but it had an issue on memory +allocation in some critical paths. Although it's addressed in recent +kernels IIUC"," the tool should support old kernels too. So it cannot +simply switch to the task local storage at least for now. + +As spinlocks create lots of contention and they disabled preemption +during the spinning","[' it can use per-cpu array to keep the timestamp to\navoid overhead in hashmap update and delete.\n\nIn contention_begin', "" it's easy to check the lock types since it can see\nthe flags. But contention_end cannot see it. So let's try to per-cpu\narray first (unconditionally) if it has an active element (lock != 0).\nThen it should be used and per-task tstamp map should not be used until\nthe per-cpu array element is cleared which means nested spinlock\ncontention (if any) was finished and it nows see (the outer) lock.\n\nSigned-off-by: Namhyung Kim \nAcked-by: Ian Rogers \nCc: Hao Luo \nCc: Song Liu \nCc: bpf@vger.kernel.org\nLink: https://lore.kernel.org/r/20231020204741.1869520-3-namhyung@kernel.org\n"", '']",Optimized lock contention handling by using per-cpu array map instead of hash map for spinlocks in perf tool.,"lock contention, spinlocks, per-cpu",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6a070573f290f99a6129ac3e13b9df521a1a65de,6a070573f290f99a6129ac3e13b9df521a1a65de,Namhyung Kim,namhyung@kernel.org,1697834860,Namhyung Kim,namhyung@kernel.org,1698253367,61889f17e90cc264f7645ecbdf1a5065622a68eb,d99317f214ca3d381f7b17a75c41263885664e06,"perf lock contention: Check race in tstamp elem creation + +When pelem is NULL"," it'd create a new entry with zero data. But it +might be preempted by IRQ/NMI just before calling bpf_map_update_elem() +then there's a chance to call it twice for the same pid. So it'd be +better to use BPF_NOEXIST flag and check the return value to prevent +the race. + +Signed-off-by: Namhyung Kim +Acked-by: Ian Rogers +Cc: Hao Luo +Cc: Song Liu +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231020204741.1869520-2-namhyung@kernel.org +",[''],Implement BPF_NOEXIST flag to prevent race conditions in perf lock contention element creation.,"race, BPF_NOEXIST, contention",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,['tracepoints like programs'] +d99317f214ca3d381f7b17a75c41263885664e06,d99317f214ca3d381f7b17a75c41263885664e06,Namhyung Kim,namhyung@kernel.org,1697834859,Namhyung Kim,namhyung@kernel.org,1698253354,3cbd12b10993be639766354b360519081709388e,e093a222d7cba1eb6c36887e58ce8a4ff249f1c6,"perf lock contention: Clear lock addr after use + +It checks the current lock to calculated the delta of contention time. +The address is saved in the tstamp map which is allocated at begining of +contention and released at end of contention. + +But it's possible for bpf_map_delete_elem() to fail. In that case"," the +element in the tstamp map kept for the current lock and it makes the +next contention for the same lock tracked incorrectly. Specificially +the next contention begin will see the existing element for the task and +it'd just return. Then the next contention end will see the element and +calculate the time using the timestamp for the previous begin. + +This can result in a large value for two small contentions happened from +time to time. Let's clear the lock address so that it can be updated +next time even if the bpf_map_delete_elem() failed. + +Signed-off-by: Namhyung Kim +Acked-by: Ian Rogers +Cc: Hao Luo +Cc: Song Liu +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231020204741.1869520-1-namhyung@kernel.org +",[''],Fix contention time tracking in perf lock by clearing lock address after use.,"perf,lock,contention",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +22360fad5889cbefe1eca695b0cc0273ab280b56,22360fad5889cbefe1eca695b0cc0273ab280b56,Martin KaFai Lau,martin.lau@kernel.org,1698188702,Martin KaFai Lau,martin.lau@kernel.org,1698188868,33ca776f10feda7e38956dc26edf74fd1bbc88da,42d31dd601fa43b9afdf069d1ba410b2306a4c76 ace15f91e569172dac71ae0aeb3a2e76d1ce1b17,"Merge branch 'Add bpf programmable net device' + +Daniel Borkmann says: + +==================== +This work adds a BPF programmable device which can operate in L3 or L2 +mode where the BPF program is part of the xmit routine. It's program +management is done via bpf_mprog and it comes with BPF link support. +For details see patch 1 and following. Thanks! + +v3 -> v4: + - Moved netkit_release_all() into ndo_uninit (Stan) + - Two small commit msg corrections (Toke) + - Added Acked/Reviewed-by +v2 -> v3: + - Remove setting dev->min_mtu to ETH_MIN_MTU (Andrew) + - Do not populate ethtool info->version (Andrew) + - Populate netdev private data before register_netdevice (Andrew) + - Use strscpy for ifname template (Jakub) + - Use GFP_KERNEL_ACCOUNT for link kzalloc (Jakub) + - Carry and dump link attach type for bpftool (Toke) +v1 -> v2: + - Rename from meta (Toke", Andrii,"[' Alexei)\n - Reuse skb_scrub_packet (Stan)\n - Remove IFF_META and use netdev_ops (Toke)\n - Add comment to multicast handler (Toke)\n - Remove silly version info (Toke)\n - Fix attach_type_name (Quentin)\n - Rework libbpf link attach api to be similar\n as tcx (Andrii)\n - Move flags last for bpf_netkit_opts (Andrii)\n - Rebased to bpf_mprog query api changes\n - Folded link support patch into main one\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",Added a BPF programmable net device with L2/L3 mode and BPF link support via bpf_mprog.,"BPF programmable, net device, bpf_mprog",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['xdp like programs', 'tracepoints like programs']" +ace15f91e569172dac71ae0aeb3a2e76d1ce1b17,ace15f91e569172dac71ae0aeb3a2e76d1ce1b17,Daniel Borkmann,daniel@iogearbox.net,1698184144,Martin KaFai Lau,martin.lau@kernel.org,1698188863,33ca776f10feda7e38956dc26edf74fd1bbc88da,51f1892b5289f0c09745d3bedb36493555d6d90c,"selftests/bpf: Add selftests for netkit + +Add a bigger batch of test coverage to assert correct operation of +netkit devices and their BPF program management: + + # ./test_progs -t tc_netkit + [...] + [ 1.166267] bpf_testmod: loading out-of-tree module taints kernel. + [ 1.166831] bpf_testmod: module verification failed: signature and/or required key missing - tainting kernel + [ 1.270957] tsc: Refined TSC clocksource calibration: 3407.988 MHz + [ 1.272579] clocksource: tsc: mask: 0xffffffffffffffff max_cycles: 0x311fc932722"," max_idle_ns: 440795381586 ns + [ 1.275336] clocksource: Switched to clocksource tsc + #257 tc_netkit_basic:OK + #258 tc_netkit_device:OK + #259 tc_netkit_multi_links:OK + #260 tc_netkit_multi_opts:OK + #261 tc_netkit_neigh_links:OK + Summary: 5/0 PASSED","[' 0 SKIPPED', ' 0 FAILED\n [...]\n\nSigned-off-by: Daniel Borkmann \nAcked-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20231024214904.29825-8-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']",Add selftests to ensure netkit devices and BPF program management function correctly.,"selftests, netkit, tc_netkit",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['tc/netfilter like programs'] +51f1892b5289f0c09745d3bedb36493555d6d90c,51f1892b5289f0c09745d3bedb36493555d6d90c,Daniel Borkmann,daniel@iogearbox.net,1698184143,Martin KaFai Lau,martin.lau@kernel.org,1698188859,57d2cc0251bbd51cbfbbeb1a234bcf34eb9c951e,bec981a4add6dd6a63065e54e2b2e67c2af6c3fa,"selftests/bpf: Add netlink helper library + +Add a minimal netlink helper library for the BPF selftests. This has been +taken and cut down and cleaned up from iproute2. This covers basics such +as netdevice creation which we need for BPF selftests / BPF CI given +iproute2 package cannot cover it yet. + +Stanislav Fomichev suggested that this could be replaced in future by ynl +tool generated C code once it has RTNL support to create devices. Once we +get to this point the BPF CI would also need to add libmnl. If no further +extensions are needed"," a second option could be that we remove this code +again once iproute2 package has support. + +Signed-off-by: Daniel Borkmann +Acked-by: Martin KaFai Lau +Link: https://lore.kernel.org/r/20231024214904.29825-7-daniel@iogearbox.net +Signed-off-by: Martin KaFai Lau +",[''],"This commit adds a minimal netlink helper library for BPF selftests, derived from iproute2, to support BPF CI.","netlink, helper library, selftests",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +bec981a4add6dd6a63065e54e2b2e67c2af6c3fa,bec981a4add6dd6a63065e54e2b2e67c2af6c3fa,Daniel Borkmann,daniel@iogearbox.net,1698184142,Martin KaFai Lau,martin.lau@kernel.org,1698188852,acd73a5086c3e112b9673d2ec175ee8a8441c6e5,92a85e18ad4705c66ace55a19f4f8301ef0eb59f,"bpftool: Extend net dump with netkit progs + +Add support to dump BPF programs on netkit via bpftool. This includes both +the BPF link and attach ops programs. Dumped information contain the attach +location", function entry name,"[' program ID and link ID when applicable.\n\nExample with tc BPF link:\n\n # ./bpftool net\n xdp:\n\n tc:\n nk1(22) netkit/peer tc1 prog_id 43 link_id 12\n\n [...]\n\nExample with json dump:\n\n # ./bpftool net --json | jq\n [\n {\n ""xdp"": []', '\n ""tc"": [\n {\n ""devname"": ""nk1""', '\n ""ifindex"": 18', '\n ""kind"": ""netkit/primary""', '\n ""name"": ""tc1""', '\n ""prog_id"": 29', '\n ""prog_flags"": []', '\n ""link_id"": 8', '\n ""link_flags"": []\n }\n ]', '\n ""flow_dissector"": []', '\n ""netfilter"": []\n }\n ]\n\nSigned-off-by: Daniel Borkmann \nReviewed-by: Quentin Monnet \nAcked-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20231024214904.29825-6-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']","Extend bpftool to support dumping BPF programs on netkit, including link and attach ops programs.","bpftool, netkit, dump",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +92a85e18ad4705c66ace55a19f4f8301ef0eb59f,92a85e18ad4705c66ace55a19f4f8301ef0eb59f,Daniel Borkmann,daniel@iogearbox.net,1698184141,Martin KaFai Lau,martin.lau@kernel.org,1698188844,6e30487e1da0904bf48de205ec3658e94be426ac,05c31b4ab20527c4d1695130aaecc54ef59a0e54,"bpftool: Implement link show support for netkit + +Add support to dump netkit link information to bpftool in similar way as +we have for XDP. The netkit link info only exposes the ifindex and the +attach_type. + +Below shows an example link dump output"," and a cgroup link is included for +comparison","[' too:\n\n # bpftool link\n [...]\n 10: cgroup prog 2466\n cgroup_id 1 attach_type cgroup_inet6_post_bind\n [...]\n 8: netkit prog 35\n ifindex nk1(18) attach_type netkit_primary\n [...]\n\nEquivalent json output:\n\n # bpftool link --json\n [...]\n {\n ""id"": 10', '\n ""type"": ""cgroup""', '\n ""prog_id"": 2466', '\n ""cgroup_id"": 1', '\n ""attach_type"": ""cgroup_inet6_post_bind""\n }', '\n [...]\n {\n ""id"": 12', '\n ""type"": ""netkit""', '\n ""prog_id"": 61', '\n ""devname"": ""nk1""', '\n ""ifindex"": 21', '\n ""attach_type"": ""netkit_primary""\n }\n [...]\n\nSigned-off-by: Daniel Borkmann \nReviewed-by: Quentin Monnet \nAcked-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20231024214904.29825-5-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']",Implement support for displaying netkit link information in bpftool.,"bpftool, netkit, link",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"['tracepoints like programs', 'cgroup like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +05c31b4ab20527c4d1695130aaecc54ef59a0e54,05c31b4ab20527c4d1695130aaecc54ef59a0e54,Daniel Borkmann,daniel@iogearbox.net,1698184140,Martin KaFai Lau,martin.lau@kernel.org,1698188818,9a4322a3c4028b65257b7798a5409b8e8bbecfde,5c1b994de4be8a27afa3281be2ff58b38e8bc50c,"libbpf: Add link-based API for netkit + +This adds bpf_program__attach_netkit() API to libbpf. Overall it is very +similar to tcx. The API looks as following: + + LIBBPF_API struct bpf_link * + bpf_program__attach_netkit(const struct bpf_program *prog", int ifindex,"['\n const struct bpf_netkit_opts *opts);\n\nThe struct bpf_netkit_opts is done in similar way as struct bpf_tcx_opts\nfor supporting bpf_mprog control parameters. The attach location for the\nprimary and peer device is derived from the program section ""netkit/primary""\nand ""netkit/peer""', ' respectively.\n\nSigned-off-by: Daniel Borkmann \nAcked-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20231024214904.29825-4-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n', '']","This commit introduces a new link-based API, bpf_program__attach_netkit, to libbpf for attaching eBPF programs.","libbpf, link-based API, netkit",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +35dfaad7188cdc043fde31709c796f5a692ba2bd,35dfaad7188cdc043fde31709c796f5a692ba2bd,Daniel Borkmann,daniel@iogearbox.net,1698184138,Martin KaFai Lau,martin.lau@kernel.org,1698188763,53a88f1799ac38892434318a47278de4a255bc19,42d31dd601fa43b9afdf069d1ba410b2306a4c76,netkit," bpf: Add bpf programmable net device + +This work adds a new","[' minimal BPF-programmable device called ""netkit""\n(former PoC code-name ""meta"") we recently presented at LSF/MM/BPF. The\ncore idea is that BPF programs are executed within the drivers xmit routine\nand therefore e.g. in case of containers/Pods moving BPF processing closer\nto the source.\n\nOne of the goals was that in case of Pod egress traffic', ' this allows to\nmove BPF programs from hostns tcx ingress into the device itself', ' providing\nearlier drop or forward mechanisms', ' for example', ' if the BPF program\ndetermines that the skb must be sent out of the node', ' then a redirect to\nthe physical device can take place directly without going through per-CPU\nbacklog queue. This helps to shift processing for such traffic from softirq\nto process context', ' leading to better scheduling decisions/performance (see\nmeasurements in the slides).\n\nIn this initial version', ' the netkit device ships as a pair', ' but we plan to\nextend this further so it can also operate in single device mode. The pair\ncomes with a primary and a peer device. Only the primary device', ' typically\nresiding in hostns', ' can manage BPF programs for itself and its peer. The\npeer device is designated for containers/Pods and cannot attach/detach\nBPF programs. Upon the device creation', "" the user can set the default policy\nto 'pass' or 'drop' for the case when no BPF program is attached.\n\nAdditionally"", ' the device can be operated in L3 (default) or L2 mode. The\nmanagement of BPF programs is done via bpf_mprog', ' so that multi-attach is\nsupported right from the beginning with similar API and dependency controls\nas tcx. For details on the latter see commit 053c8e1f235d (""bpf: Add generic\nattach/detach/query API for multi-progs""). tc BPF compatibility is provided', '\nso that existing programs can be easily migrated.\n\nGoing forward', "" we plan to use netkit devices in Cilium as the main device\ntype for connecting Pods. They will be operated in L3 mode in order to\nsimplify a Pod's neighbor management and the peer will operate in default\ndrop mode"", ' so that no traffic is leaving between the time when a Pod is\nbrought up by the CNI plugin and programs attached by the agent.\nAdditionally', ' the programs we attach via tcx on the physical devices are\nusing bpf_redirect_peer() for inbound traffic into netkit device', ' hence the\nlatter is also supporting the ndo_get_peer_dev callback. Similarly', ' we use\nbpf_redirect_neigh() for the way out', ' pushing from netkit peer to phys device\ndirectly. Also', ' BIG TCP is supported on netkit device. For the follow-up\nwork in single device mode', "" we plan to convert Cilium's cilium_host/_net\ndevices into a single one.\n\nAn extensive test suite for checking device operations and the BPF program\nand link management API comes as BPF selftests in this series.\n\nCo-developed-by: Nikolay Aleksandrov \nSigned-off-by: Nikolay Aleksandrov \nSigned-off-by: Daniel Borkmann \nReviewed-by: Toke Høiland-Jørgensen \nAcked-by: Stanislav Fomichev \nAcked-by: Martin KaFai Lau \nLink: https://github.com/borkmann/iproute2/tree/pr/netkit\nLink: http://vger.kernel.org/bpfconf2023_material/tcx_meta_netdev_borkmann.pdf (24ff.)\nLink: https://lore.kernel.org/r/20231024214904.29825-2-daniel@iogearbox.net\nSigned-off-by: Martin KaFai Lau \n"", '']",Add a BPF programmable network device in the Linux kernel.,"BPF, network, device",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['socket like programs', 'tc/netfilter like programs', 'other']" +42d31dd601fa43b9afdf069d1ba410b2306a4c76,42d31dd601fa43b9afdf069d1ba410b2306a4c76,Andrii Nakryiko,andrii@kernel.org,1698008257,Daniel Borkmann,daniel@iogearbox.net,1698151551,e018bf2cea6bc60112aef36047781ccb59c31f1f,06646da01458682023321bdc7553b8140e95d077,"bpf: Improve JEQ/JNE branch taken logic + +When determining if an if/else branch will always or never be taken"," use +signed range knowledge in addition to currently used unsigned range knowledge. +If either signed or unsigned range suggests that condition is always/never +taken","[' return corresponding branch_taken verdict.\n\nCurrent use of unsigned range for this seems arbitrary and unnecessarily\nincomplete. It is possible for *signed* operations to be performed on\nregister', ' which could ""invalidate"" unsigned range for that register. In such\ncase branch_taken will be artificially useless', ' even if we can still tell\nthat some constant is outside of register value range based on its signed\nbounds.\n\nveristat-based validation shows zero differences across selftests', ' Cilium', '\nand Meta-internal BPF object files.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: Shung-Hsi Yu \nLink: https://lore.kernel.org/bpf/20231022205743.72352-2-andrii@kernel.org\n', '']",The commit improves the logic for determining JEQ/JNE branch conditions using both signed and unsigned range knowledge.,"JEQ,JNE,branch",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +06646da01458682023321bdc7553b8140e95d077,06646da01458682023321bdc7553b8140e95d077,Paul E. McKenney,paulmck@kernel.org,1697668112,Daniel Borkmann,daniel@iogearbox.net,1698150367,31454fa3d9494e804d54f3a6fc986be93ebca2dc,d35381aa73f7e1e8b25f3ed5283287a64d9ddff5,"bpf: Fold smp_mb__before_atomic() into atomic_set_release() + +The bpf_user_ringbuf_drain() BPF_CALL function uses an atomic_set() +immediately preceded by smp_mb__before_atomic() so as to order storing +of ring-buffer consumer and producer positions prior to the atomic_set() +call's clearing of the ->busy flag"," as follows: + + smp_mb__before_atomic(); + atomic_set(&rb->busy","[' 0);\n\nAlthough this works given current architectures and implementations', ' and\ngiven that this only needs to order prior writes against a later write.\nHowever', ' it does so by accident because the smp_mb__before_atomic()\nis only guaranteed to work with read-modify-write atomic operations', ' and\nnot at all with things like atomic_set() and atomic_read().\n\nNote especially that smp_mb__before_atomic() will not', ' repeat *not*', '\norder the prior write to ""a"" before the subsequent non-read-modify-write\natomic read from ""b""', ' even on strongly ordered systems such as x86:\n\n WRITE_ONCE(a', ' 1);\n smp_mb__before_atomic();\n r1 = atomic_read(&b);\n\nTherefore', ' replace the smp_mb__before_atomic() and atomic_set() with\natomic_set_release() as follows:\n\n atomic_set_release(&rb->busy', ' 0);\n\nThis is no slower (and sometimes is faster) than the original', ' and also\nprovides a formal guarantee of ordering that the original lacks.\n\nSigned-off-by: Paul E. McKenney \nSigned-off-by: Daniel Borkmann \nAcked-by: David Vernet \nLink: https://lore.kernel.org/bpf/ec86d38e-cfb4-44aa-8fdb-6c925922d93c@paulmck-laptop\n', '']",The commit folds smp_mb__before_atomic() into atomic_set_release() in bpf_user_ringbuf_drain() for ring-buffer ordering.,"smp_mb_before_atomic,atomic_set_release,ring-buffer",It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d35381aa73f7e1e8b25f3ed5283287a64d9ddff5,d35381aa73f7e1e8b25f3ed5283287a64d9ddff5,Song Liu,song@kernel.org,1697090261,Daniel Borkmann,daniel@iogearbox.net,1698150355,2e3c4cd03ad2acc9f2c5b5b47b2383c69d9ec037,99b29a499b5fdfb7ab274835b8e4d4c11df2f6d7,"bpf: Fix unnecessary -EBUSY from htab_lock_bucket + +htab_lock_bucket uses the following logic to avoid recursion: + +1. preempt_disable(); +2. check percpu counter htab->map_locked[hash] for recursion; + 2.1. if map_lock[hash] is already taken"," return -BUSY; +3. raw_spin_lock_irqsave(); + +However","[' if an IRQ hits between 2 and 3', ' BPF programs attached to the IRQ\nlogic will not able to access the same hash of the hashtab and get -EBUSY.\n\nThis -EBUSY is not really necessary. Fix it by disabling IRQ before\nchecking map_locked:\n\n1. preempt_disable();\n2. local_irq_save();\n3. check percpu counter htab->map_locked[hash] for recursion;\n 3.1. if map_lock[hash] is already taken', ' return -BUSY;\n4. raw_spin_lock().\n\nSimilarly', ' use raw_spin_unlock() and local_irq_restore() in\nhtab_unlock_bucket().\n\nFixes: 20b6cc34ea74 (""bpf: Avoid hashtab deadlock with map_locked"")\nSuggested-by: Tejun Heo \nSigned-off-by: Song Liu \nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nLink: https://lore.kernel.org/bpf/7a9576222aa40b1c84ad3a9ba3e64011d1a04d41.camel@linux.ibm.com\nLink: https://lore.kernel.org/bpf/20231012055741.3375999-1-song@kernel.org\n', '']",Fixes erroneous -EBUSY error from htab_lock_bucket in eBPF maps.,"fix, htab_lock_bucket, eBPF",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +99b29a499b5fdfb7ab274835b8e4d4c11df2f6d7,99b29a499b5fdfb7ab274835b8e4d4c11df2f6d7,Albert Huang,huangjie.albert@bytedance.com,1698065851,Daniel Borkmann,daniel@iogearbox.net,1698141336,1d4aa58f8b314eabe16eb93feaa6a1fe4cbbdb8e,dedd6c894110371d3c218cf24ecca2f0730408ac,"xsk: Avoid starving the xsk further down the list + +In the previous implementation"," when multiple xsk sockets were +associated with a single xsk_buff_pool","[' a situation could arise\nwhere the xsk_tx_list maintained data at the front for one xsk\nsocket while starving the xsk sockets at the back of the list.\nThis could result in issues such as the inability to transmit packets', '\nincreased latency', ' and jitter. To address this problem', ' we introduce\na new variable called tx_budget_spent', ' which limits each xsk to transmit\na maximum of MAX_PER_SOCKET_BUDGET tx descriptors. This allocation ensures\nequitable opportunities for subsequent xsk sockets to send tx descriptors.\nThe value of MAX_PER_SOCKET_BUDGET is set to 32.\n\nSigned-off-by: Albert Huang \nSigned-off-by: Daniel Borkmann \nAcked-by: Magnus Karlsson \nLink: https://lore.kernel.org/bpf/20231023125732.82261-1-huangjie.albert@bytedance.com\n', '']",Optimize XSK socket handling to prevent resource starvation in shared buffer pools.,"xsk,starvation,buffer",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['socket like programs'] +dedd6c894110371d3c218cf24ecca2f0730408ac,dedd6c894110371d3c218cf24ecca2f0730408ac,Alexei Starovoitov,ast@kernel.org,1698122972,Alexei Starovoitov,ast@kernel.org,1698122972,3dc1fcf7ed24072d47e2cab602fda5476f7171b7,b63dadd6f97522513fe9497b5fde84a154e39a0b b4d8239534fddc036abe4a0fdbf474d9894d4641,"Merge branch 'exact-states-comparison-for-iterator-convergence-checks' + +Eduard Zingerman says: + +==================== +exact states comparison for iterator convergence checks + +Iterator convergence logic in is_state_visited() uses state_equals() +for states with branches counter > 0 to check if iterator based loop +converges. This is not fully correct because state_equals() relies on +presence of read and precision marks on registers. These marks are not +guaranteed to be finalized while state has branches. +Commit message for patch #3 describes a program that exhibits such +behavior. + +This patch-set aims to fix iterator convergence logic by adding notion +of exact states comparison. Exact comparison does not rely on presence +of read or precision marks and thus is more strict. +As explained in commit message for patch #3 exact comparisons require +addition of speculative register bounds widening. The end result for +BPF verifier users could be summarized as follows: + +(!) After this update verifier would reject programs that conjure an + imprecise value on the first loop iteration and use it as precise + on the second (for iterator based loops). + +I urge people to at least skim over the commit message for patch #3. + +Patches are organized as follows: +- patches #1","2: moving/extracting utility functions; +- patch #3: introduces exact mode for states comparison and adds + widening heuristic; +- patch #4: adds test-cases that demonstrate why the series is + necessary; +- patch #5: extends patch #3 with a notion of state loop entries","['\n these entries have to be tracked to correctly identify that\n different verifier states belong to the same states loop;\n- patch #6: adds a test-case that demonstrates a program\n which requires loop entry tracking for correct verification;\n- patch #7: just adds a few debug prints.\n\nThe following actions are planned as a followup for this patch-set:\n- implementation has to be adapted for callbacks handling logic as a\n part of a fix for [1];\n- it is necessary to explore ways to improve widening heuristic to\n handle iters_task_vma test w/o need to insert barrier_var() calls;\n- explored states eviction logic on cache miss has to be extended\n to either:\n - allow eviction of checkpoint states -or-\n - be sped up in case if there are many active checkpoints associated\n with the same instruction.\n\nThe patch-set is a followup for mailing list discussion [1].\n\nChangelog:\n- V2 [3] -> V3:\n - correct check for stack spills in widen_imprecise_scalars()', '\n added test case progs/iters.c:widen_spill to check the behavior\n (suggested by Andrii);\n - allow eviction of checkpoint states in is_state_visited() to avoid\n pathological verifier performance when iterator based loop does not\n converge (discussion with Alexei).\n- V1 [2] -> V2', ' applied changes suggested by Alexei offlist:\n - __explored_state() function removed;\n - same_callsites() function is now used in clean_live_states();\n - patches #1', '2 are added as preparatory code movement;\n - in process_iter_next_call() a safeguard is added to verify that\n cur_st->parent exists and has expected insn index / call sites.\n\n[1] https://lore.kernel.org/bpf/97a90da09404c65c8e810cf83c94ac703705dc0e.camel@gmail.com/\n[2] https://lore.kernel.org/bpf/20231021005939.1041-1-eddyz87@gmail.com/\n[3] https://lore.kernel.org/bpf/20231022010812.9201-1-eddyz87@gmail.com/\n====================\n\nLink: https://lore.kernel.org/r/20231024000917.12153-1-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit enhances iterator convergence checks in the BPF verifier by implementing exact states comparison.,"iterator, convergence, verifier",It's a bug fix.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b4d8239534fddc036abe4a0fdbf474d9894d4641,b4d8239534fddc036abe4a0fdbf474d9894d4641,Eduard Zingerman,eddyz87@gmail.com,1698106157,Alexei Starovoitov,ast@kernel.org,1698122972,3dc1fcf7ed24072d47e2cab602fda5476f7171b7,64870feebecb7130291a55caf0ce839a87405a70,"bpf: print full verifier states on infinite loop detection + +Additional logging in is_state_visited(): if infinite loop is detected +print full verifier state for both current and equivalent states. + +Acked-by: Andrii Nakryiko +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-8-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",,Add logging to print full verifier states when an infinite loop is detected in eBPF programs.,"verifier,logging,infinite loop",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +64870feebecb7130291a55caf0ce839a87405a70,64870feebecb7130291a55caf0ce839a87405a70,Eduard Zingerman,eddyz87@gmail.com,1698106156,Alexei Starovoitov,ast@kernel.org,1698122972,ccce1bb46ed7a2690431d43bdf0563d00c4e6249,2a0992829ea3864939d917a5c7b48be6629c6217,"selftests/bpf: test if state loops are detected in a tricky case + +A convoluted test case for iterators convergence logic that +demonstrates that states with branch count equal to 0 might still be +a part of not completely explored loop. + +E.g. consider the following state diagram: + + initial Here state 'succ' was processed first"," + | it was eventually tracked to produce a + V state identical to 'hdr'. + .---------> hdr All branches from 'succ' had been explored + | | and thus 'succ' has its .branches == 0. + | V + | .------... Suppose states 'cur' and 'succ' correspond + | | | to the same instruction + callsites. + | V V In such case it is necessary to check + | ... ... whether 'succ' and 'cur' are identical. + | | | If 'succ' and 'cur' are a part of the same loop + | V V they have to be compared exactly. + | succ <- cur + | | + | V + | ... + | | + '----' + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-7-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],The commit adds a test to ensure state loops are detected in complex cases within eBPF selftests.,"state loops,test case,iterators",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2a0992829ea3864939d917a5c7b48be6629c6217,2a0992829ea3864939d917a5c7b48be6629c6217,Eduard Zingerman,eddyz87@gmail.com,1698106155,Alexei Starovoitov,ast@kernel.org,1698122972,98866f206e4d928574a096f12956cce039718a25,389ede06c2974b2f878a7ebff6b0f4f707f9db74,"bpf: correct loop detection for iterators convergence + +It turns out that .branches > 0 in is_state_visited() is not a +sufficient condition to identify if two verifier states form a loop +when iterators convergence is computed. This commit adds logic to +distinguish situations like below: + + (I) initial (II) initial + | | + V V + .---------> hdr .. + | | | + | V V + | .------... .------.. + | | | | | + | V V V V + | ... ... .-> hdr .. + | | | | | | + | V V | V V + | succ <- cur | succ <- cur + | | | | + | V | V + | ... | ... + | | | | + '----' '----' + +For both (I) and (II) successor 'succ' of the current state 'cur' was +previously explored and has branches count at 0. However"," loop entry +'hdr' corresponding to 'succ' might be a part of current DFS path. +If that is the case 'succ' and 'cur' are members of the same loop +and have to be compared exactly. + +Co-developed-by: Andrii Nakryiko +Co-developed-by: Alexei Starovoitov +Reviewed-by: Andrii Nakryiko +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-6-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",[''],Correct loop detection logic for iterators convergence in the eBPF verifier.,"loop detection, iterators, verifier",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +389ede06c2974b2f878a7ebff6b0f4f707f9db74,389ede06c2974b2f878a7ebff6b0f4f707f9db74,Eduard Zingerman,eddyz87@gmail.com,1698106154,Alexei Starovoitov,ast@kernel.org,1698122971,4c5c43fff63b6efb7702fae5cd86aba8a1034cfa,2793a8b015f7f1caadb9bce9c63dc659f7522676,"selftests/bpf: tests with delayed read/precision makrs in loop body + +These test cases try to hide read and precision marks from loop +convergence logic: marks would only be assigned on subsequent loop +iterations or after exploring states pushed to env->head stack first. +Without verifier fix to use exact states comparison logic for +iterators convergence these tests (except 'triple_continue') would be +errorneously marked as safe. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-5-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",,Introduce selftests for BPF validating delayed read and precision marks in loop convergence logic.,"selftests,loop,verifier",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +2793a8b015f7f1caadb9bce9c63dc659f7522676,2793a8b015f7f1caadb9bce9c63dc659f7522676,Eduard Zingerman,eddyz87@gmail.com,1698106153,Alexei Starovoitov,ast@kernel.org,1698122971,2ea57178a4460bd2260f768da748d77bf5fa6150,4c97259abc9bc8df7712f76f58ce385581876857,"bpf: exact states comparison for iterator convergence checks + +Convergence for open coded iterators is computed in is_state_visited() +by examining states with branches count > 1 and using states_equal(). +states_equal() computes sub-state relation using read and precision marks. +Read and precision marks are propagated from children states"," +thus are not guaranteed to be complete inside a loop when branches +count > 1. This could be demonstrated using the following unsafe program: + + 1. r7 = -16 + 2. r6 = bpf_get_prandom_u32() + 3. while (bpf_iter_num_next(&fp[-8])) { + 4. if (r6 != 42) { + 5. r7 = -32 + 6. r6 = bpf_get_prandom_u32() + 7. continue + 8. } + 9. r0 = r10 + 10. r0 += r7 + 11. r8 = *(u64 *)(r0 + 0) + 12. r6 = bpf_get_prandom_u32() + 13. } + +Here verifier would first visit path 1-3","[' create a checkpoint at 3\nwith r7=-16', ' continue to 4-7', '3 with r7=-32.\n\nBecause instructions at 9-12 had not been visitied yet existing\ncheckpoint at 3 does not have read or precision mark for r7.\nThus states_equal() would return true and verifier would discard\ncurrent state', ' thus unsafe memory access at 11 would not be caught.\n\nThis commit fixes this loophole by introducing exact state comparisons\nfor iterator convergence logic:\n- registers are compared using regs_exact() regardless of read or\n precision marks;\n- stack slots have to have identical type.\n\nUnfortunately', ' this is too strict even for simple programs like below:\n\n i = 0;\n while(iter_next(&it))\n i++;\n\nAt each iteration step i++ would produce a new distinct state and\neventually instruction processing limit would be reached.\n\nTo avoid such behavior speculatively forget (widen) range for\nimprecise scalar registers', ' if those registers were not precise at the\nend of the previous iteration and do not match exactly.\n\nThis a conservative heuristic that allows to verify wide range of\nprograms', ' however it precludes verification of programs that conjure\nan imprecise value on the first loop iteration and use it as precise\non the second.\n\nTest case iter_task_vma_for_each() presents one of such cases:\n\n unsigned int seen = 0;\n ...\n bpf_for_each(task_vma', ' vma', ' task', "" 0) {\n if (seen >= 1000)\n break;\n ...\n seen++;\n }\n\nHere clang generates the following code:\n\n:\n 24: r8 = r6 ; stash current value of\n ... body ... 'seen'\n 29: r1 = r10\n 30: r1 += -0x8\n 31: call bpf_iter_task_vma_next\n 32: r6 += 0x1 ; seen++;\n 33: if r0 == 0x0 goto +0x2 ; exit on next() == NULL\n 34: r7 += 0x10\n 35: if r8 < 0x3e7 goto -0xc ; loop on seen < 1000\n\n:\n ... exit ...\n\nNote that counter in r6 is copied to r8 and then incremented"", '\nconditional jump is done using r8. Because of this precision mark for\nr6 lags one state behind of precision mark on r8 and widening logic\nkicks in.\n\nAdding barrier_var(seen) after conditional is sufficient to force\nclang use the same register for both counting and conditional jump.\n\nThis issue was discussed in the thread [1] which was started by\nAndrew Werner demonstrating a similar bug\nin callback functions handling. The callbacks would be addressed\nin a followup patch.\n\n[1] https://lore.kernel.org/bpf/97a90da09404c65c8e810cf83c94ac703705dc0e.camel@gmail.com/\n\nCo-developed-by: Andrii Nakryiko \nCo-developed-by: Alexei Starovoitov \nSigned-off-by: Eduard Zingerman \nLink: https://lore.kernel.org/r/20231024000917.12153-4-eddyz87@gmail.com\nSigned-off-by: Alexei Starovoitov \n', '']",Enhanced state comparison for open coded iterator convergence checks in the BPF verifier.,"exact state comparison, convergence, iterators",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4c97259abc9bc8df7712f76f58ce385581876857,4c97259abc9bc8df7712f76f58ce385581876857,Eduard Zingerman,eddyz87@gmail.com,1698106152,Alexei Starovoitov,ast@kernel.org,1698122971,641861689622e60a92fdf40f3774ba9c5e02b72c,3c4e420cb6536026ddd50eaaff5f30e4f144200d,"bpf: extract same_callsites() as utility function + +Extract same_callsites() from clean_live_states() as a utility function. +This function would be used by the next patch in the set. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-3-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",,Extracted same_callsites() as a utility function for reuse.,"utility,function,extraction",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3c4e420cb6536026ddd50eaaff5f30e4f144200d,3c4e420cb6536026ddd50eaaff5f30e4f144200d,Eduard Zingerman,eddyz87@gmail.com,1698106151,Alexei Starovoitov,ast@kernel.org,1698122971,d2bd537839a20ad819db7be96be34f0e3cee9ae9,b63dadd6f97522513fe9497b5fde84a154e39a0b,"bpf: move explored_state() closer to the beginning of verifier.c + +Subsequent patches would make use of explored_state() function. +Move it up to avoid adding unnecessary prototype. + +Signed-off-by: Eduard Zingerman +Link: https://lore.kernel.org/r/20231024000917.12153-2-eddyz87@gmail.com +Signed-off-by: Alexei Starovoitov +",,The explored_state() function is moved to the beginning of verifier.c for upcoming patches.,"explored_state, verifier, function",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +efb3e0e1649f944c032095e3f0533a235a7477d3,efb3e0e1649f944c032095e3f0533a235a7477d3,Jakub Kicinski,kuba@kernel.org,1698113691,Jakub Kicinski,kuba@kernel.org,1698113691,d80ad1aec6a538e50e841ec15360276fed7e6ed6,f4dbc2bb7a54d3bff234a9f1915f1b7187bedb1f 2d0de67da51a90c6acf7bf08d7b0501f45408002,"Merge branch 'introduce-page_pool_alloc-related-api' + +Yunsheng Lin says: + +==================== +introduce page_pool_alloc() related API + +In [1] & [2] & [3]"," there are usecases for veth and virtio_net +to use frag support in page pool to reduce memory usage","[' and it\nmay request different frag size depending on the head/tail\nroom space for xdp_frame/shinfo and mtu/packet size. When the\nrequested frag size is large enough that a single page can not\nbe split into more than one frag', "" using frag support only have\nperformance penalty because of the extra frag count handling\nfor frag support.\n\nSo this patchset provides a page pool API for the driver to\nallocate memory with least memory utilization and performance\npenalty when it doesn't know the size of memory it need\nbeforehand.\n\n1. https://patchwork.kernel.org/project/netdevbpf/patch/d3ae6bd3537fbce379382ac6a42f67e22f27ece2.1683896626.git.lorenzo@kernel.org/\n2. https://patchwork.kernel.org/project/netdevbpf/patch/20230526054621.18371-3-liangchen.linux@gmail.com/\n3. https://github.com/alobakin/linux/tree/iavf-pp-frag\n====================\n\nLink: https://lore.kernel.org/r/20231020095952.11055-1-linyunsheng@huawei.com\nSigned-off-by: Jakub Kicinski \n"", '']","Introduce page_pool_alloc related API to support fragmentation in page pool, optimizing memory usage.","page_pool_alloc, API, memory",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b63dadd6f97522513fe9497b5fde84a154e39a0b,b63dadd6f97522513fe9497b5fde84a154e39a0b,Daniel Borkmann,daniel@iogearbox.net,1698087015,Martin KaFai Lau,martin.lau@kernel.org,1698098513,d8d7dd10c79c522b20ce21d29aa06115424cc4f3,69a19170303ff2f802049be94cfcf62f714002a3,bpf," tcx: Get rid of tcx_link_const + +Small clean up to get rid of the extra tcx_link_const() and only retain +the tcx_link(). + +Signed-off-by: Daniel Borkmann +Link: https://lore.kernel.org/r/20231023185015.21152-1-daniel@iogearbox.net +Signed-off-by: Martin KaFai Lau +",[''],Remove redundant tcx_link_const() to simplify code by retaining only tcx_link() usage.,"cleanup, tcx_link, simplification",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['tc/netfilter like programs'] +69a19170303ff2f802049be94cfcf62f714002a3,69a19170303ff2f802049be94cfcf62f714002a3,Denys Zagorui,dzagorui@cisco.com,1697715321,Andrii Nakryiko,andrii@kernel.org,1698080295,3ba34c839669e39d7c8b9efd24f809e2e75e6f58,cf559a416f9bc061f3b96f8afc6ceae5eec9b2b0,"samples: bpf: Fix syscall_tp openat argument + +This modification doesn't change behaviour of the syscall_tp +But such code is often used as a reference so it should be +correct anyway + +Signed-off-by: Denys Zagorui +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231019113521.4103825-1-dzagorui@cisco.com +",,Corrected the syscall_tp openat argument in BPF samples for improved reference accuracy.,"syscall_tp, openat, BPF",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tracepoints like programs'] +90d862f370b6e9de1b5d607843c5a2f9823990f3,90d862f370b6e9de1b5d607843c5a2f9823990f3,Hari Bathini,hbathini@linux.ibm.com,1697811238,Michael Ellerman,mpe@ellerman.id.au,1698053599,08937d5801a92b65d281a4ffa62d3c37c3fa427c,de04e40600ae15fa5e484be242e74aad6de7418f,"powerpc/bpf: use bpf_jit_binary_pack_[alloc|finalize|free] + +Use bpf_jit_binary_pack_alloc in powerpc jit. The jit engine first +writes the program to the rw buffer. When the jit is done"," the program +is copied to the final location with bpf_jit_binary_pack_finalize. +With multiple jit_subprogs","[' bpf_jit_free is called on some subprograms\nthat haven\'t got bpf_jit_binary_pack_finalize() yet. Implement custom\nbpf_jit_free() like in commit 1d5f82d9dd47 (""bpf', ' x86: fix freeing of\nnot-finalized bpf_prog_pack"") to call bpf_jit_binary_pack_finalize()', '\nif necessary. As bpf_flush_icache() is not needed anymore', ' remove it.\n\nSigned-off-by: Hari Bathini \nAcked-by: Song Liu \nSigned-off-by: Michael Ellerman \nLink: https://msgid.link/20231020141358.643575-6-hbathini@linux.ibm.com\n\n', '']",Enable bpf_jit_binary_pack_usage in PowerPC JIT engine for enhanced program execution.,"PowerPC,JIT,bpf_jit_binary_pack",It's a performance optimization.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +de04e40600ae15fa5e484be242e74aad6de7418f,de04e40600ae15fa5e484be242e74aad6de7418f,Hari Bathini,hbathini@linux.ibm.com,1697811237,Michael Ellerman,mpe@ellerman.id.au,1698053599,fb9e4c5ec6d84398f5f2b691d580686b51b58709,033ffaf0af1f974ecf401db3f70aae6fe1a90fc5,"powerpc/bpf: rename powerpc64_jit_data to powerpc_jit_data + +powerpc64_jit_data is a misnomer as it is meant for both ppc32 and +ppc64. Rename it to powerpc_jit_data. + +Signed-off-by: Hari Bathini +Acked-by: Song Liu +Signed-off-by: Michael Ellerman +Link: https://msgid.link/20231020141358.643575-5-hbathini@linux.ibm.com + +",,The commit renames powerpc64_jit_data to powerpc_jit_data for consistency across ppc32 and ppc64.,"renaming, powerpc, jit",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The JIT compiler,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +033ffaf0af1f974ecf401db3f70aae6fe1a90fc5,033ffaf0af1f974ecf401db3f70aae6fe1a90fc5,Hari Bathini,hbathini@linux.ibm.com,1697811236,Michael Ellerman,mpe@ellerman.id.au,1698053599,38d47ece63167b26626246fb3531ab1ccc4247fe,6efc1675acb88eef45ef0156b93f95d66a8ee759,"powerpc/bpf: implement bpf_arch_text_invalidate for bpf_prog_pack + +Implement bpf_arch_text_invalidate and use it to fill unused part of +the bpf_prog_pack with trap instructions when a BPF program is freed. + +Signed-off-by: Hari Bathini +Acked-by: Song Liu +Signed-off-by: Michael Ellerman +Link: https://msgid.link/20231020141358.643575-4-hbathini@linux.ibm.com + +",,Implement bpf_arch_text_invalidate to manage unused areas in bpf_prog_pack for powerpc.,"powerpc,bpf_arch_text_invalidate,bpf_prog_pack",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6efc1675acb88eef45ef0156b93f95d66a8ee759,6efc1675acb88eef45ef0156b93f95d66a8ee759,Hari Bathini,hbathini@linux.ibm.com,1697811235,Michael Ellerman,mpe@ellerman.id.au,1698053599,9e43c538e8fc92f7ffcf1ae2bcbc96c673310381,465cabc97b42405eb89380ea6ba8d8b03e4ae1a2,"powerpc/bpf: implement bpf_arch_text_copy + +bpf_arch_text_copy is used to dump JITed binary to RX page"," allowing +multiple BPF programs to share the same page. Use the newly introduced +patch_instructions() to implement it. + +Signed-off-by: Hari Bathini +Acked-by: Song Liu +Signed-off-by: Michael Ellerman +Link: https://msgid.link/20231020141358.643575-3-hbathini@linux.ibm.com + +",[''],Implement bpf_arch_text_copy for dumping JITed binary to RX page in powerpc architecture.,"powerpc,JITed binary,bpf_arch_text_copy",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9c5d00cb7b6bbc5a7965d9ab7d223b5402d1f02c,9c5d00cb7b6bbc5a7965d9ab7d223b5402d1f02c,Linus Torvalds,torvalds@linux-foundation.org,1697838564,Linus Torvalds,torvalds@linux-foundation.org,1697838564,f8b4492cf7127f5af61f3bd97f4f210b393f8d74,444ccf1b11a0dbc54e789d6d2634c2649dc27498 4fa008a2db484024a5cb52676a1b1534dc82330c,"Merge tag 'perf-tools-fixes-for-v6.6-2-2023-10-20' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools + +Pull perf tools fixes from Arnaldo Carvalho de Melo: + + - Fix regression in reading scale and unit files from sysfs for PMU + events"," so that we can use that info to pretty print instead of + printing raw numbers: + + # perf stat -e power/energy-ram/","['power/energy-gpu/ sleep 2\n\n Performance counter stats for \'system wide\':\n\n 1.64 Joules power/energy-ram/\n 0.20 Joules power/energy-gpu/\n\n 2.001228914 seconds time elapsed\n #\n # grep -m1 ""model name"" /proc/cpuinfo\n model name\t: Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz\n #\n\n - The small llvm.cpp file used to check if the llvm devel files are\n present was incorrectly deleted when removing the BPF event in \'perf\n trace\'', ' put it back as it is also used by tools/bpf/bpftool', ' that\n uses llvm routines to do disassembly of BPF object files.\n\n - Fix use of addr_location__exit() in dlfilter__object_code()', "" making\n sure that it is only used to pair a previous addr_location__init()\n call.\n\n* tag 'perf-tools-fixes-for-v6.6-2-2023-10-20' of git://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools:\n tools build: Fix llvm feature detection"", ' still used by bpftool\n perf dlfilter: Add a test for object_code()\n perf dlfilter: Fix use of addr_location__exit() in dlfilter__object_code()\n perf pmu: Fix perf stat output with correct scale and unit\n', '']",Merge perf tool fixes for improved PMU event parsing from sysfs to enhance pretty printing in perf stat outputs.,"perf tools, regression, PMU",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['other'] +cf559a416f9bc061f3b96f8afc6ceae5eec9b2b0,cf559a416f9bc061f3b96f8afc6ceae5eec9b2b0,Alexei Starovoitov,ast@kernel.org,1697821975,Alexei Starovoitov,ast@kernel.org,1697836513,e00e8bcbaedd9a6bc3783abe6edcb71b3c2ac382,da1055b673f3baac2249571c9882ce767a0aa746 d440ba91ca4d3004709876779d40713a99e21f6a,"Merge branch 'bpf-fixes-for-per-cpu-kptr' + +Hou Tao says: + +==================== +bpf: Fixes for per-cpu kptr + +From: Hou Tao + +Hi"," + +The patchset aims to fix the problems found in the review of per-cpu +kptr patch-set [0]. Patch #1 moves pcpu_lock after the invocation of +pcpu_chunk_addr_search() and it is a micro-optimization for +free_percpu(). The reason includes it in the patch is that the same +logic is used in newly-added API pcpu_alloc_size(). Patch #2 introduces +pcpu_alloc_size() for dynamic per-cpu area. Patch #2 and #3 use +pcpu_alloc_size() to check whether or not unit_size matches with the +size of underlying per-cpu area and to select a matching bpf_mem_cache. +Patch #4 fixes the freeing of per-cpu kptr when these kptrs are freed by +map destruction. The last patch adds test cases for these problems. + +Please see individual patches for details. And comments are always +welcome. + +Change Log: +v3: + * rebased on bpf-next + * patch 2: update API document to note that pcpu_alloc_size() doesn't + support statically allocated per-cpu area. (Dennis) + * patch 1 & 2: add Acked-by from Dennis + +v2: https://lore.kernel.org/bpf/20231018113343.2446300-1-houtao@huaweicloud.com/ + * add a new patch ""don't acquire pcpu_lock for pcpu_chunk_addr_search()"" + * patch 2: change type of bit_off and end to unsigned long (Andrew) + * patch 2: rename the new API as pcpu_alloc_size and follow 80-column convention (Dennis) + * patch 5: move the common declaration into bpf.h (Stanislav","[' Alxei)\n\nv1: https://lore.kernel.org/bpf/20231007135106.3031284-1-houtao@huaweicloud.com/\n\n[0]: https://lore.kernel.org/bpf/20230827152729.1995219-1-yonghong.song@linux.dev\n====================\n\nLink: https://lore.kernel.org/r/20231020133202.4043247-1-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']","This commit addresses fixes for per-cpu kptr handling in eBPF, including a micro-optimization and test cases addition.","per-cpu,kptr,fixed",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +d440ba91ca4d3004709876779d40713a99e21f6a,d440ba91ca4d3004709876779d40713a99e21f6a,Hou Tao,houtao1@huawei.com,1697808722,Alexei Starovoitov,ast@kernel.org,1697836513,e00e8bcbaedd9a6bc3783abe6edcb71b3c2ac382,e383a45902337356d9ccad797094a27c6b2150f9,"selftests/bpf: Add more test cases for bpf memory allocator + +Add the following 3 test cases for bpf memory allocator: +1) Do allocation in bpf program and free through map free +2) Do batch per-cpu allocation and per-cpu free in bpf program +3) Do per-cpu allocation in bpf program and free through map free + +For per-cpu allocation"," because per-cpu allocation can not refill timely +sometimes","[' so test 2) and test 3) consider it is OK for\nbpf_percpu_obj_new_impl() to return NULL.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231020133202.4043247-8-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Added test cases for memory allocation and management in bpf programs.,"bpf,test cases,allocator",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e383a45902337356d9ccad797094a27c6b2150f9,e383a45902337356d9ccad797094a27c6b2150f9,Hou Tao,houtao1@huawei.com,1697808721,Alexei Starovoitov,ast@kernel.org,1697836513,4d1e5d7c3b683f1bc68676182c98843fdac5db59,e581a3461de3f129cfe888a67d9f31086328271f,"bpf: Use bpf_global_percpu_ma for per-cpu kptr in __bpf_obj_drop_impl() + +The following warning was reported when running ""./test_progs -t +test_bpf_ma/percpu_free_through_map_free"": + + ------------[ cut here ]------------ + WARNING: CPU: 1 PID: 68 at kernel/bpf/memalloc.c:342 + CPU: 1 PID: 68 Comm: kworker/u16:2 Not tainted 6.6.0-rc2+ #222 + Hardware name: QEMU Standard PC (i440FX + PIIX"," 1996) + Workqueue: events_unbound bpf_map_free_deferred + RIP: 0010:bpf_mem_refill+0x21c/0x2a0 + ...... + Call Trace: + + ? bpf_mem_refill+0x21c/0x2a0 + irq_work_single+0x27/0x70 + irq_work_run_list+0x2a/0x40 + irq_work_run+0x18/0x40 + __sysvec_irq_work+0x1c/0xc0 + sysvec_irq_work+0x73/0x90 + + + asm_sysvec_irq_work+0x1b/0x20 + RIP: 0010:unit_free+0x50/0x80 + ...... + bpf_mem_free+0x46/0x60 + __bpf_obj_drop_impl+0x40/0x90 + bpf_obj_free_fields+0x17d/0x1a0 + array_map_free+0x6b/0x170 + bpf_map_free_deferred+0x54/0xa0 + process_scheduled_works+0xba/0x370 + worker_thread+0x16d/0x2e0 + kthread+0x105/0x140 + ret_from_fork+0x39/0x60 + ret_from_fork_asm+0x1b/0x30 + + ---[ end trace 0000000000000000 ]--- + +The reason is simple: __bpf_obj_drop_impl() does not know the freeing +field is a per-cpu pointer and it uses bpf_global_ma to free the +pointer. Because bpf_global_ma is not a per-cpu allocator","["" so ksize() is\nused to select the corresponding cache. The bpf_mem_cache with 16-bytes\nunit_size will always be selected to do the unmatched free and it will\ntrigger the warning in free_bulk() eventually.\n\nBecause per-cpu kptr doesn't support list or rb-tree now"", ' so fix the\nproblem by only checking whether or not the type of kptr is per-cpu in\nbpf_obj_free_fields()', ' and using bpf_global_percpu_ma to these kptrs.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231020133202.4043247-7-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Fixes per-cpu kptr allocation issue in __bpf_obj_drop_impl related to bpf_global_percpu_ma.,"per-cpu,kptr,bpf_global_percpu_ma",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +e581a3461de3f129cfe888a67d9f31086328271f,e581a3461de3f129cfe888a67d9f31086328271f,Hou Tao,houtao1@huawei.com,1697808720,Alexei Starovoitov,ast@kernel.org,1697836513,469fb6cee50b375b8c58ba71f315bcd20849457c,3f2189e4f77b7a3e979d143dc4ff586488c7e8a5,"bpf: Move the declaration of __bpf_obj_drop_impl() to bpf.h + +both syscall.c and helpers.c have the declaration of +__bpf_obj_drop_impl()"," so just move it to a common header file. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231020133202.4043247-6-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],The declaration of __bpf_obj_drop_impl() is moved to a common header file bpf.h.,"declaration, bpf_obj_drop_impl, header",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3f2189e4f77b7a3e979d143dc4ff586488c7e8a5,3f2189e4f77b7a3e979d143dc4ff586488c7e8a5,Hou Tao,houtao1@huawei.com,1697808719,Alexei Starovoitov,ast@kernel.org,1697836513,d2b472bb05a3c5e94c26e69d30c09dc91139bf00,baa8fdecd87bb8751237b45e3bcb5a179e5a12ca,"bpf: Use pcpu_alloc_size() in bpf_mem_free{_rcu}() + +For bpf_global_percpu_ma"," the pointer passed to bpf_mem_free_rcu() is +allocated by kmalloc() and its size is fixed (16-bytes on x86-64). So +no matter which cache allocates the dynamic per-cpu area","[' on x86-64\ncache[2] will always be used to free the per-cpu area.\n\nFix the unbalance by checking whether the bpf memory allocator is\nper-cpu or not and use pcpu_alloc_size() instead of ksize() to\nfind the correct cache for per-cpu free.\n\nSigned-off-by: Hou Tao \nLink: https://lore.kernel.org/r/20231020133202.4043247-5-houtao@huaweicloud.com\nSigned-off-by: Alexei Starovoitov \n', '']",Optimize memory allocation in bpf_mem_free_rcu using pcpu_alloc_size.,"pcpu_alloc_size, bpf_mem_free_rcu, optimization",It's a performance optimization.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +baa8fdecd87bb8751237b45e3bcb5a179e5a12ca,baa8fdecd87bb8751237b45e3bcb5a179e5a12ca,Hou Tao,houtao1@huawei.com,1697808718,Alexei Starovoitov,ast@kernel.org,1697836513,14af489ff503a3e305ad87c77fbb35a434c24e4a,b460bc8302f222d346f0c15bba980eb8c36d6278,"bpf: Re-enable unit_size checking for global per-cpu allocator + +With pcpu_alloc_size() in place"," check whether or not the size of +the dynamic per-cpu area is matched with unit_size. + +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231020133202.4043247-4-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Re-enable unit size checking for global per-cpu allocator in eBPF.,"unit size, per-cpu allocator, checking",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF maps,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +b460bc8302f222d346f0c15bba980eb8c36d6278,b460bc8302f222d346f0c15bba980eb8c36d6278,Hou Tao,houtao1@huawei.com,1697808717,Alexei Starovoitov,ast@kernel.org,1697836506,73bd8effe56c8dcae3d9bfd166ff6772d5abb604,394e6869f0185e89cb815db29bf819474df858ae,"mm/percpu.c: introduce pcpu_alloc_size() + +Introduce pcpu_alloc_size() to get the size of the dynamic per-cpu +area. It will be used by bpf memory allocator in the following patches. +BPF memory allocator maintains per-cpu area caches for multiple area +sizes and its free API only has the to-be-freed per-cpu pointer"," so it +needs the size of dynamic per-cpu area to select the corresponding cache +when bpf program frees the dynamic per-cpu pointer. + +Acked-by: Dennis Zhou +Signed-off-by: Hou Tao +Link: https://lore.kernel.org/r/20231020133202.4043247-3-houtao@huaweicloud.com +Signed-off-by: Alexei Starovoitov +",[''],Introduce pcpu_alloc_size() to assist BPF memory allocator in managing per-cpu area caches.,"pcpu_alloc_size,dynamic,per-cpu",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +da1055b673f3baac2249571c9882ce767a0aa746,da1055b673f3baac2249571c9882ce767a0aa746,Kumar Kartikeya Dwivedi,memxor@gmail.com,1697813319,Andrii Nakryiko,andrii@kernel.org,1697819379,090defa9c2720728459a37c332274a8a085fce4b,bab8ac3c5339d7ec5312dcd836cfa8645edb954f,"selftests/bpf: Make linked_list failure test more robust + +The linked list failure test 'pop_front_off' and 'pop_back_off' +currently rely on matching exact instruction and register values. The +purpose of the test is to ensure the offset is correctly incremented for +the returned pointers from list pop helpers"," which can then be used with +container_of to obtain the real object. Hence","[' somehow obtaining the\ninformation that the offset is 48 will work for us. Make the test more\nrobust by relying on verifier error string of bpf_spin_lock and remove\ndependence on fragile instruction index or register number', ' which can be\naffected by different clang versions used to build the selftests.\n\nFixes: 300f19dcdb99 (""selftests/bpf: Add BPF linked list API tests"")\nReported-by: Andrii Nakryiko \nSigned-off-by: Kumar Kartikeya Dwivedi \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231020144839.2734006-1-memxor@gmail.com\n', '']",Improved robustness of linked list failure test in selftests/bpf by ensuring accurate offset increment for list pop helpers.,"linked list,test robustness,selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +5069211e2f0b47e75119805e23ae6352d871e263,5069211e2f0b47e75119805e23ae6352d871e263,Thomas Richter,tmricht@linux.ibm.com,1697704002,Namhyung Kim,namhyung@kernel.org,1697780506,14b6e75d750f70a3ce8558e0e3fca7bd74727f24,1f36b190ad2dea68e3a7e84b7b2f24ce8c4063ea,"perf trace: Use the right bpf_probe_read(_str) variant for reading user data + +Perf test case 111 Check open filename arg using perf trace + vfs_getname +fails on s390. This is caused by a failing function +bpf_probe_read() in file util/bpf_skel/augmented_raw_syscalls.bpf.c. + +The root cause is the lookup by address. Function bpf_probe_read() +is used. This function works only for architectures +with ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE. + +On s390 is not possible to determine from the address to which +address space the address belongs to (user or kernel space). + +Replace bpf_probe_read() by bpf_probe_read_kernel() +and bpf_probe_read_str() by bpf_probe_read_user_str() to +explicity specify the address space the address refers to. + +Output before: + # ./perf trace -eopen","openat -- touch /tmp/111 + libbpf: prog 'sys_enter': BPF program load failed: Invalid argument + libbpf: prog 'sys_enter': -- BEGIN PROG LOAD LOG -- + reg type unsupported for arg#0 function sys_enter#75 + 0: R1=ctx(off=0","['imm=0) R10=fp0\n ; int sys_enter(struct syscall_enter_args *args)\n 0: (bf) r6 = r1 ; R1=ctx(off=0', 'imm=0) R6_w=ctx(off=0', 'imm=0)\n ; return bpf_get_current_pid_tgid();\n 1: (85) call bpf_get_current_pid_tgid#14 ; R0_w=scalar()\n 2: (63) *(u32 *)(r10 -8) = r0 ; R0_w=scalar() R10=fp0 fp-8=????mmmm\n 3: (bf) r2 = r10 ; R2_w=fp0 R10=fp0\n ;\n .....\n lines deleted here\n .....\n 23: (bf) r3 = r6 ; R3_w=ctx(off=0', 'imm=0) R6=ctx(off=0', ""imm=0)\n 24: (85) call bpf_probe_read#4\n unknown func bpf_probe_read#4\n processed 23 insns (limit 1000000) max_states_per_insn 0 \\\n\t total_states 2 peak_states 2 mark_read 2\n -- END PROG LOAD LOG --\n libbpf: prog 'sys_enter': failed to load: -22\n libbpf: failed to load object 'augmented_raw_syscalls_bpf'\n libbpf: failed to load BPF skeleton 'augmented_raw_syscalls_bpf': -22\n ....\n\nOutput after:\n # ./perf test -Fv 111\n 111: Check open filename arg using perf trace + vfs_getname :\n --- start ---\n 1.085 ( 0.011 ms): touch/320753 openat(dfd: CWD"", ' filename: \\\n\t""/tmp/temporary_file.SWH85""', ' \\\n\tflags: CREAT|NOCTTY|NONBLOCK|WRONLY', ' mode: IRUGO|IWUGO) = 3\n ---- end ----\n Check open filename arg using perf trace + vfs_getname: Ok\n #\n\nTest with the sleep command shows:\nOutput before:\n # ./perf trace -e *sleep sleep 1.234567890\n 0.000 (1234.681 ms): sleep/63114 clock_nanosleep(rqtp: \\\n { .tv_sec: 0', ' .tv_nsec: 0 }', ' rmtp: 0x3ffe0979720) = 0\n #\n\nOutput after:\n # ./perf trace -e *sleep sleep 1.234567890\n 0.000 (1234.686 ms): sleep/64277 clock_nanosleep(rqtp: \\\n { .tv_sec: 1', ' .tv_nsec: 234567890 }', ' rmtp: 0x3fff3df9ea0) = 0\n #\n\nFixes: 14e4b9f4289a (""perf trace: Raw augmented syscalls fix libbpf 1.0+ compatibility"")\nSigned-off-by: Thomas Richter \nCo-developed-by: Arnaldo Carvalho de Melo \nAcked-by: Ilya Leoshkevich \nTested-by: Arnaldo Carvalho de Melo \nCc: Ian Rogers \nCc: gor@linux.ibm.com\nCc: hca@linux.ibm.com\nCc: sumanthk@linux.ibm.com\nCc: svens@linux.ibm.com\nLink: https://lore.kernel.org/r/20231019082642.3286650-1-tmricht@linux.ibm.com\nSigned-off-by: Namhyung Kim \n', '']",Fix bpf_probe_read variant usage for user data reading in perf tool on s390 architecture.,"perf,bpf_probe_read,s390",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,['kprobe/uprobe/ftrace like programs'] +4fa008a2db484024a5cb52676a1b1534dc82330c,4fa008a2db484024a5cb52676a1b1534dc82330c,Arnaldo Carvalho de Melo,acme@redhat.com,1697749773,Arnaldo Carvalho de Melo,acme@redhat.com,1697765638,b3928a05c873d290e0aa8e6d0145bcc26a821577,f38f547314b858b94d36aeb9a4401f0aade7d1af,tools build: Fix llvm feature detection," still used by bpftool + +When removing the BPF event for perf a feature test that checks if the +llvm devel files are availabe was removed but that is also used by +bpftool. + +bpftool uses it to decide what kind of disassembly it will use: llvm or +binutils based. + +Removing the tools/build/feature/test-llvm.cpp file made bpftool to +always fallback to binutils disassembly","[' even with the llvm devel files\ninstalled', ' fix it by restoring just that small test-llvm.cpp test file.\n\nFixes: 56b11a2126bf2f42 (""perf bpf: Remove support for embedding clang for compiling BPF events (-e foo.c)"")\nReported-by: Manu Bretelle \nReviewed-by: Ian Rogers \nReviewed-by: Manu Bretelle \nAcked-by: Quentin Monnet \nCc: Adrian Hunter \nCc: Alexander Shishkin \nCc: Andi Kleen \nCc: Andrii Nakryiko \nCc: Anshuman Khandual \nCc: Carsten Haitzler \nCc: Eduard Zingerman \nCc: Fangrui Song \nCc: He Kuang \nCc: Ingo Molnar \nCc: James Clark \nCc: Jiri Olsa \nCc: Kan Liang \nCc: Leo Yan \nCc: Madhavan Srinivasan \nCc: Mark Rutland \nCc: Namhyung Kim \nCc: Nathan Chancellor \nCc: Naveen N. Rao \nCc: Nick Desaulniers \nCc: Peter Zijlstra \nCc: Ravi Bangoria \nCc: Rob Herring \nCc: Tiezhu Yang \nCc: Tom Rix \nCc: Wang Nan \nCc: Wang ShaoBo \nCc: Yang Jihong \nCc: Yonghong Song \nCc: YueHaibing \nLink: https://lore.kernel.org/lkml/ZTGa0Ukt7QyxWcVy@kernel.org\nSigned-off-by: Arnaldo Carvalho de Melo \n', '']",Fixes llvm feature detection in tools build affecting bpftool disassembly selection.,"llvm,bpftool,disassembly",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,"[""It's not related to any of the above.""]" +bab8ac3c5339d7ec5312dcd836cfa8645edb954f,bab8ac3c5339d7ec5312dcd836cfa8645edb954f,Alexei Starovoitov,ast@kernel.org,1697760167,Alexei Starovoitov,ast@kernel.org,1697760167,11630b18cf327fe18688c437a20edaa9acfe364d,6bd5e167af2e9d1aa79e4a1a2598abcdc8fafd59 130e0f7af9fc7388b90fb016ca13ff3840c48d4a,"Merge branch 'add-open-coded-task-css_task-and-css-iters' + +Chuyi Zhou says: + +==================== +Add Open-coded task"," css_task and css iters + +This is version 6 of task","[' css_task and css iters support.\n\n--- Changelog ---\n\nv5 -> v6:\n\nPatch #3:\n * In bpf_iter_task_next', ' return pos rather than goto out. (Andrii)\nPatch #2', ' #3', ' #4:\n * Add the missing __diag_ignore_all to avoid kernel build warning\nPatch #5', ' #6', "" #7:\n * Add Andrii's ack\n\nPatch #8:\n * In BPF prog iter_css_task_for_each"", ' return -EPERM rather than 0', ' and\n ensure stack_mprotect() in iters.c not success. If not', "" it would cause\n the subsequent 'test_lsm' fail"", ' since the \'is_stack\' check in\n test_int_hook(lsm.c) would not be guaranteed.\n (https://github.com/kernel-patches/bpf/actions/runs/6489662214/job/17624665086?pr=5790)\n\nv4 -> v5:https://lore.kernel.org/lkml/20231007124522.34834-1-zhouchuyi@bytedance.com/\n\nPatch 3~4:\n * Relax the BUILD_BUG_ON check in bpf_iter_task_new and bpf_iter_css_new to avoid\n netdev/build_32bit CI error.\n (https://netdev.bots.linux.dev/static/nipa/790929/13412333/build_32bit/stderr)\nPatch 8:\n * Initialize skel pointer to fix the LLVM-16 build CI error\n (https://github.com/kernel-patches/bpf/actions/runs/6462875618/job/17545170863)\n\nv3 -> v4:https://lore.kernel.org/all/20230925105552.817513-1-zhouchuyi@bytedance.com/\n\n* Address all the comments from Andrii in patch-3 ~ patch-6\n* Collect Tejun\'s ack\n* Add a extra patch to rename bpf_iter_task.c to bpf_iter_tasks.c\n* Seperate three BPF program files for selftests (iters_task.c iters_css_task.c iters_css.c)\n\nv2 -> v3:https://lore.kernel.org/lkml/20230912070149.969939-1-zhouchuyi@bytedance.com/\n\nPatch 1 (cgroup: Prepare for using css_task_iter_*() in BPF)\n * Add tj\'s ack and Alexei\'s suggest-by.\nPatch 2 (bpf: Introduce css_task open-coded iterator kfuncs)\n * Use bpf_mem_alloc/bpf_mem_free rather than kzalloc()\n * Add KF_TRUSTED_ARGS for bpf_iter_css_task_new (Alexei)\n * Move bpf_iter_css_task\'s definition from uapi/linux/bpf.h to\n kernel/bpf/task_iter.c and we can use it from vmlinux.h\n * Move bpf_iter_css_task_XXX\'s declaration from bpf_helpers.h to\n bpf_experimental.h\nPatch 3 (Introduce task open coded iterator kfuncs)\n * Change th API design keep consistent with SEC(""iter/task"")', "" support\n iterating all threads(BPF_TASK_ITERATE_ALL) and threads of a\n specific task (BPF_TASK_ITERATE_THREAD).(Andrii)\n * Move bpf_iter_task's definition from uapi/linux/bpf.h to\n kernel/bpf/task_iter.c and we can use it from vmlinux.h\n * Move bpf_iter_task_XXX's declaration from bpf_helpers.h to\n bpf_experimental.h\nPatch 4 (Introduce css open-coded iterator kfuncs)\n * Change th API design keep consistent with cgroup_iters"", "" reuse\n BPF_CGROUP_ITER_DESCENDANTS_PRE/BPF_CGROUP_ITER_DESCENDANTS_POST\n /BPF_CGROUP_ITER_ANCESTORS_UP(Andrii)\n * Add KF_TRUSTED_ARGS for bpf_iter_css_new\n * Move bpf_iter_css's definition from uapi/linux/bpf.h to\n kernel/bpf/task_iter.c and we can use it from vmlinux.h\n * Move bpf_iter_css_XXX's declaration from bpf_helpers.h to\n bpf_experimental.h\nPatch 5 (teach the verifier to enforce css_iter and task_iter in RCU CS)\n * Add KF flag KF_RCU_PROTECTED to maintain kfuncs which need RCU CS.(Andrii)\n * Consider STACK_ITER when using bpf_for_each_spilled_reg.\nPatch 6 (Let bpf_iter_task_new accept null task ptr)\n * Add this extra patch to let bpf_iter_task_new accept a 'nullable'\n * task pointer(Andrii)\nPatch 7 (selftests/bpf: Add tests for open-coded task and css iter)\n * Add failure testcase(Alexei)\n\nChanges from v1(https://lore.kernel.org/lkml/20230827072057.1591929-1-zhouchuyi@bytedance.com/):\n- Add a pre-patch to make some preparations before supporting css_task\n iters.(Alexei)\n- Add an allowlist for css_task iters(Alexei)\n- Let bpf progs do explicit bpf_rcu_read_lock() when using process\n iters and css_descendant iters.(Alexei)\n---------------------\n\nIn some BPF usage scenarios"", "" it will be useful to iterate the process and\ncss directly in the BPF program. One of the expected scenarios is\ncustomizable OOM victim selection via BPF[1].\n\nInspired by Dave's task_vma iter[2]"", ' this patchset adds three types of\nopen-coded iterator kfuncs:\n\n1. bpf_task_iters. It can be used to\n1) iterate all process in the system', ' like for_each_forcess() in kernel.\n2) iterate all threads in the system.\n3) iterate all threads of a specific task\n\n2. bpf_css_iters. It works like css_task_iter_{start', ' next', ' end} and would\nbe used to iterating tasks/threads under a css.\n\n3. css_iters. It works like css_next_descendant_{pre', ' post} to iterating all\ndescendant css.\n\nBPF programs can use these kfuncs directly or through bpf_for_each macro.\n\nlink[1]: https://lore.kernel.org/lkml/20230810081319.65668-1-zhouchuyi@bytedance.com/\nlink[2]: https://lore.kernel.org/all/20230810183513.684836-1-davemarchevsky@fb.com/\n====================\n\nLink: https://lore.kernel.org/r/20231018061746.111364-1-zhouchuyi@bytedance.com\nSigned-off-by: Alexei Starovoitov \n', '']","This commit merges changes introducing open-coded task iterations, adding new task and CSS iteration features.","open-coded, task, CSS",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.","The attach events and bpf link. e.g. perf events, tracepoints, etc.","['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +130e0f7af9fc7388b90fb016ca13ff3840c48d4a,130e0f7af9fc7388b90fb016ca13ff3840c48d4a,Chuyi Zhou,zhouchuyi@bytedance.com,1697609866,Alexei Starovoitov,ast@kernel.org,1697760167,11630b18cf327fe18688c437a20edaa9acfe364d,ddab78cbb52f81f7f7598482602342955b2ff8b8,"selftests/bpf: Add tests for open-coded task and css iter + +This patch adds 4 subtests to demonstrate these patterns and validating +correctness. + +subtest1: + +1) We use task_iter to iterate all process in the system and search for the +current process with a given pid. + +2) We create some threads in current process context"," and use +BPF_TASK_ITER_PROC_THREADS to iterate all threads of current process. As +expected","[' we would find all the threads of current process.\n\n3) We create some threads and use BPF_TASK_ITER_ALL_THREADS to iterate all\nthreads in the system. As expected', ' we would find all the threads which was\ncreated.\n\nsubtest2:\n\nWe create a cgroup and add the current task to the cgroup. In the\nBPF program', ' we would use bpf_for_each(css_task', ' task', ' css) to iterate all\ntasks under the cgroup. As expected', ' we would find the current process.\n\nsubtest3:\n\n1) We create a cgroup tree. In the BPF program', ' we use\nbpf_for_each(css', ' pos', ' root', ' XXX) to iterate all descendant under the root\nwith pre and post order. As expected', ' we would find all descendant and the\nlast iterating cgroup in post-order is root cgroup', ' the first iterating\ncgroup in pre-order is root cgroup.\n\n2) We wse BPF_CGROUP_ITER_ANCESTORS_UP to traverse the cgroup tree starting\nfrom leaf and root separately', ' and record the height. The diff of the\nhights would be the total tree-high - 1.\n\nsubtest4:\n\nAdd some failure testcase when using css_task', ' task and css iters', ' e.g', '\nunlock when using task-iters to iterate tasks.\n\nSigned-off-by: Chuyi Zhou \nLink: https://lore.kernel.org/r/20231018061746.111364-9-zhouchuyi@bytedance.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit introduces four subtests for open-coded task and CSS iterator patterns in selftests for BPF.,"tests,selftests,BPF",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['kprobe/uprobe/ftrace like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ddab78cbb52f81f7f7598482602342955b2ff8b8,ddab78cbb52f81f7f7598482602342955b2ff8b8,Chuyi Zhou,zhouchuyi@bytedance.com,1697609865,Alexei Starovoitov,ast@kernel.org,1697760167,1277c81e699ed02d528aa169954c6eac98da52e8,cb3ecf7915a1d7ce5304402f4d8616d9fa5193f7,"selftests/bpf: rename bpf_iter_task.c to bpf_iter_tasks.c + +The newly-added struct bpf_iter_task has a name collision with a selftest +for the seq_file task iter's bpf skel"," so the selftests/bpf/progs file is +renamed in order to avoid the collision. + +Signed-off-by: Chuyi Zhou +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/r/20231018061746.111364-8-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov +",[''],Renamed bpf_iter_task.c to bpf_iter_tasks.c in selftests to avoid a name collision.,"rename, selftests, collision",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['tracepoints like programs'] +cb3ecf7915a1d7ce5304402f4d8616d9fa5193f7,cb3ecf7915a1d7ce5304402f4d8616d9fa5193f7,Chuyi Zhou,zhouchuyi@bytedance.com,1697609864,Alexei Starovoitov,ast@kernel.org,1697760166,9ee9742addacbd0b553396aeae598823aae8cf0a,dfab99df147b0d364f0c199f832ff2aedfb2265a,"bpf: Let bpf_iter_task_new accept null task ptr + +When using task_iter to iterate all threads of a specific task"," we enforce +that the user must pass a valid task pointer to ensure safety. However","['\nwhen iterating all threads/process in the system', ' BPF verifier still\nrequire a valid ptr instead of ""nullable"" pointer', "" even though it's\npointless"", ' which is a kind of surprising from usability standpoint. It\nwould be nice if we could let that kfunc accept a explicit null pointer\nwhen we are using BPF_TASK_ITER_ALL_{PROCS', ' THREADS} and a valid pointer\nwhen using BPF_TASK_ITER_THREAD.\n\nGiven a trival kfunc:\n\t__bpf_kfunc void FN(struct TYPE_A *obj);\n\nBPF Prog would reject a nullptr for obj. The error info is:\n""arg#x pointer type xx xx must point to scalar', ' or struct with scalar""\nreported by get_kfunc_ptr_arg_type(). The reg->type is SCALAR_VALUE and\nthe btf type of ref_t is not scalar or scalar_struct which leads to the\nrejection of get_kfunc_ptr_arg_type.\n\nThis patch add ""__nullable"" annotation:\n\t__bpf_kfunc void FN(struct TYPE_A *obj__nullable);\nHere __nullable indicates obj can be optional', ' user can pass a explicit\nnullptr or a normal TYPE_A pointer. In get_kfunc_ptr_arg_type()', ' we will\ndetect whether the current arg is optional and register is null', ' If so', '\nreturn a new kfunc_ptr_arg_type KF_ARG_PTR_TO_NULL and skip to the next\narg in check_kfunc_args().\n\nSigned-off-by: Chuyi Zhou \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231018061746.111364-7-zhouchuyi@bytedance.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit allows bpf_iter_task_new to accept a null task pointer for iterating threads.,"bpf, task_ptr, iter",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +dfab99df147b0d364f0c199f832ff2aedfb2265a,dfab99df147b0d364f0c199f832ff2aedfb2265a,Chuyi Zhou,zhouchuyi@bytedance.com,1697609863,Alexei Starovoitov,ast@kernel.org,1697760166,6bbe3fa26b07cf39eaa8a0657f03079be79c85ef,7251d0905e7518bcb990c8e9a3615b1bb23c78f2,"bpf: teach the verifier to enforce css_iter and task_iter in RCU CS + +css_iter and task_iter should be used in rcu section. Specifically"," in +sleepable progs explicit bpf_rcu_read_lock() is needed before use these +iters. In normal bpf progs that have implicit rcu_read_lock()","["" it's OK to\nuse them directly.\n\nThis patch adds a new a KF flag KF_RCU_PROTECTED for bpf_iter_task_new and\nbpf_iter_css_new. It means the kfunc should be used in RCU CS. We check\nwhether we are in rcu cs before we want to invoke this kfunc. If the rcu\nprotection is guaranteed"", ' we would let st->type = PTR_TO_STACK | MEM_RCU.\nOnce user do rcu_unlock during the iteration', ' state MEM_RCU of regs would\nbe cleared. is_iter_reg_valid_init() will reject if reg->type is UNTRUSTED.\n\nIt is worth noting that currently', ' bpf_rcu_read_unlock does not\nclear the state of the STACK_ITER reg', ' since bpf_for_each_spilled_reg\nonly considers STACK_SPILL. This patch also let bpf_for_each_spilled_reg\nsearch STACK_ITER.\n\nSigned-off-by: Chuyi Zhou \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/r/20231018061746.111364-6-zhouchuyi@bytedance.com\nSigned-off-by: Alexei Starovoitov \n', '']",The commit enforces css_iter and task_iter usage in RCU critical sections within BPF programs.,"verifier,css_iter,RCU",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +7251d0905e7518bcb990c8e9a3615b1bb23c78f2,7251d0905e7518bcb990c8e9a3615b1bb23c78f2,Chuyi Zhou,zhouchuyi@bytedance.com,1697609862,Alexei Starovoitov,ast@kernel.org,1697760166,28cbfe76ea2eff8d6ae5cd09f32c732a1cdd6e80,c68a78ffe2cb4207f64fd0f4262818c728c67be0,"bpf: Introduce css open-coded iterator kfuncs + +This Patch adds kfuncs bpf_iter_css_{new",next,"['destroy} which allow\ncreation and manipulation of struct bpf_iter_css in open-coded iterator\nstyle. These kfuncs actually wrapps css_next_descendant_{pre', ' post}.\ncss_iter can be used to:\n\n1) iterating a sepcific cgroup tree with pre/post/up order\n\n2) iterating cgroup_subsystem in BPF Prog', ' like\nfor_each_mem_cgroup_tree/cpuset_for_each_descendant_pre in kernel.\n\nThe API design is consistent with cgroup_iter. bpf_iter_css_new accepts\nparameters defining iteration order and starting css. Here we also reuse\nBPF_CGROUP_ITER_DESCENDANTS_PRE', ' BPF_CGROUP_ITER_DESCENDANTS_POST', '\nBPF_CGROUP_ITER_ANCESTORS_UP enums.\n\nSigned-off-by: Chuyi Zhou \nAcked-by: Tejun Heo \nLink: https://lore.kernel.org/r/20231018061746.111364-5-zhouchuyi@bytedance.com\nSigned-off-by: Alexei Starovoitov \n', '']",This commit introduces kfuncs for open-coded iterator in eBPF.,"kfuncs, iterator, bpf",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +c68a78ffe2cb4207f64fd0f4262818c728c67be0,c68a78ffe2cb4207f64fd0f4262818c728c67be0,Chuyi Zhou,zhouchuyi@bytedance.com,1697609861,Alexei Starovoitov,ast@kernel.org,1697760166,6a95dc7b2480bb918ba7c3e0eaa96da6ad67c18f,9c66dc94b62aef23300f05f63404afb8990920b4,"bpf: Introduce task open coded iterator kfuncs + +This patch adds kfuncs bpf_iter_task_{new",next,"['destroy} which allow\ncreation and manipulation of struct bpf_iter_task in open-coded iterator\nstyle. BPF programs can use these kfuncs or through bpf_for_each macro to\niterate all processes in the system.\n\nThe API design keep consistent with SEC(""iter/task""). bpf_iter_task_new()\naccepts a specific task and iterating type which allows:\n\n1. iterating all process in the system (BPF_TASK_ITER_ALL_PROCS)\n\n2. iterating all threads in the system (BPF_TASK_ITER_ALL_THREADS)\n\n3. iterating all threads of a specific task (BPF_TASK_ITER_PROC_THREADS)\n\nSigned-off-by: Chuyi Zhou \nLink: https://lore.kernel.org/r/20231018061746.111364-4-zhouchuyi@bytedance.com\nSigned-off-by: Alexei Starovoitov \n', '']",Introduces task open coded iterator kfuncs for eBPF.,"bpf, task, kfuncs",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9c66dc94b62aef23300f05f63404afb8990920b4,9c66dc94b62aef23300f05f63404afb8990920b4,Chuyi Zhou,zhouchuyi@bytedance.com,1697609860,Alexei Starovoitov,ast@kernel.org,1697760166,9df3e5be227342647a1815c62ac0567d9bebbf61,6da88306811b40a207c94c9da9faf07bdb20776e,"bpf: Introduce css_task open-coded iterator kfuncs + +This patch adds kfuncs bpf_iter_css_task_{new",next,"['destroy} which allow\ncreation and manipulation of struct bpf_iter_css_task in open-coded\niterator style. These kfuncs actually wrapps css_task_iter_{start', 'next', '\nend}. BPF programs can use these kfuncs through bpf_for_each macro for\niteration of all tasks under a css.\n\ncss_task_iter_*() would try to get the global spin-lock *css_set_lock*', ' so\nthe bpf side has to be careful in where it allows to use this iter.\nCurrently we only allow it in bpf_lsm and bpf iter-s.\n\nSigned-off-by: Chuyi Zhou \nAcked-by: Tejun Heo \nLink: https://lore.kernel.org/r/20231018061746.111364-3-zhouchuyi@bytedance.com\nSigned-off-by: Alexei Starovoitov \n', '']",Introduce open-coded iterator kfuncs for css_task in bpf.,"bpf, kfuncs, iterator",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +6da88306811b40a207c94c9da9faf07bdb20776e,6da88306811b40a207c94c9da9faf07bdb20776e,Chuyi Zhou,zhouchuyi@bytedance.com,1697609859,Alexei Starovoitov,ast@kernel.org,1697760166,810c25824382b03274431b9670f419b2650af7ae,6bd5e167af2e9d1aa79e4a1a2598abcdc8fafd59,"cgroup: Prepare for using css_task_iter_*() in BPF + +This patch makes some preparations for using css_task_iter_*() in BPF +Program. + +1. Flags CSS_TASK_ITER_* are #define-s and it's not easy for bpf prog to +use them. Convert them to enum so bpf prog can take them from vmlinux.h. + +2. In the next patch we will add css_task_iter_*() in common kfuncs which +is not safe. Since css_task_iter_*() does spin_unlock_irq() which might +screw up irq flags depending on the context where bpf prog is running. +So we should use irqsave/irqrestore here and the switching is harmless. + +Suggested-by: Alexei Starovoitov +Signed-off-by: Chuyi Zhou +Acked-by: Tejun Heo +Link: https://lore.kernel.org/r/20231018061746.111364-2-zhouchuyi@bytedance.com +Signed-off-by: Alexei Starovoitov +",,Prepare for using css_task_iter functions in BPF by converting defines to enums and addressing irq issues.,"css_task_iter, BPF, preparation",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The helper and kfuncs,['cgroup like programs'] +b9ec913212e6e91efa5a0a612c4a8ec4cf5da896,b9ec913212e6e91efa5a0a612c4a8ec4cf5da896,Breno Leitao,leitao@debian.org,1697464069,Jens Axboe,axboe@kernel.dk,1697755324,6cea837326eae4029a0e8afefcb1527115d75dfe,4232c6e349f3a591fd0f432e6b858d32095adce6,"selftests/bpf/sockopt: Add io_uring support + +Expand the sockopt test to use also check for io_uring {g","s}etsockopt +commands operations. + +This patch starts by marking each test if they support io_uring support +or not. + +Right now","[' io_uring cmd getsockopt() has a limitation of only\naccepting level == SOL_SOCKET', "" otherwise it returns -EOPNOTSUPP. Since\nthere aren't any test exercising getsockopt(level == SOL_SOCKET)"", ' this\npatch changes two tests to use level == SOL_SOCKET', ' they are\n""getsockopt: support smaller ctx->optlen"" and ""getsockopt: read\nctx->optlen"".\nThere is no limitation for the setsockopt() part.\n\nLater', ' each test runs using regular {g', 's}etsockopt systemcalls', ' and', ' if\nliburing is supported', ' execute the same test (again)', ' but calling\nliburing {g', 's}setsockopt commands.\n\nThis patch also changes the level of two tests to use SOL_SOCKET for the\nfollowing two tests. This is going to help to exercise the io_uring\nsubsystem:\n * getsockopt: read ctx->optlen\n * getsockopt: support smaller ctx->optlen\n\nSigned-off-by: Breno Leitao \nLink: https://lore.kernel.org/r/20231016134750.1381153-12-leitao@debian.org\nAcked-by: Martin KaFai Lau \nSigned-off-by: Jens Axboe \n', '']",The commit adds io_uring support to the sockopt selftests for checking setsockopt commands operations.,"io_uring,sockopt,selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['socket like programs'] +7746a6adfc81e2e0386a85117d5e8fd824da367b,7746a6adfc81e2e0386a85117d5e8fd824da367b,Breno Leitao,leitao@debian.org,1697464064,Jens Axboe,axboe@kernel.dk,1697755323,b7f5439e621d5aaf8162b28177cbe1e40bcda77c,5fea44a6e05b86bf49019fbbf2ab30098d03e0dc,"tools headers: Grab copy of io_uring.h + +This file will be used by mini_uring.h and allow tests to run without +the need of installing liburing to run the tests. + +This is needed to run io_uring tests in BPF"," such as +(tools/testing/selftests/bpf/prog_tests/sockopt.c). + +Signed-off-by: Breno Leitao +Link: https://lore.kernel.org/r/20231016134750.1381153-7-leitao@debian.org +Signed-off-by: Jens Axboe +",[''],This commit grabs a copy of io_uring.h for running io_uring tests without liburing installation.,"io_uring,h,tests",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +3f31e0d14d44ad491a81b7c1f83f32fbc300a867,3f31e0d14d44ad491a81b7c1f83f32fbc300a867,Breno Leitao,leitao@debian.org,1697464060,Jens Axboe,axboe@kernel.dk,1697745937,e69d7c1110eef9f75be5837577e5ba0df99cfd8a,a615f67e1a426f35366b8398c11f31c148e7df48,"bpf: Add sockptr support for setsockopt + +The whole network stack uses sockptr"," and while it doesn't move to +something more modern","["" let's use sockptr in setsockptr BPF hooks"", ' so', ' it\ncould be used by other callers.\n\nThe main motivation for this change is to use it in the io_uring\n{g', 's}etsockopt()', ' which will use a userspace pointer for *optval', ' but', ' a\nkernel value for optlen.\n\nLink: https://lore.kernel.org/all/ZSArfLaaGcfd8LH8@gmail.com/\n\nSigned-off-by: Breno Leitao \nAcked-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20231016134750.1381153-3-leitao@debian.org\nSigned-off-by: Jens Axboe \n', '']",Add support for sockptr in the bpf setsockopt function.,"sockptr, setsockopt, network",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +a615f67e1a426f35366b8398c11f31c148e7df48,a615f67e1a426f35366b8398c11f31c148e7df48,Breno Leitao,leitao@debian.org,1697464059,Jens Axboe,axboe@kernel.dk,1697745928,4e4f6688f2ea831ce503599d3880f73d60e026db,6ce4a93dbb5bd93bc2bdf14da63f9360a4dcd6a1,"bpf: Add sockptr support for getsockopt + +The whole network stack uses sockptr"," and while it doesn't move to +something more modern","["" let's use sockptr in getsockptr BPF hooks"", ' so', ' it\ncould be used by other callers.\n\nThe main motivation for this change is to use it in the io_uring\n{g', 's}etsockopt()', ' which will use a userspace pointer for *optval', ' but', ' a\nkernel value for optlen.\n\nLink: https://lore.kernel.org/all/ZSArfLaaGcfd8LH8@gmail.com/\n\nSigned-off-by: Breno Leitao \nAcked-by: Martin KaFai Lau \nLink: https://lore.kernel.org/r/20231016134750.1381153-2-leitao@debian.org\nSigned-off-by: Jens Axboe \n', '']",The commit adds sockptr support for getsockopt in the BPF subsystem.,"bpf,sockptr,getsockopt",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,['socket like programs'] +ce55c22ec8b223a90ff3e084d842f73cfba35588,ce55c22ec8b223a90ff3e084d842f73cfba35588,Linus Torvalds,torvalds@linux-foundation.org,1697742498,Linus Torvalds,torvalds@linux-foundation.org,1697742498,919fc51c26a8b5f57b3c89f6a62d0f3bb1bdfd2c,74e9347ebc5be452935fe4f3eddb150aa5a6f4fe 524515020f2552759a7ef1c9d03e7dac9b1ff3c2,"Merge tag 'net-6.6-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Jakub Kicinski: + ""Including fixes from bluetooth", netfilter,"[' WiFi.\n\n Feels like an up-tick in regression fixes', ' mostly for older releases.\n The hfsc fix', ' tcp_disconnect() and Intel WWAN fixes stand out as\n fairly clear-cut user reported regressions. The mlx5 DMA bug was\n causing strife for 390x folks. The fixes themselves are not\n particularly scary', ' tho. No open investigations / outstanding reports\n at the time of writing.\n\n Current release - regressions:\n\n - eth: mlx5: perform DMA operations in the right locations', ' make\n devices usable on s390x', "" again\n\n - sched: sch_hfsc: upgrade 'rt' to 'sc' when it becomes a inner\n curve"", ' previous fix of rejecting invalid config broke some scripts\n\n - rfkill: reduce data->mtx scope in rfkill_fop_open', ' avoid deadlock\n\n - revert ""ethtool: Fix mod state of verbose no_mask bitset""', ' needs\n more work\n\n Current release - new code bugs:\n\n - tcp: fix listen() warning with v4-mapped-v6 address\n\n Previous releases - regressions:\n\n - tcp: allow tcp_disconnect() again when threads are waiting', ' it was\n denied to plug a constant source of bugs but turns out .NET depends\n on it\n\n - eth: mlx5: fix double-free if buffer refill fails under OOM\n\n - revert ""net: wwan: iosm: enable runtime pm support for 7560""', "" it's\n causing regressions and the WWAN team at Intel disappeared\n\n - tcp: tsq: relax tcp_small_queue_check() when rtx queue contains a\n single skb"", ' fix single-stream perf regression on some devices\n\n Previous releases - always broken:\n\n - Bluetooth:\n - fix issues in legacy BR/EDR PIN code pairing\n - correctly bounds check and pad HCI_MON_NEW_INDEX name\n\n - netfilter:\n - more fixes / follow ups for the large ""commit protocol"" rework', '\n which went in as a fix to 6.5\n - fix null-derefs on netlink attrs which user may not pass in\n\n - tcp: fix excessive TLP and RACK timeouts from HZ rounding (bless\n Debian for keeping HZ=250 alive)\n\n - net: more strict VIRTIO_NET_HDR_GSO_UDP_L4 validation', ' prevent\n letting frankenstein UDP super-frames from getting into the stack\n\n - net: fix interface altnames when ifc moves to a new namespace\n\n - eth: qed: fix the size of the RX buffers\n\n - mptcp: avoid sending RST when closing the initial subflow""\n\n* tag \'net-6.6-rc7\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (94 commits)\n Revert ""ethtool: Fix mod state of verbose no_mask bitset""\n selftests: mptcp: join: no RST when rm subflow/addr\n mptcp: avoid sending RST when closing the initial subflow\n mptcp: more conservative check for zero probes\n tcp: check mptcp-level constraints for backlog coalescing\n selftests: mptcp: join: correctly check for no RST\n net: ti: icssg-prueth: Fix r30 CMDs bitmasks\n selftests: net: add very basic test for netdev names and namespaces\n net: move altnames together with the netdevice\n net: avoid UAF on deleted altname\n net: check for altname conflicts when changing netdev\'s netns\n net: fix ifname in netlink ntf during netns move\n net: ethernet: ti: Fix mixed module-builtin object\n net: phy: bcm7xxx: Add missing 16nm EPHY statistics\n ipv4: fib: annotate races around nh->nh_saddr_genid and nh->nh_saddr\n tcp_bpf: properly release resources on error paths\n net/sched: sch_hfsc: upgrade \'rt\' to \'sc\' when it becomes a inner curve\n net: mdio-mux: fix C45 access returning -EIO after API change\n tcp: tsq: relax tcp_small_queue_check() when rtx queue contains a single skb\n octeon_ep: update BQL sent bytes before ringing doorbell\n ...\n', '']","Merge network-related fixes for the Linux kernel, including updates from bluetooth.","networking, fixes, bluetooth",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +6bd5e167af2e9d1aa79e4a1a2598abcdc8fafd59,6bd5e167af2e9d1aa79e4a1a2598abcdc8fafd59,Manu Bretelle,chantr4@gmail.com,1697670093,Daniel Borkmann,daniel@iogearbox.net,1697725815,26269f8535c6e4ab0da210d580c6c4f7a6c3da8a,90704b4be0b0d6d0a7a9369d4b9aae6a579602c7,"bpftool: Wrap struct_ops dump in an array + +When dumping a struct_ops"," 2 dictionaries are emitted. + +When using `name`","[' they were already wrapped in an array', ' but not when\nusing `id`. Causing `jq` to fail at parsing the payload as it reached\nthe comma following the first dict.\n\nThis change wraps those dictionaries in an array so valid json is emitted.\n\nBefore', "" jq fails to parse the output:\n```\n $ sudo bpftool struct_ops dump id 1523612 | jq . > /dev/null\nparse error: Expected value before '"", ""' at line 19"", ' column 2\n```\n\nAfter', ' no error parsing the output:\n```\nsudo ./bpftool struct_ops dump id 1523612 | jq . > /dev/null\n```\n\nSigned-off-by: Manu Bretelle \nSigned-off-by: Daniel Borkmann \nTested-by: Eduard Zingerman \nAcked-by: Eduard Zingerman \nAcked-by: Quentin Monnet \nLink: https://lore.kernel.org/bpf/20231018230133.1593152-3-chantr4@gmail.com\n', '']",Wraps struct_ops dump in an array within bpftool utility.,"bpftool,struct_ops,array",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +90704b4be0b0d6d0a7a9369d4b9aae6a579602c7,90704b4be0b0d6d0a7a9369d4b9aae6a579602c7,Manu Bretelle,chantr4@gmail.com,1697670092,Daniel Borkmann,daniel@iogearbox.net,1697725776,b7a572801da28d3dc213446b5e72b63c76986f67,0e133a13370389d3894891eafe54fec2c44ad735,"bpftool: Fix printing of pointer value + +When printing a pointer value"," ""%p"" will either print the hexadecimal +value of the pointer (e.g `0x1234`)","[' or `(nil)` when NULL.\n\nBoth of those are invalid json ""integer"" values and need to be wrapped\nin quotes.\n\nBefore:\n```\n$ sudo bpftool struct_ops dump name ned_dummy_cca | grep next\n ""next"": (nil)', ""\n$ sudo bpftool struct_ops dump name ned_dummy_cca | \\\n jq '.[1].bpf_struct_ops_tcp_congestion_ops.data.list.next'\nparse error: Invalid numeric literal at line 29"", ' column 34\n```\n\nAfter:\n```\n$ sudo ./bpftool struct_ops dump name ned_dummy_cca | grep next\n ""next"": ""(nil)""', '\n$ sudo ./bpftool struct_ops dump name ned_dummy_cca | \\\n jq \'.[1].bpf_struct_ops_tcp_congestion_ops.data.list.next\'\n""(nil)""\n```\n\nSigned-off-by: Manu Bretelle \nSigned-off-by: Daniel Borkmann \nTested-by: Eduard Zingerman \nAcked-by: Eduard Zingerman \nAcked-by: Quentin Monnet \nLink: https://lore.kernel.org/bpf/20231018230133.1593152-2-chantr4@gmail.com\n', '']",This commit fixes the way bpftool prints pointer values to display them in hexadecimal format.,"bpftool,pointer printing,bug fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,['other'] +68b54aeff804acceb02f228ea2e28419272c1fb9,68b54aeff804acceb02f228ea2e28419272c1fb9,Paolo Abeni,pabeni@redhat.com,1697557791,Jakub Kicinski,kuba@kernel.org,1697677771,2ee3946a361acf50f951e4b6bda9cbaad27e0d49,a13b67c9a015c4e21601ef9aa4ec9c5d972df1b4,"tcp_bpf: properly release resources on error paths + +In the blamed commit below"," I completely forgot to release the acquired +resources before erroring out in the TCP BPF code","[' as reported by Dan.\n\nAddress the issues by replacing the bogus return with a jump to the\nrelevant cleanup code.\n\nFixes: 419ce133ab92 (""tcp: allow again tcp_disconnect() when threads are waiting"")\nReported-by: Dan Carpenter \nSigned-off-by: Paolo Abeni \nAcked-by: Jakub Sitnicki \nReviewed-by: Eric Dumazet \nReviewed-by: John Fastabend \nLink: https://lore.kernel.org/r/8f99194c698bcef12666f0a9a999c58f8b1cb52c.1697557782.git.pabeni@redhat.com\nSigned-off-by: Jakub Kicinski \n', '']",This commit fixes resource release on error paths in the TCP BPF code.,"TCP BPF,release,errorpaths",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,['socket like programs'] +bdcb37a5d8de3253da48b120e3f10863696fb654,bdcb37a5d8de3253da48b120e3f10863696fb654,Arnd Bergmann,arnd@arndb.de,1697553238,Yury Norov,yury.norov@gmail.com,1697677677,cec6ecddbcd76119e0e2097b28ab42c7483022d0,6cb42f91aa6dfd10fd847c469caebe63b35141ff,"buildid: reduce header file dependencies for module + +The vmlinux decompressor code intentionally has only a limited set of +included header files"," but this started running into a build failure +because of the bitmap logic needing linux/errno.h: + +In file included from include/linux/cpumask.h:12","['\n from include/linux/mm_types_task.h:14', '\n from include/linux/mm_types.h:5', '\n from include/linux/buildid.h:5', '\n from include/linux/module.h:14', '\n from arch/arm/boot/compressed/../../../../lib/lz4/lz4_decompress.c:39', '\n from arch/arm/boot/compressed/../../../../lib/decompress_unlz4.c:10', ""\n from arch/arm/boot/compressed/decompress.c:60:\ninclude/linux/bitmap.h: In function 'bitmap_allocate_region':\ninclude/linux/bitmap.h:527:25: error: 'EBUSY' undeclared (first use in this function)\n 527 | return -EBUSY;\n | ^~~~~\ninclude/linux/bitmap.h:527:25: note: each undeclared identifier is reported only once for each function it appears in\ninclude/linux/bitmap.h: In function 'bitmap_find_free_region':\ninclude/linux/bitmap.h:554:17: error: 'ENOMEM' undeclared (first use in this function)\n 554 | return -ENOMEM;\n | ^~~~~~\n\nThis is easily avoided by changing linux/buildid.h to no longer depend on\nlinux/mm_types.h"", ' a header that pulls in a huge number of indirect dependencies.\n\nFixes: b9c957f554442 (""bitmap: move bitmap_*_region() functions to bitmap.h"")\nFixes: bd7525dacd7e2 (""bpf: Move stack_map_get_build_id into lib"")\nSigned-off-by: Arnd Bergmann \nSigned-off-by: Yury Norov \n', '']",The commit reduces header file dependencies for the vmlinux decompressor module to fix build failures.,"header, dependencies, module",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +0e133a13370389d3894891eafe54fec2c44ad735,0e133a13370389d3894891eafe54fec2c44ad735,Dave Thaler,dthaler@microsoft.com,1697574620,Daniel Borkmann,daniel@iogearbox.net,1697672172,54f3b6815025572d7a5bcf028caf6a37bce626c3,bb6a88885fde24835afdaa1c5bb976a1bf5c5d71,bpf," docs: Define signed modulo as using truncated division + +There's different mathematical definitions (truncated","[' floored', ' rounded', '\netc.) and different languages have chosen different definitions [0][1].\nE.g.', ' languages/libraries that follow Knuth use a different mathematical\ndefinition than C uses. This patch specifies which definition BPF uses', '\nas verified by Eduard [2] and others.\n\n [0] https://en.wikipedia.org/wiki/Modulo#Variants_of_the_definition\n [1] https://torstencurdt.com/tech/posts/modulo-of-negative-numbers/\n [2] https://lore.kernel.org/bpf/57e6fefadaf3b2995bb259fa8e711c7220ce5290.camel@gmail.com/\n\nSigned-off-by: Dave Thaler \nSigned-off-by: Daniel Borkmann \nAcked-by: David Vernet \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20231017203020.1500-1-dthaler1968@googlemail.com\n', '']",Clarified the definition of signed modulo using truncated division in documentation.,"signed modulo, truncated division, documentation",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +b5c532e90478e134b66b067c2b0487526ac4161e,b5c532e90478e134b66b067c2b0487526ac4161e,Jiri Olsa,jolsa@kernel.org,1696800171,Namhyung Kim,namhyung@kernel.org,1697668187,35aec88f528685a6d724023cf3a550ac512a6ca0,d9997f7ffb137447aa2f820c26cb1e6f5890d978,"tools/build: Fix -s detection code in tools/scripts/Makefile.include + +As Dmitry described in [1] changelog the current way of detecting +-s option is broken for new make. + +Changing the tools/build -s option detection the same way as it was +fixed for root Makefile in [1]. + +[1] 4bf73588165b (""kbuild: Port silent mode detection to future gnu make."") + +Cc: Dmitry Goncharov +Signed-off-by: Jiri Olsa +Tested-by: Arnaldo Carvalho de Melo +Acked-by: Namhyung Kim +Cc: Peter Zijlstra +Cc: KP Singh +Cc: Martin KaFai Lau +Cc: Song Liu +Cc: Yonghong Song +Cc: John Fastabend +Cc: Hao Luo +Cc: Ian Rogers +Cc: Stanislav Fomichev +Cc: Daniel Borkmann +Cc: Quentin Monnet +Cc: Arnaldo Carvalho de Melo +Cc: Andrii Nakryiko +Cc: Alexei Starovoitov +Cc: Ingo Molnar +Cc: Alexander Shishkin +Cc: bpf@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231008212251.236023-3-jolsa@kernel.org +Signed-off-by: Namhyung Kim +",,Fix detection of the -s option in Makefile for compatibility with new versions of GNU make.,"detection, Makefile, compatibility",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +d9997f7ffb137447aa2f820c26cb1e6f5890d978,d9997f7ffb137447aa2f820c26cb1e6f5890d978,Jiri Olsa,jolsa@kernel.org,1696800170,Namhyung Kim,namhyung@kernel.org,1697668175,e398c50eb44f433bcdcb920d61c034e71777d8d2,9a13ee457a6e7a850ac1d145b0731b1d729b8f42,"tools/build: Fix -s detection code in tools/build/Makefile.build + +As Dmitry described in [1] changelog the current way of detecting +-s option is broken for new make. + +Changing the tools/build -s option detection the same way as it was +fixed for root Makefile in [1]. + +[1] 4bf73588165b (""kbuild: Port silent mode detection to future gnu make."") + +Cc: Dmitry Goncharov +Signed-off-by: Jiri Olsa +Tested-by: Arnaldo Carvalho de Melo +Acked-by: Namhyung Kim +Cc: Peter Zijlstra +Cc: KP Singh +Cc: Martin KaFai Lau +Cc: Song Liu +Cc: Yonghong Song +Cc: John Fastabend +Cc: Hao Luo +Cc: Ian Rogers +Cc: Stanislav Fomichev +Cc: Daniel Borkmann +Cc: Quentin Monnet +Cc: Arnaldo Carvalho de Melo +Cc: Andrii Nakryiko +Cc: Alexei Starovoitov +Cc: Ingo Molnar +Cc: Alexander Shishkin +Cc: bpf@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231008212251.236023-2-jolsa@kernel.org +Signed-off-by: Namhyung Kim +",,Fix the -s option detection in tools/build/Makefile.build for compatibility with new make versions.,"Fix, Makefile, tools",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +71ca5ee18708c1f9f086e20ac0a657009bcfe43a,71ca5ee18708c1f9f086e20ac0a657009bcfe43a,Joe Perches,joe@perches.com,1696541717,Andrew Morton,akpm@linux-foundation.org,1697665402,36c6ff15df35b963ea6755bef7bdd4c3adb7e3c5,ead5a727739fa63b94ccd281d848a503032444ee,"get_maintainer: add --keywords-in-file option + +There were some recent attempts [1] [2] to make the K: field less noisy +and its behavior more obvious. Ultimately"," a shift in the default +behavior and an associated command line flag is the best choice. + +Currently","[' K: will match keywords found in both patches and files.\n\nMatching content from entire files is (while documented) not obvious\nbehavior and is usually not wanted by maintainers.\n\nNow only patch content will be matched against unless --keywords-in-file\nis also provided as an argument to get_maintainer.\n\nAdd the actual keyword matched to the role or rolestats as well.\n\nFor instance given the diff below that removes clang:\n\n: diff --git a/drivers/hid/bpf/entrypoints/README b/drivers/hid/bpf/entrypoints/README\n: index 147e0d41509f..f88eb19e8ef2 100644\n: --- a/drivers/hid/bpf/entrypoints/README\n: +++ b/drivers/hid/bpf/entrypoints/README\n: @@ -1', '4 +1', '4 @@\n: WARNING:\n: If you change ""entrypoints.bpf.c"" do ""make -j"" in this directory to rebuild ""entrypoints.skel.h"".\n: -Make sure to have clang 10 installed.\n: +Make sure to have 10 installed.\n: See Documentation/bpf/bpf_devel_QA.rst\n\nThe new role/rolestats output includes "":Keyword:\\b(?i:clang|llvm)\\b""\n\n$ git diff drivers/hid/bpf/entrypoints/README | .scripts/get_maintainer.pl\nJiri Kosina (maintainer:HID CORE LAYER', 'commit_signer:1/1=100%)\nBenjamin Tissoires (maintainer:HID CORE LAYER', 'commit_signer:1/1=100%', 'authored:1/1=100%', 'added_lines:4/4=100%)\nNathan Chancellor (supporter:CLANG/LLVM BUILD SUPPORT:Keyword:\\b(?i:clang|llvm)\\b)\nNick Desaulniers (supporter:CLANG/LLVM BUILD SUPPORT:Keyword:\\b(?i:clang|llvm)\\b)\nTom Rix (reviewer:CLANG/LLVM BUILD SUPPORT:Keyword:\\b(?i:clang|llvm)\\b)\nGreg Kroah-Hartman (commit_signer:1/1=100%)\nlinux-input@vger.kernel.org (open list:HID CORE LAYER)\nlinux-kernel@vger.kernel.org (open list)\nllvm@lists.linux.dev (open list:CLANG/LLVM BUILD SUPPORT:Keyword:\\b(?i:clang|llvm)\\b)\n\nLink: https://lore.kernel.org/r/20231004-get_maintainer_change_k-v1-1-ac7ced18306a@google.com\nLink: https://lore.kernel.org/all/20230928-get_maintainer_add_d-v2-0-8acb3f394571@google.com\nLink: https://lore.kernel.org/all/3dca40b677dd2fef979a5a581a2db91df2c21801.camel@perches.com\nOriginal-patch-by: Justin Stitt \nLink: https://lkml.kernel.org/r/01fe46f0c58aa8baf92156ae2bdccfb2bf0cb48e.camel@perches.com\nSigned-off-by: Joe Perches \nTested-by: Justin Stitt \nCc: Kees Cook \nCc: Nick Desaulniers \n\nSigned-off-by: Andrew Morton \n', '']",Added an option to get_maintainer for filtering with keywords in the file.,"get_maintainer, keywords, filtering",It's a new feature.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +1bc628a756d93a7bed2f80914b15821bb9a4369c,1bc628a756d93a7bed2f80914b15821bb9a4369c,Jeff Layton,jlayton@kernel.org,1696445586,Christian Brauner,brauner@kernel.org,1697630910,0ade6c2274eba788c9928e9f6c302031d6a47c9d,d162a3cf6ee1a64417e11693c1410d79878c9917,"bpf: convert to new timestamp accessors + +Convert to using the new inode timestamp accessor functions. + +Signed-off-by: Jeff Layton +Link: https://lore.kernel.org/r/20231004185347.80880-79-jlayton@kernel.org +Signed-off-by: Christian Brauner +",,The commit updates BPF code to use new inode timestamp accessors.,"bpf, timestamp, accessors",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4b47b0fa4b15e0de916e7dd93cd787fdab208ff2,4b47b0fa4b15e0de916e7dd93cd787fdab208ff2,Muhammad Muzammil,m.muzzammilashraf@gmail.com,1697175078,Michael Ellerman,mpe@ellerman.id.au,1697628420,c9db4f51c53caac0f3c8897a821721a73ac12e22,1c7b4bc375c2a235e3dcb53c46111883df838e42,"powerpc/bpf: Fixed 'instead' typo in bpf_jit_build_body() + +Fixed 'instead' typo. + +Signed-off-by: Muhammad Muzammil +Signed-off-by: Michael Ellerman +Link: https://msgid.link/20231013053118.11221-1-m.muzzammilashraf@gmail.com + +",,Corrected a typo in the bpf_jit_build_body function for PowerPC architecture.,"typo, bpf, PowerPC",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The JIT compiler,"[""It's not related to any of the above.""]" +bb6a88885fde24835afdaa1c5bb976a1bf5c5d71,bb6a88885fde24835afdaa1c5bb976a1bf5c5d71,Larysa Zaremba,larysa.zaremba@intel.com,1697560077,Daniel Borkmann,daniel@iogearbox.net,1697616508,fb6d11350096d03d673f7389b7922b1484ed85a4,24516309e330cd592c04d0467313d885584af4e8,"selftests/bpf: Add options and frags to xdp_hw_metadata + +This is a follow-up to the commit 9b2b86332a9b (""bpf: Allow to use kfunc +XDP hints and frags together""). + +The are some possible implementations problems that may arise when providing +metadata specifically for multi-buffer packets"," therefore there must be a +possibility to test such option separately. + +Add an option to use multi-buffer AF_XDP xdp_hw_metadata and mark used XDP +program as capable to use frags. + +As for now","[' xdp_hw_metadata accepts no options', ' so add simple option\nparsing logic and a help message.\n\nFor quick reference', ' also add an ingress packet generation command to the\nhelp message. The command comes from [0].\n\nExample of output for multi-buffer packet:\n\n xsk_ring_cons__peek: 1\n 0xead018: rx_desc[15]->addr=10000000000f000 addr=f100 comp_addr=f000\n rx_hash: 0x5789FCBB with RSS type:0x29\n rx_timestamp: 1696856851535324697 (sec:1696856851.5353)\n XDP RX-time: 1696856843158256391 (sec:1696856843.1583)\n \tdelta sec:-8.3771 (-8377068.306 usec)\n AF_XDP time: 1696856843158413078 (sec:1696856843.1584)\n \tdelta sec:0.0002 (156.687 usec)\n 0xead018: complete idx=23 addr=f000\n xsk_ring_cons__peek: 1\n 0xead018: rx_desc[16]->addr=100000000008000 addr=8100 comp_addr=8000\n 0xead018: complete idx=24 addr=8000\n xsk_ring_cons__peek: 1\n 0xead018: rx_desc[17]->addr=100000000009000 addr=9100 comp_addr=9000 EoP\n 0xead018: complete idx=25 addr=9000\n\nMetadata is printed for the first packet only.\n\n [0] https://lore.kernel.org/all/20230119221536.3349901-18-sdf@google.com/\n\nSigned-off-by: Larysa Zaremba \nSigned-off-by: Daniel Borkmann \nAcked-by: Stanislav Fomichev \nLink: https://lore.kernel.org/bpf/20231017162800.24080-1-larysa.zaremba@intel.com\n', '']",Add an option to test XDP hardware metadata with multi-buffer and frags support in selftests.,"XDP, metadata, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,['xdp like programs'] +24516309e330cd592c04d0467313d885584af4e8,24516309e330cd592c04d0467313d885584af4e8,Daniel Borkmann,daniel@iogearbox.net,1697530648,Andrii Nakryiko,andrii@kernel.org,1697572663,5d37875e4ec423afdc1a97121c1576790c5351a3,44cb03f19b38c11cfc5bf76ea6d6885da210ded2,"selftests/bpf: Add additional mprog query test coverage + +Add several new test cases which assert corner cases on the mprog query +mechanism", for example,"[' around passing in a too small or a larger array\nthan the current count.\n\n ./test_progs -t tc_opts\n #252 tc_opts_after:OK\n #253 tc_opts_append:OK\n #254 tc_opts_basic:OK\n #255 tc_opts_before:OK\n #256 tc_opts_chain_classic:OK\n #257 tc_opts_chain_mixed:OK\n #258 tc_opts_delete_empty:OK\n #259 tc_opts_demixed:OK\n #260 tc_opts_detach:OK\n #261 tc_opts_detach_after:OK\n #262 tc_opts_detach_before:OK\n #263 tc_opts_dev_cleanup:OK\n #264 tc_opts_invalid:OK\n #265 tc_opts_max:OK\n #266 tc_opts_mixed:OK\n #267 tc_opts_prepend:OK\n #268 tc_opts_query:OK\n #269 tc_opts_query_attach:OK\n #270 tc_opts_replace:OK\n #271 tc_opts_revision:OK\n Summary: 20/0 PASSED', ' 0 SKIPPED', ' 0 FAILED\n\nSigned-off-by: Daniel Borkmann \nSigned-off-by: Andrii Nakryiko \nReviewed-by: Alan Maguire \nLink: https://lore.kernel.org/bpf/20231017081728.24769-1-daniel@iogearbox.net\n', '']",Add new test cases for mprog query to cover corner cases in selftests for BPF.,"selftests, mprog, query",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +eff65ee26ed73f3ca635bac13c386a4538a608d8,eff65ee26ed73f3ca635bac13c386a4538a608d8,Athira Rajeev,atrajeev@linux.vnet.ibm.com,1697182220,Namhyung Kim,namhyung@kernel.org,1697571651,7a43c152bdec47af92bbd25586fbbadce2e2f73b,47f5693c4ce9b2bf2364303a531423e43278d3b6,"perf tests: Fix shellcheck warning in record_sideband.sh + +Running shellcheck on record_sideband.sh throws below +warning: + + In tests/shell/record_sideband.sh line 25: + if ! perf record -o ${perfdata} -BN --no-bpf-event -C $1 true 2>&1 >/dev/null + ^--^ SC2069: To redirect stdout+stderr"," 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify). + +This shows shellcheck warning SC2069 where the redirection +order needs to be fixed. Use ""cmd > /dev/null 2>&1"" to fix +the redirection of perf record output + +Fixes: 23b97c7ee963 (""perf test: Add test case for record sideband events"") +Signed-off-by: Athira Rajeev +Reviewed-by: Kajol Jain +Acked-by: Namhyung Kim +Cc: disgoel@linux.vnet.ibm.com +Link: https://lore.kernel.org/r/20231013073021.99794-3-atrajeev@linux.vnet.ibm.com +Signed-off-by: Namhyung Kim +",[''],Fixes shellcheck warnings by correcting stdout and stderr redirection in record_sideband.sh script.,"shellcheck, redirection, record_sideband.sh",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +44cb03f19b38c11cfc5bf76ea6d6885da210ded2,44cb03f19b38c11cfc5bf76ea6d6885da210ded2,Yafang Shao,laoar.shao@gmail.com,1696687185,Daniel Borkmann,daniel@iogearbox.net,1697560287,0efa05d493d5d29421eaf690db7f32fc5c3cc855,29a7e00ffadddd8d68eff311de1bf12ae10687bb,"selftests/bpf: Add selftest for bpf_task_under_cgroup() in sleepable prog + +The result is as follows: + + $ tools/testing/selftests/bpf/test_progs --name=task_under_cgroup + #237 task_under_cgroup:OK + Summary: 1/0 PASSED", 0 SKIPPED,"[' 0 FAILED\n\nWithout the previous patch', ' there will be RCU warnings in dmesg when\nCONFIG_PROVE_RCU is enabled. While with the previous patch', ' there will\nbe no warnings.\n\nSigned-off-by: Yafang Shao \nSigned-off-by: Daniel Borkmann \nAcked-by: Stanislav Fomichev \nLink: https://lore.kernel.org/bpf/20231007135945.4306-2-laoar.shao@gmail.com\n', '']",Added selftest for the bpf_task_under_cgroup function in sleepable program.,"selftest,bpf_task_under_cgroup,sleepable",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +29a7e00ffadddd8d68eff311de1bf12ae10687bb,29a7e00ffadddd8d68eff311de1bf12ae10687bb,Yafang Shao,laoar.shao@gmail.com,1696687184,Daniel Borkmann,daniel@iogearbox.net,1697560061,042ee90bd69658a8806b2ff4324e8c3ef48a6d0b,9a675ba55a96a45a9fb69e6a5c43f80c6682e541,"bpf: Fix missed rcu read lock in bpf_task_under_cgroup() + +When employed within a sleepable program not under RCU protection"," the +use of 'bpf_task_under_cgroup()' may trigger a warning in the kernel log","['\nparticularly when CONFIG_PROVE_RCU is enabled:\n\n [ 1259.662357] WARNING: suspicious RCU usage\n [ 1259.662358] 6.5.0+ #33 Not tainted\n [ 1259.662360] -----------------------------\n [ 1259.662361] include/linux/cgroup.h:423 suspicious rcu_dereference_check() usage!\n\nOther info that might help to debug this:\n\n [ 1259.662366] rcu_scheduler_active = 2', ' debug_locks = 1\n [ 1259.662368] 1 lock held by trace/72954:\n [ 1259.662369] #0: ffffffffb5e3eda0 (rcu_read_lock_trace){....}-{0:0}', ' at: __bpf_prog_enter_sleepable+0x0/0xb0\n\nStack backtrace:\n\n [ 1259.662385] CPU: 50 PID: 72954 Comm: trace Kdump: loaded Not tainted 6.5.0+ #33\n [ 1259.662391] Call Trace:\n [ 1259.662393] \n [ 1259.662395] dump_stack_lvl+0x6e/0x90\n [ 1259.662401] dump_stack+0x10/0x20\n [ 1259.662404] lockdep_rcu_suspicious+0x163/0x1b0\n [ 1259.662412] task_css_set.part.0+0x23/0x30\n [ 1259.662417] bpf_task_under_cgroup+0xe7/0xf0\n [ 1259.662422] bpf_prog_7fffba481a3bcf88_lsm_run+0x5c/0x93\n [ 1259.662431] bpf_trampoline_6442505574+0x60/0x1000\n [ 1259.662439] bpf_lsm_bpf+0x5/0x20\n [ 1259.662443] ? security_bpf+0x32/0x50\n [ 1259.662452] __sys_bpf+0xe6/0xdd0\n [ 1259.662463] __x64_sys_bpf+0x1a/0x30\n [ 1259.662467] do_syscall_64+0x38/0x90\n [ 1259.662472] entry_SYSCALL_64_after_hwframe+0x6e/0xd8\n [ 1259.662479] RIP: 0033:0x7f487baf8e29\n [...]\n [ 1259.662504] \n\nThis issue can be reproduced by executing a straightforward program', ' as\ndemonstrated below:\n\nSEC(""lsm.s/bpf"")\nint BPF_PROG(lsm_run', ' int cmd', ' union bpf_attr *attr', ' unsigned int size)\n{\n struct cgroup *cgrp = NULL;\n struct task_struct *task;\n int ret = 0;\n\n if (cmd != BPF_LINK_CREATE)\n return 0;\n\n // The cgroup2 should be mounted first\n cgrp = bpf_cgroup_from_id(1);\n if (!cgrp)\n goto out;\n task = bpf_get_current_task_btf();\n if (bpf_task_under_cgroup(task', ' cgrp))\n ret = -1;\n bpf_cgroup_release(cgrp);\n\nout:\n return ret;\n}\n\nAfter running the program', ' if you subsequently execute another BPF program', ""\nyou will encounter the warning.\n\nIt's worth noting that task_under_cgroup_hierarchy() is also utilized by\nbpf_current_task_under_cgroup(). However"", ' bpf_current_task_under_cgroup()\ndoesn\'t exhibit this issue because it cannot be used in sleepable BPF\nprograms.\n\nFixes: b5ad4cdc46c7 (""bpf: Add bpf_task_under_cgroup() kfunc"")\nSigned-off-by: Yafang Shao \nSigned-off-by: Daniel Borkmann \nAcked-by: Stanislav Fomichev \nCc: Feng Zhou \nCc: KP Singh \nLink: https://lore.kernel.org/bpf/20231007135945.4306-1-laoar.shao@gmail.com\n', '']",Fixes a missing RCU read lock in bpf_task_under_cgroup for sleepable programs.,"RCU, bpf_task_under_cgroup, fix",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The helper and kfuncs,"['cgroup like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +9a675ba55a96a45a9fb69e6a5c43f80c6682e541,9a675ba55a96a45a9fb69e6a5c43f80c6682e541,Sebastian Andrzej Siewior,bigeasy@linutronix.de,1697461058,Daniel Borkmann,daniel@iogearbox.net,1697547723,c7d9260fe55b9ee3be40aae411dcba0a91556e1f,137df1189d128a6b5dee2f653e054b40ef36b94c,net," bpf: Add a warning if NAPI cb missed xdp_do_flush(). + +A few drivers were missing a xdp_do_flush() invocation after +XDP_REDIRECT. + +Add three helper functions each for one of the per-CPU lists. Return +true if the per-CPU list is non-empty and flush the list. + +Add xdp_do_check_flushed() which invokes each helper functions and +creates a warning if one of the functions had a non-empty list. + +Hide everything behind CONFIG_DEBUG_NET. + +Suggested-by: Jesper Dangaard Brouer +Signed-off-by: Sebastian Andrzej Siewior +Signed-off-by: Daniel Borkmann +Reviewed-by: Toke Høiland-Jørgensen +Acked-by: Jakub Kicinski +Acked-by: John Fastabend +Link: https://lore.kernel.org/bpf/20231016125738.Yt79p1uF@linutronix.de +",[''],Add warning for missed xdp_do_flush invocation in NAPI callbacks for XDP_REDIRECT.,"xdp_do_flush,NAPI,warning",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['xdp like programs'] +137df1189d128a6b5dee2f653e054b40ef36b94c,137df1189d128a6b5dee2f653e054b40ef36b94c,Andrii Nakryiko,andrii@kernel.org,1697480920,Daniel Borkmann,daniel@iogearbox.net,1697535800,63414cb538d83336a18287774f062f2f0df1eb2e,a3c2dd96487f1dd734c9443a3472c8dafa689813,"libbpf: Don't assume SHT_GNU_verdef presence for SHT_GNU_versym section + +Fix too eager assumption that SHT_GNU_verdef ELF section is going to be +present whenever binary has SHT_GNU_versym section. It seems like either +SHT_GNU_verdef or SHT_GNU_verneed can be used"," so failing on missing +SHT_GNU_verdef actually breaks use cases in production. + +One specific reported issue","[' which was used to manually test this fix', '\nwas trying to attach to `readline` function in BASH binary.\n\nFixes: bb7fa09399b9 (""libbpf: Support symbol versioning for uprobe"")\nReported-by: Liam Wisehart \nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nTested-by: Manu Bretelle \nReviewed-by: Fangrui Song \nAcked-by: Hengqi Chen \nLink: https://lore.kernel.org/bpf/20231016182840.4033346-1-andrii@kernel.org\n', '']",Fix assumption regarding SHT_GNU_verdef and SHT_GNU_versym ELF sections in libbpf.,"SHT_GNU_verdef,SHT_GNU_versym,libbpf",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,"[""It's not related to any of the above.""]" +a3c2dd96487f1dd734c9443a3472c8dafa689813,a3c2dd96487f1dd734c9443a3472c8dafa689813,Jakub Kicinski,kuba@kernel.org,1697515532,Jakub Kicinski,kuba@kernel.org,1697515533,8e8df48280355e3bcd331ab12aeafb0121970cf0,90de47f020db086f7929e09f64efd0cf627d6869 99c9991f4e5d77328187187d0c921a3b62bfa998,"Merge tag 'for-netdev' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next + +Daniel Borkmann says: + +==================== +pull-request: bpf-next 2023-10-16 + +We've added 90 non-merge commits during the last 25 day(s) which contain +a total of 120 files changed", 3519 insertions(+),"[' 895 deletions(-).\n\nThe main changes are:\n\n1) Add missed stats for kprobes to retrieve the number of missed kprobe\n executions and subsequent executions of BPF programs', ' from Jiri Olsa.\n\n2) Add cgroup BPF sockaddr hooks for unix sockets. The use case is\n for systemd to reimplement the LogNamespace feature which allows\n running multiple instances of systemd-journald to process the logs\n of different services', ' from Daan De Meyer.\n\n3) Implement BPF CPUv4 support for s390x BPF JIT', ' from Ilya Leoshkevich.\n\n4) Improve BPF verifier log output for scalar registers to better\n disambiguate their internal state wrt defaults vs min/max values\n matching', ' from Andrii Nakryiko.\n\n5) Extend the BPF fib lookup helpers for IPv4/IPv6 to support retrieving\n the source IP address with a new BPF_FIB_LOOKUP_SRC flag', '\n from Martynas Pumputis.\n\n6) Add support for open-coded task_vma iterator to help with symbolization\n for BPF-collected user stacks', ' from Dave Marchevsky.\n\n7) Add libbpf getters for accessing individual BPF ring buffers which\n is useful for polling them individually', ' for example', ' from Martin Kelly.\n\n8) Extend AF_XDP selftests to validate the SHARED_UMEM feature', '\n from Tushar Vyavahare.\n\n9) Improve BPF selftests cross-building support for riscv arch', '\n from Björn Töpel.\n\n10) Add the ability to pin a BPF timer to the same calling CPU', ""\n from David Vernet.\n\n11) Fix libbpf's bpf_tracing.h macros for riscv to use the generic\n implementation of PT_REGS_SYSCALL_REGS() to access syscall arguments"", '\n from Alexandre Ghiti.\n\n12) Extend libbpf to support symbol versioning for uprobes', "" from Hengqi Chen.\n\n13) Fix bpftool's skeleton code generation to guarantee that ELF data\n is 8 byte aligned"", ' from Ian Rogers.\n\n14) Inherit system-wide cpu_mitigations_off() setting for Spectre v1/v4\n security mitigations in BPF verifier', ' from Yafang Shao.\n\n15) Annotate struct bpf_stack_map with __counted_by attribute to prepare\n BPF side for upcoming __counted_by compiler support', ' from Kees Cook.\n\n* tag \'for-netdev\' of https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next: (90 commits)\n bpf: Ensure proper register state printing for cond jumps\n bpf: Disambiguate SCALAR register state output in verifier logs\n selftests/bpf: Make align selftests more robust\n selftests/bpf: Improve missed_kprobe_recursion test robustness\n selftests/bpf: Improve percpu_alloc test robustness\n selftests/bpf: Add tests for open-coded task_vma iter\n bpf: Introduce task_vma open-coded iterator kfuncs\n selftests/bpf: Rename bpf_iter_task_vma.c to bpf_iter_task_vmas.c\n bpf: Don\'t explicitly emit BTF for struct btf_iter_num\n bpf: Change syscall_nr type to int in struct syscall_tp_t\n net/bpf: Avoid unused ""sin_addr_len"" warning when CONFIG_CGROUP_BPF is not set\n bpf: Avoid unnecessary audit log for CPU security mitigations\n selftests/bpf: Add tests for cgroup unix socket address hooks\n selftests/bpf: Make sure mount directory exists\n documentation/bpf: Document cgroup unix socket address hooks\n bpftool: Add support for cgroup unix socket address hooks\n libbpf: Add support for cgroup unix socket address hooks\n bpf: Implement cgroup sockaddr hooks for unix sockets\n bpf: Add bpf_sock_addr_set_sun_path() to allow writing unix sockaddr from bpf\n bpf: Propagate modified uaddrlen from cgroup sockaddr programs\n ...\n====================\n\nLink: https://lore.kernel.org/r/20231016204803.30153-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n', '']",Merged 90 non-merge commits from the 'bpf-next' branch containing 120 files changed.,"merge,bpf-next,files",It's other type of commit.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +54a59aed395ce0f4177b5212e5746a6462de3ad9,54a59aed395ce0f4177b5212e5746a6462de3ad9,Daniel Borkmann,daniel@iogearbox.net,1696843614,Jakub Kicinski,kuba@kernel.org,1697476056,52bd084eaf68223e5246f2b4b859cb567608f65a,dccce1d7c04051bc25d3abbe7716d0ae7af9c28a,net," sched: Make tc-related drop reason more flexible + +Currently","[' the kfree_skb_reason() in sch_handle_{ingress', 'egress}() can only\nexpress a basic SKB_DROP_REASON_TC_INGRESS or SKB_DROP_REASON_TC_EGRESS reason.\n\nVictor kicked-off an initial proposal to make this more flexible by disambiguating\nverdict from return code by moving the verdict into struct tcf_result and\nletting tcf_classify() return a negative error. If hit', ' then two new drop\nreasons were added in the proposal', ' that is SKB_DROP_REASON_TC_INGRESS_ERROR\nas well as SKB_DROP_REASON_TC_EGRESS_ERROR. Further analysis of the actual\nerror codes would have required to attach to tcf_classify via kprobe/kretprobe\nto more deeply debug skb and the returned error.\n\nIn order to make the kfree_skb_reason() in sch_handle_{ingress', 'egress}() more\nextensible', ' it can be addressed in a more straight forward way', ' that is: Instead\nof placing the verdict into struct tcf_result', ' we can just put the drop reason\nin there', ' which does not require changes throughout various classful schedulers\ngiven the existing verdict logic can stay as is.\n\nThen', ' SKB_DROP_REASON_TC_ERROR{', '_*} can be added to the enum skb_drop_reason\nto disambiguate between an error or an intentional drop. New drop reason error\ncodes can be added successively to the tc code base.\n\nFor internal error locations which have not yet been annotated with a\nSKB_DROP_REASON_TC_ERROR{', '_*}', ' the fallback is SKB_DROP_REASON_TC_INGRESS and\nSKB_DROP_REASON_TC_EGRESS', ' respectively. Generic errors could be marked with a\nSKB_DROP_REASON_TC_ERROR code until they are converted to more specific ones\nif it is found that they would be useful for troubleshooting.\n\nWhile drop reasons have infrastructure for subsystem specific error codes which\nare currently used by mac80211 and ovs', ' Jakub mentioned that it is preferred\nfor tc to use the enum skb_drop_reason core codes given it is a better fit and\ncurrently the tooling support is better', "" too.\n\nWith regards to the latter:\n\n [...] I think Alastair (bpftrace) is working on auto-prettifying enums when\n bpftrace outputs maps. So we can do something like:\n\n $ bpftrace -e 'tracepoint:skb:kfree_skb { @[args->reason] = count(); }'\n Attaching 1 probe...\n ^C\n\n @[SKB_DROP_REASON_TC_INGRESS]: 2\n @[SKB_CONSUMED]: 34\n\n ^^^^^^^^^^^^ names!!\n\n Auto-magically. [...]\n\nAdd a small helper tcf_set_drop_reason() which can be used to set the drop reason\ninto the tcf_result.\n\nSigned-off-by: Daniel Borkmann \nCc: Jamal Hadi Salim \nCc: Victor Nogueira \nLink: https://lore.kernel.org/netdev/20231006063233.74345d36@kernel.org\nReviewed-by: Jakub Kicinski \nLink: https://lore.kernel.org/r/20231009092655.22025-1-daniel@iogearbox.net\nSigned-off-by: Jakub Kicinski \n"", '']",Refactor tc-related drop reasons for increased flexibility in network scheduling.,tc drop flexible,It's a cleanup or refactoring in the code.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['tc/netfilter like programs'] +99c9991f4e5d77328187187d0c921a3b62bfa998,99c9991f4e5d77328187187d0c921a3b62bfa998,Daniel Borkmann,daniel@iogearbox.net,1697456958,Daniel Borkmann,daniel@iogearbox.net,1697456981,d014e32adee15b58cb3d80b86c39d4cb09c90a7d,0e10fd4b7a6dd03cf6d1da293d5d50082917f0e0 1a8a315f008a58f54fecb012b928aa6a494435b3,"Merge branch 'bpf-log-improvements' + +Andrii Nakryiko says: + +==================== +This patch set fixes ambiguity in BPF verifier log output of SCALAR register +in the parts that emit umin/umax", smin/smax,"[' etc ranges. See patch #4 for\ndetails.\n\nAlso', "" patch #5 fixes an issue with verifier log missing instruction context\n(state) output for conditionals that trigger precision marking. See details in\nthe patch.\n\nFirst two patches are just improvements to two selftests that are very flaky\nlocally when run in parallel mode.\n\nPatch #3 changes 'align' selftest to be less strict about exact verifier log\noutput (which patch #4 changes"", ' breaking lots of align tests as written). Now\ntest does more of a register substate checks', "" mostly around expected var_off()\nvalues. This 'align' selftests is one of the more brittle ones and requires\nconstant adjustment when verifier log output changes"", ' without really catching\nany new issues. So hopefully these changes can minimize future support efforts\nfor this specific set of tests.\n====================\n\nSigned-off-by: Daniel Borkmann \n', '']",Improves BPF verifier log output for scalar register to fix umin/umax ambiguity.,"BPF verifier, log, scalar",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +1a8a315f008a58f54fecb012b928aa6a494435b3,1a8a315f008a58f54fecb012b928aa6a494435b3,Andrii Nakryiko,andrii@kernel.org,1697063848,Daniel Borkmann,daniel@iogearbox.net,1697456958,d014e32adee15b58cb3d80b86c39d4cb09c90a7d,72f8a1de4a7ecb23393a920dface58d5a96f42d8,"bpf: Ensure proper register state printing for cond jumps + +Verifier emits relevant register state involved in any given instruction +next to it after `;` to the right", if possible. Or,"[' worst case', ' on the\nseparate line repeating instruction index.\n\nE.g.', ' a nice and simple case would be:\n\n 2: (d5) if r0 s<= 0x0 goto pc+1 ; R0_w=0\n\nBut if there is some intervening extra output (e.g.', ' precision\nbacktracking log) involved', ' we are supposed to see the state after the\nprecision backtrack log:\n\n 4: (75) if r0 s>= 0x0 goto pc+1\n mark_precise: frame0: last_idx 4 first_idx 0 subseq_idx -1\n mark_precise: frame0: regs=r0 stack= before 2: (d5) if r0 s<= 0x0 goto pc+1\n mark_precise: frame0: regs=r0 stack= before 1: (b7) r0 = 0\n 6: R0_w=0\n\nFirst off', ' note that in `6: R0_w=0` instruction index corresponds to the\nnext instruction', ' not to the conditional jump instruction itself', "" which\nis wrong and we'll get to that.\n\nBut besides that"", ' the above is a happy case that does work today. Yet', '\nif it so happens that precision backtracking had to traverse some of the\nparent states', ' this `6: R0_w=0` state output would be missing.\n\nThis is due to a quirk of print_verifier_state() routine', ' which performs\nmark_verifier_state_clean(env) at the end. This marks all registers as\n""non-scratched""', ' which means that subsequent logic to print *relevant*\nregisters (that is', ' ""scratched ones"") fails and doesn\'t see anything\nrelevant to print and skips the output altogether.\n\nprint_verifier_state() is used both to print instruction context', ' but\nalso to print an **entire** verifier state indiscriminately', ' e.g.', '\nduring precision backtracking (and in a few other situations', ' like\nduring entering or exiting subprogram). Which means if we have to print\nentire parent state before getting to printing instruction context\nstate', ' instruction context is marked as clean and is omitted.\n\nLong story short', ' this is definitely not intentional. So we fix this\nbehavior in this patch by teaching print_verifier_state() to clear\nscratch state only if it was used to print instruction state', ' not the\nparent/callback state. This is determined by print_all option', "" so if\nit's not set"", "" we don't clear scratch state. This fixes missing\ninstruction state for these cases.\n\nAs for the mismatched instruction index"", ' we fix that by making sure we\ncall print_insn_state() early inside check_cond_jmp_op() before we\nadjusted insn_idx based on jump branch taken logic. And with that we get\ndesired correct information:\n\n 9: (16) if w4 == 0x1 goto pc+9\n mark_precise: frame0: last_idx 9 first_idx 9 subseq_idx -1\n mark_precise: frame0: parent state regs=r4 stack=: R2_w=1944 R4_rw=P1 R10=fp0\n mark_precise: frame0: last_idx 8 first_idx 0 subseq_idx 9\n mark_precise: frame0: regs=r4 stack= before 8: (66) if w4 s> 0x3 goto pc+5\n mark_precise: frame0: regs=r4 stack= before 7: (b7) r4 = 1\n 9: R4=1\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: John Fastabend \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20231011223728.3188086-6-andrii@kernel.org\n', '']",Ensure correct register state printing for conditional jumps in the eBPF verifier.,"register, verifier, cond jumps",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +72f8a1de4a7ecb23393a920dface58d5a96f42d8,72f8a1de4a7ecb23393a920dface58d5a96f42d8,Andrii Nakryiko,andrii@kernel.org,1697063847,Daniel Borkmann,daniel@iogearbox.net,1697456958,b730458fbe6bbbdc115084173c05a75e00b835d4,cde785142885e1fc62a9ae92e7aae90285ed3d79,"bpf: Disambiguate SCALAR register state output in verifier logs + +Currently the way that verifier prints SCALAR_VALUE register state (and +PTR_TO_PACKET"," which can have var_off and ranges info as well) is very +ambiguous. + +In the name of brevity we are trying to eliminate ""unnecessary"" output +of umin/umax","[' smin/smax', ' u32_min/u32_max', ' and s32_min/s32_max values', ' if\npossible. Current rules are that if any of those have their default\nvalue (which for mins is the minimal value of its respective types: 0', '\nS32_MIN', ' or S64_MIN', "" while for maxs it's U32_MAX"", ' S32_MAX', ' S64_MAX', ' or\nU64_MAX) *OR* if there is another min/max value that as matching value.\nE.g.', ' if smin=100 and umin=100', "" we'll emit only umin=10"", ' omitting smin\naltogether. This approach has a few problems', ' being both ambiguous and\nsort-of incorrect in some cases.\n\nAmbiguity is due to missing value could be either default value or value\nof umin/umax or smin/smax. This is especially confusing when we mix\nsigned and unsigned ranges. Quite often', ' umin=0 and smin=0', "" and so we'll\nhave only `umin=0` leaving anyone reading verifier log to guess whether\nsmin is actually 0 or it's actually -9223372036854775808 (S64_MIN). And\noften times it's important to know"", ' especially when debugging tricky\nissues.\n\n""Sort-of incorrectness"" comes from mixing negative and positive values.\nE.g.', ' if umin is some large positive number', ' it can be equal to smin\nwhich is', ' interpreted as signed value', ' is actually some negative value.\nCurrently', ' that smin will be omitted and only umin will be emitted with\na large positive value', ' giving an impression that smin is also positive.\n\nAnyway', ' ambiguity is the biggest issue making it impossible to have an\nexact understanding of register state', ' preventing any sort of automated\ntesting of verifier state based on verifier log. This patch is\nattempting to rectify the situation by removing ambiguity', ' while\nminimizing the verboseness of register state output.\n\nThe rules are straightforward:\n - if some of the values are missing', ' then it definitely has a default\n value. I.e.', ' `umin=0` means that umin is zero', ' but smin is actually\n S64_MIN;\n - all the various boundaries that happen to have the same value are\n emitted in one equality separated sequence. E.g.', ' if umin and smin are\n both 100', "" we'll emit `smin=umin=100`"", ' making this explicit;\n - we do not mix negative and positive values together', ' and even if\n they happen to have the same bit-level value', ' they will be emitted\n separately with proper sign. I.e.', ' if both umax and smax happen to be\n 0xffffffffffffffff', "" we'll emit them both separately as\n `smax=-1"", 'umax=18446744073709551615`;\n - in the name of a bit more uniformity and consistency', '\n {u32', 's32}_{min', 'max} are renamed to {s', 'u}{min', 'max}32', ' which seems to\n improve readability.\n\nThe above means that in case of all 4 ranges being', ' say', ' [50', ' 100] range', ""\nwe'd previously see hugely ambiguous:\n\n R1=scalar(umin=50"", 'umax=100)\n\nNow', "" we'll be more explicit:\n\n R1=scalar(smin=umin=smin32=umin32=50"", 'smax=umax=smax32=umax32=100)\n\nThis is slightly more verbose', "" but distinct from the case when we don't\nknow anything about signed boundaries and 32-bit boundaries"", ' which under\nnew rules will match the old case:\n\n R1=scalar(umin=50', 'umax=100)\n\nAlso', ' in the name of simplicity of implementation and consistency', ' order\nfor {s', 'u}32_{min', 'max} are emitted *before* var_off. Previously they were\nemitted afterwards', ' for unclear reasons.\n\nThis patch also includes a few fixes to selftests that expect exact\nregister state to accommodate slight changes to verifier format. You can\nsee that the changes are pretty minimal in common cases.\n\nNote', "" the special case when SCALAR_VALUE register is a known constant\nisn't changed"", "" we'll emit constant value once"", ' interpreted as signed\nvalue.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: John Fastabend \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20231011223728.3188086-5-andrii@kernel.org\n', '']",Improve the clarity of SCALAR register state outputs in bpf verifier logs.,"verifier, SCALAR, disambiguate",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF verifier,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +cde785142885e1fc62a9ae92e7aae90285ed3d79,cde785142885e1fc62a9ae92e7aae90285ed3d79,Andrii Nakryiko,andrii@kernel.org,1697063846,Daniel Borkmann,daniel@iogearbox.net,1697456958,76e6915d8e60cff8dde4f818c88c23fd6e632712,08a7078feacf419305d86d36b974c48347f3abb0,"selftests/bpf: Make align selftests more robust + +Align subtest is very specific and finicky about expected verifier log +output and format. This is often completely unnecessary as in a bunch of +situations test actually cares about var_off part of register state. But +given how exact it is right now"," any tiny verifier log changes can lead +to align tests failures","[' requiring constant adjustment.\n\nThis patch tries to make this a bit more robust by making logic first\nsearch for specified register and then allowing to match only portion of\nregister state', ' not everything exactly. This will come handly with\nfollow up changes to SCALAR register output disambiguation.\n\nSigned-off-by: Andrii Nakryiko \nSigned-off-by: Daniel Borkmann \nAcked-by: John Fastabend \nAcked-by: Eduard Zingerman \nLink: https://lore.kernel.org/bpf/20231011223728.3188086-4-andrii@kernel.org\n', '']",Improves robustness of align selftests by focusing on var_off part of register state in verifier logs.,"selftests, align, verifier",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +08a7078feacf419305d86d36b974c48347f3abb0,08a7078feacf419305d86d36b974c48347f3abb0,Andrii Nakryiko,andrii@kernel.org,1697063845,Daniel Borkmann,daniel@iogearbox.net,1697456958,c881e184693c4e36f3bd40fee50138a1b21bff77,2d78928c9cf7bee08c3e2344e6e1755412855448,"selftests/bpf: Improve missed_kprobe_recursion test robustness + +Given missed_kprobe_recursion is non-serial and uses common testing +kfuncs to count number of recursion misses it's possible that some other +parallel test can trigger extraneous recursion misses. So we can't +expect exactly 1 miss. Relax conditions and expect at least one. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: Jiri Olsa +Acked-by: John Fastabend +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231011223728.3188086-3-andrii@kernel.org +",,Improves robustness of missed_kprobe_recursion test by relaxing conditions on recursion misses.,"robustness,test,recursion",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,['kprobe/uprobe/ftrace like programs'] +2d78928c9cf7bee08c3e2344e6e1755412855448,2d78928c9cf7bee08c3e2344e6e1755412855448,Andrii Nakryiko,andrii@kernel.org,1697063844,Daniel Borkmann,daniel@iogearbox.net,1697456958,d94e87cd0f8b942aabce0c87eff573704774dd01,0e10fd4b7a6dd03cf6d1da293d5d50082917f0e0,"selftests/bpf: Improve percpu_alloc test robustness + +Make these non-serial tests filter BPF programs by intended PID of +a test runner process. This makes it isolated from other parallel tests +that might interfere accidentally. + +Signed-off-by: Andrii Nakryiko +Signed-off-by: Daniel Borkmann +Acked-by: John Fastabend +Acked-by: Eduard Zingerman +Link: https://lore.kernel.org/bpf/20231011223728.3188086-2-andrii@kernel.org +",,The commit improves robustness of the percpu_alloc test by isolating BPF programs using intended PID to avoid interference.,"percpu_alloc, BPF programs, robustness",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +0e10fd4b7a6dd03cf6d1da293d5d50082917f0e0,0e10fd4b7a6dd03cf6d1da293d5d50082917f0e0,Andrii Nakryiko,andrii@kernel.org,1697237339,Andrii Nakryiko,andrii@kernel.org,1697237369,f8e5d4265acfb8d1a0d074ca8188cbd8e86c4105,ba8ea72388a192c10f1ee5f5a4a32332e7cced76 e0e1a7a5fc377d54bd792c6368a375d41fc316ef,"Merge branch 'Open-coded task_vma iter' + +Dave Marchevsky says: + +==================== +At Meta we have a profiling daemon which periodically collects +information on many hosts. This collection usually involves grabbing +stacks (user and kernel) using perf_event BPF progs and later symbolicating +them. For user stacks we try to use BPF_F_USER_BUILD_ID and rely on +remote symbolication"," but BPF_F_USER_BUILD_ID doesn't always succeed. In +those cases we must fall back to digging around in /proc/PID/maps to map +virtual address to (binary","[' offset). The /proc/PID/maps digging does not\noccur synchronously with stack collection', ' so the process might already\nbe gone', "" in which case it won't have /proc/PID/maps and we will fail to\nsymbolicate.\n\nThis 'exited process problem' doesn't occur very often as\nmost of the prod services we care to profile are long-lived daemons"", ' but\nthere are enough usecases to warrant a workaround: a BPF program which\ncan be optionally loaded at data collection time and essentially walks\n/proc/PID/maps. Currently this is done by walking the vma list:\n\n struct vm_area_struct* mmap = BPF_CORE_READ(mm', ' mmap);\n mmap_next = BPF_CORE_READ(rmap', ' vm_next); /* in a loop */\n\nSince commit 763ecb035029 (""mm: remove the vma linked list"") there\'s no\nlonger a vma linked list to walk. Walking the vma maple tree is not as\nsimple as hopping struct vm_area_struct->vm_next. Luckily', '\ncommit f39af05949a4 (""mm: add VMA iterator"")', ' another commit in that series', '\nadded struct vma_iterator and for_each_vma macro for easy vma iteration. If\nsimilar functionality was exposed to BPF programs', ' it would be perfect for our\nusecase.\n\nThis series adds such functionality', ' specifically a BPF equivalent of\nfor_each_vma using the open-coded iterator style.\n\nNotes:\n * This approach was chosen after discussion on a previous series [0] which\n attempted to solve the same problem by adding a BPF_F_VMA_NEXT flag to\n bpf_find_vma.\n * Unlike the task_vma bpf_iter', "" the open-coded iterator kfuncs here do not\n drop the vma read lock between iterations. See Alexei's response in [0].\n * The [vsyscall] page isn't really part of task->mm's vmas"", ' but\n /proc/PID/maps returns information about it anyways. The vma iter added\n here does not do the same. See comment on selftest in patch 3.\n * bpf_iter_task_vma allocates a _data struct which contains - among other\n things - struct vma_iterator', ' using BPF allocator and keeps a pointer to\n the bpf_iter_task_vma_data. This is done in order to prevent changes to\n struct ma_state - which is wrapped by struct vma_iterator - from\n necessitating changes to uapi struct bpf_iter_task_vma.\n\nChangelog:\n\nv6 -> v7: https://lore.kernel.org/bpf/20231010185944.3888849-1-davemarchevsky@fb.com/\n\nPatch numbers correspond to their position in v6\n\nPatch 2 (""selftests/bpf: Rename bpf_iter_task_vma.c to bpf_iter_task_vmas.c"")\n * Add Andrii ack\nPatch 3 (""bpf: Introduce task_vma open-coded iterator kfuncs"")\n * Add Andrii ack\n * Add missing __diag_ignore_all for -Wmissing-prototypes (Song)\nPatch 4 (""selftests/bpf: Add tests for open-coded task_vma iter"")\n * Remove two unnecessary header includes (Andrii)\n * Remove extraneous !vmas_seen check (Andrii)\nNew Patch (""bpf: Add BPF_KFUNC_{START', 'END}_defs macros"")\n * After talking to Andrii', ' this is an attempt to clean up __diag_ignore_all\n spam everywhere kfuncs are defined. If nontrivial changes are needed', '\n let\'s apply the other 4 and I\'ll respin as a standalone patch.\n\nv5 -> v6: https://lore.kernel.org/bpf/20231010175637.3405682-1-davemarchevsky@fb.com/\n\nPatch 4 (""selftests/bpf: Add tests for open-coded task_vma iter"")\n * Remove extraneous blank line. I did this manually to the .patch file\n for v5', ' which caused BPF CI to complain about failing to apply the\n series\n\nv4 -> v5: https://lore.kernel.org/bpf/20231002195341.2940874-1-davemarchevsky@fb.com/\n\nPatch numbers correspond to their position in v4\n\nNew Patch (""selftests/bpf: Rename bpf_iter_task_vma.c to bpf_iter_task_vmas.c"")\n * Patch 2\'s renaming of this selftest', ' and associated changes in the\n userspace runner', ' are split out into this separate commit (Andrii)\n\nPatch 2 (""bpf: Introduce task_vma open-coded iterator kfuncs"")\n * Remove bpf_iter_task_vma kfuncs from libbpf\'s bpf_helpers.h', ' they\'ll be\n added to selftests\' bpf_experimental.h in selftests patch below (Andrii)\n * Split bpf_iter_task_vma.c renaming into separate commit (Andrii)\n\nPatch 3 (""selftests/bpf: Add tests for open-coded task_vma iter"")\n * Add bpf_iter_task_vma kfuncs to bpf_experimental.h (Andrii)\n * Remove \'?\' from prog SEC', ' open_and_load the skel in one operation (Andrii)\n * Ensure that fclose() always happens in test runner (Andrii)\n * Use global var w/ 1000 (vm_start', ' vm_end) structs instead of two\n MAP_TYPE_ARRAY\'s w/ 1k u64s each (Andrii)\n\nv3 -> v4: https://lore.kernel.org/bpf/20230822050558.2937659-1-davemarchevsky@fb.com/\n\nPatch 1 (""bpf: Don\'t explicitly emit BTF for struct btf_iter_num"")\n * Add Andrii ack\nPatch 2 (""bpf: Introduce task_vma open-coded iterator kfuncs"")\n * Mark bpf_iter_task_vma_new args KF_RCU and remove now-unnecessary !task\n check (Yonghong)\n * Although KF_RCU is a function-level flag', ' in reality it only applies to\n the task_struct *task parameter', ' as the other two params are a scalar int\n and a specially-handled KF_ARG_PTR_TO_ITER\n * Remove struct bpf_iter_task_vma definition from uapi headers', ' define in\n kernel/bpf/task_iter.c instead (Andrii)\nPatch 3 (""selftests/bpf: Add tests for open-coded task_vma iter"")\n * Use a local var when looping over vmas to track map idx. Update vmas_seen\n global after done iterating. Don\'t start iterating or update vmas_seen if\n vmas_seen global is nonzero. (Andrii)\n * Move getpgid() call to correct spot - above skel detach. (Andrii)\n\nv2 -> v3: https://lore.kernel.org/bpf/20230821173415.1970776-1-davemarchevsky@fb.com/\n\nPatch 1 (""bpf: Don\'t explicitly emit BTF for struct btf_iter_num"")\n * Add Yonghong ack\n\nPatch 2 (""bpf: Introduce task_vma open-coded iterator kfuncs"")\n * UAPI bpf header and tools/ version should match\n * Add bpf_iter_task_vma_kern_data which bpf_iter_task_vma_kern points to', ""\n bpf_mem_alloc/free it instead of just vma_iterator. (Alexei)\n * Inner data ptr == NULL implies initialization failed\n\nv1 -> v2: https://lore.kernel.org/bpf/20230810183513.684836-1-davemarchevsky@fb.com/\n * Patch 1\n * Now removes the unnecessary BTF_TYPE_EMIT instead of changing the\n type (Yonghong)\n * Patch 2\n * Don't do unnecessary BTF_TYPE_EMIT (Yonghong)\n * Bump task refcount to prevent ->mm reuse (Yonghong)\n * Keep a pointer to vma_iterator in bpf_iter_task_vma"", ' alloc/free\n via BPF mem allocator (Yonghong', ' Stanislav)\n * Patch 3\n\n [0]: https://lore.kernel.org/bpf/20230801145414.418145-1-davemarchevsky@fb.com/\n====================\n\nSigned-off-by: Andrii Nakryiko \n', '']",Integration of 'Open-coded task_vma iter' for improved profiling with perf_event BPF programs.,"profiling, perf_event, task_vma",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['profile like programs'] +e0e1a7a5fc377d54bd792c6368a375d41fc316ef,e0e1a7a5fc377d54bd792c6368a375d41fc316ef,Dave Marchevsky,davemarchevsky@fb.com,1697229865,Andrii Nakryiko,andrii@kernel.org,1697237338,f8e5d4265acfb8d1a0d074ca8188cbd8e86c4105,4ac4546821584736798aaa9e97da9f6eaf689ea3,"selftests/bpf: Add tests for open-coded task_vma iter + +The open-coded task_vma iter added earlier in this series allows for +natural iteration over a task's vmas using existing open-coded iter +infrastructure"," specifically bpf_for_each. + +This patch adds a test demonstrating this pattern and validating +correctness. The vma->vm_start and vma->vm_end addresses of the first +1000 vmas are recorded and compared to /proc/PID/maps output. As +expected","[' both see the same vmas and addresses - with the exception of\nthe [vsyscall] vma - which is explained in a comment in the prog_tests\nprogram.\n\nSigned-off-by: Dave Marchevsky \nSigned-off-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231013204426.1074286-5-davemarchevsky@fb.com\n', '']",This commit adds tests for open-coded task_vma iterator in selftests/bpf.,"task_vma, iterator, selftests",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['tracepoints like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +4ac4546821584736798aaa9e97da9f6eaf689ea3,4ac4546821584736798aaa9e97da9f6eaf689ea3,Dave Marchevsky,davemarchevsky@fb.com,1697229864,Andrii Nakryiko,andrii@kernel.org,1697237338,afa500eeb71da22784f72b1caa74a3b47dc35319,45b38941c81f16bb2e9b0115f03e164a3576ea8b,"bpf: Introduce task_vma open-coded iterator kfuncs + +This patch adds kfuncs bpf_iter_task_vma_{new",next,"[""destroy} which allow\ncreation and manipulation of struct bpf_iter_task_vma in open-coded\niterator style. BPF programs can use these kfuncs directly or through\nbpf_for_each macro for natural-looking iteration of all task vmas.\n\nThe implementation borrows heavily from bpf_find_vma helper's locking -\ndiffering only in that it holds the mmap_read lock for all iterations\nwhile the helper only executes its provided callback on a maximum of 1\nvma. Aside from locking"", ' struct vma_iterator and vma_next do all the\nheavy lifting.\n\nA pointer to an inner data struct', ' struct bpf_iter_task_vma_data', ' is the\nonly field in struct bpf_iter_task_vma. This is because the inner data\nstruct contains a struct vma_iterator (not ptr)', "" whose size is likely to\nchange under us. If bpf_iter_task_vma_kern contained vma_iterator directly\nsuch a change would require change in opaque bpf_iter_task_vma struct's\nsize. So better to allocate vma_iterator using BPF allocator"", ' and since\nthat alloc must already succeed', ' might as well allocate all iter fields', '\nthereby freezing struct bpf_iter_task_vma size.\n\nSigned-off-by: Dave Marchevsky \nSigned-off-by: Andrii Nakryiko \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231013204426.1074286-4-davemarchevsky@fb.com\n', '']",Introduces task_vma open-coded iterator kernel functions for BPF.,"task_vma, iterator, kfuncs",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,['other'] +45b38941c81f16bb2e9b0115f03e164a3576ea8b,45b38941c81f16bb2e9b0115f03e164a3576ea8b,Dave Marchevsky,davemarchevsky@fb.com,1697229863,Andrii Nakryiko,andrii@kernel.org,1697237338,a34707d943d092d59b5be69f83e88add89bc27f9,f10ca5da5bd71e5cefed7995e75a7c873ce3816e,"selftests/bpf: Rename bpf_iter_task_vma.c to bpf_iter_task_vmas.c + +Further patches in this series will add a struct bpf_iter_task_vma"," +which will result in a name collision with the selftest prog renamed in +this patch. Rename the selftest to avoid the collision. + +Signed-off-by: Dave Marchevsky +Signed-off-by: Andrii Nakryiko +Acked-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/20231013204426.1074286-3-davemarchevsky@fb.com +",[''],Rename bpf_iter_task_vma.c to bpf_iter_task_vmas.c to avoid name collision with future patches in selftests.,"rename,selftests,collision",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +f10ca5da5bd71e5cefed7995e75a7c873ce3816e,f10ca5da5bd71e5cefed7995e75a7c873ce3816e,Dave Marchevsky,davemarchevsky@fb.com,1697229862,Andrii Nakryiko,andrii@kernel.org,1697237338,4c7ea8cb4ca5de5d5dab49142931fc55b0794e33,ba8ea72388a192c10f1ee5f5a4a32332e7cced76,"bpf: Don't explicitly emit BTF for struct btf_iter_num + +Commit 6018e1f407cc (""bpf: implement numbers iterator"") added the +BTF_TYPE_EMIT line that this patch is modifying. The struct btf_iter_num +doesn't exist"," so only a forward declaration is emitted in BTF: + + FWD 'btf_iter_num' fwd_kind=struct + +That commit was probably hoping to ensure that struct bpf_iter_num is +emitted in vmlinux BTF. A previous version of this patch changed the +line to emit the correct type","[' but Yonghong confirmed that it would\ndefinitely be emitted regardless in [0]', ' so this patch simply removes\nthe line.\n\nThis isn\'t marked ""Fixes"" because the extraneous btf_iter_num FWD wasn\'t\ncausing any issues that I noticed', ' aside from mild confusion when I\nlooked through the code.\n\n [0]: https://lore.kernel.org/bpf/25d08207-43e6-36a8-5e0f-47a913d4cda5@linux.dev/\n\nSigned-off-by: Dave Marchevsky \nSigned-off-by: Andrii Nakryiko \nAcked-by: Yonghong Song \nAcked-by: Andrii Nakryiko \nLink: https://lore.kernel.org/bpf/20231013204426.1074286-2-davemarchevsky@fb.com\n', '']",The commit modifies BTF emission for struct btf_iter_num to only emit a forward declaration.,"BTF, emit, forward declaration",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The BPF Type Format (BTF),"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +ba8ea72388a192c10f1ee5f5a4a32332e7cced76,ba8ea72388a192c10f1ee5f5a4a32332e7cced76,Artem Savkov,asavkov@redhat.com,1697175739,Andrii Nakryiko,andrii@kernel.org,1697225976,f6b556d3e5fb7351d63c793c75e30def44909994,9c1292eca243821249fa99f40175b0660d9329e3,"bpf: Change syscall_nr type to int in struct syscall_tp_t + +linux-rt-devel tree contains a patch (b1773eac3f29c (""sched: Add support +for lazy preemption"")) that adds an extra member to struct trace_entry. +This causes the offset of args field in struct trace_event_raw_sys_enter +be different from the one in struct syscall_trace_enter: + +struct trace_event_raw_sys_enter { + struct trace_entry ent; /* 0 12 */ + + /* XXX last struct has 3 bytes of padding */ + /* XXX 4 bytes hole"," try to pack */ + + long int id; /* 16 8 */ + long unsigned int args[6]; /* 24 48 */ + /* --- cacheline 1 boundary (64 bytes) was 8 bytes ago --- */ + char __data[]; /* 72 0 */ + + /* size: 72","[' cachelines: 2', ' members: 4 */\n /* sum members: 68', ' holes: 1', ' sum holes: 4 */\n /* paddings: 1', ' sum paddings: 3 */\n /* last cacheline: 8 bytes */\n};\n\nstruct syscall_trace_enter {\n struct trace_entry ent; /* 0 12 */\n\n /* XXX last struct has 3 bytes of padding */\n\n int nr; /* 12 4 */\n long unsigned int args[]; /* 16 0 */\n\n /* size: 16', ' cachelines: 1', ' members: 3 */\n /* paddings: 1', ' sum paddings: 3 */\n /* last cacheline: 16 bytes */\n};\n\nThis', ' in turn', ' causes perf_event_set_bpf_prog() fail while running bpf\ntest_profiler testcase because max_ctx_offset is calculated based on the\nformer struct', ' while off on the latter:\n\n 10488 if (is_tracepoint || is_syscall_tp) {\n 10489 int off = trace_event_get_offsets(event->tp_event);\n 10490\n 10491 if (prog->aux->max_ctx_offset > off)\n 10492 return -EACCES;\n 10493 }\n\nWhat bpf program is actually getting is a pointer to struct\nsyscall_tp_t', ' defined in kernel/trace/trace_syscalls.c. This patch fixes\nthe problem by aligning struct syscall_tp_t with struct\nsyscall_trace_(enter|exit) and changing the tests to use these structs\nto dereference context.\n\nSigned-off-by: Artem Savkov \nSigned-off-by: Andrii Nakryiko \nAcked-by: Steven Rostedt (Google) \nLink: https://lore.kernel.org/bpf/20231013054219.172920-1-asavkov@redhat.com\n', '']",The commit changes the syscall_nr type to int in struct syscall_tp_t to ensure compatibility with trace_event_raw_sys_enter.,"syscall_nr,type,trace_event",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The syscall interface,"[""It's not related to any of the above.""]" +9c1292eca243821249fa99f40175b0660d9329e3,9c1292eca243821249fa99f40175b0660d9329e3,Martin KaFai Lau,martin.lau@kernel.org,1697223422,Andrii Nakryiko,andrii@kernel.org,1697225743,64e64477ba943941f8cf56e3dd7962e6c30f54ed,236334aeec0f93217cf9235f2004e61a0a1a5985,"net/bpf: Avoid unused ""sin_addr_len"" warning when CONFIG_CGROUP_BPF is not set + +It was reported that there is a compiler warning on the unused variable +""sin_addr_len"" in af_inet.c when CONFIG_CGROUP_BPF is not set. +This patch is to address it similar to the ipv6 counterpart +in inet6_getname(). It is to ""return sin_addr_len;"" +instead of ""return sizeof(*sin);"". + +Fixes: fefba7d1ae19 (""bpf: Propagate modified uaddrlen from cgroup sockaddr programs"") +Reported-by: Stephen Rothwell +Signed-off-by: Martin KaFai Lau +Signed-off-by: Andrii Nakryiko +Reviewed-by: Kuniyuki Iwashima +Link: https://lore.kernel.org/bpf/20231013185702.3993710-1-martin.lau@linux.dev + +Closes: https://lore.kernel.org/bpf/20231013114007.2fb09691@canb.auug.org.au/ +",,Fixes unused variable warning in net/bpf related to CONFIG_CGROUP_BPF.,"warning, sin_addr_len, CONFIG_CGROUP_BPF",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The eBPF maps,['cgroup like programs'] +236334aeec0f93217cf9235f2004e61a0a1a5985,236334aeec0f93217cf9235f2004e61a0a1a5985,Yafang Shao,laoar.shao@gmail.com,1697186356,Andrii Nakryiko,andrii@kernel.org,1697225601,2752c8b15edaa537be81e3beca7460a9eb0222c0,d2dc885b8c9ddb6fc374d93a87f8f2d1b97d2caf,"bpf: Avoid unnecessary audit log for CPU security mitigations + +Check cpu_mitigations_off() first to avoid calling capable() if it is off. +This can avoid unnecessary audit log. + +Fixes: bc5bc309db45 (""bpf: Inherit system settings for CPU security mitigations"") +Suggested-by: Andrii Nakryiko +Signed-off-by: Yafang Shao +Signed-off-by: Andrii Nakryiko +Link: https://lore.kernel.org/bpf/CAEf4Bza6UVUWqcWQ-66weZ-nMDr+TFU3Mtq=dumZFD-pSqU7Ow@mail.gmail.com/ +Link: https://lore.kernel.org/bpf/20231013083916.4199-1-laoar.shao@gmail.com +",,This commit prevents unnecessary audit logs by checking cpu_mitigations_off() before calling capable() for CPU security mitigations.,"audit log, CPU security, mitigations",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +0e6bb5b7f4c8e6665e76bdafce37ad4a8daf83c5,0e6bb5b7f4c8e6665e76bdafce37ad4a8daf83c5,Jakub Kicinski,kuba@kernel.org,1697152666,Jakub Kicinski,kuba@kernel.org,1697155654,6f71fc5628f01bcf9d2dc6eceb3000ee4e73c79a,2f0968a030f2a5dd4897a0151c8395bf5babe5b0 e8c127b0576660da9195504fe8393fe9da3de9ce,"Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Cross-merge networking fixes after downstream PR. + +No conflicts. + +Adjacent changes: + +kernel/bpf/verifier.c + 829955981c55 (""bpf: Fix verifier log for async callback return values"") + a923819fb2c5 (""bpf: Treat first argument as return value for bpf_throw"") + +Signed-off-by: Jakub Kicinski +",,Merge networking fixes from upstream into the current branch without conflicts.,"networking, fixes, merge",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +e8c127b0576660da9195504fe8393fe9da3de9ce,e8c127b0576660da9195504fe8393fe9da3de9ce,Linus Torvalds,torvalds@linux-foundation.org,1697141220,Linus Torvalds,torvalds@linux-foundation.org,1697141220,bcd572a15b68db3e1639d2298703aed23d123d1a,9a5a14948574ee09f339990cab69b4ab997d2f7d b91e8403373cab79375a65f5cf3495e2cd0bbdfa,"Merge tag 'net-6.6-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net + +Pull networking fixes from Paolo Abeni: + ""Including fixes from CAN and BPF. + + We have a regression in TC currently under investigation"," otherwise + the things that stand off most are probably the TCP and AF_PACKET + fixes","[' with both issues coming from 6.5.\n\n Previous releases - regressions:\n\n - af_packet: fix fortified memcpy() without flex array.\n\n - tcp: fix crashes trying to free half-baked MTU probes\n\n - xdp: fix zero-size allocation warning in xskq_create()\n\n - can: sja1000: always restart the tx queue after an overrun\n\n - eth: mlx5e: again mutually exclude RX-FCS and RX-port-timestamp\n\n - eth: nfp: avoid rmmod nfp crash issues\n\n - eth: octeontx2-pf: fix page pool frag allocation warning\n\n Previous releases - always broken:\n\n - mctp: perform route lookups under a RCU read-side lock\n\n - bpf: s390: fix clobbering the caller\'s backchain in the trampoline\n\n - phy: lynx-28g: cancel the CDR check work item on the remove path\n\n - dsa: qca8k: fix qca8k driver for Turris 1.x\n\n - eth: ravb: fix use-after-free issue in ravb_tx_timeout_work()\n\n - eth: ixgbe: fix crash with empty VF macvlan list""\n\n* tag \'net-6.6-rc6\' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (54 commits)\n rswitch: Fix imbalance phy_power_off() calling\n rswitch: Fix renesas_eth_sw_remove() implementation\n octeontx2-pf: Fix page pool frag allocation warning\n nfc: nci: assert requested protocol is valid\n af_packet: Fix fortified memcpy() without flex array.\n net: tcp: fix crashes trying to free half-baked MTU probes\n net/smc: Fix pos miscalculation in statistics\n nfp: flower: avoid rmmod nfp crash issues\n net: usb: dm9601: fix uninitialized variable use in dm9601_mdio_read\n ethtool: Fix mod state of verbose no_mask bitset\n net: nfc: fix races in nfc_llcp_sock_get() and nfc_llcp_sock_get_sn()\n mctp: perform route lookups under a RCU read-side lock\n net: skbuff: fix kernel-doc typos\n s390/bpf: Fix unwinding past the trampoline\n s390/bpf: Fix clobbering the caller\'s backchain in the trampoline\n net/mlx5e: Again mutually exclude RX-FCS and RX-port-timestamp\n net/smc: Fix dependency of SMC on ISM\n ixgbe: fix crash with empty VF macvlan list\n net/mlx5e: macsec: use update_pn flag instead of PN comparation\n net: phy: mscc: macsec: reject PN update requests\n ...\n', '']","Merge networking fixes for CAN, BPF, and address regression in TC subsystem.","networking, CAN, BPF",It's other type of commit.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.",Other component related to eBPF but not listed above.,"['tc/netfilter like programs', 'It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).', ""It's not related to any of the above.""]" +3fec323339a4a9801a54e8b282eb571965b67b23,3fec323339a4a9801a54e8b282eb571965b67b23,Alexandre Ghiti,alexghiti@rivosinc.com,1696580410,Palmer Dabbelt,palmer@rivosinc.com,1697136395,79b9a7bde60978a2dcb69a62f6d024c11cfe419e,a87e7d3e8832271ecb7d5eaaabc5b49fe25a469b,"drivers: perf: Fix panic in riscv SBI mmap support + +The following panic can happen when mmap is called before the pmu add +callback which sets the hardware counter index: this happens for example +with the following command `perf record --no-bpf-event -n kill`. + +[ 99.461486] CPU: 1 PID: 1259 Comm: perf Tainted: G E 6.6.0-rc4ubuntu-defconfig #2 +[ 99.461669] Hardware name: riscv-virtio","qemu (DT) +[ 99.461748] epc : pmu_sbi_set_scounteren+0x42/0x44 +[ 99.462337] ra : smp_call_function_many_cond+0x126/0x5b0 +[ 99.462369] epc : ffffffff809f9d24 ra : ffffffff800f93e0 sp : ff60000082153aa0 +[ 99.462407] gp : ffffffff82395c98 tp : ff6000009a218040 t0 : ff6000009ab3a4f0 +[ 99.462425] t1 : 0000000000000004 t2 : 0000000000000100 s0 : ff60000082153ab0 +[ 99.462459] s1 : 0000000000000000 a0 : ff60000098869528 a1 : 0000000000000000 +[ 99.462473] a2 : 000000000000001f a3 : 0000000000f00000 a4 : fffffffffffffff8 +[ 99.462488] a5 : 00000000000000cc a6 : 0000000000000000 a7 : 0000000000735049 +[ 99.462502] s2 : 0000000000000001 s3 : ffffffff809f9ce2 s4 : ff60000098869528 +[ 99.462516] s5 : 0000000000000002 s6 : 0000000000000004 s7 : 0000000000000001 +[ 99.462530] s8 : ff600003fec98bc0 s9 : ffffffff826c5890 s10: ff600003fecfcde0 +[ 99.462544] s11: ff600003fec98bc0 t3 : ffffffff819e2558 t4 : ff1c000004623840 +[ 99.462557] t5 : 0000000000000901 t6 : ff6000008feeb890 +[ 99.462570] status: 0000000200000100 badaddr: 0000000000000000 cause: 0000000000000003 +[ 99.462658] [] pmu_sbi_set_scounteren+0x42/0x44 +[ 99.462979] Code: 1060 4785 97bb 00d7 8fd9 9073 1067 6422 0141 8082 (9002) 0013 +[ 99.463335] Kernel BUG [#2] + +To circumvent this","[' try to enable userspace access to the hardware counter\nwhen it is selected in addition to when the event is mapped. And vice-versa\nwhen the event is stopped/unmapped.\n\nFixes: cc4c07c89aad (""drivers: perf: Implement perf event mmap support in the SBI backend"")\nSigned-off-by: Alexandre Ghiti \nLink: https://lore.kernel.org/r/20231006082010.11963-1-alexghiti@rivosinc.com\nCc: stable@vger.kernel.org\nSigned-off-by: Palmer Dabbelt \n', '']",This commit fixes a panic in the RISC-V SBI mmap support by addressing a hardware counter index issue.,"panic,RISC-V,mmap",It's a bug fix.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +b84b3f47921568a8172bec77d0370268e9fc62a2,b84b3f47921568a8172bec77d0370268e9fc62a2,Ian Rogers,irogers@google.com,1696876760,Namhyung Kim,namhyung@kernel.org,1697130117,c59394afeb79e3a925c5c6acb20c61ea303886b8,105254501770c8952e50c71618fca6a8b63890f1,"perf bpf_counter: Fix a few memory leaks + +Memory leaks were detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-20-irogers@google.com +Signed-off-by: Namhyung Kim +",,Fix memory leaks in the perf bpf_counter component.,"memory leaks, perf, bpf_counter",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"['It improves the overall eBPF infrastructure (e.g., verifier, runtime, etc.).']" +105254501770c8952e50c71618fca6a8b63890f1,105254501770c8952e50c71618fca6a8b63890f1,Ian Rogers,irogers@google.com,1696876759,Namhyung Kim,namhyung@kernel.org,1697130117,d6905cc51dedbd790835d8e22ebdb5e3272bfe3d,97fe038374bdf43fd025ac0e7aebf8bfbdd6d54f,"perf header: Fix various error path memory leaks + +Memory leaks were detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-19-irogers@google.com +Signed-off-by: Namhyung Kim +",,Fixes memory leaks in perf header error paths identified by clang-tidy.,"memory leaks, clang-tidy, perf header",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +97fe038374bdf43fd025ac0e7aebf8bfbdd6d54f,97fe038374bdf43fd025ac0e7aebf8bfbdd6d54f,Ian Rogers,irogers@google.com,1696876758,Namhyung Kim,namhyung@kernel.org,1697130117,5528b486ab4e61879a00083f6f95ffeebafa5b0c,c4b5140c6eac2f757d9706c6c783b60554c48cb7,"perf trace-event-info: Avoid passing NULL value to closedir + +If opendir failed then closedir was passed NULL which is +erroneous. Caught by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-18-irogers@google.com +Signed-off-by: Namhyung Kim +",,Fixed erroneous passing of NULL value to closedir in perf trace-event-info.,"NULL,closedir,clang-tidy",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +c4b5140c6eac2f757d9706c6c783b60554c48cb7,c4b5140c6eac2f757d9706c6c783b60554c48cb7,Ian Rogers,irogers@google.com,1696876757,Namhyung Kim,namhyung@kernel.org,1697130117,c4020b92d38b6393b1e4e7666cd322b719d197cc,7875c72c8b0566590c888a2420d7e8fc12f67154,"tools api: Avoid potential double free + +io__getline will free the line on error but it doesn't clear the out +argument. This may lead to the line being freed twice"," like in +tools/perf/util/srcline.c as detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-17-irogers@google.com +Signed-off-by: Namhyung Kim +",[''],Fixes a potential double free issue in tools API related to error handling in io__getline function.,"double free,error,io__getline",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +7875c72c8b0566590c888a2420d7e8fc12f67154,7875c72c8b0566590c888a2420d7e8fc12f67154,Ian Rogers,irogers@google.com,1696876756,Namhyung Kim,namhyung@kernel.org,1697130117,2cf6fe16b40715c86608ae78baaaf31396f35d9d,1370406d35b45457aae295a6cfce9fae2bbd785e,"perf parse-events: Fix unlikely memory leak when cloning terms + +Add missing free on an error path as detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-16-irogers@google.com +Signed-off-by: Namhyung Kim +",,Fix a memory leak in perf parse-events by adding a missing free on an error path.,"memory leak, perf, free",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +1370406d35b45457aae295a6cfce9fae2bbd785e,1370406d35b45457aae295a6cfce9fae2bbd785e,Ian Rogers,irogers@google.com,1696876755,Namhyung Kim,namhyung@kernel.org,1697130117,e12948eeb5df492a42ab8363c08a2d22782467b6,63d471979e49148e59eae0b33a57c12d535e20c6,"perf lock: Fix a memory leak on an error path + +If a memory allocation fails then the strdup-ed string needs +freeing. Detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-15-irogers@google.com +Signed-off-by: Namhyung Kim +",,Fixes a memory leak in perf lock by freeing strdup-ed string on error path.,"memory leak, error path, strdup",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +63d471979e49148e59eae0b33a57c12d535e20c6,63d471979e49148e59eae0b33a57c12d535e20c6,Ian Rogers,irogers@google.com,1696876754,Namhyung Kim,namhyung@kernel.org,1697130116,72aaee5f7698ac004f2fca03bcdde4ed316b5802,ef1aec6000a7364a6c1ef0a6f9cbf8b98b685255,"perf svghelper: Avoid memory leak + +On success path the sib_core and sib_thr values weren't being +freed. Detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-14-irogers@google.com +Signed-off-by: Namhyung Kim +",,The commit addresses a memory leak in the perf svghelper by ensuring sib_core and sib_thr values are freed.,"perf,memory leak,clang-tidy",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +ef1aec6000a7364a6c1ef0a6f9cbf8b98b685255,ef1aec6000a7364a6c1ef0a6f9cbf8b98b685255,Ian Rogers,irogers@google.com,1696876753,Namhyung Kim,namhyung@kernel.org,1697130116,63c15ba57b31848c44dc2bf496d816bdb29d2c13,51e9ea99f9bfe6a9c283d041dbc2c1c0be9c3a0f,"perf hists browser: Avoid potential NULL dereference + +On other code paths browser->he_selection is NULL checked"," add a +missing case reported by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-13-irogers@google.com +Signed-off-by: Namhyung Kim +",[''],The commit fixes a potential NULL dereference in the perf hists browser code.,"NULL dereference, perf, browser",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +51e9ea99f9bfe6a9c283d041dbc2c1c0be9c3a0f,51e9ea99f9bfe6a9c283d041dbc2c1c0be9c3a0f,Ian Rogers,irogers@google.com,1696876752,Namhyung Kim,namhyung@kernel.org,1697130116,e4b2cf6dca2b048504834e7783ae8509b96bb4cb,52a5ad12f2147506899ee83e680ea2a1d763adeb,"perf hists browser: Reorder variables to reduce padding + +Address clang-tidy warning: +``` +tools/perf/ui/browsers/hists.c:2416:8: warning: Excessive padding in 'struct popup_action' (8 padding bytes"," where 0 is optimal). +Optimal fields order: +time","['\nthread', '\nevsel', '\nfn', '\nms', '\nsocket', '\nrstype', '\n```\n\nSigned-off-by: Ian Rogers \nAcked-by: Namhyung Kim \nCc: Ravi Bangoria \nCc: Nick Desaulniers \nCc: Yang Jihong \nCc: Huacai Chen \nCc: Nathan Chancellor \nCc: Kan Liang \nCc: llvm@lists.linux.dev\nCc: Ming Wang \nCc: Tom Rix \nCc: bpf@vger.kernel.org\nLink: https://lore.kernel.org/r/20231009183920.200859-12-irogers@google.com\nSigned-off-by: Namhyung Kim \n', '']",This commit reorders variables in perf hists browser to address a clang-tidy padding warning.,"variable reordering, clang-tidy, padding",It's a cleanup or refactoring in the code.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +52a5ad12f2147506899ee83e680ea2a1d763adeb,52a5ad12f2147506899ee83e680ea2a1d763adeb,Ian Rogers,irogers@google.com,1696876751,Namhyung Kim,namhyung@kernel.org,1697130116,a8691f5434924f2251e136779eaf2ac60b4c62bd,85f73c377b2ac9988a204b119aebb33ca5c60083,"perf dlfilter: Be defensive against potential NULL dereference + +In the unlikely case of having a symbol without a mapping"," avoid a +NULL dereference that clang-tidy warns about. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-11-irogers@google.com +Signed-off-by: Namhyung Kim +",[''],The commit addresses a NULL dereference issue in perf dlfilter to improve stability and avoid clang-tidy warnings.,"NULL dereference, perf dlfilter, clang-tidy",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +85f73c377b2ac9988a204b119aebb33ca5c60083,85f73c377b2ac9988a204b119aebb33ca5c60083,Ian Rogers,irogers@google.com,1696876750,Namhyung Kim,namhyung@kernel.org,1697130116,9839b95859a13c6e4dfaa11dd563a23f556cb1a7,b3aa09ee78defd3d2e5f7debb5279f8a92b69749,"perf mem-events: Avoid uninitialized read + +pmu should be initialized to NULL before perf_pmus__scan loop. Fix and +shrink the scope of pmu at the same time. Issue detected by clang-tidy. + +Fixes: 5752c20f3787 (""perf mem: Scan all PMUs instead of just core ones"") +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-10-irogers@google.com +Signed-off-by: Namhyung Kim +",,Initialize pmu to NULL to prevent uninitialized read in perf mem-events and reduce its scope.,"uninitialized read, clang-tidy, pmu",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +b3aa09ee78defd3d2e5f7debb5279f8a92b69749,b3aa09ee78defd3d2e5f7debb5279f8a92b69749,Ian Rogers,irogers@google.com,1696876749,Namhyung Kim,namhyung@kernel.org,1697130116,77cb7946474a482be45699c5df4fbe51c6636f8f,e2372136700d460276ca7ff07da523e8f61b69c7,"perf jitdump: Avoid memory leak + +jit_repipe_unwinding_info is called in a loop by jit_process_dump"," +avoid leaking unwinding_data by free-ing before overwriting. Error +detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-9-irogers@google.com +Signed-off-by: Namhyung Kim +",[''],"Fix memory leak in perf jitdump by freeing unwinding_data before overwriting it, as identified by clang-tidy.","perf,jitdump,memory leak",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['other'] +e2372136700d460276ca7ff07da523e8f61b69c7,e2372136700d460276ca7ff07da523e8f61b69c7,Ian Rogers,irogers@google.com,1696876748,Namhyung Kim,namhyung@kernel.org,1697130116,14e147b5c01139a99c225443fcc266b14360e177,319d459898ce507dba58c28c17610314d16b7beb,"perf env: Remove unnecessary NULL tests + +clang-tidy was warning: +``` +util/env.c:334:23: warning: Access to field 'nr_pmu_mappings' results in a dereference of a null pointer (loaded from variable 'env') [clang-analyzer-core.NullDereference] + env->nr_pmu_mappings = pmu_num; +``` + +As functions are called potentially when !env was true. This condition +could never be true as it would produce a segv"," so remove the +unnecessary NULL tests and silence clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-8-irogers@google.com +Signed-off-by: Namhyung Kim +",[''],Remove unnecessary NULL pointer checks in perf environment code to prevent segfaults and silence clang-tidy warnings.,"NULL tests, clang-tidy, segfault",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",The bpftool utility,"[""It's not related to any of the above.""]" +319d459898ce507dba58c28c17610314d16b7beb,319d459898ce507dba58c28c17610314d16b7beb,Ian Rogers,irogers@google.com,1696876747,Namhyung Kim,namhyung@kernel.org,1697130116,131c9f1b1b8f97f8333cc04464e2f50f8712047d,da0c884b0756fc97a1c15f4cdb81e0a8490a6d7e,"perf buildid-cache: Fix use of uninitialized value + +The buildid filename is first determined and then from this the +buildid read. If getting the filename fails then the buildid will be +used for a later memcmp uninitialized. Detected by clang-tidy. + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-7-irogers@google.com +Signed-off-by: Namhyung Kim +",,Fix uninitialized value usage in perf buildid-cache to prevent memcmp issues.,"uninitialized value, buildid-cache, memcmp",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +da0c884b0756fc97a1c15f4cdb81e0a8490a6d7e,da0c884b0756fc97a1c15f4cdb81e0a8490a6d7e,Ian Rogers,irogers@google.com,1696876746,Namhyung Kim,namhyung@kernel.org,1697130115,abea99d02dc1db1279da8bfce1a011bebee8df84,b24520ffa9695c7249bdd181cf10bc0a3e365019,"perf bench uprobe: Fix potential use of memory after free + +Found by clang-tidy: +``` +bench/uprobe.c:98:3: warning: Use of memory after it is freed [clang-analyzer-unix.Malloc] + bench_uprobe_bpf__destroy(skel); +``` + +Signed-off-by: Ian Rogers +Acked-by: Namhyung Kim +Cc: Ravi Bangoria +Cc: Nick Desaulniers +Cc: Yang Jihong +Cc: Huacai Chen +Cc: Nathan Chancellor +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-6-irogers@google.com +Signed-off-by: Namhyung Kim +",,Fixes use-after-free issue in uprobe benchmarking tool detected by clang-tidy.,"memory leak, clang-tidy, uprobe",It's a bug fix.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.",['other'] +b24520ffa9695c7249bdd181cf10bc0a3e365019,b24520ffa9695c7249bdd181cf10bc0a3e365019,Ian Rogers,irogers@google.com,1696876744,Namhyung Kim,namhyung@kernel.org,1697130115,b01f7e73708287e92e0e76e73eaa2db3f76ab1a5,9e56d3be4bfd2ec6433a7c44195bd1e687b8ed2e,"run-clang-tools: Add pass through checks and and header-filter arguments + +Add a -checks argument to allow the checks passed to the clang-tool to +be set on the command line. + +Add a pass through -header-filter option. + +Don't run analysis on non-C or CPP files. + +Signed-off-by: Ian Rogers +Reviewed-by: Nick Desaulniers +Cc: Ravi Bangoria +Cc: Mark Rutland +Cc: Yang Jihong +Cc: Peter Zijlstra +Cc: Adrian Hunter +Cc: Arnaldo Carvalho de Melo +Cc: Huacai Chen +Cc: Jiri Olsa +Cc: Nathan Chancellor +Cc: Alexander Shishkin +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Ingo Molnar +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Cc: linux-kernel@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-4-irogers@google.com +Signed-off-by: Namhyung Kim +",,"Enhance run-clang-tools with command-line options for checks and header filtering, excluding non-C/CPP files.","clang-tools, header-filter, checks",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.","It's not related to any of the above, it's not related to bpf subsystem in Linux kernel, may be wrong data.","[""It's not related to any of the above.""]" +9e56d3be4bfd2ec6433a7c44195bd1e687b8ed2e,9e56d3be4bfd2ec6433a7c44195bd1e687b8ed2e,Ian Rogers,irogers@google.com,1696876743,Namhyung Kim,namhyung@kernel.org,1697130115,e7a96bbb49e0f6bbbfe68f685c0fd410bcc13bdd,52c15e7e792857c42b4a926e45228e981c5a5f13,"gen_compile_commands: Sort output compile commands by file name + +Make the output more stable and deterministic. + +Signed-off-by: Ian Rogers +Reviewed-by: Nick Desaulniers +Cc: Ravi Bangoria +Cc: Mark Rutland +Cc: Yang Jihong +Cc: Peter Zijlstra +Cc: Adrian Hunter +Cc: Arnaldo Carvalho de Melo +Cc: Huacai Chen +Cc: Jiri Olsa +Cc: Nathan Chancellor +Cc: Alexander Shishkin +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Ingo Molnar +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Cc: linux-kernel@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-3-irogers@google.com +Signed-off-by: Namhyung Kim +",,The commit updates gen_compile_commands to sort output compile commands by file name for stability and determinism.,"gen_compile_commands, sort, stability",It's a build system or CI/CD change.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +52c15e7e792857c42b4a926e45228e981c5a5f13,52c15e7e792857c42b4a926e45228e981c5a5f13,Ian Rogers,irogers@google.com,1696876742,Namhyung Kim,namhyung@kernel.org,1697130115,443ff6afb0ba82302acf7cc44c906df2426e299e,b20576fd7fe39554b212095c3c0d7a3dff512515,"gen_compile_commands: Allow the line prefix to still be cmd_ + +Builds in tools still use the cmd_ prefix in .cmd files"," so don't +require the saved part. Name the groups in the line pattern match so +that changing the regular expression is more robust and works with the +addition of a new match group. + +Signed-off-by: Ian Rogers +Reviewed-by: Nick Desaulniers +Cc: Ravi Bangoria +Cc: Mark Rutland +Cc: Yang Jihong +Cc: Peter Zijlstra +Cc: Adrian Hunter +Cc: Arnaldo Carvalho de Melo +Cc: Huacai Chen +Cc: Jiri Olsa +Cc: Nathan Chancellor +Cc: Alexander Shishkin +Cc: Kan Liang +Cc: llvm@lists.linux.dev +Cc: Ming Wang +Cc: Ingo Molnar +Cc: Tom Rix +Cc: bpf@vger.kernel.org +Cc: linux-kernel@vger.kernel.org +Cc: linux-perf-users@vger.kernel.org +Link: https://lore.kernel.org/r/20231009183920.200859-2-irogers@google.com +Signed-off-by: Namhyung Kim +",[''],The commit allows the gen_compile_commands to maintain the cmd_ prefix for robustness with new match groups.,"gen_compile_commands, cmd_prefix, robustness",It's a build system or CI/CD change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",Other component related to eBPF but not listed above.,"[""It's not related to any of the above.""]" +d2dc885b8c9ddb6fc374d93a87f8f2d1b97d2caf,d2dc885b8c9ddb6fc374d93a87f8f2d1b97d2caf,Martin KaFai Lau,martin.lau@kernel.org,1697055860,Martin KaFai Lau,martin.lau@kernel.org,1697070476,6d8e18abf80ef20cdea6a941fc05c032b19190a9,1ef09e1281a1add0a86ecd594f748d7fb8bfd78e 82ab6b505e8199cc4537f00025a7391973c3847e,"Merge branch 'Add cgroup sockaddr hooks for unix sockets' + +Daan De Meyer says: + +==================== +Changes since v10: + +* Removed extra check from bpf_sock_addr_set_sun_path() again in favor of + calling unix_validate_addr() everywhere in af_unix.c before calling the hooks. + +Changes since v9: + +* Renamed bpf_sock_addr_set_unix_addr() to bpf_sock_addr_set_sun_path() and + rennamed arguments to match the new name. +* Added an extra check to bpf_sock_addr_set_sun_path() to disallow changing the + address of an unnamed unix socket. +* Removed unnecessary NULL check on uaddrlen in + __cgroup_bpf_run_filter_sock_addr(). + +Changes since v8: + +* Added missing test programs to last patch + +Changes since v7: + +* Fixed formatting nit in comment +* Renamed from cgroup/connectun to cgroup/connect_unix (and similar for all + other hooks) + +Changes since v6: + +* Actually removed bpf_bind() helper for AF_UNIX hooks. +* Fixed merge conflict +* Updated comment to mention uaddrlen is read-only for AF_INET[6] +* Removed unnecessary forward declaration of struct sock_addr_test +* Removed unused BPF_CGROUP_RUN_PROG_UNIX_CONNECT() +* Fixed formatting nit reported by checkpatch +* Added more information to commit message about recvmsg() on connected socket + +Changes since v5: + +* Fixed kernel version in bpftool documentation (6.3 => 6.7). +* Added connection mode socket recvmsg() test. +* Removed bpf_bind() helper for AF_UNIX hooks. +* Added missing getpeernameun and getsocknameun BPF test programs. +* Added note for bind() test being unused currently. + +Changes since v4: + +* Dropped support for intercepting bind() as when using bind() with unix sockets + and a pathname sockaddr"," bind() will create an inode in the filesystem that + needs to be cleaned up. If the address is rewritten","[' users might try to clean\n up the wrong file and leak the actual socket file in the filesystem.\n* Changed bpf_sock_addr_set_unix_addr() to use BTF_KFUNC_HOOK_CGROUP_SKB instead\n of BTF_KFUNC_HOOK_COMMON.\n* Removed unix socket related changes from BPF_CGROUP_PRE_CONNECT_ENABLED() as\n unix sockets do not support pre-connect.\n* Added tests for getpeernameun and getsocknameun hooks.\n* We now disallow an empty sockaddr in bpf_sock_addr_set_unix_addr() similar to\n unix_validate_addr().\n* Removed unnecessary cgroup_bpf_enabled() checks\n* Removed unnecessary error checks\n\nChanges since v3:\n\n* Renamed bpf_sock_addr_set_addr() to bpf_sock_addr_set_unix_addr() and\n made it only operate on AF_UNIX sockaddrs. This is because for the other\n families', ' users usually want to configure more than just the address so\n a generic interface will not fit the bill here. e.g. for AF_INET and AF_INET6', ""\n users would generally also want to be able to configure the port which the\n current interface doesn't support. So we expose an AF_UNIX specific function\n instead.\n* Made the tests in the new sock addr tests more generic (similar to test_sock_addr.c)"", '\n this should make it easier to migrate the other sock addr tests in the future.\n* Removed the new kfunc hook and attached to BTF_KFUNC_HOOK_COMMON instead\n* Set uaddrlen to 0 when the family is AF_UNSPEC\n* Pass in the addrlen to the hook from IPv6 code\n* Fixed mount directory mkdir() to ignore EEXIST\n\nChanges since v2:\n\n* Configuring the sock addr is now done via a new kfunc bpf_sock_addr_set()\n* The addrlen is exposed as u32 in bpf_sock_addr_kern\n* Selftests are updated to use the new kfunc\n* Selftests are now added as a new sock_addr test in prog_tests/\n* Added BTF_KFUNC_HOOK_SOCK_ADDR for BPF_PROG_TYPE_CGROUP_SOCK_ADDR\n* __cgroup_bpf_run_filter_sock_addr() now returns the modified addrlen\n\nChanges since v1:\n\n* Split into multiple patches instead of one single patch\n* Added unix support for all socket address hooks instead of only connect()\n* Switched approach to expose the socket address length to the bpf hook\ninstead of recalculating the socket address length in kernelspace to\nproperly support abstract unix socket addresses\n* Modified socket address hook tests to calculate the socket address length\nonce and pass it around everywhere instead of recalculating the actual unix\nsocket address length on demand.\n* Added some missing section name tests for getpeername()/getsockname()\n\nThis patch series extends the cgroup sockaddr hooks to include support for unix\nsockets. To add support for unix sockets', ' struct bpf_sock_addr_kern is extended\nto expose the socket address length to the bpf program. Along with that', ' a new\nkfunc bpf_sock_addr_set_unix_addr() is added to safely allow modifying an\nAF_UNIX sockaddr from bpf programs.\n\nI intend to use these new hooks in systemd to reimplement the LogNamespace=\nfeature', ' which allows running multiple instances of systemd-journald to\nprocess the logs of different services. systemd-journald also processes\nsyslog messages', ' so currently', "" using log namespaces means all services running\nin the same log namespace have to live in the same private mount namespace\nso that systemd can mount the journal namespace's associated syslog socket\nover /dev/log to properly direct syslog messages from all services running\nin that log namespace to the correct systemd-journald instance. We want to\nrelax this requirement so that processes running in disjoint mount namespaces\ncan still run in the same log namespace. To achieve this"", ' we can use these\nnew hooks to rewrite the socket address of any connect()', ' sendto()', "" ...\nsyscalls to /dev/log to the socket address of the journal namespace's syslog\nsocket instead"", ' which will transparently do the redirection without requiring\nuse of a mount namespace and mounting over /dev/log.\n\nAside from the above usecase', ' these hooks can more generally be used to\ntransparently redirect unix sockets to different addresses as required by\nservices.\n====================\n\nSigned-off-by: Martin KaFai Lau \n', '']",This commit adds cgroup sockaddr hooks for Unix sockets and includes various fixes and renamings from previous versions.,"cgroup, unix sockets, hooks",It's a new feature.,"Complex, needs expert knowledge or significant changes to existing systems. Like adding a completely new subsystem support or a completely new program type don't exist before.","The attach events and bpf link. e.g. perf events, tracepoints, etc.",['cgroup like programs'] +82ab6b505e8199cc4537f00025a7391973c3847e,82ab6b505e8199cc4537f00025a7391973c3847e,Daan De Meyer,daan.j.demeyer@gmail.com,1697050271,Martin KaFai Lau,martin.lau@kernel.org,1697070475,6d8e18abf80ef20cdea6a941fc05c032b19190a9,af2752ed450e71fc0bd596d0b4b9b805a64ae2c1,"selftests/bpf: Add tests for cgroup unix socket address hooks + +These selftests are written in prog_tests style instead of adding +them to the existing test_sock_addr tests. Migrating the existing +sock addr tests to prog_tests style is left for future work. This +commit adds support for testing bind() sockaddr hooks"," even though +there's no unix socket sockaddr hook for bind(). We leave this code +intact for when the INET and INET6 tests are migrated in the future +which do support intercepting bind(). + +Signed-off-by: Daan De Meyer +Link: https://lore.kernel.org/r/20231011185113.140426-10-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau +",[''],Add selftests for cgroup unix socket address hooks in prog_tests style.,"selftests,cgroup,socket",It's a test case or test infrastructure change.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The test cases and makefiles,"['socket like programs', 'cgroup like programs']" +af2752ed450e71fc0bd596d0b4b9b805a64ae2c1,af2752ed450e71fc0bd596d0b4b9b805a64ae2c1,Daan De Meyer,daan.j.demeyer@gmail.com,1697050270,Martin KaFai Lau,martin.lau@kernel.org,1697070475,4bf1a4389986554336461f4c19d057bd791d6ecf,3243fef6a4c0db2dbb01ee3cf30bd787e65b8d56,"selftests/bpf: Make sure mount directory exists + +The mount directory for the selftests cgroup tree might +not exist so let's make sure it does exist by creating +it ourselves if it doesn't exist. + +Signed-off-by: Daan De Meyer +Link: https://lore.kernel.org/r/20231011185113.140426-9-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau +",,Ensure selftests create necessary mount directories for cgroup trees if not present.,"selftests, cgroup, directory",It's a test case or test infrastructure change.,"Simple, can be used without much configuration. For example, a simple helper function.",The test cases and makefiles,"[""It's not related to any of the above.""]" +3243fef6a4c0db2dbb01ee3cf30bd787e65b8d56,3243fef6a4c0db2dbb01ee3cf30bd787e65b8d56,Daan De Meyer,daan.j.demeyer@gmail.com,1697050269,Martin KaFai Lau,martin.lau@kernel.org,1697070475,a1b9c995e514da7a48507e4d10e0ed66b4703c72,8b3cba987e6d9464bb533d957de923f891b57bf8,"documentation/bpf: Document cgroup unix socket address hooks + +Update the documentation to mention the new cgroup unix sockaddr +hooks. + +Signed-off-by: Daan De Meyer +Link: https://lore.kernel.org/r/20231011185113.140426-8-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau +",,The commit updates documentation to include cgroup unix socket address hooks.,"documentation,cgroup,socket",It's a documentation change or typo fix.,"Simple, can be used without much configuration. For example, a simple helper function.",Other component related to eBPF but not listed above.,['cgroup like programs'] +8b3cba987e6d9464bb533d957de923f891b57bf8,8b3cba987e6d9464bb533d957de923f891b57bf8,Daan De Meyer,daan.j.demeyer@gmail.com,1697050268,Martin KaFai Lau,martin.lau@kernel.org,1697070475,1a03ce1f2f0ad0ca81cd2d68a690dac5fd76ecbf,bf90438c78df885c17a3474276ed39abb4a7c026,"bpftool: Add support for cgroup unix socket address hooks + +Add the necessary plumbing to hook up the new cgroup unix sockaddr +hooks into bpftool. + +Signed-off-by: Daan De Meyer +Acked-by: Quentin Monnet +Link: https://lore.kernel.org/r/20231011185113.140426-7-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau +",,This commit adds support for cgroup unix socket address hooks into bpftool.,"bpftool,cgroup,unix",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The bpftool utility,['cgroup like programs'] +bf90438c78df885c17a3474276ed39abb4a7c026,bf90438c78df885c17a3474276ed39abb4a7c026,Daan De Meyer,daan.j.demeyer@gmail.com,1697050267,Martin KaFai Lau,martin.lau@kernel.org,1697070475,b06ea6a79a254d7547802f4795df2603762d7280,859051dd165ec6cc915f0f2114699021144fd249,"libbpf: Add support for cgroup unix socket address hooks + +Add the necessary plumbing to hook up the new cgroup unix sockaddr +hooks into libbpf. + +Signed-off-by: Daan De Meyer +Link: https://lore.kernel.org/r/20231011185113.140426-6-daan.j.demeyer@gmail.com +Signed-off-by: Martin KaFai Lau +",,libbpf gains support for hooking cgroup unix socket address operations.,"libbpf,cgroup,socket",It's a new feature.,"Moderate, requires some setup or understanding of the system. For example, a new map type or a new link type.",The libbpf library,['cgroup like programs']