1*4c83f6f0Skyrie wu# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 2*4c83f6f0Skyrie wu%YAML 1.2 3*4c83f6f0Skyrie wu--- 4*4c83f6f0Skyrie wu$id: http://devicetree.org/schemas/media/mediatek,mt8195-jpegdec.yaml# 5*4c83f6f0Skyrie wu$schema: http://devicetree.org/meta-schemas/core.yaml# 6*4c83f6f0Skyrie wu 7*4c83f6f0Skyrie wutitle: MediaTek JPEG Decoder 8*4c83f6f0Skyrie wu 9*4c83f6f0Skyrie wumaintainers: 10*4c83f6f0Skyrie wu - kyrie wu <kyrie.wu@mediatek.corp-partner.google.com> 11*4c83f6f0Skyrie wu 12*4c83f6f0Skyrie wudescription: 13*4c83f6f0Skyrie wu MediaTek JPEG Decoder is the JPEG decode hardware present in MediaTek SoCs 14*4c83f6f0Skyrie wu 15*4c83f6f0Skyrie wuproperties: 16*4c83f6f0Skyrie wu compatible: 17*4c83f6f0Skyrie wu const: mediatek,mt8195-jpgdec 18*4c83f6f0Skyrie wu 19*4c83f6f0Skyrie wu power-domains: 20*4c83f6f0Skyrie wu maxItems: 1 21*4c83f6f0Skyrie wu 22*4c83f6f0Skyrie wu iommus: 23*4c83f6f0Skyrie wu maxItems: 6 24*4c83f6f0Skyrie wu description: 25*4c83f6f0Skyrie wu Points to the respective IOMMU block with master port as argument, see 26*4c83f6f0Skyrie wu Documentation/devicetree/bindings/iommu/mediatek,iommu.yaml for details. 27*4c83f6f0Skyrie wu Ports are according to the HW. 28*4c83f6f0Skyrie wu 29*4c83f6f0Skyrie wu "#address-cells": 30*4c83f6f0Skyrie wu const: 2 31*4c83f6f0Skyrie wu 32*4c83f6f0Skyrie wu "#size-cells": 33*4c83f6f0Skyrie wu const: 2 34*4c83f6f0Skyrie wu 35*4c83f6f0Skyrie wu ranges: true 36*4c83f6f0Skyrie wu 37*4c83f6f0Skyrie wu# Required child node: 38*4c83f6f0Skyrie wupatternProperties: 39*4c83f6f0Skyrie wu "^jpgdec@[0-9a-f]+$": 40*4c83f6f0Skyrie wu type: object 41*4c83f6f0Skyrie wu description: 42*4c83f6f0Skyrie wu The jpeg decoder hardware device node which should be added as subnodes to 43*4c83f6f0Skyrie wu the main jpeg node. 44*4c83f6f0Skyrie wu 45*4c83f6f0Skyrie wu properties: 46*4c83f6f0Skyrie wu compatible: 47*4c83f6f0Skyrie wu const: mediatek,mt8195-jpgdec-hw 48*4c83f6f0Skyrie wu 49*4c83f6f0Skyrie wu reg: 50*4c83f6f0Skyrie wu maxItems: 1 51*4c83f6f0Skyrie wu 52*4c83f6f0Skyrie wu iommus: 53*4c83f6f0Skyrie wu minItems: 1 54*4c83f6f0Skyrie wu maxItems: 32 55*4c83f6f0Skyrie wu description: 56*4c83f6f0Skyrie wu List of the hardware port in respective IOMMU block for current Socs. 57*4c83f6f0Skyrie wu Refer to bindings/iommu/mediatek,iommu.yaml. 58*4c83f6f0Skyrie wu 59*4c83f6f0Skyrie wu interrupts: 60*4c83f6f0Skyrie wu maxItems: 1 61*4c83f6f0Skyrie wu 62*4c83f6f0Skyrie wu clocks: 63*4c83f6f0Skyrie wu maxItems: 1 64*4c83f6f0Skyrie wu 65*4c83f6f0Skyrie wu clock-names: 66*4c83f6f0Skyrie wu items: 67*4c83f6f0Skyrie wu - const: jpgdec 68*4c83f6f0Skyrie wu 69*4c83f6f0Skyrie wu power-domains: 70*4c83f6f0Skyrie wu maxItems: 1 71*4c83f6f0Skyrie wu 72*4c83f6f0Skyrie wu required: 73*4c83f6f0Skyrie wu - compatible 74*4c83f6f0Skyrie wu - reg 75*4c83f6f0Skyrie wu - iommus 76*4c83f6f0Skyrie wu - interrupts 77*4c83f6f0Skyrie wu - clocks 78*4c83f6f0Skyrie wu - clock-names 79*4c83f6f0Skyrie wu - power-domains 80*4c83f6f0Skyrie wu 81*4c83f6f0Skyrie wu additionalProperties: false 82*4c83f6f0Skyrie wu 83*4c83f6f0Skyrie wurequired: 84*4c83f6f0Skyrie wu - compatible 85*4c83f6f0Skyrie wu - power-domains 86*4c83f6f0Skyrie wu - iommus 87*4c83f6f0Skyrie wu - ranges 88*4c83f6f0Skyrie wu 89*4c83f6f0Skyrie wuadditionalProperties: false 90*4c83f6f0Skyrie wu 91*4c83f6f0Skyrie wuexamples: 92*4c83f6f0Skyrie wu - | 93*4c83f6f0Skyrie wu #include <dt-bindings/interrupt-controller/arm-gic.h> 94*4c83f6f0Skyrie wu #include <dt-bindings/memory/mt8195-memory-port.h> 95*4c83f6f0Skyrie wu #include <dt-bindings/interrupt-controller/irq.h> 96*4c83f6f0Skyrie wu #include <dt-bindings/clock/mt8195-clk.h> 97*4c83f6f0Skyrie wu #include <dt-bindings/power/mt8195-power.h> 98*4c83f6f0Skyrie wu 99*4c83f6f0Skyrie wu soc { 100*4c83f6f0Skyrie wu #address-cells = <2>; 101*4c83f6f0Skyrie wu #size-cells = <2>; 102*4c83f6f0Skyrie wu 103*4c83f6f0Skyrie wu jpgdec-master { 104*4c83f6f0Skyrie wu compatible = "mediatek,mt8195-jpgdec"; 105*4c83f6f0Skyrie wu power-domains = <&spm MT8195_POWER_DOMAIN_VDEC1>; 106*4c83f6f0Skyrie wu iommus = <&iommu_vpp M4U_PORT_L19_JPGDEC_WDMA0>, 107*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L19_JPGDEC_BSDMA0>, 108*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L19_JPGDEC_WDMA1>, 109*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L19_JPGDEC_BSDMA1>, 110*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L19_JPGDEC_BUFF_OFFSET1>, 111*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L19_JPGDEC_BUFF_OFFSET0>; 112*4c83f6f0Skyrie wu #address-cells = <2>; 113*4c83f6f0Skyrie wu #size-cells = <2>; 114*4c83f6f0Skyrie wu ranges; 115*4c83f6f0Skyrie wu 116*4c83f6f0Skyrie wu jpgdec@1a040000 { 117*4c83f6f0Skyrie wu compatible = "mediatek,mt8195-jpgdec-hw"; 118*4c83f6f0Skyrie wu reg = <0 0x1a040000 0 0x10000>;/* JPGDEC_C0 */ 119*4c83f6f0Skyrie wu iommus = <&iommu_vdo M4U_PORT_L19_JPGDEC_WDMA0>, 120*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_BSDMA0>, 121*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_WDMA1>, 122*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_BSDMA1>, 123*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_BUFF_OFFSET1>, 124*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_BUFF_OFFSET0>; 125*4c83f6f0Skyrie wu interrupts = <GIC_SPI 343 IRQ_TYPE_LEVEL_HIGH 0>; 126*4c83f6f0Skyrie wu clocks = <&vencsys CLK_VENC_JPGDEC>; 127*4c83f6f0Skyrie wu clock-names = "jpgdec"; 128*4c83f6f0Skyrie wu power-domains = <&spm MT8195_POWER_DOMAIN_VDEC0>; 129*4c83f6f0Skyrie wu }; 130*4c83f6f0Skyrie wu 131*4c83f6f0Skyrie wu jpgdec@1a050000 { 132*4c83f6f0Skyrie wu compatible = "mediatek,mt8195-jpgdec-hw"; 133*4c83f6f0Skyrie wu reg = <0 0x1a050000 0 0x10000>;/* JPGDEC_C1 */ 134*4c83f6f0Skyrie wu iommus = <&iommu_vdo M4U_PORT_L19_JPGDEC_WDMA0>, 135*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_BSDMA0>, 136*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_WDMA1>, 137*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_BSDMA1>, 138*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_BUFF_OFFSET1>, 139*4c83f6f0Skyrie wu <&iommu_vdo M4U_PORT_L19_JPGDEC_BUFF_OFFSET0>; 140*4c83f6f0Skyrie wu interrupts = <GIC_SPI 344 IRQ_TYPE_LEVEL_HIGH 0>; 141*4c83f6f0Skyrie wu clocks = <&vencsys CLK_VENC_JPGDEC_C1>; 142*4c83f6f0Skyrie wu clock-names = "jpgdec"; 143*4c83f6f0Skyrie wu power-domains = <&spm MT8195_POWER_DOMAIN_VDEC1>; 144*4c83f6f0Skyrie wu }; 145*4c83f6f0Skyrie wu 146*4c83f6f0Skyrie wu jpgdec@1b040000 { 147*4c83f6f0Skyrie wu compatible = "mediatek,mt8195-jpgdec-hw"; 148*4c83f6f0Skyrie wu reg = <0 0x1b040000 0 0x10000>;/* JPGDEC_C2 */ 149*4c83f6f0Skyrie wu iommus = <&iommu_vpp M4U_PORT_L20_JPGDEC_WDMA0>, 150*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L20_JPGDEC_BSDMA0>, 151*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L20_JPGDEC_WDMA1>, 152*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L20_JPGDEC_BSDMA1>, 153*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L20_JPGDEC_BUFF_OFFSET1>, 154*4c83f6f0Skyrie wu <&iommu_vpp M4U_PORT_L20_JPGDEC_BUFF_OFFSET0>; 155*4c83f6f0Skyrie wu interrupts = <GIC_SPI 348 IRQ_TYPE_LEVEL_HIGH 0>; 156*4c83f6f0Skyrie wu clocks = <&vencsys_core1 CLK_VENC_CORE1_JPGDEC>; 157*4c83f6f0Skyrie wu clock-names = "jpgdec"; 158*4c83f6f0Skyrie wu power-domains = <&spm MT8195_POWER_DOMAIN_VDEC2>; 159*4c83f6f0Skyrie wu }; 160*4c83f6f0Skyrie wu }; 161*4c83f6f0Skyrie wu }; 162