Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 169214
b: refs/heads/master
c: d7b9f7b
h: refs/heads/master
v: v3
  • Loading branch information
FUJITA Tomonori authored and Ingo Molnar committed Nov 10, 2009
1 parent 33c1bdd commit bcd6606
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: d07c1be0693e0902d743160b8b638585b808f8ac
refs/heads/master: d7b9f7be216b04ff9d108f856bc03d96e7b3439c
2 changes: 0 additions & 2 deletions trunk/arch/x86/include/asm/calgary.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,8 @@ struct cal_chipset_ops {
extern int use_calgary;

#ifdef CONFIG_CALGARY_IOMMU
extern int calgary_iommu_init(void);
extern void detect_calgary(void);
#else
static inline int calgary_iommu_init(void) { return 1; }
static inline void detect_calgary(void) { return; }
#endif

Expand Down
11 changes: 5 additions & 6 deletions trunk/arch/x86/kernel/pci-calgary_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
#include <asm/dma.h>
#include <asm/rio.h>
#include <asm/bios_ebda.h>
#include <asm/x86_init.h>

#ifdef CONFIG_CALGARY_IOMMU_ENABLED_BY_DEFAULT
int use_calgary __read_mostly = 1;
Expand Down Expand Up @@ -1344,6 +1345,8 @@ static void __init get_tce_space_from_tar(void)
return;
}

int __init calgary_iommu_init(void);

void __init detect_calgary(void)
{
int bus;
Expand Down Expand Up @@ -1445,6 +1448,8 @@ void __init detect_calgary(void)
/* swiotlb for devices that aren't behind the Calgary. */
if (max_pfn > MAX_DMA32_PFN)
swiotlb = 1;

x86_init.iommu.iommu_init = calgary_iommu_init;
}
return;

Expand All @@ -1461,12 +1466,6 @@ int __init calgary_iommu_init(void)
{
int ret;

if (no_iommu || (swiotlb && !calgary_detected))
return -ENODEV;

if (!calgary_detected)
return -ENODEV;

/* ok, we're trying to use Calgary - let's roll */
printk(KERN_INFO "PCI-DMA: Using Calgary IOMMU\n");

Expand Down
2 changes: 0 additions & 2 deletions trunk/arch/x86/kernel/pci-dma.c
Original file line number Diff line number Diff line change
Expand Up @@ -294,8 +294,6 @@ static int __init pci_iommu_init(void)

x86_init.iommu.iommu_init();

calgary_iommu_init();

intel_iommu_init();

amd_iommu_init();
Expand Down

0 comments on commit bcd6606

Please sign in to comment.