-
Notifications
You must be signed in to change notification settings - Fork 150
Pass external callchain entry to get_perf_callchain #10263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: bpf-next_base
Are you sure you want to change the base?
Conversation
|
Upstream branch: 026bcf9 |
|
Upstream branch: 3249e8a |
7e8242e to
9e9f2fa
Compare
910d3ce to
50dc55d
Compare
|
Upstream branch: f1d8c65 |
9e9f2fa to
2daf675
Compare
50dc55d to
f882b4c
Compare
|
Upstream branch: 93ce3be |
2daf675 to
fbe4343
Compare
f882b4c to
4752827
Compare
|
Upstream branch: 93ce3be |
fbe4343 to
14687dc
Compare
4752827 to
05f2f03
Compare
|
Upstream branch: c1da3df |
14687dc to
6ef22c4
Compare
05f2f03 to
c343f72
Compare
|
Upstream branch: e5d2e34 |
6ef22c4 to
3069d1e
Compare
c343f72 to
6a32d09
Compare
|
Upstream branch: fea3f5e |
3069d1e to
5f1952d
Compare
6a32d09 to
b967d93
Compare
|
Upstream branch: 63066b7 |
5f1952d to
a05c18b
Compare
b967d93 to
250c35a
Compare
|
Upstream branch: c133390 |
a05c18b to
337bc20
Compare
250c35a to
5630fb8
Compare
|
Upstream branch: ef2c0b2 |
337bc20 to
52ab1ad
Compare
5630fb8 to
f815251
Compare
|
Upstream branch: a4d31f4 |
52ab1ad to
24f09ae
Compare
f815251 to
eb66b0c
Compare
From BPF stack map, we want to ensure that the callchain buffer will not be overwritten by other preemptive tasks. Peter suggested provide more flexible stack-sampling APIs, which can be used in BPF, and we can still use the perf callchain entry with the help of these APIs. The next patch will modify the BPF part. In the future, these APIs will also make it convenient for us to add stack-sampling kfuncs in the eBPF subsystem, just as Andrii and Alexei discussed earlier. Signed-off-by: Peter Zijlstra <[email protected]> Signed-off-by: Tao Chen <[email protected]>
As Alexei noted, get_perf_callchain() return values may be reused if a task is preempted after the BPF program enters migrate disable mode. The perf_callchain_entres has a small stack of entries, and we can reuse it as follows: 1. get the perf callchain entry 2. BPF use... 3. put the perf callchain entry And Peter suggested that get_recursion_context used with preemption disabled, so we should disable preemption at BPF side. Signed-off-by: Tao Chen <[email protected]> Acked-by: Yonghong Song <[email protected]>
|
Upstream branch: 4f7bc83 |
24f09ae to
07b7973
Compare
Pull request for series with
subject: Pass external callchain entry to get_perf_callchain
version: 6
url: https://patchwork.kernel.org/project/netdevbpf/list/?series=1022592