diff options
Diffstat (limited to 'drivers/net/wan')
-rw-r--r-- | drivers/net/wan/cycx_drv.c | 7 | ||||
-rw-r--r-- | drivers/net/wan/cycx_main.c | 2 | ||||
-rw-r--r-- | drivers/net/wan/dscc4.c | 14 | ||||
-rw-r--r-- | drivers/net/wan/farsync.c | 24 | ||||
-rw-r--r-- | drivers/net/wan/hdlc_fr.c | 2 | ||||
-rw-r--r-- | drivers/net/wan/lmc/lmc_debug.c | 10 | ||||
-rw-r--r-- | drivers/net/wan/lmc/lmc_media.c | 8 | ||||
-rw-r--r-- | drivers/net/wan/pc300.h | 16 | ||||
-rw-r--r-- | drivers/net/wan/pc300_drv.c | 87 | ||||
-rw-r--r-- | drivers/net/wan/pc300_tty.c | 18 | ||||
-rw-r--r-- | drivers/net/wan/sdla.c | 20 | ||||
-rw-r--r-- | drivers/net/wan/sdladrv.c | 16 | ||||
-rw-r--r-- | drivers/net/wan/syncppp.c | 10 |
13 files changed, 101 insertions, 133 deletions
diff --git a/drivers/net/wan/cycx_drv.c b/drivers/net/wan/cycx_drv.c index 9e56fc346ba4..e6d005726aad 100644 --- a/drivers/net/wan/cycx_drv.c +++ b/drivers/net/wan/cycx_drv.c | |||
@@ -109,7 +109,7 @@ static long cycx_2x_irq_options[] = { 7, 3, 5, 9, 10, 11, 12, 15 }; | |||
109 | * < 0 error. | 109 | * < 0 error. |
110 | * Context: process */ | 110 | * Context: process */ |
111 | 111 | ||
112 | int __init cycx_drv_init(void) | 112 | static int __init cycx_drv_init(void) |
113 | { | 113 | { |
114 | printk(KERN_INFO "%s v%u.%u %s\n", fullname, MOD_VERSION, MOD_RELEASE, | 114 | printk(KERN_INFO "%s v%u.%u %s\n", fullname, MOD_VERSION, MOD_RELEASE, |
115 | copyright); | 115 | copyright); |
@@ -119,7 +119,7 @@ int __init cycx_drv_init(void) | |||
119 | 119 | ||
120 | /* Module 'remove' entry point. | 120 | /* Module 'remove' entry point. |
121 | * o release all remaining system resources */ | 121 | * o release all remaining system resources */ |
122 | void cycx_drv_cleanup(void) | 122 | static void cycx_drv_cleanup(void) |
123 | { | 123 | { |
124 | } | 124 | } |
125 | 125 | ||
@@ -184,8 +184,7 @@ int cycx_down(struct cycx_hw *hw) | |||
184 | } | 184 | } |
185 | 185 | ||
186 | /* Enable interrupt generation. */ | 186 | /* Enable interrupt generation. */ |
187 | EXPORT_SYMBOL(cycx_inten); | 187 | static void cycx_inten(struct cycx_hw *hw) |
188 | void cycx_inten(struct cycx_hw *hw) | ||
189 | { | 188 | { |
190 | writeb(0, hw->dpmbase); | 189 | writeb(0, hw->dpmbase); |
191 | } | 190 | } |
diff --git a/drivers/net/wan/cycx_main.c b/drivers/net/wan/cycx_main.c index 7b48064364dc..430b1f630fb4 100644 --- a/drivers/net/wan/cycx_main.c +++ b/drivers/net/wan/cycx_main.c | |||
@@ -103,7 +103,7 @@ static struct cycx_device *cycx_card_array; /* adapter data space */ | |||
103 | * < 0 error. | 103 | * < 0 error. |
104 | * Context: process | 104 | * Context: process |
105 | */ | 105 | */ |
106 | int __init cycx_init(void) | 106 | static int __init cycx_init(void) |
107 | { | 107 | { |
108 | int cnt, err = -ENOMEM; | 108 | int cnt, err = -ENOMEM; |
109 | 109 | ||
diff --git a/drivers/net/wan/dscc4.c b/drivers/net/wan/dscc4.c index 0c1ab4ac8bdb..2f61a47b4716 100644 --- a/drivers/net/wan/dscc4.c +++ b/drivers/net/wan/dscc4.c | |||
@@ -446,8 +446,8 @@ static inline unsigned int dscc4_tx_quiescent(struct dscc4_dev_priv *dpriv, | |||
446 | return readl(dpriv->base_addr + CH0FTDA + dpriv->dev_id*4) == dpriv->ltda; | 446 | return readl(dpriv->base_addr + CH0FTDA + dpriv->dev_id*4) == dpriv->ltda; |
447 | } | 447 | } |
448 | 448 | ||
449 | int state_check(u32 state, struct dscc4_dev_priv *dpriv, struct net_device *dev, | 449 | static int state_check(u32 state, struct dscc4_dev_priv *dpriv, |
450 | const char *msg) | 450 | struct net_device *dev, const char *msg) |
451 | { | 451 | { |
452 | int ret = 0; | 452 | int ret = 0; |
453 | 453 | ||
@@ -466,8 +466,9 @@ int state_check(u32 state, struct dscc4_dev_priv *dpriv, struct net_device *dev, | |||
466 | return ret; | 466 | return ret; |
467 | } | 467 | } |
468 | 468 | ||
469 | void dscc4_tx_print(struct net_device *dev, struct dscc4_dev_priv *dpriv, | 469 | static void dscc4_tx_print(struct net_device *dev, |
470 | char *msg) | 470 | struct dscc4_dev_priv *dpriv, |
471 | char *msg) | ||
471 | { | 472 | { |
472 | printk(KERN_DEBUG "%s: tx_current=%02d tx_dirty=%02d (%s)\n", | 473 | printk(KERN_DEBUG "%s: tx_current=%02d tx_dirty=%02d (%s)\n", |
473 | dev->name, dpriv->tx_current, dpriv->tx_dirty, msg); | 474 | dev->name, dpriv->tx_current, dpriv->tx_dirty, msg); |
@@ -507,7 +508,8 @@ static void dscc4_release_ring(struct dscc4_dev_priv *dpriv) | |||
507 | } | 508 | } |
508 | } | 509 | } |
509 | 510 | ||
510 | inline int try_get_rx_skb(struct dscc4_dev_priv *dpriv, struct net_device *dev) | 511 | static inline int try_get_rx_skb(struct dscc4_dev_priv *dpriv, |
512 | struct net_device *dev) | ||
511 | { | 513 | { |
512 | unsigned int dirty = dpriv->rx_dirty%RX_RING_SIZE; | 514 | unsigned int dirty = dpriv->rx_dirty%RX_RING_SIZE; |
513 | struct RxFD *rx_fd = dpriv->rx_fd + dirty; | 515 | struct RxFD *rx_fd = dpriv->rx_fd + dirty; |
@@ -1891,7 +1893,7 @@ try: | |||
1891 | * It failed and locked solid. Thus the introduction of a dummy skb. | 1893 | * It failed and locked solid. Thus the introduction of a dummy skb. |
1892 | * Problem is acknowledged in errata sheet DS5. Joy :o/ | 1894 | * Problem is acknowledged in errata sheet DS5. Joy :o/ |
1893 | */ | 1895 | */ |
1894 | struct sk_buff *dscc4_init_dummy_skb(struct dscc4_dev_priv *dpriv) | 1896 | static struct sk_buff *dscc4_init_dummy_skb(struct dscc4_dev_priv *dpriv) |
1895 | { | 1897 | { |
1896 | struct sk_buff *skb; | 1898 | struct sk_buff *skb; |
1897 | 1899 | ||
diff --git a/drivers/net/wan/farsync.c b/drivers/net/wan/farsync.c index 10befb02d768..7981a2c7906e 100644 --- a/drivers/net/wan/farsync.c +++ b/drivers/net/wan/farsync.c | |||
@@ -74,11 +74,11 @@ MODULE_LICENSE("GPL"); | |||
74 | /* | 74 | /* |
75 | * Modules parameters and associated varaibles | 75 | * Modules parameters and associated varaibles |
76 | */ | 76 | */ |
77 | int fst_txq_low = FST_LOW_WATER_MARK; | 77 | static int fst_txq_low = FST_LOW_WATER_MARK; |
78 | int fst_txq_high = FST_HIGH_WATER_MARK; | 78 | static int fst_txq_high = FST_HIGH_WATER_MARK; |
79 | int fst_max_reads = 7; | 79 | static int fst_max_reads = 7; |
80 | int fst_excluded_cards = 0; | 80 | static int fst_excluded_cards = 0; |
81 | int fst_excluded_list[FST_MAX_CARDS]; | 81 | static int fst_excluded_list[FST_MAX_CARDS]; |
82 | 82 | ||
83 | module_param(fst_txq_low, int, 0); | 83 | module_param(fst_txq_low, int, 0); |
84 | module_param(fst_txq_high, int, 0); | 84 | module_param(fst_txq_high, int, 0); |
@@ -572,13 +572,13 @@ static void do_bottom_half_rx(struct fst_card_info *card); | |||
572 | static void fst_process_tx_work_q(unsigned long work_q); | 572 | static void fst_process_tx_work_q(unsigned long work_q); |
573 | static void fst_process_int_work_q(unsigned long work_q); | 573 | static void fst_process_int_work_q(unsigned long work_q); |
574 | 574 | ||
575 | DECLARE_TASKLET(fst_tx_task, fst_process_tx_work_q, 0); | 575 | static DECLARE_TASKLET(fst_tx_task, fst_process_tx_work_q, 0); |
576 | DECLARE_TASKLET(fst_int_task, fst_process_int_work_q, 0); | 576 | static DECLARE_TASKLET(fst_int_task, fst_process_int_work_q, 0); |
577 | 577 | ||
578 | struct fst_card_info *fst_card_array[FST_MAX_CARDS]; | 578 | static struct fst_card_info *fst_card_array[FST_MAX_CARDS]; |
579 | spinlock_t fst_work_q_lock; | 579 | static spinlock_t fst_work_q_lock; |
580 | u64 fst_work_txq; | 580 | static u64 fst_work_txq; |
581 | u64 fst_work_intq; | 581 | static u64 fst_work_intq; |
582 | 582 | ||
583 | static void | 583 | static void |
584 | fst_q_work_item(u64 * queue, int card_index) | 584 | fst_q_work_item(u64 * queue, int card_index) |
@@ -1497,7 +1497,7 @@ do_bottom_half_rx(struct fst_card_info *card) | |||
1497 | * The interrupt service routine | 1497 | * The interrupt service routine |
1498 | * Dev_id is our fst_card_info pointer | 1498 | * Dev_id is our fst_card_info pointer |
1499 | */ | 1499 | */ |
1500 | irqreturn_t | 1500 | static irqreturn_t |
1501 | fst_intr(int irq, void *dev_id, struct pt_regs *regs) | 1501 | fst_intr(int irq, void *dev_id, struct pt_regs *regs) |
1502 | { | 1502 | { |
1503 | struct fst_card_info *card; | 1503 | struct fst_card_info *card; |
diff --git a/drivers/net/wan/hdlc_fr.c b/drivers/net/wan/hdlc_fr.c index a5d6891c9d4c..e1601d35dced 100644 --- a/drivers/net/wan/hdlc_fr.c +++ b/drivers/net/wan/hdlc_fr.c | |||
@@ -330,7 +330,7 @@ static int pvc_close(struct net_device *dev) | |||
330 | 330 | ||
331 | 331 | ||
332 | 332 | ||
333 | int pvc_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) | 333 | static int pvc_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) |
334 | { | 334 | { |
335 | pvc_device *pvc = dev_to_pvc(dev); | 335 | pvc_device *pvc = dev_to_pvc(dev); |
336 | fr_proto_pvc_info info; | 336 | fr_proto_pvc_info info; |
diff --git a/drivers/net/wan/lmc/lmc_debug.c b/drivers/net/wan/lmc/lmc_debug.c index 9dccd9546a17..3b94352b0d03 100644 --- a/drivers/net/wan/lmc/lmc_debug.c +++ b/drivers/net/wan/lmc/lmc_debug.c | |||
@@ -8,10 +8,10 @@ | |||
8 | /* | 8 | /* |
9 | * Prints out len, max to 80 octets using printk, 20 per line | 9 | * Prints out len, max to 80 octets using printk, 20 per line |
10 | */ | 10 | */ |
11 | void lmcConsoleLog(char *type, unsigned char *ucData, int iLen) | ||
12 | { | ||
13 | #ifdef DEBUG | 11 | #ifdef DEBUG |
14 | #ifdef LMC_PACKET_LOG | 12 | #ifdef LMC_PACKET_LOG |
13 | void lmcConsoleLog(char *type, unsigned char *ucData, int iLen) | ||
14 | { | ||
15 | int iNewLine = 1; | 15 | int iNewLine = 1; |
16 | char str[80], *pstr; | 16 | char str[80], *pstr; |
17 | 17 | ||
@@ -43,26 +43,24 @@ void lmcConsoleLog(char *type, unsigned char *ucData, int iLen) | |||
43 | } | 43 | } |
44 | sprintf(pstr, "\n"); | 44 | sprintf(pstr, "\n"); |
45 | printk(str); | 45 | printk(str); |
46 | } | ||
46 | #endif | 47 | #endif |
47 | #endif | 48 | #endif |
48 | } | ||
49 | 49 | ||
50 | #ifdef DEBUG | 50 | #ifdef DEBUG |
51 | u_int32_t lmcEventLogIndex = 0; | 51 | u_int32_t lmcEventLogIndex = 0; |
52 | u_int32_t lmcEventLogBuf[LMC_EVENTLOGSIZE * LMC_EVENTLOGARGS]; | 52 | u_int32_t lmcEventLogBuf[LMC_EVENTLOGSIZE * LMC_EVENTLOGARGS]; |
53 | #endif | ||
54 | 53 | ||
55 | void lmcEventLog (u_int32_t EventNum, u_int32_t arg2, u_int32_t arg3) | 54 | void lmcEventLog (u_int32_t EventNum, u_int32_t arg2, u_int32_t arg3) |
56 | { | 55 | { |
57 | #ifdef DEBUG | ||
58 | lmcEventLogBuf[lmcEventLogIndex++] = EventNum; | 56 | lmcEventLogBuf[lmcEventLogIndex++] = EventNum; |
59 | lmcEventLogBuf[lmcEventLogIndex++] = arg2; | 57 | lmcEventLogBuf[lmcEventLogIndex++] = arg2; |
60 | lmcEventLogBuf[lmcEventLogIndex++] = arg3; | 58 | lmcEventLogBuf[lmcEventLogIndex++] = arg3; |
61 | lmcEventLogBuf[lmcEventLogIndex++] = jiffies; | 59 | lmcEventLogBuf[lmcEventLogIndex++] = jiffies; |
62 | 60 | ||
63 | lmcEventLogIndex &= (LMC_EVENTLOGSIZE * LMC_EVENTLOGARGS) - 1; | 61 | lmcEventLogIndex &= (LMC_EVENTLOGSIZE * LMC_EVENTLOGARGS) - 1; |
64 | #endif | ||
65 | } | 62 | } |
63 | #endif /* DEBUG */ | ||
66 | 64 | ||
67 | void lmc_trace(struct net_device *dev, char *msg){ | 65 | void lmc_trace(struct net_device *dev, char *msg){ |
68 | #ifdef LMC_TRACE | 66 | #ifdef LMC_TRACE |
diff --git a/drivers/net/wan/lmc/lmc_media.c b/drivers/net/wan/lmc/lmc_media.c index f55ce76b00ed..af8b55fdd9d9 100644 --- a/drivers/net/wan/lmc/lmc_media.c +++ b/drivers/net/wan/lmc/lmc_media.c | |||
@@ -48,14 +48,6 @@ | |||
48 | */ | 48 | */ |
49 | 49 | ||
50 | /* | 50 | /* |
51 | * For lack of a better place, put the SSI cable stuff here. | ||
52 | */ | ||
53 | char *lmc_t1_cables[] = { | ||
54 | "V.10/RS423", "EIA530A", "reserved", "X.21", "V.35", | ||
55 | "EIA449/EIA530/V.36", "V.28/EIA232", "none", NULL | ||
56 | }; | ||
57 | |||
58 | /* | ||
59 | * protocol independent method. | 51 | * protocol independent method. |
60 | */ | 52 | */ |
61 | static void lmc_set_protocol (lmc_softc_t * const, lmc_ctl_t *); | 53 | static void lmc_set_protocol (lmc_softc_t * const, lmc_ctl_t *); |
diff --git a/drivers/net/wan/pc300.h b/drivers/net/wan/pc300.h index 73401b0f0151..2024b26b99e6 100644 --- a/drivers/net/wan/pc300.h +++ b/drivers/net/wan/pc300.h | |||
@@ -472,24 +472,8 @@ enum pc300_loopback_cmds { | |||
472 | 472 | ||
473 | #ifdef __KERNEL__ | 473 | #ifdef __KERNEL__ |
474 | /* Function Prototypes */ | 474 | /* Function Prototypes */ |
475 | int dma_buf_write(pc300_t *, int, ucchar *, int); | ||
476 | int dma_buf_read(pc300_t *, int, struct sk_buff *); | ||
477 | void tx_dma_start(pc300_t *, int); | 475 | void tx_dma_start(pc300_t *, int); |
478 | void rx_dma_start(pc300_t *, int); | ||
479 | void tx_dma_stop(pc300_t *, int); | ||
480 | void rx_dma_stop(pc300_t *, int); | ||
481 | int cpc_queue_xmit(struct sk_buff *, struct net_device *); | ||
482 | void cpc_net_rx(struct net_device *); | ||
483 | void cpc_sca_status(pc300_t *, int); | ||
484 | int cpc_change_mtu(struct net_device *, int); | ||
485 | int cpc_ioctl(struct net_device *, struct ifreq *, int); | ||
486 | int ch_config(pc300dev_t *); | ||
487 | int rx_config(pc300dev_t *); | ||
488 | int tx_config(pc300dev_t *); | ||
489 | void cpc_opench(pc300dev_t *); | ||
490 | void cpc_closech(pc300dev_t *); | ||
491 | int cpc_open(struct net_device *dev); | 476 | int cpc_open(struct net_device *dev); |
492 | int cpc_close(struct net_device *dev); | ||
493 | int cpc_set_media(hdlc_device *, int); | 477 | int cpc_set_media(hdlc_device *, int); |
494 | #endif /* __KERNEL__ */ | 478 | #endif /* __KERNEL__ */ |
495 | 479 | ||
diff --git a/drivers/net/wan/pc300_drv.c b/drivers/net/wan/pc300_drv.c index 3e7753b10717..a3e65d1bc19b 100644 --- a/drivers/net/wan/pc300_drv.c +++ b/drivers/net/wan/pc300_drv.c | |||
@@ -291,6 +291,7 @@ static uclong detect_ram(pc300_t *); | |||
291 | static void plx_init(pc300_t *); | 291 | static void plx_init(pc300_t *); |
292 | static void cpc_trace(struct net_device *, struct sk_buff *, char); | 292 | static void cpc_trace(struct net_device *, struct sk_buff *, char); |
293 | static int cpc_attach(struct net_device *, unsigned short, unsigned short); | 293 | static int cpc_attach(struct net_device *, unsigned short, unsigned short); |
294 | static int cpc_close(struct net_device *dev); | ||
294 | 295 | ||
295 | #ifdef CONFIG_PC300_MLPPP | 296 | #ifdef CONFIG_PC300_MLPPP |
296 | void cpc_tty_init(pc300dev_t * dev); | 297 | void cpc_tty_init(pc300dev_t * dev); |
@@ -437,7 +438,7 @@ static void rx_dma_buf_check(pc300_t * card, int ch) | |||
437 | printk("\n"); | 438 | printk("\n"); |
438 | } | 439 | } |
439 | 440 | ||
440 | int dma_get_rx_frame_size(pc300_t * card, int ch) | 441 | static int dma_get_rx_frame_size(pc300_t * card, int ch) |
441 | { | 442 | { |
442 | volatile pcsca_bd_t __iomem *ptdescr; | 443 | volatile pcsca_bd_t __iomem *ptdescr; |
443 | ucshort first_bd = card->chan[ch].rx_first_bd; | 444 | ucshort first_bd = card->chan[ch].rx_first_bd; |
@@ -462,7 +463,7 @@ int dma_get_rx_frame_size(pc300_t * card, int ch) | |||
462 | * dma_buf_write: writes a frame to the Tx DMA buffers | 463 | * dma_buf_write: writes a frame to the Tx DMA buffers |
463 | * NOTE: this function writes one frame at a time. | 464 | * NOTE: this function writes one frame at a time. |
464 | */ | 465 | */ |
465 | int dma_buf_write(pc300_t * card, int ch, ucchar * ptdata, int len) | 466 | static int dma_buf_write(pc300_t * card, int ch, ucchar * ptdata, int len) |
466 | { | 467 | { |
467 | int i, nchar; | 468 | int i, nchar; |
468 | volatile pcsca_bd_t __iomem *ptdescr; | 469 | volatile pcsca_bd_t __iomem *ptdescr; |
@@ -503,7 +504,7 @@ int dma_buf_write(pc300_t * card, int ch, ucchar * ptdata, int len) | |||
503 | * dma_buf_read: reads a frame from the Rx DMA buffers | 504 | * dma_buf_read: reads a frame from the Rx DMA buffers |
504 | * NOTE: this function reads one frame at a time. | 505 | * NOTE: this function reads one frame at a time. |
505 | */ | 506 | */ |
506 | int dma_buf_read(pc300_t * card, int ch, struct sk_buff *skb) | 507 | static int dma_buf_read(pc300_t * card, int ch, struct sk_buff *skb) |
507 | { | 508 | { |
508 | int nchar; | 509 | int nchar; |
509 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 510 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
@@ -560,7 +561,7 @@ int dma_buf_read(pc300_t * card, int ch, struct sk_buff *skb) | |||
560 | return (rcvd); | 561 | return (rcvd); |
561 | } | 562 | } |
562 | 563 | ||
563 | void tx_dma_stop(pc300_t * card, int ch) | 564 | static void tx_dma_stop(pc300_t * card, int ch) |
564 | { | 565 | { |
565 | void __iomem *scabase = card->hw.scabase; | 566 | void __iomem *scabase = card->hw.scabase; |
566 | ucchar drr_ena_bit = 1 << (5 + 2 * ch); | 567 | ucchar drr_ena_bit = 1 << (5 + 2 * ch); |
@@ -571,7 +572,7 @@ void tx_dma_stop(pc300_t * card, int ch) | |||
571 | cpc_writeb(scabase + DRR, drr_rst_bit & ~drr_ena_bit); | 572 | cpc_writeb(scabase + DRR, drr_rst_bit & ~drr_ena_bit); |
572 | } | 573 | } |
573 | 574 | ||
574 | void rx_dma_stop(pc300_t * card, int ch) | 575 | static void rx_dma_stop(pc300_t * card, int ch) |
575 | { | 576 | { |
576 | void __iomem *scabase = card->hw.scabase; | 577 | void __iomem *scabase = card->hw.scabase; |
577 | ucchar drr_ena_bit = 1 << (4 + 2 * ch); | 578 | ucchar drr_ena_bit = 1 << (4 + 2 * ch); |
@@ -582,7 +583,7 @@ void rx_dma_stop(pc300_t * card, int ch) | |||
582 | cpc_writeb(scabase + DRR, drr_rst_bit & ~drr_ena_bit); | 583 | cpc_writeb(scabase + DRR, drr_rst_bit & ~drr_ena_bit); |
583 | } | 584 | } |
584 | 585 | ||
585 | void rx_dma_start(pc300_t * card, int ch) | 586 | static void rx_dma_start(pc300_t * card, int ch) |
586 | { | 587 | { |
587 | void __iomem *scabase = card->hw.scabase; | 588 | void __iomem *scabase = card->hw.scabase; |
588 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 589 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
@@ -607,7 +608,7 @@ void rx_dma_start(pc300_t * card, int ch) | |||
607 | /*************************/ | 608 | /*************************/ |
608 | /*** FALC Routines ***/ | 609 | /*** FALC Routines ***/ |
609 | /*************************/ | 610 | /*************************/ |
610 | void falc_issue_cmd(pc300_t * card, int ch, ucchar cmd) | 611 | static void falc_issue_cmd(pc300_t * card, int ch, ucchar cmd) |
611 | { | 612 | { |
612 | void __iomem *falcbase = card->hw.falcbase; | 613 | void __iomem *falcbase = card->hw.falcbase; |
613 | unsigned long i = 0; | 614 | unsigned long i = 0; |
@@ -622,7 +623,7 @@ void falc_issue_cmd(pc300_t * card, int ch, ucchar cmd) | |||
622 | cpc_writeb(falcbase + F_REG(CMDR, ch), cmd); | 623 | cpc_writeb(falcbase + F_REG(CMDR, ch), cmd); |
623 | } | 624 | } |
624 | 625 | ||
625 | void falc_intr_enable(pc300_t * card, int ch) | 626 | static void falc_intr_enable(pc300_t * card, int ch) |
626 | { | 627 | { |
627 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 628 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
628 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 629 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -672,7 +673,7 @@ void falc_intr_enable(pc300_t * card, int ch) | |||
672 | } | 673 | } |
673 | } | 674 | } |
674 | 675 | ||
675 | void falc_open_timeslot(pc300_t * card, int ch, int timeslot) | 676 | static void falc_open_timeslot(pc300_t * card, int ch, int timeslot) |
676 | { | 677 | { |
677 | void __iomem *falcbase = card->hw.falcbase; | 678 | void __iomem *falcbase = card->hw.falcbase; |
678 | ucchar tshf = card->chan[ch].falc.offset; | 679 | ucchar tshf = card->chan[ch].falc.offset; |
@@ -688,7 +689,7 @@ void falc_open_timeslot(pc300_t * card, int ch, int timeslot) | |||
688 | (0x80 >> (timeslot & 0x07))); | 689 | (0x80 >> (timeslot & 0x07))); |
689 | } | 690 | } |
690 | 691 | ||
691 | void falc_close_timeslot(pc300_t * card, int ch, int timeslot) | 692 | static void falc_close_timeslot(pc300_t * card, int ch, int timeslot) |
692 | { | 693 | { |
693 | void __iomem *falcbase = card->hw.falcbase; | 694 | void __iomem *falcbase = card->hw.falcbase; |
694 | ucchar tshf = card->chan[ch].falc.offset; | 695 | ucchar tshf = card->chan[ch].falc.offset; |
@@ -704,7 +705,7 @@ void falc_close_timeslot(pc300_t * card, int ch, int timeslot) | |||
704 | ~(0x80 >> (timeslot & 0x07))); | 705 | ~(0x80 >> (timeslot & 0x07))); |
705 | } | 706 | } |
706 | 707 | ||
707 | void falc_close_all_timeslots(pc300_t * card, int ch) | 708 | static void falc_close_all_timeslots(pc300_t * card, int ch) |
708 | { | 709 | { |
709 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 710 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
710 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 711 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -726,7 +727,7 @@ void falc_close_all_timeslots(pc300_t * card, int ch) | |||
726 | } | 727 | } |
727 | } | 728 | } |
728 | 729 | ||
729 | void falc_open_all_timeslots(pc300_t * card, int ch) | 730 | static void falc_open_all_timeslots(pc300_t * card, int ch) |
730 | { | 731 | { |
731 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 732 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
732 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 733 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -758,7 +759,7 @@ void falc_open_all_timeslots(pc300_t * card, int ch) | |||
758 | } | 759 | } |
759 | } | 760 | } |
760 | 761 | ||
761 | void falc_init_timeslot(pc300_t * card, int ch) | 762 | static void falc_init_timeslot(pc300_t * card, int ch) |
762 | { | 763 | { |
763 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 764 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
764 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 765 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -776,7 +777,7 @@ void falc_init_timeslot(pc300_t * card, int ch) | |||
776 | } | 777 | } |
777 | } | 778 | } |
778 | 779 | ||
779 | void falc_enable_comm(pc300_t * card, int ch) | 780 | static void falc_enable_comm(pc300_t * card, int ch) |
780 | { | 781 | { |
781 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 782 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
782 | falc_t *pfalc = (falc_t *) & chan->falc; | 783 | falc_t *pfalc = (falc_t *) & chan->falc; |
@@ -792,7 +793,7 @@ void falc_enable_comm(pc300_t * card, int ch) | |||
792 | ~((CPLD_REG1_FALC_DCD | CPLD_REG1_FALC_CTS) << (2 * ch))); | 793 | ~((CPLD_REG1_FALC_DCD | CPLD_REG1_FALC_CTS) << (2 * ch))); |
793 | } | 794 | } |
794 | 795 | ||
795 | void falc_disable_comm(pc300_t * card, int ch) | 796 | static void falc_disable_comm(pc300_t * card, int ch) |
796 | { | 797 | { |
797 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 798 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
798 | falc_t *pfalc = (falc_t *) & chan->falc; | 799 | falc_t *pfalc = (falc_t *) & chan->falc; |
@@ -806,7 +807,7 @@ void falc_disable_comm(pc300_t * card, int ch) | |||
806 | ((CPLD_REG1_FALC_DCD | CPLD_REG1_FALC_CTS) << (2 * ch))); | 807 | ((CPLD_REG1_FALC_DCD | CPLD_REG1_FALC_CTS) << (2 * ch))); |
807 | } | 808 | } |
808 | 809 | ||
809 | void falc_init_t1(pc300_t * card, int ch) | 810 | static void falc_init_t1(pc300_t * card, int ch) |
810 | { | 811 | { |
811 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 812 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
812 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 813 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -975,7 +976,7 @@ void falc_init_t1(pc300_t * card, int ch) | |||
975 | falc_close_all_timeslots(card, ch); | 976 | falc_close_all_timeslots(card, ch); |
976 | } | 977 | } |
977 | 978 | ||
978 | void falc_init_e1(pc300_t * card, int ch) | 979 | static void falc_init_e1(pc300_t * card, int ch) |
979 | { | 980 | { |
980 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 981 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
981 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 982 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1155,7 +1156,7 @@ void falc_init_e1(pc300_t * card, int ch) | |||
1155 | falc_close_all_timeslots(card, ch); | 1156 | falc_close_all_timeslots(card, ch); |
1156 | } | 1157 | } |
1157 | 1158 | ||
1158 | void falc_init_hdlc(pc300_t * card, int ch) | 1159 | static void falc_init_hdlc(pc300_t * card, int ch) |
1159 | { | 1160 | { |
1160 | void __iomem *falcbase = card->hw.falcbase; | 1161 | void __iomem *falcbase = card->hw.falcbase; |
1161 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1162 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
@@ -1181,7 +1182,7 @@ void falc_init_hdlc(pc300_t * card, int ch) | |||
1181 | falc_intr_enable(card, ch); | 1182 | falc_intr_enable(card, ch); |
1182 | } | 1183 | } |
1183 | 1184 | ||
1184 | void te_config(pc300_t * card, int ch) | 1185 | static void te_config(pc300_t * card, int ch) |
1185 | { | 1186 | { |
1186 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1187 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1187 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1188 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1241,7 +1242,7 @@ void te_config(pc300_t * card, int ch) | |||
1241 | CPC_UNLOCK(card, flags); | 1242 | CPC_UNLOCK(card, flags); |
1242 | } | 1243 | } |
1243 | 1244 | ||
1244 | void falc_check_status(pc300_t * card, int ch, unsigned char frs0) | 1245 | static void falc_check_status(pc300_t * card, int ch, unsigned char frs0) |
1245 | { | 1246 | { |
1246 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1247 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1247 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1248 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1397,7 +1398,7 @@ void falc_check_status(pc300_t * card, int ch, unsigned char frs0) | |||
1397 | } | 1398 | } |
1398 | } | 1399 | } |
1399 | 1400 | ||
1400 | void falc_update_stats(pc300_t * card, int ch) | 1401 | static void falc_update_stats(pc300_t * card, int ch) |
1401 | { | 1402 | { |
1402 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1403 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1403 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1404 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1450,7 +1451,7 @@ void falc_update_stats(pc300_t * card, int ch) | |||
1450 | * the synchronizer and then sent to the system interface. | 1451 | * the synchronizer and then sent to the system interface. |
1451 | *---------------------------------------------------------------------------- | 1452 | *---------------------------------------------------------------------------- |
1452 | */ | 1453 | */ |
1453 | void falc_remote_loop(pc300_t * card, int ch, int loop_on) | 1454 | static void falc_remote_loop(pc300_t * card, int ch, int loop_on) |
1454 | { | 1455 | { |
1455 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1456 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1456 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1457 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1495,7 +1496,7 @@ void falc_remote_loop(pc300_t * card, int ch, int loop_on) | |||
1495 | * coding must be identical. | 1496 | * coding must be identical. |
1496 | *---------------------------------------------------------------------------- | 1497 | *---------------------------------------------------------------------------- |
1497 | */ | 1498 | */ |
1498 | void falc_local_loop(pc300_t * card, int ch, int loop_on) | 1499 | static void falc_local_loop(pc300_t * card, int ch, int loop_on) |
1499 | { | 1500 | { |
1500 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1501 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1501 | falc_t *pfalc = (falc_t *) & chan->falc; | 1502 | falc_t *pfalc = (falc_t *) & chan->falc; |
@@ -1522,7 +1523,7 @@ void falc_local_loop(pc300_t * card, int ch, int loop_on) | |||
1522 | * looped. They are originated by the FALC-LH transmitter. | 1523 | * looped. They are originated by the FALC-LH transmitter. |
1523 | *---------------------------------------------------------------------------- | 1524 | *---------------------------------------------------------------------------- |
1524 | */ | 1525 | */ |
1525 | void falc_payload_loop(pc300_t * card, int ch, int loop_on) | 1526 | static void falc_payload_loop(pc300_t * card, int ch, int loop_on) |
1526 | { | 1527 | { |
1527 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1528 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1528 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1529 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1576,7 +1577,7 @@ void falc_payload_loop(pc300_t * card, int ch, int loop_on) | |||
1576 | * Description: Turns XLU bit off in the proper register | 1577 | * Description: Turns XLU bit off in the proper register |
1577 | *---------------------------------------------------------------------------- | 1578 | *---------------------------------------------------------------------------- |
1578 | */ | 1579 | */ |
1579 | void turn_off_xlu(pc300_t * card, int ch) | 1580 | static void turn_off_xlu(pc300_t * card, int ch) |
1580 | { | 1581 | { |
1581 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1582 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1582 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1583 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1597,7 +1598,7 @@ void turn_off_xlu(pc300_t * card, int ch) | |||
1597 | * Description: Turns XLD bit off in the proper register | 1598 | * Description: Turns XLD bit off in the proper register |
1598 | *---------------------------------------------------------------------------- | 1599 | *---------------------------------------------------------------------------- |
1599 | */ | 1600 | */ |
1600 | void turn_off_xld(pc300_t * card, int ch) | 1601 | static void turn_off_xld(pc300_t * card, int ch) |
1601 | { | 1602 | { |
1602 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1603 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1603 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1604 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1619,7 +1620,7 @@ void turn_off_xld(pc300_t * card, int ch) | |||
1619 | * to generate a LOOP activation code over a T1/E1 line. | 1620 | * to generate a LOOP activation code over a T1/E1 line. |
1620 | *---------------------------------------------------------------------------- | 1621 | *---------------------------------------------------------------------------- |
1621 | */ | 1622 | */ |
1622 | void falc_generate_loop_up_code(pc300_t * card, int ch) | 1623 | static void falc_generate_loop_up_code(pc300_t * card, int ch) |
1623 | { | 1624 | { |
1624 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1625 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1625 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1626 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1652,7 +1653,7 @@ void falc_generate_loop_up_code(pc300_t * card, int ch) | |||
1652 | * to generate a LOOP deactivation code over a T1/E1 line. | 1653 | * to generate a LOOP deactivation code over a T1/E1 line. |
1653 | *---------------------------------------------------------------------------- | 1654 | *---------------------------------------------------------------------------- |
1654 | */ | 1655 | */ |
1655 | void falc_generate_loop_down_code(pc300_t * card, int ch) | 1656 | static void falc_generate_loop_down_code(pc300_t * card, int ch) |
1656 | { | 1657 | { |
1657 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1658 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1658 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1659 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1682,7 +1683,7 @@ void falc_generate_loop_down_code(pc300_t * card, int ch) | |||
1682 | * it on the reception side. | 1683 | * it on the reception side. |
1683 | *---------------------------------------------------------------------------- | 1684 | *---------------------------------------------------------------------------- |
1684 | */ | 1685 | */ |
1685 | void falc_pattern_test(pc300_t * card, int ch, unsigned int activate) | 1686 | static void falc_pattern_test(pc300_t * card, int ch, unsigned int activate) |
1686 | { | 1687 | { |
1687 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1688 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1688 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 1689 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -1729,7 +1730,7 @@ void falc_pattern_test(pc300_t * card, int ch, unsigned int activate) | |||
1729 | * Description: This routine returns the bit error counter value | 1730 | * Description: This routine returns the bit error counter value |
1730 | *---------------------------------------------------------------------------- | 1731 | *---------------------------------------------------------------------------- |
1731 | */ | 1732 | */ |
1732 | ucshort falc_pattern_test_error(pc300_t * card, int ch) | 1733 | static ucshort falc_pattern_test_error(pc300_t * card, int ch) |
1733 | { | 1734 | { |
1734 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; | 1735 | pc300ch_t *chan = (pc300ch_t *) & card->chan[ch]; |
1735 | falc_t *pfalc = (falc_t *) & chan->falc; | 1736 | falc_t *pfalc = (falc_t *) & chan->falc; |
@@ -1769,7 +1770,7 @@ cpc_trace(struct net_device *dev, struct sk_buff *skb_main, char rx_tx) | |||
1769 | netif_rx(skb); | 1770 | netif_rx(skb); |
1770 | } | 1771 | } |
1771 | 1772 | ||
1772 | void cpc_tx_timeout(struct net_device *dev) | 1773 | static void cpc_tx_timeout(struct net_device *dev) |
1773 | { | 1774 | { |
1774 | pc300dev_t *d = (pc300dev_t *) dev->priv; | 1775 | pc300dev_t *d = (pc300dev_t *) dev->priv; |
1775 | pc300ch_t *chan = (pc300ch_t *) d->chan; | 1776 | pc300ch_t *chan = (pc300ch_t *) d->chan; |
@@ -1797,7 +1798,7 @@ void cpc_tx_timeout(struct net_device *dev) | |||
1797 | netif_wake_queue(dev); | 1798 | netif_wake_queue(dev); |
1798 | } | 1799 | } |
1799 | 1800 | ||
1800 | int cpc_queue_xmit(struct sk_buff *skb, struct net_device *dev) | 1801 | static int cpc_queue_xmit(struct sk_buff *skb, struct net_device *dev) |
1801 | { | 1802 | { |
1802 | pc300dev_t *d = (pc300dev_t *) dev->priv; | 1803 | pc300dev_t *d = (pc300dev_t *) dev->priv; |
1803 | pc300ch_t *chan = (pc300ch_t *) d->chan; | 1804 | pc300ch_t *chan = (pc300ch_t *) d->chan; |
@@ -1880,7 +1881,7 @@ int cpc_queue_xmit(struct sk_buff *skb, struct net_device *dev) | |||
1880 | return 0; | 1881 | return 0; |
1881 | } | 1882 | } |
1882 | 1883 | ||
1883 | void cpc_net_rx(struct net_device *dev) | 1884 | static void cpc_net_rx(struct net_device *dev) |
1884 | { | 1885 | { |
1885 | pc300dev_t *d = (pc300dev_t *) dev->priv; | 1886 | pc300dev_t *d = (pc300dev_t *) dev->priv; |
1886 | pc300ch_t *chan = (pc300ch_t *) d->chan; | 1887 | pc300ch_t *chan = (pc300ch_t *) d->chan; |
@@ -2403,7 +2404,7 @@ static irqreturn_t cpc_intr(int irq, void *dev_id, struct pt_regs *regs) | |||
2403 | return IRQ_HANDLED; | 2404 | return IRQ_HANDLED; |
2404 | } | 2405 | } |
2405 | 2406 | ||
2406 | void cpc_sca_status(pc300_t * card, int ch) | 2407 | static void cpc_sca_status(pc300_t * card, int ch) |
2407 | { | 2408 | { |
2408 | ucchar ilar; | 2409 | ucchar ilar; |
2409 | void __iomem *scabase = card->hw.scabase; | 2410 | void __iomem *scabase = card->hw.scabase; |
@@ -2495,7 +2496,7 @@ void cpc_sca_status(pc300_t * card, int ch) | |||
2495 | } | 2496 | } |
2496 | } | 2497 | } |
2497 | 2498 | ||
2498 | void cpc_falc_status(pc300_t * card, int ch) | 2499 | static void cpc_falc_status(pc300_t * card, int ch) |
2499 | { | 2500 | { |
2500 | pc300ch_t *chan = &card->chan[ch]; | 2501 | pc300ch_t *chan = &card->chan[ch]; |
2501 | falc_t *pfalc = (falc_t *) & chan->falc; | 2502 | falc_t *pfalc = (falc_t *) & chan->falc; |
@@ -2523,7 +2524,7 @@ void cpc_falc_status(pc300_t * card, int ch) | |||
2523 | CPC_UNLOCK(card, flags); | 2524 | CPC_UNLOCK(card, flags); |
2524 | } | 2525 | } |
2525 | 2526 | ||
2526 | int cpc_change_mtu(struct net_device *dev, int new_mtu) | 2527 | static int cpc_change_mtu(struct net_device *dev, int new_mtu) |
2527 | { | 2528 | { |
2528 | if ((new_mtu < 128) || (new_mtu > PC300_DEF_MTU)) | 2529 | if ((new_mtu < 128) || (new_mtu > PC300_DEF_MTU)) |
2529 | return -EINVAL; | 2530 | return -EINVAL; |
@@ -2531,7 +2532,7 @@ int cpc_change_mtu(struct net_device *dev, int new_mtu) | |||
2531 | return 0; | 2532 | return 0; |
2532 | } | 2533 | } |
2533 | 2534 | ||
2534 | int cpc_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) | 2535 | static int cpc_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) |
2535 | { | 2536 | { |
2536 | hdlc_device *hdlc = dev_to_hdlc(dev); | 2537 | hdlc_device *hdlc = dev_to_hdlc(dev); |
2537 | pc300dev_t *d = (pc300dev_t *) dev->priv; | 2538 | pc300dev_t *d = (pc300dev_t *) dev->priv; |
@@ -2856,7 +2857,7 @@ static int clock_rate_calc(uclong rate, uclong clock, int *br_io) | |||
2856 | } | 2857 | } |
2857 | } | 2858 | } |
2858 | 2859 | ||
2859 | int ch_config(pc300dev_t * d) | 2860 | static int ch_config(pc300dev_t * d) |
2860 | { | 2861 | { |
2861 | pc300ch_t *chan = (pc300ch_t *) d->chan; | 2862 | pc300ch_t *chan = (pc300ch_t *) d->chan; |
2862 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; | 2863 | pc300chconf_t *conf = (pc300chconf_t *) & chan->conf; |
@@ -3004,7 +3005,7 @@ int ch_config(pc300dev_t * d) | |||
3004 | return 0; | 3005 | return 0; |
3005 | } | 3006 | } |
3006 | 3007 | ||
3007 | int rx_config(pc300dev_t * d) | 3008 | static int rx_config(pc300dev_t * d) |
3008 | { | 3009 | { |
3009 | pc300ch_t *chan = (pc300ch_t *) d->chan; | 3010 | pc300ch_t *chan = (pc300ch_t *) d->chan; |
3010 | pc300_t *card = (pc300_t *) chan->card; | 3011 | pc300_t *card = (pc300_t *) chan->card; |
@@ -3035,7 +3036,7 @@ int rx_config(pc300dev_t * d) | |||
3035 | return 0; | 3036 | return 0; |
3036 | } | 3037 | } |
3037 | 3038 | ||
3038 | int tx_config(pc300dev_t * d) | 3039 | static int tx_config(pc300dev_t * d) |
3039 | { | 3040 | { |
3040 | pc300ch_t *chan = (pc300ch_t *) d->chan; | 3041 | pc300ch_t *chan = (pc300ch_t *) d->chan; |
3041 | pc300_t *card = (pc300_t *) chan->card; | 3042 | pc300_t *card = (pc300_t *) chan->card; |
@@ -3098,7 +3099,7 @@ static int cpc_attach(struct net_device *dev, unsigned short encoding, | |||
3098 | return 0; | 3099 | return 0; |
3099 | } | 3100 | } |
3100 | 3101 | ||
3101 | void cpc_opench(pc300dev_t * d) | 3102 | static void cpc_opench(pc300dev_t * d) |
3102 | { | 3103 | { |
3103 | pc300ch_t *chan = (pc300ch_t *) d->chan; | 3104 | pc300ch_t *chan = (pc300ch_t *) d->chan; |
3104 | pc300_t *card = (pc300_t *) chan->card; | 3105 | pc300_t *card = (pc300_t *) chan->card; |
@@ -3116,7 +3117,7 @@ void cpc_opench(pc300dev_t * d) | |||
3116 | cpc_readb(scabase + M_REG(CTL, ch)) & ~(CTL_RTS | CTL_DTR)); | 3117 | cpc_readb(scabase + M_REG(CTL, ch)) & ~(CTL_RTS | CTL_DTR)); |
3117 | } | 3118 | } |
3118 | 3119 | ||
3119 | void cpc_closech(pc300dev_t * d) | 3120 | static void cpc_closech(pc300dev_t * d) |
3120 | { | 3121 | { |
3121 | pc300ch_t *chan = (pc300ch_t *) d->chan; | 3122 | pc300ch_t *chan = (pc300ch_t *) d->chan; |
3122 | pc300_t *card = (pc300_t *) chan->card; | 3123 | pc300_t *card = (pc300_t *) chan->card; |
@@ -3173,7 +3174,7 @@ int cpc_open(struct net_device *dev) | |||
3173 | return 0; | 3174 | return 0; |
3174 | } | 3175 | } |
3175 | 3176 | ||
3176 | int cpc_close(struct net_device *dev) | 3177 | static int cpc_close(struct net_device *dev) |
3177 | { | 3178 | { |
3178 | hdlc_device *hdlc = dev_to_hdlc(dev); | 3179 | hdlc_device *hdlc = dev_to_hdlc(dev); |
3179 | pc300dev_t *d = (pc300dev_t *) dev->priv; | 3180 | pc300dev_t *d = (pc300dev_t *) dev->priv; |
diff --git a/drivers/net/wan/pc300_tty.c b/drivers/net/wan/pc300_tty.c index 8454bf6caaa7..52f26b9c69d2 100644 --- a/drivers/net/wan/pc300_tty.c +++ b/drivers/net/wan/pc300_tty.c | |||
@@ -112,10 +112,10 @@ typedef struct _st_cpc_tty_area { | |||
112 | static struct tty_driver serial_drv; | 112 | static struct tty_driver serial_drv; |
113 | 113 | ||
114 | /* local variables */ | 114 | /* local variables */ |
115 | st_cpc_tty_area cpc_tty_area[CPC_TTY_NPORTS]; | 115 | static st_cpc_tty_area cpc_tty_area[CPC_TTY_NPORTS]; |
116 | 116 | ||
117 | int cpc_tty_cnt=0; /* number of intrfaces configured with MLPPP */ | 117 | static int cpc_tty_cnt = 0; /* number of intrfaces configured with MLPPP */ |
118 | int cpc_tty_unreg_flag = 0; | 118 | static int cpc_tty_unreg_flag = 0; |
119 | 119 | ||
120 | /* TTY functions prototype */ | 120 | /* TTY functions prototype */ |
121 | static int cpc_tty_open(struct tty_struct *tty, struct file *flip); | 121 | static int cpc_tty_open(struct tty_struct *tty, struct file *flip); |
@@ -132,9 +132,9 @@ static void cpc_tty_trace(pc300dev_t *dev, char* buf, int len, char rxtx); | |||
132 | static void cpc_tty_signal_off(pc300dev_t *pc300dev, unsigned char); | 132 | static void cpc_tty_signal_off(pc300dev_t *pc300dev, unsigned char); |
133 | static void cpc_tty_signal_on(pc300dev_t *pc300dev, unsigned char); | 133 | static void cpc_tty_signal_on(pc300dev_t *pc300dev, unsigned char); |
134 | 134 | ||
135 | int pc300_tiocmset(struct tty_struct *, struct file *, | 135 | static int pc300_tiocmset(struct tty_struct *, struct file *, |
136 | unsigned int, unsigned int); | 136 | unsigned int, unsigned int); |
137 | int pc300_tiocmget(struct tty_struct *, struct file *); | 137 | static int pc300_tiocmget(struct tty_struct *, struct file *); |
138 | 138 | ||
139 | /* functions called by PC300 driver */ | 139 | /* functions called by PC300 driver */ |
140 | void cpc_tty_init(pc300dev_t *dev); | 140 | void cpc_tty_init(pc300dev_t *dev); |
@@ -538,8 +538,8 @@ static int cpc_tty_chars_in_buffer(struct tty_struct *tty) | |||
538 | return(0); | 538 | return(0); |
539 | } | 539 | } |
540 | 540 | ||
541 | int pc300_tiocmset(struct tty_struct *tty, struct file *file, | 541 | static int pc300_tiocmset(struct tty_struct *tty, struct file *file, |
542 | unsigned int set, unsigned int clear) | 542 | unsigned int set, unsigned int clear) |
543 | { | 543 | { |
544 | st_cpc_tty_area *cpc_tty; | 544 | st_cpc_tty_area *cpc_tty; |
545 | 545 | ||
@@ -565,7 +565,7 @@ int pc300_tiocmset(struct tty_struct *tty, struct file *file, | |||
565 | return 0; | 565 | return 0; |
566 | } | 566 | } |
567 | 567 | ||
568 | int pc300_tiocmget(struct tty_struct *tty, struct file *file) | 568 | static int pc300_tiocmget(struct tty_struct *tty, struct file *file) |
569 | { | 569 | { |
570 | unsigned int result; | 570 | unsigned int result; |
571 | unsigned char status; | 571 | unsigned char status; |
diff --git a/drivers/net/wan/sdla.c b/drivers/net/wan/sdla.c index 3ac9a45b20fa..036adc4f8ba7 100644 --- a/drivers/net/wan/sdla.c +++ b/drivers/net/wan/sdla.c | |||
@@ -182,7 +182,7 @@ static char sdla_byte(struct net_device *dev, int addr) | |||
182 | return(byte); | 182 | return(byte); |
183 | } | 183 | } |
184 | 184 | ||
185 | void sdla_stop(struct net_device *dev) | 185 | static void sdla_stop(struct net_device *dev) |
186 | { | 186 | { |
187 | struct frad_local *flp; | 187 | struct frad_local *flp; |
188 | 188 | ||
@@ -209,7 +209,7 @@ void sdla_stop(struct net_device *dev) | |||
209 | } | 209 | } |
210 | } | 210 | } |
211 | 211 | ||
212 | void sdla_start(struct net_device *dev) | 212 | static void sdla_start(struct net_device *dev) |
213 | { | 213 | { |
214 | struct frad_local *flp; | 214 | struct frad_local *flp; |
215 | 215 | ||
@@ -247,7 +247,7 @@ void sdla_start(struct net_device *dev) | |||
247 | * | 247 | * |
248 | ***************************************************/ | 248 | ***************************************************/ |
249 | 249 | ||
250 | int sdla_z80_poll(struct net_device *dev, int z80_addr, int jiffs, char resp1, char resp2) | 250 | static int sdla_z80_poll(struct net_device *dev, int z80_addr, int jiffs, char resp1, char resp2) |
251 | { | 251 | { |
252 | unsigned long start, done, now; | 252 | unsigned long start, done, now; |
253 | char resp, *temp; | 253 | char resp, *temp; |
@@ -505,7 +505,7 @@ static int sdla_cmd(struct net_device *dev, int cmd, short dlci, short flags, | |||
505 | 505 | ||
506 | static int sdla_reconfig(struct net_device *dev); | 506 | static int sdla_reconfig(struct net_device *dev); |
507 | 507 | ||
508 | int sdla_activate(struct net_device *slave, struct net_device *master) | 508 | static int sdla_activate(struct net_device *slave, struct net_device *master) |
509 | { | 509 | { |
510 | struct frad_local *flp; | 510 | struct frad_local *flp; |
511 | int i; | 511 | int i; |
@@ -527,7 +527,7 @@ int sdla_activate(struct net_device *slave, struct net_device *master) | |||
527 | return(0); | 527 | return(0); |
528 | } | 528 | } |
529 | 529 | ||
530 | int sdla_deactivate(struct net_device *slave, struct net_device *master) | 530 | static int sdla_deactivate(struct net_device *slave, struct net_device *master) |
531 | { | 531 | { |
532 | struct frad_local *flp; | 532 | struct frad_local *flp; |
533 | int i; | 533 | int i; |
@@ -549,7 +549,7 @@ int sdla_deactivate(struct net_device *slave, struct net_device *master) | |||
549 | return(0); | 549 | return(0); |
550 | } | 550 | } |
551 | 551 | ||
552 | int sdla_assoc(struct net_device *slave, struct net_device *master) | 552 | static int sdla_assoc(struct net_device *slave, struct net_device *master) |
553 | { | 553 | { |
554 | struct frad_local *flp; | 554 | struct frad_local *flp; |
555 | int i; | 555 | int i; |
@@ -585,7 +585,7 @@ int sdla_assoc(struct net_device *slave, struct net_device *master) | |||
585 | return(0); | 585 | return(0); |
586 | } | 586 | } |
587 | 587 | ||
588 | int sdla_deassoc(struct net_device *slave, struct net_device *master) | 588 | static int sdla_deassoc(struct net_device *slave, struct net_device *master) |
589 | { | 589 | { |
590 | struct frad_local *flp; | 590 | struct frad_local *flp; |
591 | int i; | 591 | int i; |
@@ -613,7 +613,7 @@ int sdla_deassoc(struct net_device *slave, struct net_device *master) | |||
613 | return(0); | 613 | return(0); |
614 | } | 614 | } |
615 | 615 | ||
616 | int sdla_dlci_conf(struct net_device *slave, struct net_device *master, int get) | 616 | static int sdla_dlci_conf(struct net_device *slave, struct net_device *master, int get) |
617 | { | 617 | { |
618 | struct frad_local *flp; | 618 | struct frad_local *flp; |
619 | struct dlci_local *dlp; | 619 | struct dlci_local *dlp; |
@@ -1324,7 +1324,7 @@ NOTE: This is rather a useless action right now, as the | |||
1324 | return(0); | 1324 | return(0); |
1325 | } | 1325 | } |
1326 | 1326 | ||
1327 | int sdla_change_mtu(struct net_device *dev, int new_mtu) | 1327 | static int sdla_change_mtu(struct net_device *dev, int new_mtu) |
1328 | { | 1328 | { |
1329 | struct frad_local *flp; | 1329 | struct frad_local *flp; |
1330 | 1330 | ||
@@ -1337,7 +1337,7 @@ int sdla_change_mtu(struct net_device *dev, int new_mtu) | |||
1337 | return(-EOPNOTSUPP); | 1337 | return(-EOPNOTSUPP); |
1338 | } | 1338 | } |
1339 | 1339 | ||
1340 | int sdla_set_config(struct net_device *dev, struct ifmap *map) | 1340 | static int sdla_set_config(struct net_device *dev, struct ifmap *map) |
1341 | { | 1341 | { |
1342 | struct frad_local *flp; | 1342 | struct frad_local *flp; |
1343 | int i; | 1343 | int i; |
diff --git a/drivers/net/wan/sdladrv.c b/drivers/net/wan/sdladrv.c index c8bc6da57a41..7c2cf2e76300 100644 --- a/drivers/net/wan/sdladrv.c +++ b/drivers/net/wan/sdladrv.c | |||
@@ -642,9 +642,7 @@ int sdla_mapmem (sdlahw_t* hw, unsigned long addr) | |||
642 | * Enable interrupt generation. | 642 | * Enable interrupt generation. |
643 | */ | 643 | */ |
644 | 644 | ||
645 | EXPORT_SYMBOL(sdla_inten); | 645 | static int sdla_inten (sdlahw_t* hw) |
646 | |||
647 | int sdla_inten (sdlahw_t* hw) | ||
648 | { | 646 | { |
649 | unsigned port = hw->port; | 647 | unsigned port = hw->port; |
650 | int tmp, i; | 648 | int tmp, i; |
@@ -698,8 +696,7 @@ int sdla_inten (sdlahw_t* hw) | |||
698 | * Disable interrupt generation. | 696 | * Disable interrupt generation. |
699 | */ | 697 | */ |
700 | 698 | ||
701 | EXPORT_SYMBOL(sdla_intde); | 699 | #if 0 |
702 | |||
703 | int sdla_intde (sdlahw_t* hw) | 700 | int sdla_intde (sdlahw_t* hw) |
704 | { | 701 | { |
705 | unsigned port = hw->port; | 702 | unsigned port = hw->port; |
@@ -748,14 +745,13 @@ int sdla_intde (sdlahw_t* hw) | |||
748 | } | 745 | } |
749 | return 0; | 746 | return 0; |
750 | } | 747 | } |
748 | #endif /* 0 */ | ||
751 | 749 | ||
752 | /*============================================================================ | 750 | /*============================================================================ |
753 | * Acknowledge SDLA hardware interrupt. | 751 | * Acknowledge SDLA hardware interrupt. |
754 | */ | 752 | */ |
755 | 753 | ||
756 | EXPORT_SYMBOL(sdla_intack); | 754 | static int sdla_intack (sdlahw_t* hw) |
757 | |||
758 | int sdla_intack (sdlahw_t* hw) | ||
759 | { | 755 | { |
760 | unsigned port = hw->port; | 756 | unsigned port = hw->port; |
761 | int tmp; | 757 | int tmp; |
@@ -827,8 +823,7 @@ void read_S514_int_stat (sdlahw_t* hw, u32* int_status) | |||
827 | * Generate an interrupt to adapter's CPU. | 823 | * Generate an interrupt to adapter's CPU. |
828 | */ | 824 | */ |
829 | 825 | ||
830 | EXPORT_SYMBOL(sdla_intr); | 826 | #if 0 |
831 | |||
832 | int sdla_intr (sdlahw_t* hw) | 827 | int sdla_intr (sdlahw_t* hw) |
833 | { | 828 | { |
834 | unsigned port = hw->port; | 829 | unsigned port = hw->port; |
@@ -863,6 +858,7 @@ int sdla_intr (sdlahw_t* hw) | |||
863 | } | 858 | } |
864 | return 0; | 859 | return 0; |
865 | } | 860 | } |
861 | #endif /* 0 */ | ||
866 | 862 | ||
867 | /*============================================================================ | 863 | /*============================================================================ |
868 | * Execute Adapter Command. | 864 | * Execute Adapter Command. |
diff --git a/drivers/net/wan/syncppp.c b/drivers/net/wan/syncppp.c index b56a7b516d24..3731b22f6757 100644 --- a/drivers/net/wan/syncppp.c +++ b/drivers/net/wan/syncppp.c | |||
@@ -221,7 +221,7 @@ static void sppp_clear_timeout(struct sppp *p) | |||
221 | * here. | 221 | * here. |
222 | */ | 222 | */ |
223 | 223 | ||
224 | void sppp_input (struct net_device *dev, struct sk_buff *skb) | 224 | static void sppp_input (struct net_device *dev, struct sk_buff *skb) |
225 | { | 225 | { |
226 | struct ppp_header *h; | 226 | struct ppp_header *h; |
227 | struct sppp *sp = (struct sppp *)sppp_of(dev); | 227 | struct sppp *sp = (struct sppp *)sppp_of(dev); |
@@ -355,8 +355,6 @@ done: | |||
355 | return; | 355 | return; |
356 | } | 356 | } |
357 | 357 | ||
358 | EXPORT_SYMBOL(sppp_input); | ||
359 | |||
360 | /* | 358 | /* |
361 | * Handle transmit packets. | 359 | * Handle transmit packets. |
362 | */ | 360 | */ |
@@ -990,7 +988,7 @@ EXPORT_SYMBOL(sppp_reopen); | |||
990 | * the mtu is out of range. | 988 | * the mtu is out of range. |
991 | */ | 989 | */ |
992 | 990 | ||
993 | int sppp_change_mtu(struct net_device *dev, int new_mtu) | 991 | static int sppp_change_mtu(struct net_device *dev, int new_mtu) |
994 | { | 992 | { |
995 | if(new_mtu<128||new_mtu>PPP_MTU||(dev->flags&IFF_UP)) | 993 | if(new_mtu<128||new_mtu>PPP_MTU||(dev->flags&IFF_UP)) |
996 | return -EINVAL; | 994 | return -EINVAL; |
@@ -998,8 +996,6 @@ int sppp_change_mtu(struct net_device *dev, int new_mtu) | |||
998 | return 0; | 996 | return 0; |
999 | } | 997 | } |
1000 | 998 | ||
1001 | EXPORT_SYMBOL(sppp_change_mtu); | ||
1002 | |||
1003 | /** | 999 | /** |
1004 | * sppp_do_ioctl - Ioctl handler for ppp/hdlc | 1000 | * sppp_do_ioctl - Ioctl handler for ppp/hdlc |
1005 | * @dev: Device subject to ioctl | 1001 | * @dev: Device subject to ioctl |
@@ -1456,7 +1452,7 @@ static int sppp_rcv(struct sk_buff *skb, struct net_device *dev, struct packet_t | |||
1456 | return 0; | 1452 | return 0; |
1457 | } | 1453 | } |
1458 | 1454 | ||
1459 | struct packet_type sppp_packet_type = { | 1455 | static struct packet_type sppp_packet_type = { |
1460 | .type = __constant_htons(ETH_P_WAN_PPP), | 1456 | .type = __constant_htons(ETH_P_WAN_PPP), |
1461 | .func = sppp_rcv, | 1457 | .func = sppp_rcv, |
1462 | }; | 1458 | }; |