x86/amd-iommu: Use helper function to destroy domain
commit0415a7a7068c9cb7d5b34d3a5141a0b87dea8cf7
authorJoerg Roedel <joerg.roedel@amd.com>
Mon, 8 Mar 2010 13:20:07 +0000 (8 14:20 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 26 Apr 2010 14:41:26 +0000 (26 07:41 -0700)
treedf635e10df61c19c3790169d66c1f82243bf820d
parent089017d7f11ae1deef16bbd08d7536c13954ebbc
x86/amd-iommu: Use helper function to destroy domain

commit 8b408fe4f853dcfa18d133aa4cf1d7546b4c3870 upstream.

In the amd_iommu_domain_destroy the protection_domain_free
function is partly reimplemented. The 'partly' is the bug
here because the domain is not deleted from the domain list.
This results in use-after-free errors and data-corruption.
Fix it by just using protection_domain_free instead.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
arch/x86/kernel/amd_iommu.c