[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5458F3F8.3030100@tilera.com>
Date: Tue, 4 Nov 2014 10:42:48 -0500
From: Chris Metcalf <cmetcalf@...era.com>
To: Chen Gang <gang.chen.5i5j@...il.com>, <dwalter@...gle.com>,
<richard@....at>, Al Viro <viro@...IV.linux.org.uk>
CC: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] arch: tile: kernel: signal.c: Use __copy_from/to_user()
instead of __get/put_user()
On 11/1/2014 10:13 PM, Chen Gang wrote:
> setup/restore_sigcontext() want to copy all related registers between
> user and kernel. So use block copy instead of each registers copy. Then
> can let code simple and clearer (which can avoid compiler's warning):
>
> [...]
>
> Signed-off-by: Chen Gang <gang.chen.5i5j@...il.com>
> ---
> arch/tile/kernel/signal.c | 12 ++----------
> 1 file changed, 2 insertions(+), 10 deletions(-)
>
> diff --git a/arch/tile/kernel/signal.c b/arch/tile/kernel/signal.c
> index 7c2fecc..f867783 100644
> --- a/arch/tile/kernel/signal.c
> +++ b/arch/tile/kernel/signal.c
> @@ -46,7 +46,6 @@ int restore_sigcontext(struct pt_regs *regs,
> struct sigcontext __user *sc)
> {
> int err = 0;
> - int i;
Taken into the tile tree, but I removed the now-redundant initialization
of err (shown above).
Thanks!
--
Chris Metcalf, Tilera Corp.
http://www.tilera.com
--
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