#include <linux/module.h>
#include "../comedidev.h"
-#define AIO_IIRO_16_SIZE 0x08
#define AIO_IIRO_16_RELAY_0_7 0x00
#define AIO_IIRO_16_INPUT_0_7 0x01
#define AIO_IIRO_16_IRQ 0x02
struct comedi_subdevice *s;
int ret;
- ret = comedi_request_region(dev, it->options[0], AIO_IIRO_16_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x8);
if (ret)
return ret;
/* PC36AT / PCI236 registers */
-#define PC236_IO_SIZE 4
-#define PC236_LCR_IO_SIZE 128
-
/* Disable, and clear, interrupts */
#define PCI236_INTR_DISABLE (PLX9052_INTCSR_LI1POL | \
PLX9052_INTCSR_LI2POL | \
/* Process options according to bus type. */
if (is_isa_board(thisboard)) {
- ret = comedi_request_region(dev, it->options[0], PC236_IO_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x4);
if (ret)
return ret;
#define PC263_DRIVER_NAME "amplc_pc263"
/* PC263 registers */
-#define PC263_IO_SIZE 2
/*
* Board descriptions for Amplicon PC263.
struct comedi_subdevice *s;
int ret;
- ret = comedi_request_region(dev, it->options[0], PC263_IO_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x2);
if (ret)
return ret;
/*
* PCI224/234 i/o space 1 (PCIBAR2) registers.
*/
-#define PCI224_IO1_SIZE 0x20 /* Size of i/o space 1 (8-bit registers) */
#define PCI224_Z2_CT0 0x14 /* 82C54 counter/timer 0 */
#define PCI224_Z2_CT1 0x15 /* 82C54 counter/timer 1 */
#define PCI224_Z2_CT2 0x16 /* 82C54 counter/timer 2 */
/*
* PCI224/234 i/o space 2 (PCIBAR3) 16-bit registers.
*/
-#define PCI224_IO2_SIZE 0x10 /* Size of i/o space 2 (16-bit registers). */
#define PCI224_DACDATA 0x00 /* (w-o) DAC FIFO data. */
#define PCI224_SOFTTRIG 0x00 /* (r-o) DAC software scan trigger. */
#define PCI224_DACCON 0x02 /* (r/w) DAC status/configuration. */
#define PCI_DEVICE_ID_PCI260 0x0006
#define PCI_DEVICE_ID_INVALID 0xffff
-#define PCI230_IO1_SIZE 32 /* Size of I/O space 1 */
-#define PCI230_IO2_SIZE 16 /* Size of I/O space 2 */
-
/* PCI230 i/o space 1 registers. */
#define PCI230_PPI_X_BASE 0x00 /* User PPI (82C55) base */
#define PCI230_PPI_X_A 0x00 /* User PPI (82C55) port A */
#include "comedi_fc.h"
#include "8253.h"
-#define DAS16CS_SIZE 18
-
#define DAS16CS_ADC_DATA 0
#define DAS16CS_DIO_MUX 2
#define DAS16CS_MISC1 4
/* Registers for the PCIM-DAS1602/16 */
-/* sizes of io regions (bytes) */
-#define BADR3_SIZE 16
-
/* DAC Offsets */
#define ADC_TRIG 0
#define DAC0_OFFSET 2
#include "8253.h"
#include "comedi_fc.h"
-#define DAS16M1_SIZE 16
#define DAS16M1_SIZE2 8
#define FIFO_SIZE 1024 /* 1024 sample fifo */
if (!devpriv)
return -ENOMEM;
- ret = comedi_request_region(dev, it->options[0], DAS16M1_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x10);
if (ret)
return ret;
/* Request an additional region for the 8255 */
#include "8253.h"
#include "comedi_fc.h"
-#define DAS800_SIZE 8
#define N_CHAN_AI 8 /* number of analog input channels */
/* Registers for the das800 */
if (!devpriv)
return -ENOMEM;
- ret = comedi_request_region(dev, it->options[0], DAS800_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x8);
if (ret)
return ret;
#define TIMEOUT 10000
-#define DT2811_SIZE 8
-
#define DT2811_ADCSR 0
#define DT2811_ADGCR 1
#define DT2811_ADDATLO 2
int ret;
struct comedi_subdevice *s;
- ret = comedi_request_region(dev, it->options[0], DT2811_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x8);
if (ret)
return ret;
#include "comedi_fc.h"
-#define DT2814_SIZE 2
-
#define DT2814_CSR 0
#define DT2814_DATA 1
int ret;
int i;
- ret = comedi_request_region(dev, it->options[0], DT2814_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x2);
if (ret)
return ret;
#include <linux/delay.h>
-#define DT2815_SIZE 2
-
#define DT2815_DATA 0
#define DT2815_STATUS 1
const struct comedi_lrange *current_range_type, *voltage_range_type;
int ret;
- ret = comedi_request_region(dev, it->options[0], DT2815_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x2);
if (ret)
return ret;
#include <linux/module.h>
#include "../comedidev.h"
-#define DT2817_SIZE 5
-
#define DT2817_CR 0
#define DT2817_DATA 1
int ret;
struct comedi_subdevice *s;
- ret = comedi_request_region(dev, it->options[0], DT2817_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x5);
if (ret)
return ret;
#include <linux/delay.h>
-/* Consecutive I/O port addresses */
-#define MPC624_SIZE 16
-
/* Offsets of different ports */
#define MPC624_MASTER_CONTROL 0 /* not used */
#define MPC624_GNMUXCH 1 /* Gain, Mux, Channel of ADC */
struct comedi_subdevice *s;
int ret;
- ret = comedi_request_region(dev, it->options[0], MPC624_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x10);
if (ret)
return ret;
#include <linux/interrupt.h>
#include "../comedidev.h"
-#define MULTIQ3_SIZE 16
-
/*
* MULTIQ-3 port offsets
*/
struct comedi_subdevice *s;
int ret;
- ret = comedi_request_region(dev, it->options[0], MULTIQ3_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x10);
if (ret)
return ret;
#include "8253.h"
#include "comedi_fc.h"
-#define A2150_SIZE 28
#define A2150_DMA_BUFFER_SIZE 0xff00 /* size in bytes of dma buffer */
/* Registers and bits */
if (!devpriv)
return -ENOMEM;
- ret = comedi_request_region(dev, it->options[0], A2150_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x1c);
if (ret)
return ret;
#define CLOCK_10_KHZ 0x8D25
#define CLOCK_1_KHZ 0x8E25
#define CLOCK_100_HZ 0x8F25
-/* Other miscellaneous defines */
-#define ATMIO16D_SIZE 32 /* bus address range */
struct atmio16_board_t {
struct comedi_subdevice *s;
int ret;
- ret = comedi_request_region(dev, it->options[0], ATMIO16D_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x20);
if (ret)
return ret;
#include "ni_labpc_regs.h"
#include "ni_labpc_isadma.h"
-#define LABPC_SIZE 0x20 /* size of ISA io region */
-
enum scan_mode {
MODE_SINGLE_CHAN,
MODE_SINGLE_CHAN_INTERVAL,
if (!devpriv)
return -ENOMEM;
- ret = comedi_request_region(dev, it->options[0], LABPC_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x20);
if (ret)
return ret;
#include "comedi_fc.h"
#include "mite.h"
-#define PCI_DIO_SIZE 4096
-#define PCI_MITE_SIZE 4096
-
/* defines for the PCI-DIO-32HS */
#define Window_Address 4 /* W */
#include "8255.h"
-#define PCM3724_SIZE 16
#define SIZE_8255 4
#define BUF_C0 0x1
if (!priv)
return -ENOMEM;
- ret = comedi_request_region(dev, it->options[0], PCM3724_SIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x10);
if (ret)
return ret;
#include "../comedidev.h"
#include <asm/byteorder.h>
-#define S526_SIZE 64
-
#define S526_START_AI_CONV 0
#define S526_AI_READ 0
/* Ports */
-#define S526_IOSIZE 0x40
#define S526_NUM_PORTS 27
/* registers */
struct comedi_subdevice *s;
int ret;
- ret = comedi_request_region(dev, it->options[0], S526_IOSIZE);
+ ret = comedi_request_region(dev, it->options[0], 0x40);
if (ret)
return ret;
#include "comedi_fc.h"
/* Imaginary registers for the imaginary board */
-
-#define SKEL_SIZE 0
-
#define SKEL_START_AI_CONV 0
#define SKEL_AI_READ 0