sof_ipc4_get_audio_fmt(9)
π sof_ipc4_get_audio_fmt(9) π
okay so this is a page from the Kernel API Manual, bestie, and it's genuinely so niche and so iconic at the same time. it's all about sof_ipc4_get_audio_fmt β a function that pulls the list of available audio formats out of swidget->tuples. yep. that's the whole vibe. let's get into it π
β¨ NAME β¨
sof_ipc4_get_audio_fmt β get available audio formats from swidget->tuples
like literally, that's its job. it goes and fetches the audio formats that are chillin' inside swidget->tuples. no cap π«Ά
πΈ SYNOPSIS πΈ
int sof_ipc4_get_audio_fmt (struct snd_soc_component *scomp , struct
snd_sof_widget *swidget , struct sof_ipc4_available_audio_format
*available_fmt , struct sof_ipc4_base_module_cfg *module_base_cfg );
it returns an int, and yes it takes four args, we love a four-arg moment π
π¦ ARGUMENTS π¦
scompβ pointer to pointer to SOC component. yes, pointer to pointer. double the pointer, double the slay β¨swidgetβ pointer tostruct snd_sof_widgetcontaining tuples. this is where the audio formats are actually living, iykyk πavailable_fmtβ pointer tostruct sof_ipc4_available_audio_formatbeing filling in. that's what the page says, "being filling in", and honestly? we're keeping it exactly as is. it's the format struct that's getting filled in π§module_base_cfgβ Pointer to thebase_configin the module init IPC payload. capital P, we respect it π₯
β RETURN β
0 if successful. that's it. that's the return value. zero means we ate and left no crumbs π
π SEE ALSO π
- Kernel file
./sound/soc/sof/ipc4-topology.cβ go read it, bestie, that's where the lore lives π
lowkey important reminder: keep every path and param name exactly as written, no renaming, no merging, no inventing. we're cute but we're accurate π
okay that's the whole page!! short and sweet and honestly kind of a main character for a kernel function. this gem comes to you from ./sound/soc/sof, dated October 2026 β so yes, it's lowkey from the future, and it's giving time traveler energy π¦β¨ bye bestie, go fill in those formats π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms