Path: blob/main/sys/contrib/device-tree/Bindings/iio/adc/amlogic,meson-saradc.yaml
48406 views
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)1%YAML 1.22---3$id: http://devicetree.org/schemas/iio/adc/amlogic,meson-saradc.yaml#4$schema: http://devicetree.org/meta-schemas/core.yaml#56title: Amlogic Meson SAR (Successive Approximation Register) A/D converter78maintainers:9- Martin Blumenstingl <martin.blumenstingl@googlemail.com>1011description:12Binding covers a range of ADCs found on Amlogic Meson SoCs.1314properties:15compatible:16oneOf:17- const: amlogic,meson-saradc18- items:19- enum:20- amlogic,meson8-saradc21- amlogic,meson8b-saradc22- amlogic,meson8m2-saradc23- amlogic,meson-gxbb-saradc24- amlogic,meson-gxl-saradc25- amlogic,meson-gxm-saradc26- amlogic,meson-axg-saradc27- amlogic,meson-g12a-saradc28- const: amlogic,meson-saradc2930reg:31maxItems: 13233interrupts:34description: Interrupt indicates end of sampling.35maxItems: 13637clocks:38minItems: 239maxItems: 44041clock-names:42minItems: 243items:44- const: clkin45- const: core46- const: adc_clk47- const: adc_sel4849vref-supply: true5051"#io-channel-cells":52const: 15354amlogic,hhi-sysctrl:55$ref: /schemas/types.yaml#/definitions/phandle56description:57Syscon which contains the 5th bit of the TSC (temperature sensor58coefficient) on Meson8b and Meson8m2 (which used to calibrate the59temperature sensor)6061nvmem-cells:62description: phandle to the temperature_calib eFuse cells63maxItems: 16465nvmem-cell-names:66const: temperature_calib6768power-domains:69maxItems: 17071allOf:72- if:73properties:74compatible:75contains:76enum:77- amlogic,meson8-saradc78- amlogic,meson8b-saradc79- amlogic,meson8m2-saradc80then:81properties:82clocks:83maxItems: 284clock-names:85maxItems: 286else:87properties:88nvmem-cells: false89mvmem-cel-names: false90clocks:91minItems: 492clock-names:93minItems: 49495- if:96properties:97compatible:98contains:99enum:100- amlogic,meson8b-saradc101- amlogic,meson8m2-saradc102then:103properties:104amlogic,hhi-sysctrl: true105else:106properties:107amlogic,hhi-sysctrl: false108109required:110- compatible111- reg112- interrupts113- clocks114- clock-names115- "#io-channel-cells"116117additionalProperties: false118119examples:120- |121#include <dt-bindings/interrupt-controller/irq.h>122#include <dt-bindings/clock/gxbb-clkc.h>123#include <dt-bindings/interrupt-controller/arm-gic.h>124soc {125#address-cells = <2>;126#size-cells = <2>;127adc@8680 {128compatible = "amlogic,meson-gxl-saradc", "amlogic,meson-saradc";129#io-channel-cells = <1>;130reg = <0x0 0x8680 0x0 0x34>;131interrupts = <GIC_SPI 73 IRQ_TYPE_EDGE_RISING>;132clocks = <&xtal>,133<&clkc CLKID_SAR_ADC>,134<&clkc CLKID_SAR_ADC_CLK>,135<&clkc CLKID_SAR_ADC_SEL>;136clock-names = "clkin", "core", "adc_clk", "adc_sel";137};138adc@9680 {139compatible = "amlogic,meson8b-saradc", "amlogic,meson-saradc";140#io-channel-cells = <1>;141reg = <0x0 0x9680 0x0 0x34>;142interrupts = <GIC_SPI 73 IRQ_TYPE_EDGE_RISING>;143clocks = <&xtal>, <&clkc CLKID_SAR_ADC>;144clock-names = "clkin", "core";145nvmem-cells = <&tsens_caldata>;146nvmem-cell-names = "temperature_calib";147amlogic,hhi-sysctrl = <&hhi>;148};149};150...151152153