iommu: Remove device link to group on failure
authorJon Derrick <jonathan.derrick@intel.com>
Tue, 31 Dec 2019 20:24:19 +0000 (13:24 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 23 Jan 2020 07:19:34 +0000 (08:19 +0100)
commitc664cdb835f8a39af2594d903733bacf608c926f
tree6e9445bf131d27dc241a7b4996cec138c11323cc
parent26cd0d2644812ec5785090c097fc69bb029eff45
iommu: Remove device link to group on failure

commit 7d4e6ccd1fb09dbfbc49746ca82bd5c25ad4bfe4 upstream.

This adds the missing teardown step that removes the device link from
the group when the device addition fails.

Signed-off-by: Jon Derrick <jonathan.derrick@intel.com>
Fixes: 797a8b4d768c5 ("iommu: Handle default domain attach failure")
Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/iommu/iommu.c