bpf: Rename __bpf_kprobe_multi_cookie_cmp to bpf_kprobe_multi_addrs_cmp
Renaming __bpf_kprobe_multi_cookie_cmp to bpf_kprobe_multi_addrs_cmp, because it's more suitable to current and upcoming code. Acked-by: Song Liu <song@kernel.org> Signed-off-by: Jiri Olsa <jolsa@kernel.org> Link: https://lore.kernel.org/r/20221025134148.3300700-4-jolsa@kernel.org Signed-off-by: Alexei Starovoitov <ast@kernel.org>
This commit is contained in:
parent
3640bf8584
commit
1a1b0716d3
|
@ -2548,7 +2548,7 @@ static void bpf_kprobe_multi_cookie_swap(void *a, void *b, int size, const void
|
|||
swap(*cookie_a, *cookie_b);
|
||||
}
|
||||
|
||||
static int __bpf_kprobe_multi_cookie_cmp(const void *a, const void *b)
|
||||
static int bpf_kprobe_multi_addrs_cmp(const void *a, const void *b)
|
||||
{
|
||||
const unsigned long *addr_a = a, *addr_b = b;
|
||||
|
||||
|
@ -2559,7 +2559,7 @@ static int __bpf_kprobe_multi_cookie_cmp(const void *a, const void *b)
|
|||
|
||||
static int bpf_kprobe_multi_cookie_cmp(const void *a, const void *b, const void *priv)
|
||||
{
|
||||
return __bpf_kprobe_multi_cookie_cmp(a, b);
|
||||
return bpf_kprobe_multi_addrs_cmp(a, b);
|
||||
}
|
||||
|
||||
static u64 bpf_kprobe_multi_cookie(struct bpf_run_ctx *ctx)
|
||||
|
@ -2577,7 +2577,7 @@ static u64 bpf_kprobe_multi_cookie(struct bpf_run_ctx *ctx)
|
|||
return 0;
|
||||
entry_ip = run_ctx->entry_ip;
|
||||
addr = bsearch(&entry_ip, link->addrs, link->cnt, sizeof(entry_ip),
|
||||
__bpf_kprobe_multi_cookie_cmp);
|
||||
bpf_kprobe_multi_addrs_cmp);
|
||||
if (!addr)
|
||||
return 0;
|
||||
cookie = link->cookies + (addr - link->addrs);
|
||||
|
|
Loading…
Reference in New Issue