[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20091110111219.GA32342@elte.hu>
Date: Tue, 10 Nov 2009 12:12:19 +0100
From: Ingo Molnar <mingo@...e.hu>
To: FUJITA Tomonori <fujita.tomonori@....ntt.co.jp>
Cc: linux-kernel@...r.kernel.org, chrisw@...s-sol.org,
wmw2@...radead.org, joerg.roedel@....com, muli@...ibm.com
Subject: Re: [PATCH -v2 5/9] intel-iommu: convert detect_intel_iommu to use
iommu_init hook
* FUJITA Tomonori <fujita.tomonori@....ntt.co.jp> wrote:
> This changes detect_intel_iommu() to set intel_iommu_init() to
> iommu_init hook if detect_intel_iommu() finds the IOMMU.
>
> Signed-off-by: FUJITA Tomonori <fujita.tomonori@....ntt.co.jp>
> ---
> arch/x86/kernel/pci-dma.c | 2 --
> drivers/pci/dmar.c | 4 ++++
> include/linux/dmar.h | 10 ----------
> 3 files changed, 4 insertions(+), 12 deletions(-)
FYI, the !CONFIG_DMAR case needed the fix below. (Wrt. the -ENODEV: it
doesnt matter right now as we dont check the result of ->iommu_init(),
but i kept it consistent with device initialization principles.)
Ingo
diff --git a/include/linux/dmar.h b/include/linux/dmar.h
index d814d7d..df0cfb3 100644
--- a/include/linux/dmar.h
+++ b/include/linux/dmar.h
@@ -219,5 +219,8 @@ struct dmar_atsr_unit {
};
extern int intel_iommu_init(void);
-#endif
+#else /* !CONFIG_DMAR: */
+static inline int intel_iommu_init(void) { return -ENODEV; }
+#endif /* CONFIG_DMAR */
+
#endif /* __DMAR_H__ */
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists