hinic_api_cmd_write(9)
π hinic_api_cmd_write β from the Kernel API Manual bestie, no cap π
Okay so this little icon is hinic_api_cmd_write, and yeah, the manual it lives in is literally called the Kernel API Manual. We are in kernel-land now, so grab a lil snack and let's go π
β¨ NAME β¨
hinic_api_cmd_write β the one that writes an API CMD command π
πΈ SYNOPSIS πΈ
int hinic_api_cmd_write (struct hinic_api_cmd_chain *chain , enum
hinic_node_id dest , u8 *cmd , u16 size );
That's the whole vibe check. int going in, int coming out, four args doing the absolute most π«Ά
π¦ ARGUMENTS π¦
chainβ the chain for the write command. Think of it as the group chat the message gets posted in π¬destβ the destination node on the card that will receive the command. Like, who's the lucky recipient πcmdβ the command data itself, bestie. The actual message πsizeβ the command size. Gotta know how much of thecmdwe're actually sending, fr fr π
π DESCRIPTION π
It returns 0 for Success and a negative value for Failure. That's the read. Zero is slay, negative is not me crying in the kernel π
Like, genuinely: check that return value. Negative means something went sideways, and it's not gonna text you back about it π
π SEE ALSO π
The source lives right here in the kernel, no cap:
./drivers/net/ethernet/huawei/hinic/hinic_hw_api_cmd.c
And the whole friend group β every single one of these, mwah π
chain_busy(9)get_cell_data_size(9)prepare_cell_ctrl(9)prepare_api_cmd(9)prepare_cell(9)api_cmd_status_update(9)wait_for_status_poll(9)wait_for_api_cmd_completion(9)api_cmd(9)api_cmd_hw_restart(9)api_cmd_ctrl_init(9)api_cmd_set_status_addr(9)api_cmd_set_num_cells(9)api_cmd_head_init(9)api_cmd_chain_hw_clean(9)api_cmd_chain_hw_init(9)free_cmd_buf(9)alloc_cmd_buf(9)api_cmd_create_cell(9)api_cmd_destroy_cell(9)api_cmd_destroy_cells(9)api_cmd_create_cells(9)api_chain_init(9)api_chain_free(9)api_cmd_create_chain(9)api_cmd_destroy_chain(9)hinic_api_cmd_init(9)hinic_api_cmd_free(9)
π that's the whole page, periodt π
And for the sign-off: this one came from the source at ./drivers/net/ethernet/huawei/... and is dated October 2026, page hinic_api_cmd_write(9) β mwah, drink some water, go read the rest of the chain functions π§π
π¦ 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