Commit 2ca35da8 authored by Jia Qingtong's avatar Jia Qingtong Committed by Jia Qingtong
Browse files

iommu/arm-smmu-v3: Add Arm SMMU HTTU config

virt inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/I8UZSP



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

add Arm SMMU HTTU config and set it default to no.
enable in openEuler defconfig.

Signed-off-by: default avatarJia Qingtong <jiaqingtong97@gmail.com>
parent 652b1711
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -6517,6 +6517,7 @@ CONFIG_ARM_SMMU_QCOM=y
CONFIG_ARM_SMMU_V3=y
CONFIG_ARM_SMMU_V3_SVA=y
# CONFIG_ARM_SMMU_V3_PM is not set
CONFIG_ARM_SMMU_V3_HTTU=y
# CONFIG_QCOM_IOMMU is not set
# CONFIG_VIRTIO_IOMMU is not set
CONFIG_SMMU_BYPASS_DEV=y
+7 −0
Original line number Diff line number Diff line
@@ -423,6 +423,13 @@ config ARM_SMMU_V3_PM
	help
	  Add support for suspend and resume support for arm smmu v3.

config ARM_SMMU_V3_HTTU
	bool "Add arm_smmu_v3  Hardware Translation Table Update"
	depends on ARM_SMMU_V3
	default n
	help
	  Add support for Hardware Translation Table Update arm smmu v3.

config S390_IOMMU
	def_bool y if S390 && PCI
	depends on S390 && PCI
+4 −0
Original line number Diff line number Diff line
@@ -2844,6 +2844,7 @@ static int arm_smmu_enable_nesting(struct iommu_domain *domain)
	return ret;
}

#ifdef CONFIG_ARM_SMMU_V3_HTTU
static int arm_smmu_split_block(struct iommu_domain *domain,
				unsigned long iova, size_t size)
{
@@ -3044,6 +3045,7 @@ static int arm_smmu_clear_dirty_log(struct iommu_domain *domain,
	return ops->clear_dirty_log(ops, iova, size, bitmap, base_iova,
				    bitmap_pgshift);
}
#endif

static int arm_smmu_of_xlate(struct device *dev, struct of_phandle_args *args)
{
@@ -3180,10 +3182,12 @@ static struct iommu_ops arm_smmu_ops = {
#endif
		.iova_to_phys		= arm_smmu_iova_to_phys,
		.enable_nesting		= arm_smmu_enable_nesting,
#ifdef CONFIG_ARM_SMMU_V3_HTTU
		.support_dirty_log	= arm_smmu_support_dirty_log,
		.switch_dirty_log	= arm_smmu_switch_dirty_log,
		.sync_dirty_log		= arm_smmu_sync_dirty_log,
		.clear_dirty_log	= arm_smmu_clear_dirty_log,
#endif
		.free			= arm_smmu_domain_free,
	}
};