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

Commit 6c5cc801 authored by Joerg Roedel's avatar Joerg Roedel
Browse files

iommu/amd: Use BUS_NOTIFY_REMOVED_DEVICE



Use the new device-notifier event instead of the old
BUS_NOTIFY_DEL_DEVICE to make sure the device driver had a
chance to uninit the device before all its mappings are
teared down.

Tested-by: default avatarSuravee Suthikulpanit <Suravee.Suthikulpanit@amd.com>
Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
parent 940f700d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2467,7 +2467,7 @@ static int device_change_notifier(struct notifier_block *nb,
		dev->archdata.dma_ops = &amd_iommu_dma_ops;

		break;
	case BUS_NOTIFY_DEL_DEVICE:
	case BUS_NOTIFY_REMOVED_DEVICE:

		iommu_uninit_device(dev);