genlmsg_multicast_allns(9)
π genlmsg_multicast_allns β the kernel API manual, bestie edition β¨
okay so this is genlmsg_multicast_allns(9) from the Kernel API Manual, and it's literally the glow-up your netlink message needs when it wants to be everywhere at once. sit down, we're doing this π
β¨ NAME β¨
genlmsg_multicast_allns β multicast a netlink message to all net namespaces π
like, not just your namespace. ALL of them. main character energy fr fr π
π¦ SYNOPSIS π¦
int genlmsg_multicast_allns (const struct genl_family *family , struct
sk_buff *skb , u32 portid , unsigned int group );
look at her. four args, one int return, absolutely serving π«Ά
π ARGUMENTS π
familyβ the generic netlink family π (your whole vibe, basically)skbβ netlink message as socket buffer π¨ (the message itself, packaged and ready to go)portidβ own netlink portid, so you don't send it to yourself π (no cap, nobody wants that awkward self-DM energy)groupβ offset of the multicast group in thegroupsarray π― (your specific destination within the family)
β DESCRIPTION β
This function must hold theRTNLorrcu_read_lock.
okay so lowkey this is the important part bestie π β before you call this function you MUST be holding the RTNL or rcu_read_lock. no exceptions, that's the vibe check and you will fail it if you skip it π
π SEE ALSO π
the whole friend group π β kernel file ./include/net/genetlink.h, plus:
struct genl_multicast_group(9)struct genl_family(9)struct genl_info(9)struct genl_small_ops(9)struct genl_ops(9)struct genl_split_ops(9)struct genl_dumpit_info(9)genl_info_init_ntf(9)genlmsg_iput(9)genlmsg_nlhdr(9)genlmsg_parse_deprecated(9)genlmsg_parse(9)genl_dump_check_consistent(9)genlmsg_put_reply(9)genlmsg_end(9)genlmsg_cancel(9)genlmsg_multicast_netns_filtered(9)genlmsg_multicast_netns(9)genlmsg_multicast(9)genlmsg_unicast(9)genlmsg_reply(9)genlmsg_data(9)genlmsg_len(9)genlmsg_msg_size(9)genlmsg_total_size(9)genlmsg_new(9)genl_set_err(9)
that's a lot of besties but they all ate, no notes π₯
and that's the whole page, periodt π
this lil beauty lives in ./include/net, dated October 2026, and it's part of the Kernel API Manual β mwah, go multicast responsibly bestie πβ¨
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms