From patchwork Mon Jan 6 16:06:38 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ahmad Fatoum X-Patchwork-Id: 13927660 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D19E9E77188 for ; Mon, 6 Jan 2025 16:17:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References :Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=07Rlfugw1309P93pwbPtMaeiJltL+3kc9UKGH3g2QTg=; b=zfJDGVVarsr8AGMlFHvFIYEFHw flIEJFeUuMMBZ9oLJCH2/tlc1mVkkwiC2Kw4tqG4DQzd+2YXW8OevbOQHq5cWk87YuJXCiGrM50F+ dw9CGzyf8lOtLrCDtKlrkQ0V9zZQ3r3EMiLXm9R4OV5azA3qGccHNSK8vsa1tIENPZESDlt2ecrBI 21Kj5K9XW2u4fPtXBKlQfYNayB/4vdLJ3wnr4Q3K5EEbMm5LwOY0UsiwLVQvaCGHj+vQ6pvQyTgNz BnWOTeLO10OqUq3PDvZr58gpQlGXknjwmRC1LHhZiUntTu05Rg2WjWSa3zLNM2Rov2I/oKjez7wxW vKaw3e4g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1tUpnP-00000001v0t-3n7p; Mon, 06 Jan 2025 16:17:39 +0000 Received: from desiato.infradead.org ([2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1tUpdQ-00000001taO-3Snp for linux-arm-kernel@bombadil.infradead.org; Mon, 06 Jan 2025 16:07:20 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Cc:To:In-Reply-To:References: Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Sender:Reply-To:Content-ID:Content-Description; bh=07Rlfugw1309P93pwbPtMaeiJltL+3kc9UKGH3g2QTg=; b=AoEd+nnUrEIKwqLantfVUDzvAw a1D5bjzSu2PtyjiqLj6hIV3TGgPEqyYqzYtcykHwBlNqY7yM4ICC7WOSw9QAgEYjYJqnstsSgIsKO AzCHeXdDqGz9149QrouzDrBbRzTpkW0kAAL4NOGhULxTzSvf09U3XC2+6G4uwyFAyK5BuPV/2CBKN Bt5pv9T7p0U1F2LlAdRAc89lNUL8mMcv6HIOisMJfP/xJ0u+eCd4JA3nCV94HdnhvCTsaHKgC/+kg M80UVMTCew9xf+8bZMc0TFGrRTFqWbQZKJpbpzoM59aKB9cuvSCIgALizZWw835IskZTUCNH5NIvw nlU1cbyg==; Received: from metis.whiteo.stw.pengutronix.de ([2a0a:edc0:2:b01:1d::104]) by desiato.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1tUpdN-00000008xqn-1Wmj for linux-arm-kernel@lists.infradead.org; Mon, 06 Jan 2025 16:07:19 +0000 Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1tUpcx-0000C6-KC; Mon, 06 Jan 2025 17:06:51 +0100 Received: from dude05.red.stw.pengutronix.de ([2a0a:edc0:0:1101:1d::54]) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1tUpcw-007C9n-0y; Mon, 06 Jan 2025 17:06:51 +0100 Received: from localhost ([::1] helo=dude05.red.stw.pengutronix.de) by dude05.red.stw.pengutronix.de with esmtp (Exim 4.96) (envelope-from ) id 1tUpcw-009dVc-34; Mon, 06 Jan 2025 17:06:50 +0100 From: Ahmad Fatoum Date: Mon, 06 Jan 2025 17:06:38 +0100 Subject: [PATCH v2 03/10] arm64: dts: imx8mp-skov: use I2C5 for DDC MIME-Version: 1.0 Message-Id: <20250106-skov-dt-updates-v2-3-4504d3f00ecb@pengutronix.de> References: <20250106-skov-dt-updates-v2-0-4504d3f00ecb@pengutronix.de> In-Reply-To: <20250106-skov-dt-updates-v2-0-4504d3f00ecb@pengutronix.de> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Oleksij Rempel Cc: devicetree@vger.kernel.org, imx@lists.linux.dev, Frank Li , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, kernel@pengutronix.de, Ahmad Fatoum X-Mailer: b4 0.14.2 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: a.fatoum@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-arm-kernel@lists.infradead.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20250106_160717_923932_89FDCBDE X-CRM114-Status: GOOD ( 13.53 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The HDMI DDC pads can be muxed either to an i.MX I2C controller or to a limited I2C controller within the Designware HDMI bridge. So far, the pads were muxed to the HDMI bridge, but the i.MX I2C controller is the better choice: - The Designware HDMI I2C controller doesn't support multi-byte requests and the Linux driver refuses[1] transfers to/from address 0x37, but these are required for display/brightness configuration, - The driver doesn't support I2C bus recovery, but some HDMI panels used with the board can be flaky and require it. As the i.MX I2C controller and driver don't have either of these limitations, let's make use of it instead. [1]: https://lore.kernel.org/all/20190722181945.244395-1-mka@chromium.org/ Signed-off-by: Ahmad Fatoum --- v1 -> v2: - use passive voice instead of "we" (Frank) --- .../boot/dts/freescale/imx8mp-skov-revb-hdmi.dts | 26 ++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/freescale/imx8mp-skov-revb-hdmi.dts b/arch/arm64/boot/dts/freescale/imx8mp-skov-revb-hdmi.dts index c1ca69da3cb8edf5424b727e3ba8bb74affe8e93..206116be816662349ef5b54e288b945f171f5637 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp-skov-revb-hdmi.dts +++ b/arch/arm64/boot/dts/freescale/imx8mp-skov-revb-hdmi.dts @@ -9,12 +9,34 @@ / { compatible = "skov,imx8mp-skov-revb-hdmi", "fsl,imx8mp"; }; +&i2c5 { + pinctrl-names = "default", "gpio"; + pinctrl-0 = <&pinctrl_i2c5>; + pinctrl-1 = <&pinctrl_i2c5_gpio>; + scl-gpios = <&gpio3 26 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>; + sda-gpios = <&gpio3 27 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>; + clock-frequency = <100000>; + status = "okay"; +}; + &iomuxc { pinctrl_hdmi: hdmigrp { fsl,pins = < - MX8MP_IOMUXC_HDMI_DDC_SCL__HDMIMIX_HDMI_SCL 0x1c3 - MX8MP_IOMUXC_HDMI_DDC_SDA__HDMIMIX_HDMI_SDA 0x1c3 MX8MP_IOMUXC_HDMI_HPD__HDMIMIX_HDMI_HPD 0x19 >; }; + + pinctrl_i2c5: i2c5grp { + fsl,pins = < + MX8MP_IOMUXC_HDMI_DDC_SCL__I2C5_SCL 0x400001c2 + MX8MP_IOMUXC_HDMI_DDC_SDA__I2C5_SDA 0x400001c2 + >; + }; + + pinctrl_i2c5_gpio: i2c5gpiogrp { + fsl,pins = < + MX8MP_IOMUXC_HDMI_DDC_SCL__GPIO3_IO26 0x400001c2 + MX8MP_IOMUXC_HDMI_DDC_SDA__GPIO3_IO27 0x400001c2 + >; + }; };