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

dt-bindings: i2c: nxp,lpc1788-i2c: convert to dt schema

Convert the NXP I2C controller for LPC2xxx/178x/18xx/43xx
to newer DT schema. Created DT schema based on the .txt file
which had `compatible`, `reg`, `interrupts`, `clocks`,
`#address-cells` and `#size-cells` as required properties.

Additional changes to the original .txt binding
- added maintainer from the MAINTAINERS file.
- added resets property required by the corresponding DTS files.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Kanak Shilledar <kanakshilledar@gmail.com>
Signed-off-by: Andi Shyti <andi.shyti@kernel.org>

authored by

Kanak Shilledar and committed by
Andi Shyti
d5adffc4 2362c730

+55 -34
-33
Documentation/devicetree/bindings/i2c/i2c-lpc2k.txt
··· 1 - NXP I2C controller for LPC2xxx/178x/18xx/43xx 2 - 3 - Required properties: 4 - - compatible: must be "nxp,lpc1788-i2c" 5 - - reg: physical address and length of the device registers 6 - - interrupts: a single interrupt specifier 7 - - clocks: clock for the device 8 - - #address-cells: should be <1> 9 - - #size-cells: should be <0> 10 - 11 - Optional properties: 12 - - clock-frequency: the desired I2C bus clock frequency in Hz; in 13 - absence of this property the default value is used (100 kHz). 14 - 15 - Example: 16 - i2c0: i2c@400a1000 { 17 - compatible = "nxp,lpc1788-i2c"; 18 - reg = <0x400a1000 0x1000>; 19 - interrupts = <18>; 20 - clocks = <&ccu1 CLK_APB1_I2C0>; 21 - #address-cells = <1>; 22 - #size-cells = <0>; 23 - }; 24 - 25 - &i2c0 { 26 - clock-frequency = <400000>; 27 - 28 - lm75@48 { 29 - compatible = "nxp,lm75"; 30 - reg = <0x48>; 31 - }; 32 - }; 33 -
+54
Documentation/devicetree/bindings/i2c/nxp,lpc1788-i2c.yaml
··· 1 + # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/i2c/nxp,lpc1788-i2c.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: NXP I2C controller for LPC2xxx/178x/18xx/43xx 8 + 9 + maintainers: 10 + - Vladimir Zapolskiy <vz@mleia.com> 11 + 12 + allOf: 13 + - $ref: /schemas/i2c/i2c-controller.yaml# 14 + 15 + properties: 16 + compatible: 17 + const: nxp,lpc1788-i2c 18 + 19 + reg: 20 + maxItems: 1 21 + 22 + interrupts: 23 + maxItems: 1 24 + 25 + clocks: 26 + maxItems: 1 27 + 28 + clock-frequency: 29 + description: the desired I2C bus clock frequency in Hz 30 + default: 100000 31 + 32 + resets: 33 + maxItems: 1 34 + 35 + required: 36 + - compatible 37 + - reg 38 + - interrupts 39 + - clocks 40 + 41 + unevaluatedProperties: false 42 + 43 + examples: 44 + - | 45 + #include "dt-bindings/clock/lpc18xx-ccu.h" 46 + 47 + i2c@400a1000 { 48 + compatible = "nxp,lpc1788-i2c"; 49 + reg = <0x400a1000 0x1000>; 50 + interrupts = <18>; 51 + clocks = <&ccu1 CLK_APB1_I2C0>; 52 + #address-cells = <1>; 53 + #size-cells = <0>; 54 + };
+1 -1
MAINTAINERS
··· 2374 2374 M: Vladimir Zapolskiy <vz@mleia.com> 2375 2375 L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 2376 2376 S: Maintained 2377 - F: Documentation/devicetree/bindings/i2c/i2c-lpc2k.txt 2377 + F: Documentation/devicetree/bindings/i2c/nxp,lpc1788-i2c.yaml 2378 2378 F: arch/arm/boot/dts/nxp/lpc/lpc43* 2379 2379 F: drivers/i2c/busses/i2c-lpc2k.c 2380 2380 F: drivers/memory/pl172.c