ksz_set_wol(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– ksz_set_wol(9) πŸ’–

okay so bestie, we're in the kernel API manual and this page is literally called ksz_set_wol(9) β€” it's giving "Wake-on-LAN but make it DSA". let's get into it 🫢


✨ NAME ✨

ksz_set_wol β€” Set Wake-on-LAN settings for a specified port. that's it, that's the whole vibe. πŸ”₯


🌈 SYNOPSIS 🌈

int ksz_set_wol (struct dsa_switch *ds , int port , struct
       ethtool_wolinfo *wol );

πŸŽ€ ARGUMENTS πŸŽ€

  • ds β€” The dsa_switch structure. your main character struct, ngl πŸ’…
  • port β€” The port number. which port are we waking up bestie
  • wol β€” Pointer to ethtool Wake-on-LAN settings structure. this is where the WoL tea lives β˜•

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so this function configures Wake-on-LAN (WoL) settings for a specified port. it's literally doing a whole routine, watch:

  1. it validates the provided WoL options βœ…
  2. it checks if PME is enabled and supported πŸ‘€
  3. it clears any previous wake reasons 🧹 (out with the old)
  4. it sets the Magic Packet flag in the port's PME control register β€” but only if specified ✨

no cap, it's a little pipeline of self-care for your NIC 🧚


πŸ’œ RETURN πŸ’œ

  • 0 on success 😌
  • or other error codes on failure 😭 (things happen)

⭐ SEE ALSO ⭐

Kernel file ./drivers/net/dsa/microchip/ksz_common.c β€” that's the source house, go visit 🏠

and the whole friend group, in order:


πŸ’‘ reminder bestie: every one of these is in the same directory and listed on the page β€” don't skip any, they're all invited to the function party πŸŽ‰

🌸 that's the whole page! written up in ./drivers/net/dsa/microchip, dated October 2026, and the manual name on the tin is ksz_set_wol(9). periodt. go wake something up responsibly, ily πŸ’–πŸŽ€βœ¨

πŸ“¦ where this page comes from