mbox_chan_tx...ts_available(9)
π mbox_chan_tx_slots_available(9) π
okay bestie, welcome to the Kernel API Manual β this is the page for mbox_chan_tx_slots_available, and yes we're gonna make mailbox queues make sense together π«Ά
β¨ NAME β¨
mbox_chan_tx_slots_available β literally just tells you how many free TX queue slots you've got left, no cap π
πΈ SYNOPSIS πΈ
unsigned int mbox_chan_tx_slots_available (struct mbox_chan *chan );
π ARGUMENTS π
chanβ the mailbox channel you're snooping on, iykyk. That's the one you're querying π¦
π DESCRIPTION π
So here's the vibe: clients can call this to check how many messages they can still queue up via mbox_send_message before the channel's TX queue is, like, completely full π
It's giving preventative self-care β this is how you dodge the -ENOBUFS error without having to go increase MBOX_TX_QUEUE_LEN. iconic behavior honestly π
And the best part? This can be called from atomic context. slay β¨
π₯ RETURN π₯
The number of available slots in the channel's TX queue. that's it, that's the tea π
π SEE ALSO π
Kernel file ./drivers/mailbox/mailbox.c β and the whole friend group:
mbox_chan_received_data(9)mbox_chan_txdone(9)mbox_client_txdone(9)mbox_client_peek_data(9)mbox_send_message(9)mbox_flush(9)mbox_bind_client(9)mbox_request_channel(9)mbox_free_channel(9)mbox_controller_register(9)mbox_controller_unregister(9)devm_mbox_controller_register(9)
ngl, if you're about to hit a full queue and you skip this check, that's on you bestie π
okay that's the whole page!! it lives in ./drivers/mailbox, the version vibes are from October 2026, and the page signature at the bottom is mbox_chan_tx...ts_available(9) β go forth and queue responsibly, mwah π§π
π¦ 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