cmdq_pkt_write_pa(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ cmdq_pkt_write_pa(9) ✨

okay so bestie, this is a page from the Kernel API Manual πŸ’– and honestly it's kind of a small icon β€” a little function that appends a write command to your CMDQ packet, but it does it with pa_base, which is the whole plot twist here. let's get into it πŸŽ€


🌸 NAME 🌸

cmdq_pkt_write_pa β€” append write command to the CMDQ packet with pa_base 🫢

πŸ¦‹ SYNOPSIS πŸ¦‹

int cmdq_pkt_write_pa (struct cmdq_pkt *pkt , u8 subsys , u32 pa_base ,
u16 offset , u32 value );

like… that's the whole signature, and yes the spacing is a little chaotic but she's iconic, we respect it πŸ’…

🌈 ARGUMENTS 🌈

  • pkt β€” the CMDQ packet πŸ™ˆ this is your main character, the thing you're appending to
  • subsys β€” unused parameter 😭 literally not used, it's just… there. a decorative parameter. we still love her
  • pa_base β€” the physical address base of the hardware register πŸ‘‘ this is the special sauce that makes this the _pa version
  • offset β€” register offset from CMDQ sub system ⭐
  • value β€” the specified target register value πŸ’œ the actual thing you want written, bestie

🌟 RETURN 🌟

0 for success πŸ’– … and if it's not 0, then the error code is returned. so like, vibe check the return value ngl 😭

fr fr, don't ignore the return value. 0 = she slayed, anything else = something went sideways and you get an error code back.

🧚 SEE ALSO 🧚

Kernel file ./include/linux/soc/mediatek/mtk-cmdq.h β€” that's the one, go look at it πŸŽ€

like… that's a whole friend group of functions and cmdq_pkt_write_pa is absolutely one of them, no cap 😌


and that's the page, bestie πŸ“ sourced from ./include/linux/soc/mediatek, dated October 2026, and filed under cmdq_pkt_write_pa(9) β€” mwah, go write some registers responsibly πŸ’…βœ¨

πŸ“¦ where this page comes from