phy_interface_num_ports(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– phy_interface_num_ports(9) πŸ’–

okay so welcome to the Kernel API Manual, bestie β€” today's main character is phy_interface_num_ports(9), and she is here to answer one very specific question.

πŸŽ€ NAME πŸŽ€

phy_interface_num_ports β€” returns the number of links that can be carried by a given MAC-PHY physical link. If that number is unknown, it returns 0; otherwise it returns the number of links. periodt.

✨ SYNOPSIS ✨

int phy_interface_num_ports (phy_interface_t interface );

🌸 ARGUMENTS 🌸

  • interface β€” the interface mode we wanna use to get the number of ports. that's the whole vibe check for this argument, no cap.

πŸ‘€ SEE ALSO πŸ‘€

Kernel file: ./drivers/net/phy/phy-core.c β€” and here's the whole bestie squad:


🫢 cute little sign-off: source/version ./drivers/net/phy, dated October 2026. mwah, go forth and count those links πŸ’…βœ¨
πŸ“¦ where this page comes from