Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2829047imu; Mon, 19 Nov 2018 06:46:23 -0800 (PST) X-Google-Smtp-Source: AJdET5co+8hYDnnyMEQROr5MHAzKhcaISJMPj9y/zJYiVpavNbCCKLl2LwNektHTZs7w1Ooi4lJY X-Received: by 2002:a63:e445:: with SMTP id i5mr20372352pgk.307.1542638783110; Mon, 19 Nov 2018 06:46:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542638783; cv=none; d=google.com; s=arc-20160816; b=Bi4kMbk77VD0+Of76+gF83pSfC4OKVWDdprFUtDguGpRekqAT0U7FPUEOkfPrp1okR g/WxYIYYgiAZChkfRZKaaO+1TJCseWEtPgnQxP5IPPWd/mBT4OPHmiPLiKP4f6BSpDE1 aQa8cG0/QFo+LYH3WyftfOjbiF3OCF0KBr6ensaGxmoa+Ry3WB95jWhdmJMpom2Saiu5 OgdTxCKxRysAW4zU8FFhvKIIHu+StMbOcn8p1F3D7r+nNxj+uhP+mxk5RtPOBPC7E1Bp L/6X/RkEKDUatqfEYqfRshKfh6qobjugNXCmpofDuWD/DdFBDRlv5HvAE54SG3ELe8Jx yFrg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=r/LtMoviNCE1RxKfF1JMBRuUYT5+tb6df6jPNfr6dKg=; b=FgtdsRvFMa32n7Vfq19f0BCcQvx9ft/mdDptcmFkJqrXJdgG4i/EixTr83713yTRJW ypEfX9UbqnHVmXsBhOfLWH/QbnmxNJC+CPgXeAslrRVrG5FFanqwa8kRLlLCFgpgv4FI 2Ftvhq03D0qlUCTQxughiZ3WtyTHwOfrvVlI1wFQXefrP/eofWO5X/8VoNINAe2qTjC3 UlChVhkzimtlfwsx6szmHxtK93dh4O0JVoAnldg7ctlrUDw4sLm87uHTuD/0bH0J8rqE yarhZTgCzzd0Bel8xHXVsqCLtmljDKCJLnBUv30mdr5CvqlE1uE4It52lduHtTT85SXZ aQjA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a2si26657711pgd.461.2018.11.19.06.46.07; Mon, 19 Nov 2018 06:46:23 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729602AbeKTBHk (ORCPT + 99 others); Mon, 19 Nov 2018 20:07:40 -0500 Received: from mail.bootlin.com ([62.4.15.54]:49024 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729225AbeKTBHk (ORCPT ); Mon, 19 Nov 2018 20:07:40 -0500 Received: by mail.bootlin.com (Postfix, from userid 110) id 7F7BD20791; Mon, 19 Nov 2018 15:43:49 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.bootlin.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.2 Received: from bbrezillon (aaubervilliers-681-1-13-146.w90-88.abo.wanadoo.fr [90.88.134.146]) by mail.bootlin.com (Postfix) with ESMTPSA id 24C26206D8; Mon, 19 Nov 2018 15:43:39 +0100 (CET) Date: Mon, 19 Nov 2018 15:43:38 +0100 From: Boris Brezillon To: Marek Vasut Cc: Mason Yang , broonie@kernel.org, tpiepho@impinj.com, linux-kernel@vger.kernel.org, linux-spi@vger.kernel.org, linux-renesas-soc@vger.kernel.org, Simon Horman , juliensu@mxic.com.tw, Geert Uytterhoeven , zhengxunli@mxic.com.tw Subject: Re: [PATCH 2/2] dt-binding: spi: Document Renesas R-Car RPC controller bindings Message-ID: <20181119154338.2dfa7a5a@bbrezillon> In-Reply-To: References: <1542621690-10229-1-git-send-email-masonccyang@mxic.com.tw> <1542621690-10229-3-git-send-email-masonccyang@mxic.com.tw> <629a5d6f-5c13-9b24-1c21-461d09f1aa8a@gmail.com> <20181119151009.490413d9@bbrezillon> X-Mailer: Claws Mail 3.16.0 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 19 Nov 2018 15:14:07 +0100 Marek Vasut wrote: > On 11/19/2018 03:10 PM, Boris Brezillon wrote: > > On Mon, 19 Nov 2018 14:49:31 +0100 > > Marek Vasut wrote: > > > >> On 11/19/2018 11:01 AM, Mason Yang wrote: > >>> Document the bindings used by the Renesas R-Car D3 RPC controller. > >>> > >>> Signed-off-by: Mason Yang > >>> --- > >>> .../devicetree/bindings/spi/spi-renesas-rpc.txt | 33 ++++++++++++++++++++++ > >>> 1 file changed, 33 insertions(+) > >>> create mode 100644 Documentation/devicetree/bindings/spi/spi-renesas-rpc.txt > >>> > >>> diff --git a/Documentation/devicetree/bindings/spi/spi-renesas-rpc.txt b/Documentation/devicetree/bindings/spi/spi-renesas-rpc.txt > >>> new file mode 100644 > >>> index 0000000..8286cc8 > >>> --- /dev/null > >>> +++ b/Documentation/devicetree/bindings/spi/spi-renesas-rpc.txt > >>> @@ -0,0 +1,33 @@ > >>> +Renesas R-Car D3 RPC controller Device Tree Bindings > >>> +---------------------------------------------------- > >>> + > >>> +Required properties: > >>> +- compatible: should be "renesas,rpc-r8a77995" > >>> +- #address-cells: should be 1 > >>> +- #size-cells: should be 0 > >>> +- reg: should contain 2 entries, one for the registers and one for the direct > >>> + mapping area > >>> +- reg-names: should contain "rpc_regs" and "dirmap" > >>> +- interrupts: interrupt line connected to the RPC SPI controller > >> > >> Do you also plan to support the RPC HF mode ? And if so, how would that > >> look in the bindings ? > > > > Not sure this approach is still accepted, but that's how we solved the > > problem for the flexcom block [1]. > > > > [1]https://elixir.bootlin.com/linux/v4.20-rc3/source/Documentation/devicetree/bindings/mfd/atmel-flexcom.txt > > That looks pretty horrible. > > In U-Boot we check whether the device hanging under the controller node > is JEDEC SPI flash or CFI flash and based on that decide what the config > of the controller should be (SPI or HF). Not sure that's much better,but > at least it doesn't need extra nodes which do not really represent any > kind of real hardware. > The subnodes are not needed, you can just have a property that tells in which mode the controller is supposed to operate, and the MFD would create a sub-device that points to the same device_node. Or we can have a single driver that decides what to declare (a spi_controller or flash controller), but you'd still have to decide where to place this driver...