STRUCT OF_ENDPOINT(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ struct of_endpoint(9) ✨

okay bestie, listen up πŸ’– we're in the Kernel API Manual today β€” yes, the Kernel API Manual, capital letters, very serious, very slay β€” and our main character is struct of_endpoint, aka the OF graph endpoint data structure πŸŽ€

It's giving "small struct, big responsibilities." Let's get into it πŸ¦‹


🌸 SYNOPSIS 🌸

Like, here's the whole entire thing, no cap:

struct of_endpoint {
    unsigned int port;
    unsigned int id;
    const struct device_node *local_node;
};

Three fields. That's it. That's the whole struct. Iconic minimalism honestly πŸ‘‘


πŸ’… Members πŸ’…

  • port β€” the identifier of a port this endpoint belongs to, and that identifier is literally the value of the reg property πŸ”₯ so yeah, reg is doing the heavy lifting here.
  • id β€” the identifier of this endpoint, again the value of the reg property. yes, another reg. it's reg all the way down 🫢
  • local_node β€” a pointer to the device_node of this endpoint. just a pointer, living its best life, pointing at a node πŸ’œ

πŸ¦‹ SEE ALSO πŸ¦‹

peep the kernel file ./include/linux/of_graph.h for these besties, they're all in the same friend group fr fr:


πŸ’€ no warnings on this page bestie, it's a chill little struct page. read it, love it, reference it responsibly ✨

okay and finally, the cute little sign-off πŸŽ€ this page lives under ./include/linux, dated October 2026, and it's struct of_endpoint(9) β€” so go forth and traverse the OF graph, you absolute legend πŸŒˆπŸ‘‘πŸ’–

πŸ“¦ where this page comes from