linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] n_gsm: Fix incorrect debug display
@ 2012-09-17 11:02 Alan Cox
  0 siblings, 0 replies; only message in thread
From: Alan Cox @ 2012-09-17 11:02 UTC (permalink / raw)
  To: greg, linux-serial

From: Alan Cox <alan@linux.intel.com>

In the trace we print the wrong values for N(R) on an I frame.
Correct the mask.

Signed-off-by: Alan Cox <alan@linux.intel.com>
---

 drivers/tty/n_gsm.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/n_gsm.c b/drivers/tty/n_gsm.c
index 3e210a4..1e8e8ce 100644
--- a/drivers/tty/n_gsm.c
+++ b/drivers/tty/n_gsm.c
@@ -488,7 +488,7 @@ static void gsm_print_packet(const char *hdr, int addr, int cr,
 	default:
 		if (!(control & 0x01)) {
 			pr_cont("I N(S)%d N(R)%d",
-				(control & 0x0E) >> 1, (control & 0xE) >> 5);
+				(control & 0x0E) >> 1, (control & 0xE0) >> 5);
 		} else switch (control & 0x0F) {
 			case RR:
 				pr_cont("RR(%d)", (control & 0xE0) >> 5);


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2012-09-17 10:44 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-17 11:02 [PATCH] n_gsm: Fix incorrect debug display Alan Cox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).