staging: fix ft1000 sparse warnings
Fix sparse warnings in staging/ft1000/: drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c:69:7: warning: obsolete struct initializer, use C99 syntax and make many functions & data static. Examples: drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c:65:23: warning: symbol 'fw_entry' was not declared. Should it be static? drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c:836:6: warning: symbol 'ft1000_send_cmd' was not declared. Should it be static? drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c:1014:6: warning: symbol 'ft1000_proc_drvmsg' was not declared. Should it be static? drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c:1788:5: warning: symbol 'ft1000_copy_down_pkt' was not declared. Should it be static? drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c:2096:6: warning: symbol 'stop_ft1000_card' was not declared. Should it be static? drivers/staging/ft1000/ft1000-pcmcia/ft1000_hw.c:2155:19: warning: symbol 'init_ft1000_card' was not declared. Should it be static? rivers/staging/ft1000/ft1000-pcmcia/ft1000_cs.c:172:5: warning: symbol 'ft1000_confcheck' was not declared. Should it be static? drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c:50:5: warning: symbol 'ft1000ReadProc' was not declared. Should it be static? drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c:194:6: warning: symbol 'ft1000InitProc' was not declared. Should it be static? drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c:207:6: warning: symbol 'ft1000CleanupProc' was not declared. Should it be static? Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
0118885849
commit
eb93ca4e83
|
@ -68,6 +68,16 @@ struct ft1000_info {
|
|||
char netdevname[IFNAMSIZ];
|
||||
};
|
||||
|
||||
struct pcmcia_device;
|
||||
struct net_device;
|
||||
extern struct net_device *init_ft1000_card(struct pcmcia_device *link,
|
||||
void *ft1000_reset);
|
||||
extern void stop_ft1000_card(struct net_device *dev);
|
||||
extern int card_download(struct net_device *dev, const u8 *pFileStart,
|
||||
size_t FileLength);
|
||||
extern void ft1000InitProc(struct net_device *dev);
|
||||
extern void ft1000CleanupProc(struct net_device *dev);
|
||||
|
||||
extern u16 ft1000_read_dpram(struct net_device *dev, int offset);
|
||||
extern void card_bootload(struct net_device *dev);
|
||||
extern u16 ft1000_read_dpram_mag_16(struct net_device *dev, int offset, int Index);
|
||||
|
|
|
@ -41,14 +41,12 @@ MODULE_LICENSE("GPL");
|
|||
|
||||
/*====================================================================*/
|
||||
|
||||
struct net_device *init_ft1000_card(struct pcmcia_device *link,
|
||||
void *ft1000_reset);
|
||||
void stop_ft1000_card(struct net_device *);
|
||||
|
||||
static int ft1000_config(struct pcmcia_device *link);
|
||||
static void ft1000_detach(struct pcmcia_device *link);
|
||||
static int ft1000_attach(struct pcmcia_device *link);
|
||||
|
||||
#include "ft1000.h"
|
||||
|
||||
/*====================================================================*/
|
||||
|
||||
static void ft1000_reset(struct pcmcia_device *link)
|
||||
|
@ -75,7 +73,7 @@ static void ft1000_detach(struct pcmcia_device *link)
|
|||
free_netdev(dev);
|
||||
}
|
||||
|
||||
int ft1000_confcheck(struct pcmcia_device *link, void *priv_data)
|
||||
static int ft1000_confcheck(struct pcmcia_device *link, void *priv_data)
|
||||
{
|
||||
return pcmcia_request_io(link);
|
||||
}
|
||||
|
|
|
@ -287,7 +287,8 @@ u16 hdr_checksum(struct pseudo_hdr *pHdr)
|
|||
return chksum;
|
||||
}
|
||||
|
||||
int card_download(struct net_device *dev, const u8 *pFileStart, u32 FileLength)
|
||||
int card_download(struct net_device *dev, const u8 *pFileStart,
|
||||
size_t FileLength)
|
||||
{
|
||||
struct ft1000_info *info = (struct ft1000_info *) netdev_priv(dev);
|
||||
int Status = SUCCESS;
|
||||
|
|
|
@ -56,16 +56,11 @@
|
|||
#include <linux/delay.h>
|
||||
#include "ft1000.h"
|
||||
|
||||
int card_download(struct net_device *dev, const u8 *pFileStart, u32 FileLength);
|
||||
|
||||
void ft1000InitProc(struct net_device *dev);
|
||||
void ft1000CleanupProc(struct net_device *dev);
|
||||
|
||||
const struct firmware *fw_entry;
|
||||
static const struct firmware *fw_entry;
|
||||
|
||||
static void ft1000_hbchk(u_long data);
|
||||
static struct timer_list poll_timer = {
|
||||
function:ft1000_hbchk
|
||||
.function = ft1000_hbchk
|
||||
};
|
||||
|
||||
static u16 cmdbuffer[1024];
|
||||
|
@ -788,7 +783,7 @@ static void ft1000_hbchk(u_long data)
|
|||
// Output:
|
||||
//
|
||||
//---------------------------------------------------------------------------
|
||||
void ft1000_send_cmd (struct net_device *dev, u16 *ptempbuffer, int size, u16 qtype)
|
||||
static void ft1000_send_cmd (struct net_device *dev, u16 *ptempbuffer, int size, u16 qtype)
|
||||
{
|
||||
struct ft1000_info *info = netdev_priv(dev);
|
||||
int i;
|
||||
|
@ -873,7 +868,8 @@ void ft1000_send_cmd (struct net_device *dev, u16 *ptempbuffer, int size, u16 qt
|
|||
// = 1 (successful)
|
||||
//
|
||||
//---------------------------------------------------------------------------
|
||||
bool ft1000_receive_cmd(struct net_device *dev, u16 * pbuffer, int maxsz, u16 *pnxtph)
|
||||
static bool ft1000_receive_cmd(struct net_device *dev, u16 *pbuffer,
|
||||
int maxsz, u16 *pnxtph)
|
||||
{
|
||||
struct ft1000_info *info = netdev_priv(dev);
|
||||
u16 size;
|
||||
|
@ -966,7 +962,7 @@ bool ft1000_receive_cmd(struct net_device *dev, u16 * pbuffer, int maxsz, u16 *p
|
|||
// none
|
||||
//
|
||||
//---------------------------------------------------------------------------
|
||||
void ft1000_proc_drvmsg(struct net_device *dev)
|
||||
static void ft1000_proc_drvmsg(struct net_device *dev)
|
||||
{
|
||||
struct ft1000_info *info = netdev_priv(dev);
|
||||
u16 msgtype;
|
||||
|
@ -1245,7 +1241,7 @@ void ft1000_proc_drvmsg(struct net_device *dev)
|
|||
// SUCCESS
|
||||
//
|
||||
//---------------------------------------------------------------------------
|
||||
int ft1000_parse_dpram_msg(struct net_device *dev)
|
||||
static int ft1000_parse_dpram_msg(struct net_device *dev)
|
||||
{
|
||||
struct ft1000_info *info = netdev_priv(dev);
|
||||
u16 doorbell;
|
||||
|
@ -1546,7 +1542,7 @@ static void ft1000_flush_fifo(struct net_device *dev, u16 DrvErrNum)
|
|||
// SUCCESS
|
||||
//
|
||||
//---------------------------------------------------------------------------
|
||||
int ft1000_copy_up_pkt(struct net_device *dev)
|
||||
static int ft1000_copy_up_pkt(struct net_device *dev)
|
||||
{
|
||||
u16 tempword;
|
||||
struct ft1000_info *info = netdev_priv(dev);
|
||||
|
@ -1734,7 +1730,7 @@ int ft1000_copy_up_pkt(struct net_device *dev)
|
|||
// SUCCESS
|
||||
//
|
||||
//---------------------------------------------------------------------------
|
||||
int ft1000_copy_down_pkt(struct net_device *dev, u16 * packet, u16 len)
|
||||
static int ft1000_copy_down_pkt(struct net_device *dev, u16 * packet, u16 len)
|
||||
{
|
||||
struct ft1000_info *info = netdev_priv(dev);
|
||||
union {
|
||||
|
@ -2102,7 +2098,7 @@ static const struct ethtool_ops ops = {
|
|||
};
|
||||
|
||||
struct net_device *init_ft1000_card(struct pcmcia_device *link,
|
||||
void *ft1000_reset)
|
||||
void *ft1000_reset)
|
||||
{
|
||||
struct ft1000_info *info;
|
||||
struct net_device *dev;
|
||||
|
|
|
@ -48,8 +48,8 @@
|
|||
} \
|
||||
len += snprintf(page+len, PAGE_SIZE - len, "%d\n", var[i])
|
||||
|
||||
int ft1000ReadProc(char *page, char **start, off_t off,
|
||||
int count, int *eof, void *data)
|
||||
static int ft1000ReadProc(char *page, char **start, off_t off,
|
||||
int count, int *eof, void *data)
|
||||
{
|
||||
struct net_device *dev;
|
||||
int len;
|
||||
|
|
Loading…
Reference in New Issue