Skip to content

Commit

Permalink
n_gsm: fix the wrong FCS handling
Browse files Browse the repository at this point in the history
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 <alek.du@intel.com>
Signed-off-by: Alan Cox <alan@linux.intel.com>
Cc: stable <stable@kernel.org> [3.0]

[Trivial but best backported once its in 3.1rc I think]
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Du, Alek authored and Greg Kroah-Hartman committed Jul 8, 2011
1 parent bff52fd commit f086ced
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions drivers/tty/n_gsm.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit f086ced

Please sign in to comment.