From: Cong Ding Date: Wed, 16 Jan 2013 22:30:44 +0000 (+0100) Subject: tty: serial/crisv10.c: remove unnecessary null pointer check X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=f938f3781fa877146236042341ddbcf06bc49f0a;p=linux-beck.git tty: serial/crisv10.c: remove unnecessary null pointer check The pointer tty is dereferened in line 3135, so it is not necessary to check null again in line 3140. Signed-off-by: Cong Ding Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/tty/serial/crisv10.c b/drivers/tty/serial/crisv10.c index 45acf103433e..5f37c31e32bc 100644 --- a/drivers/tty/serial/crisv10.c +++ b/drivers/tty/serial/crisv10.c @@ -3122,7 +3122,7 @@ static int rs_raw_write(struct tty_struct *tty, /* first some sanity checks */ - if (!tty || !info->xmit.buf) + if (!info->xmit.buf) return 0; #ifdef SERIAL_DEBUG_DATA