diff options
Diffstat (limited to 'lib/ioremap.c')
-rw-r--r-- | lib/ioremap.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/lib/ioremap.c b/lib/ioremap.c index 14c6078f17a2..da4e2ad74b68 100644 --- a/lib/ioremap.c +++ b/lib/ioremap.c | |||
@@ -9,14 +9,15 @@ | |||
9 | #include <linux/mm.h> | 9 | #include <linux/mm.h> |
10 | #include <linux/sched.h> | 10 | #include <linux/sched.h> |
11 | #include <linux/io.h> | 11 | #include <linux/io.h> |
12 | #include <linux/module.h> | ||
12 | #include <asm/cacheflush.h> | 13 | #include <asm/cacheflush.h> |
13 | #include <asm/pgtable.h> | 14 | #include <asm/pgtable.h> |
14 | 15 | ||
15 | static int ioremap_pte_range(pmd_t *pmd, unsigned long addr, | 16 | static int ioremap_pte_range(pmd_t *pmd, unsigned long addr, |
16 | unsigned long end, unsigned long phys_addr, pgprot_t prot) | 17 | unsigned long end, phys_addr_t phys_addr, pgprot_t prot) |
17 | { | 18 | { |
18 | pte_t *pte; | 19 | pte_t *pte; |
19 | unsigned long pfn; | 20 | u64 pfn; |
20 | 21 | ||
21 | pfn = phys_addr >> PAGE_SHIFT; | 22 | pfn = phys_addr >> PAGE_SHIFT; |
22 | pte = pte_alloc_kernel(pmd, addr); | 23 | pte = pte_alloc_kernel(pmd, addr); |
@@ -31,7 +32,7 @@ static int ioremap_pte_range(pmd_t *pmd, unsigned long addr, | |||
31 | } | 32 | } |
32 | 33 | ||
33 | static inline int ioremap_pmd_range(pud_t *pud, unsigned long addr, | 34 | static inline int ioremap_pmd_range(pud_t *pud, unsigned long addr, |
34 | unsigned long end, unsigned long phys_addr, pgprot_t prot) | 35 | unsigned long end, phys_addr_t phys_addr, pgprot_t prot) |
35 | { | 36 | { |
36 | pmd_t *pmd; | 37 | pmd_t *pmd; |
37 | unsigned long next; | 38 | unsigned long next; |
@@ -49,7 +50,7 @@ static inline int ioremap_pmd_range(pud_t *pud, unsigned long addr, | |||
49 | } | 50 | } |
50 | 51 | ||
51 | static inline int ioremap_pud_range(pgd_t *pgd, unsigned long addr, | 52 | static inline int ioremap_pud_range(pgd_t *pgd, unsigned long addr, |
52 | unsigned long end, unsigned long phys_addr, pgprot_t prot) | 53 | unsigned long end, phys_addr_t phys_addr, pgprot_t prot) |
53 | { | 54 | { |
54 | pud_t *pud; | 55 | pud_t *pud; |
55 | unsigned long next; | 56 | unsigned long next; |
@@ -67,7 +68,7 @@ static inline int ioremap_pud_range(pgd_t *pgd, unsigned long addr, | |||
67 | } | 68 | } |
68 | 69 | ||
69 | int ioremap_page_range(unsigned long addr, | 70 | int ioremap_page_range(unsigned long addr, |
70 | unsigned long end, unsigned long phys_addr, pgprot_t prot) | 71 | unsigned long end, phys_addr_t phys_addr, pgprot_t prot) |
71 | { | 72 | { |
72 | pgd_t *pgd; | 73 | pgd_t *pgd; |
73 | unsigned long start; | 74 | unsigned long start; |
@@ -90,3 +91,4 @@ int ioremap_page_range(unsigned long addr, | |||
90 | 91 | ||
91 | return err; | 92 | return err; |
92 | } | 93 | } |
94 | EXPORT_SYMBOL_GPL(ioremap_page_range); | ||