Merge tag 'iio-for-6.2a-take2' of https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into char-misc-next

Jonathan writes:

1st set of IIO new device support, feature and cleanup for 6.2 (take2)

We have finally managed to take the mlock mutex entirely private so as
to avoid it being used for multiple purposes.  Now it is just used to
protect device mode transitions (typically to and from buffered capture).

Includes merge of an immutable i2c branch to get the new
i2c_client_get_device_id() (thanks to Wolfram for providing the branch).

Based on rc3 to pick up some precursor fixes from early in the cycle and
avoid an unnecessarily messy history.

New device support
* adi,ad4310
  - New driver to support this very flexible measurement device including
    a 24 bit ADC. Later fix for documentation build issue.
* adi,adxl355
  - Add support of the ADXL359 accelerometer.
* adi,ltc2983
  - Support additional variants of the temperatures sensor:
    LTC2984 with an EEPROM
    LTC2985, LTC2986 with only 10 channels.
* invensense,icm42600
  - Add support for icm42631 (needed only ID and WHOAMI)
* kionix,kx022a
  - New driver for this 3 axis accelerometer.
* maxim,max11401
  - New driver to support this 24-bit 10 channel ADC.
    Includes some new ABI to support configuration of notch filters.
* mediatek,mt6370
  - Add new driver to support the ADC part of the mt6370.
* st,lsm6dsx
  - Add support for LSM6DSV accelerometer and gyroscope. Simple additional
    of chip specific data and IDs.
  - Add support for LSM6DSV16X accelerometer and gyroscope.  Compatible with
    features currently implemented for the LSM6DSV.
* st,stm32-adc
  - Add support for stm32pm13x SoCs.

core / subsystem wide:
 - Add new IIO_STATIC_CONST_DEVICE_ATTR() which is a dance necessary to
   allow for the wrapping of attributes in the code that duplicates them
   for multiple buffers.
 - Harden against future issues with expectation that all buffer attributes
   are iio_dev_attrs by changing the code to take an array of pointers
   of the correct type.
 - Last transitions of drivers to local locks rather than missuses of mlock.
 - Add an iio_device_claim_buffer_mode() callback to avoid a race in the
   max30100 driver without directly using mlock.
 - Move mlock to the opaque IIO device structure to prevent misuse.
 - Add missing spi_device_id tables to support auto loading of modules.
 - Update some ADI maintainers in DT bindings.
 - A few more moves of bus drivers and core module sets to export
   name spaces.
 - Extensive use of new devm_regulator_get_enable() and friends.
 - Switch a bunch of i2c drivers to probe_new() including the bmp280
   which makes use of the new i2c_client_get_device_id() helper to
   simplify this change.

dt-bindings:
 - More use of spi-peripheral-props.yaml.

Features
* freescale,mpl115
  - Use runtime PM to implement shutdown GPIO support.
* melexis,mlx90632
  - More sophisticated runtime power management
  - Provide access to sampling frequency.
  - Trivial follow up fixes.
* microchip,mcp3911
  - Support control of PGA.
* st,lsm6dsx
  - Add support for software triggers for cases where the IRQ lines
    are not wired up.
* vishay,vcnl4000
  - Add control of integration time.

Minor cleanups and fixes
* adi,ad4130
  - Improve ABI documentation formatting.
  - Kconfig dependency fixup.
* adi,ad5758
  - Minor dt binding fix.
* adi,ad9834
  - Tidy up line breaks.
* adi,ade7854
  - Minor improvement in code clarity by replacing a ternary.
* adi,admv8818
  - Harden code against hardware returning wrong values.
* adi,adxl355
  - Warn only if unknown device ID detected to allow for fall back
    device tree compatibles on future devices.
* adi,ltc2983
  - dt-bindings clarifications and general improvements.
  - Ensure DMA safe buffer for bulk writes without relying on current
    regmap implementation choices.
* avago,adps9960
  - Fix up a disconnect between event enable attributes and what was
    enabled.
* bosch,bma400
  - Switch to dev_err_probe() from open coded EPROBE_DEFER handling.
* cosmic,cc10001
  - Fully devm managed probe() and related tidying up.
* meas,ms5611
  - Add an example of spi-max-frequency.
* meleixs,mlx90632
  - Tidy up confusing error return value.
  - Style improvements.
