xref: /freebsd/sys/contrib/device-tree/Bindings/media/qcom,msm8953-camss.yaml (revision ae5de77ed78ae54d86cead5604869212e8008e6b)
15f62a964SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
25f62a964SEmmanuel Vadot%YAML 1.2
35f62a964SEmmanuel Vadot---
45f62a964SEmmanuel Vadot$id: http://devicetree.org/schemas/media/qcom,msm8953-camss.yaml#
55f62a964SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
65f62a964SEmmanuel Vadot
75f62a964SEmmanuel Vadottitle: Qualcomm MSM8953 Camera Subsystem (CAMSS)
85f62a964SEmmanuel Vadot
95f62a964SEmmanuel Vadotmaintainers:
105f62a964SEmmanuel Vadot  - Barnabas Czeman <barnabas.czeman@mainlining.org>
115f62a964SEmmanuel Vadot
125f62a964SEmmanuel Vadotdescription:
135f62a964SEmmanuel Vadot  The CAMSS IP is a CSI decoder and ISP present on Qualcomm platforms
145f62a964SEmmanuel Vadot
155f62a964SEmmanuel Vadotproperties:
165f62a964SEmmanuel Vadot  compatible:
175f62a964SEmmanuel Vadot    const: qcom,msm8953-camss
185f62a964SEmmanuel Vadot
195f62a964SEmmanuel Vadot  clocks:
205f62a964SEmmanuel Vadot    minItems: 30
215f62a964SEmmanuel Vadot    maxItems: 30
225f62a964SEmmanuel Vadot
235f62a964SEmmanuel Vadot  clock-names:
245f62a964SEmmanuel Vadot    items:
255f62a964SEmmanuel Vadot      - const: ahb
265f62a964SEmmanuel Vadot      - const: csi0
275f62a964SEmmanuel Vadot      - const: csi0_ahb
285f62a964SEmmanuel Vadot      - const: csi0_phy
295f62a964SEmmanuel Vadot      - const: csi0_pix
305f62a964SEmmanuel Vadot      - const: csi0_rdi
315f62a964SEmmanuel Vadot      - const: csi1
325f62a964SEmmanuel Vadot      - const: csi1_ahb
335f62a964SEmmanuel Vadot      - const: csi1_phy
345f62a964SEmmanuel Vadot      - const: csi1_pix
355f62a964SEmmanuel Vadot      - const: csi1_rdi
365f62a964SEmmanuel Vadot      - const: csi2
375f62a964SEmmanuel Vadot      - const: csi2_ahb
385f62a964SEmmanuel Vadot      - const: csi2_phy
395f62a964SEmmanuel Vadot      - const: csi2_pix
405f62a964SEmmanuel Vadot      - const: csi2_rdi
415f62a964SEmmanuel Vadot      - const: csi_vfe0
425f62a964SEmmanuel Vadot      - const: csi_vfe1
435f62a964SEmmanuel Vadot      - const: csiphy0_timer
445f62a964SEmmanuel Vadot      - const: csiphy1_timer
455f62a964SEmmanuel Vadot      - const: csiphy2_timer
465f62a964SEmmanuel Vadot      - const: ispif_ahb
475f62a964SEmmanuel Vadot      - const: micro_ahb
485f62a964SEmmanuel Vadot      - const: top_ahb
495f62a964SEmmanuel Vadot      - const: vfe0
505f62a964SEmmanuel Vadot      - const: vfe0_ahb
515f62a964SEmmanuel Vadot      - const: vfe0_axi
525f62a964SEmmanuel Vadot      - const: vfe1
535f62a964SEmmanuel Vadot      - const: vfe1_ahb
545f62a964SEmmanuel Vadot      - const: vfe1_axi
555f62a964SEmmanuel Vadot
565f62a964SEmmanuel Vadot  interrupts:
575f62a964SEmmanuel Vadot    minItems: 9
585f62a964SEmmanuel Vadot    maxItems: 9
595f62a964SEmmanuel Vadot
605f62a964SEmmanuel Vadot  interrupt-names:
615f62a964SEmmanuel Vadot    items:
625f62a964SEmmanuel Vadot      - const: csid0
635f62a964SEmmanuel Vadot      - const: csid1
645f62a964SEmmanuel Vadot      - const: csid2
655f62a964SEmmanuel Vadot      - const: csiphy0
665f62a964SEmmanuel Vadot      - const: csiphy1
675f62a964SEmmanuel Vadot      - const: csiphy2
685f62a964SEmmanuel Vadot      - const: ispif
695f62a964SEmmanuel Vadot      - const: vfe0
705f62a964SEmmanuel Vadot      - const: vfe1
715f62a964SEmmanuel Vadot
725f62a964SEmmanuel Vadot  iommus:
735f62a964SEmmanuel Vadot    maxItems: 1
745f62a964SEmmanuel Vadot
755f62a964SEmmanuel Vadot  power-domains:
765f62a964SEmmanuel Vadot    items:
775f62a964SEmmanuel Vadot      - description: VFE0 GDSC - Video Front End, Global Distributed Switch Controller.
785f62a964SEmmanuel Vadot      - description: VFE1 GDSC - Video Front End, Global Distributed Switch Controller.
795f62a964SEmmanuel Vadot
805f62a964SEmmanuel Vadot  power-domain-names:
815f62a964SEmmanuel Vadot    items:
825f62a964SEmmanuel Vadot      - const: vfe0
835f62a964SEmmanuel Vadot      - const: vfe1
845f62a964SEmmanuel Vadot
855f62a964SEmmanuel Vadot  ports:
865f62a964SEmmanuel Vadot    $ref: /schemas/graph.yaml#/properties/ports
875f62a964SEmmanuel Vadot
885f62a964SEmmanuel Vadot    description:
895f62a964SEmmanuel Vadot      CSI input ports.
905f62a964SEmmanuel Vadot
915f62a964SEmmanuel Vadot    properties:
925f62a964SEmmanuel Vadot      port@0:
935f62a964SEmmanuel Vadot        $ref: /schemas/graph.yaml#/$defs/port-base
945f62a964SEmmanuel Vadot        unevaluatedProperties: false
955f62a964SEmmanuel Vadot        description:
965f62a964SEmmanuel Vadot          Input port for receiving CSI data.
975f62a964SEmmanuel Vadot
985f62a964SEmmanuel Vadot        properties:
995f62a964SEmmanuel Vadot          endpoint:
1005f62a964SEmmanuel Vadot            $ref: video-interfaces.yaml#
1015f62a964SEmmanuel Vadot            unevaluatedProperties: false
1025f62a964SEmmanuel Vadot
1035f62a964SEmmanuel Vadot            properties:
1045f62a964SEmmanuel Vadot              data-lanes:
1055f62a964SEmmanuel Vadot                description:
1065f62a964SEmmanuel Vadot                  An array of physical data lanes indexes.
1075f62a964SEmmanuel Vadot                  Position of an entry determines the logical
1085f62a964SEmmanuel Vadot                  lane number, while the value of an entry
1095f62a964SEmmanuel Vadot                  indicates physical lane index. Lane swapping
1105f62a964SEmmanuel Vadot                  is supported. Physical lane indexes;
1115f62a964SEmmanuel Vadot                  0, 2, 3, 4.
1125f62a964SEmmanuel Vadot                minItems: 1
1135f62a964SEmmanuel Vadot                maxItems: 4
1145f62a964SEmmanuel Vadot
115*ae5de77eSEmmanuel Vadot              bus-type:
116*ae5de77eSEmmanuel Vadot                enum:
117*ae5de77eSEmmanuel Vadot                  - 1 # MEDIA_BUS_TYPE_CSI2_CPHY
118*ae5de77eSEmmanuel Vadot                  - 4 # MEDIA_BUS_TYPE_CSI2_DPHY
119*ae5de77eSEmmanuel Vadot
1205f62a964SEmmanuel Vadot            required:
1215f62a964SEmmanuel Vadot              - data-lanes
1225f62a964SEmmanuel Vadot
1235f62a964SEmmanuel Vadot      port@1:
1245f62a964SEmmanuel Vadot        $ref: /schemas/graph.yaml#/$defs/port-base
1255f62a964SEmmanuel Vadot        unevaluatedProperties: false
1265f62a964SEmmanuel Vadot        description:
1275f62a964SEmmanuel Vadot          Input port for receiving CSI data.
1285f62a964SEmmanuel Vadot
1295f62a964SEmmanuel Vadot        properties:
1305f62a964SEmmanuel Vadot          endpoint:
1315f62a964SEmmanuel Vadot            $ref: video-interfaces.yaml#
1325f62a964SEmmanuel Vadot            unevaluatedProperties: false
1335f62a964SEmmanuel Vadot
1345f62a964SEmmanuel Vadot            properties:
1355f62a964SEmmanuel Vadot              data-lanes:
1365f62a964SEmmanuel Vadot                minItems: 1
1375f62a964SEmmanuel Vadot                maxItems: 4
1385f62a964SEmmanuel Vadot
139*ae5de77eSEmmanuel Vadot              bus-type:
140*ae5de77eSEmmanuel Vadot                enum:
141*ae5de77eSEmmanuel Vadot                  - 1 # MEDIA_BUS_TYPE_CSI2_CPHY
142*ae5de77eSEmmanuel Vadot                  - 4 # MEDIA_BUS_TYPE_CSI2_DPHY
143*ae5de77eSEmmanuel Vadot
1445f62a964SEmmanuel Vadot            required:
1455f62a964SEmmanuel Vadot              - data-lanes
1465f62a964SEmmanuel Vadot
1475f62a964SEmmanuel Vadot      port@2:
1485f62a964SEmmanuel Vadot        $ref: /schemas/graph.yaml#/$defs/port-base
1495f62a964SEmmanuel Vadot        unevaluatedProperties: false
1505f62a964SEmmanuel Vadot        description:
1515f62a964SEmmanuel Vadot          Input port for receiving CSI data.
1525f62a964SEmmanuel Vadot
1535f62a964SEmmanuel Vadot        properties:
1545f62a964SEmmanuel Vadot          endpoint:
1555f62a964SEmmanuel Vadot            $ref: video-interfaces.yaml#
1565f62a964SEmmanuel Vadot            unevaluatedProperties: false
1575f62a964SEmmanuel Vadot
1585f62a964SEmmanuel Vadot            properties:
1595f62a964SEmmanuel Vadot              data-lanes:
1605f62a964SEmmanuel Vadot                minItems: 1
1615f62a964SEmmanuel Vadot                maxItems: 4
1625f62a964SEmmanuel Vadot
163*ae5de77eSEmmanuel Vadot              bus-type:
164*ae5de77eSEmmanuel Vadot                enum:
165*ae5de77eSEmmanuel Vadot                  - 1 # MEDIA_BUS_TYPE_CSI2_CPHY
166*ae5de77eSEmmanuel Vadot                  - 4 # MEDIA_BUS_TYPE_CSI2_DPHY
167*ae5de77eSEmmanuel Vadot
1685f62a964SEmmanuel Vadot            required:
1695f62a964SEmmanuel Vadot              - data-lanes
1705f62a964SEmmanuel Vadot
1715f62a964SEmmanuel Vadot  reg:
1725f62a964SEmmanuel Vadot    minItems: 13
1735f62a964SEmmanuel Vadot    maxItems: 13
1745f62a964SEmmanuel Vadot
1755f62a964SEmmanuel Vadot  reg-names:
1765f62a964SEmmanuel Vadot    items:
1775f62a964SEmmanuel Vadot      - const: csi_clk_mux
1785f62a964SEmmanuel Vadot      - const: csid0
1795f62a964SEmmanuel Vadot      - const: csid1
1805f62a964SEmmanuel Vadot      - const: csid2
1815f62a964SEmmanuel Vadot      - const: csiphy0
1825f62a964SEmmanuel Vadot      - const: csiphy0_clk_mux
1835f62a964SEmmanuel Vadot      - const: csiphy1
1845f62a964SEmmanuel Vadot      - const: csiphy1_clk_mux
1855f62a964SEmmanuel Vadot      - const: csiphy2
1865f62a964SEmmanuel Vadot      - const: csiphy2_clk_mux
1875f62a964SEmmanuel Vadot      - const: ispif
1885f62a964SEmmanuel Vadot      - const: vfe0
1895f62a964SEmmanuel Vadot      - const: vfe1
1905f62a964SEmmanuel Vadot
1915f62a964SEmmanuel Vadot  vdda-supply:
1925f62a964SEmmanuel Vadot    description:
1935f62a964SEmmanuel Vadot      Definition of the regulator used as analog power supply.
1945f62a964SEmmanuel Vadot
1955f62a964SEmmanuel Vadotrequired:
1965f62a964SEmmanuel Vadot  - compatible
1975f62a964SEmmanuel Vadot  - reg
1985f62a964SEmmanuel Vadot  - reg-names
1995f62a964SEmmanuel Vadot  - clocks
2005f62a964SEmmanuel Vadot  - clock-names
2015f62a964SEmmanuel Vadot  - interrupts
2025f62a964SEmmanuel Vadot  - interrupt-names
2035f62a964SEmmanuel Vadot  - iommus
2045f62a964SEmmanuel Vadot  - power-domains
2055f62a964SEmmanuel Vadot  - power-domain-names
2065f62a964SEmmanuel Vadot  - vdda-supply
2075f62a964SEmmanuel Vadot
2085f62a964SEmmanuel VadotadditionalProperties: false
2095f62a964SEmmanuel Vadot
2105f62a964SEmmanuel Vadotexamples:
2115f62a964SEmmanuel Vadot  - |
2125f62a964SEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
2135f62a964SEmmanuel Vadot    #include <dt-bindings/clock/qcom,gcc-msm8953.h>
2145f62a964SEmmanuel Vadot
2155f62a964SEmmanuel Vadot    camss: camss@1b00020 {
2165f62a964SEmmanuel Vadot        compatible = "qcom,msm8953-camss";
2175f62a964SEmmanuel Vadot
2185f62a964SEmmanuel Vadot        reg = <0x1b00020 0x10>,
2195f62a964SEmmanuel Vadot              <0x1b30000 0x100>,
2205f62a964SEmmanuel Vadot              <0x1b30400 0x100>,
2215f62a964SEmmanuel Vadot              <0x1b30800 0x100>,
2225f62a964SEmmanuel Vadot              <0x1b34000 0x1000>,
2235f62a964SEmmanuel Vadot              <0x1b00030 0x4>,
2245f62a964SEmmanuel Vadot              <0x1b35000 0x1000>,
2255f62a964SEmmanuel Vadot              <0x1b00038 0x4>,
2265f62a964SEmmanuel Vadot              <0x1b36000 0x1000>,
2275f62a964SEmmanuel Vadot              <0x1b00040 0x4>,
2285f62a964SEmmanuel Vadot              <0x1b31000 0x500>,
2295f62a964SEmmanuel Vadot              <0x1b10000 0x1000>,
2305f62a964SEmmanuel Vadot              <0x1b14000 0x1000>;
2315f62a964SEmmanuel Vadot        reg-names = "csi_clk_mux",
2325f62a964SEmmanuel Vadot                    "csid0",
2335f62a964SEmmanuel Vadot                    "csid1",
2345f62a964SEmmanuel Vadot                    "csid2",
2355f62a964SEmmanuel Vadot                    "csiphy0",
2365f62a964SEmmanuel Vadot                    "csiphy0_clk_mux",
2375f62a964SEmmanuel Vadot                    "csiphy1",
2385f62a964SEmmanuel Vadot                    "csiphy1_clk_mux",
2395f62a964SEmmanuel Vadot                    "csiphy2",
2405f62a964SEmmanuel Vadot                    "csiphy2_clk_mux",
2415f62a964SEmmanuel Vadot                    "ispif",
2425f62a964SEmmanuel Vadot                    "vfe0",
2435f62a964SEmmanuel Vadot                    "vfe1";
2445f62a964SEmmanuel Vadot
2455f62a964SEmmanuel Vadot        clocks = <&gcc GCC_CAMSS_AHB_CLK>,
2465f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI0_CLK>,
2475f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI0_AHB_CLK>,
2485f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI0PHY_CLK>,
2495f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI0PIX_CLK>,
2505f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI0RDI_CLK>,
2515f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI1_CLK>,
2525f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI1_AHB_CLK>,
2535f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI1PHY_CLK>,
2545f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI1PIX_CLK>,
2555f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI1RDI_CLK>,
2565f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI2_CLK>,
2575f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI2_AHB_CLK>,
2585f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI2PHY_CLK>,
2595f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI2PIX_CLK>,
2605f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI2RDI_CLK>,
2615f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI_VFE0_CLK>,
2625f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI_VFE1_CLK>,
2635f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI0PHYTIMER_CLK>,
2645f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI1PHYTIMER_CLK>,
2655f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_CSI2PHYTIMER_CLK>,
2665f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_ISPIF_AHB_CLK>,
2675f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_MICRO_AHB_CLK>,
2685f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_TOP_AHB_CLK>,
2695f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_VFE0_CLK>,
2705f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_VFE0_AHB_CLK>,
2715f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_VFE0_AXI_CLK>,
2725f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_VFE1_CLK>,
2735f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_VFE1_AHB_CLK>,
2745f62a964SEmmanuel Vadot                 <&gcc GCC_CAMSS_VFE1_AXI_CLK>;
2755f62a964SEmmanuel Vadot        clock-names = "ahb",
2765f62a964SEmmanuel Vadot                      "csi0",
2775f62a964SEmmanuel Vadot                      "csi0_ahb",
2785f62a964SEmmanuel Vadot                      "csi0_phy",
2795f62a964SEmmanuel Vadot                      "csi0_pix",
2805f62a964SEmmanuel Vadot                      "csi0_rdi",
2815f62a964SEmmanuel Vadot                      "csi1",
2825f62a964SEmmanuel Vadot                      "csi1_ahb",
2835f62a964SEmmanuel Vadot                      "csi1_phy",
2845f62a964SEmmanuel Vadot                      "csi1_pix",
2855f62a964SEmmanuel Vadot                      "csi1_rdi",
2865f62a964SEmmanuel Vadot                      "csi2",
2875f62a964SEmmanuel Vadot                      "csi2_ahb",
2885f62a964SEmmanuel Vadot                      "csi2_phy",
2895f62a964SEmmanuel Vadot                      "csi2_pix",
2905f62a964SEmmanuel Vadot                      "csi2_rdi",
2915f62a964SEmmanuel Vadot                      "csi_vfe0",
2925f62a964SEmmanuel Vadot                      "csi_vfe1",
2935f62a964SEmmanuel Vadot                      "csiphy0_timer",
2945f62a964SEmmanuel Vadot                      "csiphy1_timer",
2955f62a964SEmmanuel Vadot                      "csiphy2_timer",
2965f62a964SEmmanuel Vadot                      "ispif_ahb",
2975f62a964SEmmanuel Vadot                      "micro_ahb",
2985f62a964SEmmanuel Vadot                      "top_ahb",
2995f62a964SEmmanuel Vadot                      "vfe0",
3005f62a964SEmmanuel Vadot                      "vfe0_ahb",
3015f62a964SEmmanuel Vadot                      "vfe0_axi",
3025f62a964SEmmanuel Vadot                      "vfe1",
3035f62a964SEmmanuel Vadot                      "vfe1_ahb",
3045f62a964SEmmanuel Vadot                      "vfe1_axi";
3055f62a964SEmmanuel Vadot
3065f62a964SEmmanuel Vadot        interrupts = <GIC_SPI 51 IRQ_TYPE_EDGE_RISING>,
3075f62a964SEmmanuel Vadot                     <GIC_SPI 52 IRQ_TYPE_EDGE_RISING>,
3085f62a964SEmmanuel Vadot                     <GIC_SPI 153 IRQ_TYPE_EDGE_RISING>,
3095f62a964SEmmanuel Vadot                     <GIC_SPI 78 IRQ_TYPE_EDGE_RISING>,
3105f62a964SEmmanuel Vadot                     <GIC_SPI 79 IRQ_TYPE_EDGE_RISING>,
3115f62a964SEmmanuel Vadot                     <GIC_SPI 315 IRQ_TYPE_EDGE_RISING>,
3125f62a964SEmmanuel Vadot                     <GIC_SPI 55 IRQ_TYPE_EDGE_RISING>,
3135f62a964SEmmanuel Vadot                     <GIC_SPI 57 IRQ_TYPE_EDGE_RISING>,
3145f62a964SEmmanuel Vadot                     <GIC_SPI 29 IRQ_TYPE_EDGE_RISING>;
3155f62a964SEmmanuel Vadot        interrupt-names = "csid0",
3165f62a964SEmmanuel Vadot                          "csid1",
3175f62a964SEmmanuel Vadot                          "csid2",
3185f62a964SEmmanuel Vadot                          "csiphy0",
3195f62a964SEmmanuel Vadot                          "csiphy1",
3205f62a964SEmmanuel Vadot                          "csiphy2",
3215f62a964SEmmanuel Vadot                          "ispif",
3225f62a964SEmmanuel Vadot                          "vfe0",
3235f62a964SEmmanuel Vadot                          "vfe1";
3245f62a964SEmmanuel Vadot
3255f62a964SEmmanuel Vadot        iommus = <&apps_iommu 0x14>;
3265f62a964SEmmanuel Vadot
3275f62a964SEmmanuel Vadot        power-domains = <&gcc VFE0_GDSC>,
3285f62a964SEmmanuel Vadot                        <&gcc VFE1_GDSC>;
3295f62a964SEmmanuel Vadot        power-domain-names = "vfe0", "vfe1";
3305f62a964SEmmanuel Vadot
3315f62a964SEmmanuel Vadot        vdda-supply = <&reg_2v8>;
3325f62a964SEmmanuel Vadot
3335f62a964SEmmanuel Vadot        ports {
3345f62a964SEmmanuel Vadot            #address-cells = <1>;
3355f62a964SEmmanuel Vadot            #size-cells = <0>;
3365f62a964SEmmanuel Vadot        };
3375f62a964SEmmanuel Vadot    };
338