Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1338998

[PATCH 4/8] tty: n_gsm: send DM response when accessing an invalid channel

From Andrej Krpic <ak77@tnode.com>
Newsgroups linux.kernel
Subject [PATCH 4/8] tty: n_gsm: send DM response when accessing an invalid channel
Date 2016-02-21 22:50 +0100
Message-ID <r4K38-3NN-27@gated-at.bofh.it> (permalink)
References <r4K37-3NN-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Change C/R bit in a response to a UI/UIH frame sent to
non-existing/closed channel. As DM frame type is only valid as a
response, it should be sent using gsm_response function.

Signed-off-by: Andrej Krpic <ak77@tnode.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 05b562d..8551fa4 100644
--- a/drivers/tty/n_gsm.c
+++ b/drivers/tty/n_gsm.c
@@ -1857,7 +1857,7 @@ static void gsm_queue(struct gsm_mux *gsm)
 			goto invalid;
 #endif
 		if (dlci == NULL || dlci->state != DLCI_OPEN) {
-			gsm_command(gsm, address, DM|PF);
+			gsm_response(gsm, address, DM|PF);
 			return;
 		}
 		dlci->data(dlci, gsm->buf, gsm->len);
-- 
2.7.0

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 0/8] tty: n_gsm: Make mux work as a responder station Andrej Krpic <ak77@tnode.com> - 2016-02-21 22:50 +0100
  [PATCH 6/8] tty: n_gsm: add missing length field in control channel commands Andrej Krpic <ak77@tnode.com> - 2016-02-21 22:50 +0100
  [PATCH 4/8] tty: n_gsm: send DM response when accessing an invalid channel Andrej Krpic <ak77@tnode.com> - 2016-02-21 22:50 +0100
  [PATCH 1/8] tty: n_gsm: fix formatting errors Andrej Krpic <ak77@tnode.com> - 2016-02-21 22:50 +0100
    Re: [PATCH 1/8] tty: n_gsm: fix formatting errors Joe Perches <joe@perches.com> - 2016-02-21 23:40 +0100
  Re: [PATCH 0/8] tty: n_gsm: Make mux work as a responder station One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk> - 2016-02-22 00:50 +0100

csiph-web