usb_stop_hcd(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… usb_stop_hcd β€” the Kernel API Manual, bestie edition ✨

okay so we're in the Kernel API Manual today, and the star of the show is usb_stop_hcd(9). she's short, she's sweet, she's the one who turns the lights off πŸ•―οΈ


🌸 NAME 🌸

usb_stop_hcd β€” literally just halt the HCD, no cap πŸ›‘


πŸ¦‹ SYNOPSIS πŸ¦‹

void usb_stop_hcd (struct usb_hcd *hcd );

that's it. that's the whole vibe check. she takes one pointer and returns nothing (void), periodt πŸ’œ


πŸŽ€ ARGUMENTS πŸŽ€

  • hcd β€” the struct usb_hcd that has to be halted 🫢 like, the actual host controller thing you're putting to sleep. this is the one thing you gotta hand her.

✨ DESCRIPTION ✨

okay so here's what she does, and it's honestly iconic in how simple it is:

  • she stops the root-hub polling timer ⏰ β€” no more polling, we're done here
  • then she invokes the HCD's ->stop callback πŸ”₯ β€” handing the actual shutdown off to the driver's own stop routine

that's the whole function. two things. very main character energy for such a tiny amount of code πŸ’… ngl, sometimes the smallest functions ate the hardest.


πŸ‘‘ SEE ALSO πŸ‘‘

if you wanna go deeper (and you know you do, iykyk), the kernel file ./drivers/usb/core/hcd.c is where it all lives πŸ’– and here's the whole friend group, all present and accounted for:

like a whole group chat of USB core functions, and usb_stop_hcd is the one who says "okay guys, wrap it up" 😭🫢


reminder bestie: this page is straight out of ./drivers/usb/core, dated October 2026 πŸ“…βœ¨ so go forth, halt that HCD, and slay the shutdown πŸ’…πŸ’–πŸŒ·
πŸ“¦ where this page comes from