diff options
Diffstat (limited to 'arch/um/kernel')
-rw-r--r-- | arch/um/kernel/irq.c | 11 | ||||
-rw-r--r-- | arch/um/kernel/irq_user.c | 2 | ||||
-rw-r--r-- | arch/um/kernel/mem.c | 1 | ||||
-rw-r--r-- | arch/um/kernel/tt/Makefile | 15 | ||||
-rw-r--r-- | arch/um/kernel/tt/unmap.c | 31 | ||||
-rw-r--r-- | arch/um/kernel/uml.lds.S | 15 |
6 files changed, 10 insertions, 65 deletions
diff --git a/arch/um/kernel/irq.c b/arch/um/kernel/irq.c index d44fb5282547..9f18061ef4c9 100644 --- a/arch/um/kernel/irq.c +++ b/arch/um/kernel/irq.c | |||
@@ -124,14 +124,16 @@ void irq_unlock(unsigned long flags) | |||
124 | spin_unlock_irqrestore(&irq_spinlock, flags); | 124 | spin_unlock_irqrestore(&irq_spinlock, flags); |
125 | } | 125 | } |
126 | 126 | ||
127 | /* presently hw_interrupt_type must define (startup || enable) && | 127 | /* hw_interrupt_type must define (startup || enable) && |
128 | * disable && end */ | 128 | * (shutdown || disable) && end */ |
129 | static void dummy(unsigned int irq) | 129 | static void dummy(unsigned int irq) |
130 | { | 130 | { |
131 | } | 131 | } |
132 | 132 | ||
133 | static struct hw_interrupt_type SIGIO_irq_type = { | 133 | /* This is used for everything else than the timer. */ |
134 | static struct hw_interrupt_type normal_irq_type = { | ||
134 | .typename = "SIGIO", | 135 | .typename = "SIGIO", |
136 | .release = free_irq_by_irq_and_dev, | ||
135 | .disable = dummy, | 137 | .disable = dummy, |
136 | .enable = dummy, | 138 | .enable = dummy, |
137 | .ack = dummy, | 139 | .ack = dummy, |
@@ -140,6 +142,7 @@ static struct hw_interrupt_type SIGIO_irq_type = { | |||
140 | 142 | ||
141 | static struct hw_interrupt_type SIGVTALRM_irq_type = { | 143 | static struct hw_interrupt_type SIGVTALRM_irq_type = { |
142 | .typename = "SIGVTALRM", | 144 | .typename = "SIGVTALRM", |
145 | .release = free_irq_by_irq_and_dev, | ||
143 | .shutdown = dummy, /* never called */ | 146 | .shutdown = dummy, /* never called */ |
144 | .disable = dummy, | 147 | .disable = dummy, |
145 | .enable = dummy, | 148 | .enable = dummy, |
@@ -160,7 +163,7 @@ void __init init_IRQ(void) | |||
160 | irq_desc[i].status = IRQ_DISABLED; | 163 | irq_desc[i].status = IRQ_DISABLED; |
161 | irq_desc[i].action = NULL; | 164 | irq_desc[i].action = NULL; |
162 | irq_desc[i].depth = 1; | 165 | irq_desc[i].depth = 1; |
163 | irq_desc[i].handler = &SIGIO_irq_type; | 166 | irq_desc[i].handler = &normal_irq_type; |
164 | enable_irq(i); | 167 | enable_irq(i); |
165 | } | 168 | } |
166 | } | 169 | } |
diff --git a/arch/um/kernel/irq_user.c b/arch/um/kernel/irq_user.c index b3074cbaa479..c3ccaf24f3e0 100644 --- a/arch/um/kernel/irq_user.c +++ b/arch/um/kernel/irq_user.c | |||
@@ -85,8 +85,6 @@ void sigio_handler(int sig, union uml_pt_regs *regs) | |||
85 | next = irq_fd->next; | 85 | next = irq_fd->next; |
86 | if(irq_fd->freed){ | 86 | if(irq_fd->freed){ |
87 | free_irq(irq_fd->irq, irq_fd->id); | 87 | free_irq(irq_fd->irq, irq_fd->id); |
88 | free_irq_by_irq_and_dev(irq_fd->irq, | ||
89 | irq_fd->id); | ||
90 | } | 88 | } |
91 | } | 89 | } |
92 | } | 90 | } |
diff --git a/arch/um/kernel/mem.c b/arch/um/kernel/mem.c index c22825f13e40..5597bd39e6b5 100644 --- a/arch/um/kernel/mem.c +++ b/arch/um/kernel/mem.c | |||
@@ -53,7 +53,6 @@ static void setup_highmem(unsigned long highmem_start, | |||
53 | for(i = 0; i < highmem_len >> PAGE_SHIFT; i++){ | 53 | for(i = 0; i < highmem_len >> PAGE_SHIFT; i++){ |
54 | page = &mem_map[highmem_pfn + i]; | 54 | page = &mem_map[highmem_pfn + i]; |
55 | ClearPageReserved(page); | 55 | ClearPageReserved(page); |
56 | set_bit(PG_highmem, &page->flags); | ||
57 | set_page_count(page, 1); | 56 | set_page_count(page, 1); |
58 | __free_page(page); | 57 | __free_page(page); |
59 | } | 58 | } |
diff --git a/arch/um/kernel/tt/Makefile b/arch/um/kernel/tt/Makefile index c3faea21a996..3fd2554e60b6 100644 --- a/arch/um/kernel/tt/Makefile +++ b/arch/um/kernel/tt/Makefile | |||
@@ -3,10 +3,6 @@ | |||
3 | # Licensed under the GPL | 3 | # Licensed under the GPL |
4 | # | 4 | # |
5 | 5 | ||
6 | extra-y := unmap_fin.o | ||
7 | targets := unmap.o | ||
8 | clean-files := unmap_tmp.o | ||
9 | |||
10 | obj-y = exec_kern.o exec_user.o gdb.o ksyms.o mem.o mem_user.o process_kern.o \ | 6 | obj-y = exec_kern.o exec_user.o gdb.o ksyms.o mem.o mem_user.o process_kern.o \ |
11 | syscall_kern.o syscall_user.o time.o tlb.o tracer.o trap_user.o \ | 7 | syscall_kern.o syscall_user.o time.o tlb.o tracer.o trap_user.o \ |
12 | uaccess.o uaccess_user.o | 8 | uaccess.o uaccess_user.o |
@@ -16,14 +12,3 @@ obj-$(CONFIG_PT_PROXY) += gdb_kern.o ptproxy/ | |||
16 | USER_OBJS := gdb.o time.o tracer.o | 12 | USER_OBJS := gdb.o time.o tracer.o |
17 | 13 | ||
18 | include arch/um/scripts/Makefile.rules | 14 | include arch/um/scripts/Makefile.rules |
19 | |||
20 | UNMAP_CFLAGS := $(patsubst -pg -DPROFILING,,$(USER_CFLAGS)) | ||
21 | UNMAP_CFLAGS := $(patsubst -fprofile-arcs -ftest-coverage,,$(UNMAP_CFLAGS)) | ||
22 | |||
23 | #XXX: partially copied from arch/um/scripts/Makefile.rules | ||
24 | $(obj)/unmap.o: c_flags = -Wp,-MD,$(depfile) $(UNMAP_CFLAGS) | ||
25 | |||
26 | $(obj)/unmap_fin.o : $(obj)/unmap.o | ||
27 | $(LD) -r -o $(obj)/unmap_tmp.o $< $(shell $(CC) -print-file-name=libc.a) | ||
28 | $(OBJCOPY) $(obj)/unmap_tmp.o $@ -G switcheroo | ||
29 | |||
diff --git a/arch/um/kernel/tt/unmap.c b/arch/um/kernel/tt/unmap.c deleted file mode 100644 index 3f7aecdbe532..000000000000 --- a/arch/um/kernel/tt/unmap.c +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2000 Jeff Dike (jdike@karaya.com) | ||
3 | * Licensed under the GPL | ||
4 | */ | ||
5 | |||
6 | #include <sys/mman.h> | ||
7 | |||
8 | int switcheroo(int fd, int prot, void *from, void *to, int size) | ||
9 | { | ||
10 | if(munmap(to, size) < 0){ | ||
11 | return(-1); | ||
12 | } | ||
13 | if(mmap(to, size, prot, MAP_SHARED | MAP_FIXED, fd, 0) != to){ | ||
14 | return(-1); | ||
15 | } | ||
16 | if(munmap(from, size) < 0){ | ||
17 | return(-1); | ||
18 | } | ||
19 | return(0); | ||
20 | } | ||
21 | |||
22 | /* | ||
23 | * Overrides for Emacs so that we follow Linus's tabbing style. | ||
24 | * Emacs will notice this stuff at the end of the file and automatically | ||
25 | * adjust the settings for this buffer only. This must remain at the end | ||
26 | * of the file. | ||
27 | * --------------------------------------------------------------------------- | ||
28 | * Local variables: | ||
29 | * c-file-style: "linux" | ||
30 | * End: | ||
31 | */ | ||
diff --git a/arch/um/kernel/uml.lds.S b/arch/um/kernel/uml.lds.S index dd5355500bdc..61dfd4fef752 100644 --- a/arch/um/kernel/uml.lds.S +++ b/arch/um/kernel/uml.lds.S | |||
@@ -14,19 +14,10 @@ SECTIONS | |||
14 | /* Used in arch/um/kernel/mem.c. Any memory between START and __binary_start | 14 | /* Used in arch/um/kernel/mem.c. Any memory between START and __binary_start |
15 | * is remapped.*/ | 15 | * is remapped.*/ |
16 | __binary_start = .; | 16 | __binary_start = .; |
17 | #ifdef MODE_TT | ||
18 | .thread_private : { | ||
19 | __start_thread_private = .; | ||
20 | errno = .; | ||
21 | . += 4; | ||
22 | arch/um/kernel/tt/unmap_fin.o (.data) | ||
23 | __end_thread_private = .; | ||
24 | } | ||
25 | . = ALIGN(4096); | ||
26 | .remap : { arch/um/kernel/tt/unmap_fin.o (.text) } | ||
27 | 17 | ||
28 | /* We want it only if we are in MODE_TT. In both cases, however, when MODE_TT | 18 | #ifdef MODE_TT |
29 | * is off the resulting binary segfaults.*/ | 19 | .remap_data : { arch/um/sys-SUBARCH/unmap_fin.o (.data .bss) } |
20 | .remap : { arch/um/sys-SUBARCH/unmap_fin.o (.text) } | ||
30 | 21 | ||
31 | . = ALIGN(4096); /* Init code and data */ | 22 | . = ALIGN(4096); /* Init code and data */ |
32 | #endif | 23 | #endif |