Message ID | 20221122-mt8365-i2c-support-v3-0-ad9bb1076d7f@baylibre.com |
---|---|
Headers | show |
Series | Add MediaTek MT8365 I2C support | expand |
Il 06/03/23 14:47, Alexandre Mergnat ha scritto: > Enable the I2C0 bus provides communication with: > - The integrated RT9466 Switching Battery Charger. > - The integrated MT6691 LP4X buck for VDDQ. > - The integrated MT6691 LP4X buck for VDD2. > - The pin header, to plug external I2C devices. > > Signed-off-by: Alexandre Mergnat <amergnat@baylibre.com> > --- > arch/arm64/boot/dts/mediatek/mt8365-evk.dts | 19 +++++++++++++++++++ > 1 file changed, 19 insertions(+) > > diff --git a/arch/arm64/boot/dts/mediatek/mt8365-evk.dts b/arch/arm64/boot/dts/mediatek/mt8365-evk.dts > index 4683704ea235..b68aee8f229f 100644 > --- a/arch/arm64/boot/dts/mediatek/mt8365-evk.dts > +++ b/arch/arm64/boot/dts/mediatek/mt8365-evk.dts > @@ -87,6 +87,15 @@ optee_reserved: optee@43200000 { > }; > }; > > +&i2c0 { > + pinctrl-names = "default"; > + pinctrl-0 = <&i2c0_pins>; > + clock-frequency = <100000>; > + status = "okay"; > + #address-cells = <1>; > + #size-cells = <0>; Address and size cells are useless if there's no subnode of i2c0... besides that, please keep the properties ordered by name. clock-frequency pinctrl-0 pinctrl-names status > +}; > + > &pio { > gpio_keys: gpio-keys-pins { > pins { > @@ -96,6 +105,16 @@ pins { > }; > }; > > + i2c0_pins: i2c0-pins { > + pins { > + pinmux = <MT8365_PIN_57_SDA0__FUNC_SDA0_0>, > + <MT8365_PIN_58_SCL0__FUNC_SCL0_0>; > + mediatek,pull-up-adv = <3>; > + mediatek,drive-strength-adv = <00>; bias-pull-up; mediatek,d... mediatek,p.... Also, "00" is the same as "0", being this not a string... so write it as 0. Thanks, Angelo
Hi, This patch series adds I2C support for MT8365-EVK board. The I2C-0 is enabled, it can be used through the board pin header, as described directly on the PCB. This series depends to another one which add support for MT8365 SoC and EVK board. Link [1] One patch has been cherry-picked from [2], so I've addressed the comment and kept the trailer. Regards, Alex [1]: https://lore.kernel.org/linux-mediatek/20230101220149.3035048-1-bero@baylibre.com/ [2]: https://lore.kernel.org/all/20220531135026.238475-2-fparent@baylibre.com/ To: Qii Wang <qii.wang@mediatek.com> To: Rob Herring <robh+dt@kernel.org> To: Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org> To: Matthias Brugger <matthias.bgg@gmail.com> Cc: linux-i2c@vger.kernel.org Cc: devicetree@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-mediatek@lists.infradead.org Cc: linux-kernel@vger.kernel.org Cc: Fabien Parent <fparent@baylibre.com> Cc: Rob Herring <robh@kernel.org> Cc: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Signed-off-by: Alexandre Mergnat <amergnat@baylibre.com> --- Changes in v3: - Rebased to v6.3-rc1. - Move i2c3 node to be consistent with the SoC address order. - Link to v2: https://lore.kernel.org/r/20221122-mt8365-i2c-support-v2-0-e4c7c514e781@baylibre.com Changes in v2: - Drop the patch which do useless change in i2c-mt65xx.c driver. - Change 2 lines compatible/reg in oneline. - Link to v1: https://lore.kernel.org/r/20221122-mt8365-i2c-support-v1-0-4aeb7c54c67b@baylibre.com --- Alexandre Mergnat (2): arm64: dts: mediatek: add i2c support for mt8365 SoC arm64: dts: mediatek: enable i2c0 for mt8365-evk board arch/arm64/boot/dts/mediatek/mt8365-evk.dts | 19 +++++++++++ arch/arm64/boot/dts/mediatek/mt8365.dtsi | 52 +++++++++++++++++++++++++++++ 2 files changed, 71 insertions(+) --- base-commit: 5c6b974d24c21a6aa5d8b524067d7d9bc7fcc4f2 change-id: 20221122-mt8365-i2c-support-fc048da261ea Best regards,