diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-05-23 12:01:41 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-05-23 12:01:41 -0400 |
commit | 3a8580f82024e30b31c662aa49346adf7a3bcdb5 (patch) | |
tree | 7769a01f152b4081f4e4225e499082fd5c67b184 /arch/um | |
parent | 1d767cae4dbd4116fc3b2cc3251a20760f98339f (diff) | |
parent | 2ccf62b36097aa88e0ea152d6ef0c0ca2d3884e6 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml
Pull UML updates from Richard Weinberger:
"Most changes are bug fixes and cleanups"
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml:
um: missing checks of __put_user()/__get_user() return values
um: stub_rt_sigsuspend isn't needed these days anymore
um/x86: merge (and trim) 32- and 64-bit variants of ptrace.h
irq: Remove irq_chip->release()
um: Remove CONFIG_IRQ_RELEASE_METHOD
um: Remove usage of irq_chip->release()
um: Implement um_free_irq()
um: Fix __swp_type()
um: Implement a custom pte_same() function
um: Add BUG() to do_ops()'s error path
um: Remove unused variables
um: bury unused _TIF_RESTORE_SIGMASK
um: wrong sigmask saved in case of multiple sigframes
um: add TIF_NOTIFY_RESUME
um: ->restart_block.fn needs to be reset on sigreturn
Diffstat (limited to 'arch/um')
-rw-r--r-- | arch/um/Kconfig.common | 5 | ||||
-rw-r--r-- | arch/um/defconfig | 1 | ||||
-rw-r--r-- | arch/um/drivers/chan_kern.c | 9 | ||||
-rw-r--r-- | arch/um/drivers/line.c | 2 | ||||
-rw-r--r-- | arch/um/drivers/net_kern.c | 4 | ||||
-rw-r--r-- | arch/um/drivers/port_kern.c | 2 | ||||
-rw-r--r-- | arch/um/drivers/xterm_kern.c | 2 | ||||
-rw-r--r-- | arch/um/include/asm/pgtable.h | 10 | ||||
-rw-r--r-- | arch/um/include/asm/thread_info.h | 2 | ||||
-rw-r--r-- | arch/um/include/shared/irq_kern.h | 2 | ||||
-rw-r--r-- | arch/um/kernel/irq.c | 9 | ||||
-rw-r--r-- | arch/um/kernel/process.c | 10 | ||||
-rw-r--r-- | arch/um/kernel/signal.c | 14 | ||||
-rw-r--r-- | arch/um/kernel/skas/syscall.c | 2 | ||||
-rw-r--r-- | arch/um/kernel/tlb.c | 1 | ||||
-rw-r--r-- | arch/um/os-Linux/skas/mem.c | 10 |
16 files changed, 42 insertions, 43 deletions
diff --git a/arch/um/Kconfig.common b/arch/um/Kconfig.common index 20a49ba93cb9..43ef890d292c 100644 --- a/arch/um/Kconfig.common +++ b/arch/um/Kconfig.common | |||
@@ -56,11 +56,6 @@ config GENERIC_CLOCKEVENTS | |||
56 | bool | 56 | bool |
57 | default y | 57 | default y |
58 | 58 | ||
59 | # Used in kernel/irq/manage.c and include/linux/irq.h | ||
60 | config IRQ_RELEASE_METHOD | ||
61 | bool | ||
62 | default y | ||
63 | |||
64 | config HZ | 59 | config HZ |
65 | int | 60 | int |
66 | default 100 | 61 | default 100 |
diff --git a/arch/um/defconfig b/arch/um/defconfig index fdc97e2c3d73..7823ab12e6a4 100644 --- a/arch/um/defconfig +++ b/arch/um/defconfig | |||
@@ -12,7 +12,6 @@ CONFIG_LOCKDEP_SUPPORT=y | |||
12 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 12 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
13 | CONFIG_GENERIC_BUG=y | 13 | CONFIG_GENERIC_BUG=y |
14 | CONFIG_GENERIC_CLOCKEVENTS=y | 14 | CONFIG_GENERIC_CLOCKEVENTS=y |
15 | CONFIG_IRQ_RELEASE_METHOD=y | ||
16 | CONFIG_HZ=100 | 15 | CONFIG_HZ=100 |
17 | 16 | ||
18 | # | 17 | # |
diff --git a/arch/um/drivers/chan_kern.c b/arch/um/drivers/chan_kern.c index ca4c7ebfd0aa..45e248c2f43c 100644 --- a/arch/um/drivers/chan_kern.c +++ b/arch/um/drivers/chan_kern.c | |||
@@ -8,6 +8,7 @@ | |||
8 | #include <linux/tty_flip.h> | 8 | #include <linux/tty_flip.h> |
9 | #include "chan.h" | 9 | #include "chan.h" |
10 | #include "os.h" | 10 | #include "os.h" |
11 | #include "irq_kern.h" | ||
11 | 12 | ||
12 | #ifdef CONFIG_NOCONFIG_CHAN | 13 | #ifdef CONFIG_NOCONFIG_CHAN |
13 | static void *not_configged_init(char *str, int device, | 14 | static void *not_configged_init(char *str, int device, |
@@ -213,9 +214,9 @@ void free_irqs(void) | |||
213 | chan = list_entry(ele, struct chan, free_list); | 214 | chan = list_entry(ele, struct chan, free_list); |
214 | 215 | ||
215 | if (chan->input && chan->enabled) | 216 | if (chan->input && chan->enabled) |
216 | free_irq(chan->line->driver->read_irq, chan); | 217 | um_free_irq(chan->line->driver->read_irq, chan); |
217 | if (chan->output && chan->enabled) | 218 | if (chan->output && chan->enabled) |
218 | free_irq(chan->line->driver->write_irq, chan); | 219 | um_free_irq(chan->line->driver->write_irq, chan); |
219 | chan->enabled = 0; | 220 | chan->enabled = 0; |
220 | } | 221 | } |
221 | } | 222 | } |
@@ -234,9 +235,9 @@ static void close_one_chan(struct chan *chan, int delay_free_irq) | |||
234 | } | 235 | } |
235 | else { | 236 | else { |
236 | if (chan->input && chan->enabled) | 237 | if (chan->input && chan->enabled) |
237 | free_irq(chan->line->driver->read_irq, chan); | 238 | um_free_irq(chan->line->driver->read_irq, chan); |
238 | if (chan->output && chan->enabled) | 239 | if (chan->output && chan->enabled) |
239 | free_irq(chan->line->driver->write_irq, chan); | 240 | um_free_irq(chan->line->driver->write_irq, chan); |
240 | chan->enabled = 0; | 241 | chan->enabled = 0; |
241 | } | 242 | } |
242 | if (chan->ops->close != NULL) | 243 | if (chan->ops->close != NULL) |
diff --git a/arch/um/drivers/line.c b/arch/um/drivers/line.c index 4ab0d9c0911c..acfd0e0fd0c9 100644 --- a/arch/um/drivers/line.c +++ b/arch/um/drivers/line.c | |||
@@ -699,7 +699,7 @@ struct winch { | |||
699 | static void __free_winch(struct work_struct *work) | 699 | static void __free_winch(struct work_struct *work) |
700 | { | 700 | { |
701 | struct winch *winch = container_of(work, struct winch, work); | 701 | struct winch *winch = container_of(work, struct winch, work); |
702 | free_irq(WINCH_IRQ, winch); | 702 | um_free_irq(WINCH_IRQ, winch); |
703 | 703 | ||
704 | if (winch->pid != -1) | 704 | if (winch->pid != -1) |
705 | os_kill_process(winch->pid, 1); | 705 | os_kill_process(winch->pid, 1); |
diff --git a/arch/um/drivers/net_kern.c b/arch/um/drivers/net_kern.c index 95f4416e6d9f..0d60c5685c26 100644 --- a/arch/um/drivers/net_kern.c +++ b/arch/um/drivers/net_kern.c | |||
@@ -195,7 +195,7 @@ static int uml_net_close(struct net_device *dev) | |||
195 | 195 | ||
196 | netif_stop_queue(dev); | 196 | netif_stop_queue(dev); |
197 | 197 | ||
198 | free_irq(dev->irq, dev); | 198 | um_free_irq(dev->irq, dev); |
199 | if (lp->close != NULL) | 199 | if (lp->close != NULL) |
200 | (*lp->close)(lp->fd, &lp->user); | 200 | (*lp->close)(lp->fd, &lp->user); |
201 | lp->fd = -1; | 201 | lp->fd = -1; |
@@ -835,7 +835,7 @@ static void close_devices(void) | |||
835 | spin_lock(&opened_lock); | 835 | spin_lock(&opened_lock); |
836 | list_for_each(ele, &opened) { | 836 | list_for_each(ele, &opened) { |
837 | lp = list_entry(ele, struct uml_net_private, list); | 837 | lp = list_entry(ele, struct uml_net_private, list); |
838 | free_irq(lp->dev->irq, lp->dev); | 838 | um_free_irq(lp->dev->irq, lp->dev); |
839 | if ((lp->close != NULL) && (lp->fd >= 0)) | 839 | if ((lp->close != NULL) && (lp->fd >= 0)) |
840 | (*lp->close)(lp->fd, &lp->user); | 840 | (*lp->close)(lp->fd, &lp->user); |
841 | if (lp->remove != NULL) | 841 | if (lp->remove != NULL) |
diff --git a/arch/um/drivers/port_kern.c b/arch/um/drivers/port_kern.c index e31680e662a4..11866ffd45a9 100644 --- a/arch/um/drivers/port_kern.c +++ b/arch/um/drivers/port_kern.c | |||
@@ -254,7 +254,7 @@ int port_wait(void *data) | |||
254 | * connection. Then we loop here throwing out failed | 254 | * connection. Then we loop here throwing out failed |
255 | * connections until a good one is found. | 255 | * connections until a good one is found. |
256 | */ | 256 | */ |
257 | free_irq(TELNETD_IRQ, conn); | 257 | um_free_irq(TELNETD_IRQ, conn); |
258 | 258 | ||
259 | if (conn->fd >= 0) | 259 | if (conn->fd >= 0) |
260 | break; | 260 | break; |
diff --git a/arch/um/drivers/xterm_kern.c b/arch/um/drivers/xterm_kern.c index 8bd130f0bda3..b68bbe269e01 100644 --- a/arch/um/drivers/xterm_kern.c +++ b/arch/um/drivers/xterm_kern.c | |||
@@ -65,7 +65,7 @@ int xterm_fd(int socket, int *pid_out) | |||
65 | * isn't set) this will hang... */ | 65 | * isn't set) this will hang... */ |
66 | wait_for_completion(&data->ready); | 66 | wait_for_completion(&data->ready); |
67 | 67 | ||
68 | free_irq(XTERM_IRQ, data); | 68 | um_free_irq(XTERM_IRQ, data); |
69 | 69 | ||
70 | ret = data->new_fd; | 70 | ret = data->new_fd; |
71 | *pid_out = data->pid; | 71 | *pid_out = data->pid; |
diff --git a/arch/um/include/asm/pgtable.h b/arch/um/include/asm/pgtable.h index 6a3f9845743e..5888f1b83477 100644 --- a/arch/um/include/asm/pgtable.h +++ b/arch/um/include/asm/pgtable.h | |||
@@ -273,6 +273,12 @@ static inline void set_pte(pte_t *pteptr, pte_t pteval) | |||
273 | } | 273 | } |
274 | #define set_pte_at(mm,addr,ptep,pteval) set_pte(ptep,pteval) | 274 | #define set_pte_at(mm,addr,ptep,pteval) set_pte(ptep,pteval) |
275 | 275 | ||
276 | #define __HAVE_ARCH_PTE_SAME | ||
277 | static inline int pte_same(pte_t pte_a, pte_t pte_b) | ||
278 | { | ||
279 | return !((pte_val(pte_a) ^ pte_val(pte_b)) & ~_PAGE_NEWPAGE); | ||
280 | } | ||
281 | |||
276 | /* | 282 | /* |
277 | * Conversion functions: convert a page and protection to a page entry, | 283 | * Conversion functions: convert a page and protection to a page entry, |
278 | * and a page entry and page directory to the page they refer to. | 284 | * and a page entry and page directory to the page they refer to. |
@@ -348,11 +354,11 @@ extern pte_t *virt_to_pte(struct mm_struct *mm, unsigned long addr); | |||
348 | #define update_mmu_cache(vma,address,ptep) do ; while (0) | 354 | #define update_mmu_cache(vma,address,ptep) do ; while (0) |
349 | 355 | ||
350 | /* Encode and de-code a swap entry */ | 356 | /* Encode and de-code a swap entry */ |
351 | #define __swp_type(x) (((x).val >> 4) & 0x3f) | 357 | #define __swp_type(x) (((x).val >> 5) & 0x1f) |
352 | #define __swp_offset(x) ((x).val >> 11) | 358 | #define __swp_offset(x) ((x).val >> 11) |
353 | 359 | ||
354 | #define __swp_entry(type, offset) \ | 360 | #define __swp_entry(type, offset) \ |
355 | ((swp_entry_t) { ((type) << 4) | ((offset) << 11) }) | 361 | ((swp_entry_t) { ((type) << 5) | ((offset) << 11) }) |
356 | #define __pte_to_swp_entry(pte) \ | 362 | #define __pte_to_swp_entry(pte) \ |
357 | ((swp_entry_t) { pte_val(pte_mkuptodate(pte)) }) | 363 | ((swp_entry_t) { pte_val(pte_mkuptodate(pte)) }) |
358 | #define __swp_entry_to_pte(x) ((pte_t) { (x).val }) | 364 | #define __swp_entry_to_pte(x) ((pte_t) { (x).val }) |
diff --git a/arch/um/include/asm/thread_info.h b/arch/um/include/asm/thread_info.h index 200c4ab1240c..c04e5ab68f56 100644 --- a/arch/um/include/asm/thread_info.h +++ b/arch/um/include/asm/thread_info.h | |||
@@ -71,6 +71,7 @@ static inline struct thread_info *current_thread_info(void) | |||
71 | #define TIF_MEMDIE 5 /* is terminating due to OOM killer */ | 71 | #define TIF_MEMDIE 5 /* is terminating due to OOM killer */ |
72 | #define TIF_SYSCALL_AUDIT 6 | 72 | #define TIF_SYSCALL_AUDIT 6 |
73 | #define TIF_RESTORE_SIGMASK 7 | 73 | #define TIF_RESTORE_SIGMASK 7 |
74 | #define TIF_NOTIFY_RESUME 8 | ||
74 | 75 | ||
75 | #define _TIF_SYSCALL_TRACE (1 << TIF_SYSCALL_TRACE) | 76 | #define _TIF_SYSCALL_TRACE (1 << TIF_SYSCALL_TRACE) |
76 | #define _TIF_SIGPENDING (1 << TIF_SIGPENDING) | 77 | #define _TIF_SIGPENDING (1 << TIF_SIGPENDING) |
@@ -78,6 +79,5 @@ static inline struct thread_info *current_thread_info(void) | |||
78 | #define _TIF_POLLING_NRFLAG (1 << TIF_POLLING_NRFLAG) | 79 | #define _TIF_POLLING_NRFLAG (1 << TIF_POLLING_NRFLAG) |
79 | #define _TIF_MEMDIE (1 << TIF_MEMDIE) | 80 | #define _TIF_MEMDIE (1 << TIF_MEMDIE) |
80 | #define _TIF_SYSCALL_AUDIT (1 << TIF_SYSCALL_AUDIT) | 81 | #define _TIF_SYSCALL_AUDIT (1 << TIF_SYSCALL_AUDIT) |
81 | #define _TIF_RESTORE_SIGMASK (1 << TIF_RESTORE_SIGMASK) | ||
82 | 82 | ||
83 | #endif | 83 | #endif |
diff --git a/arch/um/include/shared/irq_kern.h b/arch/um/include/shared/irq_kern.h index b05d22f3d84e..7a5bfa6291b8 100644 --- a/arch/um/include/shared/irq_kern.h +++ b/arch/um/include/shared/irq_kern.h | |||
@@ -13,6 +13,6 @@ extern int um_request_irq(unsigned int irq, int fd, int type, | |||
13 | irq_handler_t handler, | 13 | irq_handler_t handler, |
14 | unsigned long irqflags, const char * devname, | 14 | unsigned long irqflags, const char * devname, |
15 | void *dev_id); | 15 | void *dev_id); |
16 | 16 | void um_free_irq(unsigned int irq, void *dev); | |
17 | #endif | 17 | #endif |
18 | 18 | ||
diff --git a/arch/um/kernel/irq.c b/arch/um/kernel/irq.c index 71b8c947e5ef..00506c3d5d6e 100644 --- a/arch/um/kernel/irq.c +++ b/arch/um/kernel/irq.c | |||
@@ -297,6 +297,13 @@ unsigned int do_IRQ(int irq, struct uml_pt_regs *regs) | |||
297 | return 1; | 297 | return 1; |
298 | } | 298 | } |
299 | 299 | ||
300 | void um_free_irq(unsigned int irq, void *dev) | ||
301 | { | ||
302 | free_irq_by_irq_and_dev(irq, dev); | ||
303 | free_irq(irq, dev); | ||
304 | } | ||
305 | EXPORT_SYMBOL(um_free_irq); | ||
306 | |||
300 | int um_request_irq(unsigned int irq, int fd, int type, | 307 | int um_request_irq(unsigned int irq, int fd, int type, |
301 | irq_handler_t handler, | 308 | irq_handler_t handler, |
302 | unsigned long irqflags, const char * devname, | 309 | unsigned long irqflags, const char * devname, |
@@ -327,7 +334,6 @@ static void dummy(struct irq_data *d) | |||
327 | /* This is used for everything else than the timer. */ | 334 | /* This is used for everything else than the timer. */ |
328 | static struct irq_chip normal_irq_type = { | 335 | static struct irq_chip normal_irq_type = { |
329 | .name = "SIGIO", | 336 | .name = "SIGIO", |
330 | .release = free_irq_by_irq_and_dev, | ||
331 | .irq_disable = dummy, | 337 | .irq_disable = dummy, |
332 | .irq_enable = dummy, | 338 | .irq_enable = dummy, |
333 | .irq_ack = dummy, | 339 | .irq_ack = dummy, |
@@ -335,7 +341,6 @@ static struct irq_chip normal_irq_type = { | |||
335 | 341 | ||
336 | static struct irq_chip SIGVTALRM_irq_type = { | 342 | static struct irq_chip SIGVTALRM_irq_type = { |
337 | .name = "SIGVTALRM", | 343 | .name = "SIGVTALRM", |
338 | .release = free_irq_by_irq_and_dev, | ||
339 | .irq_disable = dummy, | 344 | .irq_disable = dummy, |
340 | .irq_enable = dummy, | 345 | .irq_enable = dummy, |
341 | .irq_ack = dummy, | 346 | .irq_ack = dummy, |
diff --git a/arch/um/kernel/process.c b/arch/um/kernel/process.c index 2b73dedb44ca..3a2235e0abc3 100644 --- a/arch/um/kernel/process.c +++ b/arch/um/kernel/process.c | |||
@@ -18,6 +18,7 @@ | |||
18 | #include <linux/seq_file.h> | 18 | #include <linux/seq_file.h> |
19 | #include <linux/tick.h> | 19 | #include <linux/tick.h> |
20 | #include <linux/threads.h> | 20 | #include <linux/threads.h> |
21 | #include <linux/tracehook.h> | ||
21 | #include <asm/current.h> | 22 | #include <asm/current.h> |
22 | #include <asm/pgtable.h> | 23 | #include <asm/pgtable.h> |
23 | #include <asm/mmu_context.h> | 24 | #include <asm/mmu_context.h> |
@@ -114,8 +115,13 @@ void interrupt_end(void) | |||
114 | { | 115 | { |
115 | if (need_resched()) | 116 | if (need_resched()) |
116 | schedule(); | 117 | schedule(); |
117 | if (test_tsk_thread_flag(current, TIF_SIGPENDING)) | 118 | if (test_thread_flag(TIF_SIGPENDING)) |
118 | do_signal(); | 119 | do_signal(); |
120 | if (test_and_clear_thread_flag(TIF_NOTIFY_RESUME)) { | ||
121 | tracehook_notify_resume(¤t->thread.regs); | ||
122 | if (current->replacement_session_keyring) | ||
123 | key_replace_session_keyring(); | ||
124 | } | ||
119 | } | 125 | } |
120 | 126 | ||
121 | void exit_thread(void) | 127 | void exit_thread(void) |
@@ -190,7 +196,7 @@ int copy_thread(unsigned long clone_flags, unsigned long sp, | |||
190 | if (current->thread.forking) { | 196 | if (current->thread.forking) { |
191 | memcpy(&p->thread.regs.regs, ®s->regs, | 197 | memcpy(&p->thread.regs.regs, ®s->regs, |
192 | sizeof(p->thread.regs.regs)); | 198 | sizeof(p->thread.regs.regs)); |
193 | REGS_SET_SYSCALL_RETURN(p->thread.regs.regs.gp, 0); | 199 | UPT_SET_SYSCALL_RETURN(&p->thread.regs.regs, 0); |
194 | if (sp != 0) | 200 | if (sp != 0) |
195 | REGS_SP(p->thread.regs.regs.gp) = sp; | 201 | REGS_SP(p->thread.regs.regs.gp) = sp; |
196 | 202 | ||
diff --git a/arch/um/kernel/signal.c b/arch/um/kernel/signal.c index fb12f4c5e649..187118fbe1bc 100644 --- a/arch/um/kernel/signal.c +++ b/arch/um/kernel/signal.c | |||
@@ -29,9 +29,6 @@ static int handle_signal(struct pt_regs *regs, unsigned long signr, | |||
29 | unsigned long sp; | 29 | unsigned long sp; |
30 | int err; | 30 | int err; |
31 | 31 | ||
32 | /* Always make any pending restarted system calls return -EINTR */ | ||
33 | current_thread_info()->restart_block.fn = do_no_restart_syscall; | ||
34 | |||
35 | /* Did we come from a system call? */ | 32 | /* Did we come from a system call? */ |
36 | if (PT_REGS_SYSCALL_NR(regs) >= 0) { | 33 | if (PT_REGS_SYSCALL_NR(regs) >= 0) { |
37 | /* If so, check system call restarting.. */ | 34 | /* If so, check system call restarting.. */ |
@@ -77,15 +74,14 @@ static int kern_do_signal(struct pt_regs *regs) | |||
77 | { | 74 | { |
78 | struct k_sigaction ka_copy; | 75 | struct k_sigaction ka_copy; |
79 | siginfo_t info; | 76 | siginfo_t info; |
80 | sigset_t *oldset; | ||
81 | int sig, handled_sig = 0; | 77 | int sig, handled_sig = 0; |
82 | 78 | ||
83 | if (test_thread_flag(TIF_RESTORE_SIGMASK)) | ||
84 | oldset = ¤t->saved_sigmask; | ||
85 | else | ||
86 | oldset = ¤t->blocked; | ||
87 | |||
88 | while ((sig = get_signal_to_deliver(&info, &ka_copy, regs, NULL)) > 0) { | 79 | while ((sig = get_signal_to_deliver(&info, &ka_copy, regs, NULL)) > 0) { |
80 | sigset_t *oldset; | ||
81 | if (test_thread_flag(TIF_RESTORE_SIGMASK)) | ||
82 | oldset = ¤t->saved_sigmask; | ||
83 | else | ||
84 | oldset = ¤t->blocked; | ||
89 | handled_sig = 1; | 85 | handled_sig = 1; |
90 | /* Whee! Actually deliver the signal. */ | 86 | /* Whee! Actually deliver the signal. */ |
91 | if (!handle_signal(regs, sig, &ka_copy, &info, oldset)) { | 87 | if (!handle_signal(regs, sig, &ka_copy, &info, oldset)) { |
diff --git a/arch/um/kernel/skas/syscall.c b/arch/um/kernel/skas/syscall.c index f5173e1ec3ac..05fbeb480e0b 100644 --- a/arch/um/kernel/skas/syscall.c +++ b/arch/um/kernel/skas/syscall.c | |||
@@ -34,7 +34,7 @@ void handle_syscall(struct uml_pt_regs *r) | |||
34 | result = -ENOSYS; | 34 | result = -ENOSYS; |
35 | else result = EXECUTE_SYSCALL(syscall, regs); | 35 | else result = EXECUTE_SYSCALL(syscall, regs); |
36 | 36 | ||
37 | REGS_SET_SYSCALL_RETURN(r->gp, result); | 37 | UPT_SET_SYSCALL_RETURN(r, result); |
38 | 38 | ||
39 | syscall_trace(r, 1); | 39 | syscall_trace(r, 1); |
40 | } | 40 | } |
diff --git a/arch/um/kernel/tlb.c b/arch/um/kernel/tlb.c index 7f3d4d86431a..f819af951c19 100644 --- a/arch/um/kernel/tlb.c +++ b/arch/um/kernel/tlb.c | |||
@@ -75,6 +75,7 @@ static int do_ops(struct host_vm_change *hvc, int end, | |||
75 | default: | 75 | default: |
76 | printk(KERN_ERR "Unknown op type %d in do_ops\n", | 76 | printk(KERN_ERR "Unknown op type %d in do_ops\n", |
77 | op->type); | 77 | op->type); |
78 | BUG(); | ||
78 | break; | 79 | break; |
79 | } | 80 | } |
80 | } | 81 | } |
diff --git a/arch/um/os-Linux/skas/mem.c b/arch/um/os-Linux/skas/mem.c index c0afff7af4bd..90b310d29179 100644 --- a/arch/um/os-Linux/skas/mem.c +++ b/arch/um/os-Linux/skas/mem.c | |||
@@ -48,10 +48,6 @@ __initcall(init_syscall_regs); | |||
48 | 48 | ||
49 | extern int proc_mm; | 49 | extern int proc_mm; |
50 | 50 | ||
51 | int single_count = 0; | ||
52 | int multi_count = 0; | ||
53 | int multi_op_count = 0; | ||
54 | |||
55 | static inline long do_syscall_stub(struct mm_id * mm_idp, void **addr) | 51 | static inline long do_syscall_stub(struct mm_id * mm_idp, void **addr) |
56 | { | 52 | { |
57 | int n, i; | 53 | int n, i; |
@@ -64,8 +60,6 @@ static inline long do_syscall_stub(struct mm_id * mm_idp, void **addr) | |||
64 | /* FIXME: Need to look up userspace_pid by cpu */ | 60 | /* FIXME: Need to look up userspace_pid by cpu */ |
65 | pid = userspace_pid[0]; | 61 | pid = userspace_pid[0]; |
66 | 62 | ||
67 | multi_count++; | ||
68 | |||
69 | n = ptrace_setregs(pid, syscall_regs); | 63 | n = ptrace_setregs(pid, syscall_regs); |
70 | if (n < 0) { | 64 | if (n < 0) { |
71 | printk(UM_KERN_ERR "Registers - \n"); | 65 | printk(UM_KERN_ERR "Registers - \n"); |
@@ -126,9 +120,6 @@ long run_syscall_stub(struct mm_id * mm_idp, int syscall, | |||
126 | { | 120 | { |
127 | unsigned long *stack = check_init_stack(mm_idp, *addr); | 121 | unsigned long *stack = check_init_stack(mm_idp, *addr); |
128 | 122 | ||
129 | if (done && *addr == NULL) | ||
130 | single_count++; | ||
131 | |||
132 | *stack += sizeof(long); | 123 | *stack += sizeof(long); |
133 | stack += *stack / sizeof(long); | 124 | stack += *stack / sizeof(long); |
134 | 125 | ||
@@ -141,7 +132,6 @@ long run_syscall_stub(struct mm_id * mm_idp, int syscall, | |||
141 | *stack++ = args[5]; | 132 | *stack++ = args[5]; |
142 | *stack++ = expected; | 133 | *stack++ = expected; |
143 | *stack = 0; | 134 | *stack = 0; |
144 | multi_op_count++; | ||
145 | 135 | ||
146 | if (!done && ((((unsigned long) stack) & ~UM_KERN_PAGE_MASK) < | 136 | if (!done && ((((unsigned long) stack) & ~UM_KERN_PAGE_MASK) < |
147 | UM_KERN_PAGE_SIZE - 10 * sizeof(long))) { | 137 | UM_KERN_PAGE_SIZE - 10 * sizeof(long))) { |