ENUM HWSIM_COMMANDS(9)
π enum hwsim_commands(9) π
okay so bestie, welcome to the enum hwsim_commands</p> page from the Kernel API Manual β yes, this is the actual kernel docs, and yes it's about the commands that hwsim supports. buckle up, it's a whole vibe β¨
πΈ NAME πΈ
enum hwsim_commands β literally the list of supported hwsim commands. that's it, that's the whole name. slay. π
β¨ SYNOPSIS β¨
enum hwsim_commands {
HWSIM_CMD_UNSPEC ,
HWSIM_CMD_REGISTER ,
HWSIM_CMD_FRAME ,
HWSIM_CMD_TX_INFO_FRAME ,
HWSIM_CMD_NEW_RADIO ,
HWSIM_CMD_DEL_RADIO ,
HWSIM_CMD_GET_RADIO ,
HWSIM_CMD_ADD_MAC_ADDR ,
HWSIM_CMD_DEL_MAC_ADDR ,
HWSIM_CMD_START_PMSR ,
HWSIM_CMD_ABORT_PMSR ,
HWSIM_CMD_REPORT_PMSR ,
__HWSIM_CMD_MAX
};
like, that's the roster. the whole friend group. let's meet them one by one π«Ά
π Constants π
HWSIM_CMD_UNSPECβ the unspecified command, aka the vibe-check catch-all that exists to catch errors. it's giving "placeholder but make it functional" πHWSIM_CMD_REGISTERβ a request to register, and then you receive all the broadcasted frames from anymac80211_hwsimradio device. no cap, all of them. π‘HWSIM_CMD_FRAMEβ send/receive a broadcasted frame from/to kernel/user space. uses:HWSIM_ATTR_ADDR_TRANSMITTER,HWSIM_ATTR_ADDR_RECEIVER,HWSIM_ATTR_FRAME,HWSIM_ATTR_FLAGS,HWSIM_ATTR_RX_RATE,HWSIM_ATTR_SIGNAL,HWSIM_ATTR_COOKIE,HWSIM_ATTR_FREQ(optional). that optional tho πHWSIM_CMD_TX_INFO_FRAMEβ transmission info report going from user space to kernel. uses:HWSIM_ATTR_ADDR_TRANSMITTER,HWSIM_ATTR_FLAGS,HWSIM_ATTR_TX_INFO,HWSIM_ATTR_TX_INFO_FLAGS,HWSIM_ATTR_SIGNAL,HWSIM_ATTR_COOKIE. receipts, basically π§ΎHWSIM_CMD_NEW_RADIOβ create a new radio with the given parameters. returns the radio ID (>= 0) or negative on errors, and if it's successful then it multicasts the result. it uses these optional parameters:HWSIM_ATTR_REG_STRICT_REG,HWSIM_ATTR_SUPPORT_P2P_DEVICE,HWSIM_ATTR_DESTROY_RADIO_ON_CLOSE,HWSIM_ATTR_CHANNELS,HWSIM_ATTR_NO_VIF,HWSIM_ATTR_RADIO_NAME,HWSIM_ATTR_USE_CHANCTX,HWSIM_ATTR_REG_HINT_ALPHA2,HWSIM_ATTR_REG_CUSTOM_REG,HWSIM_ATTR_PERM_ADDR. main character energy fr fr πHWSIM_CMD_DEL_RADIOβ destroy a radio. the reply is multicasted. rip radio, you had a good run πHWSIM_CMD_GET_RADIOβ fetch information about existing radios. uses:HWSIM_ATTR_RADIO_ID. just checking in on them, love that for us πHWSIM_CMD_ADD_MAC_ADDRβ add a receive MAC address (given in theHWSIM_ATTR_ADDR_RECEIVERattribute) to a device identified byHWSIM_ATTR_ADDR_TRANSMITTER. this lets wmediumd forward frames to this receiver address for a given station. iconic forwarding behaviour πHWSIM_CMD_DEL_MAC_ADDRβ remove the MAC address again, and the attributes are the exact same as forHWSIM_CMD_ADD_MAC_ADDR. undo button energy πHWSIM_CMD_START_PMSRβ request to start peer measurement with theHWSIM_ATTR_PMSR_REQUEST. the result gets sent back asynchronously withHWSIM_CMD_REPORT_PMSR. not me waiting for the async callback πHWSIM_CMD_ABORT_PMSRβ abort a previously started peer measurement. nvm bestie, cancel that πHWSIM_CMD_REPORT_PMSRβ report peer measurement data. the results are in! π__HWSIM_CMD_MAXβ enum limit. the end of the list, the boundary, the little fence at the bottom of the page π
π¦ SEE ALSO π¦
kernel file ./drivers/net/wireless/virtual/mac80211_hwsim.h enum hwsim_tx_control_flags(9), Frame transmission/registration support(9), enum hwsim_attrs(9), struct hwsim_tx_rate(9), enum hwsim_tx_rate_flags(9), struct hwsim_tx_rate_flag(9), Frame transmission support over virtio(9), enum hwsim_vqs(9), enum hwsim_rate_info_attributes(9)
go read them. i'll wait. π
friendly reminder bestie: this is kernel API territory, so keep the details exact β the attributes and command names above are literally the contract π
and that's the page!! π sign-off time: this one lives under ./drivers/net/wireless/virtual, dated October 2026, and it's the enum hwsim_commands(9) page β go off, kernel bestie, you ate that π«Άβ¨
π¦ 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