From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bjorn Andersson Subject: Re: [PATCH v4 2/2] dts: arm64/sdm845: Add node for arm,mmu-500 Date: Thu, 10 Jan 2019 19:15:04 -0800 Message-ID: <20190111031504.GC17247@minitux> References: <20181011094930.17010-1-vivek.gautam@codeaurora.org> <20181011094930.17010-3-vivek.gautam@codeaurora.org> <20190108065935.GA11536@builder> <9675f7d8-a726-07d3-34b7-99b7464a6303@codeaurora.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <9675f7d8-a726-07d3-34b7-99b7464a6303@codeaurora.org> Sender: linux-kernel-owner@vger.kernel.org To: Vivek Gautam Cc: joro@8bytes.org, robh+dt@kernel.org, andy.gross@linaro.org, iommu@lists.linux-foundation.org, devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, mark.rutland@arm.com, david.brown@linaro.org, linux-kernel@vger.kernel.org, robin.murphy@arm.com, will.deacon@arm.com, dianders@chromium.org List-Id: linux-arm-msm@vger.kernel.org On Tue 08 Jan 03:18 PST 2019, Vivek Gautam wrote: > > On 1/8/2019 12:29 PM, Bjorn Andersson wrote: > > On Thu 11 Oct 02:49 PDT 2018, Vivek Gautam wrote: > > > > > Add device node for arm,mmu-500 available on sdm845. > > > This MMU-500 with single TCU and multiple TBU architecture > > > is shared among all the peripherals except gpu. > > > > > Hi Vivek, > > > > Applying this patch together with UFS ([1] and [2]) ontop of v5.0-rc1 > > causes my MTP reboot once the UFSHCD module is inserted and probed. > > Independently the patches seems to work fine. > > > > Do you have any suggestion to why this would be? > > > Hi Bjorn, > > Enabling SMMU on sdm845 when you have UFS also enabled, would need addition > of > 'iommus' property to ufs dt node. > You will need to add the following with ufs: > > iommus = <&apps_smmu 0x100 0xf>; > Thanks, this do address the sudden restart of my MTP, but provides a fault. [ 7.391117] arm-smmu 15000000.iommu: Unhandled context fault: fsr=0x402, iova=0xffffdf3e0, fsynr=0x290000, cb=0 [ 7.747406] ufshcd-qcom 1d84000.ufshc: ufshcd_verify_dev_init: NOP OUT failed -11 The only thing done ontop of v5.0-rc1, is to take your patch adding apps_smmu, add the ufs nodes as Evan proposed and specify iommus in the ufshcd node. With Coreboot UFS seems to work without specifying iommus, but with it UFS fails to come up. Regards, Bjorn > Thanks > Vivek > > > > > [1] https://lore.kernel.org/lkml/20181210192826.241350-4-evgreen@chromium.org/ > > [2] https://lore.kernel.org/lkml/20181210192826.241350-5-evgreen@chromium.org/ > > > > Regards, > > Bjorn > > > > > Signed-off-by: Vivek Gautam > > > --- > > > > > > Changes since v3: > > > - none. > > > > > > arch/arm64/boot/dts/qcom/sdm845.dtsi | 72 ++++++++++++++++++++++++++++++++++++ > > > 1 file changed, 72 insertions(+) > > > > > > diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi > > > index b72bdb0a31a5..0aace729643d 100644 > > > --- a/arch/arm64/boot/dts/qcom/sdm845.dtsi > > > +++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi > > > @@ -1297,6 +1297,78 @@ > > > cell-index = <0>; > > > }; > > > + apps_smmu: iommu@15000000 { > > > + compatible = "qcom,sdm845-smmu-500", "arm,mmu-500"; > > > + reg = <0x15000000 0x80000>; > > > + #iommu-cells = <2>; > > > + #global-interrupts = <1>; > > > + interrupts = , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + , > > > + ; > > > + }; > > > + > > > apss_shared: mailbox@17990000 { > > > compatible = "qcom,sdm845-apss-shared"; > > > reg = <0x17990000 0x1000>; > > > -- > > > QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member > > > of Code Aurora Forum, hosted by The Linux Foundation > > >