x86/amd-iommu: Reenable AMD IOMMU if it's mysteriously vanished over suspend
authorMatthew Garrett <mjg@redhat.com>
Mon, 4 Oct 2010 18:59:31 +0000 (14:59 -0400)
committerJoerg Roedel <joerg.roedel@amd.com>
Wed, 13 Oct 2010 09:11:46 +0000 (11:11 +0200)
commit5bcd757f93cc713cf61bbeefceda7539d9afca55
treee9ab85ff4adfc3da19ea326999d850a4eacefc5d
parent899611ee7d373e5eeda08e9a8632684e1ebbbf00
x86/amd-iommu: Reenable AMD IOMMU if it's mysteriously vanished over suspend

AMD's reference BIOS code had a bug that could result in the
firmware failing to reenable the iommu on resume. It
transpires that this causes certain less than desirable
behaviour when it comes to PCI accesses, to whit them ending
up somewhere near Bristol when the more desirable outcome
was Edinburgh. Sadness ensues, perhaps along with filesystem
corruption.  Let's make sure that it gets turned back on,
and that we restore its configuration so decisions it makes
bear some resemblance to those made by reasonable people
rather than crack-addled lemurs who spent all your DMA on
Thunderbird.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
arch/x86/include/asm/amd_iommu_types.h
arch/x86/kernel/amd_iommu_init.c