From: David Schleef Date: Fri, 8 Nov 2002 22:00:38 +0000 (+0000) Subject: Fix bugs noticed by check_driver X-Git-Tag: r0_7_66~49 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=fff2949e0cad3600021e19eb99cc9cf6b3e09bf3;p=comedi.git Fix bugs noticed by check_driver --- diff --git a/comedi/drivers/ke_counter.c b/comedi/drivers/ke_counter.c index fabe7439..08825c36 100644 --- a/comedi/drivers/ke_counter.c +++ b/comedi/drivers/ke_counter.c @@ -92,9 +92,6 @@ static comedi_driver cnt_driver = module: THIS_MODULE, attach: cnt_attach, detach: cnt_detach, - num_names: cnt_board_nbr, - board_name: cnt_boards, - offset: sizeof(cnt_board_struct), }; COMEDI_INITCLEANUP(cnt_driver); @@ -192,11 +189,10 @@ found: /* read register base address [PCI_BASE_ADDRESS #0] */ io_base = pci_resource_start(pci_device, 0); - dev->iobase = io_base & PCI_BASE_ADDRESS_IO_MASK; - if (request_region(dev->iobase, 0x08, CNT_DRIVER_NAME) == NULL) - { + if (request_region(io_base & PCI_BASE_ADDRESS_IO_MASK, 0x08, CNT_DRIVER_NAME) == NULL) { return -EIO; } + dev->iobase = io_base & PCI_BASE_ADDRESS_IO_MASK; /* allocate the subdevice structures */ dev->n_subdevices = 1; diff --git a/comedi/drivers/ni_mio_cs.c b/comedi/drivers/ni_mio_cs.c index e20b5d7c..a3532da0 100644 --- a/comedi/drivers/ni_mio_cs.c +++ b/comedi/drivers/ni_mio_cs.c @@ -27,6 +27,7 @@ Author: ds Status: works Devices: [National Instruments] DAQCard-AI-16XE-50 (ni_mio_cs), DAQCard-AI-16E-4, DAQCard-6062E, DAQCard-6024E +Updated: Thu, 07 Nov 2002 21:09:40 -0800 See the notes in the ni_atmio.o driver. */ diff --git a/comedi/drivers/poc.c b/comedi/drivers/poc.c index f5d572e6..1bc52fa5 100644 --- a/comedi/drivers/poc.c +++ b/comedi/drivers/poc.c @@ -237,13 +237,13 @@ static int pcl734_insn_bits(comedi_device *dev,comedi_subdevice *s, s->state &= ~data[0]; s->state |= (data[0]&data[1]); if((data[0]>>0)&0xff) - outb(dev->iobase+0,(s->state>>0)&0xff); + outb((s->state>>0)&0xff, dev->iobase + 0); if((data[0]>>8)&0xff) - outb(dev->iobase+1,(s->state>>8)&0xff); + outb((s->state>>8)&0xff, dev->iobase + 1); if((data[0]>>16)&0xff) - outb(dev->iobase+2,(s->state>>16)&0xff); + outb((s->state>>16)&0xff, dev->iobase + 2); if((data[0]>>24)&0xff) - outb(dev->iobase+3,(s->state>>24)&0xff); + outb((s->state>>24)&0xff, dev->iobase + 3); } data[1] = s->state;