From mboxrd@z Thu Jan 1 00:00:00 1970 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 8AE0FC7EE2C for ; Fri, 2 Jun 2023 13:19:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236063AbjFBNT1 (ORCPT ); Fri, 2 Jun 2023 09:19:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37044 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235849AbjFBNT0 (ORCPT ); Fri, 2 Jun 2023 09:19:26 -0400 Received: from mail-ed1-x531.google.com (mail-ed1-x531.google.com [IPv6:2a00:1450:4864:20::531]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 603FCE68 for ; Fri, 2 Jun 2023 06:19:04 -0700 (PDT) Received: by mail-ed1-x531.google.com with SMTP id 4fb4d7f45d1cf-51640b9ed95so552261a12.2 for ; Fri, 02 Jun 2023 06:19:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1685711943; x=1688303943; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=AL6U3/LQtPsSpL2edMdeHjfgSwujh1CtL4Li08D5DHs=; b=pyC6LRH2rMaASgz2UmMPd3ADLZrFuBVBFLUOOXcAxWFnky8vafdBQsVIyqsfgiogcb yo4FW5xHchmJUazBm3DBNYDPE3BepBXNEERQXVmgiZkwITQ0ZnmVihzPn86TjW5OFMF/ QLrPoPEbcoKXIenJ6OPJi8Rthh4JRXih5OTCmKLPHzaO5Q+ss0UMQcJpe6dLbRN6v8i+ 3cDjQzXg4XPOPBxJArZoOthApo8ZORoAEloRP7SHNG3MJzJdG6IH5KMb2lpUzKNx3R73 4TllygpfqMPP+owJl6MIa5i28NgAj2KPC34C61ykSM3ip1HImbFBWuLUJUsQrAv1jyh3 6cAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685711943; x=1688303943; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=AL6U3/LQtPsSpL2edMdeHjfgSwujh1CtL4Li08D5DHs=; b=F8XCXw2P+PATq6+sCWS3wz217sr4VkM/kQxI4EFfvN83EcdqnveJOyRRa5VqLBornP 9W9TxoFqaddlf8XinktZ5qVuVn4ccOxXY/1dXCnF4CWDMFiC0DBQOqbJ2EitVLz6ZmvY R9n1JP1mGXa2LWx7KBMUk5z3CqffzWAPVToSlRQw2nAlNRhyvxLCbRstr69BCtmBG/md 637IVLnVEghkyaoEA5pbVQsuPpCbakeNg9RQZf7Tvn02vfTKd/lJCdzKX8FbcPx8uHUC eew0VQ9Y+tIM6xd1OrCz9hWLI5ikk2MhcfXQVTfB7HArlpYa2ZL2PAMF4mj/YolsSQlj Bl5g== X-Gm-Message-State: AC+VfDxMTcs7qbb8mIwYah7W3ndSdza6DQYCHMCYTG1PAfPfK36IlFrJ JjhMr+vjgSD7w7M/ig2rT6HWog== X-Google-Smtp-Source: ACHHUZ4lfHUVchhkj0FLIuh1zMCNcKzc073RQWJcEmJpWsqUawWDIMPhIfzIQDTofF7iZBwWVjkUCw== X-Received: by 2002:a05:6402:1513:b0:50b:fb29:1d8f with SMTP id f19-20020a056402151300b0050bfb291d8fmr1941563edw.0.1685711942755; Fri, 02 Jun 2023 06:19:02 -0700 (PDT) Received: from [192.168.1.20] ([178.197.199.204]) by smtp.gmail.com with ESMTPSA id l5-20020aa7d945000000b00516323ef3a9sm677267eds.49.2023.06.02.06.19.00 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 02 Jun 2023 06:19:02 -0700 (PDT) Message-ID: <5b537617-a9cb-609b-790d-3dda4b3933ec@linaro.org> Date: Fri, 2 Jun 2023 15:18:59 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.2 From: Krzysztof Kozlowski Subject: Re: [EXT] Re: [PATCH 2/2] dt-bindings: i2c: imx-lpi2c: Add bus recovery example To: Carlos Song , Aisheng Dong , "shawnguo@kernel.org" , "s.hauer@pengutronix.de" , "kernel@pengutronix.de" , "festevam@gmail.com" , "robh+dt@kernel.org" , "krzysztof.kozlowski+dt@linaro.org" , "conor+dt@kernel.org" , "Anson.Huang@nxp.com" Cc: Clark Wang , Bough Chen , dl-linux-imx , "linux-i2c@vger.kernel.org" , "devicetree@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" References: <20230529074302.3612294-1-carlos.song@nxp.com> <20230529074302.3612294-2-carlos.song@nxp.com> Content-Language: en-US In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Resending as my previous email probably got lost. If you got it twice, apologies. On 31/05/2023 12:22, Carlos Song wrote: > Hi, > Thanks for you reply. >> -----Original Message----- >> From: Krzysztof Kozlowski >> Sent: Tuesday, May 30, 2023 10:59 PM >> To: Carlos Song ; Aisheng Dong >> ; shawnguo@kernel.org; s.hauer@pengutronix.de; >> kernel@pengutronix.de; festevam@gmail.com; robh+dt@kernel.org; >> krzysztof.kozlowski+dt@linaro.org; conor+dt@kernel.org; >> Anson.Huang@nxp.com >> Cc: Clark Wang ; Bough Chen >> ; dl-linux-imx ; >> linux-i2c@vger.kernel.org; devicetree@vger.kernel.org; >> linux-arm-kernel@lists.infradead.org; linux-kernel@vger.kernel.org >> Subject: [EXT] Re: [PATCH 2/2] dt-bindings: i2c: imx-lpi2c: Add bus recovery >> example >> >> Caution: This is an external email. Please take care when clicking links or >> opening attachments. When in doubt, report the message using the 'Report this >> email' button >> >> >> On 29/05/2023 09:43, carlos.song@nxp.com wrote: >>> From: Clark Wang >>> >>> Add i2c bus recovery configuration example. >> >> Why? That's just example... also with coding style issue. >> >>> >>> Signed-off-by: Clark Wang >>> Signed-off-by: Carlos Song >>> --- >>> .../devicetree/bindings/i2c/i2c-imx-lpi2c.yaml | 16 ++++++++++++++++ >>> 1 file changed, 16 insertions(+) >>> >>> diff --git a/Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml >>> b/Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml >>> index 4656f5112b84..62ee457496e4 100644 >>> --- a/Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml >>> +++ b/Documentation/devicetree/bindings/i2c/i2c-imx-lpi2c.yaml >>> @@ -58,6 +58,16 @@ properties: >>> power-domains: >>> maxItems: 1 >>> >>> + pinctrl-names: >>> + minItems: 1 >>> + maxItems: 3 >> >> What's the benefit of this? Entries should be defined but without it is not really >> helpful. Anyway not explained in commit msg. >> >>> + >>> + scl-gpios: >>> + maxItems: 1 >>> + >>> + sda-gpios: >>> + maxItems: 1 >> >> You don't need these two. Anyway not explained in commit msg. >> > > Sorry for confusing you with the poor commit log and without > full description. > > The reason why we need sending the patch for dt-binding is : > We sent out a patch for I.MX LPI2C bus support recovery function. > When LPI2C use recovery function, lpi2c controller need to switch the > SCL pin and SDA pin to their GPIO function. So I think the scl-gpio and > sda-gpio property need to be added in the dt-bindings. Why do you think they are not in the bindings already? > > And alternative pinmux settings are described in a separate pinctrl state "gpio". > So maybe "gpio" pinctrl item need to be added. > > I would like to know whether the above changes are really unnecessary according to above case? > Or because of the vague commit log, you are misled and think that our patch is not necessary to add examples. I claim your patch has zero effect. Can you prove otherwise? Proof is with DTS example and result of dtbs_check. > > Is there no need to add sda/scl-gpios property or no need to add maxItems: 1? I think entire patch can be dropped. > We also find the sci-gpio and sda-gpio have been defined in the ref: /schemas/i2c/i2c-controller.yaml. > So is this the root cause of no need to add these properties? Yes. Best regards, Krzysztof