Re: [PATCH] iommu/tegra-smmu: Fix mc errors on tegra124-nyan

2021-02-19 Thread Dmitry Osipenko
19.02.2021 01:07, Nicolin Chen пишет: > Commit 25938c73cd79 ("iommu/tegra-smmu: Rework tegra_smmu_probe_device()") > removed certain hack in the tegra_smmu_probe() by relying on IOMMU core to > of_xlate SMMU's SID per device, so as to get rid of tegra_smmu_find() and > tegra_smmu_configure() that

RE: [PATCH 2/4] iommu/vt-d: Enable write protect propagation from guest

2021-02-19 Thread Tian, Kevin
> From: Jacob Pan > Sent: Saturday, February 20, 2021 1:09 AM > > Hi Kevin, > > On Fri, 19 Feb 2021 06:19:04 +, "Tian, Kevin" > wrote: > > > > From: Jacob Pan > > > Sent: Friday, February 19, 2021 5:31 AM > > > > > > Write protect bit, when set, inhibits supervisor writes to the

Re: [PATCH 4/4] iommu/vt-d: Calculate and set flags for handle_mm_fault

2021-02-19 Thread Lu Baolu
On 2/19/21 5:31 AM, Jacob Pan wrote: Page requests are originated from the user page fault. Therefore, we shall set FAULT_FLAG_USER. FAULT_FLAG_REMOTE indicates that we are walking an mm which is not guaranteed to be the same as the current->mm and should not be subject to protection key 

Re: [PATCH 3/4] iommu/vt-d: Reject unsupported page request modes

2021-02-19 Thread Lu Baolu
On 2/19/21 5:31 AM, Jacob Pan wrote: When supervisor/privilige mode SVM is used, we bind init_mm.pgd with a supervisor PASID. There should not be any page fault for init_mm. Execution request with DMA read is also not supported. This patch checks PRQ descriptor for both unsupported

Re: [PATCH 1/4] iommu/vt-d: Enable write protect for supervisor SVM

2021-02-19 Thread Lu Baolu
Hi Jacob and Sanjay, On 2/19/21 5:31 AM, Jacob Pan wrote: Write protect bit, when set, inhibits supervisor writes to the read-only pages. In supervisor shared virtual addressing (SVA), where page tables are shared between CPU and DMA, IOMMU PASID entry WPE bit should match CR0.WP bit in the

Re: [PATCH RFC v1 5/6] xen-swiotlb: convert variables to arrays

2021-02-19 Thread Boris Ostrovsky
On 2/19/21 3:32 PM, Konrad Rzeszutek Wilk wrote: > On Sun, Feb 07, 2021 at 04:56:01PM +0100, Christoph Hellwig wrote: >> On Thu, Feb 04, 2021 at 09:40:23AM +0100, Christoph Hellwig wrote: >>> So one thing that has been on my mind for a while: I'd really like >>> to kill the separate dma ops in

Re: [PATCH 3/8] xen-swiotlb: use io_tlb_end in xen_swiotlb_dma_supported

2021-02-19 Thread Konrad Rzeszutek Wilk
On Sun, Feb 07, 2021 at 05:09:29PM +0100, Christoph Hellwig wrote: > Use the existing variable that holds the physical address for > xen_io_tlb_end to simplify xen_swiotlb_dma_supported a bit, and remove > the otherwise unused xen_io_tlb_end variable and the xen_virt_to_bus > helper. >

Re: [PATCH 2/8] xen-swiotlb: use is_swiotlb_buffer in is_xen_swiotlb_buffer

2021-02-19 Thread Konrad Rzeszutek Wilk
On Sun, Feb 07, 2021 at 05:09:28PM +0100, Christoph Hellwig wrote: > Use the is_swiotlb_buffer to check if a physical address is > a swiotlb buffer. This works because xen-swiotlb does use the > same buffer as the main swiotlb code, and xen_io_tlb_{start,end} > are just the addresses for it that

Re: [PATCH RFC v1 5/6] xen-swiotlb: convert variables to arrays

2021-02-19 Thread Konrad Rzeszutek Wilk
On Sun, Feb 07, 2021 at 04:56:01PM +0100, Christoph Hellwig wrote: > On Thu, Feb 04, 2021 at 09:40:23AM +0100, Christoph Hellwig wrote: > > So one thing that has been on my mind for a while: I'd really like > > to kill the separate dma ops in Xen swiotlb. If we compare xen-swiotlb > > to swiotlb

Re: preserve DMA offsets when using swiotlb v2

2021-02-19 Thread Konrad Rzeszutek Wilk
On Tue, Feb 09, 2021 at 11:49:40AM -0800, Jianxiong Gao wrote: > > Sorry for being a little pushy, any chance we could get this reviewed > > in time for the 5.12 merge window? > > > Tested and it looks good. Thanks for clearing it up! Let me put it on my regression bucket as last time it was able

Re: [EXTERNAL] Re: Question regarding VIOT proposal

2021-02-19 Thread Al Stone
On 19 Feb 2021 12:24, Jean-Philippe Brucker wrote: > On Thu, Feb 18, 2021 at 04:39:43PM -0700, Al Stone wrote: > > As of today, the proposal has been approved for inclusion in the next > > release of the ACPI spec (whatever version gets released post the 6.4 > > version that just came out). > > >

Re: [PATCH 2/4] iommu/vt-d: Enable write protect propagation from guest

2021-02-19 Thread Jacob Pan
Hi Kevin, On Fri, 19 Feb 2021 06:19:04 +, "Tian, Kevin" wrote: > > From: Jacob Pan > > Sent: Friday, February 19, 2021 5:31 AM > > > > Write protect bit, when set, inhibits supervisor writes to the read-only > > pages. In guest supervisor shared virtual addressing (SVA), > > write-protect

Re: [EXTERNAL] Re: Question regarding VIOT proposal

2021-02-19 Thread Jean-Philippe Brucker
On Thu, Feb 18, 2021 at 04:39:43PM -0700, Al Stone wrote: > As of today, the proposal has been approved for inclusion in the next > release of the ACPI spec (whatever version gets released post the 6.4 > version that just came out). > > Congratulations ?!? :) > > And thanks to all for their