qmi_send_message(9)
π qmi_send_message(9) π
okay so bestie, welcome to the Kernel API Manual β this is the qmi_send_message(9) page and honestly it's a whole vibe. it's giving "one function, eight arguments, zero chill" β¨
β¨ NAME β¨
qmi_send_message β send a QMI message π«Ά
πΈ SYNOPSIS πΈ
ssize_t qmi_send_message (struct qmi_handle *qmi , struct sockaddr_qrtr
*sq , struct qmi_txn *txn , int type , int msg_id , size_t len , const
struct qmi_elem_info *ei , const void *c_struct );
like, yes, that's a lot of parameters. count them. eight. she's an icon, she's a legend, she is the moment π
π ARGUMENTS π
qmiβ the QMI client handle. your main character struct πsqβ destination sockaddr. this is where the message is going, iykyktxnβ the transaction object to use for the message. gotta keep track of your business fr frtypeβ type of message to sendmsg_idβ message id. her little name tag π·οΈlenβ max length of the QMI messageeiβ QMI message description. the blueprint, the vision board πc_structβ object to be encoded. the raw material bestie π
π¦ DESCRIPTION π¦
so here's the tea, and I mean the literal encoding tea β
This function encodes c_struct using ei into a message of type type, with msg_id and txn into a buffer of maximum size len, and sends this to sq.
the way that it justβ¦ takes your struct, reads the description, builds the message, and ships it off? obsessed. no cap, that's the whole function. lowkey elegant, highkey iconic β¨
π₯ RETURN π₯
0 on success, negative errno on failure.
so like β zero means slay π , negative errno means something went sideways and you should probably go look at it π
ngl bestie, check your return value. always. no exceptions. not me being serious for one second π
β SEE ALSO β
Kernel file ./drivers/soc/qcom/qmi_interface.c β and honestly the whole qmi friend group showed up for this one:
qmi_recv_new_server(9)qmi_recv_del_server(9)qmi_recv_bye(9)qmi_recv_del_client(9)qmi_add_lookup(9)qmi_add_server(9)qmi_txn_init(9)qmi_txn_wait(9)qmi_txn_cancel(9)qmi_invoke_handler(9)qmi_handle_net_reset(9)qmi_handle_init(9)qmi_handle_release(9)qmi_send_request(9)qmi_send_response(9)qmi_send_indication(9)
the whole squad, together again π«Άπ
and that's the page!! mwah π this gem lives in ./drivers/soc/qcom and it was dated October 2026 β so like, future vibes only. go forth and send some messages bestie, you've got this π§ββοΈπ
π¦ 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