validate_vlan(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– validate_vlan(9) β€” the Kernel API Manual glow-up πŸ¦‹

okay bestie, welcome to the <pink>validate_vlan</pink> page from the Kernel API Manual, section 9. yes we're in kernel-land. yes it's giving driver internals. no you're not scared, you're gonna slay ✨


🌸 NAME 🌸

validate_vlan β€” literally just checks if the ice_vlan you passed in is valid. that's it. that's the whole job. icon behaviour honestly πŸ‘‘


✨ SYNOPSIS ✨

bool validate_vlan (struct ice_vsi *vsi , struct ice_vlan *vlan );

she returns a bool. short. sweet. decisive. we love a function that knows what she is πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • vsi β€” the VSI that gets used for printing the error message πŸ‘€ so like, if something's off, this is who's gonna be talking about it.
  • vlan β€” the ice_vlan structure that's getting validated. the main character of this whole operation fr fr.

πŸ’œ DESCRIPTION πŸ’œ

so here's the vibe check 🧚 this returns true if the VLAN TPID is valid β€” full stop, that's a pass.

it also returns true if the VLAN TPID is 0 and the VLAN VID is 0. and why do we care, you ask? because that combo lowkey unlocks two things:

  • non-zero VLAN filters with the specified VLAN TPID can be added to the prune list
  • untagged VLAN 0 filters can be added to the prune list

respectively, bestie. respectively. 😌 the way that one little true does so much heavy lifting... we're obsessed.


πŸ¦‹ SEE ALSO πŸ¦‹

the kernel file lives right here, no cap:

./drivers/net/ethernet/intel/ice/ice_vsi_vlan_lib.c

and the whole friend group πŸ’–:


ngl if you're reading this at 3am in ./drivers/net/ethernet/intel/ice, drink some water, bestie. the VLANs will still be there tomorrow 🫢

🌈 sign-off time, and it's a whole moment 🌈 β€” this page ships from ./drivers/net/ethernet/intel/ice, dated October 2026, and it's ✨validate_vlan(9)✨ forever and ever, periodt πŸ’…πŸ’–πŸŽ€

πŸ“¦ where this page comes from