public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [patch] tty: moxa: fix bit test in moxa_start()
@ 2012-03-07 10:05 Dan Carpenter
  2012-03-07 12:26 ` Jiri Slaby
  2012-03-08 16:08 ` Alan Cox
  0 siblings, 2 replies; 3+ messages in thread
From: Dan Carpenter @ 2012-03-07 10:05 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: linux-kernel, kernel-janitors

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 <dan.carpenter@oracle.com>

diff --git a/drivers/tty/moxa.c b/drivers/tty/moxa.c
index d15a071..0174d2d 100644
--- a/drivers/tty/moxa.c
+++ b/drivers/tty/moxa.c
@@ -1331,7 +1331,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);

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-03-08 16:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-03-07 10:05 [patch] tty: moxa: fix bit test in moxa_start() Dan Carpenter
2012-03-07 12:26 ` Jiri Slaby
2012-03-08 16:08 ` Alan Cox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox