From patchwork Fri Oct 26 17:35:42 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Evan Green X-Patchwork-Id: 10657699 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5851C5A4 for ; Fri, 26 Oct 2018 17:36:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 40F3A2C991 for ; Fri, 26 Oct 2018 17:36:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 325C12CA89; Fri, 26 Oct 2018 17:36:41 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham 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 BF4B02C991 for ; Fri, 26 Oct 2018 17:36:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727726AbeJ0COC (ORCPT ); Fri, 26 Oct 2018 22:14:02 -0400 Received: from mail-pf1-f193.google.com ([209.85.210.193]:34524 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727682AbeJ0COB (ORCPT ); Fri, 26 Oct 2018 22:14:01 -0400 Received: by mail-pf1-f193.google.com with SMTP id f78-v6so897975pfe.1 for ; Fri, 26 Oct 2018 10:36:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=rMPYYtJcfOKkkPHMGb8Y8gDAK7xJI/9Pi23QASvDL1E=; b=iFwHjdzC8umg6IlyVFmFkpjQiVZWuqG1U+1T3PuD3ziLxVxvtXPPuQ6oZxGx8fBaid 50Kbz9sulA/y4I7PbEhD9lJCcQXAs6x76gJ8e34Q8evj2yQLD+GwjrNJaXMBJqDL251G k4L6s0B+9Cbj+SN1AmwT5FZzICYYX3ycp6bHg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=rMPYYtJcfOKkkPHMGb8Y8gDAK7xJI/9Pi23QASvDL1E=; b=Il82pKugjGz2H+S0im+tQKlK9wVmc7gZDN6ERXkdTI941sWlUXZHuZ1xQ+C1964J+Y LlAmfZV86glxhyeFnez/GPP488UBZqxFLvgT6s9EQPFY/+b9NMAfcRUdSP7U66RKFBG/ xRmmWahSTMy6ANR9HC11iTIsVfxBJgaJuz8Msd8w+yqsnBltONc419X2AfCHd/0ofl/G GI9By1mfxvsWkCfo7SWV6tuJKYBuHXt0KEkg50DywNK9H24drBABZ9lBXvamJkQHGgKn Md6CpZMGHe+PXz24lr0sa0TZBpLbe0qc/HfMHWR/eJpbNLZ9Mc0aQx1v7TrMcn4vFzSD /cxA== X-Gm-Message-State: AGRZ1gICeWA1QGVQy1NoCEQJ8HVmTkc4nrjXJ/l/+JSOInFhm9YyFESi YKDePJajHEdcmHW2UAPN7OKpNA== X-Google-Smtp-Source: AJdET5c1qJJCHCwt+KVf9bb+Beg1nuXAeWpGIGCRchaOj898q0GKpfLfBOSebanEwX0Js5gO8NJqSA== X-Received: by 2002:a63:9e58:: with SMTP id r24mr4466127pgo.264.1540575367630; Fri, 26 Oct 2018 10:36:07 -0700 (PDT) Received: from evgreen2.mtv.corp.google.com ([2620:15c:202:201:e418:c825:76cf:5f64]) by smtp.gmail.com with ESMTPSA id b29-v6sm20164448pfj.183.2018.10.26.10.36.06 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 26 Oct 2018 10:36:06 -0700 (PDT) From: Evan Green To: Rob Herring , Andy Gross , Kishon Vijay Abraham I Cc: Douglas Anderson , Stephen Boyd , Evan Green , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Rob Herring , David Brown , Mark Rutland , linux-soc@vger.kernel.org Subject: [PATCH v5 3/5] arm64: dts: qcom: sdm845: add UFS controller Date: Fri, 26 Oct 2018 10:35:42 -0700 Message-Id: <20181026173544.136037-4-evgreen@chromium.org> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20181026173544.136037-1-evgreen@chromium.org> References: <20181026173544.136037-1-evgreen@chromium.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add the UFS controller and PHY to SDM845. Signed-off-by: Evan Green Signed-off-by: Douglas Anderson Reviewed-by: Bjorn Andersson --- As Doug mentioned in v2, this should land after (or with) the driver fix in this series. Changes in v5: None Changes in v4: None Changes in v3: None Changes in v2: - Renamed ufsphy to phy (Vivek) - Removed #clock-cells (Vivek) arch/arm64/boot/dts/qcom/sdm845.dtsi | 67 ++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi index b72bdb0a31a5..9c72edb678ec 100644 --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi @@ -808,6 +808,73 @@ }; }; + ufshc1: ufshc@1d84000 { + compatible = "qcom,sdm845-ufshc", "qcom,ufshc", + "jedec,ufs-2.0"; + reg = <0x1d84000 0x2500>; + interrupts = ; + phys = <&ufsphy1_lanes>; + phy-names = "ufsphy"; + lanes-per-direction = <2>; + power-domains = <&gcc UFS_PHY_GDSC>; + + clock-names = + "core_clk", + "bus_aggr_clk", + "iface_clk", + "core_clk_unipro", + "ref_clk", + "tx_lane0_sync_clk", + "rx_lane0_sync_clk", + "rx_lane1_sync_clk"; + clocks = + <&gcc GCC_UFS_PHY_AXI_CLK>, + <&gcc GCC_AGGRE_UFS_PHY_AXI_CLK>, + <&gcc GCC_UFS_PHY_AHB_CLK>, + <&gcc GCC_UFS_PHY_UNIPRO_CORE_CLK>, + <&rpmhcc RPMH_CXO_CLK>, + <&gcc GCC_UFS_PHY_TX_SYMBOL_0_CLK>, + <&gcc GCC_UFS_PHY_RX_SYMBOL_0_CLK>, + <&gcc GCC_UFS_PHY_RX_SYMBOL_1_CLK>; + freq-table-hz = + <50000000 200000000>, + <0 0>, + <0 0>, + <37500000 150000000>, + <0 0>, + <0 0>, + <0 0>, + <0 0>; + + resets = <&gcc GCC_UFS_PHY_BCR>; + reset-names = "rst"; + + status = "disabled"; + }; + + ufsphy1: phy@1d87000 { + compatible = "qcom,sdm845-qmp-ufs-phy"; + reg = <0x1d87000 0x18c>; + #address-cells = <1>; + #size-cells = <1>; + ranges; + clock-names = "ref", + "ref_aux"; + clocks = <&gcc GCC_UFS_MEM_CLKREF_CLK>, + <&gcc GCC_UFS_PHY_PHY_AUX_CLK>; + + status = "disabled"; + + ufsphy1_lanes: lanes@1d87400 { + reg = <0x1d87400 0x108>, + <0x1d87600 0x1e0>, + <0x1d87c00 0x1dc>, + <0x1d87800 0x108>, + <0x1d87a00 0x1e0>; + #phy-cells = <0>; + }; + }; + tcsr_mutex_regs: syscon@1f40000 { compatible = "syscon"; reg = <0x1f40000 0x40000>; From patchwork Fri Oct 26 17:35:43 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Evan Green X-Patchwork-Id: 10657695 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 48E0D5A4 for ; Fri, 26 Oct 2018 17:36:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 315C92C991 for ; Fri, 26 Oct 2018 17:36:14 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 255D92CA89; Fri, 26 Oct 2018 17:36:14 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham 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 CB8042C991 for ; Fri, 26 Oct 2018 17:36:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727724AbeJ0COF (ORCPT ); Fri, 26 Oct 2018 22:14:05 -0400 Received: from mail-pf1-f193.google.com ([209.85.210.193]:36736 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727761AbeJ0COF (ORCPT ); Fri, 26 Oct 2018 22:14:05 -0400 Received: by mail-pf1-f193.google.com with SMTP id l81-v6so894174pfg.3 for ; Fri, 26 Oct 2018 10:36:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=PteDfKg2sjPU8GQpzvIO14bIYL+O+BA756dZUBXv6tU=; b=QrwWNaG1lXd02WO21bjNs3fmRSj7JiJ7RfUNvb99Rzh3bD5klyrxRxvr1/171MxImF 9kVfK0Eecr7Y9C6663eDEwu68UQxeDbIIs9/Jz2mmwHod3Qs+dTr/wuFaLx2HW2L6Mh4 Ml1WdBmJPLesYaTs6O2OzafknRUxrF+WorSmw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=PteDfKg2sjPU8GQpzvIO14bIYL+O+BA756dZUBXv6tU=; b=Aq6dPsi+oWwDq3+QQwPA4CYKB6lq/Q4FQ3VrnR+n7pTGLFl6e0rLIJ/+anCWQUAdld qJU8XR+Rg4oekFCTW5VECq/LPSXiA1HgWfHW/dvq0ADKE5ENZ4vmRyu7DN2N2CoUdt2a tFU1TTYiTIGfPUk5rlvMi8sbGasBGU3tty3XTbyu6F+ewvAJ0eJdbqMNEmSYpY2Nj1HN MRTnRrwcAhyKQlImckgq4Gh+U0IyZ6/uvr31iff+wYKeydLPPON5761/M52CuG0bi2Ao 5kdjDA9WobBuKbSqf0aLuo92yfVzs1gGsFxU40U8G4beTYVGWpk5f1fjnJRBujK740dJ O1qQ== X-Gm-Message-State: AGRZ1gLtRZxd87NNb6cf/7CMzyI3+wGUmBkHTgO1uafSwgRhhzMJnOkv eKGi+Z1oGVqPKqyqDVYO68p78A== X-Google-Smtp-Source: AJdET5d0cgF5A2cjMuQza8KRpAWakLVECFTDBi85IVSJwrkQn7g4ukHilmgjt6EbG7wJxTg0qxqHZw== X-Received: by 2002:a62:8012:: with SMTP id j18-v6mr4635258pfd.202.1540575371842; Fri, 26 Oct 2018 10:36:11 -0700 (PDT) Received: from evgreen2.mtv.corp.google.com ([2620:15c:202:201:e418:c825:76cf:5f64]) by smtp.gmail.com with ESMTPSA id b29-v6sm20164448pfj.183.2018.10.26.10.36.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 26 Oct 2018 10:36:10 -0700 (PDT) From: Evan Green To: Rob Herring , Andy Gross , Kishon Vijay Abraham I Cc: Douglas Anderson , Stephen Boyd , Can Guo , Evan Green , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Rob Herring , David Brown , Mark Rutland , linux-soc@vger.kernel.org Subject: [PATCH v5 4/5] arm64: dts: qcom: sdm845: Add UFS nodes for sdm845-mtp Date: Fri, 26 Oct 2018 10:35:43 -0700 Message-Id: <20181026173544.136037-5-evgreen@chromium.org> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20181026173544.136037-1-evgreen@chromium.org> References: <20181026173544.136037-1-evgreen@chromium.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Can Guo Enable the UFS host controller and PHY on sdm845-mtp. Signed-off-by: Can Guo Signed-off-by: Evan Green Reviewed-by: Vivek Gautam Reviewed-by: Douglas Anderson --- Changes in v5: None Changes in v4: None Changes in v3: None Changes in v2: None arch/arm64/boot/dts/qcom/sdm845-mtp.dts | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sdm845-mtp.dts b/arch/arm64/boot/dts/qcom/sdm845-mtp.dts index eedfaf8922e2..d5fddea71a85 100644 --- a/arch/arm64/boot/dts/qcom/sdm845-mtp.dts +++ b/arch/arm64/boot/dts/qcom/sdm845-mtp.dts @@ -356,6 +356,20 @@ status = "okay"; }; +&ufshc1 { + status = "okay"; + + vcc-supply = <&vreg_l20a_2p95>; + vcc-max-microamp = <600000>; +}; + +&ufsphy1 { + status = "okay"; + + vdda-phy-supply = <&vdda_ufs1_core>; + vdda-pll-supply = <&vdda_ufs1_1p2>; +}; + &usb_1 { status = "okay"; }; From patchwork Fri Oct 26 17:35:44 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Evan Green X-Patchwork-Id: 10657697 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 6F63C109C for ; Fri, 26 Oct 2018 17:36:28 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 59DF82C991 for ; Fri, 26 Oct 2018 17:36:28 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4D7A52CA89; Fri, 26 Oct 2018 17:36:28 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham 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 E23242C991 for ; Fri, 26 Oct 2018 17:36:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727798AbeJ0COI (ORCPT ); Fri, 26 Oct 2018 22:14:08 -0400 Received: from mail-pg1-f193.google.com ([209.85.215.193]:39112 "EHLO mail-pg1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727759AbeJ0COH (ORCPT ); Fri, 26 Oct 2018 22:14:07 -0400 Received: by mail-pg1-f193.google.com with SMTP id r9-v6so854874pgv.6 for ; Fri, 26 Oct 2018 10:36:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=Nso1UGGtqZnAVAiqPSjFOiMLbuNxXiI1CzmMG9sS2h8=; b=KblY/6qvOY93fIyaaxEOX+qfzpvLWsFF9739MUDPOsyAp5Ak0sZTG6FvW3sqK0bYZz kcZF0jZCRICopSHEW2PYOVgXsA2RHngtBn0tyXgPugUFGNeOdpoMqp6Ct2cIVXV6ze9u 35EOcnA+kdYOFdCKcuEhyX+PmZh4FRcITYh8Q= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=Nso1UGGtqZnAVAiqPSjFOiMLbuNxXiI1CzmMG9sS2h8=; b=YU+0ACTzdL16vwKWSij9ocem/DK+FAbTGPmDI4dUMtK33QedJ0h1VQRvqR16VNy9J1 59GC5rWzz1PxdodPAcAln5r1MeDn70Q9+J0UoXF/hkJJ9qfQ4AkvzDVl/Lwg+fGyUspH J0JBPsaoVcijVIrY32hr2ZhpoNhN4Tdc9dQzehCxFAluf6ubSEjnkfV34CYMl0FnwL6q xM+sAKwXlygGwRwpQpO4hPD2vBBsiqttAqLFVbkU1np6AqZA6BHr/PRXWo2Rpl59VgJZ is22ljUGSrH7DfCwnqNxitAY9n01NidU1EhXwxgv2BaAcnXT+Ww+hUFfNzwd/6VMjrDw IzLg== X-Gm-Message-State: AGRZ1gKAI0NTyPtliFzM/j+KxT06+NVomvRR5QZZZ4HT5H2ulCuNi5iG y/cO1zncE6aCj6L7D9R6VZHgPA== X-Google-Smtp-Source: AJdET5csAA282mpCW37K5lx03nklgm1ifgPfTup0Z5M3qocp7nOk3mOpHnXwsEuvXryItEqw6Mr8uQ== X-Received: by 2002:a63:4658:: with SMTP id v24-v6mr4393868pgk.425.1540575374572; Fri, 26 Oct 2018 10:36:14 -0700 (PDT) Received: from evgreen2.mtv.corp.google.com ([2620:15c:202:201:e418:c825:76cf:5f64]) by smtp.gmail.com with ESMTPSA id b29-v6sm20164448pfj.183.2018.10.26.10.36.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 26 Oct 2018 10:36:13 -0700 (PDT) From: Evan Green To: Rob Herring , Andy Gross , Kishon Vijay Abraham I Cc: Douglas Anderson , Stephen Boyd , Evan Green , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Rob Herring , David Brown , Mark Rutland , linux-soc@vger.kernel.org Subject: [PATCH v5 5/5] arm64: dts: qcom: sdm845: Add USB PHY lane two Date: Fri, 26 Oct 2018 10:35:44 -0700 Message-Id: <20181026173544.136037-6-evgreen@chromium.org> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20181026173544.136037-1-evgreen@chromium.org> References: <20181026173544.136037-1-evgreen@chromium.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add the second lane registers for the USB PHY, now that the QMP phy bindings have been updated. This way the driver can stop reaching beyond its register region to get at the second lane. Signed-off-by: Evan Green Reviewed-by: Douglas Anderson Reviewed-by: Bjorn Andersson --- Changes in v5: None Changes in v4: None Changes in v3: - Removed erroneous fixup for USB UniPro PHY, which is not dual lane (Doug) Changes in v2: None arch/arm64/boot/dts/qcom/sdm845.dtsi | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi index 9c72edb678ec..ff2db36ec4fa 100644 --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi @@ -1188,10 +1188,12 @@ <&gcc GCC_USB3_PHY_PRIM_BCR>; reset-names = "phy", "common"; - usb_1_ssphy: lane@88e9200 { + usb_1_ssphy: lanes@88e9200 { reg = <0x88e9200 0x128>, <0x88e9400 0x200>, <0x88e9c00 0x218>, + <0x88e9600 0x128>, + <0x88e9800 0x200>, <0x88e9a00 0x100>; #phy-cells = <0>; clocks = <&gcc GCC_USB3_PRIM_PHY_PIPE_CLK>;