xref: /freebsd-src/sys/contrib/device-tree/Bindings/media/microchip,xisc.yaml (revision 8bab661a3316d8bd9b9fbd11a3b4371b91507bd2)
15956d97fSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
25956d97fSEmmanuel Vadot# Copyright (C) 2021 Microchip Technology, Inc.
35956d97fSEmmanuel Vadot%YAML 1.2
45956d97fSEmmanuel Vadot---
55956d97fSEmmanuel Vadot$id: http://devicetree.org/schemas/media/microchip,xisc.yaml#
65956d97fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
75956d97fSEmmanuel Vadot
85956d97fSEmmanuel Vadottitle: Microchip eXtended Image Sensor Controller (XISC)
95956d97fSEmmanuel Vadot
105956d97fSEmmanuel Vadotmaintainers:
115956d97fSEmmanuel Vadot  - Eugen Hristev <eugen.hristev@microchip.com>
125956d97fSEmmanuel Vadot
135956d97fSEmmanuel Vadotdescription: |
145956d97fSEmmanuel Vadot  The eXtended Image Sensor Controller (XISC) device provides the video input capabilities for the
155956d97fSEmmanuel Vadot  Microchip AT91 SAM family of devices.
165956d97fSEmmanuel Vadot
175956d97fSEmmanuel Vadot  The XISC has a single internal parallel input that supports RAW Bayer, RGB or YUV video.
185956d97fSEmmanuel Vadot  The source can be either a demuxer from a CSI2 type of bus, or a simple direct bridge to a
195956d97fSEmmanuel Vadot  parallel sensor.
205956d97fSEmmanuel Vadot
215956d97fSEmmanuel Vadot  The XISC provides one clock output that is used to clock the demuxer/bridge.
225956d97fSEmmanuel Vadot
235956d97fSEmmanuel Vadotproperties:
245956d97fSEmmanuel Vadot  compatible:
255956d97fSEmmanuel Vadot    const: microchip,sama7g5-isc
265956d97fSEmmanuel Vadot
275956d97fSEmmanuel Vadot  reg:
285956d97fSEmmanuel Vadot    maxItems: 1
295956d97fSEmmanuel Vadot
305956d97fSEmmanuel Vadot  interrupts:
315956d97fSEmmanuel Vadot    maxItems: 1
325956d97fSEmmanuel Vadot
335956d97fSEmmanuel Vadot  clocks:
345956d97fSEmmanuel Vadot    maxItems: 1
355956d97fSEmmanuel Vadot
365956d97fSEmmanuel Vadot  clock-names:
375956d97fSEmmanuel Vadot    items:
385956d97fSEmmanuel Vadot      - const: hclock
395956d97fSEmmanuel Vadot
405956d97fSEmmanuel Vadot  '#clock-cells':
415956d97fSEmmanuel Vadot    const: 0
425956d97fSEmmanuel Vadot
435956d97fSEmmanuel Vadot  clock-output-names:
445956d97fSEmmanuel Vadot    const: isc-mck
455956d97fSEmmanuel Vadot
465956d97fSEmmanuel Vadot  microchip,mipi-mode:
475956d97fSEmmanuel Vadot    type: boolean
485956d97fSEmmanuel Vadot    description:
495956d97fSEmmanuel Vadot      As the XISC is usually connected to a demux/bridge, the XISC receives
505956d97fSEmmanuel Vadot      the same type of input, however, it should be aware of the type of
515956d97fSEmmanuel Vadot      signals received. The mipi-mode enables different internal handling
525956d97fSEmmanuel Vadot      of the data and clock lines.
535956d97fSEmmanuel Vadot
545956d97fSEmmanuel Vadot  port:
55354d7675SEmmanuel Vadot    $ref: /schemas/graph.yaml#/$defs/port-base
565956d97fSEmmanuel Vadot    description:
575956d97fSEmmanuel Vadot      Input port node, single endpoint describing the input pad.
585956d97fSEmmanuel Vadot
595956d97fSEmmanuel Vadot    properties:
605956d97fSEmmanuel Vadot      endpoint:
615956d97fSEmmanuel Vadot        $ref: video-interfaces.yaml#
625956d97fSEmmanuel Vadot
635956d97fSEmmanuel Vadot        properties:
645956d97fSEmmanuel Vadot          bus-type:
655956d97fSEmmanuel Vadot            enum: [5, 6]
665956d97fSEmmanuel Vadot
675956d97fSEmmanuel Vadot          remote-endpoint: true
685956d97fSEmmanuel Vadot
695956d97fSEmmanuel Vadot          bus-width:
70d5b0e70fSEmmanuel Vadot            enum: [8, 9, 10, 11, 12, 14]
715956d97fSEmmanuel Vadot            default: 12
725956d97fSEmmanuel Vadot
735956d97fSEmmanuel Vadot          hsync-active:
745956d97fSEmmanuel Vadot            enum: [0, 1]
755956d97fSEmmanuel Vadot            default: 1
765956d97fSEmmanuel Vadot
775956d97fSEmmanuel Vadot          vsync-active:
785956d97fSEmmanuel Vadot            enum: [0, 1]
795956d97fSEmmanuel Vadot            default: 1
805956d97fSEmmanuel Vadot
815956d97fSEmmanuel Vadot          pclk-sample:
825956d97fSEmmanuel Vadot            enum: [0, 1]
835956d97fSEmmanuel Vadot            default: 1
845956d97fSEmmanuel Vadot
855956d97fSEmmanuel Vadot        required:
865956d97fSEmmanuel Vadot          - remote-endpoint
875956d97fSEmmanuel Vadot          - bus-type
885956d97fSEmmanuel Vadot
895956d97fSEmmanuel Vadot        additionalProperties: false
905956d97fSEmmanuel Vadot
915956d97fSEmmanuel Vadot    additionalProperties: false
925956d97fSEmmanuel Vadot
935956d97fSEmmanuel Vadotrequired:
945956d97fSEmmanuel Vadot  - compatible
955956d97fSEmmanuel Vadot  - reg
965956d97fSEmmanuel Vadot  - clocks
975956d97fSEmmanuel Vadot  - clock-names
985956d97fSEmmanuel Vadot  - '#clock-cells'
995956d97fSEmmanuel Vadot  - clock-output-names
1005956d97fSEmmanuel Vadot  - port
1015956d97fSEmmanuel Vadot
1025956d97fSEmmanuel VadotadditionalProperties: false
1035956d97fSEmmanuel Vadot
1045956d97fSEmmanuel Vadotexamples:
1055956d97fSEmmanuel Vadot  - |
1065956d97fSEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
1075956d97fSEmmanuel Vadot    #include <dt-bindings/clock/at91.h>
1085956d97fSEmmanuel Vadot    #include <dt-bindings/interrupt-controller/irq.h>
109*8bab661aSEmmanuel Vadot    #include <dt-bindings/media/video-interfaces.h>
1105956d97fSEmmanuel Vadot
1115956d97fSEmmanuel Vadot    xisc: xisc@e1408000 {
1125956d97fSEmmanuel Vadot        compatible = "microchip,sama7g5-isc";
1135956d97fSEmmanuel Vadot        reg = <0xe1408000 0x2000>;
1145956d97fSEmmanuel Vadot        interrupts = <GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>;
1155956d97fSEmmanuel Vadot        clocks = <&pmc PMC_TYPE_PERIPHERAL 56>;
1165956d97fSEmmanuel Vadot        clock-names = "hclock";
1175956d97fSEmmanuel Vadot        #clock-cells = <0>;
1185956d97fSEmmanuel Vadot        clock-output-names = "isc-mck";
1195956d97fSEmmanuel Vadot
1205956d97fSEmmanuel Vadot        port {
1215956d97fSEmmanuel Vadot                xisc_in: endpoint {
122*8bab661aSEmmanuel Vadot                       bus-type = <MEDIA_BUS_TYPE_PARALLEL>;
1235956d97fSEmmanuel Vadot                       remote-endpoint = <&csi2dc_out>;
1245956d97fSEmmanuel Vadot                       hsync-active = <1>;
1255956d97fSEmmanuel Vadot                       vsync-active = <1>;
1265956d97fSEmmanuel Vadot                       bus-width = <12>;
1275956d97fSEmmanuel Vadot                };
1285956d97fSEmmanuel Vadot        };
1295956d97fSEmmanuel Vadot    };
130