mtype_del_cidr(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ NAME ✨

Okay bestie, meet mtype_del_cidr(9) from the Kernel API Manual 🫢. Its whole vibe is Remove CIDR entry and maintain array integrity. Literally that’s the job β€” no cap πŸ’…. Think of it as the cleanup bestie that keeps the array looking cute and staying contiguous after a CIDR entry dips out.


πŸ’« SYNOPSIS πŸ’«

void mtype_del_cidr (struct ip_set *set , struct htype *h , u8 cidr , u8
n );

πŸŽ€ ARGUMENTS πŸŽ€

  • set β€” Pointer to the ip_set 🫢 yes, that ip_set.
  • h β€” Pointer to the htype.
  • cidr β€” The CIDR prefix length.
  • n β€” The index of the net_prefix array to remove cidr from.

πŸ”₯ DESCRIPTION πŸ”₯

If the CIDR entry count falls to 0, this function performs a "shift-left" operation on all following elements 😀. That’s the whole point: it ensures that the array remains contiguous and maintains its descending order by CIDR. Iconic behavior, honestly ✨. The vacated slot at the end of the array is zeroed out (cidr=0, count=0) β€” not me making it empty and tidy, it’s literally in the spec πŸ’€βœ¨.

bestie, this is the β€œkeep the array cute and contiguous” era πŸ’…

🌈 SEE ALSO 🌈

  • Kernel file ./net/netfilter/ipset/ip_set_hash_gen.h
  • struct net_prefix(9)
  • struct net_prefixes(9)
  • mtype_add_cidr(9)

β€” xoxo, sourced from ./net/netfilter/ipset, dated October 2026 πŸ’–πŸŽ€

πŸ“¦ where this page comes from