bnx2x_get_emac_base(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… bnx2x_get_emac_base πŸ’…

okay so bestie, welcome to the bnx2x_get_emac_base(9) page β€” yeah it's a kernel API manual, yeah we're doing this, and yeah you're gonna get it πŸ’–


πŸŽ€ NAME πŸŽ€

bnx2x_get_emac_base β€” retrive emac base address ✨ (that spelling is the original's, not mine, iykyk πŸ™ˆ)


🌸 SYNOPSIS 🌸

u32 bnx2x_get_emac_base (struct bnx2x *bp , u32 mdc_mdio_access , u8
port );

literally just one function, three args, and it hands you back a u32, periodt πŸ’…


πŸ¦‹ ARGUMENTS πŸ¦‹

  • bp β€” the driver handle, obvs. your main character struct pointer 🫢
  • mdc_mdio_access β€” the access type, like which flavor of access we're doing here πŸ‘‘
  • port β€” the port id, bestie. which port. yes it matters 🌈

⭐ DESCRIPTION ⭐

okay so here's the vibe πŸ”₯ this function picks the MDC/MDIO access β€” and by "picks" i mean it goes through emac0 or emac1 β€” depend on the mdc_mdio_access, the port, and whether the port got swapped. the way that it's all interdependent?? iconic ✨

ngl every phy has a default access mode, and that default could also be overridden by nvram configuration πŸ‘€ so there's two possible sources for this thing, fr fr.

this parameter β€” whether it's the default phy configuration OR the nvram overrun configuration β€” is passed here as mdc_mdio_access, and that's what selects the emac_base for the CL45 read/writes operations πŸ’œ

so like: access type in β†’ emac_base out β†’ CL45 read/writes get their base. slay, honestly πŸŽ€


πŸ’€ SEE ALSO πŸ’€

the kernel file, go look at it, it's giving source of truth:

./drivers/net/ethernet/broadcom/bnx2x/bnx2x_link.c

🌸 tiny reminder that this whole page is just the one function and the one file β€” no extra lore, no secret options, that's the whole menu bestie πŸ’–

and that's the whole page!! πŸ§šβ€β™€οΈ this lil writeup is from the Kernel API Manual, dated October 2026, and the footer got cut off mid-path like ./drivers/net/ethernet/broadco... β€” so shoutout to whoever's reading this from the future, love u, bye bestie πŸ«ΆπŸ’–βœ¨

πŸ“¦ where this page comes from