Staging: comedi: hwdrv_apci3120.c: Checkpatch cleanup
ERROR: do not initialise statics to 0 or NULL
+static unsigned int ui_Temp = 0;
WARNING: braces {} are not necessary for any arm of this statement
+ if (data[1]) {
[...]
+ } else
[...]
WARNING: braces {} are not necessary for single statement blocks
+ for (i = 0; i < devpriv->ui_AiNbrofChannels; i++) {
+ devpriv->ui_AiChannelList[i] = data[4 + i];
+ }
ERROR: that open brace { should be on the previous line
+ } else /* EOC */
+ {
WARNING: braces {} are not necessary for any arm of this statement
+ if (data[1]) {
[...]
+ } else {
[...]
ERROR: that open brace { should be on the previous line
+ if (insn->unused[0] == 222) /* second insn read */
+ {
WARNING: braces {} are not necessary for single statement blocks
+ for (i = 0; i < insn->n; i++) {
+ data[i] = devpriv->ui_AiReadData[i];
+ }
WARNING: braces {} are not necessary for single statement blocks
+ if (cmd->start_src != TRIG_NOW && cmd->start_src != TRIG_EXT) {
+ err++;
+ }
ERROR: that open brace { should be on the previous line
+ if (cmd->scan_begin_src == TRIG_TIMER) /* Test Delay timing */
+ {
ERROR: that open brace { should be on the previous line
+ if (cmd->convert_src == TRIG_TIMER) /* Test Acquisition timing */
+ {
WARNING: braces {} are not necessary for any arm of this statement
+ if (cmd->stop_src == TRIG_COUNT) {
[...]
+ } else {
[...]
WARNING: braces {} are not necessary for single statement blocks
+ if (devpriv->b_ExttrigEnable == APCI3120_ENABLE) {
+ i_APCI3120_ExttrigEnable(dev); /* activate EXT trigger */
+ }
WARNING: braces {} are not necessary for single statement blocks
+ if (dmalen0 > (devpriv->ui_AiDataLength)) {
+ dmalen0 = devpriv->ui_AiDataLength;
+ }
WARNING: braces {} are not necessary for single statement blocks
+ if (dmalen1 > (devpriv->ui_AiDataLength)) {
+ dmalen1 = devpriv->ui_AiDataLength;
+ }
WARNING: braces {} are not necessary for any arm of this statement
+ if (CR_RANGE(chanlist[i]) < APCI3120_BIPOLAR_RANGES) {
[...]
+ } else {
[...]
ERROR: that open brace { should be on the previous line
+ if (devpriv->b_EocEosInterrupt == APCI3120_ENABLE) /* enable this in without DMA ??? */
+ {
ERROR: that open brace { should be on the previous line
+ if (data[0] == APCI3120_TIMER) /* initialize timer */
+ {
ERROR: that open brace { should be on the previous line
+ } else /* Initialize Watch dog */
+ {
ERROR: that open brace { should be on the previous line
+ if (data[0] == 2) /* write new value */
+ {
ERROR: that open brace { should be on the previous line
+ if (devpriv->b_Timer2Mode == APCI3120_TIMER) /* start timer */
+ {
ERROR: that open brace { should be on the previous line
+ } else /* start watch dog */
+ {
ERROR: that open brace { should be on the previous line
+ if (devpriv->b_Timer2Mode == APCI3120_TIMER) /* start timer */
+ {
ERROR: that open brace { should be on the previous line
+ } else /* Read watch dog status */
+ {
WARNING: braces {} are not necessary for single statement blocks
+ if (!devpriv->b_OutputMemoryStatus) {
+ ui_Temp = 0;
+
+ } /* if(!devpriv->b_OutputMemoryStatus ) */
ERROR: code indent should use tabs where possible
+ data[0] Value to be written$
ERROR: code indent should use tabs where possible
+ data[1] :1 Set digital o/p ON$
ERROR: code indent should use tabs where possible
+ data[1] 2 Set digital o/p OFF with memory ON$
ERROR: that open brace { should be on the previous line
+ if (ui_Range) /* if 1 then unipolar */
+ {
ERROR: that open brace { should be on the previous line
+ } else /* if 0 then bipolar */
+ {
ERROR: that open brace { should be on the previous line
+ do /* Waiting of DA_READY BIT */
+ {
Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>