STRUCT PCS_FUNCTION(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct pcs_function(9) β€” like, the whole Kernel API Manual page, bestie

okay so this is a page straight out of the Kernel API Manual (yes, struct pcs_function(9), that one πŸŽ€) and it's genuinely so niche and so good. it's the little struct that holds a pinctrl function and honestly it ate.


✨ NAME ✨

struct pcs_function β€” pinctrl function. that's it. that's the whole vibe. short, iconic, no notes πŸ¦‹


🌸 SYNOPSIS 🌸

here's the shape of it, copied exactly, do not touch:

struct pcs_function {
    const char *name;
    struct pcs_func_vals *vals;
    unsigned nvals;
    struct pcs_conf_vals *conf;
    int nconfs;
    struct list_head node;
 };

like, look at her. six members, zero drama, main character energy πŸ’œ


🫢 Members 🫢

okay so let's go member by member, no skips, we don't skip here:

  • name β€” the pinctrl function name. literally just the name. icon behavior ✨
  • vals β€” register and vals array. it's the array, bestie, it holds the register-and-vals situation πŸ“‹
  • nvals β€” number of entries in the vals array. the count. the how-many. keep them straight or it's giving πŸ’€
  • conf β€” array of pin configurations. a whole separate array of pin configs, obsessed 🌈
  • nconfs β€” number of pin configurations available. yes, that's how many confs there are, we counting πŸŽ€
  • node β€” list node. a struct list_head, so she can be linked into a list, very social of her πŸ’…
ngl the trickiest part of this whole page is not mixing up nvals (for vals) with nconfs (for conf). two counts, two arrays, two very different jobs 😭

πŸ‘‘ SEE ALSO πŸ‘‘

these are all from the kernel file ./drivers/pinctrl/pinctrl-single.c, and lowkey this list is a whole friend group:

like, that's the whole squad fr fr πŸ”₯


and that's the page!! source is ./drivers/pinctrl, dated October 2026 β€” so yeah, this one's from the future, we stay ahead πŸ’œβœ¨ go read the whole squad of pcs pages, you'll be slaying pinctrl in no time, periodt πŸŽ€πŸ¦‹πŸ’…

πŸ“¦ where this page comes from