diff options
Diffstat (limited to 'arch/s390/kernel/entry.S')
-rw-r--r-- | arch/s390/kernel/entry.S | 29 |
1 files changed, 14 insertions, 15 deletions
diff --git a/arch/s390/kernel/entry.S b/arch/s390/kernel/entry.S index bdbb3bcd78a5..708cf9cf9a35 100644 --- a/arch/s390/kernel/entry.S +++ b/arch/s390/kernel/entry.S | |||
@@ -279,8 +279,6 @@ sysc_do_restart: | |||
279 | st %r2,SP_R2(%r15) # store return value (change R2 on stack) | 279 | st %r2,SP_R2(%r15) # store return value (change R2 on stack) |
280 | 280 | ||
281 | sysc_return: | 281 | sysc_return: |
282 | tm SP_PSW+1(%r15),0x01 # returning to user ? | ||
283 | bno BASED(sysc_restore) | ||
284 | tm __TI_flags+3(%r9),_TIF_WORK_SVC | 282 | tm __TI_flags+3(%r9),_TIF_WORK_SVC |
285 | bnz BASED(sysc_work) # there is work to do (signals etc.) | 283 | bnz BASED(sysc_work) # there is work to do (signals etc.) |
286 | sysc_restore: | 284 | sysc_restore: |
@@ -312,6 +310,8 @@ sysc_work_loop: | |||
312 | # One of the work bits is on. Find out which one. | 310 | # One of the work bits is on. Find out which one. |
313 | # | 311 | # |
314 | sysc_work: | 312 | sysc_work: |
313 | tm SP_PSW+1(%r15),0x01 # returning to user ? | ||
314 | bno BASED(sysc_restore) | ||
315 | tm __TI_flags+3(%r9),_TIF_MCCK_PENDING | 315 | tm __TI_flags+3(%r9),_TIF_MCCK_PENDING |
316 | bo BASED(sysc_mcck_pending) | 316 | bo BASED(sysc_mcck_pending) |
317 | tm __TI_flags+3(%r9),_TIF_NEED_RESCHED | 317 | tm __TI_flags+3(%r9),_TIF_NEED_RESCHED |
@@ -602,12 +602,6 @@ io_no_vtime: | |||
602 | la %r2,SP_PTREGS(%r15) # address of register-save area | 602 | la %r2,SP_PTREGS(%r15) # address of register-save area |
603 | basr %r14,%r1 # branch to standard irq handler | 603 | basr %r14,%r1 # branch to standard irq handler |
604 | io_return: | 604 | io_return: |
605 | tm SP_PSW+1(%r15),0x01 # returning to user ? | ||
606 | #ifdef CONFIG_PREEMPT | ||
607 | bno BASED(io_preempt) # no -> check for preemptive scheduling | ||
608 | #else | ||
609 | bno BASED(io_restore) # no-> skip resched & signal | ||
610 | #endif | ||
611 | tm __TI_flags+3(%r9),_TIF_WORK_INT | 605 | tm __TI_flags+3(%r9),_TIF_WORK_INT |
612 | bnz BASED(io_work) # there is work to do (signals etc.) | 606 | bnz BASED(io_work) # there is work to do (signals etc.) |
613 | io_restore: | 607 | io_restore: |
@@ -629,10 +623,18 @@ io_restore_trace_psw: | |||
629 | .long 0, io_restore_trace + 0x80000000 | 623 | .long 0, io_restore_trace + 0x80000000 |
630 | #endif | 624 | #endif |
631 | 625 | ||
632 | #ifdef CONFIG_PREEMPT | 626 | # |
633 | io_preempt: | 627 | # switch to kernel stack, then check the TIF bits |
628 | # | ||
629 | io_work: | ||
630 | tm SP_PSW+1(%r15),0x01 # returning to user ? | ||
631 | #ifndef CONFIG_PREEMPT | ||
632 | bno BASED(io_restore) # no-> skip resched & signal | ||
633 | #else | ||
634 | bnz BASED(io_work_user) # no -> check for preemptive scheduling | ||
635 | # check for preemptive scheduling | ||
634 | icm %r0,15,__TI_precount(%r9) | 636 | icm %r0,15,__TI_precount(%r9) |
635 | bnz BASED(io_restore) | 637 | bnz BASED(io_restore) # preemption disabled |
636 | l %r1,SP_R15(%r15) | 638 | l %r1,SP_R15(%r15) |
637 | s %r1,BASED(.Lc_spsize) | 639 | s %r1,BASED(.Lc_spsize) |
638 | mvc SP_PTREGS(__PT_SIZE,%r1),SP_PTREGS(%r15) | 640 | mvc SP_PTREGS(__PT_SIZE,%r1),SP_PTREGS(%r15) |
@@ -646,10 +648,7 @@ io_resume_loop: | |||
646 | br %r1 # call schedule | 648 | br %r1 # call schedule |
647 | #endif | 649 | #endif |
648 | 650 | ||
649 | # | 651 | io_work_user: |
650 | # switch to kernel stack, then check the TIF bits | ||
651 | # | ||
652 | io_work: | ||
653 | l %r1,__LC_KERNEL_STACK | 652 | l %r1,__LC_KERNEL_STACK |
654 | s %r1,BASED(.Lc_spsize) | 653 | s %r1,BASED(.Lc_spsize) |
655 | mvc SP_PTREGS(__PT_SIZE,%r1),SP_PTREGS(%r15) | 654 | mvc SP_PTREGS(__PT_SIZE,%r1),SP_PTREGS(%r15) |