[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] SMMU, Unhandled context fault
On Thu, Apr 28, 2016 at 11:27:22AM +0100, Julien Grall wrote: > > >On 28/04/16 07:39, Peng Fan wrote: >>Hi Julien, > >Hello Peng, > >>On Thu, Apr 28, 2016 at 10:37:54AM +0800, Peng Fan wrote: >>>Hi Julien, >>>On Wed, Apr 27, 2016 at 10:58:28AM +0100, Julien Grall wrote: >>>>Hello Peng, >>>> >>>>On 27/04/2016 03:02, Peng Fan wrote: >>>>>On Tue, Apr 26, 2016 at 04:30:03PM +0200, Edgar E. Iglesias wrote: >>>>>>On Tue, Apr 26, 2016 at 09:56:33PM +0800, Peng Fan wrote: >>>>>>>You mean the PNU bit(Privileged Not Unprivileged) is 1? >>>>>>>I did not met Unhandled context fault each time. >>>>>>>Actually during my serveral boot test, I only met two times. >>>>>> >>>>>> >>>>>> >>>>>>I meant the NSSTATE and NSATTR bits in FSYNR are set to zero. I get the >>>>>>impression that the TrustZone state for the SD controller may be >>>>> >>>>>oh. The NSATTR bit is 0. I did not find NSSTATE in my Issue D SMMU spec. >>>>>If without xen, only one linux boots up, sd controller can access memory >>>>>using >>>>>DMA without issue. >>>> >>>>IIRC, by default Linux baremetal does not protect the devices with the SMMU. >>>> >>>>I would recommend you to check whether the SMMUs are in-used and configured >>>>to generate a fault (disable_bypass = 1). >>> >>>Ok. I'll set S2CRn to generate fault in xen smmu driver to see whether SMMUs >>>in-used or not > >I meant in Linux. My bad. Do you mean enabling SMMU driver in Linux with KVM support? > >>> >>>I found a patch for errata of mmu-500, >>>https://git.kernel.org/cgit/linux/kernel/git/will/linux.git/commit/?h=iommu/devel&id=7f0cc5124f5ec66b5b26878ac85137adc6537413 >>>Do you know this? >>> >>>I suspect the unstable issue on my platform seems related to this errata, >>>but i do not have details about this errata. > >Have you tried to port the patch to Xen and see if it helps? I tried. But the value of the register does not change. I am checking with our IC team. > >> >>I do the following change: >> //s2cr = S2CR_TYPE_TRANS | S2CR_PRIVCFG_UNPRIV | >> s2cr = S2CR_TYPE_FAULT | S2CR_PRIVCFG_UNPRIV | >> (smmu_domain->cfg.cbndx << S2CR_CBNDX_SHIFT); >> >>Now XEN SMMU driver reports that: >>(XEN) smmu: /iommu@5c800000: Unexpected global fault, this could be serious >>(XEN) smmu: /iommu@5c800000: GFSR 0x00000001, GFSYNR0 0x00000004, GFSYNR1 >>0x00000011, GFSYNR2 0x00000000 >> >>So I think SMMU is working. > >Well, it does not help to know whether the SMMU has been correctly >initialized by Xen. Is there any big difference between XEN SMMU driver and linux SMMU driver? I know that XEN only support Stage 2. But the initliaization flow is almost the same. Thanks, Peng. > >Regards, > >-- >Julien Grall _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |