Commit 96897153 authored by Zhen Lei's avatar Zhen Lei Committed by Zhang Zekun
Browse files

iommu/arm-smmu-v3: Allow disabling ECMDQs at boot time

hulk inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I8Z6DC



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

Add boot option arm_smmu_v3.disable_ecmdq to support disabling ECMDQ
during startup. For example, add arm_smmu_v3.disable_ecmdq=1 in command
line to disable ECMDQ and use normal CMDQ.

Signed-off-by: default avatarZhen Lei <thunder.leizhen@huawei.com>
Signed-off-by: default avatarZhang Zekun <zhangzekun11@huawei.com>
parent 22129ea1
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -41,6 +41,12 @@ module_param(disable_msipolling, bool, 0444);
MODULE_PARM_DESC(disable_msipolling,
	"Disable MSI-based polling for CMD_SYNC completion.");

#ifdef CONFIG_ARM_SMMU_V3_ECMDQ
static bool disable_ecmdq;
module_param(disable_ecmdq, bool, 0444);
MODULE_PARM_DESC(disable_ecmdq,	"Disable the use of ECMDQs");
#endif

#ifdef CONFIG_SMMU_BYPASS_DEV
struct smmu_bypass_device {
	unsigned short vendor;
@@ -4504,7 +4510,7 @@ static int arm_smmu_device_hw_probe(struct arm_smmu_device *smmu)
		 smmu->ias, smmu->oas, smmu->features);

#ifdef CONFIG_ARM_SMMU_V3_ECMDQ
	if (smmu->features & ARM_SMMU_FEAT_ECMDQ) {
	if (smmu->features & ARM_SMMU_FEAT_ECMDQ && !disable_ecmdq) {
		int err;

		err = arm_smmu_ecmdq_probe(smmu);