Commit cd80a9b
committed
selftests/bpf: Adapt assert_mprog_count to always expect 0 count
jira LE-1907
Rebuild_History Non-Buildable kernel-5.14.0-427.18.1.el9_4
commit-author Daniel Borkmann <[email protected]>
commit b773682
Simplify __assert_mprog_count() to remove the -ENOENT corner case as the
bpf_prog_query() now returns 0 when no bpf_mprog is attached. This also
allows to convert a few test cases from using raw __assert_mprog_count()
over to plain assert_mprog_count() helper.
Signed-off-by: Daniel Borkmann <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Martin KaFai Lau <[email protected]>
(cherry picked from commit b773682)
Signed-off-by: Jonathan Maple <[email protected]>1 parent acbb04e commit cd80a9b
File tree
3 files changed
+8
-11
lines changed- tools/testing/selftests/bpf/prog_tests
3 files changed
+8
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
48 | | - | |
| 48 | + | |
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
| 56 | + | |
60 | 57 | | |
61 | 58 | | |
62 | 59 | | |
63 | 60 | | |
64 | | - | |
| 61 | + | |
65 | 62 | | |
66 | 63 | | |
67 | 64 | | |
68 | 65 | | |
69 | | - | |
| 66 | + | |
70 | 67 | | |
71 | 68 | | |
72 | 69 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1667 | 1667 | | |
1668 | 1668 | | |
1669 | 1669 | | |
1670 | | - | |
| 1670 | + | |
1671 | 1671 | | |
1672 | 1672 | | |
1673 | 1673 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
635 | 635 | | |
636 | 636 | | |
637 | 637 | | |
638 | | - | |
| 638 | + | |
639 | 639 | | |
640 | 640 | | |
641 | 641 | | |
| |||
2250 | 2250 | | |
2251 | 2251 | | |
2252 | 2252 | | |
2253 | | - | |
| 2253 | + | |
2254 | 2254 | | |
2255 | 2255 | | |
2256 | 2256 | | |
| |||
2352 | 2352 | | |
2353 | 2353 | | |
2354 | 2354 | | |
2355 | | - | |
| 2355 | + | |
2356 | 2356 | | |
2357 | 2357 | | |
2358 | 2358 | | |
| |||
0 commit comments