acm_cdc_notify(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… acm_cdc_notify β€” the "issue CDC notification to host" girlie πŸ’…

okay so real talk, this is a page from the Kernel API Manual, section 9, and it's all about acm_cdc_notify. yes bestie, that's the whole name. she's niche, she's specific, she's serving exactly one job and she does it flawlessly. πŸŽ€


✨ SYNOPSIS ✨

int acm_cdc_notify (struct f_acm *acm , u8 type , u16 value , void *data
, unsigned length );

like, look at her. five params, one int return, no notes. iconic behavior honestly. 🌸


🫢 ARGUMENTS 🫢

  • acm β€” this is the struct f_acm * that wraps the host you're notifying. she's the main character of this whole operation, lowkey. πŸ‘‘
  • type β€” the notification type. that's it, that's the vibe. 🌈
  • value β€” fr fr, just refer to the CDC specs for this one β€” it's the wValue field. iykyk. πŸ“–
  • data β€” the actual data to be sent. the payload. the moment. ✨
  • length β€” the size of data. keep it accurate bestie, no guessing. πŸ“

πŸ¦‹ CONTEXT πŸ¦‹

okay this is the part where you gotta read the room before you call her. when acm_cdc_notify runs, all of this needs to be true:

  • irqs blocked πŸ™ˆ
  • acm->lock held πŸ”’
  • acm_notify_req non-null βœ…
no cap, if you roll up in the wrong context she will not be happy with you. do the vibe check first. πŸ’€

πŸ’– DESCRIPTION πŸ’–

she returns zero on success, or a negative errno if things went sideways. clean, simple, no drama.

and if you're wondering what notification she's even issuing β€” go read section 6.3.5 of the CDC 1.1 specification. because there's literally only one notification we ever issue: SerialState change. that's it. that's the one. periodt. πŸ’…πŸ”₯


🌟 SEE ALSO 🌟

  • kernel file ./drivers/usb/gadget/function/f_acm.c β€” go read the source bestie, she's right there 🧚

and that's the whole page! stay hydrated, keep your locks held, and remember: this came to you from ./drivers/usb/gadget/function, dated October 2026, living in the Kernel API Manual. mwah πŸ’œπŸ“

πŸ“¦ where this page comes from