* multiplexer
  - Switch to dev_err_probe() from open coded EPROBE_DEFER handling.
* qcom,spmi-vadc
  - Minor dt binding improvements.
* rockchip,saradc
  - Add ID for rv1126.
* semtech,sx9360
  - Add SAMM0208 ACPI ID. Doesn't appear to be a valid vendor prefix
    but is in the wild.
* st,lsm6dsx
  - Factor out common code as _device_set_enable().
  - Fix up wrong docs after LSM6DSV addition.
* st,stm32-adc
  - Manage the min sampling time on all internal channels.
* trig,sysfs
  - Improve error labels.

* tag 'iio-for-6.2a-take2' of https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio: (146 commits)
  iio: pressure: bmp280: convert to i2c's .probe_new()
  iio: imu: st_lsm6dsx: fix LSM6DSV sensor description
  iio: adc: ad4130: depend on GPIOLIB
  staging: iio: meter: replace ternary operator by if condition
  iio: light: apds9960: Fix iio_event_spec structures
  dt-bindings: iio: imu: Add inv_icm42600 documentation
  iio: imu: inv_icm42600: Add support for icm42631
  dt-bindings: iio: adc: rockchip-saradc: Add saradc for rv1126
  dt-bindings: iio: dac: adi,ad5758: Drop 'contains' from 'adi,dc-dc-mode'
  dt-bindings: iio: imu: st_lsm6dsx: add lsm6dsv16x
  iio: imu: st_lsm6dsx: add support to LSM6DSV16X
  iio: proximity: sx9360: Add a new ACPI hardware ID
  iio: temperature: mlx90632: Add missing static marking on devm_pm_ops
  iio: temperature: mlx90632: Add error handling for devm_pm_runtime_enable()
  iio: temperature: ltc2983: support more parts
  dt-bindings: iio: temperature: ltc2983: support more parts
  dt-bindings: iio: temperature: ltc2983: use generic node name in example
  dt-bindings: iio: temperature: ltc2983: describe broken mux delay property
  dt-bindings: iio: temperature: ltc2983: refine descriptions
  dt-bindings: iio: temperature: ltc2983: change default excitation for custom thermistors
  ...
This commit is contained in:
Greg Kroah-Hartman
2022-11-25 18:35:16 +01:00
162 changed files with 8081 additions and 1305 deletions

View File

@@ -0,0 +1,46 @@
What: /sys/bus/iio/devices/iio:deviceX/in_voltage-voltage_filter_mode_available
KernelVersion: 6.2
Contact: linux-iio@vger.kernel.org
Description:
Reading returns a list with the possible filter modes.
* "sinc4" - Sinc 4. Excellent noise performance. Long
1st conversion time. No natural 50/60Hz rejection.
* "sinc4+sinc1" - Sinc4 + averaging by 8. Low 1st conversion
time.
* "sinc3" - Sinc3. Moderate 1st conversion time.
Good noise performance.
* "sinc3+rej60" - Sinc3 + 60Hz rejection. At a sampling
frequency of 50Hz, achieves simultaneous 50Hz and 60Hz
rejection.
* "sinc3+sinc1" - Sinc3 + averaging by 8. Low 1st conversion
time. Best used with a sampling frequency of at least
216.19Hz.
* "sinc3+pf1" - Sinc3 + Post Filter 1. 53dB rejection @
50Hz, 58dB rejection @ 60Hz.
* "sinc3+pf2" - Sinc3 + Post Filter 2. 70dB rejection @
50Hz, 70dB rejection @ 60Hz.
* "sinc3+pf3" - Sinc3 + Post Filter 3. 99dB rejection @
50Hz, 103dB rejection @ 60Hz.
* "sinc3+pf4" - Sinc3 + Post Filter 4. 103dB rejection @
50Hz, 109dB rejection @ 60Hz.
What: /sys/bus/iio/devices/iio:deviceX/in_voltageY-voltageZ_filter_mode
KernelVersion: 6.2
Contact: linux-iio@vger.kernel.org
Description:
Set the filter mode of the differential channel. When the filter
mode changes, the in_voltageY-voltageZ_sampling_frequency and
in_voltageY-voltageZ_sampling_frequency_available attributes
might also change to accommodate the new filter mode.
If the current sampling frequency is out of range for the new
filter mode, the sampling frequency will be changed to the
closest valid one.

