diff options
author | Wang Nan <wangnan0@huawei.com> | 2015-08-06 07:02:33 (GMT) |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-08-10 05:50:05 (GMT) |
commit | 2a36f0b92eb638dd023870574eb471b1c56be9ad (patch) | |
tree | 74d714e1fc1e2daa98d61fdf948d9b7fae0e4378 /kernel/bpf/core.c | |
parent | ffe8690c85b8426db7783064724d106702f1b1e8 (diff) | |
download | linux-2a36f0b92eb638dd023870574eb471b1c56be9ad.tar.xz |
bpf: Make the bpf_prog_array_map more generic
All the map backends are of generic nature. In order to avoid
adding much special code into the eBPF core, rewrite part of
the bpf_prog_array map code and make it more generic. So the
new perf_event_array map type can reuse most of code with
bpf_prog_array map and add fewer lines of special code.
Signed-off-by: Wang Nan <wangnan0@huawei.com>
Signed-off-by: Kaixu Xia <xiakaixu@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'kernel/bpf/core.c')
-rw-r--r-- | kernel/bpf/core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/bpf/core.c b/kernel/bpf/core.c index fafa741..67c380c 100644 --- a/kernel/bpf/core.c +++ b/kernel/bpf/core.c @@ -450,7 +450,7 @@ select_insn: tail_call_cnt++; - prog = READ_ONCE(array->prog[index]); + prog = READ_ONCE(array->ptrs[index]); if (unlikely(!prog)) goto out; |