Skip to content

Commit

Permalink
tty: moxa: fix bit test in moxa_start()
Browse files Browse the repository at this point in the history
This is supposed to be doing a shift before the comparison instead of
just doing a bitwise AND directly.  The current code means the start()
just returns without doing anything.

Signed-off-by: Dan Carpenter <[email protected]>
Acked-by: Jiri Slaby <[email protected]>
Cc: stable <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
Dan Carpenter authored and gregkh committed Mar 8, 2012
1 parent 48a7466 commit 58112df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/tty/moxa.c
Original file line number Diff line number Diff line change
Expand Up @@ -1330,7 +1330,7 @@ static void moxa_start(struct tty_struct *tty)
if (ch == NULL)
return;

if (!(ch->statusflags & TXSTOPPED))
if (!test_bit(TXSTOPPED, &ch->statusflags))
return;

MoxaPortTxEnable(ch);
Expand Down

0 comments on commit 58112df

Please sign in to comment.