Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 325254
b: refs/heads/master
c: df1a3f8
h: refs/heads/master
v: v3
  • Loading branch information
H Hartley Sweeten authored and Greg Kroah-Hartman committed Sep 14, 2012
1 parent 63be149 commit 80a8f0e
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 202 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f7c22868267da71c65fd09556fc07d62058ff8e6
refs/heads/master: df1a3f87967a2eaadf22936b30c05a7427d78db8
11 changes: 1 addition & 10 deletions trunk/drivers/staging/comedi/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -558,6 +558,7 @@ config COMEDI_8255_PCI

Supported boards:
ADlink - PCI-7224, PCI-7248, and PCI-7296
Measurement Computing - PCI-DIO24, PCI-DIO24H and PCI-DIO48H

To compile this driver as a module, choose M here: the module will
be called 8255_pci.
Expand Down Expand Up @@ -934,16 +935,6 @@ config COMEDI_CB_PCIDDA
To compile this driver as a module, choose M here: the module will be
called cb_pcidda.

config COMEDI_CB_PCIDIO
tristate "MeasurementComputing PCI-DIO series support"
select COMEDI_8255
---help---
Enable support for ComputerBoards/MeasurementComputing PCI-DIO series
PCI-DIO24, PCI-DIO24H and PCI-DIO48H

To compile this driver as a module, choose M here: the module will be
called cb_pcidio.

config COMEDI_CB_PCIMDAS
tristate "MeasurementComputing PCIM-DAS1602/16 support"
select COMEDI_8255
Expand Down
36 changes: 35 additions & 1 deletion trunk/drivers/staging/comedi/drivers/8255_pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
*
* Based on the tested adl_pci7296 driver written by:
* Jon Grierson <jd@renko.co.uk>
* and the experimental cb_pcidio driver written by:
* Yoshiya Matsuzaka
*
* COMEDI - Linux Control and Measurement Device Interface
* Copyright (C) 2000 David A. Schleef <ds@schleef.org>
Expand All @@ -29,6 +31,9 @@ Description: Generic PCI based 8255 Digital I/O boards
Devices: (ADLink) PCI-7224 [adl_pci-7224] - 24 channels
(ADLink) PCI-7248 [adl_pci-7248] - 48 channels
(ADLink) PCI-7296 [adl_pci-7296] - 96 channels
(Measurement Computing) PCI-DIO24 [cb_pci-dio24] - 24 channels
(Measurement Computing) PCI-DIO24H [cb_pci-dio24h] - 24 channels
(Measurement Computing) PCI-DIO48H [cb_pci-dio48h] - 48 channels
Author: H Hartley Sweeten <hsweeten@visionengravers.com>
Updated: Wed, 12 Sep 2012 11:52:01 -0700
Status: untested
Expand All @@ -52,25 +57,51 @@ Configuration Options: not applicable, uses PCI auto config
#define PCI_DEVICE_ID_ADLINK_PCI7248 0x7248
#define PCI_DEVICE_ID_ADLINK_PCI7296 0x7296

/* ComputerBoards is now known as Measurement Computing */
#define PCI_VENDOR_ID_CB 0x1307

#define PCI_DEVICE_ID_CB_PCIDIO48H 0x000b
#define PCI_DEVICE_ID_CB_PCIDIO24H 0x0014
#define PCI_DEVICE_ID_CB_PCIDIO24 0x0028

struct pci_8255_boardinfo {
const char *name;
unsigned short device;
int dio_badr;
int n_8255;
};

static const struct pci_8255_boardinfo pci_8255_boards[] = {
{
.name = "adl_pci-7224",
.device = PCI_DEVICE_ID_ADLINK_PCI7224,
.dio_badr = 2,
.n_8255 = 1,
}, {
.name = "adl_pci-7248",
.device = PCI_DEVICE_ID_ADLINK_PCI7248,
.dio_badr = 2,
.n_8255 = 2,
}, {
.name = "adl_pci-7296",
.device = PCI_DEVICE_ID_ADLINK_PCI7296,
.dio_badr = 2,
.n_8255 = 4,
}, {
.name = "cb_pci-dio24",
.device = PCI_DEVICE_ID_CB_PCIDIO24,
.dio_badr = 2,
.n_8255 = 1,
}, {
.name = "cb_pci-dio24h",
.device = PCI_DEVICE_ID_CB_PCIDIO24H,
.dio_badr = 2,
.n_8255 = 1,
}, {
.name = "cb_pci-dio48h",
.device = PCI_DEVICE_ID_CB_PCIDIO48H,
.dio_badr = 1,
.n_8255 = 2,
},
};

Expand Down Expand Up @@ -107,7 +138,7 @@ static int pci_8255_attach_pci(struct comedi_device *dev,
ret = comedi_pci_enable(pcidev, dev->board_name);
if (ret)
return ret;
dev->iobase = pci_resource_start(pcidev, 2);
dev->iobase = pci_resource_start(pcidev, board->dio_badr);

/*
* One, two, or four subdevices are setup by this driver depending
Expand Down Expand Up @@ -172,6 +203,9 @@ static DEFINE_PCI_DEVICE_TABLE(pci_8255_pci_table) = {
{ PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_ADLINK_PCI7224) },
{ PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_ADLINK_PCI7248) },
{ PCI_DEVICE(PCI_VENDOR_ID_ADLINK, PCI_DEVICE_ID_ADLINK_PCI7296) },
{ PCI_DEVICE(PCI_VENDOR_ID_CB, PCI_DEVICE_ID_CB_PCIDIO24) },
{ PCI_DEVICE(PCI_VENDOR_ID_CB, PCI_DEVICE_ID_CB_PCIDIO24H) },
{ PCI_DEVICE(PCI_VENDOR_ID_CB, PCI_DEVICE_ID_CB_PCIDIO48H) },
{ 0 }
};
MODULE_DEVICE_TABLE(pci, pci_8255_pci_table);
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/staging/comedi/drivers/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ obj-$(CONFIG_COMEDI_KE_COUNTER) += ke_counter.o
obj-$(CONFIG_COMEDI_CB_PCIDAS64) += cb_pcidas64.o
obj-$(CONFIG_COMEDI_CB_PCIDAS) += cb_pcidas.o
obj-$(CONFIG_COMEDI_CB_PCIDDA) += cb_pcidda.o
obj-$(CONFIG_COMEDI_CB_PCIDIO) += cb_pcidio.o
obj-$(CONFIG_COMEDI_CB_PCIMDAS) += cb_pcimdas.o
obj-$(CONFIG_COMEDI_CB_PCIMDDA) += cb_pcimdda.o
obj-$(CONFIG_COMEDI_ME4000) += me4000.o
Expand Down
189 changes: 0 additions & 189 deletions trunk/drivers/staging/comedi/drivers/cb_pcidio.c

This file was deleted.

0 comments on commit 80a8f0e

Please sign in to comment.