H Hartley Sweeten [Tue, 30 Jul 2013 00:46:27 +0000 (17:46 -0700)]
staging: comedi: usbdux: tidy up usbdux_alloc_usb_buffers()
Tidy up the error path by doing all the basic allocations then checking
for failures.
We have the comedi device now so fill in the urb->context.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:46:07 +0000 (17:46 -0700)]
staging: comedi: usbduxsigma: return void from usbduxsigma_pwm_pattern()
This function never fails and currently returns '1' so that the
usbduxsigma_pwm_write() function returns to proper value (insn->n).
It's also called by usbduxsigma_pwm_config() which also returns the
'1' value. The proper return code for this function should be '0' to
indicate success.
Change the return type of the function to void and just have the
callers return the proper values.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:45:47 +0000 (17:45 -0700)]
staging: comedi: usbdux: return void from usbdux_pwm_pattern()
This function never fails and currently returns '1' so that the
usbdux_pwm_write() function returns to proper value (insn->n).
It's also called by usbdux_pwm_config() which also returns the '1'
value. The proper return code for this function should be '0' to
indicate success.
Change the return type of the function to void and just have the
callers return the proper values.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:45:28 +0000 (17:45 -0700)]
staging: comedi: usbdux: tidy up usbdux_pwm_config()
Rename the local variable used for the private data pointer to 'devpriv'.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:45:09 +0000 (17:45 -0700)]
staging: comedi: usbdux: remove usbdux_pwm_read()
The pwm subdevice is not readable so this callback function is not
needed. 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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:44:50 +0000 (17:44 -0700)]
staging: comedi: usbdux: tidy up usbdux_pwm_write()
Remove the sanity check of the private data. This function can only be
called if the private data was successfully allocated in the attach.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:44:32 +0000 (17:44 -0700)]
staging: comedi: usbdux: tidy up usbdux_pwm_pattern()
Rename the local variable used for the private data pointer to 'devpriv'.
Remove the sanity check of the private data. This function can only be
called if the private data was successfully allocated in the attach.
Tidy up the function to make it more concise.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:44:14 +0000 (17:44 -0700)]
staging: comedi: usbdux: tidy up usbdux_pwm_period()
Rename the local variable used for the private data pointer to 'devpriv'.
Fix the fx2delay calculation so it does not use floating point values.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:43:55 +0000 (17:43 -0700)]
staging: comedi: usbduxsigma: remove the usb endpoint defines
The endpoint defines are each only used in one place and don't help
clarify the code. Remove the defines and just open code the values.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:43:36 +0000 (17:43 -0700)]
staging: comedi: usbduxsigma: generalize the ai/ao usb_kill_urb()
Generalize a helper function to replace for() loops in usbduxsigma_{ai,ao}_stop()
that call usb_kill_urb() to unlink all the urbs.
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>
H Hartley Sweeten [Tue, 30 Jul 2013 00:43:16 +0000 (17:43 -0700)]
staging: comedi: usbdux: generalize the usb_submit_urb functions
Generalize a helper function to replace usbduxsub_submit_{in,out}urbs().
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>
Malcolm Priestley [Tue, 30 Jul 2013 20:08:54 +0000 (21:08 +0100)]
staging: vt6656: device.h unused variables
wACKDuration
wRTSTransmitLen
byRTSServiceField
byRTSSignalField
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Tue, 30 Jul 2013 20:03:13 +0000 (21:03 +0100)]
staging: vt6656: dead code wCTSDuration.
Always set to zero, so remove.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Eli Billauer [Wed, 31 Jul 2013 08:22:43 +0000 (11:22 +0300)]
staging: xillybus: Fixed sparse errors
Changes:
* xillybus.h: __iomem added to struct xilly_endpoint -> registers to suppress
"different address spaces" errors.
* xillybus_core.c: __user added as required for the same reason.
* The two member names of struct xilly_endpoint_hardware of the form
sync_single_for_{cpu,device} were changed to something that won't look
like the well-known functions.
* All *.c files: Variables and functions made static as required.
Reported-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Eli Billauer <eli.billauer@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Eli Billauer [Wed, 31 Jul 2013 08:22:42 +0000 (11:22 +0300)]
staging: xillybus: Removed dependency on OF_DEVICE in Kconfig
This variable was removed from the kernel a while ago.
Signed-off-by: Eli Billauer <eli.billauer@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
H Hartley Sweeten [Mon, 29 Jul 2013 21:08:31 +0000 (14:08 -0700)]
staging: comedi: das16: tidy up multi-line comments
Tidy up the multi-line comments 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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:08:13 +0000 (14:08 -0700)]
staging: comedi: das16: remove some unnecessary parentheses
These parentheses are not necessary.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:07:53 +0000 (14:07 -0700)]
staging: comedi: das16: tidy up user ai/ao range initialization
The allocation of the user range tables could fail. Make sure to check
for it.
Change the kmalloc()'s to kzalloc()'s to make sure the allocated range
tables are initialized to a known state.
Change the local variables so they can be used for both the ai and ao
range initialization and use shorter names to keep the lines < 80 chars.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:07:30 +0000 (14:07 -0700)]
staging: comedi: das16: remove an unnecessary check in the attach
If the user does not specify the analog output range the private data
'user_ao_range_table' will not be allocated. The comedi core will detect
the NULL s->range_table and automatically set it to &range_unknown.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:07:10 +0000 (14:07 -0700)]
staging: comedi: das16: fix das16_detach()
The function das16_reset() needs a valid dev->iobase. Since the iobase
is requested after the devpriv has been allocated in the attach, move
the das16_reset() call into the if (devpriv) and add a if (dev->iobase).
Also, move the release of the extra iobase into the if (devpriv) to
prevent an invalid memory access.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:06:52 +0000 (14:06 -0700)]
staging: comedi: das16: change MODULE_DESCRIPTION
Change the MODULE_DESCRIPTION to something useful instead of the
generic "Comedi low-level 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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:06:34 +0000 (14:06 -0700)]
staging: comedi: das16: tidy up private data definition
Remove the comments and add some whitespace to help readability.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:06:16 +0000 (14:06 -0700)]
staging: comedi: das16: cleanup comedi_error() messages
Some of these messages are missing the terminating '\n' and most of them
have the quoted string split across lines.
Change all of them to dev_err() messages and fix the issues.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:05:59 +0000 (14:05 -0700)]
staging: comedi: das16: fix a > 80 char line issue
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:05:37 +0000 (14:05 -0700)]
staging: comedi: das16: absorb das1600_mode_detect() into caller
This function is only called during the board attach to determine the
pacer clock speed for the boards capable of bursting.
Absorb it into the caller and remove the attach noise.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:05:20 +0000 (14:05 -0700)]
staging: comedi: das16: cleanup printk message in board attach
Convert this printk message into a 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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:05:00 +0000 (14:05 -0700)]
staging: comedi: das16: fail attach if board id is incorrect
This driver probes the board id during the attach to ensure that the
user is attempting to attach to the correct board type. Currently an
error message is output if the ids are not consistent but the attach
continues anyway.
Make the attach fail if the id bits do not match. Also, cleanup the
printk messages and use a dev_err() only if the probe fails.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:04:41 +0000 (14:04 -0700)]
staging: comedi: das16: tidy up the register map defines
Add the suffix _REG to all the register defines to better indicate
what they are.
Add a prefix to all the register bit defines to avoid namespace clashes
and to better indicate what they are.
Tidy up the whitesapce.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:04:13 +0000 (14:04 -0700)]
staging: comedi: das16: tidy up 8255 digital i/o subdevice
The 8255 digital i/o subdevice is only available on some of the boards
supported by this driver. Currently the 'i8255_offset' member of the
boardinfo is used to indicate that it is available.
To clarify this support, add a 'has_8255' bit-field flag to the boardinfo.
We can then use this flag to conditionally allocate the space for the
subdevice only when it is needed.
Also, make sure to check that subdev_8255_init() is successful and propagate
any errors.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:03:46 +0000 (14:03 -0700)]
staging: comedi: das16: remove 'i8254_offset' from boardinfo
All the boards supported by this driver have an 8254 timer at offset
0x0c. Remove this unused information from the boardinfo.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:03:28 +0000 (14:03 -0700)]
staging: comedi: das16: move boardinfo declaration
Now that the boardinfo does not require any forward declarations,
move it near the definition of the struct.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:03:11 +0000 (14:03 -0700)]
staging: comedi: das16: remove unnecessary test in das16_interrupt()
The timer is only started by the ai subdevice in das16_cmd_exec()
and this function can only be called if the device is attached.
Remove the unnecessary sanity check.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:02:48 +0000 (14:02 -0700)]
staging: comedi: das16: move some functions to improve readability
For aesthetics, move some of the functions to make the code easier
to follow.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 21:02:22 +0000 (14:02 -0700)]
staging: comedi: das16: tidy up das16_ai_insn_read()
Factor out the loop that waits for the ai conversion to complete.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:58:36 +0000 (13:58 -0700)]
staging: comedi: das16: introduce das16_ai_{en, dis}able() helpers
Introduce a couple helper functions to enable and disable the
analog input interrupt/dma conversions.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:58:17 +0000 (13:58 -0700)]
staging: comedi: das16: remove the register map comments
This is just extra cruft. 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:57:58 +0000 (13:57 -0700)]
staging: comedi: das16: remove unused static const variable
This variable is not used in the driver. 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:57:38 +0000 (13:57 -0700)]
staging: comedi: das16: remove unused DAS16_SIZE
This define is not used in the driver. 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:57:18 +0000 (13:57 -0700)]
staging: comedi: das16: add a 'can_burst' flag to the private data
If the boardinfo 'size' is > 0x400 it indicates that the board has
additional registers that allow bursting of analog input data.
To better indicate this add a flag 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:56:59 +0000 (13:56 -0700)]
staging: comedi: das16: remove 'volatile' on private data variables
As indicated by checkpatch.pl, "WARNING: Use of volatile is usually
wrong: ...". The variables in the private data that are marked
volatile don't need to be. Remove the volatile.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:56:38 +0000 (13:56 -0700)]
staging: comedi: das16: remove DEBUG_PRINT macro
This macro outputs some printk() debug info that is just added noise.
Remove it as well as the DEBUG stuff.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:56:21 +0000 (13:56 -0700)]
staging: comedi: das16: remove reg_dump()
This function just prints some development debug information. There is
no reason to leave this in the final 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:56:02 +0000 (13:56 -0700)]
staging: comedi: das16: remove 'ai_unipolar' and 'ai_singleended'
These members in the private data are only used during the board attach.
Move the reading of the status register to the board attach and just
check the value where needed when initializing the analog input subdevice.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:55:38 +0000 (13:55 -0700)]
staging: comedi: das16: remove unused struct definition
This struct is not used by the driver. 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:55:20 +0000 (13:55 -0700)]
staging: comedi: das16: tidy up the comedi_lrange tables
Cleanup the whitespace in the tables.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:55:00 +0000 (13:55 -0700)]
staging: comedi: das16: cleanup analog output subdevice
All the boards supported by this driver that have analog outputs use
the same function to handle the (*insn_write) for the subdevice. They
all also have 12-bit resolution (maxdata = 0x0fff).
Remove the 'ao' and 'ao_nbits' members from the boardinfo and replace
them with a simple bit-field flag 'has_ao'.
Tidy up the subdevice init a bit as well as the (*insn_write) 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:54:39 +0000 (13:54 -0700)]
staging: comedi: das16: all supported board have digital outputs
All the boards supported by this driver have digital outputs and all
of then use the same function to handle the (*insn_bits) for the
subdevice.
Remove the 'do_' member from the boardinfo and always initialize the
digital output subdevice during the board attach.
Tidy up the subdevice init a bit as well as the (*insn_bits) function.
Remove SDF_READABLE from the subdev_flags. This is a pure digital output
subdevice and the outputs are not readable.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:54:09 +0000 (13:54 -0700)]
staging: comedi: das16: all supported board have digital inputs
All the boards supported by this driver have digital inputs and all
of then use the same function to handle the (*insn_bits) for the
subdevice.
Remove the 'di' member from the boardinfo and always initialize the
digital input subdevice during the board attach.
Tidy up the subdevice init a bit as well as the (*insn_bits) function.
The (*insn_bits) function does not need to clear data[0].
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:49:21 +0000 (13:49 -0700)]
staging: comedi: das16: change boardinfo 'ai_nbits' to 'ai_maxdata'
The subdevice functions that used this boardinfo can use the subdevice
's->maxdata' value instead. Tidy up those functions.
Change the boardinfo so that the calculation is not needed during the
attach.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:49:01 +0000 (13:49 -0700)]
staging: comedi: das16: all supported board have analog inputs
All the boards supported by this driver have analog inputs and all
of then use the same function to handle the (*insn_read) for the
subdevice.
Remove the 'ai' member from the boardinfo and always initalize the
analog input subdevice during the board attach.
Tidy up the subdevice init 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:48:38 +0000 (13:48 -0700)]
staging: comedi: das16: fix DMA init during board attach
DMA support is optional in this driver. To enable it, the user
passes the desired DMA channel during the board attach. A timer
is then used by the driver to periodically get the analog input
data from the DMA.
Since the DMA support is optional, modify the init code so that
it only fails if the DMA channel is unavailable or the DMA buffers
can not be allocated. Don't fail just because the user passed an
invalid DMA channel (only DMA channels 1 and 3 are valid).
Remove the printk() noise about the DMA. Change the printk() when
the request_dma() fails into a dev_err().
Move the timer initialization so it's only setup if DMA is available.
It's not needed otherwise. Also, only hook up the subdevice command
support functions if DMA is available. This allows removing a couple
sanity checks in the 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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:48:19 +0000 (13:48 -0700)]
staging: comedi: das16: remove DMA irq support
As noted in the driver, a timer is always used by this driver to handle
the DMA because samples could be dropped while waiting for the DMA done
interrupt.
Remove the irq setup code as well as the interrupt handler.
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>
H Hartley Sweeten [Mon, 29 Jul 2013 20:48:01 +0000 (13:48 -0700)]
staging: comedi: das16: "timer_mode" is always used for DMA
As noted in the driver, a timer is always used by this driver to handle the
DMA due to buggy DMA controllers and the lack of a hardware fifo in some of
the supported boards.
Remove all the non-timer mode specific code.
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>
Jens Frederich [Tue, 30 Jul 2013 18:11:34 +0000 (20:11 +0200)]
staging: olpc_dcon: provide detailed FB_OLPC_DCON help section
The FB_OLPC_DCON help section is to short according to checkpatch.pl.
We want more information about the controller type, its task, its video
pipeline position and so on.
There are no style issues, remove checkpatch.pl TODO entry.
Signed-off-by: Jens Frederich <jfrederich@gmail.com>
Acked-by: Andres Salomon <dilinger@queued.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Li Zefan [Wed, 31 Jul 2013 06:30:13 +0000 (14:30 +0800)]
Staging: rtl8192u/ieee80211: add missing single_release()
The debug file is opened with single_open(), but there's no
single_release().
Signed-off-by: Li Zefan <lizefan@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Li Zefan [Wed, 31 Jul 2013 06:29:27 +0000 (14:29 +0800)]
Staging: rtl8192e: add missing single_release()
The debug file is opened with single_open(), but there's no
single_release().
Signed-off-by: Li Zefan <lizefan@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Greg Kroah-Hartman [Mon, 29 Jul 2013 19:27:40 +0000 (12:27 -0700)]
staging: gdm724x: depend on CONFIG_TTY
The driver uses the tty layer, so explicitly say that, to prevent
randomconfig build errors.
Reported-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:08:00 +0000 (20:08 +0300)]
staging: octeon-usb: cvmx-usb: reformat documentation
Reformat the high-level documentation to human readable plain text by
removing HTML and other tags.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:59 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: delete CVS keyword markers
Delete CVS keyword markers.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:58 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: convert @return
Convert "@return" to "Returns: ".
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:57 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: convert @param
Convert "@param name" inside comments to "@name:".
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:56 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: delete duplicated documentation from .h file
Delete duplicated function call documentation from the .h file. These
functions are just internal anyway, and the .h file will be completely
removed in the future when the driver will be made a single self-contained
.c file.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:55 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: delete @INTERNAL
Delete "@INTERNAL" from comments.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:54 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: reformat long comments
Reformat long comments according to multi-line comment style.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:53 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: fix whitespace issues
Fix most of the whitespace issues reported by checkpatch:
- use tabs for indentation
- brace placement vs. newlines
- (foo_t*) -> (foo_t *)
- i=0 -> i = 0
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:52 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: delete __cvmx_usb_complete_to_string()
Delete a redundant function.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:51 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: replace cvmx_le16_to_cpu with le16_to_cpu
Replace cvmx_le16_to_cpu() with le16_to_cpu().
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:50 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: replace cvmx_wait_usec with udelay
Just use udelay().
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:49 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: replace long udelays with mdelays
Replace long udelays with mdelays.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:48 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: eliminate cvmx_likely/unlikely
Just use likely/unlikely.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:47 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: utilize Linux error codes
Use generic Linux error codes to replace cvmx_usb_status_t.
The conversion table:
Before After
cvmx_usb_status_t int
CVMX_USB_SUCCESS 0
CVMX_USB_INVALID_PARAM -EINVAL
CVMX_USB_NO_MEMORY -ENOMEM
CVMX_USB_BUSY -EBUSY
CVMX_USB_TIMEOUT -ETIMEDOUT
CVMX_USB_INCORRECT_MODE Deleted (was never used)
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:46 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: delete __cplusplus
Delete __cplusplus.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:45 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: delete redundant example code
Delete redundant example code found in comments. It's already there in
the driver proper.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:44 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: delete redundant debug flags
Delete redudant debug flags and dead code behind them.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:43 +0000 (20:07 +0300)]
staging: octeon-usb: cvmx-usb: delete driver-specific tracing code
Delete call, parameter, and return value tracing.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:42 +0000 (20:07 +0300)]
staging: octeon-usb: use correct board type for EdgeRouter Lite
Use CVMX_BOARD_TYPE_UBNT_E100 for EdgeRouter Lite.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Aaro Koskinen [Mon, 29 Jul 2013 17:07:41 +0000 (20:07 +0300)]
staging: octeon-usb: depend on CAVIUM_OCTEON_SOC
The USB driver should depend on SOC instead of CPU.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Lilis Iskandar [Sat, 27 Jul 2013 19:34:47 +0000 (03:34 +0800)]
Staging: bcm: LeakyBucket: Fixed a pointer asterisk placement issue
Fixed a pointer asterisk placement issue
Signed-off-by: Lilis Iskandar <veeableful@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Lilis Iskandar [Sat, 27 Jul 2013 19:34:46 +0000 (03:34 +0800)]
Staging: bcm: LeakyBucket: Fixed code indent issues
Fixed code indent issues
Signed-off-by: Lilis Iskandar <veeableful@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Lilis Iskandar [Sat, 27 Jul 2013 19:34:45 +0000 (03:34 +0800)]
Staging: bcm: LeakyBucket: Fixed C99 comments
Fixed C99 comments
Signed-off-by: Lilis Iskandar <veeableful@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Lilis Iskandar [Sat, 27 Jul 2013 19:34:44 +0000 (03:34 +0800)]
Staging: bcm: LeakyBucket: Fixed brace issues
Fixed brace issues
Signed-off-by: Lilis Iskandar <veeableful@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Lilis Iskandar [Sat, 27 Jul 2013 19:34:43 +0000 (03:34 +0800)]
Staging: bcm: LeakyBucket: Fixed spacing/tabing issues
This one fixes spacing/tabbing issues.
Signed-off-by: Lilis Iskandar <veeableful@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Marc Dietrich [Sat, 27 Jul 2013 16:20:58 +0000 (18:20 +0200)]
staging: nvec: re-enable the clock on resume
On resume the slave controller is reinitialized. The tegra i2c master
controller disables the clock at the end of the initialiation, propably
to save some power, and enables it again on each transfer. We don't
do this yet and also forgot to enable the clock on resume. Fix this
copy-paste error by not disabling the clock after initialization.
This didn't striked us yet because suspend/resume hasn't landed in mainline
yet, but will soon.
Signed-off-by: Marc Dietrich <marvin24@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Won Kang [Sat, 27 Jul 2013 06:42:18 +0000 (15:42 +0900)]
staging: gdm724x: Modified function name conflict set_endian
Conflict resolution for function name set_endian when building for powerpc
The name changed to gdm_set_endian
Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Won Kang <wonkang@gctsemi.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Wei Yongjun [Mon, 29 Jul 2013 04:28:51 +0000 (12:28 +0800)]
staging: comedi: dt9812: remove duplicated include from dt9812.c
Remove duplicated include.
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Wei Yongjun [Mon, 29 Jul 2013 04:33:24 +0000 (12:33 +0800)]
staging: gdm724x: remove duplicated include from gdm_lte.c
Remove duplicated include.
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Wei Yongjun [Mon, 29 Jul 2013 04:59:30 +0000 (12:59 +0800)]
staging: xillybus: remove duplicated include from xillybus_core.c
Remove duplicated include.
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Emil Goode [Sat, 27 Jul 2013 22:38:56 +0000 (00:38 +0200)]
staging: lustre: Fix sparse warnings about use of obsolete initializer
This patch fixes a lot of sparse warnings about use of obsolete
struct and array initializer.
Signed-off-by: Emil Goode <emilgoode@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Emil Goode [Sat, 27 Jul 2013 22:38:55 +0000 (00:38 +0200)]
staging: lustre: Fix non-ANSI sparse warnings
This patch fixes a lot of non-ANSI sparse warnings by adding void to
parameterless functions.
Signed-off-by: Emil Goode <emilgoode@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Greg Kroah-Hartman [Mon, 29 Jul 2013 14:40:10 +0000 (07:40 -0700)]
Merge 3.11-rc3 into staging-next
We want these fixes here.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Linus Torvalds [Mon, 29 Jul 2013 03:53:33 +0000 (20:53 -0700)]
Linux 3.11-rc3
Linus Torvalds [Mon, 29 Jul 2013 01:19:27 +0000 (18:19 -0700)]
Merge tag 'pinctrl-for-v3.11-2' of git://git./linux/kernel/git/linusw/linux-pinctrl
Pull pin control fixes from Linus Walleij:
- Driver fixes for AM33xx, SIRF and PFC pin controllers
- Fix a compile warning from the pinctrl single-register driver
- Fix a little nasty memory leak
* tag 'pinctrl-for-v3.11-2' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl:
pinctrl: fix a memleak when freeing maps
pinctrl: pinctrl-single: fix compile warning when no CONFIG_PM
pinctrl: sh-pfc: fix SDHI0 VccQ regulator on sh73a0 with DT
arm/dts: sirf: fix the pingroup name mismatch between drivers and dts
pinctrl: sirf: add usp0_uart_nostreamctrl pin group for usp-uart without flowctrl
pinctrl: sirf: fix the pin number and mux bit for usp0
pinctrl: am33xx dt binding: correct include path
Linus Torvalds [Mon, 29 Jul 2013 01:10:39 +0000 (18:10 -0700)]
Merge tag 'trace-fixes-3.11-rc2' of git://git./linux/kernel/git/rostedt/linux-trace
Pull tracing fixes from Steven Rostedt:
"Oleg is working on fixing a very tight race between opening a event
file and deleting that event at the same time (both must be done as
root).
I also found a bug while testing Oleg's patches which has to do with a
race with kprobes using the function tracer.
There's also a deadlock fix that was introduced with the previous
fixes"
* tag 'trace-fixes-3.11-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace:
tracing: Remove locking trace_types_lock from tracing_reset_all_online_cpus()
ftrace: Add check for NULL regs if ops has SAVE_REGS set
tracing: Kill trace_cpu struct/members
tracing: Change tracing_fops/snapshot_fops to rely on tracing_get_cpu()
tracing: Change tracing_entries_fops to rely on tracing_get_cpu()
tracing: Change tracing_stats_fops to rely on tracing_get_cpu()
tracing: Change tracing_buffers_fops to rely on tracing_get_cpu()
tracing: Change tracing_pipe_fops() to rely on tracing_get_cpu()
tracing: Introduce trace_create_cpu_file() and tracing_get_cpu()
Linus Torvalds [Mon, 29 Jul 2013 01:09:34 +0000 (18:09 -0700)]
Merge tag 'scsi-fixes' of git://git./linux/kernel/git/jejb/scsi
Pull SCSI fixes from James Bottomley:
"This is five bug fixes, two of which fix long standing problems
causing crashes (sd and mvsas). The remaining three are hung (isci
race) or lost (qla2xxx, isci) devices"
* tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
[SCSI] isci: fix breakage caused by >16byte CDB patch
[SCSI] mvsas: Fix kernel panic on tile due to unaligned data access
[SCSI] sd: fix crash when UA received on DIF enabled device
[SCSI] qla2xxx: Properly set the tagging for commands.
[SCSI] isci: Fix a race condition in the SSP task management path
Yijing Wang [Thu, 27 Jun 2013 12:57:23 +0000 (20:57 +0800)]
vt6655/trivial: replace numeric with standard PM state macros
Use standard PM state macros PCI_Dx instead of numeric 0/1/2..
Signed-off-by: Yijing Wang <wangyijing@huawei.com>
Cc: Forest Bond <forest@alittletooquiet.net>
Cc: Jiri Kosina <trivial@kernel.org>
Cc: Devendra Naga <devendra.aaru@gmail.com>
Cc: Joe Perches <joe@perches.com>
Cc: Marcos Paulo de Souza <marcos.souza.org@gmail.com>
Cc: Bill Pemberton <wfp5p@virginia.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Sunghan Suh [Wed, 3 Jul 2013 11:10:05 +0000 (20:10 +0900)]
zram: prevent data loss in error cases of function zram_bvec_write()
In function zram_bvec_write(), previous data at the index is
already freed by function zram_free_page().
When failed to compress or zs_malloc, there is no way to restore old data.
Therefore, free previous data when it's about to update.
Also, no need to check whether table is not empty outside of
function zram_free_page(), because the function properly checks inside.
Signed-off-by: Sunghan Suh <sunghan.suh@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Greg Kroah-Hartman [Fri, 26 Jul 2013 22:37:54 +0000 (15:37 -0700)]
staging: asus_oled: delete driver
No one has the hardware for it anymore, and there has not been any
development on it in a long time.
If someone shows up with the hardware, and wants to clean it up, this
can be easily reverted.
Reported-by: Lidza Louina <lidza.louina@gmail.com>
Cc: Jakub Schmidtke <sjakub@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
H Hartley Sweeten [Thu, 25 Jul 2013 23:12:30 +0000 (16:12 -0700)]
staging: comedi: usbdux: consolidate usbduxsub_unlink_{in, out}urbs()
These functions are identical other than the which and how many urbs
are unlinked.
Consolidate the functions into one usbdux_unlink_urbs() 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>
H Hartley Sweeten [Thu, 25 Jul 2013 23:12:05 +0000 (16:12 -0700)]
staging: comedi: usbdux: move and rename the bulk transfer commands
For aesthetic reasons, move the defines used for the bulk transfer
commands out of the middle of the code and rename them so they are
a bit more readable.
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>
H Hartley Sweeten [Thu, 25 Jul 2013 23:11:46 +0000 (16:11 -0700)]
staging: comedi: usbdux: remove unused define
This define is not used, and it's actually incorrect. The usbdux device
only has 4 analog output channels.
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>