View File

@@ -0,0 +1,13 @@
What: /sys/bus/iio/devices/iio:deviceX/in_voltage_filterY_notch_en
Date: September 2022
KernelVersion: 6.0
Contact: linux-iio@vger.kernel.org
Description:
Enable or disable a notch filter.
What: /sys/bus/iio/devices/iio:deviceX/in_voltage_filterY_notch_center
Date: September 2022
KernelVersion: 6.0
Contact: linux-iio@vger.kernel.org
Description:
Center frequency of the notch filter in Hz.

View File

@@ -4,20 +4,22 @@
$id: http://devicetree.org/schemas/iio/accel/adi,adxl355.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Analog Devices ADXL355 3-Axis, Low noise MEMS Accelerometer
title: Analog Devices ADXL355 and ADXL359 3-Axis, Low noise MEMS Accelerometers
maintainers:
- Puranjay Mohan <puranjay12@gmail.com>
description: |
Analog Devices ADXL355 3-Axis, Low noise MEMS Accelerometer that supports
both I2C & SPI interfaces
Analog Devices ADXL355 and ADXL359 3-Axis, Low noise MEMS Accelerometers that
support both I2C & SPI interfaces
https://www.analog.com/en/products/adxl355.html
https://www.analog.com/en/products/adxl359.html
properties:
compatible:
enum:
- adi,adxl355
- adi,adxl359
reg:
maxItems: 1

View File

@@ -0,0 +1,65 @@
# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
%YAML 1.2
---
$id: http://devicetree.org/schemas/iio/accel/kionix,kx022a.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: ROHM/Kionix KX022A Accelerometer
maintainers:
- Matti Vaittinen <mazziesaccount@gmail.com>
description: |
KX022A is a 3-axis accelerometer supporting +/- 2G, 4G, 8G and 16G ranges,
output data-rates from 0.78Hz to 1600Hz and a hardware-fifo buffering.
KX022A can be accessed either via I2C or SPI.
properties:
compatible:
const: kionix,kx022a
reg:
maxItems: 1
interrupts:
minItems: 1
maxItems: 2
interrupt-names:
minItems: 1
items:
- enum: [INT1, INT2]
- const: INT2
vdd-supply: true
io-vdd-supply: true
mount-matrix:
description: |
an optional 3x3 mounting rotation matrix.
required:
- compatible
- reg
- interrupts
additionalProperties: false
examples:
- |
#include <dt-bindings/interrupt-controller/irq.h>
i2c {
#address-cells = <1>;
#size-cells = <0>;
accel@1f {
compatible = "kionix,kx022a";
reg = <0x1f>;
interrupt-parent = <&gpio1>;
interrupts = <29 IRQ_TYPE_LEVEL_LOW>;
interrupt-names = "INT1";
io-vdd-supply = <&iovdd>;
vdd-supply = <&vdd>;
};
};

View File

