Commit Graph

429103 Commits

Author SHA1 Message Date
Ken Cox
a1d842e84f Staging: unisys: channels: Cleanup sparse warnings
Clean up multiple sparse warnings mostly due to different address spaces
when accessing I/O memory.

Also, remove SignalRemoveAll(), SignalQueueHasOneElement(),
SignalQueueIsFull(), because they were never called.

Signed-off-by: Ken Cox <jkc@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:42:40 -07:00
Daeseok Youn
4b4b535e64 staging: unisys: remove incorrect error handling after queue_delayed_work
The queue_delayed_work() return false if the work is
already on the queue, true otherwise.
So return value cannot be less than zero.

Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:42:40 -07:00
Daeseok Youn
93c76c9c1d staging: dgnc: replace unnecessary while() with if()
It doesn't need to use while loop for getting newrate,
because it always breaks out the end of while loop with
"break". So just replace while with if.

And the type of newrate is "unsigned int", this type
is never less than zero. If it can be set to negative value by
user application with ioctl(), it is not zero but it
can be a unexpected value for setting custom baudrate.

Also smatch says:
drivers/staging/dgnc/dgnc_tty.c:967 dgnc_set_custom_speed() warn:
 unsigned 'newrate' is never less than zero.
drivers/staging/dgnc/dgnc_tty.c:981 dgnc_set_custom_speed() info:
 ignoring unreachable code.

Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:37:46 -07:00
Mark Hounschell
c0c31b9b2a staging: dgap: Add a pr_info per board info
This patch adds a pr_info per board that indicates
board number, type, etc..

Signed-off-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:35:44 -07:00
Mark Hounschell
bd3e43e5f0 staging: dgap: remove more unneeded brd-state states
This patch removes more unneeded brd-state states

Signed-off-by: Mark Hounschell <markh@compro.net>
Tested-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:35:43 -07:00
Mark Hounschell
b2e78c2440 staging: dgap: remove unused brd->state states
This patch removes unused brd->state states previously
used in the userland firmware download process.

Signed-off-by: Mark Hounschell <markh@compro.net>
Tested-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:35:43 -07:00
Mark Hounschell
74f71e7175 staging: dgap: remove unneeded dgap_driver_states
The only driver states we need now is READY or !READY.
No need for a sysfs method of seeing those 2 states so
the sysfs entries for dgap_driver_state is also removed.

Signed-off-by: Mark Hounschell <markh@compro.net>
Tested-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:35:43 -07:00
Mark Hounschell
211568d000 staging: dgap: Replace/remove DGAP_SPINLOCK_INIT macro
This patch gets rid of the DGAP_SPINLOCK_INIT macro

Signed-off-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:33:35 -07:00
Mark Hounschell
339db3a32b staging: dgap: Remove unused DGAP_TRYLOCK macro
This patch removes  the unused DGAP_TRYLOCK macro

Signed-off-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:33:35 -07:00
Mark Hounschell
928d70bb1e staging: dgap: Remove unneeded code from dgap.c
This patch removes more unneeded code that was
supporting the old firmware loading process

Signed-off-by: Mark Hounschell <markh@compro.net>
Tested-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:33:34 -07:00
Mark Hounschell
abbdd11ac3 staging: dgap: remove some unused defines in dgap.h
This patch removes some unused defines in dgap.h

Signed-off-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:33:34 -07:00
Mark Hounschell
93fb1e256a staging: dgap: fix a few more 80+ char lines (02/02)
This patch fixes a few more 80+ char lines as reported by checkpatch

Signed-off-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:32:03 -07:00
Mark Hounschell
84e88287d8 staging: dgap: fix a few more 80+ char lines (01/02)
This patch fixes a few more 80+ char lines as reported by checkpatch

Signed-off-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:32:03 -07:00
Mark Hounschell
70d97a616f staging: dgap: fix a few 80+ char lines
This patch fixes a few 80+ char lines
as reported by checkpatch

Signed-off-by: Mark Hounschell <markh@compro.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:31:47 -07:00
Malcolm Priestley
6ae4663342 staging: vt6656: [BUG] set usb_fill_int_urb interval to 1
As result of patch
staging: vt6656: [BUG] Fix Warning BOGUS urb xfer, pipe 3 != type 1

has resulted in sluggish TX performance due to interupt inverval
being too long.

Set int_interval to 1 as set in bInterval of endpoint 1.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:29:50 -07:00
Gary Rookard
d4b54fb74f Staging: lustre: fld: fix split strings.
unsplit strings from two lines to one. Changes resulted
in line over 80 characters warning. Leaving the latter
of the two warnings for possible string grepping reasons.

