Commit 9ad00740 authored by Bill Pemberton's avatar Bill Pemberton Committed by Greg Kroah-Hartman

Staging: comedi: Remove labpc_board_struct typedef

Signed-off-by: default avatarBill Pemberton <wfp5p@virginia.edu>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 70275063
...@@ -360,7 +360,7 @@ static inline void labpc_writeb(unsigned int byte, unsigned long address) ...@@ -360,7 +360,7 @@ static inline void labpc_writeb(unsigned int byte, unsigned long address)
writeb(byte, (void *)address); writeb(byte, (void *)address);
} }
static const labpc_board labpc_boards[] = { static const struct labpc_board_struct labpc_boards[] = {
{ {
name: "lab-pc-1200", name: "lab-pc-1200",
ai_speed:10000, ai_speed:10000,
...@@ -422,7 +422,7 @@ static const labpc_board labpc_boards[] = { ...@@ -422,7 +422,7 @@ static const labpc_board labpc_boards[] = {
/* /*
* Useful for shorthand access to the particular board structure * Useful for shorthand access to the particular board structure
*/ */
#define thisboard ((labpc_board *)dev->board_ptr) #define thisboard ((struct labpc_board_struct *)dev->board_ptr)
static const int dma_buffer_size = 0xff00; // size in bytes of dma buffer static const int dma_buffer_size = 0xff00; // size in bytes of dma buffer
static const int sample_size = 2; // 2 bytes per sample static const int sample_size = 2; // 2 bytes per sample
...@@ -434,9 +434,9 @@ static struct comedi_driver driver_labpc = { ...@@ -434,9 +434,9 @@ static struct comedi_driver driver_labpc = {
.module = THIS_MODULE, .module = THIS_MODULE,
.attach = labpc_attach, .attach = labpc_attach,
.detach = labpc_common_detach, .detach = labpc_common_detach,
.num_names = sizeof(labpc_boards) / sizeof(labpc_board), .num_names = sizeof(labpc_boards) / sizeof(struct labpc_board_struct),
.board_name = &labpc_boards[0].name, .board_name = &labpc_boards[0].name,
.offset = sizeof(labpc_board), .offset = sizeof(struct labpc_board_struct),
}; };
#ifdef CONFIG_COMEDI_PCI #ifdef CONFIG_COMEDI_PCI
......
...@@ -32,7 +32,7 @@ enum labpc_register_layout { labpc_plus_layout, labpc_1200_layout }; ...@@ -32,7 +32,7 @@ enum labpc_register_layout { labpc_plus_layout, labpc_1200_layout };
enum transfer_type { fifo_not_empty_transfer, fifo_half_full_transfer, enum transfer_type { fifo_not_empty_transfer, fifo_half_full_transfer,
isa_dma_transfer }; isa_dma_transfer };
typedef struct labpc_board_struct { struct labpc_board_struct {
const char *name; const char *name;
int device_id; // device id for pci and pcmcia boards int device_id; // device id for pci and pcmcia boards
int ai_speed; // maximum input speed in nanoseconds int ai_speed; // maximum input speed in nanoseconds
...@@ -44,7 +44,7 @@ typedef struct labpc_board_struct { ...@@ -44,7 +44,7 @@ typedef struct labpc_board_struct {
const int *ai_range_is_unipolar; const int *ai_range_is_unipolar;
unsigned ai_scan_up:1; // board can auto scan up in ai channels, not just down unsigned ai_scan_up:1; // board can auto scan up in ai channels, not just down
unsigned memory_mapped_io:1; /* uses memory mapped io instead of ioports */ unsigned memory_mapped_io:1; /* uses memory mapped io instead of ioports */
} labpc_board; };
typedef struct { typedef struct {
struct mite_struct *mite; // for mite chip on pci-1200 struct mite_struct *mite; // for mite chip on pci-1200
......
...@@ -81,7 +81,7 @@ static struct pcmcia_device *pcmcia_cur_dev = NULL; ...@@ -81,7 +81,7 @@ static struct pcmcia_device *pcmcia_cur_dev = NULL;
static int labpc_attach(struct comedi_device * dev, struct comedi_devconfig * it); static int labpc_attach(struct comedi_device * dev, struct comedi_devconfig * it);
static const labpc_board labpc_cs_boards[] = { static const struct labpc_board_struct labpc_cs_boards[] = {
{ {
name: "daqcard-1200", name: "daqcard-1200",
device_id:0x103, // 0x10b is manufacturer id, 0x103 is device id device_id:0x103, // 0x10b is manufacturer id, 0x103 is device id
...@@ -114,16 +114,16 @@ static const labpc_board labpc_cs_boards[] = { ...@@ -114,16 +114,16 @@ static const labpc_board labpc_cs_boards[] = {
/* /*
* Useful for shorthand access to the particular board structure * Useful for shorthand access to the particular board structure
*/ */
#define thisboard ((const labpc_board *)dev->board_ptr) #define thisboard ((const struct labpc_board_struct *)dev->board_ptr)
static struct comedi_driver driver_labpc_cs = { static struct comedi_driver driver_labpc_cs = {
.driver_name = "ni_labpc_cs", .driver_name = "ni_labpc_cs",
.module = THIS_MODULE, .module = THIS_MODULE,
.attach = &labpc_attach, .attach = &labpc_attach,
.detach = &labpc_common_detach, .detach = &labpc_common_detach,
.num_names = sizeof(labpc_cs_boards) / sizeof(labpc_board), .num_names = sizeof(labpc_cs_boards) / sizeof(struct labpc_board_struct),
.board_name = &labpc_cs_boards[0].name, .board_name = &labpc_cs_boards[0].name,
.offset = sizeof(labpc_board), .offset = sizeof(struct labpc_board_struct),
}; };
static int labpc_attach(struct comedi_device * dev, struct comedi_devconfig * it) static int labpc_attach(struct comedi_device * dev, struct comedi_devconfig * it)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment