skb_dstref_steal(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… skb_dstref_steal(9) β€” Kernel API Manual energy ✨

🌸 NAME 🌸

skb_dstref_steal β€” return current dst_entry value and clear it. That's literally the whole vibe: it gives you the current dst_entry and clears it. πŸ’…

✨ SYNOPSIS ✨

unsigned long skb_dstref_steal (struct sk_buff *skb );

πŸŽ€ ARGUMENTS πŸŽ€

  • skb β€” buffer. That's the buffer, bestie. 🫢

πŸ¦‹ DESCRIPTION πŸ¦‹

Okay so skb_dstref_steal resets the skb's dst_entry without adjusting its reference count. It's useful in cases where dst_entry needs to be temporarily reset and restored. ✨

Important note, bestie: the returned value cannot be used directly because it might contain the SKB_DST_NOREF bit. 😭

⚠️ When in doubt, prefer skb_dst_drop over skb_dstref_steal to correctly handle dst_entry reference counting. That's the recommendation, no cap. πŸ’–

πŸ”₯ RETURN πŸ”₯

The original skb dst_entry. That's what comes back to you, bestie. πŸ’…

πŸ’– SEE ALSO πŸ’–

The whole kernel skb friend group, in order, no skips: πŸ‘‘


Source/version: ./include/linux Β· date: October 2026 β€” mwah, bestie, you ate πŸ’‹πŸ’–

πŸ“¦ where this page comes from