128 lines · yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)2%YAML 1.23---4$id: http://devicetree.org/schemas/media/brcm,bcm2835-unicam.yaml#5$schema: http://devicetree.org/meta-schemas/core.yaml#6 7title: Broadcom BCM283x Camera Interface (Unicam)8 9maintainers:10 - Raspberry Pi Kernel Maintenance <kernel-list@raspberrypi.com>11 12description: |-13 The Unicam block on BCM283x SoCs is the receiver for either14 CSI-2 or CCP2 data from image sensors or similar devices.15 16 The main platform using this SoC is the Raspberry Pi family of boards. On17 the Pi the VideoCore firmware can also control this hardware block, and18 driving it from two different processors will cause issues. To avoid this,19 the firmware checks the device tree configuration during boot. If it finds20 device tree nodes whose name starts with 'csi' then it will stop the firmware21 accessing the block, and it can then safely be used via the device tree22 binding.23 24properties:25 compatible:26 const: brcm,bcm2835-unicam27 28 reg:29 items:30 - description: Unicam block.31 - description: Clock Manager Image (CMI) block.32 33 reg-names:34 items:35 - const: unicam36 - const: cmi37 38 interrupts:39 maxItems: 140 41 clocks:42 items:43 - description: Clock to drive the LP state machine of Unicam.44 - description: Clock for the VPU (core clock).45 46 clock-names:47 items:48 - const: lp49 - const: vpu50 51 power-domains:52 items:53 - description: Unicam power domain54 55 brcm,num-data-lanes:56 $ref: /schemas/types.yaml#/definitions/uint3257 enum: [ 2, 4 ]58 description: |59 Number of CSI-2 data lanes supported by this Unicam instance. The number60 of data lanes actively used is specified with the data-lanes endpoint61 property.62 63 port:64 $ref: /schemas/graph.yaml#/$defs/port-base65 unevaluatedProperties: false66 67 properties:68 endpoint:69 $ref: /schemas/media/video-interfaces.yaml#70 additionalProperties: false71 72 properties:73 bus-type:74 enum: [ 3, 4 ]75 76 clock-noncontinuous: true77 data-lanes: true78 remote-endpoint: true79 80 required:81 - bus-type82 - data-lanes83 - remote-endpoint84 85 required:86 - endpoint87 88required:89 - compatible90 - reg91 - reg-names92 - interrupts93 - clocks94 - clock-names95 - power-domains96 - brcm,num-data-lanes97 - port98 99additionalProperties: False100 101examples:102 - |103 #include <dt-bindings/clock/bcm2835.h>104 #include <dt-bindings/interrupt-controller/arm-gic.h>105 #include <dt-bindings/media/video-interfaces.h>106 #include <dt-bindings/power/raspberrypi-power.h>107 108 csi1: csi@7e801000 {109 compatible = "brcm,bcm2835-unicam";110 reg = <0x7e801000 0x800>,111 <0x7e802004 0x4>;112 reg-names = "unicam", "cmi";113 interrupts = <GIC_SPI 103 IRQ_TYPE_LEVEL_HIGH>;114 clocks = <&clocks BCM2835_CLOCK_CAM1>,115 <&firmware_clocks 4>;116 clock-names = "lp", "vpu";117 power-domains = <&power RPI_POWER_DOMAIN_UNICAM1>;118 brcm,num-data-lanes = <2>;119 port {120 csi1_ep: endpoint {121 remote-endpoint = <&imx219_0>;122 bus-type = <MEDIA_BUS_TYPE_CSI2_DPHY>;123 data-lanes = <1 2>;124 };125 };126 };127...128