Lines Matching defs:t

188  * if there were some unused strings in *src_btf*, those won't be copied over,
363 static inline __u16 btf_kind(const struct btf_type *t)
365 return BTF_INFO_KIND(t->info);
368 static inline __u16 btf_vlen(const struct btf_type *t)
370 return BTF_INFO_VLEN(t->info);
373 static inline bool btf_kflag(const struct btf_type *t)
375 return BTF_INFO_KFLAG(t->info);
378 static inline bool btf_is_void(const struct btf_type *t)
380 return btf_kind(t) == BTF_KIND_UNKN;
383 static inline bool btf_is_int(const struct btf_type *t)
385 return btf_kind(t) == BTF_KIND_INT;
388 static inline bool btf_is_ptr(const struct btf_type *t)
390 return btf_kind(t) == BTF_KIND_PTR;
393 static inline bool btf_is_array(const struct btf_type *t)
395 return btf_kind(t) == BTF_KIND_ARRAY;
398 static inline bool btf_is_struct(const struct btf_type *t)
400 return btf_kind(t) == BTF_KIND_STRUCT;
403 static inline bool btf_is_union(const struct btf_type *t)
405 return btf_kind(t) == BTF_KIND_UNION;
408 static inline bool btf_is_composite(const struct btf_type *t)
410 __u16 kind = btf_kind(t);
415 static inline bool btf_is_enum(const struct btf_type *t)
417 return btf_kind(t) == BTF_KIND_ENUM;
420 static inline bool btf_is_enum64(const struct btf_type *t)
422 return btf_kind(t) == BTF_KIND_ENUM64;
425 static inline bool btf_is_fwd(const struct btf_type *t)
427 return btf_kind(t) == BTF_KIND_FWD;
430 static inline bool btf_is_typedef(const struct btf_type *t)
432 return btf_kind(t) == BTF_KIND_TYPEDEF;
435 static inline bool btf_is_volatile(const struct btf_type *t)
437 return btf_kind(t) == BTF_KIND_VOLATILE;
440 static inline bool btf_is_const(const struct btf_type *t)
442 return btf_kind(t) == BTF_KIND_CONST;
445 static inline bool btf_is_restrict(const struct btf_type *t)
447 return btf_kind(t) == BTF_KIND_RESTRICT;
450 static inline bool btf_is_mod(const struct btf_type *t)
452 __u16 kind = btf_kind(t);
460 static inline bool btf_is_func(const struct btf_type *t)
462 return btf_kind(t) == BTF_KIND_FUNC;
465 static inline bool btf_is_func_proto(const struct btf_type *t)
467 return btf_kind(t) == BTF_KIND_FUNC_PROTO;
470 static inline bool btf_is_var(const struct btf_type *t)
472 return btf_kind(t) == BTF_KIND_VAR;
475 static inline bool btf_is_datasec(const struct btf_type *t)
477 return btf_kind(t) == BTF_KIND_DATASEC;
480 static inline bool btf_is_float(const struct btf_type *t)
482 return btf_kind(t) == BTF_KIND_FLOAT;
485 static inline bool btf_is_decl_tag(const struct btf_type *t)
487 return btf_kind(t) == BTF_KIND_DECL_TAG;
490 static inline bool btf_is_type_tag(const struct btf_type *t)
492 return btf_kind(t) == BTF_KIND_TYPE_TAG;
495 static inline bool btf_is_any_enum(const struct btf_type *t)
497 return btf_is_enum(t) || btf_is_enum64(t);
507 static inline __u8 btf_int_encoding(const struct btf_type *t)
509 return BTF_INT_ENCODING(*(__u32 *)(t + 1));
512 static inline __u8 btf_int_offset(const struct btf_type *t)
514 return BTF_INT_OFFSET(*(__u32 *)(t + 1));
517 static inline __u8 btf_int_bits(const struct btf_type *t)
519 return BTF_INT_BITS(*(__u32 *)(t + 1));
522 static inline struct btf_array *btf_array(const struct btf_type *t)
524 return (struct btf_array *)(t + 1);
527 static inline struct btf_enum *btf_enum(const struct btf_type *t)
529 return (struct btf_enum *)(t + 1);
534 static inline struct btf_enum64 *btf_enum64(const struct btf_type *t)
536 return (struct btf_enum64 *)(t + 1);
565 static inline struct btf_member *btf_members(const struct btf_type *t)
567 return (struct btf_member *)(t + 1);
571 static inline __u32 btf_member_bit_offset(const struct btf_type *t,
574 const struct btf_member *m = btf_members(t) + member_idx;
575 bool kflag = btf_kflag(t);
580 * Get bitfield size of a member, assuming t is BTF_KIND_STRUCT or
583 static inline __u32 btf_member_bitfield_size(const struct btf_type *t,
586 const struct btf_member *m = btf_members(t) + member_idx;
587 bool kflag = btf_kflag(t);
592 static inline struct btf_param *btf_params(const struct btf_type *t)
594 return (struct btf_param *)(t + 1);
597 static inline struct btf_var *btf_var(const struct btf_type *t)
599 return (struct btf_var *)(t + 1);
603 btf_var_secinfos(const struct btf_type *t)
605 return (struct btf_var_secinfo *)(t + 1);
609 static inline struct btf_decl_tag *btf_decl_tag(const struct btf_type *t)
611 return (struct btf_decl_tag *)(t + 1);