diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-09-22 19:54:53 (GMT) |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-09-22 20:01:40 (GMT) |
commit | ae19ffbadc1b2100285a5b5b3d0a4e0a11390904 (patch) | |
tree | 3c2086ab67398a019089a47ca3f362a4bc6db74f /drivers/staging/comedi/kcomedilib/kcomedilib_main.c | |
parent | 34e84f39a27d059a3e6ec6e8b94aafa702e6f220 (diff) | |
parent | 9173a8ef24a6b1b8031507b35b8ffe5f85a87692 (diff) | |
download | linux-fsl-qoriq-ae19ffbadc1b2100285a5b5b3d0a4e0a11390904.tar.xz |
Merge branch 'master' into for-linus
Diffstat (limited to 'drivers/staging/comedi/kcomedilib/kcomedilib_main.c')
-rw-r--r-- | drivers/staging/comedi/kcomedilib/kcomedilib_main.c | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/drivers/staging/comedi/kcomedilib/kcomedilib_main.c b/drivers/staging/comedi/kcomedilib/kcomedilib_main.c index b39ea7c..6552ef6 100644 --- a/drivers/staging/comedi/kcomedilib/kcomedilib_main.c +++ b/drivers/staging/comedi/kcomedilib/kcomedilib_main.c @@ -67,7 +67,7 @@ void *comedi_open(const char *filename) if (!try_module_get(dev->driver->module)) return NULL; - return (void *) dev; + return (void *)dev; } void *comedi_open_old(unsigned int minor) @@ -86,12 +86,12 @@ void *comedi_open_old(unsigned int minor) if (dev == NULL || !dev->attached) return NULL; - return (void *) dev; + return (void *)dev; } int comedi_close(void *d) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; module_put(dev->driver->module); @@ -115,7 +115,7 @@ char *comedi_strerror(int err) int comedi_fileno(void *d) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; /* return something random */ return dev->minor; @@ -123,7 +123,7 @@ int comedi_fileno(void *d) int comedi_command(void *d, struct comedi_cmd *cmd) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; struct comedi_async *async; unsigned runflags; @@ -159,7 +159,7 @@ int comedi_command(void *d, struct comedi_cmd *cmd) int comedi_command_test(void *d, struct comedi_cmd *cmd) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; if (cmd->subdev >= dev->n_subdevices) @@ -181,7 +181,7 @@ int comedi_command_test(void *d, struct comedi_cmd *cmd) */ int comedi_do_insn(void *d, struct comedi_insn *insn) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; int ret = 0; @@ -214,7 +214,7 @@ int comedi_do_insn(void *d, struct comedi_insn *insn) } if (insn->subdev >= dev->n_subdevices) { printk("%d not usable subdevice\n", - insn->subdev); + insn->subdev); ret = -EINVAL; break; } @@ -296,7 +296,7 @@ int comedi_do_insn(void *d, struct comedi_insn *insn) goto error; } #endif - error: +error: return ret; } @@ -322,7 +322,7 @@ int comedi_do_insn(void *d, struct comedi_insn *insn) */ int comedi_lock(void *d, unsigned int subdevice) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; unsigned long flags; int ret = 0; @@ -365,7 +365,7 @@ int comedi_lock(void *d, unsigned int subdevice) */ int comedi_unlock(void *d, unsigned int subdevice) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; unsigned long flags; struct comedi_async *async; @@ -417,7 +417,7 @@ int comedi_unlock(void *d, unsigned int subdevice) */ int comedi_cancel(void *d, unsigned int subdevice) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; int ret = 0; @@ -456,9 +456,10 @@ int comedi_cancel(void *d, unsigned int subdevice) registration of callback functions */ int comedi_register_callback(void *d, unsigned int subdevice, - unsigned int mask, int (*cb) (unsigned int, void *), void *arg) + unsigned int mask, int (*cb) (unsigned int, + void *), void *arg) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; struct comedi_async *async; @@ -494,7 +495,7 @@ int comedi_register_callback(void *d, unsigned int subdevice, int comedi_poll(void *d, unsigned int subdevice) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s = dev->subdevices; struct comedi_async *async; @@ -521,7 +522,7 @@ int comedi_poll(void *d, unsigned int subdevice) /* WARNING: not portable */ int comedi_map(void *d, unsigned int subdevice, void *ptr) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; if (subdevice >= dev->n_subdevices) @@ -543,7 +544,7 @@ int comedi_map(void *d, unsigned int subdevice, void *ptr) /* WARNING: not portable */ int comedi_unmap(void *d, unsigned int subdevice) { - struct comedi_device *dev = (struct comedi_device *) d; + struct comedi_device *dev = (struct comedi_device *)d; struct comedi_subdevice *s; if (subdevice >= dev->n_subdevices) |