• Home
  • Raw
  • Download

Lines Matching refs:hdr

206 	struct btf_header hdr;  member
604 offset < btf->hdr.str_len; in btf_name_offset_valid()
652 else if (offset < btf->hdr.str_len) in __btf_name_by_offset()
660 if (offset < btf->hdr.str_len) in btf_name_by_offset()
1367 const struct btf_header *hdr; in btf_verifier_log_hdr() local
1374 hdr = &btf->hdr; in btf_verifier_log_hdr()
1375 __btf_verifier_log(log, "magic: 0x%x\n", hdr->magic); in btf_verifier_log_hdr()
1376 __btf_verifier_log(log, "version: %u\n", hdr->version); in btf_verifier_log_hdr()
1377 __btf_verifier_log(log, "flags: 0x%x\n", hdr->flags); in btf_verifier_log_hdr()
1378 __btf_verifier_log(log, "hdr_len: %u\n", hdr->hdr_len); in btf_verifier_log_hdr()
1379 __btf_verifier_log(log, "type_off: %u\n", hdr->type_off); in btf_verifier_log_hdr()
1380 __btf_verifier_log(log, "type_len: %u\n", hdr->type_len); in btf_verifier_log_hdr()
1381 __btf_verifier_log(log, "str_off: %u\n", hdr->str_off); in btf_verifier_log_hdr()
1382 __btf_verifier_log(log, "str_len: %u\n", hdr->str_len); in btf_verifier_log_hdr()
3797 struct btf_header *hdr; in btf_check_all_metas() local
3800 hdr = &btf->hdr; in btf_check_all_metas()
3801 cur = btf->nohdr_data + hdr->type_off; in btf_check_all_metas()
3802 end = cur + hdr->type_len; in btf_check_all_metas()
3931 const struct btf_header *hdr = &env->btf->hdr; in btf_parse_type_sec() local
3935 if (hdr->type_off & (sizeof(u32) - 1)) { in btf_parse_type_sec()
3940 if (!hdr->type_len) { in btf_parse_type_sec()
3954 const struct btf_header *hdr; in btf_parse_str_sec() local
3958 hdr = &btf->hdr; in btf_parse_str_sec()
3959 start = btf->nohdr_data + hdr->str_off; in btf_parse_str_sec()
3960 end = start + hdr->str_len; in btf_parse_str_sec()
3967 if (!hdr->str_len || hdr->str_len - 1 > BTF_MAX_NAME_OFFSET || in btf_parse_str_sec()
3996 const struct btf_header *hdr; in btf_check_sec_info() local
4000 hdr = &btf->hdr; in btf_check_sec_info()
4004 secs[i] = *(struct btf_sec_info *)((void *)hdr + in btf_check_sec_info()
4012 expected_total = btf_data_size - hdr->hdr_len; in btf_check_sec_info()
4047 const struct btf_header *hdr; in btf_parse_hdr() local
4055 offsetof(struct btf_header, hdr_len) + sizeof(hdr->hdr_len)) { in btf_parse_hdr()
4060 hdr = btf->data; in btf_parse_hdr()
4061 hdr_len = hdr->hdr_len; in btf_parse_hdr()
4068 if (hdr_len > sizeof(btf->hdr)) { in btf_parse_hdr()
4069 u8 *expected_zero = btf->data + sizeof(btf->hdr); in btf_parse_hdr()
4080 hdr_copy = min_t(u32, hdr_len, sizeof(btf->hdr)); in btf_parse_hdr()
4081 memcpy(&btf->hdr, btf->data, hdr_copy); in btf_parse_hdr()
4083 hdr = &btf->hdr; in btf_parse_hdr()
4087 if (hdr->magic != BTF_MAGIC) { in btf_parse_hdr()
4092 if (hdr->version != BTF_VERSION) { in btf_parse_hdr()
4097 if (hdr->flags) { in btf_parse_hdr()
4102 if (btf_data_size == hdr->hdr_len) { in btf_parse_hdr()
4171 btf->nohdr_data = btf->data + btf->hdr.hdr_len; in btf_parse()
4381 btf->nohdr_data = btf->data + btf->hdr.hdr_len; in BTF_ID()