]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commit
iommu/amd: Reserve exclusion range in iova-domain
authorJoerg Roedel <jroedel@suse.de>
Thu, 28 Mar 2019 10:44:59 +0000 (11:44 +0100)
committerStefan Bader <stefan.bader@canonical.com>
Tue, 2 Jul 2019 10:07:53 +0000 (12:07 +0200)
commit9be8b5005f8787da0960f911ac19a30966c83584
treee2c4a071f78f01f4ed7de3c306ec16de91570955
parent497db807935fd0f663139a774594502dce9af6cb
iommu/amd: Reserve exclusion range in iova-domain

BugLink: https://bugs.launchpad.net/bugs/1830934
[ Upstream commit 8aafaaf2212192012f5bae305bb31cdf7681d777 ]

If a device has an exclusion range specified in the IVRS
table, this region needs to be reserved in the iova-domain
of that device. This hasn't happened until now and can cause
data corruption on data transfered with these devices.

Treat exclusion ranges as reserved regions in the iommu-core
to fix the problem.

Fixes: be2a022c0dd0 ('x86, AMD IOMMU: add functions to parse IOMMU memory mapping requirements for devices')
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Reviewed-by: Gary R Hook <gary.hook@amd.com>
Signed-off-by: Sasha Levin (Microsoft) <sashal@kernel.org>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/iommu/amd_iommu.c
drivers/iommu/amd_iommu_init.c
drivers/iommu/amd_iommu_types.h