Received: by 10.192.165.148 with SMTP id m20csp1621136imm; Thu, 10 May 2018 13:45:02 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrjlwne9RkkrET6AO6FVjATBfsnSkT5eDsIIyPI2pqxEQQF6tHlqnr22GGVqALPBCsJGlJ5 X-Received: by 2002:a17:902:da4:: with SMTP id 33-v6mr2734440plv.52.1525985102222; Thu, 10 May 2018 13:45:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525985102; cv=none; d=google.com; s=arc-20160816; b=vNcJt0jE2yrHp9X+jhlbpMOL5P/NpippbkqOq8F6af/9c73kfpVcMV4kxDiAQR9W3H rStxcKBWoz02vCOGW3CyBjFlRKnidnaohwzaLggfql1c4t4A2o8xrQ+bzPkPDTP2Ec58 gpufRFTyWzWGI7Cp02M2m72QtT3ASR5dlT/auEi/beI5o+VvtnCaelVHpoZJhsCFJbCt qUzh9765E1Gj28wiSunzvsuqkCuxAHU/1uvnQQj5194iY6N8b5DiH19BgyPQTHL5WX6J ifpeaw77ksfG01MXj5oXHC4kGVINVjZ98cVX9EjfB3/RTKIxgwGJuftwtsuV33ALG9Mr puAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=LaF7f9BU8SqJd9wh0TpcU7iJm4o7hZuEEoXtQYhcOvI=; b=IyRfLsnqoy915JJPJH3HnfN6rJVS4hr8ifaruEGqLORylMBkvvf6S3WIMjKtvPBImb /OfWyGQKY1BfboFw7IdBVt9iib2ROjkmwCx25KXIVvqvR431vyKgCpXbtckunJHolRZI 9AgQ/18BppXINmSoDJvOpzv+OKwtS4jigsV9NGHZueZTddVyRmZ79YQMbOBqI+edDps6 7wlTyJ3Pcfai0i43QbAPPhKCe2oiydDaXI61kVCO40cZFwL0bRQgCmYTOapVjfRRYKrY 3IXKH1FPtQX5RdnbiAskWxWCH037qQM5NFC5qyXqL9IvMtvNbNWcGHlw7YoJYeaCIPCN YYZw== 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 69-v6si1336388pgc.64.2018.05.10.13.44.35; Thu, 10 May 2018 13:45:02 -0700 (PDT) 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 S1752345AbeEJUoX (ORCPT + 99 others); Thu, 10 May 2018 16:44:23 -0400 Received: from mga12.intel.com ([192.55.52.136]:59217 "EHLO mga12.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751963AbeEJUoV (ORCPT ); Thu, 10 May 2018 16:44:21 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 May 2018 13:44:21 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,386,1520924400"; d="scan'208";a="40007063" Received: from tthayer-hp-z620-workstation.an.intel.com ([10.122.105.144]) by orsmga007.jf.intel.com with ESMTP; 10 May 2018 13:44:19 -0700 From: thor.thayer@linux.intel.com To: dinguyen@kernel.org, robh+dt@kernel.org, mark.rutland@arm.com Cc: catalin.marinas@arm.com, will.deacon@arm.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Thor Thayer Subject: [PATCH] arm64: dts: stratix10: Add QSPI support for Stratix10 Date: Thu, 10 May 2018 15:46:44 -0500 Message-Id: <1525985204-11525-1-git-send-email-thor.thayer@linux.intel.com> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Thor Thayer Add qspi_clock The qspi_clk frequency is updated by U-Boot before starting Linux. Add QSPI interface node. Add QSPI flash memory child node. Setup the QSPI memory in 2 partitions. Signed-off-by: Thor Thayer --- arch/arm64/boot/dts/altera/socfpga_stratix10.dtsi | 22 +++++++++++++++ .../boot/dts/altera/socfpga_stratix10_socdk.dts | 31 ++++++++++++++++++++++ 2 files changed, 53 insertions(+) diff --git a/arch/arm64/boot/dts/altera/socfpga_stratix10.dtsi b/arch/arm64/boot/dts/altera/socfpga_stratix10.dtsi index e6b059378dc0..ed47dfce3ba6 100644 --- a/arch/arm64/boot/dts/altera/socfpga_stratix10.dtsi +++ b/arch/arm64/boot/dts/altera/socfpga_stratix10.dtsi @@ -119,6 +119,12 @@ #clock-cells = <0>; compatible = "fixed-clock"; }; + + qspi_clk: qspi_clk { + #clock-cells = <0>; + compatible = "fixed-clock"; + clock-frequency = <200000000>; + }; }; gmac0: ethernet@ff800000 { @@ -466,5 +472,21 @@ interrupts = <16 4>, <48 4>; }; }; + + qspi: spi@ff8d2000 { + compatible = "cdns,qspi-nor"; + #address-cells = <1>; + #size-cells = <0>; + reg = <0xff8d2000 0x100>, + <0xff900000 0x100000>; + interrupts = <0 3 4>; + cdns,fifo-depth = <128>; + cdns,fifo-width = <4>; + cdns,trigger-address = <0x00000000>; + clocks = <&qspi_clk>; + bus-num = <1>; + + status = "disabled"; + }; }; }; diff --git a/arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts b/arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts index f9b1ef12db48..60251462067a 100644 --- a/arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts +++ b/arch/arm64/boot/dts/altera/socfpga_stratix10_socdk.dts @@ -147,3 +147,34 @@ reg = <0x68>; }; }; + +&qspi { + flash0: n25q00@0 { + #address-cells = <1>; + #size-cells = <1>; + compatible = "n25q00aa"; + reg = <0>; + spi-max-frequency = <50000000>; + + m25p,fast-read; + cdns,page-size = <256>; + cdns,block-size = <16>; + cdns,read-delay = <1>; + cdns,tshsl-ns = <50>; + cdns,tsd2d-ns = <50>; + cdns,tchsh-ns = <4>; + cdns,tslch-ns = <4>; + + partition@qspi-boot { + label = "Boot and fpga data"; + /* 64MB for boot and FPGA data */ + reg = <0x0 0x4000000>; + }; + + partition@qspi-rootfs { + label = "Root Filesystem - JFFS2"; + /* 64MB for Linux jffs2 */ + reg = <0x4000000 0x4000000>; + }; + }; +}; -- 2.7.4