History

dmaengine: Document dmaengine_prep_dma_memset

Document this function to make clear the expected behavior of the 'value' parameter. It was intended to match the behavior of POSIX memset as laid out here: https://lore.kernel.org/dmaengine/YejrA5ZWZ3lTRO%2F1@matsya/

Ben Walker committed 4 years ago

Commit fc44ff01 parent 439b5e72 files · +14 −0Browse files

Showing the changes to include (1 of 2 files). Show all

Unified · Split

include/linux/dmaengine.h+8−0
@@ -1030,6 +1030,14 @@ static inline struct dma_async_tx_descriptor *dmaengine_prep_interleaved_dma( · 1029 unmodified lines
10301030 return chan->device->device_prep_interleaved_dma(chan, xt, flags);
10311031 }
10321032
1033+/**
1034+ * dmaengine_prep_dma_memset() - Prepare a DMA memset descriptor.
1035+ * @chan: The channel to be used for this descriptor
1036+ * @dest: Address of buffer to be set
1037+ * @value: Treated as a single byte value that fills the destination buffer
1038+ * @len: The total size of dest
1039+ * @flags: DMA engine flags
1040+ */
10331041 static inline struct dma_async_tx_descriptor *dmaengine_prep_dma_memset(
10341042 struct dma_chan *chan, dma_addr_t dest, int value, size_t len,
10351043 unsigned long flags)