projects/linux·commit 6daa9043

Merge tag 'dmaengine-5.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/dmaengine

6daa9043 · Linus Torvalds <[email protected]> · 2020-12-17 12:52:23 -08:00

Pull dmaengine updates from Vinod Koul:
 "The last dmaengine updates for this year :)

  This contains couple of new drivers, new device support and updates to
  bunch of drivers.

  New drivers/devices:
   - Qualcomm ADM driver
   - Qualcomm GPI driver
   - Allwinner A100 DMA support
   - Microchip Sama7g5 support
   - Mediatek MT8516 apdma

  Updates:
   - more updates to idxd driver and support for IAX config
   - runtime PM support for dw driver
   - TI drivers"

* tag 'dmaengine-5.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vkoul/dmaengine: (75 commits)
  soc: ti: k3-ringacc: Use correct error casting in k3_ringacc_dmarings_init
  dmaengine: ti: k3-udma-glue: Add support for K3 PKTDMA
  dmaengine: ti: k3-udma: Initial support for K3 PKTDMA
  dmaengine: ti: k3-udma: Add support for BCDMA channel TPL handling
  dmaengine: ti: k3-udma: Initial support for K3 BCDMA
  soc: ti: k3-ringacc: add AM64 DMA rings support.
  dmaengine: ti: Add support for k3 event routers
  dmaengine: ti: k3-psil: Add initial map for AM64
  dmaengine: ti: k3-psil: Extend psil_endpoint_config for K3 PKTDMA
  dt-bindings: dma: ti: Add document for K3 PKTDMA
  dt-bindings: dma: ti: Add document for K3 BCDMA
  dmaengine: dmatest: Use dmaengine_get_dma_device
  dmaengine: doc: client: Update for dmaengine_get_dma_device() usage
  dmaengine: Add support for per channel coherency handling
  dmaengine: of-dma: Add support for optional router configuration callback
  dmaengine: ti: k3-udma-glue: Configure the dma_dev for rings
  dmaengine: ti: k3-udma-glue: Get the ringacc from udma_dev
  dmaengine: ti: k3-udma-glue: Add function to get device pointer for DMA API
  dmaengine: ti: k3-udma: Add support for second resource range from sysfw
  dmaengine: ti: k3-udma: Wait for peer teardown completion if supported
  ...
Commit
6daa90439e91bb9a71864b02f7d0af8587ea889a
Parents
83005cd6 · 115ff12a

Merge commit. Changes below are compared with the first parent: 83005cd6.

Changes

70 files changed · +7724 −575

