of_dma_configure_id(9)
π« of_dma_configure_id π«
okay so this is a page straight out of the Kernel API Manual, and honestly? it's a little baddie. bestie, we're about to set up DMA configuration and it's gonna slay.
β¨ NAME β¨
of_dma_configure_id β Setup DMA configuration π
like, it configures DMA. that's the whole vibe. no cap.
πΈ SYNOPSIS πΈ
int of_dma_configure_id (struct device *dev , struct device_node *np ,
bool force_dma , const u32 *id );
look at her. four args, one int return, main character energy fr fr π
π¦ ARGUMENTS π¦
devβ the device we're applying DMA configuration to π«Ά she's the one getting glowed up.npβ pointer to the OF node that's holding the DMA configuration. like, this is where the info lives, iykyk.force_dmaβ aboolthat decides whether the device is to be set up byof_dma_configureeven if DMA capability is not explicitly described by firmware. so yeah, it's the "do it anyway" switch π iconic.idβ optional const pointer value input id. yes bestie, optional, and yes it's aconst u32 *, we love a little pointer β¨
π DESCRIPTION π
so what does she actually do? she tries to get the device's DMA configuration from DT and update it accordingly. that's it. that's the plot π¬
and if platform code needs to use its own special DMA configuration (not me being extra π), it can use a platform bus notifier and handle BUS_NOTIFY_ADD_DEVICE events to fix up DMA configuration. like, that's the escape hatch, go off king π
π SEE ALSO π
- Kernel file
./drivers/of/device.c of_match_device(9)of_device_modalias(9)of_device_uevent(9)of_device_make_bus_id(9)
the whole friend group honestly, they all ate π₯
okay tiny reminder bestie: force_dma really does bypass the "firmware didn't describe DMA" situation, so don't be shocked when a device gets configured that you didn't think had DMA. that's the whole point of the flag π
mmm bye bestie!! this page lives in ./drivers/of, dated October 2026, and if you need to find her again just look for of_dma_configure_id(9) in the Kernel API Manual πβ¨ππ¦π
π¦ 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