Skip to content

Commit

Permalink
Staging: comedi: fix sparse issues in comedi_bond.c
Browse files Browse the repository at this point in the history
This fixes the issues raised by the sparse tool on the
comedi_bond.c file.

Cc: Calin A. Culianu <calin@ajvar.org>
Cc: David Schleef <ds@schleef.org>
Cc: Frank Mori Hess <fmhess@users.sourceforge.net>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Greg Kroah-Hartman committed Jan 6, 2009
1 parent ff53476 commit 246c541
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions drivers/staging/comedi/drivers/comedi_bond.c
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ MODULE_LICENSE("GPL");
# define STR(x) STR1(x)
#endif

int debug;
static int debug;
module_param(debug, int, 0644);
MODULE_PARM_DESC(debug, "If true, print extra cryptic debugging output useful"
"only to developers.");
Expand Down Expand Up @@ -408,7 +408,7 @@ static int doDevConfig(comedi_device *dev, comedi_devconfig *it)
int minor = it->options[i];
comedi_t *d;
int sdev = -1, nchans, tmp;
struct BondedDevice *bdev = 0;
struct BondedDevice *bdev = NULL;

if (minor < 0 || minor > COMEDI_NUM_BOARD_MINORS) {
ERROR("Minor %d is invalid!\n", minor);
Expand Down Expand Up @@ -515,18 +515,18 @@ static void doDevUnconfig(comedi_device *dev)
kfree(bdev);
}
kfree(devpriv->devs);
devpriv->devs = 0;
devpriv->devs = NULL;
kfree(devpriv);
dev->private = 0;
dev->private = NULL;
}
}

int __init init(void)
static int __init init(void)
{
return comedi_driver_register(&driver_bonding);
}

void __exit cleanup(void)
static void __exit cleanup(void)
{
comedi_driver_unregister(&driver_bonding);
}
Expand Down

0 comments on commit 246c541

Please sign in to comment.