FileStatusAddDelContent
Documentation/ABI/stable/sysfs-driver-dma-idxdmodified+21−0View file
Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yamlmodified+4−1View file
Documentation/devicetree/bindings/dma/atmel-xdma.txtmodified+2−1View file
Documentation/devicetree/bindings/dma/mtk-uart-apdma.txtmodified+1−0View file
Documentation/devicetree/bindings/dma/qcom,gpi.yamladded+88−0View file
Documentation/devicetree/bindings/dma/ti/k3-bcdma.yamladded+164−0View file
Documentation/devicetree/bindings/dma/ti/k3-pktdma.yamladded+172−0View file
Documentation/driver-api/dmaengine/client.rstmodified+3−1View file
drivers/dma/Kconfigmodified+10−0View file
drivers/dma/at_xdmac.cmodified+134−29View file
drivers/dma/dma-jz4780.cmodified+1−1View file
drivers/dma/dmatest.cmodified+8−5View file
drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.cmodified+1−1View file
drivers/dma/dw/core.cmodified+6−0View file
drivers/dma/hisi_dma.cmodified+2−3View file
drivers/dma/idma64.cmodified+2−6View file
drivers/dma/idxd/cdev.cmodified+49−1View file
drivers/dma/idxd/device.cmodified+120−23View file
drivers/dma/idxd/dma.cmodified+0−9View file
drivers/dma/idxd/idxd.hmodified+53−5View file
drivers/dma/idxd/init.cmodified+93−30View file
drivers/dma/idxd/irq.cmodified+134−12View file
drivers/dma/idxd/registers.hmodified+26−2View file
drivers/dma/idxd/submit.cmodified+31−6View file
drivers/dma/idxd/sysfs.cmodified+204−3View file
drivers/dma/imx-dma.cmodified+4−29View file
drivers/dma/imx-sdma.cmodified+1−37View file
drivers/dma/ipu/ipu_idmac.cmodified+5−6View file
drivers/dma/k3dma.cmodified+4−5View file
drivers/dma/milbeaut-xdmac.cmodified+2−3View file
drivers/dma/moxart-dma.cmodified+2−3View file
drivers/dma/mv_xor.cmodified+1−1View file
drivers/dma/mv_xor_v2.cmodified+3−1View file
drivers/dma/mxs-dma.cmodified+5−32View file
drivers/dma/of-dma.cmodified+10−0View file
drivers/dma/pl330.cmodified+0−2View file
drivers/dma/ppc4xx/adma.cmodified+1−3View file
drivers/dma/pxa_dma.cmodified+2−3View file
drivers/dma/qcom/Kconfigmodified+23−0View file
drivers/dma/qcom/Makefilemodified+2−0View file
drivers/dma/qcom/bam_dma.cmodified+1−1View file
drivers/dma/qcom/gpi.cadded+2303−0View file
drivers/dma/qcom/qcom_adm.cadded+905−0View file
drivers/dma/sf-pdma/sf-pdma.cmodified+5−7View file
drivers/dma/ste_dma40.cmodified+2−3View file
drivers/dma/stm32-dma.cmodified+31−16View file
drivers/dma/stm32-dmamux.cmodified+1−1View file
drivers/dma/stm32-mdma.cmodified+35−31View file
drivers/dma/sun6i-dma.cmodified+25−0View file
drivers/dma/tegra210-adma.cmodified+3−4View file
drivers/dma/ti/Makefilemodified+2−1View file
drivers/dma/ti/dma-crossbar.cmodified+3−3View file
drivers/dma/ti/k3-psil-am64.cadded+158−0View file
drivers/dma/ti/k3-psil-priv.hmodified+1−0View file
drivers/dma/ti/k3-psil.cmodified+1−0View file
drivers/dma/ti/k3-udma-glue.cmodified+314−69View file
drivers/dma/ti/k3-udma-private.cmodified+45−0View file
drivers/dma/ti/k3-udma.cmodified+1800−166View file
drivers/dma/ti/k3-udma.hmodified+26−2View file
drivers/soc/ti/k3-ringacc.cmodified+318−7View file
include/dt-bindings/dma/jz4775-dma.hadded+44−0View file
include/dt-bindings/dma/qcom-gpi.hadded+11−0View file
include/dt-bindings/dma/x2000-dma.hadded+54−0View file
include/linux/dma/k3-event-router.hadded+16−0View file
include/linux/dma/k3-psil.hmodified+16−0View file
include/linux/dma/k3-udma-glue.hmodified+12−0View file
include/linux/dma/qcom-gpi-dma.hadded+83−0View file
include/linux/dmaengine.hmodified+19−0View file
include/linux/soc/ti/k3-ringacc.hmodified+17−0View file
include/uapi/linux/idxd.hmodified+79−0View file

Only the first 600 diff lines are shown. Download the complete patch.

Documentation/ABI/stable/sysfs-driver-dma-idxd

View file
diff --git a/Documentation/ABI/stable/sysfs-driver-dma-idxd b/Documentation/ABI/stable/sysfs-driver-dma-idxd
index b441838..55285c1 100644
--- a/Documentation/ABI/stable/sysfs-driver-dma-idxd
+++ b/Documentation/ABI/stable/sysfs-driver-dma-idxd
@@ -77,6 +77,13 @@ Contact: [email protected]
Description: The operation capability bit mask specify the operation types
supported by the this device.
+What: /sys/bus/dsa/devices/dsa<m>/pasid_enabled
+Date: Oct 27, 2020
+KernelVersion: 5.11.0
+Description: To indicate if PASID (process address space identifier) is
+ enabled or not for this device.
+
What: /sys/bus/dsa/devices/dsa<m>/state
Date: Oct 25, 2019
KernelVersion: 5.6.0
@@ -122,6 +129,13 @@ KernelVersion: 5.10.0
Description: The last executed device administrative command's status/error.
+What: /sys/bus/dsa/devices/wq<m>.<n>/block_on_fault
+Date: Oct 27, 2020
+KernelVersion: 5.11.0
+Description: To indicate block on fault is allowed or not for the work queue
+ to support on demand paging.
+
What: /sys/bus/dsa/devices/wq<m>.<n>/group_id
Date: Oct 25, 2019
KernelVersion: 5.6.0
@@ -190,6 +204,13 @@ Contact: [email protected]
Description: The max batch size for this workqueue. Cannot exceed device
max batch size. Configurable parameter.
+What: /sys/bus/dsa/devices/wq<m>.<n>/ats_disable
+Date: Nov 13, 2020
+KernelVersion: 5.11.0
+Description: Indicate whether ATS disable is turned on for the workqueue.
+ 0 indicates ATS is on, and 1 indicates ATS is off for the workqueue.
+
What: /sys/bus/dsa/devices/engine<m>.<n>/group_id
Date: Oct 25, 2019
KernelVersion: 5.6.0

Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml

