bpf_prog_create(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

okay bestie, welcome to bpf_prog_create(9) from the Kernel API Manual ✨ this one is literally about creating an unattached filter, and it's giving solo main character energy πŸ’…

🌸 NAME 🌸

bpf_prog_create β€” create an unattached filter 🫢

✨ SYNOPSIS ✨

int bpf_prog_create (struct bpf_prog **pfp , struct sock_fprog_kern
       *fprog );

πŸŽ€ ARGUMENTS πŸŽ€

  • pfp β€” the unattached filter that is created πŸ‘‘ yes, this is the new filter being made
  • fprog β€” the filter program 🌸

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so bpf_prog_create creates a filter that is independent of any socket β€” she does not need a socket to be attached to, she's doing her own thing πŸ”₯

First, it runs some sanity checks on the filter to make sure it does not explode on us later πŸ˜­πŸ’€. If an error occurs, or if there is insufficient memory for the filter, a negative errno code is returned. On success, the return is zero ✨ no cap.

bestie, quick vibe check: negative errno code = it did not slay; zero = success, periodt πŸ’…

🌈 SEE ALSO 🌈


cute little sign-off: this page comes from the ./net/core source/version and is dated October 2026 β€” bpf_prog_create(9), and that's the whole manual page, bestie πŸŽ€πŸ’œ

πŸ“¦ where this page comes from