From patchwork Wed Jun 14 03:38:03 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeffy Chen X-Patchwork-Id: 9785207 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 DFB1E602DC for ; Wed, 14 Jun 2017 03:39:13 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E63D828589 for ; Wed, 14 Jun 2017 03:39:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id DAFA72858F; Wed, 14 Jun 2017 03:39:13 +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=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 9875228589 for ; Wed, 14 Jun 2017 03:39:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=q+/uF3r6quOL9kKlPPwh9TvX8vARRtP4II+zxjk0gTI=; b=prQN+x6rX3Vs5qPc/Pbx45sxD4 oM09Uf7kqnXNyPOx/3LIlkxUJcdMsVTPtYwIHLRR3ylXm6+LKKbDnvemcjtPPzhGMet8RvOSc30oD bqwEh/RGsVWlb8ahfxfYAio7B/VQkXKjgaFu4bnInScIVXniWCBV+B8+ve8IPzcMYhPznK0BvzkOq jCQIResEtivP+12Q8t5uMcgJ+CooQwOfxZpdf6Pbj2D24SLALSn3g7RGU4yAZFV/sx1nIoYC6HQVL xWwqIb19yc8+b7tXV2HGZJuOLKEfABi6qyKlgcPVet70hw4tKhta0vw0Mp0KRVTUI6Qjv2/zEJYBy KX1eKv0A==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dKz9E-0004Ij-3C; Wed, 14 Jun 2017 03:39:12 +0000 Received: from regular1.263xmail.com ([211.150.99.135]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dKz8r-0003hZ-Vm; Wed, 14 Jun 2017 03:38:52 +0000 Received: from jeffy.chen?rock-chips.com (unknown [192.168.167.174]) by regular1.263xmail.com (Postfix) with ESMTP id EEF511DF93; Wed, 14 Jun 2017 11:38:24 +0800 (CST) X-263anti-spam: KSV:0; X-MAIL-GRAY: 0 X-MAIL-DELIVERY: 1 X-KSVirus-check: 0 X-ABS-CHECKED: 4 Received: from localhost (localhost [127.0.0.1]) by smtp.263.net (Postfix) with ESMTPA id 891F9393; Wed, 14 Jun 2017 11:38:21 +0800 (CST) X-RL-SENDER: jeffy.chen@rock-chips.com X-FST-TO: linux-kernel@vger.kernel.org X-SENDER-IP: 103.29.142.67 X-LOGIN-NAME: jeffy.chen@rock-chips.com X-UNIQUE-TAG: <197186dc8ad8132dac0dadd8aaf27dbd> X-ATTACHMENT-NUM: 0 X-SENDER: cjf@rock-chips.com X-DNS-TYPE: 0 Received: from localhost (unknown [103.29.142.67]) by smtp.263.net (Postfix) whith ESMTP id 3174071KVUP; Wed, 14 Jun 2017 11:38:24 +0800 (CST) From: Jeffy Chen To: linux-kernel@vger.kernel.org, broonie@kernel.org Subject: [PATCH v3 3/3] arm64: dts: rockchip: use cs-gpios for cros_ec_spi Date: Wed, 14 Jun 2017 11:38:03 +0800 Message-Id: <1497411483-23377-3-git-send-email-jeffy.chen@rock-chips.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1497411483-23377-1-git-send-email-jeffy.chen@rock-chips.com> References: <1497411483-23377-1-git-send-email-jeffy.chen@rock-chips.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170613_203850_549776_61C3CC46 X-CRM114-Status: UNSURE ( 5.17 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , devicetree@vger.kernel.org, briannorris@chromium.org, heiko@sntech.de, Catalin Marinas , Jeffy Chen , Will Deacon , dianders@chromium.org, linux-rockchip@lists.infradead.org, Rob Herring , linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The cros_ec requires CS line to be active after last message. But the CS would be toggled when powering off/on rockchip spi, which breaks ec xfer. Use GPIO CS to prevent that. Signed-off-by: Jeffy Chen --- Changes in v3: None Changes in v2: Fix wrong pinconf for spi5_cs0. arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi b/arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi index eb50593..b34a51d 100644 --- a/arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk3399-gru.dtsi @@ -790,6 +790,8 @@ ap_i2c_audio: &i2c8 { &spi5 { status = "okay"; + cs-gpios = <&gpio2 23 GPIO_ACTIVE_HIGH>; + cros_ec: ec@0 { compatible = "google,cros-ec-spi"; reg = <0>; @@ -813,6 +815,10 @@ ap_i2c_audio: &i2c8 { }; }; +&spi5_cs0 { + rockchip,pins = ; +}; + &tsadc { status = "okay";