View file
diff --git a/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml b/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml
index 372679d..b6e1ebf 100644
--- a/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml
+++ b/Documentation/devicetree/bindings/dma/allwinner,sun50i-a64-dma.yaml
@@ -21,6 +21,7 @@ properties:
compatible:
oneOf:
- const: allwinner,sun50i-a64-dma
+ - const: allwinner,sun50i-a100-dma
- const: allwinner,sun50i-h6-dma
- items:
- const: allwinner,sun8i-r40-dma
@@ -56,7 +57,9 @@ required:
if:
properties:
compatible:
- const: allwinner,sun50i-h6-dma
+ enum:
+ - allwinner,sun50i-a100-dma
+ - allwinner,sun50i-h6-dma
then:
properties:

Documentation/devicetree/bindings/dma/atmel-xdma.txt

View file
diff --git a/Documentation/devicetree/bindings/dma/atmel-xdma.txt b/Documentation/devicetree/bindings/dma/atmel-xdma.txt
index 4dc398e..510b7f2 100644
--- a/Documentation/devicetree/bindings/dma/atmel-xdma.txt
+++ b/Documentation/devicetree/bindings/dma/atmel-xdma.txt
@@ -2,7 +2,8 @@
* XDMA Controller
Required properties:
-- compatible: Should be "atmel,sama5d4-dma" or "microchip,sam9x60-dma".
+- compatible: Should be "atmel,sama5d4-dma", "microchip,sam9x60-dma" or
+ "microchip,sama7g5-dma".
- reg: Should contain DMA registers location and length.
- interrupts: Should contain DMA interrupt.
- #dma-cells: Must be <1>, used to represent the number of integer cells in

Documentation/devicetree/bindings/dma/mtk-uart-apdma.txt

View file
diff --git a/Documentation/devicetree/bindings/dma/mtk-uart-apdma.txt b/Documentation/devicetree/bindings/dma/mtk-uart-apdma.txt
index 2117db0..fef9c1e 100644
--- a/Documentation/devicetree/bindings/dma/mtk-uart-apdma.txt
+++ b/Documentation/devicetree/bindings/dma/mtk-uart-apdma.txt
@@ -4,6 +4,7 @@ Required properties:
- compatible should contain:
* "mediatek,mt2712-uart-dma" for MT2712 compatible APDMA
* "mediatek,mt6577-uart-dma" for MT6577 and all of the above
+ * "mediatek,mt8516-uart-dma", "mediatek,mt6577" for MT8516 SoC
- reg: The base address of the APDMA register bank.

Documentation/devicetree/bindings/dma/qcom,gpi.yaml

