wx_get_mac_addr(9)
π wx_get_mac_addr(9) β the Kernel API Manual page, but make it make sense π
okay bestie, so this is a page straight out of the Kernel API Manual, and it's lowkey one of the shortest ones you'll ever meet β but it's important, so pay attention π
β¨ NAME β¨
wx_get_mac_addr β the generic "gimme the MAC address" function π¦
β¨ SYNOPSIS β¨
void wx_get_mac_addr (struct wx *wx , u8 *mac_addr );
like, that's it. two args. in, out. slay π
β¨ ARGUMENTS β¨
wxβ pointer to hardware structure. it's giving "here's the whole adapter, bestie" πmac_addrβ Adapter MAC address. this is where the goods land, so make sure it's got room π
β¨ DESCRIPTION β¨
so what does it actually do? it reads the adapter's MAC address from the first Receive Address Register β that's RAR0, iykyk πΈ
β οΈ okay here's the part that matters, no cap: a reset of the adapter must be performed prior to calling this function in order for the MAC address to have been loaded from the EEPROM into RAR0. so if you skip the reset, don't come crying to me when RAR0 is empty, bestie π that's literally the whole vibe check of this function.
β¨ SEE ALSO β¨
the kernel file lives at ./drivers/net/ethernet/wangxun/libwx/wx_hw.c, and these are all the siblings in the family group chat π«Ά
wx_irq_disable(9)wx_mng_present(9)wx_release_sw_sync(9)wx_acquire_sw_sync(9)wx_host_interface_command(9)wx_read_ee_hostif_data(9)wx_read_ee_hostif(9)wx_read_ee_hostif_buffer(9)wx_init_eeprom_params(9)wx_set_rar(9)wx_clear_rar(9)wx_clear_vmdq(9)wx_init_uta_tables(9)wx_init_rx_addrs(9)wx_write_uc_addr_list(9)wx_mta_vector(9)wx_set_mta(9)wx_update_mc_addr_list(9)wx_write_mc_addr_list(9)wx_set_mac(9)wx_set_rxpba(9)wx_hpbthresh(9)wx_lpbthresh(9)wx_pbthresh_setup(9)wx_disable_sec_rx_path(9)wx_enable_sec_rx_path(9)wx_change_mtu(9)wx_configure_tx(9)wx_configure_rx(9)wx_disable_pcie_master(9)wx_stop_adapter(9)wx_get_pcie_msix_counts(9)wx_init_rss_key(9)wx_find_vlvf_slot(9)wx_set_vlvf(9)wx_set_vfta(9)wx_clear_vfta(9)wx_update_stats(9)wx_clear_hw_cntrs(9)wx_start_hw(9)
and that's the whole page, bestie!! π it came from ./drivers/net/ethernet/wangxun... and it's dated October 2026, so go forth and read your MAC addresses responsibly β¨π
π
π¦ 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