diff options
author | Philippe De Muyter <phdm@macqel.be> | 2010-08-17 12:58:29 -0400 |
---|---|---|
committer | Greg Ungerer <gerg@uclinux.org> | 2010-10-20 20:17:29 -0400 |
commit | c8a2786b107873e34d540b8e3e54bd3cef03bc56 (patch) | |
tree | ea28f615c29fd8c30e3b98b04f2ac55ece7fc308 /arch/m68knommu | |
parent | 47422259b44e53e670b4ee375ff98f0603e6dd45 (diff) |
m68knommu: fix strace support for 68328/68360
strace enabled is marked using the `flags' field of the `thread_info' struct.
68360 version of entry.S did test a wrong bit in a wrong structure
(task_struct).
68328 version of entry.S did test the right bit in the right structure,
but wrongly, because the `flags' field is 32 bit wide, while the used
assembler insn (btst) only accesses a 8 bit byte in memory.
Fix both using code already used in the coldfire version of entry.S
Signed-off-by: Philippe De Muyter <phdm@macqel.be>
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Diffstat (limited to 'arch/m68knommu')
-rw-r--r-- | arch/m68knommu/platform/68328/entry.S | 2 | ||||
-rw-r--r-- | arch/m68knommu/platform/68360/entry.S | 7 |
2 files changed, 7 insertions, 2 deletions
diff --git a/arch/m68knommu/platform/68328/entry.S b/arch/m68knommu/platform/68328/entry.S index 9d80d2c42866..31a091708317 100644 --- a/arch/m68knommu/platform/68328/entry.S +++ b/arch/m68knommu/platform/68328/entry.S | |||
@@ -80,7 +80,7 @@ ENTRY(system_call) | |||
80 | movel %sp,%d1 /* get thread_info pointer */ | 80 | movel %sp,%d1 /* get thread_info pointer */ |
81 | andl #-THREAD_SIZE,%d1 | 81 | andl #-THREAD_SIZE,%d1 |
82 | movel %d1,%a2 | 82 | movel %d1,%a2 |
83 | btst #TIF_SYSCALL_TRACE,%a2@(TI_FLAGS) | 83 | btst #(TIF_SYSCALL_TRACE%8),%a2@(TI_FLAGS+(31-TIF_SYSCALL_TRACE)/8) |
84 | jne do_trace | 84 | jne do_trace |
85 | cmpl #NR_syscalls,%d0 | 85 | cmpl #NR_syscalls,%d0 |
86 | jcc badsys | 86 | jcc badsys |
diff --git a/arch/m68knommu/platform/68360/entry.S b/arch/m68knommu/platform/68360/entry.S index 6d3460a39cac..d5ad4080f553 100644 --- a/arch/m68knommu/platform/68360/entry.S +++ b/arch/m68knommu/platform/68360/entry.S | |||
@@ -71,7 +71,12 @@ ENTRY(system_call) | |||
71 | jbsr set_esp0 | 71 | jbsr set_esp0 |
72 | addql #4,%sp | 72 | addql #4,%sp |
73 | 73 | ||
74 | btst #PF_TRACESYS_BIT,%a2@(TASK_FLAGS+PF_TRACESYS_OFF) | 74 | movel %sp@(PT_OFF_ORIG_D0),%d0 |
75 | |||
76 | movel %sp,%d1 /* get thread_info pointer */ | ||
77 | andl #-THREAD_SIZE,%d1 | ||
78 | movel %d1,%a2 | ||
79 | btst #(TIF_SYSCALL_TRACE%8),%a2@(TI_FLAGS+(31-TIF_SYSCALL_TRACE)/8) | ||
75 | jne do_trace | 80 | jne do_trace |
76 | cmpl #NR_syscalls,%d0 | 81 | cmpl #NR_syscalls,%d0 |
77 | jcc badsys | 82 | jcc badsys |