@@ -0,0 +1,259 @@
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
# Copyright 2022 Analog Devices Inc.
%YAML 1.2
---
$id: http://devicetree.org/schemas/iio/adc/adi,ad4130.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Analog Devices AD4130 ADC device driver
maintainers:
- Cosmin Tanislav <cosmin.tanislav@analog.com>
description: |
Bindings for the Analog Devices AD4130 ADC. Datasheet can be found here:
https://www.analog.com/media/en/technical-documentation/data-sheets/AD4130-8.pdf
properties:
compatible:
enum:
- adi,ad4130
reg:
maxItems: 1
clocks:
maxItems: 1
description: phandle to the master clock (mclk)
clock-names:
items:
- const: mclk
interrupts:
maxItems: 1
interrupt-names:
description: |
Specify which interrupt pin should be configured as Data Ready / FIFO
interrupt.
Default if not supplied is int.
enum:
- int
- clk
- p2
- dout
'#address-cells':
const: 1
'#size-cells':
const: 0
'#clock-cells':
const: 0
clock-output-names:
maxItems: 1
refin1-supply:
description: refin1 supply. Can be used as reference for conversion.
refin2-supply:
description: refin2 supply. Can be used as reference for conversion.
avdd-supply:
description: AVDD voltage supply. Can be used as reference for conversion.
iovdd-supply:
description: IOVDD voltage supply. Used for the chip interface.
spi-max-frequency:
maximum: 5000000
adi,ext-clk-freq-hz:
description: Specify the frequency of the external clock.
enum: [76800, 153600]
default: 76800
adi,bipolar:
description: Specify if the device should be used in bipolar mode.
type: boolean
adi,vbias-pins:
description: Analog inputs to apply a voltage bias of (AVDD AVSS) / 2 to.
$ref: /schemas/types.yaml#/definitions/uint32-array
minItems: 1
maxItems: 16
items:
minimum: 0
maximum: 15
required:
- compatible
- reg
- interrupts
patternProperties:
"^channel@([0-9a-f])$":
type: object
$ref: adc.yaml
unevaluatedProperties: false
properties:
reg:
description: The channel number.
minimum: 0
maximum: 15
diff-channels:
description: |
Besides the analog inputs available, internal inputs can be used.
16: Internal temperature sensor.
17: AVSS
18: Internal reference
19: DGND
20: (AVDD AVSS)/6+
21: (AVDD AVSS)/6-
22: (IOVDD DGND)/6+
23: (IOVDD DGND)/6-
24: (ALDO AVSS)/6+
25: (ALDO AVSS)/6-
26: (DLDO DGND)/6+
27: (DLDO DGND)/6-
28: V_MV_P
29: V_MV_M
items:
minimum: 0
maximum: 29
adi,reference-select:
description: |
Select the reference source to use when converting on the
specific channel. Valid values are:
0: REFIN1(+)/REFIN1()
1: REFIN2(+)/REFIN2()
2: REFOUT/AVSS (Internal reference)
3: AVDD/AVSS
If not specified, REFIN1 is used.
$ref: /schemas/types.yaml#/definitions/uint32
enum: [0, 1, 2, 3]
default: 0
adi,excitation-pin-0:
description: |
Analog input to apply excitation current to while the channel
is active.
$ref: /schemas/types.yaml#/definitions/uint32
minimum: 0
maximum: 15
default: 0
adi,excitation-pin-1:
description: |
Analog input to apply excitation current to while this channel
is active.
$ref: /schemas/types.yaml#/definitions/uint32
minimum: 0
maximum: 15
default: 0
adi,excitation-current-0-nanoamp:
description: |
Excitation current in nanoamps to be applied to pin specified in
adi,excitation-pin-0 while this channel is active.
enum: [0, 100, 10000, 20000, 50000, 100000, 150000, 200000]
default: 0
adi,excitation-current-1-nanoamp:
description: |
Excitation current in nanoamps to be applied to pin specified in
adi,excitation-pin-1 while this channel is active.
enum: [0, 100, 10000, 20000, 50000, 100000, 150000, 200000]
default: 0
adi,burnout-current-nanoamp:
description: |
Burnout current in nanoamps to be applied for this channel.
enum: [0, 500, 2000, 4000]
default: 0
adi,buffered-positive:
description: Enable buffered mode for positive input.
type: boolean
adi,buffered-negative:
description: Enable buffered mode for negative input.
type: boolean
required:
- reg
- diff-channels
additionalProperties: false
examples:
- |
#include <dt-bindings/interrupt-controller/irq.h>
spi {
#address-cells = <1>;
#size-cells = <0>;
adc@0 {
compatible = "adi,ad4130";
reg = <0>;
#address-cells = <1>;
#size-cells = <0>;
spi-max-frequency = <5000000>;
interrupts = <27 IRQ_TYPE_EDGE_FALLING>;
interrupt-parent = <&gpio>;
channel@0 {
reg = <0>;
adi,reference-select = <2>;
/* AIN8, AIN9 */
diff-channels = <8 9>;
};
channel@1 {
reg = <1>;
adi,reference-select = <2>;
/* AIN10, AIN11 */
diff-channels = <10 11>;
};
channel@2 {
reg = <2>;
adi,reference-select = <2>;
/* Temperature Sensor, DGND */
diff-channels = <16 19>;
};
channel@3 {
reg = <3>;
adi,reference-select = <2>;
/* Internal reference, DGND */
diff-channels = <18 19>;
};
channel@4 {
reg = <4>;
adi,reference-select = <2>;
/* DGND, DGND */
diff-channels = <19 19>;
};
};
};

View File

