dma_channel_rebalance(9)
π dma_channel_rebalance β a Kernel API Manual moment (section 9, bestie)
okay so picture this: you're in the Kernel API Manual, section 9, and the function on the cover is dma_channel_rebalance. she's a void function, she takes nothing, and she's about to rearrange the whole channel situation. main character energy fr fr π
β¨ NAME β¨
dma_channel_rebalance β literally just redistribute the available channels. that's it. that's the whole job. iconic.
πΈ SYNOPSIS πΈ
void dma_channel_rebalance (void );
she takes no arguments, she returns nothing, she simply does. periodt π
π¦ ARGUMENTS π¦
voidβ no arguments. none. zero. the void is the vibe. ngl this is my favourite kind of parameter list π«Ά
π₯ DESCRIPTION π₯
okay so here's the tea β β this function optimizes for CPU isolation in the SMP case, meaning each CPU gets its own dedicated channel for an operation type. like, everyone gets their own room, no sharing, no drama β¨
and then in the non-SMP case, she optimizes for operation isolation instead β the whole point being to avoid multitasking channels. no cap, keep your operations separate, let them breathe πΈ
β οΈ bestie listen to me: this must be called under dma_list_mutex. not "should", not "ideally" β must. do not come crying to me when you skip the mutex ππ
π SEE ALSO π
Kernel file ./drivers/dma/dmaengine.c plus the whole squad, all of them, no one left out π:
dev_to_dma_chan(9)struct dma_chan_tbl_ent(9)dma_chan_is_local(9)min_chan(9)balance_ref_count(9)dma_chan_get(9)dma_chan_put(9)dma_find_channel(9)dma_issue_pending_all(9)dma_get_slave_channel(9)__dma_request_channel(9)dma_request_chan(9)dma_request_chan_by_mask(9)devm_dma_request_chan(9)dmaengine_get(9)dmaengine_put(9)dma_async_device_register(9)dma_async_device_unregister(9)dmaenginem_async_device_register(9)dma_wait_for_async_tx(9)dma_run_dependencies(9)
and that's the whole page, bestie πβ¨ this cutie lives over in ./drivers/dma, she's dated October 2026, and she answers to the name dma_channel_rebalance(9). go forth and rebalance your channels 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