mraid_mm_attach_buf(9)
π mraid_mm_attach_buf(9) β like, the kernel API manual bestie β¨
okay so we're diving into mraid_mm_attach_buf from the Kernel API Manual today and honestly? it's giving "small function, big responsibility" π
πΈ NAME πΈ
mraid_mm_attach_buf β attach a free dma buffer for required size π lowkey exactly what it says on the tin, no cap
β¨ SYNOPSIS β¨
int mraid_mm_attach_buf (mraid_mmadp_t *adp , uioc_t *kioc , int xferlen
);
like yes she returns an int, and yes she takes three things π«Ά
π¦ ARGUMENTS π¦
adpβ the adapter softstate, aka the whole vibe of the adapter itself π«kiocβ thekiocthat the buffer needs to be attached to, she's the main character here frxferlenβ required length for buffer, aka how much room we're asking for π
π DESCRIPTION π
so here's the tea β first we search for a pool with the smallest buffer that is >= xferlen. iconic, efficient, we love her π
but wait β if that pool has no free buffer, we don't panic, we just try for the next bigger size πβ¨
and if none is available? bestie we improvise: we will try to allocate the smallest buffer that is >= xferlen and attach it the pool. periodt π no buffer left behind, that's the energy π
π₯ SEE ALSO π₯
kernel file ./drivers/scsi/megaraid/megaraid_mm.c and honestly the whole megaraid family reunion π:
mraid_mm_open(9)mraid_mm_ioctl(9)mraid_mm_get_adapter(9)handle_drvrcmd(9)mimd_to_kioc(9)mraid_mm_alloc_kioc(9)mraid_mm_dealloc_kioc(9)lld_ioctl(9)ioctl_done(9)lld_timedout(9)kioc_to_mimd(9)hinfo_to_cinfo(9)mraid_mm_register_adp(9)mraid_mm_adapter_app_handle(9)mraid_mm_setup_dma_pools(9)mraid_mm_unregister_adp(9)mraid_mm_free_adp_resources(9)mraid_mm_teardown_dma_pools(9)mraid_mm_init(9)mraid_mm_exit(9)
aaaaand that's the whole page bestie!! π§ source is ./drivers/scsi/megaraid, dated October 2026 β go forth and attach those buffers, ily, bye ππ¦π
π¦ 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