cs_dsp_set_dspclk(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… cs_dsp_set_dspclk (9) β€” a kernel API manual, but make it make sense

okay bestie, welcome to the kernel API manual, section 9, and today's main character is cs_dsp_set_dspclk πŸŽ€ no cap, this one's a tiny little function but she does exactly one job and she does it slayfully.


✨ NAME ✨

cs_dsp_set_dspclk β€” applies the given frequency to the given cs_dsp

like... that's it. that's the whole vibe. you hand her a frequency, she hands it to the cs_dsp. iconic behavior honestly πŸ¦‹


🌸 SYNOPSIS 🌸

int cs_dsp_set_dspclk (struct cs_dsp *dsp , unsigned int freq );

look at her. one return type, two arguments, zero drama (on ADSP2 cores at least, more on that in a sec πŸ’€).


πŸ’– ARGUMENTS πŸ’–

  • dsp β€” pointer to the DSP structure 🫢 so like, the actual cs_dsp we're messing with. she's the target of the whole operation, the main character if you will.
  • freq β€” the clock rate to set ⭐ literally the frequency. the number. the whole point. that's what's getting applied.

πŸ”₯ DESCRIPTION πŸ”₯

so here's the tea: this is only for use on ADSP2 cores πŸ’… periodt. not ADSP1, not Halo, not whatever else β€” ADSP2 only. if you're out here calling this on a non-ADSP2 core, that's not her job, bestie, read the room 😭

ngl the description is short because the function is short. lowkey refreshing honestly.


🌈 RETURN 🌈

  • Zero for success β€” slay ✨ we love a clean exit
  • a negative number on error β€” 😭 not the negative return, but at least it's honest

so like, check your return value. 0 = we ate. negative = we did not.


πŸ¦‹ SEE ALSO πŸ¦‹

and now, the girlies. the whole friend group. the extended cirrus cs_dsp cinematic universe πŸ‘‘

also worth peeking at the kernel file: ./drivers/firmware/cirrus/cs_dsp.c

like, go read them. iykyk 🧚


πŸ’€ friendly reminder before you go: ADSP2 cores only. don't come for me if you ignore that, i literally told you.

and that's the page, bestie πŸ’œ this lil manual lives under ./drivers/firmware/cirrus, dated October 2026, and yes she's still rocking her original title cs_dsp_set_dspclk(9) like the queen she is. mwah 🫢✨

πŸ“¦ where this page comes from