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: sc16is7xx: convert to YAML

Convert binding from text format to YAML.

Additions to original text binding:
- add rs485 reference.

Signed-off-by: Hugo Villeneuve <hvilleneuve@dimonoff.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20230927160153.2717788-3-hugo@hugovil.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Hugo Villeneuve and committed by
Greg Kroah-Hartman
0d447e92 1a0a2a1e

+127 -118
-118
Documentation/devicetree/bindings/serial/nxp,sc16is7xx.txt
··· 1 - * NXP SC16IS7xx advanced Universal Asynchronous Receiver-Transmitter (UART) 2 - * i2c as bus 3 - 4 - Required properties: 5 - - compatible: Should be one of the following: 6 - - "nxp,sc16is740" for NXP SC16IS740, 7 - - "nxp,sc16is741" for NXP SC16IS741, 8 - - "nxp,sc16is750" for NXP SC16IS750, 9 - - "nxp,sc16is752" for NXP SC16IS752, 10 - - "nxp,sc16is760" for NXP SC16IS760, 11 - - "nxp,sc16is762" for NXP SC16IS762. 12 - - reg: I2C address of the SC16IS7xx device. 13 - - interrupts: Should contain the UART interrupt 14 - - clocks: Reference to the IC source clock. 15 - OR (when there is no clock provider visible to the platform) 16 - - clock-frequency: The source clock frequency for the IC. 17 - 18 - Optional properties: 19 - - gpio-controller: Marks the device node as a GPIO controller. 20 - - #gpio-cells: Should be two. The first cell is the GPIO number and 21 - the second cell is used to specify the GPIO polarity: 22 - 0 = active high, 23 - 1 = active low. 24 - - irda-mode-ports: An array that lists the indices of the port that 25 - should operate in IrDA mode. 26 - - nxp,modem-control-line-ports: An array that lists the indices of the port that 27 - should have shared GPIO lines configured as 28 - modem control lines. 29 - 30 - Example: 31 - sc16is750: sc16is750@51 { 32 - compatible = "nxp,sc16is750"; 33 - reg = <0x51>; 34 - clocks = <&clk20m>; 35 - interrupt-parent = <&gpio3>; 36 - interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 37 - gpio-controller; 38 - #gpio-cells = <2>; 39 - }; 40 - 41 - sc16is752: sc16is752@53 { 42 - compatible = "nxp,sc16is752"; 43 - reg = <0x53>; 44 - clocks = <&clk20m>; 45 - interrupt-parent = <&gpio3>; 46 - interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 47 - nxp,modem-control-line-ports = <1>; /* Port 1 as modem control lines */ 48 - gpio-controller; /* Port 0 as GPIOs */ 49 - #gpio-cells = <2>; 50 - }; 51 - 52 - sc16is752: sc16is752@54 { 53 - compatible = "nxp,sc16is752"; 54 - reg = <0x54>; 55 - clocks = <&clk20m>; 56 - interrupt-parent = <&gpio3>; 57 - interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 58 - nxp,modem-control-line-ports = <0 1>; /* Ports 0 and 1 as modem control lines */ 59 - }; 60 - 61 - * spi as bus 62 - 63 - Required properties: 64 - - compatible: Should be one of the following: 65 - - "nxp,sc16is740" for NXP SC16IS740, 66 - - "nxp,sc16is741" for NXP SC16IS741, 67 - - "nxp,sc16is750" for NXP SC16IS750, 68 - - "nxp,sc16is752" for NXP SC16IS752, 69 - - "nxp,sc16is760" for NXP SC16IS760, 70 - - "nxp,sc16is762" for NXP SC16IS762. 71 - - reg: SPI chip select number. 72 - - interrupts: Specifies the interrupt source of the parent interrupt 73 - controller. The format of the interrupt specifier depends on the 74 - parent interrupt controller. 75 - - clocks: phandle to the IC source clock. 76 - 77 - Optional properties: 78 - - gpio-controller: Marks the device node as a GPIO controller. 79 - - #gpio-cells: Should be two. The first cell is the GPIO number and 80 - the second cell is used to specify the GPIO polarity: 81 - 0 = active high, 82 - 1 = active low. 83 - - irda-mode-ports: An array that lists the indices of the port that 84 - should operate in IrDA mode. 85 - - nxp,modem-control-line-ports: An array that lists the indices of the port that 86 - should have shared GPIO lines configured as 87 - modem control lines. 88 - 89 - Example: 90 - sc16is750: sc16is750@0 { 91 - compatible = "nxp,sc16is750"; 92 - reg = <0>; 93 - clocks = <&clk20m>; 94 - interrupt-parent = <&gpio3>; 95 - interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 96 - gpio-controller; 97 - #gpio-cells = <2>; 98 - }; 99 - 100 - sc16is752: sc16is752@1 { 101 - compatible = "nxp,sc16is752"; 102 - reg = <1>; 103 - clocks = <&clk20m>; 104 - interrupt-parent = <&gpio3>; 105 - interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 106 - nxp,modem-control-line-ports = <1>; /* Port 1 as modem control lines */ 107 - gpio-controller; /* Port 0 as GPIOs */ 108 - #gpio-cells = <2>; 109 - }; 110 - 111 - sc16is752: sc16is752@2 { 112 - compatible = "nxp,sc16is752"; 113 - reg = <2>; 114 - clocks = <&clk20m>; 115 - interrupt-parent = <&gpio3>; 116 - interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 117 - nxp,modem-control-line-ports = <0 1>; /* Ports 0 and 1 as modem control lines */ 118 - };
+127
Documentation/devicetree/bindings/serial/nxp,sc16is7xx.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/serial/nxp,sc16is7xx.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: NXP SC16IS7xx Advanced Universal Asynchronous Receiver-Transmitter (UART) 8 + 9 + maintainers: 10 + - Hugo Villeneuve <hvilleneuve@dimonoff.com> 11 + 12 + properties: 13 + compatible: 14 + enum: 15 + - nxp,sc16is740 16 + - nxp,sc16is741 17 + - nxp,sc16is750 18 + - nxp,sc16is752 19 + - nxp,sc16is760 20 + - nxp,sc16is762 21 + 22 + reg: 23 + maxItems: 1 24 + 25 + interrupts: 26 + maxItems: 1 27 + 28 + clocks: 29 + maxItems: 1 30 + 31 + clock-frequency: 32 + description: 33 + When there is no clock provider visible to the platform, this 34 + is the source crystal or external clock frequency for the IC in Hz. 35 + minimum: 1 36 + maximum: 80000000 37 + 38 + gpio-controller: true 39 + 40 + "#gpio-cells": 41 + const: 2 42 + 43 + gpio-line-names: 44 + minItems: 1 45 + maxItems: 8 46 + 47 + irda-mode-ports: 48 + description: | 49 + An array that lists the indices of the port that should operate in IrDA 50 + mode: 51 + 0: port A 52 + 1: port B 53 + $ref: /schemas/types.yaml#/definitions/uint32-array 54 + minItems: 1 55 + maxItems: 2 56 + items: 57 + minimum: 0 58 + maximum: 1 59 + 60 + nxp,modem-control-line-ports: 61 + description: | 62 + An array that lists the indices of the port that should have shared GPIO 63 + lines configured as modem control lines: 64 + 0: port A 65 + 1: port B 66 + $ref: /schemas/types.yaml#/definitions/uint32-array 67 + minItems: 1 68 + maxItems: 2 69 + items: 70 + minimum: 0 71 + maximum: 1 72 + 73 + allOf: 74 + - $ref: /schemas/spi/spi-peripheral-props.yaml# 75 + - $ref: /schemas/serial/serial.yaml# 76 + - $ref: /schemas/serial/rs485.yaml# 77 + 78 + required: 79 + - compatible 80 + - reg 81 + - interrupts 82 + 83 + oneOf: 84 + - required: 85 + - clocks 86 + - required: 87 + - clock-frequency 88 + 89 + unevaluatedProperties: false 90 + 91 + examples: 92 + - | 93 + #include <dt-bindings/interrupt-controller/irq.h> 94 + i2c { 95 + #address-cells = <1>; 96 + #size-cells = <0>; 97 + 98 + serial@51 { 99 + compatible = "nxp,sc16is750"; 100 + reg = <0x51>; 101 + clocks = <&clk20m>; 102 + interrupt-parent = <&gpio3>; 103 + interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 104 + gpio-controller; 105 + #gpio-cells = <2>; 106 + }; 107 + 108 + serial@53 { 109 + compatible = "nxp,sc16is752"; 110 + reg = <0x53>; 111 + clocks = <&clk20m>; 112 + interrupt-parent = <&gpio3>; 113 + interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 114 + nxp,modem-control-line-ports = <1>; /* Port 1 as modem control lines */ 115 + gpio-controller; /* Port 0 as GPIOs */ 116 + #gpio-cells = <2>; 117 + }; 118 + 119 + serial@54 { 120 + compatible = "nxp,sc16is752"; 121 + reg = <0x54>; 122 + clocks = <&clk20m>; 123 + interrupt-parent = <&gpio3>; 124 + interrupts = <7 IRQ_TYPE_EDGE_FALLING>; 125 + nxp,modem-control-line-ports = <0 1>; /* Ports 0 and 1 as modem control lines */ 126 + }; 127 + };