Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3854519pxv; Mon, 19 Jul 2021 10:19:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyJ7tC7U2x7IZzsc3S8o8IrXhT7OBkRd9bxypzaTtobmGNnjQ453Vt/Y9E6chgi99AkINd+ X-Received: by 2002:a05:6402:22e1:: with SMTP id dn1mr36122038edb.8.1626715151761; Mon, 19 Jul 2021 10:19:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626715151; cv=none; d=google.com; s=arc-20160816; b=lFcEJVj9/WX4Gocpd+RjX1SYoqgG35CcqT2CFvfwvu67tR4ED9DnnKdjqGYVBtYPLI sfpR48qV9wn/sSTj8kTODfiy9ujg6OrzGIbjQRSaA4+T4t9xqJYic2PPIXyWIE2eglf5 amH3kxJsM8xb5wfzhDr03OhhXiJs3+7aSIiZMTT0De2L0zxo13+JesOqW/weqh3kx+ak 3HMretTOX9uAgoXeq9ssWm3N1XhLaU+U4KpCGCEZme6ew5j2QqWYdUJz1MR4EE2F5KQ1 HHb5yrPG7/+83Iz7+WWVX+2QseyMr4PLTU6a3VWw/5HmZwGthLptVgL5jEK6GLHHuvtU zsVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=s8BlVg02Kb1hEnuoqIQg9TlGP35aV75iFaGnqwM8lMU=; b=rGkDVnKpc3dCAK9F8vVhJTNcOd+MoAl9yQkSQm9F1I+0ZvC4YFzrc+z+Ezp32N5WlG 6O4oxiA0z+Mr4Dte3Ggvguw1tN5G2+I0QL1dYIGlxEpCEFdFH4iYhsjebUxfkXjbBALA 0mzlMYoRcQRJFR2UGaB8tacrk9nBnnlizzBx9Jz7vfX70LKLeZDD6JytD4kUFIK2/l3i s0rFB0oLETfbj0+wNjAN8u7b3WxtzNNlOj5l3xIIgbsWGTc2/65TKcEZe4/S/J2vfv3S WUG/zxaAcDc+ORbGF7VcUkdacyPVfwfh33NnqJfNYkqOLOTr+9TYjKlaDnRtjp+5lJvj Xedg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=YjPawnB5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g1si10240863ejb.43.2021.07.19.10.18.47; Mon, 19 Jul 2021 10:19:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=YjPawnB5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1355467AbhGSQgU (ORCPT + 99 others); Mon, 19 Jul 2021 12:36:20 -0400 Received: from mail.kernel.org ([198.145.29.99]:40696 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348060AbhGSPYd (ORCPT ); Mon, 19 Jul 2021 11:24:33 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id E5BB461406; Mon, 19 Jul 2021 16:01:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1626710461; bh=sYAem16VqUqLD/uB6TbBoCxDXXCGI+F8rq4lvRX6WMU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=YjPawnB57zFxAL9OQsTBDe64NDlJmaO6jL2HV66vxHZNmDHO5sdDxRMXErc7PXGos TE93VL1Bc6ryBRsRRUf5o4z80O04KNKlEHpi+a4FtqMfpVIjBl12LPYjhbt2huqMu/ wS3O+86B+QtGiD9JHi0EAPgfap5+J4cqzkMDF09s= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Christoph Niedermaier , Shawn Guo , Fabio Estevam , Marek Vasut , NXP Linux Team , kernel@dh-electronics.com, Sasha Levin Subject: [PATCH 5.10 227/243] ARM: dts: imx6q-dhcom: Add gpios pinctrl for i2c bus recovery Date: Mon, 19 Jul 2021 16:54:16 +0200 Message-Id: <20210719144948.249498890@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210719144940.904087935@linuxfoundation.org> References: <20210719144940.904087935@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Christoph Niedermaier [ Upstream commit ddc873cd3c0af4faad6a00bffda21c3f775126dd ] The i2c bus can freeze at the end of transaction so the bus can no longer work. This scenario is improved by adding scl/sda gpios definitions to implement the i2c bus recovery mechanism. Fixes: 52c7a088badd ("ARM: dts: imx6q: Add support for the DHCOM iMX6 SoM and PDK2") Signed-off-by: Christoph Niedermaier Cc: Shawn Guo Cc: Fabio Estevam Cc: Marek Vasut Cc: NXP Linux Team Cc: kernel@dh-electronics.com To: linux-arm-kernel@lists.infradead.org Signed-off-by: Shawn Guo Signed-off-by: Sasha Levin --- arch/arm/boot/dts/imx6q-dhcom-som.dtsi | 36 +++++++++++++++++++++++--- 1 file changed, 33 insertions(+), 3 deletions(-) diff --git a/arch/arm/boot/dts/imx6q-dhcom-som.dtsi b/arch/arm/boot/dts/imx6q-dhcom-som.dtsi index 6043be73a1a8..e3de2b487cf4 100644 --- a/arch/arm/boot/dts/imx6q-dhcom-som.dtsi +++ b/arch/arm/boot/dts/imx6q-dhcom-som.dtsi @@ -105,22 +105,31 @@ &i2c1 { clock-frequency = <100000>; - pinctrl-names = "default"; + pinctrl-names = "default", "gpio"; pinctrl-0 = <&pinctrl_i2c1>; + pinctrl-1 = <&pinctrl_i2c1_gpio>; + scl-gpios = <&gpio3 21 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>; + sda-gpios = <&gpio3 28 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>; status = "okay"; }; &i2c2 { clock-frequency = <100000>; - pinctrl-names = "default"; + pinctrl-names = "default", "gpio"; pinctrl-0 = <&pinctrl_i2c2>; + pinctrl-1 = <&pinctrl_i2c2_gpio>; + scl-gpios = <&gpio4 12 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>; + sda-gpios = <&gpio4 13 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>; status = "okay"; }; &i2c3 { clock-frequency = <100000>; - pinctrl-names = "default"; + pinctrl-names = "default", "gpio"; pinctrl-0 = <&pinctrl_i2c3>; + pinctrl-1 = <&pinctrl_i2c3_gpio>; + scl-gpios = <&gpio1 3 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>; + sda-gpios = <&gpio1 6 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>; status = "okay"; ltc3676: pmic@3c { @@ -286,6 +295,13 @@ >; }; + pinctrl_i2c1_gpio: i2c1-gpio-grp { + fsl,pins = < + MX6QDL_PAD_EIM_D21__GPIO3_IO21 0x4001b8b1 + MX6QDL_PAD_EIM_D28__GPIO3_IO28 0x4001b8b1 + >; + }; + pinctrl_i2c2: i2c2-grp { fsl,pins = < MX6QDL_PAD_KEY_COL3__I2C2_SCL 0x4001b8b1 @@ -293,6 +309,13 @@ >; }; + pinctrl_i2c2_gpio: i2c2-gpio-grp { + fsl,pins = < + MX6QDL_PAD_KEY_COL3__GPIO4_IO12 0x4001b8b1 + MX6QDL_PAD_KEY_ROW3__GPIO4_IO13 0x4001b8b1 + >; + }; + pinctrl_i2c3: i2c3-grp { fsl,pins = < MX6QDL_PAD_GPIO_3__I2C3_SCL 0x4001b8b1 @@ -300,6 +323,13 @@ >; }; + pinctrl_i2c3_gpio: i2c3-gpio-grp { + fsl,pins = < + MX6QDL_PAD_GPIO_3__GPIO1_IO03 0x4001b8b1 + MX6QDL_PAD_GPIO_6__GPIO1_IO06 0x4001b8b1 + >; + }; + pinctrl_pmic_hw300: pmic-hw300-grp { fsl,pins = < MX6QDL_PAD_EIM_A25__GPIO5_IO02 0x1B0B0 -- 2.30.2