Skip to content

Commit

Permalink
tests: Add probe_read_kernel to known types
Browse files Browse the repository at this point in the history
  • Loading branch information
fbs committed Aug 28, 2020
1 parent 1038d07 commit 5441336
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion tests/runtime/engine/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def __read_test_struct(test, test_suite):
arch = [x.strip() for x in line.split("|")]
elif item_name == 'REQUIRES_FEATURE':
feature_requirement = {x.strip() for x in line.split(" ")}
unknown = feature_requirement - {"loop", "btf"}
unknown = feature_requirement - {"loop", "btf", "probe_read_kernel"}
if len(unknown) > 0:
raise UnknownFieldError('%s is invalid for REQUIRES_FEATURE. Suite: %s' % (','.join(unknown), test_suite))
else:
Expand Down
1 change: 1 addition & 0 deletions tests/runtime/engine/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ def __get_bpffeature():
output = p.communicate()[0]
bpffeature = {}
bpffeature["loop"] = output.find("Loop support: yes") != -1
bpffeature["probe_read_kernel"] = output.find("probe_read_kernel: yes") != -1
bpffeature["btf"] = output.find("btf (depends on Build:libbpf): yes") != -1
return bpffeature

Expand Down

0 comments on commit 5441336

Please sign in to comment.