ce62432c | 22-Mar-2023 |
Walker Chen <walker.chen@starfivetech.com> |
dmaengine: dw-axi-dmac: Increase polling time to DMA transmission completion status
The bit DMAC_CHEN[0] is automatically cleared by hardware to disable the channel after the last AMBA transfer of t
dmaengine: dw-axi-dmac: Increase polling time to DMA transmission completion status
The bit DMAC_CHEN[0] is automatically cleared by hardware to disable the channel after the last AMBA transfer of the DMA transfer to the destination has completed. Software can therefore poll this bit to determine when this channel is free for a new DMA transfer. This time requires at least 40 milliseconds on JH7110 SoC, otherwise an error message 'failed to stop' will be reported.
Signed-off-by: Walker Chen <walker.chen@starfivetech.com> Link: https://lore.kernel.org/r/20230322094820.24738-4-walker.chen@starfivetech.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|
be4d46ed | 27-Jan-2023 |
Kees Cook <keescook@chromium.org> |
dmaengine: dw-axi-dmac: Do not dereference NULL structure
If "vdesc" is NULL, it cannot be used with vd_to_axi_desc(). Leave "bytes" unchanged at 0. Seen under GCC 13 with -Warray-bounds:
../driver
dmaengine: dw-axi-dmac: Do not dereference NULL structure
If "vdesc" is NULL, it cannot be used with vd_to_axi_desc(). Leave "bytes" unchanged at 0. Seen under GCC 13 with -Warray-bounds:
../drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c: In function 'dma_chan_tx_status': ../drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c:329:46: warning: array subscript 0 is outside array bounds of 'struct virt_dma_desc[46116860184273879]' [-Warray-bounds=] 329 | bytes = vd_to_axi_desc(vdesc)->length; | ^~
Fixes: 8e55444da65c ("dmaengine: dw-axi-dmac: Support burst residue granularity") Cc: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Cc: Vinod Koul <vkoul@kernel.org> Cc: dmaengine@vger.kernel.org Signed-off-by: Kees Cook <keescook@chromium.org> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20230127223623.never.507-kees@kernel.org Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
/openbmc/linux/Documentation/devicetree/bindings/dma/allwinner,sun4i-a10-dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/allwinner,sun6i-a31-dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/altr,msgdma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/apple,admac.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/arm-pl08x.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/dma-controller.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/dma-router.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/fsl,edma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/ingenic,dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/intel,ldma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/mediatek,uart-dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/nvidia,tegra186-gpc-dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/nvidia,tegra210-adma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/owl-dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/qcom,gpi.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/renesas,rcar-dmac.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/renesas,rz-dmac.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/renesas,rzn1-dmamux.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/renesas,usb-dmac.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/sifive,fu540-c000-pdma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/snps,dma-spear1340.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/snps,dw-axi-dmac.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/socionext,uniphier-mio-dmac.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/socionext,uniphier-xdmac.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/st,stm32-dma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/st,stm32-dmamux.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/st,stm32-mdma.yaml/openbmc/linux/Documentation/devicetree/bindings/dma/stericsson,dma40.yaml/openbmc/linux/MAINTAINERS/openbmc/linux/drivers/dma/Kconfig/openbmc/linux/drivers/dma/dmaengine.cdw-axi-dmac-platform.c/openbmc/linux/drivers/dma/idxd/device.c/openbmc/linux/drivers/dma/idxd/init.c/openbmc/linux/drivers/dma/sf-pdma/sf-pdma.c/openbmc/linux/drivers/dma/sf-pdma/sf-pdma.h/openbmc/linux/drivers/dma/xilinx/Makefile/openbmc/linux/drivers/dma/xilinx/xdma-regs.h/openbmc/linux/drivers/dma/xilinx/xdma.c/openbmc/linux/include/linux/dma/amd_xdma.h/openbmc/linux/include/linux/dmaengine.h/openbmc/linux/include/linux/platform_data/amd_xdma.h |
820f5ce9 | 08-Jul-2022 |
Ben Dooks <ben.dooks@sifive.com> |
dmaengine: dw-axi-dmac: ignore interrupt if no descriptor
If the channel has no descriptor and the interrupt is raised then the kernel will OOPS. Check the result of vchan_next_desc() in the handler
dmaengine: dw-axi-dmac: ignore interrupt if no descriptor
If the channel has no descriptor and the interrupt is raised then the kernel will OOPS. Check the result of vchan_next_desc() in the handler axi_chan_block_xfer_complete() to avoid the error happening.
Signed-off-by: Ben Dooks <ben.dooks@sifive.com> Link: https://lore.kernel.org/r/20220708170153.269991-4-ben.dooks@sifive.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|
2d0f07f8 | 01-Oct-2021 |
Pandith N <pandith.n@intel.com> |
dmaengine: dw-axi-dmac: set coherent mask
Add support for setting dma coherent mask, dma mask is set to 64 bit
Signed-off-by: Pandith N <pandith.n@intel.com> Reviewed-by: Andy Shevchenko <andriy.sh
dmaengine: dw-axi-dmac: set coherent mask
Add support for setting dma coherent mask, dma mask is set to 64 bit
Signed-off-by: Pandith N <pandith.n@intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20211001140812.24977-4-pandith.n@intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|
93a7d32e | 01-Oct-2021 |
Pandith N <pandith.n@intel.com> |
dmaengine: dw-axi-dmac: Hardware handshake configuration
Added hardware handshake selection in channel config, for mem2per and per2mem case. The peripheral specific handshake interface needs to be p
dmaengine: dw-axi-dmac: Hardware handshake configuration
Added hardware handshake selection in channel config, for mem2per and per2mem case. The peripheral specific handshake interface needs to be programmed in src_per, dst_per bits of CHx_CFG register.
Signed-off-by: Pandith N <pandith.n@intel.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20211001140812.24977-3-pandith.n@intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|
c454d16a | 02-Aug-2021 |
Pandith N <pandith.n@intel.com> |
dmaengine: dw-axi-dmac: Burst length settings
Burst length, DMA HW capability set in dt-binding is now used in driver.
Signed-off-by: Pandith N <pandith.n@intel.com> Tested-by: Pan Kris <kris.pan@i
dmaengine: dw-axi-dmac: Burst length settings
Burst length, DMA HW capability set in dt-binding is now used in driver.
Signed-off-by: Pandith N <pandith.n@intel.com> Tested-by: Pan Kris <kris.pan@intel.com> Link: https://lore.kernel.org/r/20210802055454.15192-4-pandith.n@intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|
f95f3b53 | 02-Aug-2021 |
Pandith N <pandith.n@intel.com> |
dmaengine: dw-axi-dmac: support parallel memory <--> peripheral transfers
Added support for multiple DMA_MEM_TO_DEV, DMA_DEV_TO_MEM transfers in parallel. This is required for peripherals using DMA
dmaengine: dw-axi-dmac: support parallel memory <--> peripheral transfers
Added support for multiple DMA_MEM_TO_DEV, DMA_DEV_TO_MEM transfers in parallel. This is required for peripherals using DMA for transmit and receive operations at the same time. APB slot number needs to be programmed in channel hardware handshaking interface
Signed-off-by: Pandith N <pandith.n@intel.com> Tested-by: Pan Kris <kris.pan@intel.com> Link: https://lore.kernel.org/r/20210802055454.15192-3-pandith.n@intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|
eda38ce4 | 03-Feb-2021 |
Colin Ian King <colin.king@canonical.com> |
dmaengine: dw-axi-dmac: remove redundant null check on desc
The pointer desc is being null checked twice, the second null check is redundant because desc has not been re-assigned between the checks.
dmaengine: dw-axi-dmac: remove redundant null check on desc
The pointer desc is being null checked twice, the second null check is redundant because desc has not been re-assigned between the checks. Remove the redundant second null check on desc.
Fixes: ef6fb2d6f1ab ("dmaengine: dw-axi-dmac: simplify descriptor management") Signed-off-by: Colin Ian King <colin.king@canonical.com> Tested-by: Sia Jee Heng <jee.heng.sia@intel.com> Reviewed-by: Sia Jee Heng <jee.heng.sia@intel.com> Addresses-Coverity: ("Logically dead code") Link: https://lore.kernel.org/r/20210203134652.22618-1-colin.king@canonical.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|
f80f7c96 | 24-Jan-2021 |
Sia Jee Heng <jee.heng.sia@intel.com> |
dmaengine: dw-axi-dmac: Virtually split the linked-list
AxiDMA driver exposed the dma_set_max_seg_size() to the DMAENGINE. It shall helps the DMA clients to create size-optimized linked-list for the
dmaengine: dw-axi-dmac: Virtually split the linked-list
AxiDMA driver exposed the dma_set_max_seg_size() to the DMAENGINE. It shall helps the DMA clients to create size-optimized linked-list for the controller.
However, there are certain situations where DMA client might not be abled to benefit from the dma_get_max_seg_size() if the segment size can't meet the nature of the DMA client's operation.
In the case of ALSA operation, ALSA application and driver expecting to run in a period of larger than 10ms regardless of the bit depth. With this large period, there is a strong request to split the linked-list in the AxiDMA driver.
Signed-off-by: Sia Jee Heng <jee.heng.sia@intel.com> Tested-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Reviewed-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Link: https://lore.kernel.org/r/20210125013255.25799-18-jee.heng.sia@intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|
78a90a1e | 24-Jan-2021 |
Sia Jee Heng <jee.heng.sia@intel.com> |
dmaengine: dw-axi-dmac: Set constraint to the Max segment size
Add support for DMA Scatter-Gather (SG) constraint so that DMA clients can handle the AxiDMA limitation.
Without supporting DMA constr
dmaengine: dw-axi-dmac: Set constraint to the Max segment size
Add support for DMA Scatter-Gather (SG) constraint so that DMA clients can handle the AxiDMA limitation.
Without supporting DMA constraint the default Max segment size reported by dmaengine is 64KB, which is not supported by Intel KeemBay AxiDMA.
Signed-off-by: Sia Jee Heng <jee.heng.sia@intel.com> Tested-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Link: https://lore.kernel.org/r/20210125013255.25799-17-jee.heng.sia@intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
show more ...
|