lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 22 Apr 2014 19:08:20 +0800
From:	Ley Foon Tan <lftan@...era.com>
To:	Ezequiel Garcia <ezequiel.garcia@...e-electrons.com>
Cc:	Linux-Arch <linux-arch@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"linux-doc@...r.kernel.org" <linux-doc@...r.kernel.org>,
	cltang@...esourcery.com
Subject: Re: [PATCH 04/28] nios2: Exception handling

On Tue, Apr 22, 2014 at 6:57 PM, Ezequiel Garcia
<ezequiel.garcia@...e-electrons.com> wrote:
> Hi Ley Foon,
>
> Are you sure this is correct? Have you tested this works correctly?
>
> Last time I tested this, it caused the traced_system_call to be taken
> for every system call. I already reported and provided a patch a few
> months ago:
>
> http://lists.rocketboards.org/pipermail/nios2-dev/2014-January/006968.html
>
> Here's my proposed fix:
>
> diff --git a/arch/nios2/kernel/entry.S b/arch/nios2/kernel/entry.S
> index 9cf2bac..3798008 100644
> --- a/arch/nios2/kernel/entry.S
> +++ b/arch/nios2/kernel/entry.S
> @@ -204,13 +204,10 @@ ENTRY(handle_system_call)
>         ldw     r1, %lo(sys_call_table)(r1)
>         beq     r1, r0, ret_invsyscall
>
> -       /* Get thread info pointer */
> -       movi    r11, %lo(0xfffff000)
> -       and     r11, sp, r11
> -       ldw     r11, TI_FLAGS(r11)
> -
> -       /* If someone is ptrace:ing us, take the long way. */
> -       BTBNZ   r11, r11, TIF_SYSCALL_TRACE, traced_system_call
> +       /* Check if we are being traced */
> +       GET_THREAD_INFO r11
> +       ldw     r11,TI_FLAGS(r11)
> +       BTBNZ   r11,r11,TIF_SYSCALL_TRACE,traced_system_call
>
>         /* Execute the system call */
>         callr   r1
I think I missed out this in nios2-dev ML previously. I will take your fix.
Thanks.

Regards
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists