diff options
author | H Hartley Sweeten <hsweeten@visionengravers.com> | 2013-01-30 23:44:47 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-02-04 01:27:37 (GMT) |
commit | 25602bd7350dc180128376db9772277818f041f2 (patch) | |
tree | 6680f86263a007a39ea79ee3aa318ed27391cb56 | |
parent | 112215012f42e2db1f7e2965e25936c4809e89b1 (diff) | |
download | linux-25602bd7350dc180128376db9772277818f041f2.tar.xz |
staging: comedi: ni_daq_dio24: move comedi_driver declaration
Move the comedi_driver declaration down in the file. This removes
the need for the forward declarations.
For aesthetic reasons, add some whitespace to the declaration.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/comedi/drivers/ni_daq_dio24.c | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/drivers/staging/comedi/drivers/ni_daq_dio24.c b/drivers/staging/comedi/drivers/ni_daq_dio24.c index 826bea9..acfef6e 100644 --- a/drivers/staging/comedi/drivers/ni_daq_dio24.c +++ b/drivers/staging/comedi/drivers/ni_daq_dio24.c @@ -56,9 +56,6 @@ static struct pcmcia_device *pcmcia_cur_dev; #define DIO24_SIZE 4 /* size of io region used by board */ -static int dio24_attach(struct comedi_device *dev, struct comedi_devconfig *it); -static void dio24_detach(struct comedi_device *dev); - enum dio24_bustype { pcmcia_bustype }; struct dio24_board_struct { @@ -96,16 +93,6 @@ struct dio24_private { int data; /* number of data points left to be taken */ }; -static struct comedi_driver driver_dio24 = { - .driver_name = "ni_daq_dio24", - .module = THIS_MODULE, - .attach = dio24_attach, - .detach = dio24_detach, - .num_names = ARRAY_SIZE(dio24_boards), - .board_name = &dio24_boards[0].name, - .offset = sizeof(struct dio24_board_struct), -}; - static int dio24_attach(struct comedi_device *dev, struct comedi_devconfig *it) { struct dio24_private *devpriv; @@ -184,6 +171,16 @@ static void dio24_detach(struct comedi_device *dev) free_irq(dev->irq, dev); }; +static struct comedi_driver driver_dio24 = { + .driver_name = "ni_daq_dio24", + .module = THIS_MODULE, + .attach = dio24_attach, + .detach = dio24_detach, + .num_names = ARRAY_SIZE(dio24_boards), + .board_name = &dio24_boards[0].name, + .offset = sizeof(struct dio24_board_struct), +}; + static int dio24_pcmcia_config_loop(struct pcmcia_device *p_dev, void *priv_data) { |