Signed-off-by: Gary Alan Rookard <garyrookard@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:24:35 -07:00
Gary Rookard
238bbffb99 Staging: lustre: fld: fix spacing issue.
fixed up a spacing issue.

Signed-off-by: Gary Alan Rookard <garyrookard@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:24:35 -07:00
Gary Rookard
fdb59a46c6 Staging: lustre: fld: fix split string.
unsplit string from two lines to one.

Signed-off-by: Gary Alan Rookard <garyrookard@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:24:35 -07:00
Gary Rookard
5cbcd111f0 Staging: lustre: fid: fix split strings.
unsplit strings from two lines to one.

Signed-off-by: Gary Alan Rookard <garyrookard@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:24:35 -07:00
Daeseok Youn
5ddd113297 staging: cxt1e1: remove redundant memset() call
The banner array doens't need to set to 0.
sprintf() adds a terminating '\0'.

And the sn array can be declared and initialized to zero.
So remove redundant memset() with zero.

Remove unnecessary cast for memcpy().

Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:22:47 -07:00
Daeseok Youn
14eec44430 staging: cxt1e1: remove redundant memset() call
The name array doens't need to set to 0. Because
sprintf/snprintf adds a terminating '\0'.

And also it doesn't need to assign name array
address to np pointer.

Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:22:47 -07:00
Monam Agarwal
b0a0fb1e29 Staging: slicoss: Replace macro with inline defination in slicoss.c
This patch moves the macro "SLIC_GET_SLIC_HANDLE(_adapter, _pslic_handle)" to inline
in slicoss.c since it has been used only once.

Signed-off-by: Monam Agarwal <monamagarwal123@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-17 14:21:25 -07:00
H Hartley Sweeten
79e5e6addb staging: comedi: das6402: rewrite broken driver
This driver is _really_ broken.

It initializes an analog input subdevice that only has a (*cancel)
function. It also does a request_irq() to hookup an interrupt handler
using it->options[0] as the IRQ. This option is actually the base
address of the I/O region used by the board. If the interrupt handler
actually did get hooked up, the rest of the code assumes that IRQ 10
is being used.

Rewrite the driver to properly support the hardware.

The DAS6402-12/16 boards have 64 single-ended / 32 differential analog
inputs, 2 analog outputs, 8 digital inputs, and 8 digital outputs. Add
proper support for these subdevices.

Stub in the analog input async command support.

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-03-17 14:20:10 -07:00
H Hartley Sweeten
2925cc8637 staging: comedi: rti802: update the MODULE_DESCRIPTION
Change the generic MODULE_DESCRIPTION text to something more
specific for this driver.

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-03-17 14:20:10 -07:00
H Hartley Sweeten
8f3367af3d staging: comedi: rti802: tidy up the multi-line comments
Tidy up the milti-line comments so they follow the CodingStyle.

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-03-17 14:20:10 -07:00
H Hartley Sweeten
6938dd289d staging: comedi: rti802: tidy up the register map defines
For aesthetics, add some whitespace to the register map defines and
convert the offsets to hex.

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-03-17 14:20:09 -07:00
H Hartley Sweeten
052c198b6e staging: comedi: rti802: tidy up the subdevice init
For aesthetics, add some whitespace to the subdevice init.

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-03-17 14:20:09 -07:00
H Hartley Sweeten
57450d9036 staging: comedi: rti802: tidy up rti802_ao_insn_write()
Use comedi_offset_munge() to handle munging the offset binary to two's
complement.

Tidy up the function a bit.

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-03-17 14:20:09 -07:00
H Hartley Sweeten
c0c6ae260a staging: comedi: rti802: tidy up rti802_ao_insn_read()
To clarify the function a bit, add a local variable for the 'chan'
that is being read and change the final return to 'insn->n'.

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-03-17 14:20:09 -07:00
H Hartley Sweeten
df8f09bb44 staging: comedi: rti802: remove RTI802_SIZE define
This define is only used in the attach to specify the I/O region size
passed to comedi_request_region(). Remove the define and just open
code the value.

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-03-17 14:20:09 -07:00
H Hartley Sweeten
f0571cb440 staging: comedi: gsc_hpdi: tidy up multi-line comment
Tidy up the comment to follow the CodingStyle.

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-03-17 14:19:51 -07:00
H Hartley Sweeten
63810f3b55 staging: comedi: gsc_hpdi: remove pr_fmt() define
This driver no longer has any pr_{level} messages. Remove the pr_fmt().

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-03-17 14:19:51 -07:00
H Hartley Sweeten
47266aaf35 staging: comedi: gsc_hpdi: convert comedi_error() messages to dev_err()
For aesthetics, convert the comedi_error() messages to dev_err().

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-03-17 14:19:51 -07:00
H Hartley Sweeten
d67107fe91 staging: comedi: gsc_hpdi: tidy up the boardinfo
Remove the unnecessary comments in the boardinfo definition and
tidy up the declaration.

