aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/serial/jsm/jsm.h
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2005-04-16 18:25:44 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:25:44 -0400
commit614a7d6a76b7fb37bb399047eb3ccf86cafbf60d (patch)
treee7e85414691ef0f85509f1084c0cecc99f588418 /drivers/serial/jsm/jsm.h
parenta299738283a654544c75167d190d9e87b77e5fb7 (diff)
[PATCH] fix up newly added jsm driver
- plug various leaks and use after frees in the remove and initialization failure path (some still left) - remove useless global list of boards and use pci_set_drvdata instead - unobsfucate init path by merging functions together - kill various totally useless state variables - .. probably more I forgot Note that the tty part still generates lots of sparse warnings and there's still a totally useless layer of function pointer indirections, but maybe someone else will fix that bit up. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/serial/jsm/jsm.h')
-rw-r--r--drivers/serial/jsm/jsm.h38
1 files changed, 0 insertions, 38 deletions
diff --git a/drivers/serial/jsm/jsm.h b/drivers/serial/jsm/jsm.h
index b12ee02a0f7c..e0717611c940 100644
--- a/drivers/serial/jsm/jsm.h
+++ b/drivers/serial/jsm/jsm.h
@@ -93,28 +93,6 @@ enum {
93#define JSM_VERSION "jsm: 1.1-1-INKERNEL" 93#define JSM_VERSION "jsm: 1.1-1-INKERNEL"
94#define JSM_PARTNUM "40002438_A-INKERNEL" 94#define JSM_PARTNUM "40002438_A-INKERNEL"
95 95
96/*
97 * All the possible states the driver can be while being loaded.
98 */
99enum {
100 DRIVER_INITIALIZED = 0,
101 DRIVER_READY
102};
103
104/*
105 * All the possible states the board can be while booting up.
106 */
107enum {
108 BOARD_FAILED = 0,
109 BOARD_FOUND,
110 BOARD_READY
111};
112
113struct board_id {
114 u8 *name;
115 u32 maxports;
116};
117
118struct jsm_board; 96struct jsm_board;
119struct jsm_channel; 97struct jsm_channel;
120 98
@@ -149,7 +127,6 @@ struct jsm_board
149 int boardnum; /* Board number: 0-32 */ 127 int boardnum; /* Board number: 0-32 */
150 128
151 int type; /* Type of board */ 129 int type; /* Type of board */
152 char *name; /* Product Name */
153 u8 rev; /* PCI revision ID */ 130 u8 rev; /* PCI revision ID */
154 struct pci_dev *pci_dev; 131 struct pci_dev *pci_dev;
155 u32 maxports; /* MAX ports this board can handle */ 132 u32 maxports; /* MAX ports this board can handle */
@@ -160,9 +137,6 @@ struct jsm_board
160 * the interrupt routine from each other. 137 * the interrupt routine from each other.
161 */ 138 */
162 139
163 u32 state; /* State of card. */
164 wait_queue_head_t state_wait; /* Place to sleep on for state change */
165
166 u32 nasync; /* Number of ports on card */ 140 u32 nasync; /* Number of ports on card */
167 141
168 u32 irq; /* Interrupt request number */ 142 u32 irq; /* Interrupt request number */
@@ -181,9 +155,6 @@ struct jsm_board
181 struct jsm_channel *channels[MAXPORTS]; /* array of pointers to our channels. */ 155 struct jsm_channel *channels[MAXPORTS]; /* array of pointers to our channels. */
182 char *flipbuf; /* Our flip buffer, alloced if board is found */ 156 char *flipbuf; /* Our flip buffer, alloced if board is found */
183 157
184 u16 dpatype; /* The board "type", as defined by DPA */
185 u16 dpastatus; /* The board "status", as defined by DPA */
186
187 u32 bd_dividend; /* Board/UARTs specific dividend */ 158 u32 bd_dividend; /* Board/UARTs specific dividend */
188 159
189 struct board_ops *bd_ops; 160 struct board_ops *bd_ops;
@@ -412,12 +383,6 @@ extern struct board_ops jsm_neo_ops;
412extern int jsm_debug; 383extern int jsm_debug;
413extern int jsm_rawreadok; 384extern int jsm_rawreadok;
414 385
415extern int jsm_driver_state; /* The state of the driver */
416extern char *jsm_driver_state_text[];/* Array of driver state text */
417
418extern spinlock_t jsm_board_head_lock;
419extern struct list_head jsm_board_head;
420
421/************************************************************************* 386/*************************************************************************
422 * 387 *
423 * Prototypes for non-static functions used in more than one module 388 * Prototypes for non-static functions used in more than one module
@@ -431,7 +396,4 @@ void jsm_input(struct jsm_channel *ch);
431void jsm_carrier(struct jsm_channel *ch); 396void jsm_carrier(struct jsm_channel *ch);
432void jsm_check_queue_flow_control(struct jsm_channel *ch); 397void jsm_check_queue_flow_control(struct jsm_channel *ch);
433 398
434void jsm_create_driver_sysfiles(struct device_driver *);
435void jsm_remove_driver_sysfiles(struct device_driver *);
436
437#endif 399#endif