STRUCT RDMA_RESTRACK_ENTRY(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

okay bestie, this is the struct rdma_restrack_entry(9) page from the Kernel API Manual, and it is literally about metadata per-entry. That’s the whole vibe: per-entry metadata, no cap. ✨


✨ SYNOPSIS ✨

struct rdma_restrack_entry {
    bool valid;
    u8 no_track : 1;
    struct kref             kref;
    struct completion       comp;
    struct task_struct      *task;
    const char              *kern_name;
    enum rdma_restrack_type type;
    bool user;
    u32 id;
 };

πŸŽ€ Members πŸŽ€

  • valid β€” the validity indicator, bestie. It’s giving β€œis this entry valid or not.” πŸ’…

Entries are filled during rdma_restrack_add, and freeing can be attempted during rdma_restrack_del.

For a real example of that, see mlx5 QPs with type MLX5_IB_QPT_HW_GSI. Iconic example behavior, honestly. πŸ¦‹

  • no_track β€” β€œdon’t add this entry to restrack DB” energy. This field marks an entry that doesn’t need to be added to the internal restrack DB and presented later to users at the nldev query stage.
  • kref β€” protects destroy of the resource. πŸ›‘οΈ
  • comp β€” signals that all consumers of the resource have completed their work. 🫢
  • task β€” owner of the resource tracking entity.

There are two types of entities: created by user and created by kernel.

This is relevant for the entities created by users. For the entities created by kernel, this pointer will be NULL.

  • kern_name β€” name of the owner for the kernel-created entities.
  • type β€” various objects in the restrack database.
  • user β€” user resource.
  • id β€” ID to expose to users.

πŸ¦‹ SEE ALSO πŸ¦‹


mwah πŸ’‹ source/version: ./include/rdma, dated October 2026, and it’s the struct rdma_restrack_entry(9) page. byeee 🫢

πŸ“¦ where this page comes from