path: root/drivers/iommu/amd_iommu_init.c
diff options
authorLinus Torvalds <torvalds@linux-foundation.org>2015-02-09 16:57:56 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2015-02-09 16:57:56 -0800
commit9d43bade347143b96671b38a7f81c39a81206675 (patch)
tree9c2126fa29fdbc6274f83be653de5f014e999f32 /drivers/iommu/amd_iommu_init.c
parent0ba97bc4b4b054b71cd348dab838a7545a27b893 (diff)
parentba360f887a4130b06c55eb93bcb4ae373b262a1c (diff)
Merge branch 'x86-apic-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 APIC updates from Ingo Molnar: "Continued fallout of the conversion of the x86 IRQ code to the hierarchical irqdomain framework: more cleanups, simplifications, memory allocation behavior enhancements, mainly in the interrupt remapping and APIC code" * 'x86-apic-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (44 commits) x86, init: Fix UP boot regression on x86_64 iommu/amd: Fix irq remapping detection logic x86/acpi: Make acpi_[un]register_gsi_ioapic() depend on CONFIG_X86_LOCAL_APIC x86: Consolidate boot cpu timer setup x86/apic: Reuse apic_bsp_setup() for UP APIC setup x86/smpboot: Sanitize uniprocessor init x86/smpboot: Move apic init code to apic.c init: Get rid of x86isms x86/apic: Move apic_init_uniprocessor code x86/smpboot: Cleanup ioapic handling x86/apic: Sanitize ioapic handling x86/ioapic: Add proper checks to setp/enable_IO_APIC() x86/ioapic: Provide stub functions for IOAPIC%3Dn x86/smpboot: Move smpboot inlines to code x86/x2apic: Use state information for disable x86/x2apic: Split enable and setup function x86/x2apic: Disable x2apic from nox2apic setup x86/x2apic: Add proper state tracking x86/x2apic: Clarify remapping mode for x2apic enablement x86/x2apic: Move code in conditional region ...
Diffstat (limited to 'drivers/iommu/amd_iommu_init.c')
1 files changed, 7 insertions, 8 deletions
diff --git a/drivers/iommu/amd_iommu_init.c b/drivers/iommu/amd_iommu_init.c
index b0522f15730f..9a20248e7068 100644
--- a/drivers/iommu/amd_iommu_init.c
+++ b/drivers/iommu/amd_iommu_init.c
@@ -2014,9 +2014,6 @@ static bool detect_ivrs(void)
/* Make sure ACS will be enabled during PCI probe */
- if (!disable_irq_remap)
- amd_iommu_irq_remap = true;
return true;
@@ -2123,12 +2120,14 @@ static int __init iommu_go_to_state(enum iommu_init_state state)
int __init amd_iommu_prepare(void)
- return iommu_go_to_state(IOMMU_ACPI_FINISHED);
+ int ret;
-int __init amd_iommu_supported(void)
- return amd_iommu_irq_remap ? 1 : 0;
+ amd_iommu_irq_remap = true;
+ ret = iommu_go_to_state(IOMMU_ACPI_FINISHED);
+ if (ret)
+ return ret;
+ return amd_iommu_irq_remap ? 0 : -ENODEV;
int __init amd_iommu_enable(void)

Privacy Policy