1858de34cSSinan KayaQualcomm Technologies HIDMA Management interface 2858de34cSSinan Kaya 3858de34cSSinan KayaQualcomm Technologies HIDMA is a high speed DMA device. It only supports 4858de34cSSinan Kayamemcpy and memset capabilities. It has been designed for virtualized 5858de34cSSinan Kayaenvironments. 6858de34cSSinan Kaya 7858de34cSSinan KayaEach HIDMA HW instance consists of multiple DMA channels. These channels 813af1c8cSSinan Kayashare the same bandwidth. The bandwidth utilization can be partitioned 9858de34cSSinan Kayaamong channels based on the priority and weight assignments. 10858de34cSSinan Kaya 11858de34cSSinan KayaThere are only two priority levels and 15 weigh assignments possible. 12858de34cSSinan Kaya 13858de34cSSinan KayaOther parameters here determine how much of the system bus this HIDMA 1413af1c8cSSinan Kayainstance can use like maximum read/write request and number of bytes to 15858de34cSSinan Kayaread/write in a single burst. 16858de34cSSinan Kaya 17858de34cSSinan KayaMain node required properties: 18858de34cSSinan Kaya- compatible: "qcom,hidma-mgmt-1.0"; 19858de34cSSinan Kaya- reg: Address range for DMA device 20858de34cSSinan Kaya- dma-channels: Number of channels supported by this DMA controller. 21858de34cSSinan Kaya- max-write-burst-bytes: Maximum write burst in bytes that HIDMA can 22858de34cSSinan Kaya occupy the bus for in a single transaction. A memcpy requested is 23858de34cSSinan Kaya fragmented to multiples of this amount. This parameter is used while 24858de34cSSinan Kaya writing into destination memory. Setting this value incorrectly can 25858de34cSSinan Kaya starve other peripherals in the system. 26858de34cSSinan Kaya- max-read-burst-bytes: Maximum read burst in bytes that HIDMA can 27858de34cSSinan Kaya occupy the bus for in a single transaction. A memcpy request is 28858de34cSSinan Kaya fragmented to multiples of this amount. This parameter is used while 29858de34cSSinan Kaya reading the source memory. Setting this value incorrectly can starve 30858de34cSSinan Kaya other peripherals in the system. 31858de34cSSinan Kaya- max-write-transactions: This value is how many times a write burst is 32858de34cSSinan Kaya applied back to back while writing to the destination before yielding 33858de34cSSinan Kaya the bus. 34858de34cSSinan Kaya- max-read-transactions: This value is how many times a read burst is 35858de34cSSinan Kaya applied back to back while reading the source before yielding the bus. 36858de34cSSinan Kaya- channel-reset-timeout-cycles: Channel reset timeout in cycles for this SOC. 37858de34cSSinan Kaya Once a reset is applied to the HW, HW starts a timer for reset operation 38858de34cSSinan Kaya to confirm. If reset is not completed within this time, HW reports reset 39858de34cSSinan Kaya failure. 40858de34cSSinan Kaya 41858de34cSSinan KayaSub-nodes: 42858de34cSSinan Kaya 43858de34cSSinan KayaHIDMA has one or more DMA channels that are used to move data from one 44858de34cSSinan Kayamemory location to another. 45858de34cSSinan Kaya 46858de34cSSinan KayaWhen the OS is not in control of the management interface (i.e. it's a guest), 47858de34cSSinan Kayathe channel nodes appear on their own, not under a management node. 48858de34cSSinan Kaya 49858de34cSSinan KayaRequired properties: 50*afc996a3SSinan Kaya- compatible: must contain "qcom,hidma-1.0" for initial HW or 51*afc996a3SSinan Kaya "qcom,hidma-1.1"/"qcom,hidma-1.2" for MSI capable HW. 52858de34cSSinan Kaya- reg: Addresses for the transfer and event channel 53858de34cSSinan Kaya- interrupts: Should contain the event interrupt 54858de34cSSinan Kaya- desc-count: Number of asynchronous requests this channel can handle 55858de34cSSinan Kaya- iommus: required a iommu node 56858de34cSSinan Kaya 57ef6661bfSSinan KayaOptional properties for MSI: 58ef6661bfSSinan Kaya- msi-parent : See the generic MSI binding described in 59ef6661bfSSinan Kaya devicetree/bindings/interrupt-controller/msi.txt for a description of the 60ef6661bfSSinan Kaya msi-parent property. 61ef6661bfSSinan Kaya 62858de34cSSinan KayaExample: 63858de34cSSinan Kaya 64858de34cSSinan KayaHypervisor OS configuration: 65858de34cSSinan Kaya 66858de34cSSinan Kaya hidma-mgmt@f9984000 = { 67858de34cSSinan Kaya compatible = "qcom,hidma-mgmt-1.0"; 68858de34cSSinan Kaya reg = <0xf9984000 0x15000>; 69858de34cSSinan Kaya dma-channels = <6>; 70858de34cSSinan Kaya max-write-burst-bytes = <1024>; 71858de34cSSinan Kaya max-read-burst-bytes = <1024>; 72858de34cSSinan Kaya max-write-transactions = <31>; 73858de34cSSinan Kaya max-read-transactions = <31>; 74858de34cSSinan Kaya channel-reset-timeout-cycles = <0x500>; 75858de34cSSinan Kaya 764c9847b7SMathieu Malaterre hidma_24: dma-controller@5c050000 { 77858de34cSSinan Kaya compatible = "qcom,hidma-1.0"; 78858de34cSSinan Kaya reg = <0 0x5c050000 0x0 0x1000>, 79858de34cSSinan Kaya <0 0x5c0b0000 0x0 0x1000>; 80858de34cSSinan Kaya interrupts = <0 389 0>; 81858de34cSSinan Kaya desc-count = <10>; 82858de34cSSinan Kaya iommus = <&system_mmu>; 83858de34cSSinan Kaya }; 84858de34cSSinan Kaya }; 85858de34cSSinan Kaya 86858de34cSSinan KayaGuest OS configuration: 87858de34cSSinan Kaya 884c9847b7SMathieu Malaterre hidma_24: dma-controller@5c050000 { 89858de34cSSinan Kaya compatible = "qcom,hidma-1.0"; 90858de34cSSinan Kaya reg = <0 0x5c050000 0x0 0x1000>, 91858de34cSSinan Kaya <0 0x5c0b0000 0x0 0x1000>; 92858de34cSSinan Kaya interrupts = <0 389 0>; 93858de34cSSinan Kaya desc-count = <10>; 94858de34cSSinan Kaya iommus = <&system_mmu>; 95858de34cSSinan Kaya }; 96