[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4F561AA3.6050600@suse.cz>
Date: Tue, 06 Mar 2012 15:09:39 +0100
From: Jiri Slaby <jslaby@...e.cz>
To: Dan Carpenter <dan.carpenter@...cle.com>
CC: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org,
Jiri Slaby <jirislaby@...il.com>
Subject: Re: [patch v2] tty: cyclades: TIOCSERGETLSR should should store to
a uint
On 03/05/2012 07:07 PM, Dan Carpenter wrote:
> TIOCSERGETLSR should be saved in a uint so the cast here to unsigned
> long is a bug.
>
> Reported-by: Jiri Slaby <jslaby@...e.cz>
> Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
ACK. Thanks.
> ---
> v2: completely different from v1.
>
> diff --git a/drivers/tty/cyclades.c b/drivers/tty/cyclades.c
> index c9bf779..5575fee 100644
> --- a/drivers/tty/cyclades.c
> +++ b/drivers/tty/cyclades.c
> @@ -2413,7 +2413,7 @@ static int get_lsr_info(struct cyclades_port *info, unsigned int __user *value)
> /* Not supported yet */
> return -EINVAL;
> }
> - return put_user(result, (unsigned long __user *)value);
> + return put_user(result, value);
> }
>
> static int cy_tiocmget(struct tty_struct *tty)
--
js
suse labs
--
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