summaryrefslogtreecommitdiff
path: root/drivers/staging
AgeCommit message (Collapse)AuthorFilesLines
2014-05-29staging: comedi: pcl711: use comedi_cmd pointerH Hartley Sweeten1-2/+2
Use a local variable to access the comedi_cmd as a pointer instead of getting to from the comedi_subdevice pointer. 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>
2014-05-29staging: comedi: pcl816: fix DMA 'bytes' calculationH Hartley Sweeten1-3/+1
The calculation for the total number of bytes in the DMA transfer is incorrect. Fix it. 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>
2014-05-29staging: comedi: pcmmio: remove 'continuous' from private dataH Hartley Sweeten1-20/+9
This member of the private data can be determined from the cmd->stop_src. Do that instead and remove the member. Refactor pcmmio_handle_dio_intr() to remove an indent level. For aesthetics, change the switch in pcmmio_cmd() to an if/else. 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>
2014-05-29staging: comedi: pcmmio: use comedi_cmd pointerH Hartley Sweeten1-3/+3
Use a local variable to access the comedi_cmd as a pointer instead of getting to from the comedi_subdevice pointer. Remove the unnecessary local variables used for the cmd->chanlist_len. 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>
2014-05-29staging: comedi: pcmuio: tidy up local variables in pcmuio_handle_intr_subdev()H Hartley Sweeten1-3/+3
Tidy up the local variables so that the comedi_cmd is accessed as a pointer instead of getting to it from the comedi_subdevice pointer. Remove the local variable 'len' and use the cmd->chanlist_len directly. 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>
2014-05-29staging: comedi: usbduxsigma: use comedi_cmd pointerH Hartley Sweeten1-1/+1
Use the local variable to access the comedi_cmd as a pointer instead of getting to it from the comedi_subdevice pointer. 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>
2014-05-29staging: comedi: ni_65xx: remove commented out local variableH Hartley Sweeten1-1/+0
This function does not use the comedi_cmd. Remove the commented out local variable. 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>
2014-05-29staging: comedi: mite: tidy up local variables in mite_sync_output_dma()H Hartley Sweeten1-8/+6
Tidy up the local variables so that the comedi_cmd is accessed as a pointer instead of getting to it from the comedi_async pointer. 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>
2014-05-29staging: comedi: das1800: use comedi_cmd pointerH Hartley Sweeten1-1/+1
Use the local variable to access the comedi_cmd as a pointer instead of getting to it from the comedi_subdevice pointer. 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>
2014-05-29staging: comedi: cb_pcidas: use comedi_cmd pointerH Hartley Sweeten1-4/+6
Use the local variable to access the comedi_cmd as a pointer instead of getting to it from the comedi_async pointer. 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>
2014-05-29staging: comedi: amplc_pci230: use comedi_cmd pointerH Hartley Sweeten1-3/+3
Use the local variable to access the comedi_cmd as a pointer in pci230_handle_ai() instead of getting to it from the comedi_async pointer. 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>
2014-05-29staging: comedi: amplc_pci224: use comedi_cmd pointerH Hartley Sweeten1-2/+2
Use the local variable to access the comedi_cmd as a pointer in pci224_ao_munge() instead of getting to it from the comedi_async pointer. 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>
2014-05-29staging: comedi: amplc_dio200_common: use comedi_cmd pointerH Hartley Sweeten1-4/+3
Use the local variable to access the comedi_cmd as a pointer in dio200_read_scan_intr() instead of getting to it from the comedi_subdevice pointer. Remove the unnecessary local variable 'len', this is just the cmd->chanlist_len. 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>
2014-05-29staging: comedi: das800: remove 'forever' from private dataH Hartley Sweeten1-10/+9
This member of the private data can be determined from the cmd->stop_src. Do that instead. 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>
2014-05-29staging: comedi: das800: add a local var for the comedi_cmd pointerH Hartley Sweeten1-7/+8
For aesthetics, use a local variable to access the comedi_cmd as a pointer in das800_ai_do_cmd() instead of getting to it from the comedi_async pointer. 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>
2014-05-29staging: comedi: usbduxsigma: remove 'ao_chanlist' from private dataH Hartley Sweeten1-9/+3
This member of the private data is just a copy of the channels from the cmd->chanlist. Remove the member and just use the cmd->chanlist directly. Remove the unneeded 'len' local variable in usbduxsigma_ao_urb_complete(). This is just the cmd->chanlist_len. 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>
2014-05-29staging: comedi: usbdux: use 'cmd' pointer in usbduxsub_ai_isoc_irq()H Hartley Sweeten1-4/+3
Use the 'cmd' pointer to access the chanlist instead of getting to it using the comedi_subdevice pointer. Remove the unneeded 'n' local variable, this is just the cmd->chanlist_len. 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>
2014-05-29staging: comedi: usbdux: remove 'ao_chanlist' from private dataH Hartley Sweeten1-10/+3
This member of the private data is just a copy of the channels from the cmd->chanlist. Remove the member and just use the cmd->chanlist directly. Remove the unneeded 'len' local variable in usbdux_ao_isoc_irq(). This is just the cmd->chanlist_len. 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>
2014-05-29staging: comedi: usbduxsigma: remove 'ao_continuous' from private dataH Hartley Sweeten1-4/+2
This member of the private data can be determined from the cmd->stop_src. Do that instead. 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>
2014-05-29staging: comedi: usbduxsigma: remove 'ai_continuous' from private dataH Hartley Sweeten1-4/+2
This member of the private data can be determined from the cmd->stop_src. Do that instead. 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>
2014-05-29staging: comedi: usbduxfast: remove 'ai_continuous' from private dataH Hartley Sweeten1-4/+2
This member of the private data can be determined from the cmd->stop_src. Do that instead. 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>
2014-05-29staging: comedi: usbdux: remove 'ao_continuous' from private dataH Hartley Sweeten1-4/+2
This member of the private data can be determined from the cmd->stop_src. Do that instead. 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>
2014-05-29staging: comedi: usbdux: remove 'ai_continuous' from private dataH Hartley Sweeten1-4/+2
This member of the private data can be determined from the cmd->stop_src. Do that instead. 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>
2014-05-29staging: comedi: addi_apci_3xxx: use comedi_fc helpers to validate timer argH Hartley Sweeten1-6/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger argument when the source is TRIG_TIMER. For aesthetics, rename the local variable 'tmp' to 'arg'. 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>
2014-05-29staging: comedi: skel: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-17/+12
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. Use cfc_check_trigger_arg_min() to vaidate the scan_begin_arg when the scan_begin_src and convert_src are both TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: s626: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-20/+16
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. Use cfc_check_trigger_arg_min() to vaidate the scan_begin_arg when the scan_begin_src and convert_src are both TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. Change the type of the first parameter to s626_ns_to_timer() to remove the need for the casts. 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>
2014-05-29staging: comedi: rtd520: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-19/+13
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. Use cfc_check_trigger_arg_min() to vaidate the scan_begin_arg when the scan_begin_src and convert_src are both TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: quatech_daqp_cs: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-11/+7
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: pcl818: use comedi_fc helpers to validate timer argH Hartley Sweeten1-7/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger argument when the source is TRIG_TIMER. The minimum test is not needed, this was already validated in Step 3. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: pcl816: use comedi_fc helpers to validate timer argH Hartley Sweeten1-7/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger argument when the source is TRIG_TIMER. The minimum test is not needed, this was already validated in Step 3. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: pcl812: use comedi_fc helpers to validate timer argH Hartley Sweeten1-7/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger argument when the source is TRIG_TIMER. The minimum test is not needed, this was already validated in Step 3. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: pcl711: use comedi_fc helpers to validate timer argH Hartley Sweeten1-6/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger argument when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: ni_pcidio: use comedi_fc helpers to validate timer argH Hartley Sweeten1-6/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger argument when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: ni_at_a2150: use comedi_fc helpers to validate timer argH Hartley Sweeten1-5/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger argument when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: dt282x: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-10/+8
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: dt2814: use comedi_fc helpers to validate timer argH Hartley Sweeten1-5/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger argument when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: dmm32at: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-17/+12
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. Use cfc_check_trigger_arg_min() to vaidate the scan_begin_arg when the scan_begin_src and convert_src are both TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: das800: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-6/+4
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: das16m1: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-6/+5
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. For aesthetics, rename the local variable 'tmp' to 'arg'. Also, change the 'err' variable to the correct type. 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>
2014-05-29staging: comedi: das16: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-17/+15
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. Tidy up the local varaibles in the function. 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>
2014-05-29staging: comedi: comedi_test: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-13/+9
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: cb_pcidas: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-14/+11
Use the comedi_fc helper cfc_check_trigger_arg_is() to validate the trigger arguments when the source is TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: adl_pci9118: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-30/+15
Use the comedi_fc helper, cfc_check_trigger_arg_is(), to validate the arguments for the TRIG_TIMER command sources. Pass the local variable to i8253_cascade_ns_to_timer() instead of the cmd argument. This value is modified by that function to return the actual time (in nanoseconds) that the timer will be programmed with based on the calculated divisors. The cfc_check_trigger_arg_is() helper will then validate that the argument is that value and modify it if not. Use cfc_check_trigger_arg_min() to do validate the cmd->scan_begin_arg when the scan_begin_src is TRIG_TIMER and the convert_src is TRIG_NOW. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: dt3000: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-17/+12
Use the comedi_fc helper, cfc_check_trigger_arg_is(), to validate the cmd->scan_begin_arg for the scan_begin_src TRIG_TIMER. Pass the local variable to dt2k_ns_to_timer() instead of the cmd argument. This value is modified by that function to return the actual time (in nanoseconds) that the timer will be programmed with based on the calculated divisor. The cfc_check_trigger_arg_is() helper will then validate that the cmd->cscan_begin_arg is that value and modify it if not. Also use cfc_check_trigger_arg_is() to validate the cmd->convert_arg using the same logic. Use cfc_check_trigger_arg_min() to do validate the cmd->scan_begin_arg when the convert_src and scan_begin_src are both TRIG_TIMER. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons. 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>
2014-05-29staging: comedi: adv_pci1710: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-7/+4
Use the comedi_fc helper, cfc_check_trigger_arg_is(), to validate the cmd->convert_arg for the convert_src TRIG_TIMER. Pass the local variable to i8253_cascade_ns_to_timer() instead of the cmd argument. This value is modified by that function to return the actual time (in nanoseconds) that the timer will be programmed with based on the calculated divisors. The cfc_check_trigger_arg_is() helper will then validate that the cmd->convert_arg is that value and modify it if not. The minimum validation is not needed. That was already handled in Step 3. All the arguments are unsigned int, change the local variable to an unsigned int and rename it for aesthetic reasons.. 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>
2014-05-29staging: comedi: adl_pci9111: use comedi_fc helpers to validate timer argsH Hartley Sweeten1-7/+3
Use the comedi_fc helper, cfc_check_trigger_arg_is(), to validate the cmd->convert_arg for the convert_src TRIG_TIMER. Pass the local variable to i8253_cascade_ns_to_timer() instead of the cmd argument. This value is modified by that function to return the actual time (in nanoseconds) that the timer will be programmed with based on the calculated divisors. The cfc_check_trigger_arg_is() helper will then validate that the cmd->convert_arg is that value and modify it if not. Also use cfc_check_trigger_arg_is() to validate that the cmd->scan_begin_arg is the calculate value and modify it if not. 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>
2014-05-29staging: comedi: TODO: remove item "reserve major number"H Hartley Sweeten1-1/+0
The major number for comedi has been listed in Documentation/devices.txt since kernel 2.1.88. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-29Staging: comedi: addi-data: clean up formatting of the else statementMarcin Kostrzewa1-5/+1
Signed-off-by: Marcin Kostrzewa <marckostrzewa@gmail.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-29Revert "staging: rtl8192u: rename CONFIG_IEEE80211_CRYPT_TKIP"Greg Kroah-Hartman2-2/+2
This reverts commit f8cc81f845456c126fd0ab4d8379a8c47f5ca743. It breaks the build in linux-next. Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Cc: Paul Bolle <pebolle@tiscali.nl> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-29staging: vt6655: refactor iwctl_giwaplist() to avoid -Wframe-larger-than warn.Konrad Zapalowicz1-24/+48
This commit refactors the iwctl_giwaplist() function so that the sparse warning "the frame size of 1292 bytes is larger than 1024 bytes [-Wframe-larger-than=]" is no more. The root cause of this warning were two arrays allocated on the stack and this commit changes this - these arrays are now kmalloc'ed. As a result the function is refactored and hopefully stil working the same. I were not able to test these changes so at least the carefull review is more than welcomed. Note that my changes has broadened the set of error codes that this function can return. The new error code is ENOMEM. Luckily, this is no issue. Signed-off-by: Konrad Zapalowicz <bergo.torino@gmail.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>