aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/isdn/hysdn/hysdn_defs.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/isdn/hysdn/hysdn_defs.h')
-rw-r--r--drivers/isdn/hysdn/hysdn_defs.h71
1 files changed, 34 insertions, 37 deletions
diff --git a/drivers/isdn/hysdn/hysdn_defs.h b/drivers/isdn/hysdn/hysdn_defs.h
index 432f6f99089e..3a9b29b38bc4 100644
--- a/drivers/isdn/hysdn/hysdn_defs.h
+++ b/drivers/isdn/hysdn/hysdn_defs.h
@@ -20,14 +20,6 @@
20#include <linux/workqueue.h> 20#include <linux/workqueue.h>
21#include <linux/skbuff.h> 21#include <linux/skbuff.h>
22 22
23/****************************/
24/* storage type definitions */
25/****************************/
26#define uchar unsigned char
27#define uint unsigned int
28#define ulong unsigned long
29#define word unsigned short
30
31#include "ince1pc.h" 23#include "ince1pc.h"
32 24
33#ifdef CONFIG_HYSDN_CAPI 25#ifdef CONFIG_HYSDN_CAPI
@@ -147,18 +139,18 @@ typedef struct HYSDN_CARD {
147 139
148 /* general variables for the cards */ 140 /* general variables for the cards */
149 int myid; /* own driver card id */ 141 int myid; /* own driver card id */
150 uchar bus; /* pci bus the card is connected to */ 142 unsigned char bus; /* pci bus the card is connected to */
151 uchar devfn; /* slot+function bit encoded */ 143 unsigned char devfn; /* slot+function bit encoded */
152 word subsysid; /* PCI subsystem id */ 144 unsigned short subsysid;/* PCI subsystem id */
153 uchar brdtype; /* type of card */ 145 unsigned char brdtype; /* type of card */
154 uint bchans; /* number of available B-channels */ 146 unsigned int bchans; /* number of available B-channels */
155 uint faxchans; /* number of available fax-channels */ 147 unsigned int faxchans; /* number of available fax-channels */
156 uchar mac_addr[6]; /* MAC Address read from card */ 148 unsigned char mac_addr[6];/* MAC Address read from card */
157 uint irq; /* interrupt number */ 149 unsigned int irq; /* interrupt number */
158 uint iobase; /* IO-port base address */ 150 unsigned int iobase; /* IO-port base address */
159 ulong plxbase; /* PLX memory base */ 151 unsigned long plxbase; /* PLX memory base */
160 ulong membase; /* DPRAM memory base */ 152 unsigned long membase; /* DPRAM memory base */
161 ulong memend; /* DPRAM memory end */ 153 unsigned long memend; /* DPRAM memory end */
162 void *dpram; /* mapped dpram */ 154 void *dpram; /* mapped dpram */
163 int state; /* actual state of card -> CARD_STATE_** */ 155 int state; /* actual state of card -> CARD_STATE_** */
164 struct HYSDN_CARD *next; /* pointer to next card */ 156 struct HYSDN_CARD *next; /* pointer to next card */
@@ -168,26 +160,26 @@ typedef struct HYSDN_CARD {
168 void *procconf; /* pointer to procconf filesystem specific data */ 160 void *procconf; /* pointer to procconf filesystem specific data */
169 161
170 /* debugging and logging */ 162 /* debugging and logging */
171 uchar err_log_state; /* actual error log state of the card */ 163 unsigned char err_log_state;/* actual error log state of the card */
172 ulong debug_flags; /* tells what should be debugged and where */ 164 unsigned long debug_flags;/* tells what should be debugged and where */
173 void (*set_errlog_state) (struct HYSDN_CARD *, int); 165 void (*set_errlog_state) (struct HYSDN_CARD *, int);
174 166
175 /* interrupt handler + interrupt synchronisation */ 167 /* interrupt handler + interrupt synchronisation */
176 struct work_struct irq_queue; /* interrupt task queue */ 168 struct work_struct irq_queue; /* interrupt task queue */
177 uchar volatile irq_enabled; /* interrupt enabled if != 0 */ 169 unsigned char volatile irq_enabled;/* interrupt enabled if != 0 */
178 uchar volatile hw_lock; /* hardware is currently locked -> no access */ 170 unsigned char volatile hw_lock;/* hardware is currently locked -> no access */
179 171
180 /* boot process */ 172 /* boot process */
181 void *boot; /* pointer to boot private data */ 173 void *boot; /* pointer to boot private data */
182 int (*writebootimg) (struct HYSDN_CARD *, uchar *, ulong); 174 int (*writebootimg) (struct HYSDN_CARD *, unsigned char *, unsigned long);
183 int (*writebootseq) (struct HYSDN_CARD *, uchar *, int); 175 int (*writebootseq) (struct HYSDN_CARD *, unsigned char *, int);
184 int (*waitpofready) (struct HYSDN_CARD *); 176 int (*waitpofready) (struct HYSDN_CARD *);
185 int (*testram) (struct HYSDN_CARD *); 177 int (*testram) (struct HYSDN_CARD *);
186 178
187 /* scheduler for data transfer (only async parts) */ 179 /* scheduler for data transfer (only async parts) */
188 uchar async_data[256]; /* async data to be sent (normally for config) */ 180 unsigned char async_data[256];/* async data to be sent (normally for config) */
189 word volatile async_len; /* length of data to sent */ 181 unsigned short volatile async_len;/* length of data to sent */
190 word volatile async_channel; /* channel number for async transfer */ 182 unsigned short volatile async_channel;/* channel number for async transfer */
191 int volatile async_busy; /* flag != 0 sending in progress */ 183 int volatile async_busy; /* flag != 0 sending in progress */
192 int volatile net_tx_busy; /* a network packet tx is in progress */ 184 int volatile net_tx_busy; /* a network packet tx is in progress */
193 185
@@ -251,15 +243,18 @@ extern int ergo_inithardware(hysdn_card * card); /* get hardware -> module init
251 243
252/* hysdn_boot.c */ 244/* hysdn_boot.c */
253extern int pof_write_close(hysdn_card *); /* close proc file after writing pof */ 245extern int pof_write_close(hysdn_card *); /* close proc file after writing pof */
254extern int pof_write_open(hysdn_card *, uchar **); /* open proc file for writing pof */ 246extern int pof_write_open(hysdn_card *, unsigned char **); /* open proc file for writing pof */
255extern int pof_write_buffer(hysdn_card *, int); /* write boot data to card */ 247extern int pof_write_buffer(hysdn_card *, int); /* write boot data to card */
256extern int EvalSysrTokData(hysdn_card *, uchar *, int); /* Check Sysready Token Data */ 248extern int EvalSysrTokData(hysdn_card *, unsigned char *, int); /* Check Sysready Token Data */
257 249
258/* hysdn_sched.c */ 250/* hysdn_sched.c */
259extern int hysdn_sched_tx(hysdn_card *, uchar *, word volatile *, word volatile *, 251extern int hysdn_sched_tx(hysdn_card *, unsigned char *,
260 word); 252 unsigned short volatile *, unsigned short volatile *,
261extern int hysdn_sched_rx(hysdn_card *, uchar *, word, word); 253 unsigned short);
262extern int hysdn_tx_cfgline(hysdn_card *, uchar *, word); /* send one cfg line */ 254extern int hysdn_sched_rx(hysdn_card *, unsigned char *, unsigned short,
255 unsigned short);
256extern int hysdn_tx_cfgline(hysdn_card *, unsigned char *,
257 unsigned short); /* send one cfg line */
263 258
264/* hysdn_net.c */ 259/* hysdn_net.c */
265extern unsigned int hynet_enable; 260extern unsigned int hynet_enable;
@@ -269,14 +264,16 @@ extern int hysdn_net_release(hysdn_card *); /* delete the device */
269extern char *hysdn_net_getname(hysdn_card *); /* get name of net interface */ 264extern char *hysdn_net_getname(hysdn_card *); /* get name of net interface */
270extern void hysdn_tx_netack(hysdn_card *); /* acknowledge a packet tx */ 265extern void hysdn_tx_netack(hysdn_card *); /* acknowledge a packet tx */
271extern struct sk_buff *hysdn_tx_netget(hysdn_card *); /* get next network packet */ 266extern struct sk_buff *hysdn_tx_netget(hysdn_card *); /* get next network packet */
272extern void hysdn_rx_netpkt(hysdn_card *, uchar *, word); /* rxed packet from network */ 267extern void hysdn_rx_netpkt(hysdn_card *, unsigned char *,
268 unsigned short); /* rxed packet from network */
273 269
274#ifdef CONFIG_HYSDN_CAPI 270#ifdef CONFIG_HYSDN_CAPI
275extern unsigned int hycapi_enable; 271extern unsigned int hycapi_enable;
276extern int hycapi_capi_create(hysdn_card *); /* create a new capi device */ 272extern int hycapi_capi_create(hysdn_card *); /* create a new capi device */
277extern int hycapi_capi_release(hysdn_card *); /* delete the device */ 273extern int hycapi_capi_release(hysdn_card *); /* delete the device */
278extern int hycapi_capi_stop(hysdn_card *card); /* suspend */ 274extern int hycapi_capi_stop(hysdn_card *card); /* suspend */
279extern void hycapi_rx_capipkt(hysdn_card * card, uchar * buf, word len); 275extern void hycapi_rx_capipkt(hysdn_card * card, unsigned char * buf,
276 unsigned short len);
280extern void hycapi_tx_capiack(hysdn_card * card); 277extern void hycapi_tx_capiack(hysdn_card * card);
281extern struct sk_buff *hycapi_tx_capiget(hysdn_card *card); 278extern struct sk_buff *hycapi_tx_capiget(hysdn_card *card);
282extern int hycapi_init(void); 279extern int hycapi_init(void);