Thread (1 message) 1 message, 1 author, 2018-04-04

[PATCH 27/37] iommu/arm-smmu-v3: Register fault workqueue

From: Jean-Philippe Brucker <hidden>
Date: 2018-04-04 10:13:01
Also in: kvm, linux-acpi, linux-devicetree, linux-iommu, linux-pci

On 22/03/18 01:09, Yisheng Xie wrote:
Hi Jean,

On 2018/3/21 21:24, Jean-Philippe Brucker wrote:
quoted
Hi Yisheng,

On 19/03/18 11:03, Yisheng Xie wrote:
quoted
Hi Jean,

[...]
quoted
@@ -3168,6 +3260,13 @@ static int arm_smmu_device_probe(struct platform_device *pdev)
 	if (ret)
 		return ret;
 
+	if (smmu->features & (ARM_SMMU_FEAT_STALLS | ARM_SMMU_FEAT_PRI)) {
+		smmu->faultq_nb.notifier_call = arm_smmu_flush_queues;
+		ret = iommu_fault_queue_register(&smmu->faultq_nb);
+		if (ret)
+			return ret;
I find a case here: CONFIG_IOMMU_FAULT=n, and smmu support feature STALLS or PRI,
the device probe will failed here, is this what we want?
Since CONFIG_ARM_SMMU_V3 selects CONFIG_IOMMU_FAULT, I don't think it
can happen. 
But CONFIG_IOMMU_FAULT can be changed after select, maybe can make it as unchangeable. Seems sensible, I don't see a reason to leave IOMMU_FAULT selectable
manually.

Thanks,
Jean
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help