Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 159057
b: refs/heads/master
c: f3fad22
h: refs/heads/master
i:
  159055: b2805ac
v: v3
  • Loading branch information
Karsten Keil committed Jul 25, 2009
1 parent b096583 commit db992c8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c38fc3bc2ecddd4f5278131603e6964cbed071b2
refs/heads/master: f3fad223ed69f406f33c9619c256858d5a5fc5c7
7 changes: 6 additions & 1 deletion trunk/drivers/isdn/i4l/isdnhdlc.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ enum {
HDLC_SEND_DATA, HDLC_SEND_CRC1, HDLC_SEND_FAST_FLAG,
HDLC_SEND_FIRST_FLAG, HDLC_SEND_CRC2, HDLC_SEND_CLOSING_FLAG,
HDLC_SEND_IDLE1, HDLC_SEND_FAST_IDLE, HDLC_SENDFLAG_B0,
HDLC_SENDFLAG_B1A6, HDLC_SENDFLAG_B7, STOPPED
HDLC_SENDFLAG_B1A6, HDLC_SENDFLAG_B7, STOPPED, HDLC_SENDFLAG_ONE
};

void isdnhdlc_rcv_init(struct isdnhdlc_vars *hdlc, u32 features)
Expand Down Expand Up @@ -362,6 +362,9 @@ int isdnhdlc_encode(struct isdnhdlc_vars *hdlc, const u8 *src, u16 slen,

*count = slen;

/* special handling for one byte frames */
if ((slen == 1) && (hdlc->state == HDLC_SEND_FAST_FLAG))
hdlc->state = HDLC_SENDFLAG_ONE;
while (dsize > 0) {
if (hdlc->bit_shift == 0) {
if (slen && !hdlc->do_closing) {
Expand Down Expand Up @@ -407,6 +410,8 @@ int isdnhdlc_encode(struct isdnhdlc_vars *hdlc, const u8 *src, u16 slen,
dsize--;
break;
}
/* fall through */
case HDLC_SENDFLAG_ONE:
if (hdlc->bit_shift == 8) {
hdlc->cbin = hdlc->ffvalue >>
(8 - hdlc->data_bits);
Expand Down

0 comments on commit db992c8

Please sign in to comment.