From: Du, Alek Date: Thu, 7 Jul 2011 14:16:48 +0000 (+0100) Subject: n_gsm: fix the wrong FCS handling X-Git-Tag: next-20110726~7^2~1 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=f086ced17191fa0c5712539d2b680eae3dc972a1;p=karo-tx-linux.git n_gsm: fix the wrong FCS handling FCS could be GSM0_SOF, so will break state machine... [This byte isn't quoted in any way so a SOF here doesn't imply an error occurred.] Signed-off-by: Alek Du Signed-off-by: Alan Cox Cc: stable [3.0] [Trivial but best backported once its in 3.1rc I think] Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/tty/n_gsm.c b/drivers/tty/n_gsm.c index a38114b01fea..14522ee8a91f 100644 --- a/drivers/tty/n_gsm.c +++ b/drivers/tty/n_gsm.c @@ -1871,10 +1871,6 @@ static void gsm0_receive(struct gsm_mux *gsm, unsigned char c) break; case GSM_FCS: /* FCS follows the packet */ gsm->received_fcs = c; - if (c == GSM0_SOF) { - gsm->state = GSM_SEARCH; - break; - } gsm_queue(gsm); gsm->state = GSM_SSOF; break;