1c66ec88fSEmmanuel Vadot# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 2c66ec88fSEmmanuel Vadot%YAML 1.2 3c66ec88fSEmmanuel Vadot--- 4c66ec88fSEmmanuel Vadot$id: http://devicetree.org/schemas/i2c/nuvoton,npcm7xx-i2c.yaml# 5c66ec88fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6c66ec88fSEmmanuel Vadot 7*7ef62cebSEmmanuel Vadottitle: nuvoton NPCM7XX I2C Controller 8c66ec88fSEmmanuel Vadot 9c66ec88fSEmmanuel Vadotdescription: | 10b97ee269SEmmanuel Vadot I2C bus controllers of the NPCM series support both master and 11b97ee269SEmmanuel Vadot slave mode. Each controller can switch between master and slave at run time 12b97ee269SEmmanuel Vadot (i.e. IPMB mode). HW FIFO for TX and RX are supported. 13c66ec88fSEmmanuel Vadot 14c66ec88fSEmmanuel Vadotmaintainers: 15c66ec88fSEmmanuel Vadot - Tali Perry <tali.perry1@gmail.com> 16c66ec88fSEmmanuel Vadot 17c66ec88fSEmmanuel Vadotproperties: 18c66ec88fSEmmanuel Vadot compatible: 19b97ee269SEmmanuel Vadot enum: 20b97ee269SEmmanuel Vadot - nuvoton,npcm750-i2c 21b97ee269SEmmanuel Vadot - nuvoton,npcm845-i2c 22c66ec88fSEmmanuel Vadot 23c66ec88fSEmmanuel Vadot reg: 24c66ec88fSEmmanuel Vadot maxItems: 1 25c66ec88fSEmmanuel Vadot 26c66ec88fSEmmanuel Vadot interrupts: 27c66ec88fSEmmanuel Vadot maxItems: 1 28c66ec88fSEmmanuel Vadot 29c66ec88fSEmmanuel Vadot clocks: 30c66ec88fSEmmanuel Vadot maxItems: 1 31c66ec88fSEmmanuel Vadot description: Reference clock for the I2C bus 32c66ec88fSEmmanuel Vadot 33c66ec88fSEmmanuel Vadot clock-frequency: 34c66ec88fSEmmanuel Vadot description: Desired I2C bus clock frequency in Hz. If not specified, 35c66ec88fSEmmanuel Vadot the default 100 kHz frequency will be used. 36c66ec88fSEmmanuel Vadot possible values are 100000, 400000 and 1000000. 37c66ec88fSEmmanuel Vadot default: 100000 38c66ec88fSEmmanuel Vadot enum: [100000, 400000, 1000000] 39c66ec88fSEmmanuel Vadot 40b97ee269SEmmanuel Vadot nuvoton,sys-mgr: 41b97ee269SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/phandle 42b97ee269SEmmanuel Vadot description: The phandle of system manager register node. 43b97ee269SEmmanuel Vadot 44c66ec88fSEmmanuel Vadotrequired: 45c66ec88fSEmmanuel Vadot - compatible 46c66ec88fSEmmanuel Vadot - reg 47c66ec88fSEmmanuel Vadot - interrupts 48c66ec88fSEmmanuel Vadot - clocks 49c66ec88fSEmmanuel Vadot 50c66ec88fSEmmanuel VadotallOf: 51c66ec88fSEmmanuel Vadot - $ref: /schemas/i2c/i2c-controller.yaml# 52b97ee269SEmmanuel Vadot - if: 53b97ee269SEmmanuel Vadot properties: 54b97ee269SEmmanuel Vadot compatible: 55b97ee269SEmmanuel Vadot contains: 56b97ee269SEmmanuel Vadot const: nuvoton,npcm845-i2c 57b97ee269SEmmanuel Vadot 58b97ee269SEmmanuel Vadot then: 59b97ee269SEmmanuel Vadot required: 60b97ee269SEmmanuel Vadot - nuvoton,sys-mgr 61c66ec88fSEmmanuel Vadot 62c66ec88fSEmmanuel VadotunevaluatedProperties: false 63c66ec88fSEmmanuel Vadot 64c66ec88fSEmmanuel Vadotexamples: 65c66ec88fSEmmanuel Vadot - | 66c66ec88fSEmmanuel Vadot #include <dt-bindings/clock/nuvoton,npcm7xx-clock.h> 67c66ec88fSEmmanuel Vadot #include <dt-bindings/interrupt-controller/arm-gic.h> 68c66ec88fSEmmanuel Vadot i2c0: i2c@80000 { 69c66ec88fSEmmanuel Vadot reg = <0x80000 0x1000>; 70c66ec88fSEmmanuel Vadot clocks = <&clk NPCM7XX_CLK_APB2>; 71c66ec88fSEmmanuel Vadot clock-frequency = <100000>; 72c66ec88fSEmmanuel Vadot interrupts = <GIC_SPI 64 IRQ_TYPE_LEVEL_HIGH>; 73c66ec88fSEmmanuel Vadot compatible = "nuvoton,npcm750-i2c"; 74b97ee269SEmmanuel Vadot nuvoton,sys-mgr = <&gcr>; 75c66ec88fSEmmanuel Vadot }; 76c66ec88fSEmmanuel Vadot 77c66ec88fSEmmanuel Vadot... 78