Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4a349d06 authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "iommu/arm-smmu: fix issue by devm_free_irq on cb interrupt line"

parents 016d6205 ff5d6f72
Loading
Loading
Loading
Loading
+7 −6
Original line number Diff line number Diff line
@@ -1820,12 +1820,6 @@ static int arm_smmu_init_domain_context(struct iommu_domain *domain,
		goto out_unlock;

	cfg->cbndx = ret;
	if (smmu->version < ARM_SMMU_V2) {
		cfg->irptndx = atomic_inc_return(&smmu->irptndx);
		cfg->irptndx %= smmu->num_context_irqs;
	} else {
		cfg->irptndx = cfg->cbndx;
	}

	if (arm_smmu_is_slave_side_secure(smmu_domain)) {
		smmu_domain->pgtbl_cfg = (struct io_pgtable_cfg) {
@@ -1892,6 +1886,13 @@ static int arm_smmu_init_domain_context(struct iommu_domain *domain,
		if (ret)
			goto out_clear_smmu;

		if (smmu->version < ARM_SMMU_V2) {
			cfg->irptndx = atomic_inc_return(&smmu->irptndx);
			cfg->irptndx %= smmu->num_context_irqs;
		} else {
			cfg->irptndx = cfg->cbndx;
		}

		/*
		 * Request context fault interrupt. Do this last to avoid the
		 * handler seeing a half-initialised domain state.