• Yonghong Song's avatar
    tools/bpf: add addition type tests to test_btf · d0848912
    Yonghong Song authored
    The following additional unit testcases are added to test_btf:
    ...
    BTF raw test[42] (typedef (invalid name, name_off = 0)): OK
    BTF raw test[43] (typedef (invalid name, invalid identifier)): OK
    BTF raw test[44] (ptr type (invalid name, name_off <> 0)): OK
    BTF raw test[45] (volatile type (invalid name, name_off <> 0)): OK
    BTF raw test[46] (const type (invalid name, name_off <> 0)): OK
    BTF raw test[47] (restrict type (invalid name, name_off <> 0)): OK
    BTF raw test[48] (fwd type (invalid name, name_off = 0)): OK
    BTF raw test[49] (fwd type (invalid name, invalid identifier)): OK
    BTF raw test[50] (array type (invalid name, name_off <> 0)): OK
    BTF raw test[51] (struct type (name_off = 0)): OK
    BTF raw test[52] (struct type (invalid name, invalid identifier)): OK
    BTF raw test[53] (struct member (name_off = 0)): OK
    BTF raw test[54] (struct member (invalid name, invalid identifier)): OK
    BTF raw test[55] (enum type (name_off = 0)): OK
    BTF raw test[56] (enum type (invalid name, invalid identifier)): OK
    BTF raw test[57] (enum member (invalid name, name_off = 0)): OK
    BTF raw test[58] (enum member (invalid name, invalid identifier)): OK
    ...
    
    Fixes: c0fa1b6c ("bpf: btf: Add BTF tests")
    Acked-by: default avatarMartin KaFai Lau <kafai@fb.com>
    Signed-off-by: default avatarYonghong Song <yhs@fb.com>
    Signed-off-by: default avatarAlexei Starovoitov <ast@kernel.org>
    d0848912
test_btf.c 70.5 KB