From c8a2786b107873e34d540b8e3e54bd3cef03bc56 Mon Sep 17 00:00:00 2001 From: Philippe De Muyter Date: Tue, 17 Aug 2010 18:58:29 +0200 Subject: 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 Signed-off-by: Greg Ungerer --- arch/m68knommu/platform/68360/entry.S | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'arch/m68knommu/platform/68360') diff --git a/arch/m68knommu/platform/68360/entry.S b/arch/m68knommu/platform/68360/entry.S index 6d3460a39ca..d5ad4080f55 100644 --- a/arch/m68knommu/platform/68360/entry.S +++ b/arch/m68knommu/platform/68360/entry.S @@ -71,7 +71,12 @@ ENTRY(system_call) jbsr set_esp0 addql #4,%sp - btst #PF_TRACESYS_BIT,%a2@(TASK_FLAGS+PF_TRACESYS_OFF) + movel %sp@(PT_OFF_ORIG_D0),%d0 + + movel %sp,%d1 /* get thread_info pointer */ + andl #-THREAD_SIZE,%d1 + movel %d1,%a2 + btst #(TIF_SYSCALL_TRACE%8),%a2@(TI_FLAGS+(31-TIF_SYSCALL_TRACE)/8) jne do_trace cmpl #NR_syscalls,%d0 jcc badsys -- cgit v1.2.3