View file
diff --git a/Documentation/devicetree/bindings/dma/qcom,gpi.yaml b/Documentation/devicetree/bindings/dma/qcom,gpi.yaml
new file mode 100644
index 0000000..f8142ad
--- /dev/null
+++ b/Documentation/devicetree/bindings/dma/qcom,gpi.yaml
@@ -0,0 +1,88 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/dma/qcom,gpi.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm Technologies Inc GPI DMA controller
+
+maintainers:
+ - Vinod Koul <[email protected]>
+
+description: |
+ QCOM GPI DMA controller provides DMA capabilities for
+ peripheral buses such as I2C, UART, and SPI.
+
+allOf:
+ - $ref: "dma-controller.yaml#"
+
+properties:
+ compatible:
+ enum:
+ - qcom,sdm845-gpi-dma
+
+ reg:
+ maxItems: 1
+
+ interrupts:
+ description:
+ Interrupt lines for each GPI instance
+ maxItems: 13
+
+ "#dma-cells":
+ const: 3
+ description: >
+ DMA clients must use the format described in dma.txt, giving a phandle
+ to the DMA controller plus the following 3 integer cells:
+ - channel: if set to 0xffffffff, any available channel will be allocated
+ for the client. Otherwise, the exact channel specified will be used.
+ - seid: serial id of the client as defined in the SoC documentation.
+ - client: type of the client as defined in dt-bindings/dma/qcom-gpi.h
+
+ iommus:
+ maxItems: 1
+
+ dma-channels:
+ maximum: 31
+
+ dma-channel-mask:
+ maxItems: 1
+
+required:
+ - compatible
+ - reg
+ - interrupts
+ - "#dma-cells"
+ - iommus
+ - dma-channels
+ - dma-channel-mask
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/interrupt-controller/arm-gic.h>
+ #include <dt-bindings/dma/qcom-gpi.h>
+ gpi_dma0: dma-controller@800000 {
+ compatible = "qcom,gpi-dma";
+ #dma-cells = <3>;
+ reg = <0x00800000 0x60000>;
+ iommus = <&apps_smmu 0x0016 0x0>;
+ dma-channels = <13>;
+ dma-channel-mask = <0xfa>;
+ interrupts = <GIC_SPI 244 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 245 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 246 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 247 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 248 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 249 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 250 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 251 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 252 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 253 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 254 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 255 IRQ_TYPE_LEVEL_HIGH>,
+ <GIC_SPI 256 IRQ_TYPE_LEVEL_HIGH>;
+ };
+
+...

Documentation/devicetree/bindings/dma/ti/k3-bcdma.yaml

View file
diff --git a/Documentation/devicetree/bindings/dma/ti/k3-bcdma.yaml b/Documentation/devicetree/bindings/dma/ti/k3-bcdma.yaml
new file mode 100644
index 0000000..b15f68c
--- /dev/null
+++ b/Documentation/devicetree/bindings/dma/ti/k3-bcdma.yaml
@@ -0,0 +1,164 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/dma/ti/k3-bcdma.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments K3 DMSS BCDMA Device Tree Bindings
+
+maintainers:
+ - Peter Ujfalusi <[email protected]>
+
+description: |
+ The Block Copy DMA (BCDMA) is intended to perform similar functions as the TR
+ mode channels of K3 UDMA-P.
+ BCDMA includes block copy channels and Split channels.
+
+ Block copy channels mainly used for memory to memory transfers, but with
+ optional triggers a block copy channel can service peripherals by accessing
+ directly to memory mapped registers or area.
+
+ Split channels can be used to service PSI-L based peripherals.
+ The peripherals can be PSI-L native or legacy, non PSI-L native peripherals
+ with PDMAs. PDMA is tasked to act as a bridge between the PSI-L fabric and the
+ legacy peripheral.
+
+ PDMAs can be configured via BCDMA split channel's peer registers to match with
+ the configuration of the legacy peripheral.
+
+allOf:
+ - $ref: /schemas/dma/dma-controller.yaml#
+
+properties:
+ compatible:
+ const: ti,am64-dmss-bcdma
+
+ "#dma-cells":
+ const: 3
+ description: |
+ cell 1: type of the BCDMA channel to be used to service the peripheral:
+ 0 - split channel
+ 1 - block copy channel using global trigger 1
+ 2 - block copy channel using global trigger 2
+ 3 - block copy channel using local trigger
+
+ cell 2: parameter for the channel:
+ if cell 1 is 0 (split channel):
+ PSI-L thread ID of the remote (to BCDMA) end.
+ Valid ranges for thread ID depends on the data movement direction:
+ for source thread IDs (rx): 0 - 0x7fff
+ for destination thread IDs (tx): 0x8000 - 0xffff
+
+ Please refer to the device documentation for the PSI-L thread map and
+ also the PSI-L peripheral chapter for the correct thread ID.
+ if cell 1 is 1 or 2 (block copy channel using global trigger):
+ Unused, ignored
+
+ The trigger must be configured for the channel externally to BCDMA,
+ channels using global triggers should not be requested directly, but
+ via DMA event router.
+ if cell 1 is 3 (block copy channel using local trigger):
+ bchan number of the locally triggered channel
+
+ cell 3: ASEL value for the channel
+
+ reg:
+ maxItems: 5
+
+ reg-names:
+ items:
+ - const: gcfg
+ - const: bchanrt
+ - const: rchanrt
+ - const: tchanrt
+ - const: ringrt
+
+ msi-parent: true
+
+ ti,asel:
+ $ref: /schemas/types.yaml#/definitions/uint32
+ description: ASEL value for non slave channels
+
+ ti,sci-rm-range-bchan:
+ $ref: /schemas/types.yaml#/definitions/uint32-array
+ description: |
+ Array of BCDMA block-copy channel resource subtypes for resource
+ allocation for this host
+ minItems: 1
+ # Should be enough
+ maxItems: 255
+ items:
+ maximum: 0x3f
+
+ ti,sci-rm-range-tchan:
+ $ref: /schemas/types.yaml#/definitions/uint32-array
+ description: |
+ Array of BCDMA split tx channel resource subtypes for resource allocation
+ for this host
+ minItems: 1
+ # Should be enough
+ maxItems: 255
+ items:
+ maximum: 0x3f
+
+ ti,sci-rm-range-rchan:
+ $ref: /schemas/types.yaml#/definitions/uint32-array
+ description: |
+ Array of BCDMA split rx channel resource subtypes for resource allocation
+ for this host
+ minItems: 1
+ # Should be enough
+ maxItems: 255
+ items:
+ maximum: 0x3f
+
+required:
+ - compatible
+ - "#dma-cells"
+ - reg
+ - reg-names
+ - msi-parent
+ - ti,sci
+ - ti,sci-dev-id
+ - ti,sci-rm-range-bchan
+ - ti,sci-rm-range-tchan
+ - ti,sci-rm-range-rchan
+
+unevaluatedProperties: false
+
+examples:
+ - |+
+ cbass_main {
+ #address-cells = <2>;
+ #size-cells = <2>;
+
+ main_dmss {
+ compatible = "simple-mfd";
+ #address-cells = <2>;
+ #size-cells = <2>;
+ dma-ranges;
+ ranges;
+
+ ti,sci-dev-id = <25>;
+
+ main_bcdma: dma-controller@485c0100 {
+ compatible = "ti,am64-dmss-bcdma";
+
+ reg = <0x0 0x485c0100 0x0 0x100>,
+ <0x0 0x4c000000 0x0 0x20000>,
+ <0x0 0x4a820000 0x0 0x20000>,
+ <0x0 0x4aa40000 0x0 0x20000>,
+ <0x0 0x4bc00000 0x0 0x100000>;
+ reg-names = "gcfg", "bchanrt", "rchanrt", "tchanrt", "ringrt";
+ msi-parent = <&inta_main_dmss>;
+ #dma-cells = <3>;
+
+ ti,sci = <&dmsc>;
+ ti,sci-dev-id = <26>;
+
+ ti,sci-rm-range-bchan = <0x20>; /* BLOCK_COPY_CHAN */
+ ti,sci-rm-range-rchan = <0x21>; /* SPLIT_TR_RX_CHAN */
+ ti,sci-rm-range-tchan = <0x22>; /* SPLIT_TR_TX_CHAN */
+ };
+ };
+ };

Documentation/devicetree/bindings/dma/ti/k3-pktdma.yaml

View file
diff --git a/Documentation/devicetree/bindings/dma/ti/k3-pktdma.yaml b/Documentation/devicetree/bindings/dma/ti/k3-pktdma.yaml
new file mode 100644
index 0000000..b13ab60
--- /dev/null
+++ b/Documentation/devicetree/bindings/dma/ti/k3-pktdma.yaml
@@ -0,0 +1,172 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/dma/ti/k3-pktdma.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Texas Instruments K3 DMSS PKTDMA Device Tree Bindings
+
+maintainers:
+ - Peter Ujfalusi <[email protected]>
+
+description: |
+ The Packet DMA (PKTDMA) is intended to perform similar functions as the packet
+ mode channels of K3 UDMA-P.
+ PKTDMA only includes Split channels to service PSI-L based peripherals.
+
+ The peripherals can be PSI-L native or legacy, non PSI-L native peripherals
+ with PDMAs. PDMA is tasked to act as a bridge between the PSI-L fabric and the
+ legacy peripheral.
+
+ PDMAs can be configured via PKTDMA split channel's peer registers to match
+ with the configuration of the legacy peripheral.
+
+allOf:
+ - $ref: /schemas/dma/dma-controller.yaml#
+
+properties:
+ compatible:
+ const: ti,am64-dmss-pktdma
+
+ "#dma-cells":
+ const: 2
+ description: |
+ The first cell is the PSI-L thread ID of the remote (to PKTDMA) end.
+ Valid ranges for thread ID depends on the data movement direction:
+ for source thread IDs (rx): 0 - 0x7fff
+ for destination thread IDs (tx): 0x8000 - 0xffff
+
+ Please refer to the device documentation for the PSI-L thread map and also
+ the PSI-L peripheral chapter for the correct thread ID.
+
+ The second cell is the ASEL value for the channel
+
+ reg:
+ maxItems: 4
+
+ reg-names:
+ items:
+ - const: gcfg
+ - const: rchanrt
+ - const: tchanrt
+ - const: ringrt
+
+ msi-parent: true
+
+ ti,sci-rm-range-tchan:
+ $ref: /schemas/types.yaml#/definitions/uint32-array
+ description: |
+ Array of PKTDMA split tx channel resource subtypes for resource allocation
+ for this host
+ minItems: 1
+ # Should be enough
+ maxItems: 255
+ items:
+ maximum: 0x3f
+
+ ti,sci-rm-range-tflow:
+ $ref: /schemas/types.yaml#/definitions/uint32-array
+ description: |
+ Array of PKTDMA split tx flow resource subtypes for resource allocation
+ for this host
+ minItems: 1
+ # Should be enough
+ maxItems: 255
+ items:
+ maximum: 0x3f
+
+ ti,sci-rm-range-rchan:
+ $ref: /schemas/types.yaml#/definitions/uint32-array
+ description: |
+ Array of PKTDMA split rx channel resource subtypes for resource allocation
+ for this host
+ minItems: 1
+ # Should be enough
+ maxItems: 255
+ items:
+ maximum: 0x3f
+
+ ti,sci-rm-range-rflow:
+ $ref: /schemas/types.yaml#/definitions/uint32-array
+ description: |
+ Array of PKTDMA split rx flow resource subtypes for resource allocation
+ for this host
+ minItems: 1
+ # Should be enough
+ maxItems: 255
+ items:
+ maximum: 0x3f
+
+required:
+ - compatible
+ - "#dma-cells"
+ - reg
+ - reg-names
+ - msi-parent
+ - ti,sci
+ - ti,sci-dev-id
+ - ti,sci-rm-range-tchan
+ - ti,sci-rm-range-tflow
+ - ti,sci-rm-range-rchan
+ - ti,sci-rm-range-rflow
+
+unevaluatedProperties: false
+
+examples:
+ - |+
+ cbass_main {
+ #address-cells = <2>;
+ #size-cells = <2>;
+
+ main_dmss {
+ compatible = "simple-mfd";
+ #address-cells = <2>;
+ #size-cells = <2>;
+ dma-ranges;
+ ranges;
+
+ ti,sci-dev-id = <25>;
+
+ main_pktdma: dma-controller@485c0000 {
+ compatible = "ti,am64-dmss-pktdma";
+
+ reg = <0x0 0x485c0000 0x0 0x100>,
+ <0x0 0x4a800000 0x0 0x20000>,
+ <0x0 0x4aa00000 0x0 0x40000>,
+ <0x0 0x4b800000 0x0 0x400000>;
+ reg-names = "gcfg", "rchanrt", "tchanrt", "ringrt";
+ msi-parent = <&inta_main_dmss>;
+ #dma-cells = <2>;
+
+ ti,sci = <&dmsc>;
+ ti,sci-dev-id = <30>;
+
+ ti,sci-rm-range-tchan = <0x23>, /* UNMAPPED_TX_CHAN */
+ <0x24>, /* CPSW_TX_CHAN */
+ <0x25>, /* SAUL_TX_0_CHAN */
+ <0x26>, /* SAUL_TX_1_CHAN */
+ <0x27>, /* ICSSG_0_TX_CHAN */
+ <0x28>; /* ICSSG_1_TX_CHAN */
+ ti,sci-rm-range-tflow = <0x10>, /* RING_UNMAPPED_TX_CHAN */
+ <0x11>, /* RING_CPSW_TX_CHAN */
+ <0x12>, /* RING_SAUL_TX_0_CHAN */
+ <0x13>, /* RING_SAUL_TX_1_CHAN */
+ <0x14>, /* RING_ICSSG_0_TX_CHAN */
+ <0x15>; /* RING_ICSSG_1_TX_CHAN */
+ ti,sci-rm-range-rchan = <0x29>, /* UNMAPPED_RX_CHAN */
+ <0x2b>, /* CPSW_RX_CHAN */
+ <0x2d>, /* SAUL_RX_0_CHAN */
+ <0x2f>, /* SAUL_RX_1_CHAN */
+ <0x31>, /* SAUL_RX_2_CHAN */
+ <0x33>, /* SAUL_RX_3_CHAN */
+ <0x35>, /* ICSSG_0_RX_CHAN */
+ <0x37>; /* ICSSG_1_RX_CHAN */
+ ti,sci-rm-range-rflow = <0x2a>, /* FLOW_UNMAPPED_RX_CHAN */
+ <0x2c>, /* FLOW_CPSW_RX_CHAN */
+ <0x2e>, /* FLOW_SAUL_RX_0/1_CHAN */
+ <0x32>, /* FLOW_SAUL_RX_2/3_CHAN */
+ <0x36>, /* FLOW_ICSSG_0_RX_CHAN */
+ <0x38>; /* FLOW_ICSSG_1_RX_CHAN */
+ };
+ };
+ };

