staging: comedi: ni_stc.h: add some 'is_{board type}' flags to private data
The board->reg_type if checked quite often in the ni_mio_common.c code to handle differences in the PCI devices supported by the ni_pcimio driver. Simplify the code a bit by adding some 'is_{board type}' bit-field flags to the private data. 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:
parent
bfb0c28ba0
commit
a52b53e4a7
|
@ -958,11 +958,11 @@ static void ni_e_series_enable_second_irq(struct comedi_device *dev,
|
||||||
|
|
||||||
static void ni_clear_ai_fifo(struct comedi_device *dev)
|
static void ni_clear_ai_fifo(struct comedi_device *dev)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
struct ni_private *devpriv = dev->private;
|
||||||
static const int timeout = 10000;
|
static const int timeout = 10000;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if (board->reg_type == ni_reg_6143) {
|
if (devpriv->is_6143) {
|
||||||
/* Flush the 6143 data FIFO */
|
/* Flush the 6143 data FIFO */
|
||||||
ni_writel(dev, 0x10, AIFIFO_Control_6143);
|
ni_writel(dev, 0x10, AIFIFO_Control_6143);
|
||||||
ni_writel(dev, 0x00, AIFIFO_Control_6143);
|
ni_writel(dev, 0x00, AIFIFO_Control_6143);
|
||||||
|
@ -977,7 +977,7 @@ static void ni_clear_ai_fifo(struct comedi_device *dev)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
ni_stc_writew(dev, 1, ADC_FIFO_Clear);
|
ni_stc_writew(dev, 1, ADC_FIFO_Clear);
|
||||||
if (board->reg_type == ni_reg_625x) {
|
if (devpriv->is_625x) {
|
||||||
ni_writeb(dev, 0, M_Offset_Static_AI_Control(0));
|
ni_writeb(dev, 0, M_Offset_Static_AI_Control(0));
|
||||||
ni_writeb(dev, 1, M_Offset_Static_AI_Control(0));
|
ni_writeb(dev, 1, M_Offset_Static_AI_Control(0));
|
||||||
#if 0
|
#if 0
|
||||||
|
@ -1140,7 +1140,7 @@ static int ni_ao_wait_for_dma_load(struct comedi_device *dev)
|
||||||
static void ni_ao_fifo_load(struct comedi_device *dev,
|
static void ni_ao_fifo_load(struct comedi_device *dev,
|
||||||
struct comedi_subdevice *s, int n)
|
struct comedi_subdevice *s, int n)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
struct ni_private *devpriv = dev->private;
|
||||||
struct comedi_async *async = s->async;
|
struct comedi_async *async = s->async;
|
||||||
struct comedi_cmd *cmd = &async->cmd;
|
struct comedi_cmd *cmd = &async->cmd;
|
||||||
int chan;
|
int chan;
|
||||||
|
@ -1158,10 +1158,10 @@ static void ni_ao_fifo_load(struct comedi_device *dev,
|
||||||
|
|
||||||
range = CR_RANGE(cmd->chanlist[chan]);
|
range = CR_RANGE(cmd->chanlist[chan]);
|
||||||
|
|
||||||
if (board->reg_type & ni_reg_6xxx_mask) {
|
if (devpriv->is_6xxx) {
|
||||||
packed_data = d & 0xffff;
|
packed_data = d & 0xffff;
|
||||||
/* 6711 only has 16 bit wide ao fifo */
|
/* 6711 only has 16 bit wide ao fifo */
|
||||||
if (board->reg_type != ni_reg_6711) {
|
if (!devpriv->is_6711) {
|
||||||
err &= comedi_buf_get(s, &d);
|
err &= comedi_buf_get(s, &d);
|
||||||
if (err == 0)
|
if (err == 0)
|
||||||
break;
|
break;
|
||||||
|
@ -1224,11 +1224,12 @@ static int ni_ao_prep_fifo(struct comedi_device *dev,
|
||||||
struct comedi_subdevice *s)
|
struct comedi_subdevice *s)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
const struct ni_board_struct *board = comedi_board(dev);
|
||||||
|
struct ni_private *devpriv = dev->private;
|
||||||
int n;
|
int n;
|
||||||
|
|
||||||
/* reset fifo */
|
/* reset fifo */
|
||||||
ni_stc_writew(dev, 1, DAC_FIFO_Clear);
|
ni_stc_writew(dev, 1, DAC_FIFO_Clear);
|
||||||
if (board->reg_type & ni_reg_6xxx_mask)
|
if (devpriv->is_6xxx)
|
||||||
ni_ao_win_outl(dev, 0x6, AO_FIFO_Offset_Load_611x);
|
ni_ao_win_outl(dev, 0x6, AO_FIFO_Offset_Load_611x);
|
||||||
|
|
||||||
/* load some data */
|
/* load some data */
|
||||||
|
@ -1248,12 +1249,11 @@ static int ni_ao_prep_fifo(struct comedi_device *dev,
|
||||||
static void ni_ai_fifo_read(struct comedi_device *dev,
|
static void ni_ai_fifo_read(struct comedi_device *dev,
|
||||||
struct comedi_subdevice *s, int n)
|
struct comedi_subdevice *s, int n)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
|
||||||
struct ni_private *devpriv = dev->private;
|
struct ni_private *devpriv = dev->private;
|
||||||
struct comedi_async *async = s->async;
|
struct comedi_async *async = s->async;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if (board->reg_type == ni_reg_611x) {
|
if (devpriv->is_611x) {
|
||||||
unsigned short data[2];
|
unsigned short data[2];
|
||||||
u32 dl;
|
u32 dl;
|
||||||
|
|
||||||
|
@ -1270,7 +1270,7 @@ static void ni_ai_fifo_read(struct comedi_device *dev,
|
||||||
data[0] = dl & 0xffff;
|
data[0] = dl & 0xffff;
|
||||||
cfc_write_to_buffer(s, data[0]);
|
cfc_write_to_buffer(s, data[0]);
|
||||||
}
|
}
|
||||||
} else if (board->reg_type == ni_reg_6143) {
|
} else if (devpriv->is_6143) {
|
||||||
unsigned short data[2];
|
unsigned short data[2];
|
||||||
u32 dl;
|
u32 dl;
|
||||||
|
|
||||||
|
@ -1324,7 +1324,6 @@ static void ni_handle_fifo_half_full(struct comedi_device *dev)
|
||||||
*/
|
*/
|
||||||
static void ni_handle_fifo_dregs(struct comedi_device *dev)
|
static void ni_handle_fifo_dregs(struct comedi_device *dev)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
|
||||||
struct ni_private *devpriv = dev->private;
|
struct ni_private *devpriv = dev->private;
|
||||||
struct comedi_subdevice *s = dev->read_subdev;
|
struct comedi_subdevice *s = dev->read_subdev;
|
||||||
unsigned short data[2];
|
unsigned short data[2];
|
||||||
|
@ -1332,7 +1331,7 @@ static void ni_handle_fifo_dregs(struct comedi_device *dev)
|
||||||
unsigned short fifo_empty;
|
unsigned short fifo_empty;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if (board->reg_type == ni_reg_611x) {
|
if (devpriv->is_611x) {
|
||||||
while ((ni_stc_readw(dev, AI_Status_1_Register) &
|
while ((ni_stc_readw(dev, AI_Status_1_Register) &
|
||||||
AI_FIFO_Empty_St) == 0) {
|
AI_FIFO_Empty_St) == 0) {
|
||||||
dl = ni_readl(dev, ADC_FIFO_Data_611x);
|
dl = ni_readl(dev, ADC_FIFO_Data_611x);
|
||||||
|
@ -1342,7 +1341,7 @@ static void ni_handle_fifo_dregs(struct comedi_device *dev)
|
||||||
data[1] = (dl & 0xffff);
|
data[1] = (dl & 0xffff);
|
||||||
cfc_write_array_to_buffer(s, data, sizeof(data));
|
cfc_write_array_to_buffer(s, data, sizeof(data));
|
||||||
}
|
}
|
||||||
} else if (board->reg_type == ni_reg_6143) {
|
} else if (devpriv->is_6143) {
|
||||||
i = 0;
|
i = 0;
|
||||||
while (ni_readl(dev, AIFIFO_Status_6143) & 0x04) {
|
while (ni_readl(dev, AIFIFO_Status_6143) & 0x04) {
|
||||||
dl = ni_readl(dev, AIFIFO_Data_6143);
|
dl = ni_readl(dev, AIFIFO_Data_6143);
|
||||||
|
@ -1388,12 +1387,12 @@ static void ni_handle_fifo_dregs(struct comedi_device *dev)
|
||||||
|
|
||||||
static void get_last_sample_611x(struct comedi_device *dev)
|
static void get_last_sample_611x(struct comedi_device *dev)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
struct ni_private *devpriv = dev->private;
|
||||||
struct comedi_subdevice *s = dev->read_subdev;
|
struct comedi_subdevice *s = dev->read_subdev;
|
||||||
unsigned short data;
|
unsigned short data;
|
||||||
u32 dl;
|
u32 dl;
|
||||||
|
|
||||||
if (board->reg_type != ni_reg_611x)
|
if (!devpriv->is_611x)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/* Check if there's a single sample stuck in the FIFO */
|
/* Check if there's a single sample stuck in the FIFO */
|
||||||
|
@ -1406,12 +1405,12 @@ static void get_last_sample_611x(struct comedi_device *dev)
|
||||||
|
|
||||||
static void get_last_sample_6143(struct comedi_device *dev)
|
static void get_last_sample_6143(struct comedi_device *dev)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
struct ni_private *devpriv = dev->private;
|
||||||
struct comedi_subdevice *s = dev->read_subdev;
|
struct comedi_subdevice *s = dev->read_subdev;
|
||||||
unsigned short data;
|
unsigned short data;
|
||||||
u32 dl;
|
u32 dl;
|
||||||
|
|
||||||
if (board->reg_type != ni_reg_6143)
|
if (!devpriv->is_6143)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/* Check if there's a single sample stuck in the FIFO */
|
/* Check if there's a single sample stuck in the FIFO */
|
||||||
|
@ -1685,7 +1684,6 @@ static void ni_ai_munge(struct comedi_device *dev, struct comedi_subdevice *s,
|
||||||
|
|
||||||
static int ni_ai_setup_MITE_dma(struct comedi_device *dev)
|
static int ni_ai_setup_MITE_dma(struct comedi_device *dev)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
|
||||||
struct ni_private *devpriv = dev->private;
|
struct ni_private *devpriv = dev->private;
|
||||||
struct comedi_subdevice *s = dev->read_subdev;
|
struct comedi_subdevice *s = dev->read_subdev;
|
||||||
int retval;
|
int retval;
|
||||||
|
@ -1705,18 +1703,13 @@ static int ni_ai_setup_MITE_dma(struct comedi_device *dev)
|
||||||
return -EIO;
|
return -EIO;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (board->reg_type) {
|
if (devpriv->is_611x || devpriv->is_6143)
|
||||||
case ni_reg_611x:
|
|
||||||
case ni_reg_6143:
|
|
||||||
mite_prep_dma(devpriv->ai_mite_chan, 32, 16);
|
mite_prep_dma(devpriv->ai_mite_chan, 32, 16);
|
||||||
break;
|
else if (devpriv->is_628x)
|
||||||
case ni_reg_628x:
|
|
||||||
mite_prep_dma(devpriv->ai_mite_chan, 32, 32);
|
mite_prep_dma(devpriv->ai_mite_chan, 32, 32);
|
||||||
break;
|
else
|
||||||
default:
|
|
||||||
mite_prep_dma(devpriv->ai_mite_chan, 16, 16);
|
mite_prep_dma(devpriv->ai_mite_chan, 16, 16);
|
||||||
break;
|
|
||||||
}
|
|
||||||
/*start the MITE */
|
/*start the MITE */
|
||||||
mite_dma_arm(devpriv->ai_mite_chan);
|
mite_dma_arm(devpriv->ai_mite_chan);
|
||||||
spin_unlock_irqrestore(&devpriv->mite_channel_lock, flags);
|
spin_unlock_irqrestore(&devpriv->mite_channel_lock, flags);
|
||||||
|
@ -1726,7 +1719,6 @@ static int ni_ai_setup_MITE_dma(struct comedi_device *dev)
|
||||||
|
|
||||||
static int ni_ao_setup_MITE_dma(struct comedi_device *dev)
|
static int ni_ao_setup_MITE_dma(struct comedi_device *dev)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
|
||||||
struct ni_private *devpriv = dev->private;
|
struct ni_private *devpriv = dev->private;
|
||||||
struct comedi_subdevice *s = dev->write_subdev;
|
struct comedi_subdevice *s = dev->write_subdev;
|
||||||
int retval;
|
int retval;
|
||||||
|
@ -1741,7 +1733,7 @@ static int ni_ao_setup_MITE_dma(struct comedi_device *dev)
|
||||||
|
|
||||||
spin_lock_irqsave(&devpriv->mite_channel_lock, flags);
|
spin_lock_irqsave(&devpriv->mite_channel_lock, flags);
|
||||||
if (devpriv->ao_mite_chan) {
|
if (devpriv->ao_mite_chan) {
|
||||||
if (board->reg_type & (ni_reg_611x | ni_reg_6713)) {
|
if (devpriv->is_611x || devpriv->is_6713) {
|
||||||
mite_prep_dma(devpriv->ao_mite_chan, 32, 32);
|
mite_prep_dma(devpriv->ao_mite_chan, 32, 32);
|
||||||
} else {
|
} else {
|
||||||
/* doing 32 instead of 16 bit wide transfers from memory
|
/* doing 32 instead of 16 bit wide transfers from memory
|
||||||
|
@ -1766,7 +1758,7 @@ static int ni_ao_setup_MITE_dma(struct comedi_device *dev)
|
||||||
|
|
||||||
static int ni_ai_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
static int ni_ai_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
struct ni_private *devpriv = dev->private;
|
||||||
|
|
||||||
ni_release_ai_mite_channel(dev);
|
ni_release_ai_mite_channel(dev);
|
||||||
/* ai configuration */
|
/* ai configuration */
|
||||||
|
@ -1781,7 +1773,7 @@ static int ni_ai_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
|
|
||||||
ni_clear_ai_fifo(dev);
|
ni_clear_ai_fifo(dev);
|
||||||
|
|
||||||
if (board->reg_type != ni_reg_6143)
|
if (!devpriv->is_6143)
|
||||||
ni_writeb(dev, 0, Misc_Command);
|
ni_writeb(dev, 0, Misc_Command);
|
||||||
|
|
||||||
ni_stc_writew(dev, AI_Disarm, AI_Command_1_Register); /* reset pulses */
|
ni_stc_writew(dev, AI_Disarm, AI_Command_1_Register); /* reset pulses */
|
||||||
|
@ -1791,7 +1783,7 @@ static int ni_ai_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
ni_stc_writew(dev, 0x0000, AI_Mode_2_Register);
|
ni_stc_writew(dev, 0x0000, AI_Mode_2_Register);
|
||||||
/* generate FIFO interrupts on non-empty */
|
/* generate FIFO interrupts on non-empty */
|
||||||
ni_stc_writew(dev, (0 << 6) | 0x0000, AI_Mode_3_Register);
|
ni_stc_writew(dev, (0 << 6) | 0x0000, AI_Mode_3_Register);
|
||||||
if (board->reg_type == ni_reg_611x) {
|
if (devpriv->is_611x) {
|
||||||
ni_stc_writew(dev,
|
ni_stc_writew(dev,
|
||||||
AI_SHIFTIN_Pulse_Width |
|
AI_SHIFTIN_Pulse_Width |
|
||||||
AI_SOC_Polarity |
|
AI_SOC_Polarity |
|
||||||
|
@ -1805,7 +1797,7 @@ static int ni_ai_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
AI_CONVERT_Output_Select
|
AI_CONVERT_Output_Select
|
||||||
(AI_CONVERT_Output_Enable_High),
|
(AI_CONVERT_Output_Enable_High),
|
||||||
AI_Output_Control_Register);
|
AI_Output_Control_Register);
|
||||||
} else if (board->reg_type == ni_reg_6143) {
|
} else if (devpriv->is_6143) {
|
||||||
ni_stc_writew(dev, AI_SHIFTIN_Pulse_Width |
|
ni_stc_writew(dev, AI_SHIFTIN_Pulse_Width |
|
||||||
AI_SOC_Polarity |
|
AI_SOC_Polarity |
|
||||||
AI_LOCALMUX_CLK_Pulse_Width,
|
AI_LOCALMUX_CLK_Pulse_Width,
|
||||||
|
@ -1831,7 +1823,7 @@ static int ni_ai_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
AI_EXTMUX_CLK_Output_Select(0) |
|
AI_EXTMUX_CLK_Output_Select(0) |
|
||||||
AI_LOCALMUX_CLK_Output_Select(2) |
|
AI_LOCALMUX_CLK_Output_Select(2) |
|
||||||
AI_SC_TC_Output_Select(3);
|
AI_SC_TC_Output_Select(3);
|
||||||
if (board->reg_type == ni_reg_622x)
|
if (devpriv->is_622x)
|
||||||
ai_output_control_bits |=
|
ai_output_control_bits |=
|
||||||
AI_CONVERT_Output_Select
|
AI_CONVERT_Output_Select
|
||||||
(AI_CONVERT_Output_Enable_High);
|
(AI_CONVERT_Output_Enable_High);
|
||||||
|
@ -2022,8 +2014,7 @@ static void ni_load_channelgain_list(struct comedi_device *dev,
|
||||||
ni_m_series_load_channelgain_list(dev, n_chan, list);
|
ni_m_series_load_channelgain_list(dev, n_chan, list);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (n_chan == 1 && (board->reg_type != ni_reg_611x)
|
if (n_chan == 1 && !devpriv->is_611x && !devpriv->is_6143) {
|
||||||
&& (board->reg_type != ni_reg_6143)) {
|
|
||||||
if (devpriv->changain_state
|
if (devpriv->changain_state
|
||||||
&& devpriv->changain_spec == list[0]) {
|
&& devpriv->changain_spec == list[0]) {
|
||||||
/* ready to go. */
|
/* ready to go. */
|
||||||
|
@ -2038,7 +2029,7 @@ static void ni_load_channelgain_list(struct comedi_device *dev,
|
||||||
ni_stc_writew(dev, 1, Configuration_Memory_Clear);
|
ni_stc_writew(dev, 1, Configuration_Memory_Clear);
|
||||||
|
|
||||||
/* Set up Calibration mode if required */
|
/* Set up Calibration mode if required */
|
||||||
if (board->reg_type == ni_reg_6143) {
|
if (devpriv->is_6143) {
|
||||||
if ((list[0] & CR_ALT_SOURCE)
|
if ((list[0] & CR_ALT_SOURCE)
|
||||||
&& !devpriv->ai_calib_source_enabled) {
|
&& !devpriv->ai_calib_source_enabled) {
|
||||||
/* Strobe Relay enable bit */
|
/* Strobe Relay enable bit */
|
||||||
|
@ -2064,8 +2055,7 @@ static void ni_load_channelgain_list(struct comedi_device *dev,
|
||||||
|
|
||||||
offset = 1 << (board->adbits - 1);
|
offset = 1 << (board->adbits - 1);
|
||||||
for (i = 0; i < n_chan; i++) {
|
for (i = 0; i < n_chan; i++) {
|
||||||
if ((board->reg_type != ni_reg_6143)
|
if (!devpriv->is_6143 && (list[i] & CR_ALT_SOURCE)) {
|
||||||
&& (list[i] & CR_ALT_SOURCE)) {
|
|
||||||
chan = devpriv->ai_calib_source;
|
chan = devpriv->ai_calib_source;
|
||||||
} else {
|
} else {
|
||||||
chan = CR_CHAN(list[i]);
|
chan = CR_CHAN(list[i]);
|
||||||
|
@ -2076,20 +2066,20 @@ static void ni_load_channelgain_list(struct comedi_device *dev,
|
||||||
|
|
||||||
/* fix the external/internal range differences */
|
/* fix the external/internal range differences */
|
||||||
range = ni_gainlkup[board->gainlkup][range];
|
range = ni_gainlkup[board->gainlkup][range];
|
||||||
if (board->reg_type == ni_reg_611x)
|
if (devpriv->is_611x)
|
||||||
devpriv->ai_offset[i] = offset;
|
devpriv->ai_offset[i] = offset;
|
||||||
else
|
else
|
||||||
devpriv->ai_offset[i] = (range & 0x100) ? 0 : offset;
|
devpriv->ai_offset[i] = (range & 0x100) ? 0 : offset;
|
||||||
|
|
||||||
hi = 0;
|
hi = 0;
|
||||||
if ((list[i] & CR_ALT_SOURCE)) {
|
if ((list[i] & CR_ALT_SOURCE)) {
|
||||||
if (board->reg_type == ni_reg_611x)
|
if (devpriv->is_611x)
|
||||||
ni_writew(dev, CR_CHAN(list[i]) & 0x0003,
|
ni_writew(dev, CR_CHAN(list[i]) & 0x0003,
|
||||||
Calibration_Channel_Select_611x);
|
Calibration_Channel_Select_611x);
|
||||||
} else {
|
} else {
|
||||||
if (board->reg_type == ni_reg_611x)
|
if (devpriv->is_611x)
|
||||||
aref = AREF_DIFF;
|
aref = AREF_DIFF;
|
||||||
else if (board->reg_type == ni_reg_6143)
|
else if (devpriv->is_6143)
|
||||||
aref = AREF_OTHER;
|
aref = AREF_OTHER;
|
||||||
switch (aref) {
|
switch (aref) {
|
||||||
case AREF_DIFF:
|
case AREF_DIFF:
|
||||||
|
@ -2109,7 +2099,7 @@ static void ni_load_channelgain_list(struct comedi_device *dev,
|
||||||
|
|
||||||
ni_writew(dev, hi, Configuration_Memory_High);
|
ni_writew(dev, hi, Configuration_Memory_High);
|
||||||
|
|
||||||
if (board->reg_type != ni_reg_6143) {
|
if (!devpriv->is_6143) {
|
||||||
lo = range;
|
lo = range;
|
||||||
if (i == n_chan - 1)
|
if (i == n_chan - 1)
|
||||||
lo |= AI_LAST_CHANNEL;
|
lo |= AI_LAST_CHANNEL;
|
||||||
|
@ -2121,10 +2111,8 @@ static void ni_load_channelgain_list(struct comedi_device *dev,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* prime the channel/gain list */
|
/* prime the channel/gain list */
|
||||||
if ((board->reg_type != ni_reg_611x)
|
if (!devpriv->is_611x && !devpriv->is_6143)
|
||||||
&& (board->reg_type != ni_reg_6143)) {
|
|
||||||
ni_prime_channelgain_list(dev);
|
ni_prime_channelgain_list(dev);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int ni_ai_insn_read(struct comedi_device *dev,
|
static int ni_ai_insn_read(struct comedi_device *dev,
|
||||||
|
@ -2145,7 +2133,7 @@ static int ni_ai_insn_read(struct comedi_device *dev,
|
||||||
ni_clear_ai_fifo(dev);
|
ni_clear_ai_fifo(dev);
|
||||||
|
|
||||||
signbits = devpriv->ai_offset[0];
|
signbits = devpriv->ai_offset[0];
|
||||||
if (board->reg_type == ni_reg_611x) {
|
if (devpriv->is_611x) {
|
||||||
for (n = 0; n < num_adc_stages_611x; n++) {
|
for (n = 0; n < num_adc_stages_611x; n++) {
|
||||||
ni_stc_writew(dev, AI_CONVERT_Pulse,
|
ni_stc_writew(dev, AI_CONVERT_Pulse,
|
||||||
AI_Command_1_Register);
|
AI_Command_1_Register);
|
||||||
|
@ -2178,7 +2166,7 @@ static int ni_ai_insn_read(struct comedi_device *dev,
|
||||||
d += signbits;
|
d += signbits;
|
||||||
data[n] = d;
|
data[n] = d;
|
||||||
}
|
}
|
||||||
} else if (board->reg_type == ni_reg_6143) {
|
} else if (devpriv->is_6143) {
|
||||||
for (n = 0; n < insn->n; n++) {
|
for (n = 0; n < insn->n; n++) {
|
||||||
ni_stc_writew(dev, AI_CONVERT_Pulse,
|
ni_stc_writew(dev, AI_CONVERT_Pulse,
|
||||||
AI_Command_1_Register);
|
AI_Command_1_Register);
|
||||||
|
@ -2261,17 +2249,13 @@ static unsigned ni_min_ai_scan_period_ns(struct comedi_device *dev,
|
||||||
unsigned num_channels)
|
unsigned num_channels)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
const struct ni_board_struct *board = comedi_board(dev);
|
||||||
|
struct ni_private *devpriv = dev->private;
|
||||||
|
|
||||||
switch (board->reg_type) {
|
/* simultaneously-sampled inputs */
|
||||||
case ni_reg_611x:
|
if (devpriv->is_611x || devpriv->is_6143)
|
||||||
case ni_reg_6143:
|
|
||||||
/* simultaneously-sampled inputs */
|
|
||||||
return board->ai_speed;
|
return board->ai_speed;
|
||||||
break;
|
|
||||||
default:
|
/* multiplexed inputs */
|
||||||
/* multiplexed inputs */
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
return board->ai_speed * num_channels;
|
return board->ai_speed * num_channels;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2295,8 +2279,7 @@ static int ni_ai_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s,
|
||||||
TRIG_TIMER | TRIG_EXT);
|
TRIG_TIMER | TRIG_EXT);
|
||||||
|
|
||||||
sources = TRIG_TIMER | TRIG_EXT;
|
sources = TRIG_TIMER | TRIG_EXT;
|
||||||
if (board->reg_type == ni_reg_611x ||
|
if (devpriv->is_611x || devpriv->is_6143)
|
||||||
board->reg_type == ni_reg_6143)
|
|
||||||
sources |= TRIG_NOW;
|
sources |= TRIG_NOW;
|
||||||
err |= cfc_check_trigger_src(&cmd->convert_src, sources);
|
err |= cfc_check_trigger_src(&cmd->convert_src, sources);
|
||||||
|
|
||||||
|
@ -2353,8 +2336,7 @@ static int ni_ai_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cmd->convert_src == TRIG_TIMER) {
|
if (cmd->convert_src == TRIG_TIMER) {
|
||||||
if ((board->reg_type == ni_reg_611x)
|
if (devpriv->is_611x || devpriv->is_6143) {
|
||||||
|| (board->reg_type == ni_reg_6143)) {
|
|
||||||
err |= cfc_check_trigger_arg_is(&cmd->convert_arg, 0);
|
err |= cfc_check_trigger_arg_is(&cmd->convert_arg, 0);
|
||||||
} else {
|
} else {
|
||||||
err |= cfc_check_trigger_arg_min(&cmd->convert_arg,
|
err |= cfc_check_trigger_arg_min(&cmd->convert_arg,
|
||||||
|
@ -2379,7 +2361,7 @@ static int ni_ai_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s,
|
||||||
if (cmd->stop_src == TRIG_COUNT) {
|
if (cmd->stop_src == TRIG_COUNT) {
|
||||||
unsigned int max_count = 0x01000000;
|
unsigned int max_count = 0x01000000;
|
||||||
|
|
||||||
if (board->reg_type == ni_reg_611x)
|
if (devpriv->is_611x)
|
||||||
max_count -= num_adc_stages_611x;
|
max_count -= num_adc_stages_611x;
|
||||||
err |= cfc_check_trigger_arg_max(&cmd->stop_arg, max_count);
|
err |= cfc_check_trigger_arg_max(&cmd->stop_arg, max_count);
|
||||||
err |= cfc_check_trigger_arg_min(&cmd->stop_arg, 1);
|
err |= cfc_check_trigger_arg_min(&cmd->stop_arg, 1);
|
||||||
|
@ -2405,8 +2387,7 @@ static int ni_ai_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s,
|
||||||
err++;
|
err++;
|
||||||
}
|
}
|
||||||
if (cmd->convert_src == TRIG_TIMER) {
|
if (cmd->convert_src == TRIG_TIMER) {
|
||||||
if ((board->reg_type != ni_reg_611x)
|
if (!devpriv->is_611x && !devpriv->is_6143) {
|
||||||
&& (board->reg_type != ni_reg_6143)) {
|
|
||||||
tmp = cmd->convert_arg;
|
tmp = cmd->convert_arg;
|
||||||
cmd->convert_arg =
|
cmd->convert_arg =
|
||||||
ni_timer_to_ns(dev, ni_ns_to_timer(dev,
|
ni_timer_to_ns(dev, ni_ns_to_timer(dev,
|
||||||
|
@ -2451,7 +2432,6 @@ static int ni_ai_inttrig(struct comedi_device *dev,
|
||||||
|
|
||||||
static int ni_ai_cmd(struct comedi_device *dev, struct comedi_subdevice *s)
|
static int ni_ai_cmd(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
|
||||||
struct ni_private *devpriv = dev->private;
|
struct ni_private *devpriv = dev->private;
|
||||||
const struct comedi_cmd *cmd = &s->async->cmd;
|
const struct comedi_cmd *cmd = &s->async->cmd;
|
||||||
int timer;
|
int timer;
|
||||||
|
@ -2507,8 +2487,7 @@ static int ni_ai_cmd(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
mode2 &= ~AI_SC_Reload_Mode;
|
mode2 &= ~AI_SC_Reload_Mode;
|
||||||
ni_stc_writew(dev, mode2, AI_Mode_2_Register);
|
ni_stc_writew(dev, mode2, AI_Mode_2_Register);
|
||||||
|
|
||||||
if (cmd->chanlist_len == 1 || (board->reg_type == ni_reg_611x)
|
if (cmd->chanlist_len == 1 || devpriv->is_611x || devpriv->is_6143) {
|
||||||
|| (board->reg_type == ni_reg_6143)) {
|
|
||||||
start_stop_select |= AI_STOP_Polarity;
|
start_stop_select |= AI_STOP_Polarity;
|
||||||
start_stop_select |= AI_STOP_Select(31); /* logic low */
|
start_stop_select |= AI_STOP_Select(31); /* logic low */
|
||||||
start_stop_select |= AI_STOP_Sync;
|
start_stop_select |= AI_STOP_Sync;
|
||||||
|
@ -2522,7 +2501,7 @@ static int ni_ai_cmd(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
case TRIG_COUNT:
|
case TRIG_COUNT:
|
||||||
stop_count = cmd->stop_arg - 1;
|
stop_count = cmd->stop_arg - 1;
|
||||||
|
|
||||||
if (board->reg_type == ni_reg_611x) {
|
if (devpriv->is_611x) {
|
||||||
/* have to take 3 stage adc pipeline into account */
|
/* have to take 3 stage adc pipeline into account */
|
||||||
stop_count += num_adc_stages_611x;
|
stop_count += num_adc_stages_611x;
|
||||||
}
|
}
|
||||||
|
@ -2857,7 +2836,6 @@ static int ni_ai_insn_config(struct comedi_device *dev,
|
||||||
struct comedi_subdevice *s,
|
struct comedi_subdevice *s,
|
||||||
struct comedi_insn *insn, unsigned int *data)
|
struct comedi_insn *insn, unsigned int *data)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
|
||||||
struct ni_private *devpriv = dev->private;
|
struct ni_private *devpriv = dev->private;
|
||||||
|
|
||||||
if (insn->n < 1)
|
if (insn->n < 1)
|
||||||
|
@ -2875,7 +2853,7 @@ static int ni_ai_insn_config(struct comedi_device *dev,
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
devpriv->ai_calib_source = data[1];
|
devpriv->ai_calib_source = data[1];
|
||||||
} else if (board->reg_type == ni_reg_6143) {
|
} else if (devpriv->is_6143) {
|
||||||
unsigned int calib_source;
|
unsigned int calib_source;
|
||||||
|
|
||||||
calib_source = data[1] & 0xf;
|
calib_source = data[1] & 0xf;
|
||||||
|
@ -2895,7 +2873,7 @@ static int ni_ai_insn_config(struct comedi_device *dev,
|
||||||
if (calib_source >= 8)
|
if (calib_source >= 8)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
devpriv->ai_calib_source = calib_source;
|
devpriv->ai_calib_source = calib_source;
|
||||||
if (board->reg_type == ni_reg_611x) {
|
if (devpriv->is_611x) {
|
||||||
ni_writeb(dev, calib_source_adjust,
|
ni_writeb(dev, calib_source_adjust,
|
||||||
Cal_Gain_Select_611x);
|
Cal_Gain_Select_611x);
|
||||||
}
|
}
|
||||||
|
@ -3182,7 +3160,6 @@ static int ni_ao_inttrig(struct comedi_device *dev,
|
||||||
struct comedi_subdevice *s,
|
struct comedi_subdevice *s,
|
||||||
unsigned int trig_num)
|
unsigned int trig_num)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board __maybe_unused = comedi_board(dev);
|
|
||||||
struct ni_private *devpriv = dev->private;
|
struct ni_private *devpriv = dev->private;
|
||||||
struct comedi_cmd *cmd = &s->async->cmd;
|
struct comedi_cmd *cmd = &s->async->cmd;
|
||||||
int ret;
|
int ret;
|
||||||
|
@ -3203,7 +3180,7 @@ static int ni_ao_inttrig(struct comedi_device *dev,
|
||||||
interrupt_b_bits = AO_Error_Interrupt_Enable;
|
interrupt_b_bits = AO_Error_Interrupt_Enable;
|
||||||
#ifdef PCIDMA
|
#ifdef PCIDMA
|
||||||
ni_stc_writew(dev, 1, DAC_FIFO_Clear);
|
ni_stc_writew(dev, 1, DAC_FIFO_Clear);
|
||||||
if (board->reg_type & ni_reg_6xxx_mask)
|
if (devpriv->is_6xxx)
|
||||||
ni_ao_win_outl(dev, 0x6, AO_FIFO_Offset_Load_611x);
|
ni_ao_win_outl(dev, 0x6, AO_FIFO_Offset_Load_611x);
|
||||||
ret = ni_ao_setup_MITE_dma(dev);
|
ret = ni_ao_setup_MITE_dma(dev);
|
||||||
if (ret)
|
if (ret)
|
||||||
|
@ -3271,7 +3248,7 @@ static int ni_ao_cmd(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
|
|
||||||
ni_stc_writew(dev, AO_Disarm, AO_Command_1_Register);
|
ni_stc_writew(dev, AO_Disarm, AO_Command_1_Register);
|
||||||
|
|
||||||
if (board->reg_type & ni_reg_6xxx_mask) {
|
if (devpriv->is_6xxx) {
|
||||||
ni_ao_win_outw(dev, CLEAR_WG, AO_Misc_611x);
|
ni_ao_win_outw(dev, CLEAR_WG, AO_Misc_611x);
|
||||||
|
|
||||||
bits = 0;
|
bits = 0;
|
||||||
|
@ -3397,8 +3374,7 @@ static int ni_ao_cmd(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
unsigned bits;
|
unsigned bits;
|
||||||
devpriv->ao_mode1 &= ~AO_Multiple_Channels;
|
devpriv->ao_mode1 &= ~AO_Multiple_Channels;
|
||||||
bits = AO_UPDATE_Output_Select(AO_Update_Output_High_Z);
|
bits = AO_UPDATE_Output_Select(AO_Update_Output_High_Z);
|
||||||
if (devpriv->is_m_series ||
|
if (devpriv->is_m_series || devpriv->is_6xxx) {
|
||||||
board->reg_type & ni_reg_6xxx_mask) {
|
|
||||||
bits |= AO_Number_Of_Channels(0);
|
bits |= AO_Number_Of_Channels(0);
|
||||||
} else {
|
} else {
|
||||||
bits |=
|
bits |=
|
||||||
|
@ -3541,7 +3517,6 @@ static int ni_ao_cmdtest(struct comedi_device *dev, struct comedi_subdevice *s,
|
||||||
|
|
||||||
static int ni_ao_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
static int ni_ao_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
{
|
{
|
||||||
const struct ni_board_struct *board = comedi_board(dev);
|
|
||||||
struct ni_private *devpriv = dev->private;
|
struct ni_private *devpriv = dev->private;
|
||||||
|
|
||||||
ni_release_ao_mite_channel(dev);
|
ni_release_ao_mite_channel(dev);
|
||||||
|
@ -3571,7 +3546,7 @@ static int ni_ao_reset(struct comedi_device *dev, struct comedi_subdevice *s)
|
||||||
devpriv->ao_trigger_select = 0;
|
devpriv->ao_trigger_select = 0;
|
||||||
ni_stc_writew(dev, devpriv->ao_trigger_select,
|
ni_stc_writew(dev, devpriv->ao_trigger_select,
|
||||||
AO_Trigger_Select_Register);
|
AO_Trigger_Select_Register);
|
||||||
if (board->reg_type & ni_reg_6xxx_mask) {
|
if (devpriv->is_6xxx) {
|
||||||
unsigned immediate_bits = 0;
|
unsigned immediate_bits = 0;
|
||||||
unsigned i;
|
unsigned i;
|
||||||
for (i = 0; i < s->n_chan; ++i)
|
for (i = 0; i < s->n_chan; ++i)
|
||||||
|
@ -5656,7 +5631,7 @@ static int ni_E_init(struct comedi_device *dev,
|
||||||
s->type = COMEDI_SUBD_AI;
|
s->type = COMEDI_SUBD_AI;
|
||||||
s->subdev_flags =
|
s->subdev_flags =
|
||||||
SDF_READABLE | SDF_DIFF | SDF_DITHER | SDF_CMD_READ;
|
SDF_READABLE | SDF_DIFF | SDF_DITHER | SDF_CMD_READ;
|
||||||
if (board->reg_type != ni_reg_611x)
|
if (!devpriv->is_611x)
|
||||||
s->subdev_flags |= SDF_GROUND | SDF_COMMON | SDF_OTHER;
|
s->subdev_flags |= SDF_GROUND | SDF_COMMON | SDF_OTHER;
|
||||||
if (board->adbits > 16)
|
if (board->adbits > 16)
|
||||||
s->subdev_flags |= SDF_LSAMPL;
|
s->subdev_flags |= SDF_LSAMPL;
|
||||||
|
@ -5692,7 +5667,7 @@ static int ni_E_init(struct comedi_device *dev,
|
||||||
s->maxdata = (1 << board->aobits) - 1;
|
s->maxdata = (1 << board->aobits) - 1;
|
||||||
s->range_table = board->ao_range_table;
|
s->range_table = board->ao_range_table;
|
||||||
s->insn_read = &ni_ao_insn_read;
|
s->insn_read = &ni_ao_insn_read;
|
||||||
if (board->reg_type & ni_reg_6xxx_mask)
|
if (devpriv->is_6xxx)
|
||||||
s->insn_write = &ni_ao_insn_write_671x;
|
s->insn_write = &ni_ao_insn_write_671x;
|
||||||
else
|
else
|
||||||
s->insn_write = &ni_ao_insn_write;
|
s->insn_write = &ni_ao_insn_write;
|
||||||
|
@ -5715,7 +5690,7 @@ static int ni_E_init(struct comedi_device *dev,
|
||||||
} else {
|
} else {
|
||||||
s->type = COMEDI_SUBD_UNUSED;
|
s->type = COMEDI_SUBD_UNUSED;
|
||||||
}
|
}
|
||||||
if ((board->reg_type & ni_reg_67xx_mask))
|
if (devpriv->is_67xx)
|
||||||
init_ao_67xx(dev, s);
|
init_ao_67xx(dev, s);
|
||||||
|
|
||||||
/* digital i/o subdevice */
|
/* digital i/o subdevice */
|
||||||
|
@ -5773,7 +5748,7 @@ static int ni_E_init(struct comedi_device *dev,
|
||||||
s->n_chan = 1;
|
s->n_chan = 1;
|
||||||
s->maxdata = 0;
|
s->maxdata = 0;
|
||||||
ni_writel(dev, 0x0, M_Offset_Cal_PWM);
|
ni_writel(dev, 0x0, M_Offset_Cal_PWM);
|
||||||
} else if (board->reg_type == ni_reg_6143) {
|
} else if (devpriv->is_6143) {
|
||||||
/* internal PWM analog output used for AI nonlinearity calibration */
|
/* internal PWM analog output used for AI nonlinearity calibration */
|
||||||
s->subdev_flags = SDF_INTERNAL;
|
s->subdev_flags = SDF_INTERNAL;
|
||||||
s->insn_config = &ni_6143_pwm_config;
|
s->insn_config = &ni_6143_pwm_config;
|
||||||
|
@ -5822,7 +5797,7 @@ static int ni_E_init(struct comedi_device *dev,
|
||||||
|
|
||||||
/* cs5529 calibration adc */
|
/* cs5529 calibration adc */
|
||||||
s = &dev->subdevices[NI_CS5529_CALIBRATION_SUBDEV];
|
s = &dev->subdevices[NI_CS5529_CALIBRATION_SUBDEV];
|
||||||
if (board->reg_type & ni_reg_67xx_mask) {
|
if (devpriv->is_67xx) {
|
||||||
s->type = COMEDI_SUBD_AI;
|
s->type = COMEDI_SUBD_AI;
|
||||||
s->subdev_flags = SDF_READABLE | SDF_DIFF | SDF_INTERNAL;
|
s->subdev_flags = SDF_READABLE | SDF_DIFF | SDF_INTERNAL;
|
||||||
/* one channel for each analog output channel */
|
/* one channel for each analog output channel */
|
||||||
|
@ -5909,7 +5884,7 @@ static int ni_E_init(struct comedi_device *dev,
|
||||||
/* ai configuration */
|
/* ai configuration */
|
||||||
s = &dev->subdevices[NI_AI_SUBDEV];
|
s = &dev->subdevices[NI_AI_SUBDEV];
|
||||||
ni_ai_reset(dev, s);
|
ni_ai_reset(dev, s);
|
||||||
if ((board->reg_type & ni_reg_6xxx_mask) == 0) {
|
if (!devpriv->is_6xxx) {
|
||||||
/* BEAM is this needed for PCI-6143 ?? */
|
/* BEAM is this needed for PCI-6143 ?? */
|
||||||
devpriv->clock_and_fout =
|
devpriv->clock_and_fout =
|
||||||
Slow_Internal_Time_Divide_By_2 |
|
Slow_Internal_Time_Divide_By_2 |
|
||||||
|
@ -5943,7 +5918,7 @@ static int ni_E_init(struct comedi_device *dev,
|
||||||
ni_writeb(dev, devpriv->ai_ao_select_reg, AI_AO_Select);
|
ni_writeb(dev, devpriv->ai_ao_select_reg, AI_AO_Select);
|
||||||
ni_writeb(dev, devpriv->g0_g1_select_reg, G0_G1_Select);
|
ni_writeb(dev, devpriv->g0_g1_select_reg, G0_G1_Select);
|
||||||
|
|
||||||
if (board->reg_type & ni_reg_6xxx_mask) {
|
if (devpriv->is_6xxx) {
|
||||||
ni_writeb(dev, 0, Magic_611x);
|
ni_writeb(dev, 0, Magic_611x);
|
||||||
} else if (devpriv->is_m_series) {
|
} else if (devpriv->is_m_series) {
|
||||||
int channel;
|
int channel;
|
||||||
|
|
|
@ -1209,6 +1209,24 @@ static int pcimio_auto_attach(struct comedi_device *dev,
|
||||||
|
|
||||||
if (board->reg_type & ni_reg_m_series_mask)
|
if (board->reg_type & ni_reg_m_series_mask)
|
||||||
devpriv->is_m_series = 1;
|
devpriv->is_m_series = 1;
|
||||||
|
if (board->reg_type & ni_reg_6xxx_mask)
|
||||||
|
devpriv->is_6xxx = 1;
|
||||||
|
if (board->reg_type == ni_reg_611x)
|
||||||
|
devpriv->is_611x = 1;
|
||||||
|
if (board->reg_type == ni_reg_6143)
|
||||||
|
devpriv->is_6143 = 1;
|
||||||
|
if (board->reg_type == ni_reg_622x)
|
||||||
|
devpriv->is_622x = 1;
|
||||||
|
if (board->reg_type == ni_reg_625x)
|
||||||
|
devpriv->is_625x = 1;
|
||||||
|
if (board->reg_type == ni_reg_628x)
|
||||||
|
devpriv->is_628x = 1;
|
||||||
|
if (board->reg_type & ni_reg_67xx_mask)
|
||||||
|
devpriv->is_67xx = 1;
|
||||||
|
if (board->reg_type == ni_reg_6711)
|
||||||
|
devpriv->is_6711 = 1;
|
||||||
|
if (board->reg_type == ni_reg_6713)
|
||||||
|
devpriv->is_6713 = 1;
|
||||||
|
|
||||||
ret = mite_setup(devpriv->mite);
|
ret = mite_setup(devpriv->mite);
|
||||||
if (ret < 0) {
|
if (ret < 0) {
|
||||||
|
@ -1234,7 +1252,7 @@ static int pcimio_auto_attach(struct comedi_device *dev,
|
||||||
|
|
||||||
if (devpriv->is_m_series)
|
if (devpriv->is_m_series)
|
||||||
m_series_init_eeprom_buffer(dev);
|
m_series_init_eeprom_buffer(dev);
|
||||||
if (board->reg_type == ni_reg_6143)
|
if (devpriv->is_6143)
|
||||||
init_6143(dev);
|
init_6143(dev);
|
||||||
|
|
||||||
irq = pcidev->irq;
|
irq = pcidev->irq;
|
||||||
|
|
|
@ -1491,7 +1491,17 @@ struct ni_private {
|
||||||
struct mite_dma_descriptor_ring *cdo_mite_ring;
|
struct mite_dma_descriptor_ring *cdo_mite_ring;
|
||||||
struct mite_dma_descriptor_ring *gpct_mite_ring[NUM_GPCT];
|
struct mite_dma_descriptor_ring *gpct_mite_ring[NUM_GPCT];
|
||||||
|
|
||||||
|
/* ni_pcimio board type flags (based on the boardinfo reg_type) */
|
||||||
unsigned int is_m_series:1;
|
unsigned int is_m_series:1;
|
||||||
|
unsigned int is_6xxx:1;
|
||||||
|
unsigned int is_611x:1;
|
||||||
|
unsigned int is_6143:1;
|
||||||
|
unsigned int is_622x:1;
|
||||||
|
unsigned int is_625x:1;
|
||||||
|
unsigned int is_628x:1;
|
||||||
|
unsigned int is_67xx:1;
|
||||||
|
unsigned int is_6711:1;
|
||||||
|
unsigned int is_6713:1;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* _COMEDI_NI_STC_H */
|
#endif /* _COMEDI_NI_STC_H */
|
||||||
|
|
Loading…
Reference in New Issue