xref: /freebsd/sys/contrib/device-tree/Bindings/media/nxp,imx8-jpeg.yaml (revision 7d0873ebb83b19ba1e8a89e679470d885efe12e3)
12eb4d8dcSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
22eb4d8dcSEmmanuel Vadot%YAML 1.2
32eb4d8dcSEmmanuel Vadot---
42eb4d8dcSEmmanuel Vadot$id: http://devicetree.org/schemas/media/nxp,imx8-jpeg.yaml#
52eb4d8dcSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
62eb4d8dcSEmmanuel Vadot
77ef62cebSEmmanuel Vadottitle: i.MX8QXP/QM JPEG decoder/encoder
82eb4d8dcSEmmanuel Vadot
92eb4d8dcSEmmanuel Vadotmaintainers:
102eb4d8dcSEmmanuel Vadot  - Mirela Rabulea <mirela.rabulea@nxp.com>
112eb4d8dcSEmmanuel Vadot
122eb4d8dcSEmmanuel Vadotdescription: |-
132eb4d8dcSEmmanuel Vadot  The JPEG decoder/encoder present in iMX8QXP and iMX8QM SoCs is an
142eb4d8dcSEmmanuel Vadot  ISO/IEC 10918-1 JPEG standard compliant decoder/encoder, for Baseline
152eb4d8dcSEmmanuel Vadot  and Extended Sequential DCT modes.
162eb4d8dcSEmmanuel Vadot
172eb4d8dcSEmmanuel Vadotproperties:
182eb4d8dcSEmmanuel Vadot  compatible:
19354d7675SEmmanuel Vadot    oneOf:
20354d7675SEmmanuel Vadot      - items:
21354d7675SEmmanuel Vadot          enum:
222eb4d8dcSEmmanuel Vadot            - nxp,imx8qxp-jpgdec
232eb4d8dcSEmmanuel Vadot            - nxp,imx8qxp-jpgenc
24354d7675SEmmanuel Vadot      - items:
25354d7675SEmmanuel Vadot          - const: nxp,imx8qm-jpgdec
26354d7675SEmmanuel Vadot          - const: nxp,imx8qxp-jpgdec
27354d7675SEmmanuel Vadot      - items:
28354d7675SEmmanuel Vadot          - const: nxp,imx8qm-jpgenc
29354d7675SEmmanuel Vadot          - const: nxp,imx8qxp-jpgenc
302eb4d8dcSEmmanuel Vadot
312eb4d8dcSEmmanuel Vadot  reg:
322eb4d8dcSEmmanuel Vadot    maxItems: 1
332eb4d8dcSEmmanuel Vadot
34*7d0873ebSEmmanuel Vadot  clocks:
35*7d0873ebSEmmanuel Vadot    items:
36*7d0873ebSEmmanuel Vadot      - description: AXI DMA engine clock for fetching JPEG bitstream from memory (per)
37*7d0873ebSEmmanuel Vadot      - description: IP bus clock for register access (ipg)
38*7d0873ebSEmmanuel Vadot
392eb4d8dcSEmmanuel Vadot  interrupts:
402eb4d8dcSEmmanuel Vadot    description: |
412eb4d8dcSEmmanuel Vadot      There are 4 slots available in the IP, which the driver may use
422eb4d8dcSEmmanuel Vadot      If a certain slot is used, it should have an associated interrupt
432eb4d8dcSEmmanuel Vadot      The interrupt with index i is assumed to be for slot i
442eb4d8dcSEmmanuel Vadot    minItems: 1               # At least one slot is needed by the driver
452eb4d8dcSEmmanuel Vadot    maxItems: 4               # The IP has 4 slots available for use
462eb4d8dcSEmmanuel Vadot
472eb4d8dcSEmmanuel Vadot  power-domains:
482eb4d8dcSEmmanuel Vadot    description:
492eb4d8dcSEmmanuel Vadot      List of phandle and PM domain specifier as documented in
502eb4d8dcSEmmanuel Vadot      Documentation/devicetree/bindings/power/power_domain.txt
512eb4d8dcSEmmanuel Vadot    minItems: 2               # Wrapper and 1 slot
522eb4d8dcSEmmanuel Vadot    maxItems: 5               # Wrapper and 4 slots
532eb4d8dcSEmmanuel Vadot
542eb4d8dcSEmmanuel Vadotrequired:
552eb4d8dcSEmmanuel Vadot  - compatible
562eb4d8dcSEmmanuel Vadot  - reg
57*7d0873ebSEmmanuel Vadot  - clocks
582eb4d8dcSEmmanuel Vadot  - interrupts
592eb4d8dcSEmmanuel Vadot  - power-domains
602eb4d8dcSEmmanuel Vadot
612eb4d8dcSEmmanuel VadotadditionalProperties: false
622eb4d8dcSEmmanuel Vadot
632eb4d8dcSEmmanuel Vadotexamples:
642eb4d8dcSEmmanuel Vadot  - |
65*7d0873ebSEmmanuel Vadot    #include <dt-bindings/clock/imx8-lpcg.h>
662eb4d8dcSEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
672eb4d8dcSEmmanuel Vadot    #include <dt-bindings/firmware/imx/rsrc.h>
682eb4d8dcSEmmanuel Vadot
692eb4d8dcSEmmanuel Vadot    jpegdec: jpegdec@58400000 {
702eb4d8dcSEmmanuel Vadot        compatible = "nxp,imx8qxp-jpgdec";
712eb4d8dcSEmmanuel Vadot        reg = <0x58400000 0x00050000 >;
72*7d0873ebSEmmanuel Vadot        clocks = <&img_jpeg_dec_lpcg IMX_LPCG_CLK_0>,
73*7d0873ebSEmmanuel Vadot                 <&img_jpeg_dec_lpcg IMX_LPCG_CLK_4>;
742eb4d8dcSEmmanuel Vadot        interrupts = <GIC_SPI 309 IRQ_TYPE_LEVEL_HIGH>,
752eb4d8dcSEmmanuel Vadot                     <GIC_SPI 310 IRQ_TYPE_LEVEL_HIGH>,
762eb4d8dcSEmmanuel Vadot                     <GIC_SPI 311 IRQ_TYPE_LEVEL_HIGH>,
772eb4d8dcSEmmanuel Vadot                     <GIC_SPI 312 IRQ_TYPE_LEVEL_HIGH>;
782eb4d8dcSEmmanuel Vadot        power-domains = <&pd IMX_SC_R_MJPEG_DEC_MP>,
792eb4d8dcSEmmanuel Vadot                        <&pd IMX_SC_R_MJPEG_DEC_S0>,
802eb4d8dcSEmmanuel Vadot                        <&pd IMX_SC_R_MJPEG_DEC_S1>,
812eb4d8dcSEmmanuel Vadot                        <&pd IMX_SC_R_MJPEG_DEC_S2>,
822eb4d8dcSEmmanuel Vadot                        <&pd IMX_SC_R_MJPEG_DEC_S3>;
832eb4d8dcSEmmanuel Vadot    };
842eb4d8dcSEmmanuel Vadot
852eb4d8dcSEmmanuel Vadot    jpegenc: jpegenc@58450000 {
86354d7675SEmmanuel Vadot        compatible = "nxp,imx8qm-jpgenc", "nxp,imx8qxp-jpgenc";
872eb4d8dcSEmmanuel Vadot        reg = <0x58450000 0x00050000 >;
88*7d0873ebSEmmanuel Vadot        clocks = <&img_jpeg_enc_lpcg IMX_LPCG_CLK_0>,
89*7d0873ebSEmmanuel Vadot                 <&img_jpeg__lpcg IMX_LPCG_CLK_4>;
902eb4d8dcSEmmanuel Vadot        interrupts = <GIC_SPI 305 IRQ_TYPE_LEVEL_HIGH>,
912eb4d8dcSEmmanuel Vadot                     <GIC_SPI 306 IRQ_TYPE_LEVEL_HIGH>,
922eb4d8dcSEmmanuel Vadot                     <GIC_SPI 307 IRQ_TYPE_LEVEL_HIGH>,
932eb4d8dcSEmmanuel Vadot                     <GIC_SPI 308 IRQ_TYPE_LEVEL_HIGH>;
942eb4d8dcSEmmanuel Vadot        power-domains = <&pd IMX_SC_R_MJPEG_ENC_MP>,
952eb4d8dcSEmmanuel Vadot                        <&pd IMX_SC_R_MJPEG_ENC_S0>,
962eb4d8dcSEmmanuel Vadot                        <&pd IMX_SC_R_MJPEG_ENC_S1>,
972eb4d8dcSEmmanuel Vadot                        <&pd IMX_SC_R_MJPEG_ENC_S2>,
982eb4d8dcSEmmanuel Vadot                        <&pd IMX_SC_R_MJPEG_ENC_S3>;
992eb4d8dcSEmmanuel Vadot    };
1002eb4d8dcSEmmanuel Vadot...
101