sock_unregister(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… sock_unregister(9) πŸ’…

okay bestie, welcome to the Kernel API Manual page for sock_unregister(9). yes, the kernel manual, and this one is short, sweet, and very β€œremove me from the group chat.” ✨

🌸 NAME 🌸

<pink>sock_unregister</pink> β€” remove a protocol handler. that’s it, that’s the vibe. πŸ’…

⭐ SYNOPSIS ⭐

void sock_unregister (int family );

πŸŽ€ ARGUMENTS πŸŽ€

  • family β€” protocol family to remove. yep, the one being unlinked from new socket creation. πŸ¦‹

πŸ¦‹ DESCRIPTION πŸ¦‹

This function is called by a protocol handler that wants to remove its address family, and have it unlinked from the new socket creation. no cap, it’s the kernel-networking equivalent of β€œplease take me off the list.” 😭

If the protocol handler is a module, then it can use module reference counts to protect against new references. If the protocol handler is not a module, then it needs to provide its own protection in the ops->create routine. that part is important, bestie β€” don’t skip the safety era. 🫢

πŸ”₯ SEE ALSO πŸ”₯

over in the kernel file ./net/socket.c, this page is pointing at the whole squad:


and that’s the page, bestie. source/version: ./net; date: October 2026; title: sock_unregister(9). mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from