From patchwork Sat Dec 4 21:58:12 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sam Protsenko X-Patchwork-Id: 520728 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0E70EC433F5 for ; Sat, 4 Dec 2021 21:58:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236369AbhLDWBu (ORCPT ); Sat, 4 Dec 2021 17:01:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47420 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236707AbhLDWBt (ORCPT ); Sat, 4 Dec 2021 17:01:49 -0500 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1168DC061359 for ; Sat, 4 Dec 2021 13:58:23 -0800 (PST) Received: by mail-wm1-x334.google.com with SMTP id i12so5165753wmq.4 for ; Sat, 04 Dec 2021 13:58:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=jHZ/NY52q+fJ8ZyowbxA7ltlvG1kl7aRGse+qxxLYbY=; b=TaNYBwZrqLHyDEpJd9tFK7v+pEKaWZ3gK/aQWMCDDiOa6FN6Mnu+hJnKy121s0MzAX jbUGACs1M/WfjkNBwPxlIVi8YPDfNYI2gAn/Eb2RgQQCRrZgLRMcYopKWgiKyfQ/9zBT 0+45bnNZAEfMMDVntIok6Cb9RlSyuacIBJJWN9dDtpXoH8feVj4IZJPNVMsc2n65lTY6 e5jr96haRHzO7POFgzMt9Bvc8gKcRV4WyEkwHJlnmG6TBKJkMDfZ2+xgpCQjzEOaQY/m xzEoF9kclmjQhxyGKDNVj5UQN5qCXQk9+qf9609TYCc629b3/WHGgyG2xYQUw8mGUbAz dmdQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=jHZ/NY52q+fJ8ZyowbxA7ltlvG1kl7aRGse+qxxLYbY=; b=RY37kvuSs9oUW3LlDTDXVRQsH3gp+XcXwCek0I4NHtTSyiecNQ+gXAAFr5uXjTImV3 f49LKLoEVmuCiM8vDW2LyTYPkNUtcvUER8lWDqPwR7/iN9ym80VzK45UhxQ6xQ0igsKR Bar+c9n7hgIAYOda58fRse04TnqSyDxnc59pnSGGirzKrs+dH5YtKydBialET1rN9A8B LEseMRAxYkTdouy+hoaK/iBIUdmA7PrvgledrUd7mVcrjS6Pr9FXky7zlq7Jzw6IdzUW KRryVoShQUgQvXFtdUaT+QAClMf381r6InlDl6S9wV6T3BD7haK8YGd4bFqNoZBF0mig nuIw== X-Gm-Message-State: AOAM532i85b5vMO3BQF8/EFkC06i4bi1FxIAzJ9Vl0TsQ7Te2/oorMTH Q7DbDCSkIGNWLXOSDeu941Qz2g== X-Google-Smtp-Source: ABdhPJyBlS65eTB40gkaiVnMcqmJfn92ZRp+4jD43fZfatuxal9gpwbItlIEPVa3d0KqyoC1hPexAA== X-Received: by 2002:a05:600c:4e8f:: with SMTP id f15mr11572129wmq.116.1638655101461; Sat, 04 Dec 2021 13:58:21 -0800 (PST) Received: from localhost ([31.134.121.151]) by smtp.gmail.com with ESMTPSA id o3sm9628522wms.10.2021.12.04.13.58.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 04 Dec 2021 13:58:21 -0800 (PST) From: Sam Protsenko To: Krzysztof Kozlowski , Rob Herring Cc: Jaewon Kim , Chanho Park , David Virag , Youngmin Nam , Wolfram Sang , Arnd Bergmann , linux-i2c@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-samsung-soc@vger.kernel.org Subject: [PATCH v2 RESEND 0/8] i2c: exynos5: Add support for modern Exynos SoCs Date: Sat, 4 Dec 2021 23:58:12 +0200 Message-Id: <20211204215820.17378-1-semen.protsenko@linaro.org> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org Modern ARM64 Samsung Exynos SoCs (like Exynos Auto V9 and Exynos850) use pretty much the same High-Speed I2C controller supported in i2c-exynos5 driver ("samsung,exynos7-hsi2c" variant), but with some differences: - timings are now calculated and configured a bit differently - two clocks are now provided to HSI2C controller (and must be asserted during I2C operation and register access) This patch series implements these changes, making it possible to use HSI2C driver on modern Exynos SoCs. Another change in mentioned SoCs is that HSI2C controller is now a part of USIv2 IP-core. But no USI modifications are needed in HSI2C driver, as all USI related configuration is done in USI driver independently. USI driver is added in [1] series (or its later revision, if available). To make HSI2C functional, both patch series (this one and [1]) have to be applied, but those can be applied independently. Changes in v2: - Added new patches renaming "hsi2c@*" nodes to "i2c@*" for Exynos dts's - Added R-b tags from v1 review - Fixed and improved i2c-exynos5 dt-bindings [1] https://patchwork.kernel.org/project/linux-samsung-soc/cover/20211204195757.8600-1-semen.protsenko@linaro.org/ Jaewon Kim (2): dt-bindings: i2c: exynos5: Add exynosautov9-hsi2c compatible i2c: exynos5: Add support for ExynosAutoV9 SoC Sam Protsenko (6): dt-bindings: i2c: exynos5: Convert to dtschema dt-bindings: i2c: exynos5: Add bus clock i2c: exynos5: Add bus clock support i2c: exynos5: Mention Exynos850 and ExynosAutoV9 in Kconfig arm: dts: exynos: Rename hsi2c nodes to i2c for Exynos5260 arm64: dts: exynos: Rename hsi2c nodes to i2c for Exynos5433 and Exynos7 .../devicetree/bindings/i2c/i2c-exynos5.txt | 53 ------- .../devicetree/bindings/i2c/i2c-exynos5.yaml | 133 ++++++++++++++++++ arch/arm/boot/dts/exynos5260.dtsi | 8 +- arch/arm64/boot/dts/exynos/exynos5433.dtsi | 24 ++-- arch/arm64/boot/dts/exynos/exynos7.dtsi | 24 ++-- drivers/i2c/busses/Kconfig | 2 +- drivers/i2c/busses/i2c-exynos5.c | 108 +++++++++++--- 7 files changed, 253 insertions(+), 99 deletions(-) delete mode 100644 Documentation/devicetree/bindings/i2c/i2c-exynos5.txt create mode 100644 Documentation/devicetree/bindings/i2c/i2c-exynos5.yaml