@@ -0,0 +1,177 @@
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
# Copyright 2022 Analog Devices Inc.
%YAML 1.2
---
$id: http://devicetree.org/schemas/iio/adc/adi,max11410.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Analog Devices MAX11410 ADC device driver
maintainers:
- Ibrahim Tilki <Ibrahim.Tilki@analog.com>
description: |
Bindings for the Analog Devices MAX11410 ADC device. Datasheet can be
found here:
https://datasheets.maximintegrated.com/en/ds/MAX11410.pdf
properties:
compatible:
enum:
- adi,max11410
reg:
maxItems: 1
interrupts:
minItems: 1
maxItems: 2
interrupt-names:
description: Name of the gpio pin of max11410 used for IRQ
minItems: 1
items:
- enum: [gpio0, gpio1]
- const: gpio1
'#address-cells':
const: 1
'#size-cells':
const: 0
avdd-supply:
description: Optional avdd supply. Used as reference when no explicit reference supplied.
vref0p-supply:
description: vref0p supply can be used as reference for conversion.
vref1p-supply:
description: vref1p supply can be used as reference for conversion.
vref2p-supply:
description: vref2p supply can be used as reference for conversion.
vref0n-supply:
description: vref0n supply can be used as reference for conversion.
vref1n-supply:
description: vref1n supply can be used as reference for conversion.
vref2n-supply:
description: vref2n supply can be used as reference for conversion.
spi-max-frequency:
maximum: 8000000
patternProperties:
"^channel(@[0-9])?$":
$ref: adc.yaml
type: object
description: Represents the external channels which are connected to the ADC.
properties:
reg:
description: The channel number in single-ended mode.
minimum: 0
maximum: 9
adi,reference:
description: |
Select the reference source to use when converting on
the specific channel. Valid values are:
0: VREF0P/VREF0N
1: VREF1P/VREF1N
2: VREF2P/VREF2N
3: AVDD/AGND
4: VREF0P/AGND
5: VREF1P/AGND
6: VREF2P/AGND
If this field is left empty, AVDD/AGND is selected.
$ref: /schemas/types.yaml#/definitions/uint32
enum: [0, 1, 2, 3, 4, 5, 6]
default: 3
adi,input-mode:
description: |
Select signal path of input channels. Valid values are:
0: Buffered, low-power, unity-gain path (default)
1: Bypass path
2: PGA path
$ref: /schemas/types.yaml#/definitions/uint32
enum: [0, 1, 2]
default: 0
diff-channels: true
bipolar: true
settling-time-us: true
adi,buffered-vrefp:
description: Enable buffered mode for positive reference.
type: boolean
adi,buffered-vrefn:
description: Enable buffered mode for negative reference.
type: boolean
required:
- reg
additionalProperties: false
required:
- compatible
- reg
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |
#include <dt-bindings/interrupt-controller/irq.h>
spi {
#address-cells = <1>;
#size-cells = <0>;
adc@0 {
reg = <0>;
compatible = "adi,max11410";
spi-max-frequency = <8000000>;
interrupt-parent = <&gpio>;
interrupts = <25 IRQ_TYPE_EDGE_FALLING>;
interrupt-names = "gpio1";
avdd-supply = <&adc_avdd>;
vref1p-supply = <&adc_vref1p>;
vref1n-supply = <&adc_vref1n>;
#address-cells = <1>;
#size-cells = <0>;
channel@0 {
reg = <0>;
};
channel@1 {
reg = <1>;
diff-channels = <2 3>;
adi,reference = <1>;
bipolar;
settling-time-us = <100000>;
};
channel@2 {
reg = <2>;
diff-channels = <7 9>;
adi,reference = <5>;
adi,input-mode = <2>;
settling-time-us = <50000>;
};
};
};

View File

