staging: comedi: addi_apci_3501: remove i_APCI3501_ConfigDigitalOutput()
authorH Hartley Sweeten <hartleys@visionengravers.com>
Tue, 6 Nov 2012 16:56:55 +0000 (09:56 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 13 Nov 2012 19:21:36 +0000 (11:21 -0800)
This function is the digital output subdevice 'insn_config' operation.
It does not follow the comedi API and the digital output channels on
this board are not configurable. Just remove this broken function.

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>
drivers/staging/comedi/drivers/addi-data/hwdrv_apci3501.c
drivers/staging/comedi/drivers/addi_apci_3501.c

index c92ec8fc932f4bf8cedad3d9ece4bb7543c0fd38..0f03c6e9ffb222618c08b7e00e9f066e36e921e4 100644 (file)
@@ -131,52 +131,6 @@ static int i_APCI3501_ReadDigitalInput(struct comedi_device *dev,
        return insn->n;
 }
 
-/*
-+----------------------------------------------------------------------------+
-| Function   Name   : int i_APCI3501_ConfigDigitalOutput                     |
-|                        (struct comedi_device *dev,struct comedi_subdevice *s,               |
-|                      struct comedi_insn *insn,unsigned int *data)                     |
-+----------------------------------------------------------------------------+
-| Task              : Configures The Digital Output Subdevice.               |
-+----------------------------------------------------------------------------+
-| Input Parameters  : struct comedi_device *dev : Driver handle                     |
-|                     unsigned int *data         : Data Pointer contains             |
-|                                          configuration parameters as below |
-|                                                                            |
-|                                        data[1]            : 1 Enable  VCC  Interrupt  |
-|                                                                                 0 Disable VCC  Interrupt  |
-|                                        data[2]            : 1 Enable  CC  Interrupt   |
-|                                                                                 0 Disable CC  Interrupt   |
-|                                                                                                                                       |
-+----------------------------------------------------------------------------+
-| Output Parameters :  --                                                                                                       |
-+----------------------------------------------------------------------------+
-| Return Value      : TRUE  : No error occur                                 |
-|                          : FALSE : Error occur. Return the error          |
-|                                                                               |
-+----------------------------------------------------------------------------+
-*/
-static int i_APCI3501_ConfigDigitalOutput(struct comedi_device *dev,
-                                         struct comedi_subdevice *s,
-                                         struct comedi_insn *insn,
-                                         unsigned int *data)
-{
-       struct addi_private *devpriv = dev->private;
-
-       if ((data[0] != 0) && (data[0] != 1)) {
-               comedi_error(dev,
-                       "Not a valid Data !!! ,Data should be 1 or 0\n");
-               return -EINVAL;
-       }                       /* if  ( (data[0]!=0) && (data[0]!=1) ) */
-       if (data[0]) {
-               devpriv->b_OutputMemoryStatus = ADDIDATA_ENABLE;
-       }                       /*  if  (data[0]) */
-       else {
-               devpriv->b_OutputMemoryStatus = ADDIDATA_DISABLE;
-       }                       /* else if  (data[0]) */
-       return insn->n;
-}
-
 /*
 +----------------------------------------------------------------------------+
 | Function   Name   : int i_APCI3501_WriteDigitalOutput                      |
index 14ee4e0c5a98c13b04d981233fc86bcf05cb85a2..c86f31e585988b570e225b86428408ecc8f04b1b 100644 (file)
@@ -28,7 +28,6 @@ static const struct addi_board apci3501_boardtypes[] = {
                .ao_config              = i_APCI3501_ConfigAnalogOutput,
                .ao_write               = i_APCI3501_WriteAnalogOutput,
                .di_bits                = i_APCI3501_ReadDigitalInput,
-               .do_config              = i_APCI3501_ConfigDigitalOutput,
                .do_write               = i_APCI3501_WriteDigitalOutput,
                .do_bits                = i_APCI3501_ReadDigitalOutput,
                .timer_config           = i_APCI3501_ConfigTimerCounterWatchdog,