Commit 46399a84 authored by H Hartley Sweeten's avatar H Hartley Sweeten Committed by Greg Kroah-Hartman

staging: comedi: das16: move boardinfo declaration

Now that the boardinfo does not require any forward declarations,
move it near the definition of the struct.
Signed-off-by: default avatarH Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: default avatarIan Abbott <abbotti@mev.co.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent b65daeef
...@@ -253,6 +253,218 @@ struct das16_board { ...@@ -253,6 +253,218 @@ struct das16_board {
unsigned int id; unsigned int id;
}; };
static const struct das16_board das16_boards[] = {
{
.name = "das-16",
.ai_maxdata = 0x0fff,
.ai_speed = 15000,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x00,
}, {
.name = "das-16g",
.ai_maxdata = 0x0fff,
.ai_speed = 15000,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x00,
}, {
.name = "das-16f",
.ai_maxdata = 0x0fff,
.ai_speed = 8500,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x00,
}, {
.name = "cio-das16",
.ai_maxdata = 0x0fff,
.ai_speed = 20000,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x80,
}, {
.name = "cio-das16/f",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x80,
}, {
.name = "cio-das16/jr",
.ai_maxdata = 0x0fff,
.ai_speed = 7692,
.ai_pg = das16_pg_16jr,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x10,
.id = 0x00,
}, {
.name = "pc104-das16jr",
.ai_maxdata = 0x0fff,
.ai_speed = 3300,
.ai_pg = das16_pg_16jr,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x10,
.id = 0x00,
}, {
.name = "cio-das16jr/16",
.ai_maxdata = 0xffff,
.ai_speed = 10000,
.ai_pg = das16_pg_16jr_16,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x10,
.id = 0x00,
}, {
.name = "pc104-das16jr/16",
.ai_maxdata = 0xffff,
.ai_speed = 10000,
.ai_pg = das16_pg_16jr_16,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x10,
.id = 0x00,
}, {
.name = "das-1201",
.ai_maxdata = 0x0fff,
.ai_speed = 20000,
.ai_pg = das16_pg_none,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0x20,
}, {
.name = "das-1202",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_none,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0x20,
}, {
.name = "das-1401",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1601,
.i8255_offset = 0x0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "das-1402",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.i8255_offset = 0x0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "das-1601",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1601,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "das-1602",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1401/12",
.ai_maxdata = 0x0fff,
.ai_speed = 6250,
.ai_pg = das16_pg_1601,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1402/12",
.ai_maxdata = 0x0fff,
.ai_speed = 6250,
.ai_pg = das16_pg_1602,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1402/16",
.ai_maxdata = 0xffff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1601/12",
.ai_maxdata = 0x0fff,
.ai_speed = 6250,
.ai_pg = das16_pg_1601,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1602/12",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1602/16",
.ai_maxdata = 0xffff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das16/330",
.ai_maxdata = 0x0fff,
.ai_speed = 3030,
.ai_pg = das16_pg_16jr,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0xf0,
},
};
/* Period for timer interrupt in jiffies. It's a function /* Period for timer interrupt in jiffies. It's a function
* to deal with possibility of dynamic HZ patches */ * to deal with possibility of dynamic HZ patches */
static inline int timer_period(void) static inline int timer_period(void)
...@@ -1066,218 +1278,6 @@ static void das16_detach(struct comedi_device *dev) ...@@ -1066,218 +1278,6 @@ static void das16_detach(struct comedi_device *dev)
comedi_legacy_detach(dev); comedi_legacy_detach(dev);
} }
static const struct das16_board das16_boards[] = {
{
.name = "das-16",
.ai_maxdata = 0x0fff,
.ai_speed = 15000,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x00,
}, {
.name = "das-16g",
.ai_maxdata = 0x0fff,
.ai_speed = 15000,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x00,
}, {
.name = "das-16f",
.ai_maxdata = 0x0fff,
.ai_speed = 8500,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x00,
}, {
.name = "cio-das16",
.ai_maxdata = 0x0fff,
.ai_speed = 20000,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x80,
}, {
.name = "cio-das16/f",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_none,
.has_ao = 1,
.i8255_offset = 0x10,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0x80,
}, {
.name = "cio-das16/jr",
.ai_maxdata = 0x0fff,
.ai_speed = 7692,
.ai_pg = das16_pg_16jr,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x10,
.id = 0x00,
}, {
.name = "pc104-das16jr",
.ai_maxdata = 0x0fff,
.ai_speed = 3300,
.ai_pg = das16_pg_16jr,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x10,
.id = 0x00,
}, {
.name = "cio-das16jr/16",
.ai_maxdata = 0xffff,
.ai_speed = 10000,
.ai_pg = das16_pg_16jr_16,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x10,
.id = 0x00,
}, {
.name = "pc104-das16jr/16",
.ai_maxdata = 0xffff,
.ai_speed = 10000,
.ai_pg = das16_pg_16jr_16,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x10,
.id = 0x00,
}, {
.name = "das-1201",
.ai_maxdata = 0x0fff,
.ai_speed = 20000,
.ai_pg = das16_pg_none,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0x20,
}, {
.name = "das-1202",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_none,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0x20,
}, {
.name = "das-1401",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1601,
.i8255_offset = 0x0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "das-1402",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.i8255_offset = 0x0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "das-1601",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1601,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "das-1602",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1401/12",
.ai_maxdata = 0x0fff,
.ai_speed = 6250,
.ai_pg = das16_pg_1601,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1402/12",
.ai_maxdata = 0x0fff,
.ai_speed = 6250,
.ai_pg = das16_pg_1602,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1402/16",
.ai_maxdata = 0xffff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1601/12",
.ai_maxdata = 0x0fff,
.ai_speed = 6250,
.ai_pg = das16_pg_1601,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1602/12",
.ai_maxdata = 0x0fff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das1602/16",
.ai_maxdata = 0xffff,
.ai_speed = 10000,
.ai_pg = das16_pg_1602,
.has_ao = 1,
.i8255_offset = 0x400,
.i8254_offset = 0x0c,
.size = 0x408,
.id = 0xc0,
}, {
.name = "cio-das16/330",
.ai_maxdata = 0x0fff,
.ai_speed = 3030,
.ai_pg = das16_pg_16jr,
.i8255_offset = 0,
.i8254_offset = 0x0c,
.size = 0x14,
.id = 0xf0,
},
};
static struct comedi_driver das16_driver = { static struct comedi_driver das16_driver = {
.driver_name = "das16", .driver_name = "das16",
.module = THIS_MODULE, .module = THIS_MODULE,
......
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