diff options
| author | Karsten Keil <[email protected]> | 2009-07-08 20:31:42 +0200 |
|---|---|---|
| committer | Karsten Keil <[email protected]> | 2009-07-25 20:16:01 +0200 |
| commit | c38fc3bc2ecddd4f5278131603e6964cbed071b2 (patch) | |
| tree | 3821cf2fc6226375bbbf8c338316eef33f5b899d /include/linux/isdn | |
| parent | 6bd4bcd3cd8affc09eaee7efbc037f65f4a71501 (diff) | |
ISDN: Add support for none reverse bitstreams to isdnhdc
The original isdnhdlc code was developed for devices which had
reversed bitorder in the byte stream. Adding code to handle normal
bitstreams as well.
Signed-off-by: Karsten Keil <[email protected]>
Diffstat (limited to 'include/linux/isdn')
| -rw-r--r-- | include/linux/isdn/hdlc.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/include/linux/isdn/hdlc.h b/include/linux/isdn/hdlc.h index 8f3540c7f692..4b3ecc40889a 100644 --- a/include/linux/isdn/hdlc.h +++ b/include/linux/isdn/hdlc.h @@ -6,6 +6,7 @@ * controllers. * * Copyright (C) + * 2009 Karsten Keil <[email protected]> * 2002 Wolfgang Mües <[email protected]> * 2001 Frode Isaksen <[email protected]> * 2001 Kai Germaschewski <[email protected]> @@ -50,8 +51,14 @@ struct isdnhdlc_vars { u32 do_adapt56:1; /* set if in closing phase (need to send CRC + flag) */ u32 do_closing:1; + /* set if data is bitreverse */ + u32 do_bitreverse:1; }; +/* Feature Flags */ +#define HDLC_56KBIT 0x01 +#define HDLC_DCHANNEL 0x02 +#define HDLC_BITREVERSE 0x04 /* The return value from isdnhdlc_decode is @@ -62,13 +69,12 @@ struct isdnhdlc_vars { #define HDLC_CRC_ERROR 2 #define HDLC_LENGTH_ERROR 3 -extern void isdnhdlc_rcv_init(struct isdnhdlc_vars *hdlc, int do_adapt56); +extern void isdnhdlc_rcv_init(struct isdnhdlc_vars *hdlc, u32 features); extern int isdnhdlc_decode(struct isdnhdlc_vars *hdlc, const u8 *src, int slen, int *count, u8 *dst, int dsize); -extern void isdnhdlc_out_init(struct isdnhdlc_vars *hdlc, int is_d_channel, - int do_adapt56); +extern void isdnhdlc_out_init(struct isdnhdlc_vars *hdlc, u32 features); extern int isdnhdlc_encode(struct isdnhdlc_vars *hdlc, const u8 *src, u16 slen, int *count, u8 *dst, int dsize); |
