cmdq_pkt_write_mask(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ cmdq_pkt_write_mask(9) ✨

okay so bestie, this is a page from the Kernel API Manual and it's literally about cmdq_pkt_write_mask β€” appending a write command with a mask to the CMDQ packet πŸ’… no cap, that's the whole NAME section, we move.


🌸 SYNOPSIS 🌸

int cmdq_pkt_write_mask (struct cmdq_pkt *pkt , u8 subsys , u16 offset ,
u32 value , u32 mask );

that's it. that's the signature. it returns an int, she's giving "I might fail and I'll tell you why" energy πŸŽ€


πŸ¦‹ ARGUMENTS πŸ¦‹

  • pkt β€” the CMDQ packet πŸ’– literally the packet you're stuffing this command into.
  • subsys β€” the CMDQ sub system code πŸ”₯ it's a u8, so keep it cute and small.
  • offset β€” register offset from CMDQ sub system ✨ a u16, iykyk.
  • value β€” the specified target register value πŸ‘‘ this is the actual number you want in there.
  • mask β€” the specified target register mask 🌈 the mask that decides which bits of value actually get to be main character.

⭐ RETURN ⭐

0 for success 🫢 otherwise the error code is returned β€” so like, check it, don't just vibe past it 😭

fr fr: 0 means slay, anything else means something went sideways and you should look at the error code.

🧚 SEE ALSO 🧚

Kernel file ./include/linux/soc/mediatek/mtk-cmdq.h πŸ’œ β€” go read it, it's giving source of truth.

then the whole friend group, and yes we're listing every single one because the original said so:


that's the whole page, bestie πŸ’… this cutie lives at ./include/linux/soc/mediatek, dated October 2026, and she answers to cmdq_pkt_write_mask(9) β€” mwah, go write some masked registers πŸŽ€βœ¨

πŸ“¦ where this page comes from