Messages in this thread Patch in this message | | | From | Jacob Pan <> | Subject | [PATCH v4 07/22] iommu: Use device fault trace event | Date | Sun, 9 Jun 2019 06:44:07 -0700 |
| |
For performance and debugging purposes, these trace events help analyzing device faults that interact with IOMMU subsystem. E.g. IOMMU:0000:00:0a.0 type=2 reason=0 addr=0x00000000007ff000 pasid=1 group=1 last=0 prot=1
Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com> [JPB: removed invalidate event, that will be added later] Signed-off-by: Jean-Philippe Brucker <jean-philippe.brucker@arm.com> --- drivers/iommu/iommu.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/drivers/iommu/iommu.c b/drivers/iommu/iommu.c index 64e87d5..166adb8 100644 --- a/drivers/iommu/iommu.c +++ b/drivers/iommu/iommu.c @@ -1032,6 +1032,7 @@ int iommu_report_device_fault(struct device *dev, struct iommu_fault_event *evt) } ret = fparam->handler(evt, fparam->data); + trace_dev_fault(dev, &evt->fault); done_unlock: mutex_unlock(¶m->lock); return ret; @@ -1604,6 +1605,7 @@ int iommu_page_response(struct device *dev, if (evt->fault.prm.pasid == msg->pasid && evt->fault.prm.grpid == msg->grpid) { msg->iommu_data = evt->iommu_private; + trace_dev_page_response(dev, msg); ret = domain->ops->page_response(dev, msg); list_del(&evt->list); kfree(evt); -- 2.7.4
| |