提交 5d84ca80 编写于 作者: J Jacob Pan 提交者: Zheng Zengkai

iommu: Use device fault trace event

maillist inclusion
category: feature
bugzilla: 51855
CVE: NA

Reference: https://jpbrucker.net/git/linux/commit/?h=sva/2021-03-01&id=f6cfa2e3655787bc3f90c50aff7cc75d0746bdf3

---------------------------------------------

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: NJacob Pan <jacob.jun.pan@linux.intel.com>
[JPB: removed invalidate event, that will be added later]
Signed-off-by: NJean-Philippe Brucker <jean-philippe@linaro.org>
Signed-off-by: NLijun Fang <fanglijun3@huawei.com>
Reviewed-by: NWeilong Chen <chenweilong@huawei.com>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
上级 083ae66e
......@@ -1259,6 +1259,7 @@ int iommu_report_device_fault(struct device *dev, struct iommu_fault_event *evt)
mutex_unlock(&fparam->lock);
kfree(evt_pending);
}
trace_dev_fault(dev, &evt->fault);
done_unlock:
mutex_unlock(&param->lock);
return ret;
......@@ -1318,6 +1319,7 @@ int iommu_page_response(struct device *dev,
}
ret = domain->ops->page_response(dev, evt, msg);
trace_dev_page_response(dev, msg);
list_del(&evt->list);
kfree(evt);
break;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册