From patchwork Fri Aug 12 16:38:40 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geert Uytterhoeven X-Patchwork-Id: 9277453 X-Patchwork-Delegate: horms@verge.net.au Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B103F60CDC for ; Fri, 12 Aug 2016 16:39:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A3DB928AA7 for ; Fri, 12 Aug 2016 16:39:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 98DD428AAA; Fri, 12 Aug 2016 16:39:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4D5E328AA7 for ; Fri, 12 Aug 2016 16:39:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752927AbcHLQjD (ORCPT ); Fri, 12 Aug 2016 12:39:03 -0400 Received: from albert.telenet-ops.be ([195.130.137.90]:50833 "EHLO albert.telenet-ops.be" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752904AbcHLQi5 (ORCPT ); Fri, 12 Aug 2016 12:38:57 -0400 Received: from ayla.of.borg ([84.193.137.253]) by albert.telenet-ops.be with bizsmtp id WGet1t0015UCtCs06GetpL; Fri, 12 Aug 2016 18:38:53 +0200 Received: from ramsan.of.borg ([192.168.97.29] helo=ramsan) by ayla.of.borg with esmtp (Exim 4.82) (envelope-from ) id 1bYFTw-0006EB-W8; Fri, 12 Aug 2016 18:38:52 +0200 Received: from geert by ramsan with local (Exim 4.82) (envelope-from ) id 1bYFTy-0007aC-7S; Fri, 12 Aug 2016 18:38:54 +0200 From: Geert Uytterhoeven To: linux-renesas-soc@vger.kernel.org Cc: linux-spi@vger.kernel.org, linux-clk@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH/PROTO 4/9 common] arm64: dts: salvator-x: Add dummy MSIOF SPI slave devices Date: Fri, 12 Aug 2016 18:38:40 +0200 Message-Id: <1471019925-29083-5-git-send-email-geert+renesas@glider.be> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1471019925-29083-1-git-send-email-geert+renesas@glider.be> References: <1471019925-29083-1-git-send-email-geert+renesas@glider.be> Sender: linux-renesas-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Declares three SPI slave devices on three different MSIOF instances: - high-speed (30 MHz), - medium-speed (1 MHz), - low-speed (20 kHz). The maximum frequencies are chosen such that the optimal parent clock frequency for the high-speed device is outside of the allowed range for the low-speed device. Reorder the devices by changing the "&msiofX" references to investigate different probe order. Not-Signed-off-by: Geert Uytterhoeven --- Not intended for upstream merge. --- arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts | 74 ++++++++++++++++++++++ 1 file changed, 74 insertions(+) diff --git a/arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts b/arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts index 4ef4a712671b2579..9040a691b8b61887 100644 --- a/arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts +++ b/arch/arm64/boot/dts/renesas/r8a7795-salvator-x.dts @@ -45,6 +45,10 @@ serial2 = &scif3; serial3 = &hscif3; ethernet0 = &avb; + spi0 = &msiof0; + spi1 = &msiof1; + spi2 = &msiof2; + spi3 = &msiof3; }; chosen { @@ -182,6 +186,24 @@ function = "avb"; }; + msiof0_pins: msiof0 { + groups = "msiof0_clk", "msiof0_sync", "msiof0_rxd", + "msiof0_txd"; + function = "msiof0"; + }; + + msiof2_pins: msiof2 { + groups = "msiof2_clk_b", "msiof2_sync_b", "msiof2_rxd_b", + "msiof2_txd_b"; + function = "msiof2"; + }; + + msiof3_pins: msiof3 { + groups = "msiof3_clk_a", "msiof3_sync_a", "msiof3_rxd_a", + "msiof3_txd_a"; + function = "msiof3"; + }; + sdhi0_pins: sd0 { groups = "sdhi0_data4", "sdhi0_ctrl"; function = "sdhi0"; @@ -455,3 +477,55 @@ &pciec1 { status = "okay"; }; + +/* Dummy high-speed SPI slave device */ +&msiof0 { + pinctrl-0 = <&msiof0_pins>; + pinctrl-names = "default"; + + status = "okay"; + + flash@0 { + compatible = "jedec,spi-nor"; + //compatible = "spidev"; + reg = <0>; + + spi-max-frequency = <30000000>; + }; +}; + +/* Dummy medium-speed SPI slave device */ +&msiof2 { + pinctrl-0 = <&msiof2_pins>; + pinctrl-names = "default"; + + status = "okay"; + + spidev@0 { + //compatible = "jedec,spi-nor"; + compatible = "spidev"; + reg = <0>; + + spi-max-frequency = <1000000>; + }; +}; + +/* Dummy low-speed SPI slave device */ +&msiof3 { + pinctrl-0 = <&msiof3_pins>; + pinctrl-names = "default"; + + status = "okay"; + + gpio@0 { + compatible = "fairchild,74hc595"; + //compatible = "jedec,spi-nor"; + //compatible = "spidev"; + reg = <0>; + + gpio-controller; + #gpio-cells = <2>; + registers-number = <2>; + spi-max-frequency = <20000>; + }; +};