Skip to content

Commit 8a7f7c9

Browse files
Jesper JuhlLinus Torvalds
authored andcommitted
[PATCH] moxa: remove pointless check of 'tty' argument vs NULL
Remove pointless check of 'tty' argument vs NULL from moxa driver. Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
1 parent 56e139f commit 8a7f7c9

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎drivers/char/mxser.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1081,7 +1081,7 @@ static int mxser_write(struct tty_struct *tty, const unsigned char *buf, int cou
10811081
struct mxser_struct *info = tty->driver_data;
10821082
unsigned long flags;
10831083

1084-
if (!tty || !info->xmit_buf)
1084+
if (!info->xmit_buf)
10851085
return (0);
10861086

10871087
while (1) {
@@ -1117,7 +1117,7 @@ static void mxser_put_char(struct tty_struct *tty, unsigned char ch)
11171117
struct mxser_struct *info = tty->driver_data;
11181118
unsigned long flags;
11191119

1120-
if (!tty || !info->xmit_buf)
1120+
if (!info->xmit_buf)
11211121
return;
11221122

11231123
if (info->xmit_cnt >= SERIAL_XMIT_SIZE - 1)

0 commit comments

Comments
 (0)