batadv_forw...t_list_steal(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

okay so, hi bestie, this is batadv_forw...t_list_steal(9) straight out of the Kernel API Manual, and the whole vibe is: batadv_forw_packet_list_steal β€” it claims a list of forward packets so they can get free()'d. that's it, that's the job. 🫢


✨ SYNOPSIS ✨

void batadv_forw_packet_list_steal (struct hlist_head *forw_list ,
struct hlist_head *cleanup_list , const struct batadv_hard_iface
*hard_iface );

no cap, that's the whole signature β€” copy it exactly, she's particular about her types πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • forw_list β€” the forward packets that are about to get stolen. yes, stolen. it's giving heist movie πŸ¦‹
  • cleanup_list β€” a backup pointer, so you can still dispose of the packet later. literally the safety net, keep her close πŸ™ˆ
  • hard_iface β€” the interface you're stealing forward packets from.

🌸 DESCRIPTION 🌸

so here's the tea: this function claims responsibility to free any forw_packet queued up on the given hard_iface. like, it's volunteering as tribute 😭

and if hard_iface is NULL? bestie, it goes wide β€” forwarding packets on all hard interfaces will be claimed. main character energy, no interface left behind πŸ‘‘

the packets are being moved from the forw_list to the cleanup_list. and bestie, that move is the whole point β€” it makes it possible for already running threads to notice the claim. the way that concurrency works is genuinely iconic ⭐


πŸ¦‹ SEE ALSO πŸ¦‹

it all lives in the Kernel file ./net/batman-adv/send.c, and the whole friend group is here:


ngl bestie, if you're poking at forwarding packets from multiple threads, read the steal / was_stolen pair before you do anything. the claim is only visible because the packets got moved β€” that's the whole trick 🧚

and that's the page!! mwah πŸ’œ this one's from ./net/batman-adv, dated October 2026, filed under batadv_forw...t_list_steal(9) β€” go forth and steal responsibly, queen πŸ“βœ¨

πŸ“¦ where this page comes from