@@ -22,13 +22,11 @@ properties:
- items:
- const: qcom,pms405-adc
- const: qcom,spmi-adc-rev2
- items:
- enum:
- qcom,spmi-vadc
- qcom,spmi-adc5
- qcom,spmi-adc-rev2
- qcom,spmi-adc7
- enum:
- qcom,spmi-vadc
- qcom,spmi-adc5
- qcom,spmi-adc-rev2
- qcom,spmi-adc7
reg:
description: VADC base address in the SPMI PMIC register map
@@ -238,42 +236,72 @@ additionalProperties: false
examples:
- |
spmi_bus {
#address-cells = <1>;
#size-cells = <0>;
/* VADC node */
pmic_vadc: adc@3100 {
compatible = "qcom,spmi-vadc";
reg = <0x3100>;
interrupts = <0x0 0x31 0x0 0x1>;
spmi {
#address-cells = <1>;
#size-cells = <0>;
#io-channel-cells = <1>;
/* VADC node */
pmic_vadc: adc@3100 {
compatible = "qcom,spmi-vadc";
reg = <0x3100>;
interrupts = <0x0 0x31 0x0 0x1>;
#address-cells = <1>;
#size-cells = <0>;
#io-channel-cells = <1>;
/* Channel node */
adc-chan@39 {
reg = <0x39>;
qcom,decimation = <512>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,avg-samples = <1>;
qcom,pre-scaling = <1 3>;
};
/* Channel node */
adc-chan@39 {
reg = <0x39>;
qcom,decimation = <512>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
qcom,avg-samples = <1>;
qcom,pre-scaling = <1 3>;
};
adc-chan@9 {
reg = <0x9>;
};
adc-chan@9 {
reg = <0x9>;
};
adc-chan@a {
reg = <0xa>;
};
adc-chan@a {
reg = <0xa>;
};
adc-chan@e {
reg = <0xe>;
};
adc-chan@e {
reg = <0xe>;
};
adc-chan@f {
reg = <0xf>;
adc-chan@f {
reg = <0xf>;
};
};
};
- |
#include <dt-bindings/iio/qcom,spmi-adc7-pmk8350.h>
#include <dt-bindings/iio/qcom,spmi-adc7-pm8350.h>
#include <dt-bindings/interrupt-controller/irq.h>
spmi {
#address-cells = <1>;
#size-cells = <0>;
adc@3100 {
reg = <0x3100>;
compatible = "qcom,spmi-adc7";
#address-cells = <1>;
#size-cells = <0>;
#io-channel-cells = <1>;
/* Other properties are omitted */
xo-therm@44 {
reg = <PMK8350_ADC7_AMUX_THM1_100K_PU>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
conn-therm@47 {
reg = <PM8350_ADC7_AMUX_THM4_100K_PU>;
qcom,ratiometric;
qcom,hw-settle-time = <200>;
};
};
};
};

View File

@@ -22,6 +22,7 @@ properties:
- rockchip,rk3328-saradc
- rockchip,rk3568-saradc
- rockchip,rv1108-saradc
- rockchip,rv1126-saradc
- const: rockchip,rk3399-saradc
reg:

View File

@@ -27,6 +27,7 @@ properties:
- st,stm32f4-adc-core
- st,stm32h7-adc-core
- st,stm32mp1-adc-core
- st,stm32mp13-adc-core
reg:
maxItems: 1
@@ -37,6 +38,7 @@ properties:
- stm32f4 and stm32h7 share a common ADC interrupt line.
- stm32mp1 has two separate interrupt lines, one for each ADC within
ADC block.
- stm32mp13 has an interrupt line per ADC block.
minItems: 1
maxItems: 2
@@ -180,6 +182,33 @@ allOf:
maximum: 36000000
default: 36000000
- if:
properties:
compatible:
contains:
const: st,stm32mp13-adc-core
then:
properties:
clocks:
minItems: 1
maxItems: 2
clock-names:
items:
- const: bus
- const: adc
minItems: 1
interrupts:
items:
- description: ADC interrupt line
st,max-clk-rate-hz:
minimum: 150000
maximum: 75000000
default: 75000000
additionalProperties: false
required:
@@ -208,6 +237,7 @@ patternProperties:
- st,stm32f4-adc
- st,stm32h7-adc
- st,stm32mp1-adc
- st,stm32mp13-adc
reg:
description: |
@@ -229,7 +259,7 @@ patternProperties:
interrupts:
description: |
IRQ Line for the ADC instance. Valid values are:
- 0 for adc@0
- 0 for adc@0 (single adc for stm32mp13)
- 1 for adc@100
- 2 for adc@200 (stm32f4 only)
maxItems: 1
@@ -250,13 +280,14 @@ patternProperties:
assigned-resolution-bits:
description: |
Resolution (bits) to use for conversions:
- can be 6, 8, 10 or 12 on stm32f4
- can be 6, 8, 10 or 12 on stm32f4 and stm32mp13
- can be 8, 10, 12, 14 or 16 on stm32h7 and stm32mp1
st,adc-channels:
description: |
List of single-ended channels muxed for this ADC. It can have up to:
- 16 channels, numbered from 0 to 15 (for in0..in15) on stm32f4
- 19 channels, numbered from 0 to 18 (for in0..in18) on stm32mp13.
- 20 channels, numbered from 0 to 19 (for in0..in19) on stm32h7 and
stm32mp1.
$ref: /schemas/types.yaml#/definitions/uint32-array
@@ -322,7 +353,7 @@ patternProperties:
label:
description: |
Unique name to identify which channel this is.
Reserved label names "vddcore", "vrefint" and "vbat"
Reserved label names "vddcore", "vddcpu", "vddq_ddr", "vrefint" and "vbat"
are used to identify internal channels with matching names.
diff-channels:
@@ -419,6 +450,37 @@ patternProperties:
items:
minimum: 40
- if:
properties:
compatible:
contains:
const: st,stm32mp13-adc
then:
properties:
reg:
const: 0x0
interrupts:
const: 0
assigned-resolution-bits:
enum: [6, 8, 10, 12]
default: 12
st,adc-channels:
minItems: 1
maxItems: 19
items:
minimum: 0
maximum: 18
st,min-sample-time-nsecs:
minItems: 1
maxItems: 19
items:
minimum: 40
additionalProperties: false
required:

View File

@@ -58,8 +58,6 @@ required:
- spi-cpol
- refin-supply
additionalProperties: false
patternProperties:
"^channel@[0-3]$":
type: object
@@ -103,6 +101,11 @@ patternProperties:
required:
- reg
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |
#include <dt-bindings/gpio/gpio.h>
@@ -113,10 +116,7 @@ examples:
#address-cells = <1>;
#size-cells = <0>;
cs-gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
status = "okay";
ad74413r@0 {
addac@0 {
compatible = "adi,ad74413r";
reg = <0>;
spi-max-frequency = <1000000>;

View File

@@ -102,8 +102,7 @@ allOf:
- if:
properties:
adi,dc-dc-mode:
contains:
enum: [1, 3]
enum: [1, 3]
then:
properties:
adi,range-microvolt: false

View File

@@ -8,7 +8,7 @@ $schema: http://devicetree.org/meta-schemas/core.yaml#
title: Analog Devices AD5766 DAC device driver
maintainers:
- Cristian Pop <cristian.pop@analog.com>
- Nuno Sá <nuno.sa@analog.com>
description: |
Bindings for the Analog Devices AD5766 current DAC device. Datasheet can be

View File

@@ -160,13 +160,16 @@ properties:
2: +2dBm
3: +5dBm
additionalProperties: false
required:
- compatible
- reg
- clocks
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |
spi {

View File

@@ -70,7 +70,10 @@ required:
- clock-names
- vcm-supply
additionalProperties: false
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |

View File

@@ -104,7 +104,10 @@ required:
- clock-names
- vcm-supply
additionalProperties: false
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |

View File

@@ -7,7 +7,7 @@ $schema: http://devicetree.org/meta-schemas/core.yaml#
title: ADMV4420 K Band Downconverter
maintainers:
- Cristian Pop <cristian.pop@analog.com>
- Nuno Sá <nuno.sa@analog.com>
description:
The ADMV4420 is a highly integrated, double balanced, active
@@ -37,7 +37,11 @@ required:
- compatible
- reg
additionalProperties: false
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |

View File

@@ -113,7 +113,10 @@ required:
- clocks
- clock-names
additionalProperties: false
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |

View File

@@ -38,7 +38,10 @@ required:
- spi-cpol
- spi-cpha
additionalProperties: false
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |

View File

@@ -56,7 +56,10 @@ required:
- compatible
- reg
additionalProperties: false
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
unevaluatedProperties: false
examples:
- |

View File

@@ -79,6 +79,7 @@ required:
- spi-cpol
allOf:
- $ref: /schemas/spi/spi-peripheral-props.yaml#
- if:
properties:
compatible:
@@ -107,7 +108,7 @@ allOf:
dependencies:
adi,sync-mode: [ clocks ]
additionalProperties: false
unevaluatedProperties: false
examples:
- |

Some files were not shown because too many files have changed in this diff Show More