diff options
author | Peter Hagervall <hager@cs.umu.se> | 2006-06-23 05:06:04 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-23 10:43:08 -0400 |
commit | cdaad343b561cdeb38b0578bb038eb5e87ed5551 (patch) | |
tree | e9f43e14114b7bb46d3175df92a1de5643b2f976 | |
parent | 908dcecda1d18803b5823f30e6c47d2882dc0cf1 (diff) |
[PATCH] Sparse fixes for synclink_cs
Mark a few non-exported functions static.
Signed-off-by: Peter Hagervall <hager@cs.umu.se>
Cc: Paul Fulghum <paulkf@microgate.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r-- | drivers/char/pcmcia/synclink_cs.c | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/drivers/char/pcmcia/synclink_cs.c b/drivers/char/pcmcia/synclink_cs.c index 07213454c458..0c141c295fb6 100644 --- a/drivers/char/pcmcia/synclink_cs.c +++ b/drivers/char/pcmcia/synclink_cs.c | |||
@@ -844,7 +844,7 @@ static int bh_action(MGSLPC_INFO *info) | |||
844 | return rc; | 844 | return rc; |
845 | } | 845 | } |
846 | 846 | ||
847 | void bh_handler(void* Context) | 847 | static void bh_handler(void* Context) |
848 | { | 848 | { |
849 | MGSLPC_INFO *info = (MGSLPC_INFO*)Context; | 849 | MGSLPC_INFO *info = (MGSLPC_INFO*)Context; |
850 | int action; | 850 | int action; |
@@ -888,7 +888,7 @@ void bh_handler(void* Context) | |||
888 | __FILE__,__LINE__,info->device_name); | 888 | __FILE__,__LINE__,info->device_name); |
889 | } | 889 | } |
890 | 890 | ||
891 | void bh_transmit(MGSLPC_INFO *info) | 891 | static void bh_transmit(MGSLPC_INFO *info) |
892 | { | 892 | { |
893 | struct tty_struct *tty = info->tty; | 893 | struct tty_struct *tty = info->tty; |
894 | if (debug_level >= DEBUG_LEVEL_BH) | 894 | if (debug_level >= DEBUG_LEVEL_BH) |
@@ -900,7 +900,7 @@ void bh_transmit(MGSLPC_INFO *info) | |||
900 | } | 900 | } |
901 | } | 901 | } |
902 | 902 | ||
903 | void bh_status(MGSLPC_INFO *info) | 903 | static void bh_status(MGSLPC_INFO *info) |
904 | { | 904 | { |
905 | info->ri_chkcount = 0; | 905 | info->ri_chkcount = 0; |
906 | info->dsr_chkcount = 0; | 906 | info->dsr_chkcount = 0; |
@@ -2305,7 +2305,7 @@ static int mgslpc_ioctl(struct tty_struct *tty, struct file * file, | |||
2305 | return ioctl_common(info, cmd, arg); | 2305 | return ioctl_common(info, cmd, arg); |
2306 | } | 2306 | } |
2307 | 2307 | ||
2308 | int ioctl_common(MGSLPC_INFO *info, unsigned int cmd, unsigned long arg) | 2308 | static int ioctl_common(MGSLPC_INFO *info, unsigned int cmd, unsigned long arg) |
2309 | { | 2309 | { |
2310 | int error; | 2310 | int error; |
2311 | struct mgsl_icount cnow; /* kernel counter temps */ | 2311 | struct mgsl_icount cnow; /* kernel counter temps */ |
@@ -2877,7 +2877,7 @@ done: | |||
2877 | return ((count < begin+len-off) ? count : begin+len-off); | 2877 | return ((count < begin+len-off) ? count : begin+len-off); |
2878 | } | 2878 | } |
2879 | 2879 | ||
2880 | int rx_alloc_buffers(MGSLPC_INFO *info) | 2880 | static int rx_alloc_buffers(MGSLPC_INFO *info) |
2881 | { | 2881 | { |
2882 | /* each buffer has header and data */ | 2882 | /* each buffer has header and data */ |
2883 | info->rx_buf_size = sizeof(RXBUF) + info->max_frame_size; | 2883 | info->rx_buf_size = sizeof(RXBUF) + info->max_frame_size; |
@@ -2900,13 +2900,13 @@ int rx_alloc_buffers(MGSLPC_INFO *info) | |||
2900 | return 0; | 2900 | return 0; |
2901 | } | 2901 | } |
2902 | 2902 | ||
2903 | void rx_free_buffers(MGSLPC_INFO *info) | 2903 | static void rx_free_buffers(MGSLPC_INFO *info) |
2904 | { | 2904 | { |
2905 | kfree(info->rx_buf); | 2905 | kfree(info->rx_buf); |
2906 | info->rx_buf = NULL; | 2906 | info->rx_buf = NULL; |
2907 | } | 2907 | } |
2908 | 2908 | ||
2909 | int claim_resources(MGSLPC_INFO *info) | 2909 | static int claim_resources(MGSLPC_INFO *info) |
2910 | { | 2910 | { |
2911 | if (rx_alloc_buffers(info) < 0 ) { | 2911 | if (rx_alloc_buffers(info) < 0 ) { |
2912 | printk( "Cant allocate rx buffer %s\n", info->device_name); | 2912 | printk( "Cant allocate rx buffer %s\n", info->device_name); |
@@ -2916,7 +2916,7 @@ int claim_resources(MGSLPC_INFO *info) | |||
2916 | return 0; | 2916 | return 0; |
2917 | } | 2917 | } |
2918 | 2918 | ||
2919 | void release_resources(MGSLPC_INFO *info) | 2919 | static void release_resources(MGSLPC_INFO *info) |
2920 | { | 2920 | { |
2921 | if (debug_level >= DEBUG_LEVEL_INFO) | 2921 | if (debug_level >= DEBUG_LEVEL_INFO) |
2922 | printk("release_resources(%s)\n", info->device_name); | 2922 | printk("release_resources(%s)\n", info->device_name); |
@@ -2928,7 +2928,7 @@ void release_resources(MGSLPC_INFO *info) | |||
2928 | * | 2928 | * |
2929 | * Arguments: info pointer to device instance data | 2929 | * Arguments: info pointer to device instance data |
2930 | */ | 2930 | */ |
2931 | void mgslpc_add_device(MGSLPC_INFO *info) | 2931 | static void mgslpc_add_device(MGSLPC_INFO *info) |
2932 | { | 2932 | { |
2933 | info->next_device = NULL; | 2933 | info->next_device = NULL; |
2934 | info->line = mgslpc_device_count; | 2934 | info->line = mgslpc_device_count; |
@@ -2964,7 +2964,7 @@ void mgslpc_add_device(MGSLPC_INFO *info) | |||
2964 | #endif | 2964 | #endif |
2965 | } | 2965 | } |
2966 | 2966 | ||
2967 | void mgslpc_remove_device(MGSLPC_INFO *remove_info) | 2967 | static void mgslpc_remove_device(MGSLPC_INFO *remove_info) |
2968 | { | 2968 | { |
2969 | MGSLPC_INFO *info = mgslpc_device_list; | 2969 | MGSLPC_INFO *info = mgslpc_device_list; |
2970 | MGSLPC_INFO *last = NULL; | 2970 | MGSLPC_INFO *last = NULL; |
@@ -3257,7 +3257,7 @@ static void loopback_enable(MGSLPC_INFO *info) | |||
3257 | write_reg(info, CHA + MODE, val); | 3257 | write_reg(info, CHA + MODE, val); |
3258 | } | 3258 | } |
3259 | 3259 | ||
3260 | void hdlc_mode(MGSLPC_INFO *info) | 3260 | static void hdlc_mode(MGSLPC_INFO *info) |
3261 | { | 3261 | { |
3262 | unsigned char val; | 3262 | unsigned char val; |
3263 | unsigned char clkmode, clksubmode; | 3263 | unsigned char clkmode, clksubmode; |
@@ -3497,7 +3497,7 @@ void hdlc_mode(MGSLPC_INFO *info) | |||
3497 | rx_stop(info); | 3497 | rx_stop(info); |
3498 | } | 3498 | } |
3499 | 3499 | ||
3500 | void rx_stop(MGSLPC_INFO *info) | 3500 | static void rx_stop(MGSLPC_INFO *info) |
3501 | { | 3501 | { |
3502 | if (debug_level >= DEBUG_LEVEL_ISR) | 3502 | if (debug_level >= DEBUG_LEVEL_ISR) |
3503 | printk("%s(%d):rx_stop(%s)\n", | 3503 | printk("%s(%d):rx_stop(%s)\n", |
@@ -3510,7 +3510,7 @@ void rx_stop(MGSLPC_INFO *info) | |||
3510 | info->rx_overflow = 0; | 3510 | info->rx_overflow = 0; |
3511 | } | 3511 | } |
3512 | 3512 | ||
3513 | void rx_start(MGSLPC_INFO *info) | 3513 | static void rx_start(MGSLPC_INFO *info) |
3514 | { | 3514 | { |
3515 | if (debug_level >= DEBUG_LEVEL_ISR) | 3515 | if (debug_level >= DEBUG_LEVEL_ISR) |
3516 | printk("%s(%d):rx_start(%s)\n", | 3516 | printk("%s(%d):rx_start(%s)\n", |
@@ -3526,7 +3526,7 @@ void rx_start(MGSLPC_INFO *info) | |||
3526 | info->rx_enabled = 1; | 3526 | info->rx_enabled = 1; |
3527 | } | 3527 | } |
3528 | 3528 | ||
3529 | void tx_start(MGSLPC_INFO *info) | 3529 | static void tx_start(MGSLPC_INFO *info) |
3530 | { | 3530 | { |
3531 | if (debug_level >= DEBUG_LEVEL_ISR) | 3531 | if (debug_level >= DEBUG_LEVEL_ISR) |
3532 | printk("%s(%d):tx_start(%s)\n", | 3532 | printk("%s(%d):tx_start(%s)\n", |
@@ -3564,7 +3564,7 @@ void tx_start(MGSLPC_INFO *info) | |||
3564 | info->tx_enabled = 1; | 3564 | info->tx_enabled = 1; |
3565 | } | 3565 | } |
3566 | 3566 | ||
3567 | void tx_stop(MGSLPC_INFO *info) | 3567 | static void tx_stop(MGSLPC_INFO *info) |
3568 | { | 3568 | { |
3569 | if (debug_level >= DEBUG_LEVEL_ISR) | 3569 | if (debug_level >= DEBUG_LEVEL_ISR) |
3570 | printk("%s(%d):tx_stop(%s)\n", | 3570 | printk("%s(%d):tx_stop(%s)\n", |
@@ -3578,7 +3578,7 @@ void tx_stop(MGSLPC_INFO *info) | |||
3578 | 3578 | ||
3579 | /* Reset the adapter to a known state and prepare it for further use. | 3579 | /* Reset the adapter to a known state and prepare it for further use. |
3580 | */ | 3580 | */ |
3581 | void reset_device(MGSLPC_INFO *info) | 3581 | static void reset_device(MGSLPC_INFO *info) |
3582 | { | 3582 | { |
3583 | /* power up both channels (set BIT7) */ | 3583 | /* power up both channels (set BIT7) */ |
3584 | write_reg(info, CHA + CCR0, 0x80); | 3584 | write_reg(info, CHA + CCR0, 0x80); |
@@ -3628,7 +3628,7 @@ void reset_device(MGSLPC_INFO *info) | |||
3628 | write_reg(info, IPC, 0x05); | 3628 | write_reg(info, IPC, 0x05); |
3629 | } | 3629 | } |
3630 | 3630 | ||
3631 | void async_mode(MGSLPC_INFO *info) | 3631 | static void async_mode(MGSLPC_INFO *info) |
3632 | { | 3632 | { |
3633 | unsigned char val; | 3633 | unsigned char val; |
3634 | 3634 | ||
@@ -3799,7 +3799,7 @@ void async_mode(MGSLPC_INFO *info) | |||
3799 | 3799 | ||
3800 | /* Set the HDLC idle mode for the transmitter. | 3800 | /* Set the HDLC idle mode for the transmitter. |
3801 | */ | 3801 | */ |
3802 | void tx_set_idle(MGSLPC_INFO *info) | 3802 | static void tx_set_idle(MGSLPC_INFO *info) |
3803 | { | 3803 | { |
3804 | /* Note: ESCC2 only supports flags and one idle modes */ | 3804 | /* Note: ESCC2 only supports flags and one idle modes */ |
3805 | if (info->idle_mode == HDLC_TXIDLE_FLAGS) | 3805 | if (info->idle_mode == HDLC_TXIDLE_FLAGS) |
@@ -3810,7 +3810,7 @@ void tx_set_idle(MGSLPC_INFO *info) | |||
3810 | 3810 | ||
3811 | /* get state of the V24 status (input) signals. | 3811 | /* get state of the V24 status (input) signals. |
3812 | */ | 3812 | */ |
3813 | void get_signals(MGSLPC_INFO *info) | 3813 | static void get_signals(MGSLPC_INFO *info) |
3814 | { | 3814 | { |
3815 | unsigned char status = 0; | 3815 | unsigned char status = 0; |
3816 | 3816 | ||
@@ -3832,7 +3832,7 @@ void get_signals(MGSLPC_INFO *info) | |||
3832 | /* Set the state of DTR and RTS based on contents of | 3832 | /* Set the state of DTR and RTS based on contents of |
3833 | * serial_signals member of device extension. | 3833 | * serial_signals member of device extension. |
3834 | */ | 3834 | */ |
3835 | void set_signals(MGSLPC_INFO *info) | 3835 | static void set_signals(MGSLPC_INFO *info) |
3836 | { | 3836 | { |
3837 | unsigned char val; | 3837 | unsigned char val; |
3838 | 3838 | ||
@@ -3856,7 +3856,7 @@ void set_signals(MGSLPC_INFO *info) | |||
3856 | set_reg_bits(info, CHA + PVR, PVR_DTR); | 3856 | set_reg_bits(info, CHA + PVR, PVR_DTR); |
3857 | } | 3857 | } |
3858 | 3858 | ||
3859 | void rx_reset_buffers(MGSLPC_INFO *info) | 3859 | static void rx_reset_buffers(MGSLPC_INFO *info) |
3860 | { | 3860 | { |
3861 | RXBUF *buf; | 3861 | RXBUF *buf; |
3862 | int i; | 3862 | int i; |
@@ -3875,7 +3875,7 @@ void rx_reset_buffers(MGSLPC_INFO *info) | |||
3875 | * | 3875 | * |
3876 | * Returns 1 if frame returned, otherwise 0 | 3876 | * Returns 1 if frame returned, otherwise 0 |
3877 | */ | 3877 | */ |
3878 | int rx_get_frame(MGSLPC_INFO *info) | 3878 | static int rx_get_frame(MGSLPC_INFO *info) |
3879 | { | 3879 | { |
3880 | unsigned short status; | 3880 | unsigned short status; |
3881 | RXBUF *buf; | 3881 | RXBUF *buf; |
@@ -3961,7 +3961,7 @@ int rx_get_frame(MGSLPC_INFO *info) | |||
3961 | return 1; | 3961 | return 1; |
3962 | } | 3962 | } |
3963 | 3963 | ||
3964 | BOOLEAN register_test(MGSLPC_INFO *info) | 3964 | static BOOLEAN register_test(MGSLPC_INFO *info) |
3965 | { | 3965 | { |
3966 | static unsigned char patterns[] = | 3966 | static unsigned char patterns[] = |
3967 | { 0x00, 0xff, 0xaa, 0x55, 0x69, 0x96, 0x0f }; | 3967 | { 0x00, 0xff, 0xaa, 0x55, 0x69, 0x96, 0x0f }; |
@@ -3987,7 +3987,7 @@ BOOLEAN register_test(MGSLPC_INFO *info) | |||
3987 | return rc; | 3987 | return rc; |
3988 | } | 3988 | } |
3989 | 3989 | ||
3990 | BOOLEAN irq_test(MGSLPC_INFO *info) | 3990 | static BOOLEAN irq_test(MGSLPC_INFO *info) |
3991 | { | 3991 | { |
3992 | unsigned long end_time; | 3992 | unsigned long end_time; |
3993 | unsigned long flags; | 3993 | unsigned long flags; |
@@ -4022,7 +4022,7 @@ BOOLEAN irq_test(MGSLPC_INFO *info) | |||
4022 | return info->irq_occurred ? TRUE : FALSE; | 4022 | return info->irq_occurred ? TRUE : FALSE; |
4023 | } | 4023 | } |
4024 | 4024 | ||
4025 | int adapter_test(MGSLPC_INFO *info) | 4025 | static int adapter_test(MGSLPC_INFO *info) |
4026 | { | 4026 | { |
4027 | if (!register_test(info)) { | 4027 | if (!register_test(info)) { |
4028 | info->init_error = DiagStatus_AddressFailure; | 4028 | info->init_error = DiagStatus_AddressFailure; |
@@ -4044,7 +4044,7 @@ int adapter_test(MGSLPC_INFO *info) | |||
4044 | return 0; | 4044 | return 0; |
4045 | } | 4045 | } |
4046 | 4046 | ||
4047 | void trace_block(MGSLPC_INFO *info,const char* data, int count, int xmit) | 4047 | static void trace_block(MGSLPC_INFO *info,const char* data, int count, int xmit) |
4048 | { | 4048 | { |
4049 | int i; | 4049 | int i; |
4050 | int linecount; | 4050 | int linecount; |
@@ -4079,7 +4079,7 @@ void trace_block(MGSLPC_INFO *info,const char* data, int count, int xmit) | |||
4079 | /* HDLC frame time out | 4079 | /* HDLC frame time out |
4080 | * update stats and do tx completion processing | 4080 | * update stats and do tx completion processing |
4081 | */ | 4081 | */ |
4082 | void tx_timeout(unsigned long context) | 4082 | static void tx_timeout(unsigned long context) |
4083 | { | 4083 | { |
4084 | MGSLPC_INFO *info = (MGSLPC_INFO*)context; | 4084 | MGSLPC_INFO *info = (MGSLPC_INFO*)context; |
4085 | unsigned long flags; | 4085 | unsigned long flags; |