fsl_dma_hw_params(9)
π fsl_dma_hw_params β Kernel API Manual β¨
okay bestie, so this page is all about fsl_dma_hw_params(9) β that's the kernel API manual entry, the whole doc lives in the kernel API manual set, and we're about to get into it π
πΈ NAME πΈ
fsl_dma_hw_params β continue initializing the DMA links β¨
π¦ SYNOPSIS π¦
int fsl_dma_hw_params (struct snd_soc_component *component , struct
snd_pcm_substream *substream , struct snd_pcm_hw_params *hw_params );
literally the whole signature up there, no notes π
π ARGUMENTS π
so the original is kinda shy about these, ngl. it says:
componentβ -- undescribed --substreamβ -- undescribed --hw_paramsβ -- undescribed --
and that's it, that's the tea π΅ like the manpage genuinely just leaves all three as "undescribed" so i'm not gonna sit here and make stuff up about them, iykyk π
π₯ DESCRIPTION π₯
okay so here's what it actually does: this function obtains hardware parameters about the opened stream and programs the DMA controller accordingly. icon behaviour honestly π
now, the main character energy of this whole page is the big-endian situation, so let's talk about it. one drawback of big-endian is that when you're copying integers of different sizes into a fixed-sized register, the address you have to copy the integer to depends on the size of the integer. the way that's kind of a whole thing π
for example β and this is the example straight from the page, keep up bestie:
- if
Pis the address of a 32-bit register, andXis a 32-bit integer, thenXshould be copied to addressP. - however, if
Xis a 16-bit integer, then it should be copied toP+2. - if
Xis an 8-bit register, then it should be copied toP+3.
so for playback of 8-bit samples, the DMA controller must transfer single bytes from the DMA buffer to the last byte of the STX0 register β i.e. offset by 3 bytes. for 16-bit samples, the offset is two bytes. π«Ά
and for 24-bit samples, the offset is 1 byte. BUT β and this is the part where you gotta pay attention π¨ β the DMA controller does not support 3-byte copies (the DAHTS register supports only 1, 2, 4, and 8 bytes at a time). so we do not support packed 24-bit samples. 24-bit data must be padded to 32 bits. periodt. no packed 24-bit for you, that's the rule π
fr fr do not try to sneak packed 24-bit samples past this thing β it's not a vibe, it's just not supported, the hardware genuinely can't do the 3-byte copy πΈ
π SEE ALSO π
- Kernel file
./sound/soc/fsl/fsl_dma.c fsl_dma_abort_stream(9)fsl_dma_update_pointers(9)fsl_dma_isr(9)fsl_dma_new(9)fsl_dma_open(9)fsl_dma_pointer(9)fsl_dma_hw_free(9)fsl_dma_close(9)find_ssi_node(9)
go read the whole squad, they're all iconic in their own way π
and that's the page!! π this one lives under ./sound/soc/fsl in the kernel API manual, dated October 2026 β so yeah, future vibes, slay β bye bestie, go program that DMA controller 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