STRUCT VSC73XX(9)
π struct vsc73xx π
okay so welcome to the Kernel API Manual bestie, today we're doing struct vsc73xx and honestly? she's the main character of this whole file. this is the VSC73xx state container: main data structure β¨ like, everything else in this driver kinda orbits around her, no cap.
β¨ NAME β¨
struct vsc73xx β the VSC73xx state container, aka the main data structure π«Ά
πΈ SYNOPSIS πΈ
struct vsc73xx {
struct device *dev;
struct gpio_desc *reset;
struct dsa_switch *ds;
struct gpio_chip gc;
u16 chipid;
u8 addr[ETH_ALEN];
const struct vsc73xx_ops *ops;
void *priv;
struct vsc73xx_portinfo portinfo[VSC73XX_MAX_NUM_PORTS];
struct list_head vlans;
struct mutex fdb_lock;
};
like, look at her. iconic. every single field accounted for π
π«Ά MEMBERS π«Ά
every field gets her moment, let's go:
devβ The device pointer. yeah that's it, that's the whole vibe, she just points at the device πresetβ The descriptor for the GPIO line tied to the reset pin. so when you gotta β¨ reset β¨ her, this is the line you pokedsβ Pointer to the DSA core structure. the DSA girlies stay connected πgcβ Main structure of the GPIO controller. she's in charge of the GPIOs, lowkey a whole managerchipidβ Storage for the Chip ID value read from theCHIPIDregister of the switch. literally just holding the ID so nobody has to go ask the switch again πaddrβ MAC address used in flow control frames. yes bestie, an actual MAC address, it lives inaddr[ETH_ALEN]opsβ Structure with hardware-dependent operations. the hardware-specific stuff goes here so the rest of us can pretend it's all the same π¦privβ Pointer to the configuration interface structure. the ~private~ one, iykykportinfoβ Storage table portinfo structructures. yes the typo is canon, i don't make the rules π it's a whole table ofstruct vsc73xx_portinfovlansβ List of configured vlans. Contains port mask and untagged status of every vlan configured in port vlan operation. It doesn't cover tag_8021q vlans. β so important: port mask + untagged status per vlan, but not the tag_8021q ones, don't come for her for thatfdb_lockβ Mutex protects fdb access. hold the lock, bestie, or the fdb gets messy π
fr fr, that vlans note is the one people get wrong: tag_8021q vlans are simply not in this list. periodt.
π SEE ALSO π
- Kernel file
./drivers/net/dsa/vitesse-vsc73xx.hβ go read the header, she's right there π§ struct vsc73xx_portinfo(9)struct vsc73xx_ops(9)struct vsc73xx_bridge_vlan(9)
and that's the page, bestie π this lil masterpiece lives in ./drivers/net/dsa, it's dated October 2026, and it's filed under struct vsc73xx(9) β go forth and read the header, ily, bye ππ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms