summaryrefslogtreecommitdiffstats
path: root/drivers/staging/comedi
Commit message (Collapse)AuthorAgeFilesLines
* staging: comedi: s626: fix value written by s626_set_dac()Ian Abbott2013-11-251-1/+1
| | | | | | | | | | | | | | | | I broke `s626_set_dac()` by changing the type of the `dacdata` parameter from `short` to `unsigned short`. It's actually designed to take a signed value in the range -0x1fff to +0x2000 although values above 0x1fff get clamped to 0x1fff. (We could change the `maxdata` value to 0x1ffe to avoid the clamping, but `maxdata` values are usually a power of 2 minus 1.) The bug results in all negative values passed to the function being changed to +0x1fff by the clamp. Change the parameter type to `int16_t` to fix the problem. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Cc: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: comedi: pcl730: fix some bitwise vs logical AND bugsDan Carpenter2013-11-251-3/+3
| | | | | | | | | | These conditions are never true because they use bitwise AND instead of logical ands. Fixes: b3ff824a81e8 ('staging: comedi: drivers: use comedi_dio_update_state() for complex cases') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: comedi: fix potentially uninitialised variableMichal Nazarewicz2013-11-251-1/+1
| | | | | | | | If none of the if conditions take a true path, the ret variable will never be assigned a value. Signed-off-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Merge branch 'for-linus' of ↵Linus Torvalds2013-11-131-3/+0
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs Pull vfs updates from Al Viro: "All kinds of stuff this time around; some more notable parts: - RCU'd vfsmounts handling - new primitives for coredump handling - files_lock is gone - Bruce's delegations handling series - exportfs fixes plus misc stuff all over the place" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (101 commits) ecryptfs: ->f_op is never NULL locks: break delegations on any attribute modification locks: break delegations on link locks: break delegations on rename locks: helper functions for delegation breaking locks: break delegations on unlink namei: minor vfs_unlink cleanup locks: implement delegations locks: introduce new FL_DELEG lock flag vfs: take i_mutex on renamed file vfs: rename I_MUTEX_QUOTA now that it's not used for quotas vfs: don't use PARENT/CHILD lock classes for non-directories vfs: pull ext4's double-i_mutex-locking into common code exportfs: fix quadratic behavior in filehandle lookup exportfs: better variable name exportfs: move most of reconnect_path to helper function exportfs: eliminate unused "noprogress" counter exportfs: stop retrying once we race with rename/remove exportfs: clear DISCONNECTED on all parents sooner exportfs: more detailed comment for path_reconnect ...
| * file->f_op is never NULL...Al Viro2013-10-241-3/+0
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* | staging: comedi: s626: replace S626_MULT_X? valuesIan Abbott2013-10-292-25/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace the use of the `S626_MULT_X1`, `S626_MULT_X2` and `S626_MULT_X4` clock multiplier values with the equivalent `S626_CLKMULT_1X`, `S626_CLKMULT_2X` and `S626_CLKMULT_4X` values to avoid duplication. Replace the use of `S626_MULT_X0` with a new macro `S626_CLKMULT_SPECIAL` (this is treated specially by the 'ClkMultA'/'ClkMultB' field of the 'CRA'/'CRB' register). Remove the now unused `S626_MULT_X?` macros. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: remove S626_BF_* macrosIan Abbott2013-10-291-9/+0
| | | | | | | | | | | | | | | | | | | | The `S626_BF_*` bitfield position macros are no longer used and are just a subset of the corresponding `S626_STDBIT_*` bitfield position macros. Remove them. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: expand standardized IndxSrc valuesIan Abbott2013-10-292-15/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'IndxSrc' value for the standardized encoder setup is currently 1 bit wide and takes one of the following values: S626_INDXSRC_HARD = 0 // index source from hardware encoder S626_INDXSRC_SOFT = 1 // index source software controlled by IndxPol However the hardware 'IndxSrcA' and 'IndxSrcB' values for the 'A' and 'B' counters are 2 bits wide. The above standardized values 0 and 1 correspond to the hardware values 0 and 2. In order to simplify conversions between the standardized values and hardware values, expand the range of standardized values to cover all four possible values. The new values are as follows: S626_INDXSRC_ENCODER = 0 // index source from hardware encoder S626_INDXSRC_DIGIN = 1 // index source from digital inputs S626_INDXSRC_SOFT = 2 // index source s/w controlled by IndxPol S626_INDXSRC_DISABLED = 2 // index source disabled (Note the change in value for `S626_INDXSRC_SOFT` and the replacement of `S626_INDXSRC_HARD` with `S626_INDXSRC_ENCODER` for consistency with the `CntSrc` values.) Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: make CRA and CRB setup conversions more readableIan Abbott2013-10-291-166/+151
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use the new macros defined in "s626.h" for constructing and decomposing 'CRA', 'CRB' and standardized encoder setup values to make the conversions between standardized encoder setup values, and CRA/CRB register values easier to follow. There is some messing about with the 'IndxSrc' values which are 1-bit wide in the standardized encoder setup, and 2-bit wide in the 'CRA' and 'CRB' register values. This will be addressed by a later patch. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: adl_pci9118: fix a misaligned commentIan Abbott2013-10-291-1/+1
| | | | | | | | | | | | | | | | As pointed out by Hartley Sweeten, one of my recent patches resulted in the start of a multi-line comment ending up misaligned. Fix it. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: use memdup_user to simplify codeTeodora Baluta2013-10-291-23/+10
| | | | | | | | | | | | | | | | | | | | | | Use memdup_user rather than duplicating implementation. Fix following coccinelle warnings: drivers/staging/comedi/comedi_fops.c:1425:5-12: WARNING opportunity for memdup_user drivers/staging/comedi/comedi_fops.c:1553:6-13: WARNING opportunity for memdup_user Signed-off-by: Teodora Baluta <teobaluta@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: bitfield manipulation macros for CRA, CRB and setupIan Abbott2013-10-191-41/+212
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some bits of the 'CRB' register have different functions when read or written, so add macros to define the read-only parts. Add macros to define the widths of the bitfields in the 'CRA' and 'CRB' registers and the standard encoder setup value. Add macros to construct and extract parts of the 'CRA' and 'CRB' register values and the standard encoder setup value, along with a couple of general helper macros for the above. Redefine the bitfield mask macros for 'CRA', 'CRB' and standard encoder setup using the above. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: add missing bits for 'CRB' registerIan Abbott2013-10-191-3/+11
| | | | | | | | | | | | | | | | | | | | | | | | There are some bits in the 'CRB' register not defined in "s626.h". Three of these are read-only bits that overlay the write-only interrupt control bits. Another missing bit controls whether counter 'B' is cleared when counter 'A' overflows. Add the missing bit definitions for completeness. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: correct S626_CRAMSK_CLKPOL_A macro (unused)Ian Abbott2013-10-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | The counter 'A' clock polarity field in the 'CRA' register is only 1 bit wide, but the `S626_CRAMSK_CLKPOL_A` macro shows it as 2 bits wide, which would overlap with the counter 'A' interrupt source field. This is harmless as the macro isn't actually used yet, but correct it anyway as I want to use it! Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: distinguish counter src from encoder modeIan Abbott2013-10-192-61/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The macros `S626_CLKSRC_COUNTER`, `S626_CLKSRC_TIMER` and `S626_CLKSRC_EXTENDER` are used logically to set the operating mode of an encoder channel. `S626_CLKSRC_COUNTER` (0) is also used as a 2-bit physical value to set the counter source of an encoder channel to "encoder". Rename the macros to `S626_ENCMODE_COUNTER`, `S626_ENCMODE_TIMER` and `S626_ENCMODE_EXTENDER` and rename some other macros and (unused) functions relating to the encoder mode for consistency. Define new macros to specify the physical counter source values for the 'CRA' register and rename the corresponding bitshift and mask macros accordingly. The physical values for the counter source are: S626_CNTSRC_ENCODER = 0 // encoder S626_CNTSRC_DIGIN = 1 // digital inputs S626_CNTSRC_SYSCLK = 2 // system clock up S626_CNTSRC_SYSCLK_DOWN = 3 // system clock down Also use the `S626_CNTSRC_SYSCLK` value as a bitmask (bit 1) to indicate either of the system clock values, with the direction (bit 0) indicated separately in this case. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: correct a comment in s626_get_mode_b()Ian Abbott2013-10-191-1/+1
| | | | | | | | | | | | Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: specify bitshift for encoder A clock sourceIan Abbott2013-10-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | When setting the clock source for one of the 'A' encoders to operate in "counter" mode in `s626_set_mode_a()`, bitshift the clock source value by `S626_CRABIT_CLKSRC_A` for consistency with the other modes. This has no effect on the value since `S626_CRABIT_CLKSRC_A` is 0. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: clock polarity and direction are the sameIan Abbott2013-10-191-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When setting up an encoder channel, the setup value includes a polarity and direction, but these are the same bit of the setup value: S626_CLKPOL_POS = S626_CNTDIR_UP = 0 S626_CLKPOL_NEG = S626_CNTDIR_DOWN = 1 In the construction of the setup value, both the CLKPOL and the CNTDIR constants are shifted by the same amount `S626_BF_CLKPOL`. Only the following combinations are set up currently (this may change if user configuration of the encoder is implemented properly): (S626_CLKPOL_POS << S626_BF_CLKPOL) (S626_CLKPOL_POS << S626_BF_CLKPOL) | (S626_CNTDIR_UP << S626_BF_CLKPOL) (S626_CLKPOL_POS << S626_BF_CLKPOL) | (S626_CNTDIR_DOWN << S626_BF_CLKPOL) The first two are used in "counter" mode and is equivalent to: (S626_CLKPOL_POS << S626_BF_CLKPOL) The last one is used in "timer" mode and is equivalent to: (S626_CNTDIR_DOWN << S626_BF_CLKPOL) Use the shorter equivalents. The comments in "s626.h" indicate that the 'CLKPOL' constants make more sense for the "counter" mode (when the encoders operate as up/down counters) and the 'CNTDIR' constants make more sense for the "timer" mode. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: rtd520: use normal bitfield functionsIan Abbott2013-10-191-20/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `unsigned char chan_is_bipolar[]` member of `struct rtd_private` is used with some macros as a packed array of 1-bit values that indicate whether the corresponding entries in the hardware's "channel-gain" table have been set to a bipolar (1) or unipolar (0) range, as the raw samples from the hardware need to be cooked differently in each case. Replace the declaration of the member with a standard Linux bitfield using `DECLARE_BITFIELD()`, and replace the home-grown macros used access the bitfield with the standard Linux non-atomic bitop functions, `__set_bit()`, `__clear_bit()` and `test_bit()`. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: usbduxsigma: sample types are unsignedIan Abbott2013-10-161-10/+10
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Use unsigned types consistently for handling comedi sample data and also for the USB data buffers. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: usbdux: sample types are unsignedIan Abbott2013-10-161-17/+18
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Use unsigned types consistently for handling comedi sample data and also for the USB data buffers. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: s626: sample types are unsignedIan Abbott2013-10-161-15/+7
| | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Use unsigned types consistently in the "s626" module when dealing with sample values. Rewrite `s626_reg_to_uint()` as it can be done with a one-liner. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: rtd520: sample types are unsignedIan Abbott2013-10-161-18/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Use unsigned types for sample value manipulations in the "rtd520" driver for consistency. Also replace the hand-coded munging of 2's complement sample values with calls to `comedi_offset_munge()` and AND with `s->maxdata` to strip off any extra sign bits. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: quatech_daqp_cs: sample types are unsignedIan Abbott2013-10-161-2/+1
| | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change `daqp_interrupt()` to use unsigned sample values for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: pcmuio: sample types are unsignedIan Abbott2013-10-161-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change `pcmuio_handle_intr_subdev()` in the "pcmuio" module to use unsigned sample values for consistency. Also, make the order in which `pcmuio_handle_intr_subdev()` writes the two sample values (each actually containing up to 16 1-bit sample values) independent of the host byte ordering. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: pcmmio: sample types are unsignedIan Abbott2013-10-161-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change `interrupt_pcmmio()` and `ai_rinsn()` in the "pcmmio" module to use unsigned sample values for consistency. Also, make the order in which `interrupt_pcmmio()` writes the two sample values (each actually containing up to 16 1-bit sample values) independent of the host byte ordering. Note that this module is a mess, so please excuse the checkpatch warnings. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: pcl818: sample types are unsignedIan Abbott2013-10-161-6/+5
| | | | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the interrupt data transfer functions in the "pcl818" module to use unsigned types for consistency. Also remove the `short *ai_data` member of `struct pcl818_private` as it is only assigned to and otherwise unused. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: pcl816: sample types are unsignedIan Abbott2013-10-161-5/+7
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the "pcl816" module to use unsigned types to handle samples for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: pcl812: sample types are unsignedIan Abbott2013-10-161-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change `transfer_from_dma_buf()` and `interrupt_pcl812_ai_dma()` in the "pcl812" module to use `unsigned short` sample values for consistency. Also remove the `short *ai_data` member of `struct pcl812_private` as it is only assigned to. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: pcl711: sample types are unsignedIan Abbott2013-10-161-1/+1
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Don't cast the sample value parameter of `comedi_buf_put()` to `short`, particularly as it has now been changed to `unsigned short`. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: ni_pcidio: sample types are unsignedIan Abbott2013-10-161-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change `nidio_interrupt()` to use unsigned types for sample values (actually bit-vectors of 1-bit sample values) instead of signed types. Also rename the `AuxData` variable to `auxdata` and change it from `long` to `unsigned int` as it only needs to hold a 32-bit value. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: ni_mio_common: sample types are unsignedIan Abbott2013-10-162-10/+10
| | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the element type of the `ai_fifo_buffer[]` element of `struct ni_board_struct` and the types of various local variables from `short` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: ni_labpc: sample types are unsignedIan Abbott2013-10-161-1/+1
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the type of the `data` variable in `labpc_ai_cmd()` from `short` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: ni_at_a2150: sample types are unsignedIan Abbott2013-10-161-2/+2
| | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented by unsigned values. Change the type of the `dma_buffer` member of `struct a2150_private` from `s16 *` to `uint16_t *`, and change the type of the `dpnt` variable in `a2150_interrupt()` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: me4000: sample types are unsigned (and not long!)Ian Abbott2013-10-161-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the types of various variables in the "me4000" driver dealing with samples to use unsigned types for consistency. Also replace the `long` or `unsigned long` variables used to handle 32-bit register values to `unsigned int`. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: icp_multi: sample types are unsignedIan Abbott2013-10-161-3/+1
| | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the element type of the `ao_data[]` member of `struct icp_multi_private` from `short` to `unsigned short` for consistency. Also remove the `ai_data` and `di_data` members as they are not used. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: fl512: sample types are unsignedIan Abbott2013-10-161-2/+1
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the element type of the `ao_readback[]` member of `struct fl512_private` from `short` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: dt3000: sample types are unsignedIan Abbott2013-10-161-1/+1
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the type of the `data` variable in `dt3k_ai_empty_fifo()` from `short` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: dt282x: sample types are unsignedIan Abbott2013-10-161-6/+6
| | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change various members of `struct dt282x_private` and various parameters and variables dealing with samples to use `unsigned short` instead of `short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: das1800: sample types are unsignedIan Abbott2013-10-161-4/+5
| | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented by unsigned values. Change the type of the `ao_update_bits` member of `struct das1800_private` and the types of various local variables used to hold sample values from `short` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: das16m1: sample types are unsignedIan Abbott2013-10-161-3/+3
| | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the element type of the `ai_buffer[]` member of `struct das16m1_private_struct` and the types used by `munge_sample()` and `munge_sample_array()` from `short` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: das16: sample types are unsignedIan Abbott2013-10-161-1/+1
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the type of the `data` variable in `das16_ai_munge()` from `short *` to `unsigned short *` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: cb_pcidas64: sample types are unsignedIan Abbott2013-10-161-1/+1
| | | | | | | | | | | | | | | | | | Sample values in comedi are unsigned. Change the element type of `ao_bounce_buffer[]` in `struct pcidas64_private` from `short` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: cb_pcidas: sample types are unsignedIan Abbott2013-10-161-3/+3
| | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented by unsigned values. Change the element types of `ai_buffer[]`, `ao_buffer[]` and `ao_value[]` in `struct cb_pcidas_private` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: amplc_pci230: sample types are unsignedIan Abbott2013-10-161-10/+11
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Replace all uses of `short` to handle sample values in the "amplc_pci230" driver with `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: amplc_pci224: sample types are unsignedIan Abbott2013-10-161-2/+2
| | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the type of the `ao_scan_vals` member of `struct pci224_private` from `short *` to `unsigned short *` for consistency. Also change the type of the `array` variable in `pci224_ao_munge()` from `short *` to `unsigned short *`. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: adv_pci1723: sample types are unsignedIan Abbott2013-10-161-1/+1
| | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the element type of the `ao_data[]` member of `struct pci1723_private` from `short` to `unsigned short` for consistency. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: adv_pci1710: sample types are unsignedIan Abbott2013-10-161-5/+3
| | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the element type of the `ao_data[]` member of `struct pci1710_private` from `short` to `unsigned short` for consistency. Also remove the `ai_data` member as it is only assigned to. Change various local variables used to hold sample values to `unsigned short`. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: adl_pci9118: sample types are unsignedIan Abbott2013-10-161-10/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the `ao_data[]` and `dmabuf_virt[]` members of `struct pci9118_private` and various local variables dealing with sample values to use `unsigned short` instead of `short` for consistency. Also remove the `short *ai_data` member of `struct pci9118_private` as it is only assigned to. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* | staging: comedi: adl_pci9111: sample types are unsignedIan Abbott2013-10-161-2/+2
| | | | | | | | | | | | | | | | | | | | | | Sample values in comedi are generally represented as unsigned values. Change the element type of the `ai_bounce_buffer[]` member of `struct pci9111_private_data` from `short` to `unsigned short` for consistency. Also change the type of the `array` variable in `pci9111_ai_munge()` from `short *` to `unsigned short *`. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
OpenPOWER on IntegriCloud