STRUCT EF10_VF(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct ef10_vf(9) πŸ’–

okay bestie, welcome to struct ef10_vf β€” this is straight out of the Kernel API Manual, and it's literally the PF's little storage locker for all its VF data. Like, the physical function keeps receipts on every virtual function it hands out. Very organized. Very demure. We stan a bookkeeping queen. πŸ‘‘


✨ SYNOPSIS ✨

struct ef10_vf {
    struct efx_nic *efx;
    struct pci_dev *pci_dev;
    unsigned int vport_id;
    unsigned int vport_assigned;
    u8 mac[ETH_ALEN];
    u16 vlan;
  #define EFX_EF10_NO_VLAN       0;
 };

That's the whole squad, no cap. Now let's meet them one by one 🫢


πŸŽ€ Members πŸŽ€

  • efx β€” the efx_nic struct for the current VF. Basically the main character's whole identity card. πŸͺͺ
  • pci_dev β€” the pci_dev struct for the VF, and here's the tea: it's retained while the VF is assigned. So it sticks around for as long as the VF is holding its spot. πŸ’…
  • vport_id β€” the vport ID for the VF. Its little name tag. 🏷️
  • vport_assigned β€” records whether the vport is currently assigned to the VF or not. A yes/no vibe check, stored forever. ✨
  • mac β€” the MAC address for the VF. And, important detail bestie: it's zero when the address is removed from the vport. So if you're seeing all zeros, that's not a bug, that's the address being gone-gone. 😭
  • vlan β€” the Default VLAN for the VF, or #EFX_EF10_NO_VLAN if there isn't one. And hey, remember the synopsis defines it as:
#define EFX_EF10_NO_VLAN       0;

So "no VLAN" is just a fancy way of saying 0. Iconic. πŸŽ€


🌈 SEE ALSO 🌈

  • Kernel file ./drivers/net/ethernet/sfc/ef10_sriov.h β€” go read the header bestie, it's all there fr fr πŸ”₯

ngl this page is short, but that's the vibe: one struct, six members, zero filler. Periodt. πŸ’œ

sign-off szn πŸ¦‹ β€” this one lives in ./drivers/net/ethernet/sfc, dated October 2026, and it's your girl struct ef10_vf(9) saying byeee, drink water, and don't forget to free your pci_dev πŸ“βœ¨

πŸ“¦ where this page comes from