Lines Matching defs:byte_sz
2019 int btf__add_int(struct btf *btf, const char *name, size_t byte_sz, int encoding)
2027 /* byte_sz must be power of 2 */
2028 if (!byte_sz || (byte_sz & (byte_sz - 1)) || byte_sz > 16)
2052 t->size = byte_sz;
2054 *(__u32 *)(t + 1) = (encoding << 24) | (byte_sz * 8);
2067 int btf__add_float(struct btf *btf, const char *name, size_t byte_sz)
2076 /* byte_sz must be one of the explicitly allowed values */
2077 if (byte_sz != 2 && byte_sz != 4 && byte_sz != 8 && byte_sz != 12 &&
2078 byte_sz != 16)
2095 t->size = byte_sz;
2224 * - *byte_sz* - size of the struct, in bytes;
2233 int btf__add_struct(struct btf *btf, const char *name, __u32 byte_sz)
2235 return btf_add_composite(btf, BTF_KIND_STRUCT, name, byte_sz);
2241 * - *byte_sz* - size of the union, in bytes;
2251 int btf__add_union(struct btf *btf, const char *name, __u32 byte_sz)
2253 return btf_add_composite(btf, BTF_KIND_UNION, name, byte_sz);
2326 static int btf_add_enum_common(struct btf *btf, const char *name, __u32 byte_sz,
2332 /* byte_sz must be power of 2 */
2333 if (!byte_sz || (byte_sz & (byte_sz - 1)) || byte_sz > 8)
2353 t->size = byte_sz;
2361 * - *byte_sz* - size of the enum, in bytes.
2371 int btf__add_enum(struct btf *btf, const char *name, __u32 byte_sz)
2377 return btf_add_enum_common(btf, name, byte_sz, false, BTF_KIND_ENUM);
2439 * - *byte_sz* - size of the enum, in bytes.
2450 int btf__add_enum64(struct btf *btf, const char *name, __u32 byte_sz,
2453 return btf_add_enum_common(btf, name, byte_sz, is_signed,
2781 * - *byte_sz* - data section size, in bytes.
2790 int btf__add_datasec(struct btf *btf, const char *name, __u32 byte_sz)
2814 t->size = byte_sz;
2823 * - *byte_sz* - variable size, in bytes.
2829 int btf__add_datasec_var_info(struct btf *btf, int var_type_id, __u32 offset, __u32 byte_sz)
2856 v->size = byte_sz;