Re: [PATCH 3/5] swiotlb: Add alloc and free APIs

2020-04-29 Thread kbuild test robot
Hi Srivatsa, Thank you for the patch! Yet something to improve: [auto build test ERROR on vhost/linux-next] [also build test ERROR on xen-tip/linux-next linus/master v5.7-rc3 next-20200429] [cannot apply to swiotlb/linux-next] [if your patch is applied to the wrong git tree, please drop us a

Re: [RFC PATCH] iommu/amd: fix a race in fetch_pte()

2020-04-29 Thread Qian Cai
> On Apr 29, 2020, at 7:20 AM, Joerg Roedel wrote: > > On Mon, Apr 20, 2020 at 09:26:12AM -0400, Qian Cai wrote: >> No dice. There could be some other races. For example, > > Can you please test this branch: > > > https://git.kernel.org/pub/scm/linux/kernel/git/joro/linux.git/log/?h=am

Re: [PATCH v3 16/34] iommu/vt-d: Convert to probe/release_device() call-backs

2020-04-29 Thread Lu Baolu
On 2020/4/29 21:36, Joerg Roedel wrote: From: Joerg Roedel Convert the Intel IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel Reviewed-by: Lu Baolu Best regards, bao

Re: [PATCH v3 04/34] iommu/vt-d: Wire up iommu_ops->def_domain_type

2020-04-29 Thread Lu Baolu
On 2020/4/29 21:36, Joerg Roedel wrote: From: Joerg Roedel The Intel VT-d driver already has a matching function to determine the default domain type for a device. Wire it up in intel_iommu_ops. Signed-off-by: Joerg Roedel Reviewed-by: Lu Baolu Best regards, baolu --- drivers/iommu/in

Re: [PATCH v12 4/8] iommu/vt-d: Add bind guest PASID support

2020-04-29 Thread Jacob Pan
On Wed, 29 Apr 2020 16:12:01 +0200 Auger Eric wrote: > >> in last review Eric raised the open about what about binding the > >> same PASID to the same pdev multiple times. We discussed that > >> should be disallowed. Here can you check whether aux_domain is > >> enabled on pdev to restrict multip

Re: [PATCH v3 3/4] iommu/vt-d: Add page request draining support

2020-04-29 Thread Jacob Pan
On Wed, 29 Apr 2020 14:00:05 +0800 Lu Baolu wrote: > Hi Jacob, > > On 2020/4/29 11:36, Jacob Pan wrote: > > On Wed, 22 Apr 2020 16:06:10 +0800 > > Lu Baolu wrote: > > > >> When a PASID is stopped or terminated, there can be pending PRQs > >> (requests that haven't received responses) in rema

[RFC PATCH] virtio: virtio_pool can be static

2020-04-29 Thread kbuild test robot
Signed-off-by: kbuild test robot --- virtio_bounce.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/virtio/virtio_bounce.c b/drivers/virtio/virtio_bounce.c index 3de8e0eb71e48..5a68d48667c42 100644 --- a/drivers/virtio/virtio_bounce.c +++ b/drivers/virtio/vir

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread kbuild test robot
us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Srivatsa-Vaddagiri/virtio-on-Type-1-hypervisor/20200429-0

Re: [PATCH] perf/smmuv3: Allow sharing MMIO registers with the SMMU driver

2020-04-29 Thread Tuan Phan
> On Apr 29, 2020, at 12:21 AM, Jean-Philippe Brucker > wrote: > > On Tue, Apr 28, 2020 at 11:10:09AM -0700, Tuan Phan wrote: >> I tested this patch on HW, however I need to add one more following change >> to make it works > > Thanks for testing. I don't understand why you need the change b

RE: iommu_iova slab eats too much memory

2020-04-29 Thread Salil Mehta
> From: Robin Murphy [mailto:robin.mur...@arm.com] > Sent: Wednesday, April 29, 2020 3:00 PM > To: Salil Mehta ; Bin > > On 2020-04-29 2:37 pm, Salil Mehta wrote: > > Hi Bin, > > > >> From: Bin [mailto:anole1...@gmail.com] > >> Sent: Wednesday, April 29, 2020 5:14 AM > >> To: Salil Mehta > >> Hi

Re: [PATCH v12 4/8] iommu/vt-d: Add bind guest PASID support

2020-04-29 Thread Auger Eric
Hi, On 4/27/20 10:34 PM, Jacob Pan wrote: > On Fri, 24 Apr 2020 10:47:45 + > "Tian, Kevin" wrote: > >>> From: Jacob Pan >>> Sent: Wednesday, April 22, 2020 2:53 AM >>> >>> When supporting guest SVA with emulated IOMMU, the guest PASID >>> table is shadowed in VMM. Updates to guest vIOMMU PA

Re: iommu_iova slab eats too much memory

2020-04-29 Thread Robin Murphy
On 2020-04-29 2:37 pm, Salil Mehta wrote: Hi Bin, From: Bin [mailto:anole1...@gmail.com] Sent: Wednesday, April 29, 2020 5:14 AM To: Salil Mehta Hi Shlil: Thank you for your attention, and these are my answers: 1. I don't really understand what you're saying. What's the difference between D

Re: [PATCH v12 6/8] iommu/vt-d: Add svm/sva invalidate function

2020-04-29 Thread Auger Eric
Hi Jacob, On 4/21/20 8:52 PM, Jacob Pan wrote: > When Shared Virtual Address (SVA) is enabled for a guest OS via > vIOMMU, we need to provide invalidation support at IOMMU API and driver > level. This patch adds Intel VT-d specific function to implement > iommu passdown invalidate API for shared v

[PATCH v3 31/34] iommu/exynos: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the Exynos IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Joerg Roedel --- drivers/iommu/exynos-i

[PATCH v3 17/34] iommu/arm-smmu: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the arm-smmu and arm-smmu-v3 drivers to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/arm-smmu-v3.c | 38 ++---

[PATCH v3 24/34] iommu/qcom: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the QCOM IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/qcom_iommu.c | 24 +++- 1 file changed, 7 inser

[PATCH v3 06/34] iommu/amd: Return -ENODEV in add_device when device is not handled by IOMMU

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel When check_device() fails on the device, it is not handled by the IOMMU and amd_iommu_add_device() needs to return -ENODEV. Signed-off-by: Joerg Roedel --- drivers/iommu/amd_iommu.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/iommu/amd_iom

[PATCH v3 34/34] iommu: Unexport iommu_group_get_for_dev()

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel The function is now only used in IOMMU core code and shouldn't be used outside of it anyway, so remove the export for it. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Joerg Roedel --- drivers/iommu/iommu.c | 4 ++-- include/linux/iommu.h | 1 - 2 f

[PATCH v3 26/34] iommu/tegra: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the Tegra IOMMU drivers to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/tegra-gart.c | 24 ++-- drivers/iommu/tegra-s

[PATCH v3 30/34] iommu/exynos: Use first SYSMMU in controllers list for IOMMU core

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel On Exynos platforms there can be more than one SYSMMU (IOMMU) for one DMA master device. Since the IOMMU core code expects only one hardware IOMMU, use the first SYSMMU in the list. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Joerg Roedel --- driv

[PATCH v3 15/34] iommu/amd: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the AMD IOMMU Driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/amd_iommu.c | 71 --- 1 file cha

[PATCH v3 33/34] iommu: Move more initialization to __iommu_probe_device()

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Move the calls to dev_iommu_get() and try_module_get() into __iommu_probe_device(), so that the callers don't have to do it on their own. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Joerg Roedel --- drivers/iommu/iommu.c | 47 +

[PATCH v3 32/34] iommu: Remove add_device()/remove_device() code-paths

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel All drivers are converted to use the probe/release_device() call-backs, so the add_device/remove_device() pointers are unused and the code using them can be removed. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Joerg Roedel --- drivers/iommu/iommu.

[PATCH v3 08/34] iommu: Move default domain allocation to iommu_probe_device()

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Well, not really. The call to iommu_alloc_default_domain() in iommu_group_get_for_dev() has to stay around as long as there are IOMMU drivers using the add/remove_device() call-backs instead of probe/release_device(). Those drivers expect that iommu_group_get_for_dev() returns

[PATCH v3 27/34] iommu/renesas: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the Renesas IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/ipmmu-vmsa.c | 60 +- 1 file

[PATCH v3 18/34] iommu/pamu: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the PAMU IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/fsl_pamu_domain.c | 22 +- 1 file changed, 5 in

[PATCH v3 25/34] iommu/rockchip: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the Rockchip IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/rockchip-iommu.c | 26 +++--- 1 file change

[PATCH v3 19/34] iommu/s390: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the S390 IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/s390-iommu.c | 22 ++ 1 file changed, 6 inserti

[PATCH v3 04/34] iommu/vt-d: Wire up iommu_ops->def_domain_type

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel The Intel VT-d driver already has a matching function to determine the default domain type for a device. Wire it up in intel_iommu_ops. Signed-off-by: Joerg Roedel --- drivers/iommu/intel-iommu.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/iommu/intel-iommu.c

[PATCH v3 10/34] iommu: Move new probe_device path to separate function

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel This makes it easier to remove to old code-path when all drivers are converted. As a side effect that it also fixes the error cleanup path. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Joerg Roedel --- drivers/iommu/iommu.c | 69 +++

[PATCH v3 16/34] iommu/vt-d: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the Intel IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/intel-iommu.c | 67 - 1 file c

[PATCH v3 01/34] iommu: Move default domain allocation to separate function

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Move the code out of iommu_group_get_for_dev() into a separate function. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Joerg Roedel --- drivers/iommu/iommu.c | 74 ++- 1 file changed, 45 insertions(+), 29 dele

[PATCH v3 13/34] iommu: Export bus_iommu_probe() and make is safe for re-probing

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Add a check to the bus_iommu_probe() call-path to make sure it ignores devices which have already been successfully probed. Then export the bus_iommu_probe() function so it can be used by IOMMU drivers. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Jo

RE: iommu_iova slab eats too much memory

2020-04-29 Thread Salil Mehta
Hi Bin, > From: Bin [mailto:anole1...@gmail.com] > Sent: Wednesday, April 29, 2020 5:14 AM > To: Salil Mehta > Hi Shlil: > > Thank you for your attention, and these are my answers: > > 1. I don't really understand what you're saying. What's the difference > between DMA buffer and DMA mapping?

[PATCH v3 14/34] iommu/amd: Remove dev_data->passthrough

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Make use of generic IOMMU infrastructure to gather the same information carried in dev_data->passthrough and remove the struct member. Signed-off-by: Joerg Roedel --- drivers/iommu/amd_iommu.c | 10 +- drivers/iommu/amd_iommu_types.h | 1 - 2 files changed, 5

[PATCH v3 12/34] iommu: Move iommu_group_create_direct_mappings() out of iommu_group_add_device()

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel After the previous changes the iommu group may not have a default domain when iommu_group_add_device() is called. With no default domain iommu_group_create_direct_mappings() will do nothing and no direct mappings will be created. Rename iommu_group_create_direct_mappings() to

[PATCH v3 11/34] iommu: Split off default domain allocation from group assignment

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel When a bus is initialized with iommu-ops, all devices on the bus are scanned and iommu-groups are allocated for them, and each groups will also get a default domain allocated. Until now this happened as soon as the group was created and the first device added to it. When other

[PATCH v3 28/34] iommu/omap: Remove orphan_dev tracking

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Remove the tracking of device which could not be probed because their IOMMU is not probed yet. Replace it with a call to bus_iommu_probe() when a new IOMMU is probed. Signed-off-by: Joerg Roedel --- drivers/iommu/omap-iommu.c | 54 +++--- 1 fi

[PATCH v3 05/34] iommu/amd: Remove dma_mask check from check_device()

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel The check was only needed for the DMA-API implementation in the AMD IOMMU driver, which no longer exists. Signed-off-by: Joerg Roedel --- drivers/iommu/amd_iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/a

[PATCH v3 22/34] iommu/mediatek: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the Mediatek IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/mtk_iommu.c | 24 ++-- 1 file changed, 6 in

[PATCH v3 23/34] iommu/mediatek-v1 Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the Mediatek-v1 IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/mtk_iommu_v1.c | 50 +++- 1

[PATCH v3 03/34] iommu/amd: Implement iommu_ops->def_domain_type call-back

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Implement the new def_domain_type call-back for the AMD IOMMU driver. Signed-off-by: Joerg Roedel --- drivers/iommu/amd_iommu.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/amd_iommu.c index 20cce366e951..73b4

[PATCH v3 02/34] iommu: Add def_domain_type() callback in iommu_ops

2020-04-29 Thread Joerg Roedel
From: Sai Praneeth Prakhya Some devices are reqired to use a specific type (identity or dma) of default domain when they are used with a vendor iommu. When the system level default domain type is different from it, the vendor iommu driver has to request a new default domain with iommu_request_dma

[PATCH v3 07/34] iommu: Add probe_device() and release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Add call-backs to 'struct iommu_ops' as an alternative to the add_device() and remove_device() call-backs, which will be removed when all drivers are converted. The new call-backs will not setup IOMMU groups and domains anymore, so also add a probe_finalize() call-back where t

[PATCH v3 09/34] iommu: Keep a list of allocated groups in __iommu_probe_device()

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel This is needed to defer default_domain allocation for new IOMMU groups until all devices have been added to the group. Tested-by: Marek Szyprowski Acked-by: Marek Szyprowski Signed-off-by: Joerg Roedel --- drivers/iommu/iommu.c | 9 +++-- 1 file changed, 7 insertions(+

[PATCH v3 20/34] iommu/virtio: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the VirtIO IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/virtio-iommu.c | 41 +--- 1 file

[PATCH v3 21/34] iommu/msm: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the MSM IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/msm_iommu.c | 34 +++--- 1 file changed,

[PATCH v3 29/34] iommu/omap: Convert to probe/release_device() call-backs

2020-04-29 Thread Joerg Roedel
From: Joerg Roedel Convert the OMAP IOMMU driver to use the probe_device() and release_device() call-backs of iommu_ops, so that the iommu core code does the group and sysfs setup. Signed-off-by: Joerg Roedel --- drivers/iommu/omap-iommu.c | 49 ++ 1 file ch

[PATCH v3 00/34] iommu: Move iommu_group setup to IOMMU core code

2020-04-29 Thread Joerg Roedel
Hi, here is the third version of this patch-set. Older versions can be found here: v1: https://lore.kernel.org/lkml/20200407183742.4344-1-j...@8bytes.org/ (Has some more introductory text) v2: https://lore.kernel.org/lkml/20200414131542.25608-1-j...@8bytes.org/ Chang

Re: [RFC PATCH] iommu/amd: fix a race in fetch_pte()

2020-04-29 Thread Joerg Roedel
On Mon, Apr 20, 2020 at 09:26:12AM -0400, Qian Cai wrote: > No dice. There could be some other races. For example, Can you please test this branch: https://git.kernel.org/pub/scm/linux/kernel/git/joro/linux.git/log/?h=amd-iommu-fixes It has the previous fix in it and a couple more to ma

Re: [virtio-dev] Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Jan Kiszka
On 29.04.20 12:45, Michael S. Tsirkin wrote: On Wed, Apr 29, 2020 at 12:26:43PM +0200, Jan Kiszka wrote: On 29.04.20 12:20, Michael S. Tsirkin wrote: On Wed, Apr 29, 2020 at 03:39:53PM +0530, Srivatsa Vaddagiri wrote: That would still not work I think where swiotlb is used for pass-thr devices

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Michael S. Tsirkin
On Wed, Apr 29, 2020 at 12:26:43PM +0200, Jan Kiszka wrote: > On 29.04.20 12:20, Michael S. Tsirkin wrote: > > On Wed, Apr 29, 2020 at 03:39:53PM +0530, Srivatsa Vaddagiri wrote: > > > That would still not work I think where swiotlb is used for pass-thr > > > devices > > > (when private memory is

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Srivatsa Vaddagiri
* Michael S. Tsirkin [2020-04-29 06:20:48]: > On Wed, Apr 29, 2020 at 03:39:53PM +0530, Srivatsa Vaddagiri wrote: > > That would still not work I think where swiotlb is used for pass-thr devices > > (when private memory is fine) as well as virtio devices (when shared memory > > is > > required).

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Jan Kiszka
On 29.04.20 12:20, Michael S. Tsirkin wrote: On Wed, Apr 29, 2020 at 03:39:53PM +0530, Srivatsa Vaddagiri wrote: That would still not work I think where swiotlb is used for pass-thr devices (when private memory is fine) as well as virtio devices (when shared memory is required). So that is a s

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Michael S. Tsirkin
On Wed, Apr 29, 2020 at 03:39:53PM +0530, Srivatsa Vaddagiri wrote: > That would still not work I think where swiotlb is used for pass-thr devices > (when private memory is fine) as well as virtio devices (when shared memory is > required). So that is a separate question. When there are multiple u

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Srivatsa Vaddagiri
* Michael S. Tsirkin [2020-04-29 05:52:05]: > > > So it seems that with modern Linux, all one needs > > > to do on x86 is mark the device as untrusted. > > > It's already possible to do this with ACPI and with OF - would that be > > > sufficient for achieving what this patchset is trying to do? >

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Michael S. Tsirkin
On Wed, Apr 29, 2020 at 03:14:10PM +0530, Srivatsa Vaddagiri wrote: > * Michael S. Tsirkin [2020-04-29 02:50:41]: > > > So it seems that with modern Linux, all one needs > > to do on x86 is mark the device as untrusted. > > It's already possible to do this with ACPI and with OF - would that be >

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Srivatsa Vaddagiri
* Michael S. Tsirkin [2020-04-29 02:50:41]: > So it seems that with modern Linux, all one needs > to do on x86 is mark the device as untrusted. > It's already possible to do this with ACPI and with OF - would that be > sufficient for achieving what this patchset is trying to do? In my case, its

Re: [RFC PATCH] iommu/amd: fix a race in fetch_pte()

2020-04-29 Thread Joerg Roedel
Hi Qian, On Mon, Apr 20, 2020 at 09:26:12AM -0400, Qian Cai wrote: > > No dice. There could be some other races. For example, Okay, I think I know what is happening. The increase_address_space() function increases the address space, but does not update the DTE and does not flush the old DTE from

Re: [PATCH] perf/smmuv3: Allow sharing MMIO registers with the SMMU driver

2020-04-29 Thread Jean-Philippe Brucker
On Tue, Apr 28, 2020 at 11:10:09AM -0700, Tuan Phan wrote: > I tested this patch on HW, however I need to add one more following change to > make it works Thanks for testing. I don't understand why you need the change below though, do you know which other region is conflicting with the SMMU? It s

Re: [PATCH] perf/smmuv3: Allow sharing MMIO registers with the SMMU driver

2020-04-29 Thread Tuan Phan
> On Apr 21, 2020, at 8:57 AM, Jean-Philippe Brucker > wrote: > > Some Arm SMMUv3 implementations, for example Arm CoreLink MMU-600, embed > the PMCG registers into the SMMU MMIO regions. It currently causes probe > failure because the PMU and SMMU drivers request overlapping resources. > > A

Re: [PATCH 5/5] virtio: Add bounce DMA ops

2020-04-29 Thread Lu Baolu
On 2020/4/29 14:50, Michael S. Tsirkin wrote: On Wed, Apr 29, 2020 at 01:42:13PM +0800, Lu Baolu wrote: On 2020/4/29 12:57, Michael S. Tsirkin wrote: On Wed, Apr 29, 2020 at 10:22:32AM +0800, Lu Baolu wrote: On 2020/4/29 4:41, Michael S. Tsirkin wrote: On Tue, Apr 28, 2020 at 11:19:52PM +0530