]> www.infradead.org Git - nvme.git/commitdiff
dmaengine: stm32: New directory for STM32 DMA controllers drivers
authorAmelie Delaunay <amelie.delaunay@foss.st.com>
Fri, 31 May 2024 15:07:02 +0000 (17:07 +0200)
committerVinod Koul <vkoul@kernel.org>
Tue, 11 Jun 2024 18:25:33 +0000 (23:55 +0530)
Gather the STM32 DMA controllers under drivers/dma/stm32/

Signed-off-by: Amelie Delaunay <amelie.delaunay@foss.st.com>
Link: https://lore.kernel.org/r/20240531150712.2503554-3-amelie.delaunay@foss.st.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/dma/Kconfig
drivers/dma/Makefile
drivers/dma/stm32/Kconfig [new file with mode: 0644]
drivers/dma/stm32/Makefile [new file with mode: 0644]
drivers/dma/stm32/stm32-dma.c [moved from drivers/dma/stm32-dma.c with 99% similarity]
drivers/dma/stm32/stm32-dmamux.c [moved from drivers/dma/stm32-dmamux.c with 100% similarity]
drivers/dma/stm32/stm32-mdma.c [moved from drivers/dma/stm32-mdma.c with 99% similarity]

index 002a5ec806207ca2614615b37eb1e38303292728..32b4256ef87400c0b91bf23bd7769c110b70b374 100644 (file)
@@ -568,38 +568,6 @@ config ST_FDMA
          Say Y here if you have such a chipset.
          If unsure, say N.
 
-config STM32_DMA
-       bool "STMicroelectronics STM32 DMA support"
-       depends on ARCH_STM32 || COMPILE_TEST
-       select DMA_ENGINE
-       select DMA_VIRTUAL_CHANNELS
-       help
-         Enable support for the on-chip DMA controller on STMicroelectronics
-         STM32 MCUs.
-         If you have a board based on such a MCU and wish to use DMA say Y
-         here.
-
-config STM32_DMAMUX
-       bool "STMicroelectronics STM32 dma multiplexer support"
-       depends on STM32_DMA || COMPILE_TEST
-       help
-         Enable support for the on-chip DMA multiplexer on STMicroelectronics
-         STM32 MCUs.
-         If you have a board based on such a MCU and wish to use DMAMUX say Y
-         here.
-
-config STM32_MDMA
-       bool "STMicroelectronics STM32 master dma support"
-       depends on ARCH_STM32 || COMPILE_TEST
-       depends on OF
-       select DMA_ENGINE
-       select DMA_VIRTUAL_CHANNELS
-       help
-         Enable support for the on-chip MDMA controller on STMicroelectronics
-         STM32 platforms.
-         If you have a board based on STM32 SoC and wish to use the master DMA
-         say Y here.
-
 config SPRD_DMA
        tristate "Spreadtrum DMA support"
        depends on ARCH_SPRD || COMPILE_TEST
@@ -772,6 +740,8 @@ source "drivers/dma/fsl-dpaa2-qdma/Kconfig"
 
 source "drivers/dma/lgm/Kconfig"
 
+source "drivers/dma/stm32/Kconfig"
+
 # clients
 comment "DMA Clients"
        depends on DMA_ENGINE
index 802ca916f05f509f9e7645a8c6c8b5f43ae80325..374ea98faf43e259d23af5e5aaae7f16ecb61243 100644 (file)
@@ -70,9 +70,6 @@ obj-$(CONFIG_PXA_DMA) += pxa_dma.o
 obj-$(CONFIG_RENESAS_DMA) += sh/
 obj-$(CONFIG_SF_PDMA) += sf-pdma/
 obj-$(CONFIG_STE_DMA40) += ste_dma40.o ste_dma40_ll.o
