STRUCT RSEQ_IDS(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

struct rseq_ids(9) πŸ’…

Okay bestie, welcome to the Kernel API Manual page for struct rseq_ids β€” it's literally the cache for ids that need to be updated. Lowkey iconic little struct behavior. πŸŽ€


✨ NAME ✨

struct rseq_ids β€” Cache for ids, which need to be updated πŸ’–


πŸ¦‹ SYNOPSIS πŸ¦‹

struct rseq_ids {
    union {
      u64 cpu_cid;
      struct {
        u32 cpu_id;
        u32 mm_cid;
      };
    };
    u32 node_id;
 };

🌸 Members 🌸

  • {unnamed_union} β€” anonymous. The manpage literally says anonymous, and honestly? Same. πŸ™ˆ
  • cpu_cid β€” compound of cpu_id and mm_cid to make the compiler emit a single compare on 64-bit. Not me being obsessed with one compare, it's just efficient queen behavior. ⚑
  • {unnamed_struct} β€” anonymous.
  • cpu_id β€” the CPU ID which was written last to user space. πŸ’»
  • mm_cid β€” the MM CID which was written last to user space. 🧚
  • node_id β€” the node ID which was written last to user space. 🌈

πŸ’œ Description πŸ’œ

So the whole vibe is: cpu_id, mm_cid and node_id are updated when the data is written to user space. That's it, that's the plot. ✨


πŸ‘‘ SEE ALSO πŸ‘‘

Kernel file ./include/linux/rseq_types.h and the whole friend group:

  • struct rseq_event(9)
  • union rseq_slice_state(9)
  • struct rseq_slice(9)
  • struct rseq_data(9)
  • struct sched_mm_cid(9)
  • struct mm_cid_pcpu(9)
  • struct mm_mm_cid(9)

Source: ./include/linux, dated October 2026, page struct rseq_ids(9). Periodt. πŸ’‹πŸ«Ά

πŸ“¦ where this page comes from