15ae45114SSam Protsenko# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 25ae45114SSam Protsenko%YAML 1.2 35ae45114SSam Protsenko--- 45ae45114SSam Protsenko$id: http://devicetree.org/schemas/i2c/i2c-exynos5.yaml# 55ae45114SSam Protsenko$schema: http://devicetree.org/meta-schemas/core.yaml# 65ae45114SSam Protsenko 75ae45114SSam Protsenkotitle: Samsung's High Speed I2C controller 85ae45114SSam Protsenko 95ae45114SSam Protsenkomaintainers: 10*8a1e6bb3SKrzysztof Kozlowski - Krzysztof Kozlowski <krzk@kernel.org> 115ae45114SSam Protsenko 125ae45114SSam Protsenkodescription: | 135ae45114SSam Protsenko The Samsung's High Speed I2C controller is used to interface with I2C devices 145ae45114SSam Protsenko at various speeds ranging from 100kHz to 3.4MHz. 155ae45114SSam Protsenko 16bd5f985dSJaewon Kim In case the HSI2C controller is encapsulated within USI block (it's the case 17bd5f985dSJaewon Kim e.g. for Exynos850 and Exynos Auto V9 SoCs), it might be also necessary to 18bd5f985dSJaewon Kim define USI node in device tree file, choosing "i2c" configuration. Please see 19bd5f985dSJaewon Kim Documentation/devicetree/bindings/soc/samsung/exynos-usi.yaml for details. 20bd5f985dSJaewon Kim 215ae45114SSam Protsenkoproperties: 225ae45114SSam Protsenko compatible: 235ae45114SSam Protsenko oneOf: 245ae45114SSam Protsenko - enum: 255ae45114SSam Protsenko - samsung,exynos5250-hsi2c # Exynos5250 and Exynos5420 265ae45114SSam Protsenko - samsung,exynos5260-hsi2c # Exynos5260 275ae45114SSam Protsenko - samsung,exynos7-hsi2c # Exynos7 28bd5f985dSJaewon Kim - samsung,exynosautov9-hsi2c # ExynosAutoV9 and Exynos850 295ae45114SSam Protsenko - const: samsung,exynos5-hsi2c # Exynos5250 and Exynos5420 305ae45114SSam Protsenko deprecated: true 315ae45114SSam Protsenko 325ae45114SSam Protsenko reg: 335ae45114SSam Protsenko maxItems: 1 345ae45114SSam Protsenko 355ae45114SSam Protsenko interrupts: 365ae45114SSam Protsenko maxItems: 1 375ae45114SSam Protsenko 385ae45114SSam Protsenko clock-frequency: 395ae45114SSam Protsenko default: 100000 405ae45114SSam Protsenko description: 415ae45114SSam Protsenko Desired operating frequency in Hz of the bus. 425ae45114SSam Protsenko 435ae45114SSam Protsenko If not specified, the bus operates in fast-speed mode at 100kHz. 445ae45114SSam Protsenko 455ae45114SSam Protsenko If specified, the bus operates in high-speed mode only if the 465ae45114SSam Protsenko clock-frequency is >= 1MHz. 475ae45114SSam Protsenko 485ae45114SSam Protsenko clocks: 49ea8491a2SSam Protsenko minItems: 1 50ea8491a2SSam Protsenko items: 51ea8491a2SSam Protsenko - description: I2C operating clock 52ea8491a2SSam Protsenko - description: Bus clock (APB) 535ae45114SSam Protsenko 545ae45114SSam Protsenko clock-names: 55ea8491a2SSam Protsenko minItems: 1 56ea8491a2SSam Protsenko items: 57ea8491a2SSam Protsenko - const: hsi2c 58ea8491a2SSam Protsenko - const: hsi2c_pclk 595ae45114SSam Protsenko 605ae45114SSam Protsenkorequired: 615ae45114SSam Protsenko - compatible 625ae45114SSam Protsenko - reg 635ae45114SSam Protsenko - interrupts 645ae45114SSam Protsenko - clocks 655ae45114SSam Protsenko 66ea8491a2SSam ProtsenkoallOf: 67ea8491a2SSam Protsenko - $ref: /schemas/i2c/i2c-controller.yaml# 68ea8491a2SSam Protsenko - if: 69ea8491a2SSam Protsenko properties: 70ea8491a2SSam Protsenko compatible: 71ea8491a2SSam Protsenko contains: 72ea8491a2SSam Protsenko enum: 73ea8491a2SSam Protsenko - samsung,exynosautov9-hsi2c 74ea8491a2SSam Protsenko 75ea8491a2SSam Protsenko then: 76ea8491a2SSam Protsenko properties: 77ea8491a2SSam Protsenko clocks: 78ea8491a2SSam Protsenko minItems: 2 79ea8491a2SSam Protsenko 80ea8491a2SSam Protsenko clock-names: 81ea8491a2SSam Protsenko minItems: 2 82ea8491a2SSam Protsenko 83ea8491a2SSam Protsenko required: 84ea8491a2SSam Protsenko - clock-names 85ea8491a2SSam Protsenko 86ea8491a2SSam Protsenko else: 87ea8491a2SSam Protsenko properties: 88ea8491a2SSam Protsenko clocks: 89ea8491a2SSam Protsenko maxItems: 1 90ea8491a2SSam Protsenko 915ae45114SSam ProtsenkounevaluatedProperties: false 925ae45114SSam Protsenko 935ae45114SSam Protsenkoexamples: 945ae45114SSam Protsenko - | 955ae45114SSam Protsenko #include <dt-bindings/clock/exynos5420.h> 965ae45114SSam Protsenko #include <dt-bindings/interrupt-controller/arm-gic.h> 975ae45114SSam Protsenko #include <dt-bindings/interrupt-controller/irq.h> 985ae45114SSam Protsenko 995ae45114SSam Protsenko hsi2c_8: i2c@12e00000 { 1005ae45114SSam Protsenko compatible = "samsung,exynos5250-hsi2c"; 1015ae45114SSam Protsenko reg = <0x12e00000 0x1000>; 1025ae45114SSam Protsenko interrupts = <GIC_SPI 87 IRQ_TYPE_LEVEL_HIGH>; 1035ae45114SSam Protsenko #address-cells = <1>; 1045ae45114SSam Protsenko #size-cells = <0>; 1055ae45114SSam Protsenko clock-frequency = <100000>; 1065ae45114SSam Protsenko clocks = <&clock CLK_USI4>; 1075ae45114SSam Protsenko clock-names = "hsi2c"; 1085ae45114SSam Protsenko 1095ae45114SSam Protsenko pmic@66 { 1105ae45114SSam Protsenko /* compatible = "samsung,s2mps11-pmic"; */ 1115ae45114SSam Protsenko reg = <0x66>; 1125ae45114SSam Protsenko }; 1135ae45114SSam Protsenko }; 114ea8491a2SSam Protsenko 115ea8491a2SSam Protsenko - | 116ea8491a2SSam Protsenko #include <dt-bindings/clock/exynos850.h> 117ea8491a2SSam Protsenko #include <dt-bindings/interrupt-controller/arm-gic.h> 118ea8491a2SSam Protsenko 119ea8491a2SSam Protsenko hsi2c_2: i2c@138c0000 { 120ea8491a2SSam Protsenko compatible = "samsung,exynosautov9-hsi2c"; 121ea8491a2SSam Protsenko reg = <0x138c0000 0xc0>; 122ea8491a2SSam Protsenko interrupts = <GIC_SPI 195 IRQ_TYPE_LEVEL_HIGH>; 123ea8491a2SSam Protsenko #address-cells = <1>; 124ea8491a2SSam Protsenko #size-cells = <0>; 125ea8491a2SSam Protsenko clocks = <&cmu_peri CLK_GOUT_HSI2C2_IPCLK>, 126ea8491a2SSam Protsenko <&cmu_peri CLK_GOUT_HSI2C2_PCLK>; 127ea8491a2SSam Protsenko clock-names = "hsi2c", "hsi2c_pclk"; 128ea8491a2SSam Protsenko 129ea8491a2SSam Protsenko pmic@66 { 130ea8491a2SSam Protsenko /* compatible = "samsung,s2mps11-pmic"; */ 131ea8491a2SSam Protsenko reg = <0x66>; 132ea8491a2SSam Protsenko }; 133ea8491a2SSam Protsenko }; 134