Skip to content

Commit 801f92a

Browse files
Haavard SkinnemoenLinus Torvalds
authored andcommitted
[PATCH] Generic ioremap_page_range: alpha conversion
Convert Alpha to use generic ioremap_page_range() by turning __alpha_remap_area_pages() into an inline wrapper around ioremap_page_range(). Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com> Cc: Richard Henderson <rth@twiddle.net> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
1 parent db71daa commit 801f92a

3 files changed

Lines changed: 13 additions & 90 deletions

File tree

‎arch/alpha/kernel/proto.h‎

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#include <linux/interrupt.h>
2+
#include <linux/io.h>
23

4+
#include <asm/pgtable.h>
35

46
/* Prototypes of functions used across modules here in this directory. */
57

@@ -181,9 +183,16 @@ extern void titan_dispatch_irqs(u64, struct pt_regs *);
181183
extern void switch_to_system_map(void);
182184
extern void srm_paging_stop(void);
183185

184-
/* ../mm/remap.c */
185-
extern int __alpha_remap_area_pages(unsigned long, unsigned long,
186-
unsigned long, unsigned long);
186+
static inline int
187+
__alpha_remap_area_pages(unsigned long address, unsigned long phys_addr,
188+
unsigned long size, unsigned long flags)
189+
{
190+
pgprot_t prot;
191+
192+
prot = __pgprot(_PAGE_VALID | _PAGE_ASM | _PAGE_KRE
193+
| _PAGE_KWE | flags);
194+
return ioremap_page_range(address, address + size, phys_addr, prot);
195+
}
187196

188197
/* irq.c */
189198

‎arch/alpha/mm/Makefile‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44

55
EXTRA_CFLAGS := -Werror
66

7-
obj-y := init.o fault.o extable.o remap.o
7+
obj-y := init.o fault.o extable.o
88

99
obj-$(CONFIG_DISCONTIGMEM) += numa.o

‎arch/alpha/mm/remap.c‎

Lines changed: 0 additions & 86 deletions
This file was deleted.

0 commit comments

Comments
 (0)