]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[MIPS] Fix register handling in syscalls when debugging.
authorRalf Baechle <ralf@linux-mips.org>
Wed, 30 Nov 2005 16:24:57 +0000 (16:24 +0000)
committerRalf Baechle <ralf@linux-mips.org>
Thu, 1 Dec 2005 11:05:17 +0000 (11:05 +0000)
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/kernel/scall32-o32.S
arch/mips/kernel/scall64-64.S
arch/mips/kernel/scall64-n32.S
arch/mips/kernel/scall64-o32.S

index 2258fc69e14d39373b925fc5af12dfbb705cbd19..a42e0e8caa7b229292954bd2e1a33fb1865ce307 100644 (file)
@@ -94,11 +94,13 @@ syscall_trace_entry:
        li      a1, 0
        jal     do_syscall_trace
 
+       move    t0, s0
+       RESTORE_STATIC
        lw      a0, PT_R4(sp)           # Restore argument registers
        lw      a1, PT_R5(sp)
        lw      a2, PT_R6(sp)
        lw      a3, PT_R7(sp)
-       jalr    s0
+       jalr    t0
 
        li      t0, -EMAXERRNO - 1      # error?
        sltu    t0, t0, v0
index cb28de6a2efa74eae75569ff3d3515ad4229b097..47bfbd416709cadb1e4fa96a0b32c20b026e80be 100644 (file)
@@ -93,13 +93,15 @@ syscall_trace_entry:
        li      a1, 0
        jal     do_syscall_trace
 
+       move    t0, s0
+       RESTORE_STATIC
        ld      a0, PT_R4(sp)           # Restore argument registers
        ld      a1, PT_R5(sp)
        ld      a2, PT_R6(sp)
        ld      a3, PT_R7(sp)
        ld      a4, PT_R8(sp)
        ld      a5, PT_R9(sp)
-       jalr    s0
+       jalr    t0
 
        li      t0, -EMAXERRNO - 1      # error?
        sltu    t0, t0, v0
index 7e66eb823bf6a4c4d05a5776b1dd5dad8ba3f77b..b465ced1758f7a49f35cd085b2289162a7fa3037 100644 (file)
@@ -90,13 +90,15 @@ n32_syscall_trace_entry:
        li      a1, 0
        jal     do_syscall_trace
 
+       move    t0, s0
+       RESTORE_STATIC
        ld      a0, PT_R4(sp)           # Restore argument registers
        ld      a1, PT_R5(sp)
        ld      a2, PT_R6(sp)
        ld      a3, PT_R7(sp)
        ld      a4, PT_R8(sp)
        ld      a5, PT_R9(sp)
-       jalr    s0
+       jalr    t0
 
        li      t0, -EMAXERRNO - 1      # error?
        sltu    t0, t0, v0
index 5a16401e443a3c8b8103357a9c79a91fd5e4ca52..3d338ca7eeeb1ca82529f03268cb0f6bf54999ce 100644 (file)
@@ -124,6 +124,8 @@ trace_a_syscall:
        li      a1, 0
        jal     do_syscall_trace
 
+       move    t0, s0
+       RESTORE_STATIC
        ld      a0, PT_R4(sp)           # Restore argument registers
        ld      a1, PT_R5(sp)
        ld      a2, PT_R6(sp)
@@ -132,7 +134,7 @@ trace_a_syscall:
        ld      a5, PT_R9(sp)
        ld      a6, PT_R10(sp)
        ld      a7, PT_R11(sp)          # For indirect syscalls
-       jalr    s0
+       jalr    t0
 
        li      t0, -EMAXERRNO - 1      # error?
        sltu    t0, t0, v0