Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

dt-bindings:iio:health:ti,afe4403: txt to yaml binding

A few questions came up whilst converting this one.
1) What is actually required?
- Checking Linux driver, interrupt is not, and the tx-supply could
be supplied by a stub regulator as long as it's always on.
As such I have reduced the required list to just compatible and reg.
2) What is the regulator called?
- It's tx-supply in the binding doc, but the driver requests tx_sup.
I'll post a fix patch to change the driver to fix this as it makes
little sense.

Andrew's email is bouncing so until someone else steps up I have
listed myself as maintainer for this binding.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20201031184854.745828-8-jic23@kernel.org

+54 -33
-33
Documentation/devicetree/bindings/iio/health/afe4403.txt
··· 1 - Texas Instruments AFE4403 Heart rate and Pulse Oximeter 2 - 3 - Required properties: 4 - - compatible : Should be "ti,afe4403". 5 - - reg : SPI chip select address of device. 6 - - tx-supply : Regulator supply to transmitting LEDs. 7 - - interrupts : The interrupt line the device ADC_RDY pin is 8 - connected to. For details refer to, 9 - ../../interrupt-controller/interrupts.txt. 10 - 11 - Optional properties: 12 - - reset-gpios : GPIO used to reset the device. 13 - For details refer to, ../../gpio/gpio.txt. 14 - 15 - For other required and optional properties of SPI slave nodes 16 - please refer to ../../spi/spi-bus.txt. 17 - 18 - Example: 19 - 20 - &spi0 { 21 - heart_mon@0 { 22 - compatible = "ti,afe4403"; 23 - reg = <0>; 24 - spi-max-frequency = <10000000>; 25 - 26 - tx-supply = <&vbat>; 27 - 28 - interrupt-parent = <&gpio1>; 29 - interrupts = <28 IRQ_TYPE_EDGE_RISING>; 30 - 31 - reset-gpios = <&gpio1 16 GPIO_ACTIVE_LOW>; 32 - }; 33 - };
+54
Documentation/devicetree/bindings/iio/health/ti,afe4403.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/iio/health/ti,afe4403.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: Texas Instruments AFE4403 Heart rate and Pulse Oximeter 8 + 9 + maintainers: 10 + - Jonathan Cameron <jic23@kernel.org> 11 + 12 + properties: 13 + compatible: 14 + const: ti,afe4403 15 + 16 + reg: 17 + maxItems: 1 18 + 19 + tx-supply: 20 + description: Supply to transmitting LEDs. 21 + 22 + interrupts: 23 + maxItems: 1 24 + description: Connected to ADC_RDY pin. 25 + 26 + reset-gpios: true 27 + 28 + spi-max-frequency: true 29 + 30 + additionalProperties: false 31 + 32 + required: 33 + - compatible 34 + - reg 35 + 36 + examples: 37 + - | 38 + #include <dt-bindings/gpio/gpio.h> 39 + #include <dt-bindings/interrupt-controller/irq.h> 40 + spi { 41 + #address-cells = <1>; 42 + #size-cells = <0>; 43 + 44 + heart_mon@0 { 45 + compatible = "ti,afe4403"; 46 + reg = <0>; 47 + spi-max-frequency = <10000000>; 48 + tx-supply = <&vbat>; 49 + interrupt-parent = <&gpio1>; 50 + interrupts = <28 IRQ_TYPE_EDGE_RISING>; 51 + reset-gpios = <&gpio1 16 GPIO_ACTIVE_LOW>; 52 + }; 53 + }; 54 + ...