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  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:	Thu, 24 Jul 2014 14:55:02 +0800
From:	Steven Miao <realmz6@...il.com>
To:	Richard Weinberger <richard@...ma-star.at>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	"open list:CAN NETWORK DRIVERS <linux-can@...r.kernel.org>, open
	list:NETWORKING DRIVERS <netdev@...r.kernel.org>, open list" 
	<linux-kernel@...r.kernel.org>, linux-arch@...r.kernel.org,
	Richard Weinberger <richard@....at>,
	bfin <adi-buildroot-devel@...ts.sourceforge.net>
Subject: Re: [PATCH 31/43] blackfin: Use sigsp()

Acked-by: Steven Miao <realmz6@...il.com>

Thanks.

On Mon, Jul 21, 2014 at 10:03 PM, Richard Weinberger
<richard@...ma-star.at> wrote:
> From: Richard Weinberger <richard@....at>
>
> Use sigsp() instead of the open coded variant.
>
> Signed-off-by: Richard Weinberger <richard@....at>
> ---
>  arch/blackfin/kernel/signal.c | 14 +++-----------
>  1 file changed, 3 insertions(+), 11 deletions(-)
>
> diff --git a/arch/blackfin/kernel/signal.c b/arch/blackfin/kernel/signal.c
> index 1389cd3..ef27557 100644
> --- a/arch/blackfin/kernel/signal.c
> +++ b/arch/blackfin/kernel/signal.c
> @@ -135,19 +135,11 @@ static inline int rt_setup_sigcontext(struct sigcontext *sc, struct pt_regs *reg
>         return err;
>  }
>
> -static inline void *get_sigframe(struct k_sigaction *ka, struct pt_regs *regs,
> +static inline void *get_sigframe(struct ksignal *ksig,
>                                  size_t frame_size)
>  {
> -       unsigned long usp;
> +       unsigned long usp = sigsp(rdusp(), ksig);
>
> -       /* Default to using normal stack.  */
> -       usp = rdusp();
> -
> -       /* This is the X/Open sanctioned signal stack switching.  */
> -       if (ka->sa.sa_flags & SA_ONSTACK) {
> -               if (!on_sig_stack(usp))
> -                       usp = current->sas_ss_sp + current->sas_ss_size;
> -       }
>         return (void *)((usp - frame_size) & -8UL);
>  }
>
> @@ -157,7 +149,7 @@ setup_rt_frame(struct ksignal *ksig, sigset_t *set, struct pt_regs *regs)
>         struct rt_sigframe *frame;
>         int err = 0;
>
> -       frame = get_sigframe(&ksig->ka, regs, sizeof(*frame));
> +       frame = get_sigframe(ksig, sizeof(*frame));
>
>         err |= __put_user((current_thread_info()->exec_domain
>                            && current_thread_info()->exec_domain->signal_invmap
> --
> 1.8.4.5
>
--
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