STRUCT SOF_TOPOLOGY_TOKEN(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸŽ€ struct sof_topology_token(9) πŸŽ€

okay bestie, welcome to the Kernel API Manual β€” this is the page for struct sof_topology_token(9) and honestly? it's giving "tiny struct, big job" energy. let's get into it πŸ’…

✨ NAME ✨

struct sof_topology_token β€” the SOF topology token definition, aka the lil blueprint that says "here's a token, here's what it looks like, and here's how to shove its value into an object" 🫢

✨ SYNOPSIS ✨

struct sof_topology_token {
    u32 token;
    u32 type;
    int (*get_token)(void *elem, void *object, u32 offset);
    u32 offset;
 };

like. look at her. four fields. no cap, she's iconic πŸ’–

✨ Members ✨

  • token β€” the Token number. that's the ID, the name tag, the "who dis" of the whole thing 🏷️
  • type β€” the Token type. because every token's gotta have a vibe, and this is hers ✨
  • get_token β€” a function pointer that parses the token value and saves it in a object. literally the main character of this struct, she does the actual work πŸ”₯ (and yes, the original says "a object" β€” we do not fix, we do not touch, we respect the source πŸ™ˆ)
  • offset β€” the Offset within an object to save the token value into. think of it as the exact seat assignment so the value doesn't wander off and sit somewhere weird πŸŽ€

✨ SEE ALSO ✨

go check these out, bestie, they're all in the kernel file ./sound/soc/sof/sof-audio.h and they're lowkey a whole friend group πŸ‘‘

  • struct sof_ipc_pcm_ops(9)
  • struct sof_ipc_tplg_control_ops(9)
  • struct sof_ipc_tplg_widget_ops(9)
  • struct sof_ipc_tplg_ops(9)
  • struct snd_sof_pcm_stream_pipeline_list(9)

and that's the whole page, no crumbs left behind πŸ“ this little gem lives over in ./sound/soc/sof and the version/date stamp on her is October 2026 β€” so yeah, she's from the future and she ate πŸ’€βœ¨ mwah, go read the source, ily πŸ«ΆπŸ’œ

πŸ“¦ where this page comes from