diff options
author | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2008-07-29 00:38:53 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-29 06:12:48 -0400 |
commit | 8978b74253280d59e97cf49a3ec2c0cbccd5b801 (patch) | |
tree | 7cecd6951437f01f541178c1afc14d4e1d2e2b23 /include | |
parent | 35780c8ea7ad5c6d5483244d5f5bf37176fda86a (diff) |
generic, x86: fix add iommu_num_pages helper function
This IOMMU helper function doesn't work for some architectures:
http://marc.info/?l=linux-kernel&m=121699304403202&w=2
It also breaks POWER and SPARC builds:
http://marc.info/?l=linux-kernel&m=121730388001890&w=2
Currently, only x86 IOMMUs use this so let's move it to x86 for
now.
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-x86/iommu.h | 2 | ||||
-rw-r--r-- | include/linux/iommu-helper.h | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/include/asm-x86/iommu.h b/include/asm-x86/iommu.h index ecc8061904a9..5f888cc5be49 100644 --- a/include/asm-x86/iommu.h +++ b/include/asm-x86/iommu.h | |||
@@ -7,6 +7,8 @@ extern struct dma_mapping_ops nommu_dma_ops; | |||
7 | extern int force_iommu, no_iommu; | 7 | extern int force_iommu, no_iommu; |
8 | extern int iommu_detected; | 8 | extern int iommu_detected; |
9 | 9 | ||
10 | extern unsigned long iommu_num_pages(unsigned long addr, unsigned long len); | ||
11 | |||
10 | #ifdef CONFIG_GART_IOMMU | 12 | #ifdef CONFIG_GART_IOMMU |
11 | extern int gart_iommu_aperture; | 13 | extern int gart_iommu_aperture; |
12 | extern int gart_iommu_aperture_allowed; | 14 | extern int gart_iommu_aperture_allowed; |
diff --git a/include/linux/iommu-helper.h b/include/linux/iommu-helper.h index f8598f583944..c975caf75385 100644 --- a/include/linux/iommu-helper.h +++ b/include/linux/iommu-helper.h | |||
@@ -8,4 +8,3 @@ extern unsigned long iommu_area_alloc(unsigned long *map, unsigned long size, | |||
8 | unsigned long align_mask); | 8 | unsigned long align_mask); |
9 | extern void iommu_area_free(unsigned long *map, unsigned long start, | 9 | extern void iommu_area_free(unsigned long *map, unsigned long start, |
10 | unsigned int nr); | 10 | unsigned int nr); |
11 | extern unsigned long iommu_num_pages(unsigned long addr, unsigned long len); | ||