From patchwork Thu Mar 20 15:55:20 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 26732 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-oa0-f72.google.com (mail-oa0-f72.google.com [209.85.219.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 9AB2720143 for ; Thu, 20 Mar 2014 15:55:44 +0000 (UTC) Received: by mail-oa0-f72.google.com with SMTP id eb12sf4193164oac.3 for ; Thu, 20 Mar 2014 08:55:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=z3Yq7ScgT8CLkKWnCgDQQv+RxPHqoYjZY2y+4q3b81A=; b=LHGsXhVKP2CjqxBR6G2xbCQxHnHIStTFTeZ0zvF5jtVLgor6RAKQB45xztdKmp/xlX ElznNE0KAuL8Xwm0WX/YVdXdCoXbue2uNcwQuAfgjq/LHxxihu4dpKAOyCxSyX2Hv6n9 ZMznTGtPDu3CboLm7AdPQKw/pkL/pkIg5ASIzG5N9Btdl6VfsUsKlTvXRZ93WP0o1g4D 0xI5nGfO5SHWnkKyrKVliStZy7cECLiJc4wNOmnVxkGGU2EUKa7z3AMnriyJuBQiCxyi Swy5YGMrfpEtRHsS6JNDjC9vkecF4I8u0r5mqZPPovE/N6NBFVLX8D/G8804B6zbeEyh lK+g== X-Gm-Message-State: ALoCoQlnpppsW1lTdnR2PAg93NoGym+/k+aS7ou8NMNciruaGU0Lm3XPyg1PfOHOMuXeeNEuER2G X-Received: by 10.42.13.198 with SMTP id e6mr15244789ica.21.1395330944171; Thu, 20 Mar 2014 08:55:44 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.97.72 with SMTP id l66ls270924qge.16.gmail; Thu, 20 Mar 2014 08:55:43 -0700 (PDT) X-Received: by 10.52.15.132 with SMTP id x4mr5257054vdc.31.1395330943927; Thu, 20 Mar 2014 08:55:43 -0700 (PDT) Received: from mail-vc0-f169.google.com (mail-vc0-f169.google.com [209.85.220.169]) by mx.google.com with ESMTPS id f7si504908vcz.165.2014.03.20.08.55.43 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 20 Mar 2014 08:55:43 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.169 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.169; Received: by mail-vc0-f169.google.com with SMTP id ik5so1191250vcb.14 for ; Thu, 20 Mar 2014 08:55:43 -0700 (PDT) X-Received: by 10.52.137.74 with SMTP id qg10mr774832vdb.61.1395330943825; Thu, 20 Mar 2014 08:55:43 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.78.9 with SMTP id i9csp399127vck; Thu, 20 Mar 2014 08:55:43 -0700 (PDT) X-Received: by 10.66.216.129 with SMTP id oq1mr47792999pac.75.1395330942940; Thu, 20 Mar 2014 08:55:42 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id zm8si1764146pac.194.2014.03.20.08.55.42; Thu, 20 Mar 2014 08:55:42 -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; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933913AbaCTPzb (ORCPT + 26 others); Thu, 20 Mar 2014 11:55:31 -0400 Received: from mail-we0-f179.google.com ([74.125.82.179]:60747 "EHLO mail-we0-f179.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932530AbaCTPz0 (ORCPT ); Thu, 20 Mar 2014 11:55:26 -0400 Received: by mail-we0-f179.google.com with SMTP id x48so756471wes.10 for ; Thu, 20 Mar 2014 08:55:25 -0700 (PDT) X-Received: by 10.180.12.233 with SMTP id b9mr3892207wic.8.1395330925139; Thu, 20 Mar 2014 08:55:25 -0700 (PDT) Received: from lee--X1.home (host109-148-113-193.range109-148.btcentralplus.com. [109.148.113.193]) by mx.google.com with ESMTPSA id mw3sm54051630wic.7.2014.03.20.08.55.23 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 20 Mar 2014 08:55:24 -0700 (PDT) From: Lee Jones To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: lee.jones@linaro.org, kernel@stlinux.com, srinivas.kandagatla@st.com, maxime.coquelin@st.com, patrice.chotard@st.com Subject: [PATCH] ARM: STi: Add support for the FSM Serial Flash Controller Date: Thu, 20 Mar 2014 15:55:20 +0000 Message-Id: <1395330920-10559-1-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.8.3.2 Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: lee.jones@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.169 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Here we add the necessary device nodes required for successful device probing and Pinctrl setup for the FSM. Acked-by: Srinivas Kandagatla Acked-by Angus Clark Acked-by: Brian Norris Signed-off-by: Lee Jones Acked-by: Maxime Coquelin --- arch/arm/boot/dts/stih416-pinctrl.dtsi | 13 +++++++++++++ arch/arm/boot/dts/stih416.dtsi | 13 +++++++++++++ arch/arm/boot/dts/stih41x-b2020.dtsi | 1 + arch/arm/boot/dts/stih41x-b2020x.dtsi | 28 ++++++++++++++++++++++++++++ 4 files changed, 55 insertions(+) create mode 100644 arch/arm/boot/dts/stih41x-b2020x.dtsi diff --git a/arch/arm/boot/dts/stih416-pinctrl.dtsi b/arch/arm/boot/dts/stih416-pinctrl.dtsi index b29ff4b..81df8e7 100644 --- a/arch/arm/boot/dts/stih416-pinctrl.dtsi +++ b/arch/arm/boot/dts/stih416-pinctrl.dtsi @@ -210,6 +210,19 @@ }; }; }; + + fsm { + pinctrl_fsm: fsm { + st,pins { + spi-fsm-clk = <&PIO12 2 ALT1 OUT>; + spi-fsm-cs = <&PIO12 3 ALT1 OUT>; + spi-fsm-mosi = <&PIO12 4 ALT1 OUT>; + spi-fsm-miso = <&PIO12 5 ALT1 IN>; + spi-fsm-hol = <&PIO12 6 ALT1 OUT>; + spi-fsm-wp = <&PIO12 7 ALT1 OUT>; + }; + }; + }; }; pin-controller-rear { diff --git a/arch/arm/boot/dts/stih416.dtsi b/arch/arm/boot/dts/stih416.dtsi index b7ab47b..1e24b9e 100644 --- a/arch/arm/boot/dts/stih416.dtsi +++ b/arch/arm/boot/dts/stih416.dtsi @@ -145,5 +145,18 @@ status = "disabled"; }; + + /* FSM */ + spifsm: spifsm@fe902000 { + compatible = "st,spi-fsm"; + reg = <0xfe902000 0x1000>; + pinctrl-0 = <&pinctrl_fsm>; + + st,syscfg = <&syscfg_rear>; + st,boot-device-reg = <0x958>; + st,boot-device-spi = <0x1a>; + + status = "disabled"; + }; }; }; diff --git a/arch/arm/boot/dts/stih41x-b2020.dtsi b/arch/arm/boot/dts/stih41x-b2020.dtsi index 0ef0a69..01487e0 100644 --- a/arch/arm/boot/dts/stih41x-b2020.dtsi +++ b/arch/arm/boot/dts/stih41x-b2020.dtsi @@ -6,6 +6,7 @@ * it under the terms of the GNU General Public License version 2 as * publishhed by the Free Software Foundation. */ +#include "stih41x-b2020x.dtsi" / { memory{ device_type = "memory"; diff --git a/arch/arm/boot/dts/stih41x-b2020x.dtsi b/arch/arm/boot/dts/stih41x-b2020x.dtsi new file mode 100644 index 0000000..df01c12 --- /dev/null +++ b/arch/arm/boot/dts/stih41x-b2020x.dtsi @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2013 STMicroelectronics (R&D) Limited. + * Author: Lee Jones + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * publishhed by the Free Software Foundation. + */ +/ { + soc { + spifsm: spifsm@fe902000 { + #address-cells = <1>; + #size-cells = <1>; + + status = "okay"; + + partition@0 { + label = "SerialFlash1"; + reg = <0x00000000 0x00500000>; + }; + + partition@500000 { + label = "SerialFlash2"; + reg = <0x00500000 0x00b00000>; + }; + }; + }; +};