]> git.baikalelectronics.ru Git - kernel.git/commit
iommu: Improve error handling when setting bus iommu
authorHeiko Stübner <heiko@sntech.de>
Wed, 29 Oct 2014 00:22:56 +0000 (01:22 +0100)
committerJoerg Roedel <jroedel@suse.de>
Tue, 4 Nov 2014 14:00:48 +0000 (15:00 +0100)
commita91554e1dafda9793e3204c11c424cab46c233b3
tree65411798415b8d124525ee4d51426b08f47fd028
parentdf10cc33886cfe3a144d6ef07ad4f9de2910c878
iommu: Improve error handling when setting bus iommu

When some part of bus_set_iommu fails it should undo any made changes
and not simply leave everything as is.

This includes unregistering the bus notifier in iommu_bus_init when
add_iommu_group fails and also setting the bus->iommu_ops back to NULL.

Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/iommu.c