Path: blob/master/Documentation/devicetree/bindings/i2c/atmel,at91sam-i2c.yaml
26307 views
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)1# Copyright (C) 2022 Microchip Technology, Inc. and its subsidiaries2%YAML 1.23---4$id: http://devicetree.org/schemas/i2c/atmel,at91sam-i2c.yaml#5$schema: http://devicetree.org/meta-schemas/core.yaml#67title: I2C for Atmel/Microchip platforms89maintainers:10- Alexandre Belloni <alexandre.belloni@bootlin.com>1112properties:13compatible:14oneOf:15- items:16- enum:17- atmel,at91rm9200-i2c18- atmel,at91sam9261-i2c19- atmel,at91sam9260-i2c20- atmel,at91sam9g20-i2c21- atmel,at91sam9g10-i2c22- atmel,at91sam9x5-i2c23- atmel,sama5d4-i2c24- atmel,sama5d2-i2c25- microchip,sam9x60-i2c26- items:27- enum:28- microchip,sama7d65-i2c29- microchip,sama7g5-i2c30- microchip,sam9x7-i2c31- const: microchip,sam9x60-i2c3233reg:34maxItems: 13536interrupts:37maxItems: 13839clocks:40maxItems: 14142clock-frequency:43default: 1000004445dmas:46items:47- description: TX DMA Channel Specifier48- description: RX DMA Channel Specifier4950dma-names:51items:52- const: tx53- const: rx5455atmel,fifo-size:56$ref: /schemas/types.yaml#/definitions/uint3257description: |58Maximum number of data the RX and TX FIFOs can store for59FIFO capable I2C controllers.6061scl-gpios: true6263sda-gpios: true6465required:66- compatible67- reg68- interrupts69- clocks7071allOf:72- $ref: /schemas/i2c/i2c-controller.yaml#73- if:74properties:75compatible:76contains:77enum:78- atmel,sama5d4-i2c79- atmel,sama5d2-i2c80- microchip,sam9x60-i2c81- microchip,sama7d65-i2c82- microchip,sama7g5-i2c83then:84properties:85i2c-sda-hold-time-ns:86description:87TWD hold time88maxItems: 18990unevaluatedProperties: false9192examples:93- |94#include <dt-bindings/interrupt-controller/irq.h>95#include <dt-bindings/dma/at91.h>96#include <dt-bindings/gpio/gpio.h>9798i2c0: i2c@fff84000 {99compatible = "atmel,at91sam9g20-i2c";100reg = <0xfff84000 0x100>;101interrupts = <12 IRQ_TYPE_LEVEL_HIGH 6>;102#address-cells = <1>;103#size-cells = <0>;104clocks = <&twi0_clk>;105clock-frequency = <400000>;106107eeprom@50 {108compatible = "atmel,24c512";109reg = <0x50>;110pagesize = <128>;111};112};113114i2c1: i2c@f8034600 {115compatible = "atmel,sama5d2-i2c";116reg = <0xf8034600 0x100>;117interrupts = <19 IRQ_TYPE_LEVEL_HIGH 7>;118dmas = <&dma0119(AT91_XDMAC_DT_MEM_IF(0) | AT91_XDMAC_DT_PER_IF(1))120AT91_XDMAC_DT_PERID(11)>,121<&dma0122(AT91_XDMAC_DT_MEM_IF(0) | AT91_XDMAC_DT_PER_IF(1))123AT91_XDMAC_DT_PERID(12)>;124dma-names = "tx", "rx";125#address-cells = <1>;126#size-cells = <0>;127clocks = <&flx0>;128atmel,fifo-size = <16>;129i2c-sda-hold-time-ns = <336>;130pinctrl-names = "default", "gpio";131pinctrl-0 = <&pinctrl_i2c0>;132pinctrl-1 = <&pinctrl_i2c0_gpio>;133sda-gpios = <&pioA 30 GPIO_ACTIVE_HIGH>;134scl-gpios = <&pioA 31 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;135136eeprom@54 {137compatible = "atmel,24c02";138reg = <0x54>;139pagesize = <16>;140};141};142143144