Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp2599767rwr; Sat, 6 May 2023 15:03:37 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7m9brkR7dt0slL3+mHDn4+4gdiCNBrp+O1ncn3uzifi7rVgsZNbuhlk6PmH6/ZZ0/OAHLc X-Received: by 2002:a05:6a21:2d05:b0:ed:1355:f88a with SMTP id tw5-20020a056a212d0500b000ed1355f88amr5511874pzb.46.1683410617472; Sat, 06 May 2023 15:03:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683410617; cv=none; d=google.com; s=arc-20160816; b=rgPEjqca8yb9aWrzz8dAqO/eydIVY3mcBQLPBPclF/VWSlWVhmlLFTm7PTHA1OgfA1 HHp3LZzIrhZ8vp32GVOZyQah9bie7KVUn1F1aQ++pB0Wqdx3x0fwEA+TtJVh6uqyhGWc uHhXSFUjjX3vrYDSIzEk2O1p/UM3IgkzWK6D55naEqeb5J0ZRGp8Fh3O/dLwEkAk83OV sDyIzpMHUcHsy9FyiDwQCPYJx2WHwgy2cGSoxZ16xrhDM6dLcYpOwTC/B4h0CjGs30GA N+VRUpKqhvjVnfFpr94Ut3hQtv+Y+UYmksHJpDgz7qf1+18OcJY+viNipZeJj+cdlImX 26mA== 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 :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=BlSXKa3QBpz0AE7bUzu4R+U5P5DXAZOLeOOVyy0FUko=; b=EP3kDpT5VmB9G8pWdcyJfvNUFtfFetY4QjTvWuHEXWn/rPkqps8tb9ZOnypFcaWFKY v1T0SB04cqtkNEpYie0drvNgvRDsJWZdMZQw9Ya0w5yqozTXVXHFQn5UdMzNmQf9NKsJ bGo4s+3RIZ32TL5IXM73ECwCa658JBGmWVgRAcMvVsB65SRID5JizE6jXGmQ60rhYh+2 /5zW1/cRqe+E+7FgDA2BnA7JP0GBRYmq58y0nTTvSsXo6qKunxDEcDEmqCFJ9WwTTYZO z06frtWmOqFw9ZToeYXx5eEQl7ah/AQVV+ui9h9gsqmLrbiN0ZJ9+mmV/6QXN5s0Ay5M m93Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r25-20020aa79639000000b0063d30bb0aa7si5167269pfg.381.2023.05.06.15.03.22; Sat, 06 May 2023 15:03:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229577AbjEFV6d (ORCPT + 99 others); Sat, 6 May 2023 17:58:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50616 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229441AbjEFV6c (ORCPT ); Sat, 6 May 2023 17:58:32 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 13D0F191E6; Sat, 6 May 2023 14:58:31 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id EC8FC1FB; Sat, 6 May 2023 14:59:14 -0700 (PDT) Received: from slackpad.lan (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 364DF3F5A1; Sat, 6 May 2023 14:58:27 -0700 (PDT) Date: Sat, 6 May 2023 22:58:11 +0100 From: Andre Przywara To: Krzysztof Kozlowski Cc: Maksim Kiselev , Icenowy Zheng , Mark Brown , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Paul Walmsley , Palmer Dabbelt , Albert Ou , Cristian Ciocaltea , Heiko Stuebner , Maxime Ripard , linux-spi@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org Subject: Re: [PATCH v2 1/6] dt-bindings: spi: sun6i: add DT bindings for Allwinner R329 SPI Message-ID: <20230506225811.4e928e46@slackpad.lan> In-Reply-To: References: <20230506073018.1411583-1-bigunclemax@gmail.com> <20230506073018.1411583-2-bigunclemax@gmail.com> Organization: Arm Ltd. X-Mailer: Claws Mail 4.1.0 (GTK 3.24.31; x86_64-slackware-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 6 May 2023 12:53:07 +0200 Krzysztof Kozlowski wrote: Hi Maksim, > On 06/05/2023 09:30, Maksim Kiselev wrote: > > From: Icenowy Zheng > > > > Allwinner R329 SPI has two controllers, and the second one has helper > > functions for MIPI-DBI Type C. > > I wonder what is the difference of DBI compatible. You refer to "helper > functions", which sounds like driver... do you mean some parts of SPI > controller? So I checked the manuals, all of the D1, T113-s and R329 are the same in this respect: - There are two SPI controllers, the "first" one is what this series fully supports. - The second SPI controller has some additional registers and two extra bits in the control register to drive the DBI extension, but is otherwise compatible to the first one: So I'd suggest to introduce the following compatible string combinations to the binding *now*. We don't support the DBI bits (yet), but this would be the correct hardware description: For the R329: spi0: spi@4025000 { compatible = "allwinner,sun50i-r329-spi"; .... spi1: spi@4026000 { compatible = "allwinner,sun50i-r329-spi-dbi", "allwinner,sun50i-r329-spi"; For the D1/T113s: spi0: spi@4025000 { compatible = "allwinner,sun20i-d1-spi", "allwinner,sun50i-r329-spi"; .... spi1: spi@4026000 { compatible = "allwinner,sun20i-d1-spi-dbi", "allwinner,sun50i-r329-spi-dbi", "allwinner,sun50i-r329-spi"; I leave that as an exercise to the reader to convert that into the minimal set of DT schema lines ;-) I would suggest to add both the D1/T113s and the R329 bindings in this one patch, to reduce the churn. I guess if you do this, you could even drop Icenowy's authorship on this patch, since it has not much to do with the original version anymore. Cheers, Andre > > Add compatible strings for these controllers > > > > Signed-off-by: Icenowy Zheng > > > --- > > .../devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml | 2 ++ > > 1 file changed, 2 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml b/Documentation/devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml > > index de36c6a34a0f..2c1b8da35339 100644 > > --- a/Documentation/devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml > > +++ b/Documentation/devicetree/bindings/spi/allwinner,sun6i-a31-spi.yaml > > @@ -21,6 +21,8 @@ properties: > > oneOf: > > - const: allwinner,sun6i-a31-spi > > - const: allwinner,sun8i-h3-spi > > + - const: > > + - const: allwinner,sun50i-r329-spi-dbi > > As Conor pointed out, nothing improved here. > > Best regards, > Krzysztof >