aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/isdn/gigaset/gigaset.h
diff options
context:
space:
mode:
authorTilman Schmidt <tilman@imap.cc>2008-02-06 04:38:24 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-06 13:41:11 -0500
commitc652cbd8ee114307baab072e4e560dce5c5fb12a (patch)
tree093a7933798841060bbb2f7c847f31d1ee1d906d /drivers/isdn/gigaset/gigaset.h
parentdbd9823121b4e369bc414be75e12b4f6c84c52c0 (diff)
gigaset: code cleanups
Some cleanups to the bas-gigaset and usb-gigaset USB ISDN drivers: - simplified error handling - improved debug messages - readability improvements - removal of obsolete defines and comments Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Greg KH <gregkh@suse.de> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/isdn/gigaset/gigaset.h')
-rw-r--r--drivers/isdn/gigaset/gigaset.h18
1 files changed, 6 insertions, 12 deletions
diff --git a/drivers/isdn/gigaset/gigaset.h b/drivers/isdn/gigaset/gigaset.h
index c67b5f97c133..8303625d0401 100644
--- a/drivers/isdn/gigaset/gigaset.h
+++ b/drivers/isdn/gigaset/gigaset.h
@@ -70,22 +70,13 @@
70 70
71extern int gigaset_debuglevel; /* "needs" cast to (enum debuglevel) */ 71extern int gigaset_debuglevel; /* "needs" cast to (enum debuglevel) */
72 72
73/* any combination of these can be given with the 'debug=' parameter to insmod, 73/* debug flags, combine by adding/bitwise OR */
74 * e.g. 'insmod usb_gigaset.o debug=0x2c' will set DEBUG_OPEN, DEBUG_CMD and
75 * DEBUG_INTR.
76 */
77enum debuglevel { 74enum debuglevel {
78 DEBUG_REG = 0x0002, /* serial port I/O register operations */ 75 DEBUG_INTR = 0x00008, /* interrupt processing */
79 DEBUG_OPEN = 0x0004, /* open/close serial port */
80 DEBUG_INTR = 0x0008, /* interrupt processing */
81 DEBUG_INTR_DUMP = 0x0010, /* Activating hexdump debug output on
82 interrupt requests, not available as
83 run-time option */
84 DEBUG_CMD = 0x00020, /* sent/received LL commands */ 76 DEBUG_CMD = 0x00020, /* sent/received LL commands */
85 DEBUG_STREAM = 0x00040, /* application data stream I/O events */ 77 DEBUG_STREAM = 0x00040, /* application data stream I/O events */
86 DEBUG_STREAM_DUMP = 0x00080, /* application data stream content */ 78 DEBUG_STREAM_DUMP = 0x00080, /* application data stream content */
87 DEBUG_LLDATA = 0x00100, /* sent/received LL data */ 79 DEBUG_LLDATA = 0x00100, /* sent/received LL data */
88 DEBUG_INTR_0 = 0x00200, /* serial port interrupt processing */
89 DEBUG_DRIVER = 0x00400, /* driver structure */ 80 DEBUG_DRIVER = 0x00400, /* driver structure */
90 DEBUG_HDLC = 0x00800, /* M10x HDLC processing */ 81 DEBUG_HDLC = 0x00800, /* M10x HDLC processing */
91 DEBUG_WRITE = 0x01000, /* M105 data write */ 82 DEBUG_WRITE = 0x01000, /* M105 data write */
@@ -93,7 +84,7 @@ enum debuglevel {
93 DEBUG_MCMD = 0x04000, /* COMMANDS THAT ARE SENT VERY OFTEN */ 84 DEBUG_MCMD = 0x04000, /* COMMANDS THAT ARE SENT VERY OFTEN */
94 DEBUG_INIT = 0x08000, /* (de)allocation+initialization of data 85 DEBUG_INIT = 0x08000, /* (de)allocation+initialization of data
95 structures */ 86 structures */
96 DEBUG_LOCK = 0x10000, /* semaphore operations */ 87 DEBUG_SUSPEND = 0x10000, /* suspend/resume processing */
97 DEBUG_OUTPUT = 0x20000, /* output to device */ 88 DEBUG_OUTPUT = 0x20000, /* output to device */
98 DEBUG_ISO = 0x40000, /* isochronous transfers */ 89 DEBUG_ISO = 0x40000, /* isochronous transfers */
99 DEBUG_IF = 0x80000, /* character device operations */ 90 DEBUG_IF = 0x80000, /* character device operations */
@@ -191,6 +182,9 @@ void gigaset_dbg_buffer(enum debuglevel level, const unsigned char *msg,
191#define HD_OPEN_ATCHANNEL (0x28) // 3070 182#define HD_OPEN_ATCHANNEL (0x28) // 3070
192#define HD_CLOSE_ATCHANNEL (0x29) // 3070 183#define HD_CLOSE_ATCHANNEL (0x29) // 3070
193 184
185/* number of B channels supported by base driver */
186#define BAS_CHANNELS 2
187
194/* USB frames for isochronous transfer */ 188/* USB frames for isochronous transfer */
195#define BAS_FRAMETIME 1 /* number of milliseconds between frames */ 189#define BAS_FRAMETIME 1 /* number of milliseconds between frames */
196#define BAS_NUMFRAMES 8 /* number of frames per URB */ 190#define BAS_NUMFRAMES 8 /* number of frames per URB */