FWIW, I'm not sure this boardinfo is really needed...

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-03-17 14:19:51 -07:00
H Hartley Sweeten
fce0ff523a staging: comedi: gsc_hpdi: tidy up the register map
For aesthetics, convert the various enums into simple defines to
describe the register map for the board. Group the bit defines with
the associated register define. Convert the helper functions for
the register bit/shift/mask stuff into simple defines.

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-03-17 14:19:51 -07:00
H Hartley Sweeten
4cbbacb285 staging: comedi: gsc_hpdi: rename 'hpdi_iobase' in private data
This member in the private data holds the ioremaped PCI BAR2 address
which is the primary base address for the boards registers.

For aesthetics, rename this member simply 'mmio'.

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-03-17 14:19:51 -07:00
H Hartley Sweeten
139740370c staging: comedi: gsc_hpdi: rename 'plx9080_iobase' in private data
Rename this member to fix two checkpatch.pl warnings about lines > 80
characters.

Also remove the unnecessary comment.

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-03-17 14:19:51 -07:00
H Hartley Sweeten
d213563198 staging: comedi: gsc_hpdi: tidy up gsc_hpdi_drain_dma()
Refactor this function to clarify the loop that reads all the full
buffers.

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-03-17 14:19:51 -07:00
H Hartley Sweeten
2a5a3d0c8f staging: comedi: gsc_hpdi: remove 'volatile' from the private data members
As reported by checkpatch.pl, the private data members do not need
the volatile tag. Remove them.

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-03-17 14:19:50 -07:00
H Hartley Sweeten
ab5cf49317 staging: comedi: gsc_hpdi: remove hpdi_writel()
This helper function is used to OR bits with a software copy of a
register value then writel() the new value to the register. The
software copies are never updated in the driver so they are always
0 due to the kzalloc.

Remove the unnecessary 'bits' from the private data and replace
the hpdi_writel() calls with writel().

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-03-17 14:19:50 -07:00
H Hartley Sweeten
42ea78126c staging: comedi: gsc_hpdi: remove disable_plx_interrupts()
This helper function is just a simple writel(). Remove 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-03-17 14:19:50 -07:00
H Hartley Sweeten
63da0d087c staging: comedi: gsc_hpdi: rename init_hpdi()
For aesthetics, rename this function so it has namespace associated
with the driver.

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-03-17 14:19:50 -07:00
H Hartley Sweeten
201a81437c staging: comedi: gsc_hpdi: rename init_plx9080()
For aesthetics, rename this function so it has namespace associated
with the driver.

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-03-17 14:19:50 -07:00
H Hartley Sweeten
6a23558b34 staging: comedi: gsc_hpdi: rename hpdi_find_board()
For aesthetics, rename this function so it has namespace associated
with the driver.

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-03-17 14:19:50 -07:00
H Hartley Sweeten
1335cee5d2 staging: comedi: gsc_hpdi: rename the (*auto_attach) and (*detach) functions
For aesthetics, rename these functions so they have namespace associated
with the driver.

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-03-17 14:19:49 -07:00
H Hartley Sweeten
9fe635cd86 staging: comedi: gsc_hpdi: rename drain_dma_buffers()
For aesthetics, rename this function so it has namespace associated
with the driver.

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-03-17 14:19:49 -07:00
H Hartley Sweeten
3521d454d2 staging: comedi: gsc_hpdi: rename handle_interrupt()
For aesthetics, rename this function so it has namespace associated
with the driver.

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-03-17 14:19:49 -07:00
H Hartley Sweeten
9cbf669737 staging: comedi: gsc_hpdi: rename abort_dma()
For aesthetics, rename this function so it has namespace associated
with the driver.

Also, remove the unnecessary forward declaration.

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-03-17 14:19:49 -07:00
H Hartley Sweeten
3547473931 staging: comedi: gsc_hpdi: rename hpdi_cancel()
For aesthetics, rename this function so it has namespace associated
with the driver.

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-03-17 14:19:49 -07:00
H Hartley Sweeten
6b0cca01ac staging: comedi: gsc_hpdi: tidy up hpdi_cmd_test()
For aesthetics, rename this function so it has namespace associated
with the driver and move it so that it is not in the middle of the
interrupt support code.

Absorb the di_cmd_test() helper and tidy up the function a bit.

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-03-17 14:19:49 -07:00