Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\test_bpf.c Create Date:2022-07-28 06:27:57
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:prepare_bpf_tests

Proto:static __init int prepare_bpf_tests(void)

Type:int

Parameter:Nothing

6736  If test_id >= 0 Then
6742  pr_err("test_bpf: invalid test_id specified.\n")
6743  Return -EINVAL
6746  test_range[0] = test_id
6747  test_range[1] = test_id
6748  Else if test_name Then
6753  idx = find_test_index(test_name)
6755  If idx < 0 Then
6756  pr_err("test_bpf: no test named '%s' found.\n", test_name)
6758  Return -EINVAL
6760  test_range[0] = idx
6761  test_range[1] = idx
6762  Else
6769  pr_err("test_bpf: test_range is out of bound.\n")
6770  Return -EINVAL
6773  If test_range[1] < test_range[0] Then
6774  pr_err("test_bpf: test_range is ending before it starts.\n")
6775  Return -EINVAL
6779  When i < ARRAY_SIZE - get the number of elements in array @arr*@arr: array to be sized(tests) cycle
6780  If fill_helper && fill_helper( & tests[i]) < 0 Then Return -ENOMEM
6785  Return 0
Caller
NameDescribe
test_bpf_init