-obj-$(CONFIG_STM32_DMA) += stm32-dma.o
-obj-$(CONFIG_STM32_DMAMUX) += stm32-dmamux.o
-obj-$(CONFIG_STM32_MDMA) += stm32-mdma.o
 obj-$(CONFIG_SPRD_DMA) += sprd-dma.o
 obj-$(CONFIG_TXX9_DMAC) += txx9dmac.o
 obj-$(CONFIG_TEGRA186_GPC_DMA) += tegra186-gpc-dma.o
@@ -88,5 +85,6 @@ obj-$(CONFIG_INTEL_LDMA) += lgm/
 
 obj-y += mediatek/
 obj-y += qcom/
+obj-y += stm32/
 obj-y += ti/
 obj-y += xilinx/
diff --git a/drivers/dma/stm32/Kconfig b/drivers/dma/stm32/Kconfig
new file mode 100644 (file)
index 0000000..b72ae1a
--- /dev/null
@@ -0,0 +1,37 @@
+# SPDX-License-Identifier: GPL-2.0-only
+#
+# STM32 DMA controllers drivers
+#
+if ARCH_STM32 || COMPILE_TEST
+
+config STM32_DMA
+       bool "STMicroelectronics STM32 DMA support"
+       select DMA_ENGINE
+       select DMA_VIRTUAL_CHANNELS
+       help
+         Enable support for the on-chip DMA controller on STMicroelectronics
+         STM32 platforms.
+         If you have a board based on STM32 SoC with such DMA controller
+         and want to use DMA say Y here.
+
+config STM32_DMAMUX
+       bool "STMicroelectronics STM32 DMA multiplexer support"
+       depends on STM32_DMA
+       help
+         Enable support for the on-chip DMA multiplexer on STMicroelectronics
+         STM32 platforms.
+         If you have a board based on STM32 SoC with such DMA multiplexer
+         and want to use DMAMUX say Y here.
+
+config STM32_MDMA
+       bool "STMicroelectronics STM32 master DMA support"
+       depends on OF
+       select DMA_ENGINE
+       select DMA_VIRTUAL_CHANNELS
+       help
+         Enable support for the on-chip MDMA controller on STMicroelectronics
+         STM32 platforms.
+         If you have a board based on STM32 SoC with such DMA controller
+         and want to use MDMA say Y here.
+
+endif
diff --git a/drivers/dma/stm32/Makefile b/drivers/dma/stm32/Makefile
new file mode 100644 (file)
index 0000000..663a389
--- /dev/null
@@ -0,0 +1,4 @@
+# SPDX-License-Identifier: GPL-2.0-only
+obj-$(CONFIG_STM32_DMA) += stm32-dma.o
+obj-$(CONFIG_STM32_DMAMUX) += stm32-dmamux.o
+obj-$(CONFIG_STM32_MDMA) += stm32-mdma.o
similarity index 99%
rename from drivers/dma/stm32-dma.c
rename to drivers/dma/stm32/stm32-dma.c
index 90857d08a1a7435fc130b168eb155cd2f6e94242..917f8e9223739af853e492d97cecac0e95e0aea3 100644 (file)
@@ -28,7 +28,7 @@
 #include <linux/sched.h>
 #include <linux/slab.h>
 
-#include "virt-dma.h"
+#include "../virt-dma.h"
 
 #define STM32_DMA_LISR                 0x0000 /* DMA Low Int Status Reg */
 #define STM32_DMA_HISR                 0x0004 /* DMA High Int Status Reg */
similarity index 99%
rename from drivers/dma/stm32-mdma.c
rename to drivers/dma/stm32/stm32-mdma.c
index 6505081ced441cff5dc7fd34ee2bd0fdad0dd7db..e6d525901de7ecf822d218b87b95aba6bbf0a3ef 100644 (file)
@@ -30,7 +30,7 @@
 #include <linux/reset.h>
 #include <linux/slab.h>
 
-#include "virt-dma.h"
+#include "../virt-dma.h"
 
 #define STM32_MDMA_GISR0               0x0000 /* MDMA Int Status Reg 1 */