Documentation/driver-api/dmaengine/client.rst

View file
diff --git a/Documentation/driver-api/dmaengine/client.rst b/Documentation/driver-api/dmaengine/client.rst
index 09a3f66..bfd057b 100644
--- a/Documentation/driver-api/dmaengine/client.rst
+++ b/Documentation/driver-api/dmaengine/client.rst
@@ -120,7 +120,9 @@ The details of these operations are:
.. code-block:: c
- nr_sg = dma_map_sg(chan->device->dev, sgl, sg_len);
+ struct device *dma_dev = dmaengine_get_dma_device(chan);
+
+ nr_sg = dma_map_sg(dma_dev, sgl, sg_len);
if (nr_sg == 0)
/* error */

drivers/dma/Kconfig

View file
diff --git a/drivers/dma/Kconfig b/drivers/dma/Kconfig
index 90284ff..d242c76 100644
--- a/drivers/dma/Kconfig
+++ b/drivers/dma/Kconfig
@@ -296,6 +296,16 @@ config INTEL_IDXD
If unsure, say N.
+# Config symbol that collects all the dependencies that's necessary to
+# support shared virtual memory for the devices supported by idxd.
+config INTEL_IDXD_SVM
+ bool "Accelerator Shared Virtual Memory Support"
+ depends on INTEL_IDXD
+ depends on INTEL_IOMMU_SVM
+ depends on PCI_PRI
+ depends on PCI_PASID
+ depends on PCI_IOV
+
config INTEL_IOATDMA
tristate "Intel I/OAT DMA support"
depends on PCI && X86_64

drivers/dma/at_xdmac.c

