iommu/tegra-smmu: Properly release domain resources
Release all memory allocations associated with a released domain and emit warning if domain is in-use at the time of destruction. Signed-off-by: Dmitry Osipenko <digetx@gmail.com> Acked-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Joerg Roedel <jroedel@suse.de>
This commit is contained in:
parent
43a0541e31
commit
4f97031ff8
|
@ -327,6 +327,9 @@ static void tegra_smmu_domain_free(struct iommu_domain *domain)
|
||||||
|
|
||||||
/* TODO: free page directory and page tables */
|
/* TODO: free page directory and page tables */
|
||||||
|
|
||||||
|
WARN_ON_ONCE(as->use_count);
|
||||||
|
kfree(as->count);
|
||||||
|
kfree(as->pts);
|
||||||
kfree(as);
|
kfree(as);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue