summaryrefslogtreecommitdiff
path: root/drivers/dahdi/wcb4xxp
diff options
context:
space:
mode:
authorKevin P. Fleming <kpfleming@digium.com>2008-10-28 21:49:02 +0000
committerKevin P. Fleming <kpfleming@digium.com>2008-10-28 21:49:02 +0000
commitcb2fd65e3da7a68ef11d458e9ca99463f90b32a0 (patch)
tree8acd0b016433ced01fd64876a031381c822c30aa /drivers/dahdi/wcb4xxp
parent8b0e06e5f588d24af0666b1d605084a83c7c8c25 (diff)
fix a large number of warnings found by sparse, the kernel code sanity checking tool. some of these fixes are non-optimal (casting 'unsigned long' to '__user void *'), but are unavoidable in many cases. started from tzafrir's patch, did most of the work myself.
(closes issue #13763) Reported by: tzafrir Patches: sparse_fixes_1.diff uploaded by tzafrir (license 46) git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@5162 a0bf4364-ded3-4de4-8d8a-66a801d63aff
Diffstat (limited to 'drivers/dahdi/wcb4xxp')
-rw-r--r--drivers/dahdi/wcb4xxp/base.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/drivers/dahdi/wcb4xxp/base.c b/drivers/dahdi/wcb4xxp/base.c
index ff213cf..5eb6a6c 100644
--- a/drivers/dahdi/wcb4xxp/base.c
+++ b/drivers/dahdi/wcb4xxp/base.c
@@ -109,9 +109,10 @@ struct devtype {
static struct devtype wcb4xxp = { "Wildcard B410P", 0 };
-const char *wcb4xxp_rcsdata = "$RCSfile: base.c,v $ $Revision$";
-const char *build_stamp = "" __DATE__ " " __TIME__ "";
-
+#if 0
+static const char *wcb4xxp_rcsdata = "$RCSfile: base.c,v $ $Revision$";
+static const char *build_stamp = "" __DATE__ " " __TIME__ "";
+#endif
/*
* lowlevel PCI access functions
@@ -1582,7 +1583,8 @@ static int hdlc_rx_frame(struct b4xxp_span *bspan)
static int hdlc_tx_frame(struct b4xxp_span *bspan)
{
struct b4xxp *b4 = bspan->parent;
- int res, i, fifo, size=32;
+ int res, i, fifo;
+ unsigned int size = 32;
int z1, z2, zlen;
unsigned char buf[32];
unsigned long irq_flags;
@@ -2286,7 +2288,7 @@ static void b4xxp_bottom_half(unsigned long data)
/********************************************************************************* proc stuff *****/
-int b4xxp_proc_read_one(char *buf, struct b4xxp *b4)
+static int b4xxp_proc_read_one(char *buf, struct b4xxp *b4)
{
struct dahdi_chan *chan;
int len, i, j;
@@ -2332,7 +2334,7 @@ int b4xxp_proc_read_one(char *buf, struct b4xxp *b4)
return len;
}
-int b4xxp_proc_read(char *buf, char **start, off_t offset, int count, int *eof, void *data)
+static int b4xxp_proc_read(char *buf, char **start, off_t offset, int count, int *eof, void *data)
{
struct b4xxp **b4_cards = data;
char sBuf[256];
@@ -2601,12 +2603,10 @@ static struct pci_device_id b4xx_ids[] __devinitdata =
};
static struct pci_driver b4xx_driver = {
- name: "wcb4xxp",
- probe: b4xx_probe,
- remove: __devexit_p(b4xxp_remove),
- suspend: NULL,
- resume: NULL,
- id_table: b4xx_ids,
+ .name = "wcb4xxp",
+ .probe = b4xx_probe,
+ .remove = __devexit_p(b4xxp_remove),
+ .id_table = b4xx_ids,
};
static int __init b4xx_init(void)