From patchwork Wed Oct 17 17:23:11 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Evan Green X-Patchwork-Id: 10645973 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 5101213B0 for ; Wed, 17 Oct 2018 17:23:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3D500286D6 for ; Wed, 17 Oct 2018 17:23:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 316BE28779; Wed, 17 Oct 2018 17:23:54 +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 C8C6B286D6 for ; Wed, 17 Oct 2018 17:23:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727788AbeJRBU1 (ORCPT ); Wed, 17 Oct 2018 21:20:27 -0400 Received: from mail-pl1-f195.google.com ([209.85.214.195]:45698 "EHLO mail-pl1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727734AbeJRBU1 (ORCPT ); Wed, 17 Oct 2018 21:20:27 -0400 Received: by mail-pl1-f195.google.com with SMTP id y15-v6so13005933plr.12 for ; Wed, 17 Oct 2018 10:23:47 -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=9EIWQQk5EjjFfrDkrK63GK5vxiX3qXyY+XumPaw9dsY=; b=cuCcoPf9voMp8CTmUgfpn7eps/N6acCmW3WC2ka3dZU3XUtRgyCXGh5/EjkGlCILaU WQFjiywqThJFWGTCpZNeHHyKF7RttBwFjeXergUrNQfMxYCp5sMGumOjVLY7kzz/Vpel SghWPBEwRHM7CRo0EeKR//wzDzaprh7IwQ13k= 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=9EIWQQk5EjjFfrDkrK63GK5vxiX3qXyY+XumPaw9dsY=; b=QjS+XU5bgEgwy3IgnFZeAISwD2z8qLzepkkvyhGaUUW6G4iF+krDH7gTie89n0nUPF I/c/DryNpsco7kDhYf60lyll9//dQbna7ZA6iarirkyrG76wYDpFz0tMnjGgiU67GurY /G9nY2rXJp+K3YOdBSgx+q5bTibd+GFCRCrpVivr7to5lro6owXhG/N1YJv0VPJYjpa8 v9ldGX8vBKJnZuENhqOWdroqJ7AZEf55VMYfRn/1A7ZJU07Y6HOZ/UgTN6dJ9NxBCPkQ +W98PRNV9QvgMEvJB9GnJmt99sLfrOWPZnKaV1p4qjf4R7NLVVYXiKJI1/NMqdUfmgXB 1iYg== X-Gm-Message-State: ABuFfogAXvnmDJa/OWuvZDOsVAyaDg+8KO5WabXk4YBdzfqe0lxEPaRn KEajBK3a7wi9cPwl1HhaOQlX1Q== X-Google-Smtp-Source: ACcGV60eqiDrN849rDif+1g+IITyA7nwcoGomQ/uwdvgZqvyPm8QP9oOj8BnnngExyoUa1ipdXZS9Q== X-Received: by 2002:a17:902:2867:: with SMTP id e94-v6mr13594311plb.317.1539797027351; Wed, 17 Oct 2018 10:23:47 -0700 (PDT) Received: from evgreen2.mtv.corp.google.com ([2620:15c:202:201:e418:c825:76cf:5f64]) by smtp.gmail.com with ESMTPSA id h75-v6sm19760141pfe.146.2018.10.17.10.23.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 17 Oct 2018 10:23:46 -0700 (PDT) From: Evan Green To: Andy Gross , David Brown , Rob Herring , Mark Rutland , linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: swboyd@chromium.org, dianders@chromium.org, Evan Green Subject: [PATCH 1/2] arm64: dts: qcom: sdm845: add UFS controller Date: Wed, 17 Oct 2018 10:23:11 -0700 Message-Id: <20181017172312.194281-2-evgreen@chromium.org> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20181017172312.194281-1-evgreen@chromium.org> References: <20181017172312.194281-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 This change adds the UFS controller and PHY to SDM845. Signed-off-by: Evan Green Signed-off-by: Douglas Anderson --- arch/arm64/boot/dts/qcom/sdm845.dtsi | 66 ++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi index b72bdb0a31a5..20b2c258816a 100644 --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi @@ -808,6 +808,72 @@ }; }; + 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: ufsphy@1d87000 { + compatible = "qcom,sdm845-qmp-ufs-phy"; + reg = <0x1d87000 0x18c>; + #clock-cells = <1>; + #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>; + #phy-cells = <0>; + }; + }; + tcsr_mutex_regs: syscon@1f40000 { compatible = "syscon"; reg = <0x1f40000 0x40000>; From patchwork Wed Oct 17 17:23:12 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Evan Green X-Patchwork-Id: 10645975 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 44EB3109C for ; Wed, 17 Oct 2018 17:24:06 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 30575286D6 for ; Wed, 17 Oct 2018 17:24:06 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2440928779; Wed, 17 Oct 2018 17:24:06 +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 16ADA286D6 for ; Wed, 17 Oct 2018 17:24:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727976AbeJRBUo (ORCPT ); Wed, 17 Oct 2018 21:20:44 -0400 Received: from mail-pf1-f193.google.com ([209.85.210.193]:34624 "EHLO mail-pf1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727770AbeJRBUo (ORCPT ); Wed, 17 Oct 2018 21:20:44 -0400 Received: by mail-pf1-f193.google.com with SMTP id f78-v6so7758908pfe.1 for ; Wed, 17 Oct 2018 10:24:04 -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=cCTK2ppRlB6er40eSHAXoUbuoFkweFdZ8znYjF+YJKc=; b=dj6SG4p4o5OIu36I3PZWIQFuep2QqiXzNbAZZjwUs00/SLrmiWJqaVuO79ep9IEoe1 gq11t1k1iJIAn/KzUWdMPb2EZsBY5Q9/zqoYG8evcKQfav3MKI9zdhjqANamiIEdyneD 4BcmxQreIWJlsWCavwsycXUw9dUeGPjg823lE= 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=cCTK2ppRlB6er40eSHAXoUbuoFkweFdZ8znYjF+YJKc=; b=aPEInB6q7R7eZzqVxrQAXyyKOS/Y1wmnBzl3BSBG1+C5+rNsFmjvWBA1d+sfRbSN4w dxi1Duinog+OgDclBCNFMzivPIeaOorFve1QVBwK5cr8HnStgE37C8PfszgW6NcH0gYo O4nxKirmmBc1eGiwLiZzRX85hAxK3W+UjoxZ4zPn9aZVN52AxcF3fNcg0BerHBY/PHS0 zHyzvIsCtxV/GhRC3qd5+8c/b1Nr3oKpUgoUYUGkm29c0dvgvBzFi3uV35+ssG+1zxm4 zHR2Jd2ncqNmQpUVnU2mLZuUjHDG8CnIewykjUfaMLNnAPufXvmxru1SDwqhd4pKFVQ2 ULAw== X-Gm-Message-State: ABuFfogjC+m9wAPm2oOrvofAe2AaC/ytk6rIO3sl2+rlCwKofkU9bINS 0UxN19UW2Aeqii47xVFb+3FuAw== X-Google-Smtp-Source: ACcGV635WKETw56JtJwxAej6DUsFmVPvLj7kjp624epkdtRxOZqwyZjaOGfHsJ51S+PIL4zqJhMpzg== X-Received: by 2002:a65:6295:: with SMTP id f21-v6mr25497288pgv.167.1539797043984; Wed, 17 Oct 2018 10:24:03 -0700 (PDT) Received: from evgreen2.mtv.corp.google.com ([2620:15c:202:201:e418:c825:76cf:5f64]) by smtp.gmail.com with ESMTPSA id h75-v6sm19760141pfe.146.2018.10.17.10.24.02 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 17 Oct 2018 10:24:02 -0700 (PDT) From: Evan Green To: Andy Gross , David Brown , Rob Herring , Mark Rutland , linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: swboyd@chromium.org, dianders@chromium.org, Can Guo , Evan Green Subject: [PATCH 2/2] arm64: dts: qcom: sdm845: Add UFS nodes for sdm845-mtp Date: Wed, 17 Oct 2018 10:23:12 -0700 Message-Id: <20181017172312.194281-3-evgreen@chromium.org> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20181017172312.194281-1-evgreen@chromium.org> References: <20181017172312.194281-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 This change enables the UFS host controller and PHY on sdm845-mtp. Signed-off-by: Can Guo Signed-off-by: Evan Green Reviewed-by: Vivek Gautam --- I was unable to test this on an MTP, if somebody could give this a try I would be grateful. This applies atop agross/for-next, since it needs the regulators. 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"; };