mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-06 14:48:06 +00:00
x86: remove ifdef CONFIG_GART_IOMMU in pci-dma.c
Our way to handle gart_* functions for CONFIG_GART_IOMMU and !CONFIG_GART_IOMMU cases is inconsistent. We have some dummy gart_* functions in !CONFIG_GART_IOMMU case and also use ifdef CONFIG_GART_IOMMU tricks in pci-dma.c to call some gart_* functions in only CONFIG_GART_IOMMU case. This patch removes ifdef CONFIG_GART_IOMMU in pci-dma.c and always use dummy gart_* functions in iommu.h. Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Acked-by: Muli Ben-Yehuda <muli@il.ibm.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
parent
46a7fa270a
commit
ac7ded2adb
2 changed files with 9 additions and 7 deletions
|
@ -114,9 +114,7 @@ void __init pci_iommu_alloc(void)
|
||||||
* The order of these functions is important for
|
* The order of these functions is important for
|
||||||
* fall-back/fail-over reasons
|
* fall-back/fail-over reasons
|
||||||
*/
|
*/
|
||||||
#ifdef CONFIG_GART_IOMMU
|
|
||||||
gart_iommu_hole_init();
|
gart_iommu_hole_init();
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_CALGARY_IOMMU
|
#ifdef CONFIG_CALGARY_IOMMU
|
||||||
detect_calgary();
|
detect_calgary();
|
||||||
|
@ -184,9 +182,7 @@ static __init int iommu_setup(char *p)
|
||||||
swiotlb = 1;
|
swiotlb = 1;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_GART_IOMMU
|
|
||||||
gart_parse_options(p);
|
gart_parse_options(p);
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_CALGARY_IOMMU
|
#ifdef CONFIG_CALGARY_IOMMU
|
||||||
if (!strncmp(p, "calgary", 7))
|
if (!strncmp(p, "calgary", 7))
|
||||||
|
@ -508,9 +504,7 @@ static int __init pci_iommu_init(void)
|
||||||
|
|
||||||
amd_iommu_init();
|
amd_iommu_init();
|
||||||
|
|
||||||
#ifdef CONFIG_GART_IOMMU
|
|
||||||
gart_iommu_init();
|
gart_iommu_init();
|
||||||
#endif
|
|
||||||
|
|
||||||
no_iommu_init();
|
no_iommu_init();
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -25,10 +25,18 @@ extern void gart_iommu_hole_init(void);
|
||||||
static inline void early_gart_iommu_check(void)
|
static inline void early_gart_iommu_check(void)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
static inline void gart_iommu_init(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
static inline void gart_iommu_shutdown(void)
|
static inline void gart_iommu_shutdown(void)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
static inline void gart_parse_options(char *options)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
static inline void gart_iommu_hole_init(void)
|
||||||
|
{
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Reference in a new issue