View file
diff --git a/drivers/dma/at_xdmac.c b/drivers/dma/at_xdmac.c
index 3b53115..fe45ad5 100644
--- a/drivers/dma/at_xdmac.c
+++ b/drivers/dma/at_xdmac.c
@@ -30,7 +30,24 @@
#define AT_XDMAC_FIFO_SZ(i) (((i) >> 5) & 0x7FF) /* Number of Bytes */
#define AT_XDMAC_NB_REQ(i) ((((i) >> 16) & 0x3F) + 1) /* Number of Peripheral Requests Minus One */
#define AT_XDMAC_GCFG 0x04 /* Global Configuration Register */
+#define AT_XDMAC_WRHP(i) (((i) & 0xF) << 4)
+#define AT_XDMAC_WRMP(i) (((i) & 0xF) << 8)
+#define AT_XDMAC_WRLP(i) (((i) & 0xF) << 12)
+#define AT_XDMAC_RDHP(i) (((i) & 0xF) << 16)
+#define AT_XDMAC_RDMP(i) (((i) & 0xF) << 20)
+#define AT_XDMAC_RDLP(i) (((i) & 0xF) << 24)
+#define AT_XDMAC_RDSG(i) (((i) & 0xF) << 28)
+#define AT_XDMAC_GCFG_M2M (AT_XDMAC_RDLP(0xF) | AT_XDMAC_WRLP(0xF))
+#define AT_XDMAC_GCFG_P2M (AT_XDMAC_RDSG(0x1) | AT_XDMAC_RDHP(0x3) | \
+ AT_XDMAC_WRHP(0x5))
#define AT_XDMAC_GWAC 0x08 /* Global Weighted Arbiter Configuration Register */
+#define AT_XDMAC_PW0(i) (((i) & 0xF) << 0)
+#define AT_XDMAC_PW1(i) (((i) & 0xF) << 4)
+#define AT_XDMAC_PW2(i) (((i) & 0xF) << 8)
+#define AT_XDMAC_PW3(i) (((i) & 0xF) << 12)
+#define AT_XDMAC_GWAC_M2M 0
+#define AT_XDMAC_GWAC_P2M (AT_XDMAC_PW0(0xF) | AT_XDMAC_PW2(0xF))
+
#define AT_XDMAC_GIE 0x0C /* Global Interrupt Enable Register */

This diff is incomplete. Download the complete patch.

drivers/dma/dma-jz4780.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/dmatest.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/dw-axi-dmac/dw-axi-dmac-platform.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/dw/core.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/hisi_dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idma64.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/cdev.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/device.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/idxd.h

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/init.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/irq.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/registers.h

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/submit.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/idxd/sysfs.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/imx-dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/imx-sdma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ipu/ipu_idmac.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/k3dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/milbeaut-xdmac.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/moxart-dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/mv_xor.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/mv_xor_v2.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/mxs-dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/of-dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/pl330.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ppc4xx/adma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/pxa_dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/qcom/Kconfig

View file

This diff is incomplete. Download the complete patch.

drivers/dma/qcom/Makefile

View file

This diff is incomplete. Download the complete patch.

drivers/dma/qcom/bam_dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/qcom/gpi.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/qcom/qcom_adm.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/sf-pdma/sf-pdma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ste_dma40.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/stm32-dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/stm32-dmamux.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/stm32-mdma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/sun6i-dma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/tegra210-adma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/Makefile

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/dma-crossbar.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/k3-psil-am64.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/k3-psil-priv.h

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/k3-psil.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/k3-udma-glue.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/k3-udma-private.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/k3-udma.c

View file

This diff is incomplete. Download the complete patch.

drivers/dma/ti/k3-udma.h

View file

This diff is incomplete. Download the complete patch.

drivers/soc/ti/k3-ringacc.c

View file

This diff is incomplete. Download the complete patch.

include/dt-bindings/dma/jz4775-dma.h

View file

This diff is incomplete. Download the complete patch.

include/dt-bindings/dma/qcom-gpi.h

View file

This diff is incomplete. Download the complete patch.

include/dt-bindings/dma/x2000-dma.h

View file

This diff is incomplete. Download the complete patch.

include/linux/dma/k3-event-router.h

View file

This diff is incomplete. Download the complete patch.

include/linux/dma/k3-psil.h

View file

This diff is incomplete. Download the complete patch.

include/linux/dma/k3-udma-glue.h

View file

This diff is incomplete. Download the complete patch.

include/linux/dma/qcom-gpi-dma.h

View file

This diff is incomplete. Download the complete patch.

include/linux/dmaengine.h

View file

This diff is incomplete. Download the complete patch.

include/linux/soc/ti/k3-ringacc.h

View file

This diff is incomplete. Download the complete patch.

include/uapi/linux/idxd.h

View file

This diff is incomplete. Download the complete patch.