staging: comedi: ni_stc.h: the boardinfo 'name' should be first

By convention, the first member of the boardinfo is a 'const char *' to
the board name, especially for those comedi drivers that rely on the
comedi core to set dev->board_ptr to the entry matching the board name
when doing a legacy (*attach) to a comedi driver.

Modify the ni_board_struct appropriately for consistency, although the
board name is only used for informational purposes by this driver (only
the driver name is matched by the comedi core).

For aesthetics, also move the members in the boardinfo declarations.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
H Hartley Sweeten 2014-06-26 10:13:08 -07:00 committed by Greg Kroah-Hartman
parent 252948517c
commit b674f9df20
3 changed files with 15 additions and 15 deletions

View File

@ -107,9 +107,9 @@ are not supported.
static const struct ni_board_struct ni_boards[] = {
{
.name = "at-mio-16e-1",
.device_id = 44,
.isapnp_id = 0x0000, /* XXX unknown */
.name = "at-mio-16e-1",
.n_adchan = 16,
.adbits = 12,
.ai_fifo_depth = 8192,
@ -124,9 +124,9 @@ static const struct ni_board_struct ni_boards[] = {
.num_p0_dio_channels = 8,
.caldac = { mb88341 },
}, {
.name = "at-mio-16e-2",
.device_id = 25,
.isapnp_id = 0x1900,
.name = "at-mio-16e-2",
.n_adchan = 16,
.adbits = 12,
.ai_fifo_depth = 2048,
@ -141,9 +141,9 @@ static const struct ni_board_struct ni_boards[] = {
.num_p0_dio_channels = 8,
.caldac = { mb88341 },
}, {
.name = "at-mio-16e-10",
.device_id = 36,
.isapnp_id = 0x2400,
.name = "at-mio-16e-10",
.n_adchan = 16,
.adbits = 12,
.ai_fifo_depth = 512,
@ -157,9 +157,9 @@ static const struct ni_board_struct ni_boards[] = {
.num_p0_dio_channels = 8,
.caldac = { ad8804_debug },
}, {
.name = "at-mio-16de-10",
.device_id = 37,
.isapnp_id = 0x2500,
.name = "at-mio-16de-10",
.n_adchan = 16,
.adbits = 12,
.ai_fifo_depth = 512,
@ -174,9 +174,9 @@ static const struct ni_board_struct ni_boards[] = {
.caldac = { ad8804_debug },
.has_8255 = 1,
}, {
.name = "at-mio-64e-3",
.device_id = 38,
.isapnp_id = 0x2600,
.name = "at-mio-64e-3",
.n_adchan = 64,
.adbits = 12,
.ai_fifo_depth = 2048,
@ -191,9 +191,9 @@ static const struct ni_board_struct ni_boards[] = {
.num_p0_dio_channels = 8,
.caldac = { ad8804_debug },
}, {
.name = "at-mio-16xe-50",
.device_id = 39,
.isapnp_id = 0x2700,
.name = "at-mio-16xe-50",
.n_adchan = 16,
.adbits = 16,
.ai_fifo_depth = 512,
@ -207,9 +207,9 @@ static const struct ni_board_struct ni_boards[] = {
.num_p0_dio_channels = 8,
.caldac = { dac8800, dac8043 },
}, {
.name = "at-mio-16xe-10",
.device_id = 50,
.isapnp_id = 0x0000, /* XXX unknown */
.name = "at-mio-16xe-10",
.n_adchan = 16,
.adbits = 16,
.ai_fifo_depth = 512,
@ -225,9 +225,9 @@ static const struct ni_board_struct ni_boards[] = {
.num_p0_dio_channels = 8,
.caldac = { dac8800, dac8043, ad8522 },
}, {
.name = "at-ai-16xe-10",
.device_id = 51,
.isapnp_id = 0x0000, /* XXX unknown */
.name = "at-ai-16xe-10",
.n_adchan = 16,
.adbits = 16,
.ai_fifo_depth = 512,

View File

@ -56,8 +56,8 @@ See the notes in the ni_atmio.o driver.
static const struct ni_board_struct ni_boards[] = {
{
.device_id = 0x010d,
.name = "DAQCard-ai-16xe-50",
.device_id = 0x010d,
.n_adchan = 16,
.adbits = 16,
.ai_fifo_depth = 1024,
@ -66,8 +66,8 @@ static const struct ni_board_struct ni_boards[] = {
.num_p0_dio_channels = 8,
.caldac = { dac8800, dac8043 },
}, {
.device_id = 0x010c,
.name = "DAQCard-ai-16e-4",
.device_id = 0x010c,
.n_adchan = 16,
.adbits = 12,
.ai_fifo_depth = 1024,
@ -76,8 +76,8 @@ static const struct ni_board_struct ni_boards[] = {
.num_p0_dio_channels = 8,
.caldac = { mb88341 }, /* verified */
}, {
.device_id = 0x02c4,
.name = "DAQCard-6062E",
.device_id = 0x02c4,
.n_adchan = 16,
.adbits = 12,
.ai_fifo_depth = 8192,
@ -92,8 +92,8 @@ static const struct ni_board_struct ni_boards[] = {
.caldac = { ad8804_debug }, /* verified */
}, {
/* specs incorrect! */
.device_id = 0x075e,
.name = "DAQCard-6024E",
.device_id = 0x075e,
.n_adchan = 16,
.adbits = 12,
.ai_fifo_depth = 1024,
@ -107,8 +107,8 @@ static const struct ni_board_struct ni_boards[] = {
.caldac = { ad8804_debug },
}, {
/* specs incorrect! */
.device_id = 0x0245,
.name = "DAQCard-6036E",
.device_id = 0x0245,
.n_adchan = 16,
.adbits = 16,
.ai_fifo_depth = 1024,
@ -124,8 +124,8 @@ static const struct ni_board_struct ni_boards[] = {
},
#if 0
{
.device_id = 0x0000, /* unknown */
.name = "DAQCard-6715",
.device_id = 0x0000, /* unknown */
.n_aochan = 8,
.aobits = 12,
.ao_671x = 8192,

View File

@ -1388,9 +1388,9 @@ enum Interrupt_C_Status_Bits {
#define M_SERIES_EEPROM_SIZE 1024
struct ni_board_struct {
const char *name;
int device_id;
int isapnp_id;
char *name;
int n_adchan;
int adbits;