Re: [PATCH kernel] vfio/spapr: Add trace points for map/unmap

2017-11-22 Thread Alexey Kardashevskiy
On 17/11/17 17:58, Alexey Kardashevskiy wrote: > On 17/11/17 11:13, Alex Williamson wrote: >> On Tue, 14 Nov 2017 10:47:12 +1100 >> Alexey Kardashevskiy wrote: >> >>> On 27/10/17 14:00, Alexey Kardashevskiy wrote: This adds trace_map/trace_unmap tracepoints to spapr driver.

Re: No check of the size passed to unmap_single in swiotlb

2017-11-22 Thread Robin Murphy
On 22/11/17 03:23, Eric Yang wrote: -Original Message- From: Konrad Rzeszutek Wilk [mailto:konrad.w...@oracle.com] Sent: Tuesday, November 21, 2017 12:27 AM To: Eric Yang ; iommu@lists.linux-foundation.org Cc: linux-ker...@vger.kernel.org; Greg Kroah-Hartman

Re: [RFCv2 PATCH 01/36] iommu: Keep track of processes and PASIDs

2017-11-22 Thread Jean-Philippe Brucker
On 22/11/17 03:15, Bob Liu wrote: > Hey Jean, > > On 2017/10/6 21:31, Jean-Philippe Brucker wrote: >> IOMMU drivers need a way to bind Linux processes to devices. This is used >> for Shared Virtual Memory (SVM), where devices support paging. In that >> mode, DMA can directly target virtual

[PATCH V2 12/29] iommu/amd: deprecate pci_get_bus_and_slot()

2017-11-22 Thread Sinan Kaya
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as where a PCI device is present. This restricts the device drivers to be reused for other domain numbers. Getting ready to remove pci_get_bus_and_slot() function in favor of pci_get_domain_bus_and_slot(). Hard-code the domain

RE: No check of the size passed to unmap_single in swiotlb

2017-11-22 Thread Eric Yang
> -Original Message- > From: Robin Murphy [mailto:robin.mur...@arm.com] > Sent: Wednesday, November 22, 2017 9:15 PM > To: Eric Yang ; Konrad Rzeszutek Wilk > ; iommu@lists.linux-foundation.org > Cc: Daniel Borkmann ; Kees

[PATCH v2 1/6] iommu/vt-d: Add debugfs support for Intel IOMMU internals

2017-11-22 Thread Sohil Mehta
From: Gayatri Kammela Enable Intel IOMMU debug to export Intel IOMMU internals in debugfs Cc: Sohil Mehta Cc: Fenghua Yu Cc: Ashok Raj Signed-off-by: Jacob Pan

[PATCH v2 5/6] iommu/vt-d: Add debugfs extension to show Pasid table contents

2017-11-22 Thread Sohil Mehta
From: Gayatri Kammela Debugfs extension to dump the internals such as pasid table entries for each IOMMU to the userspace. Example of such dump in Kabylake: root@OTC-KBLH-01:~# cat /sys/kernel/debug/intel_iommu/intel_iommu_ctx IOMMU dmar0: Extended Root Table

[PATCH v2 2/6] iommu/vt-d: Add Intel IOMMU debugfs to show context internals

2017-11-22 Thread Sohil Mehta
From: Gayatri Kammela IOMMU internals states such as root and context can be exported to the userspace. Example of such dump in Kabylake: root@OTC-KBLH-01:~# cat /sys/kernel/debug/intel_iommu/intel_iommu_ctx IOMMU dmar2:Root Table Addr:4558a3000 Root tbl

[PATCH v2 6/6] iommu/vt-d: Add debugfs support for Intel IOMMU Interrupt remapping

2017-11-22 Thread Sohil Mehta
Debugfs extension for Intel IOMMU to dump Interrupt remapping table entries for Interrupt remapping and Interrupt posting. The file /sys/kernel/debug/intel_iommu/intel_iommu_interrupt_remap provides detailed information, such as Index, Source Id, Destination Id, Vector and the raw values for

[PATCH v2 3/6] iommu/vt-d: Add Intel IOMMU debugfs to show extended context internals

2017-11-22 Thread Sohil Mehta
From: Gayatri Kammela Debugfs extension to dump internals such as extended context table entries for each IOMMU to the userspace. root@OTC-KBLH-01:~# cat /sys/kernel/debug/intel_iommu/intel_iommu_ctx IOMMU dmar1: Extended Root Table Addr:4558a1800 Extended Root tbl

[PATCH v2 4/6] iommu/vt-d: Add debugfs extension to show register contents

2017-11-22 Thread Sohil Mehta
From: Gayatri Kammela Debugfs extension to dump all the register contents for each IOMMU device to the user space via debugfs. example: root@OTC-KBLH-01:~# cat /sys/kernel/debug/intel_iommu/intel_iommu_regset DMAR: dmar1: reg_base_addr fed9 Name Offset

[PATCH v2 0/6] Intel IOMMU debugfs support

2017-11-22 Thread Sohil Mehta
Hi all, This series aims to add debugfs support for Intel IOMMU. It exposes IOMMU registers, internal context and dumps individual table entries to help debug Intel IOMMUs. The first patch does the ground work for the following patches by creating a new Kconfig option - INTEL_IOMMU_DEBUG. It

Re: [PATCH v2 4/6] iommu/vt-d: Add debugfs extension to show register contents

2017-11-22 Thread Andy Shevchenko
On Wed, 2017-11-22 at 11:25 -0800, Sohil Mehta wrote: > From: Gayatri Kammela > +static int intel_iommu_regs_open(struct inode *inode, struct file > *file) > +{ > + return single_open(file, intel_iommu_debugfs_regs_show, > +

Re: [PATCH v2 6/6] iommu/vt-d: Add debugfs support for Intel IOMMU Interrupt remapping

2017-11-22 Thread Andy Shevchenko
On Wed, 2017-11-22 at 11:25 -0800, Sohil Mehta wrote: > Debugfs extension for Intel IOMMU to dump Interrupt remapping table > entries for Interrupt remapping and Interrupt posting. > +static int intel_iommu_ir_open(struct inode *inode, struct file > *file) > +{ > + return single_open(file,

Re: [PATCH v2 0/6] Intel IOMMU debugfs support

2017-11-22 Thread Raj, Ashok
Hi Alex you can add for the whole series Reviewed By: Ashok Raj On Wed, Nov 22, 2017 at 11:25:40AM -0800, Mehta, Sohil wrote: > Hi all, > > This series aims to add debugfs support for Intel IOMMU. It exposes IOMMU > registers, internal context and dumps individual table