openwrt/staging/blogic.git
11 years agostaging: dgnc: changes arguments in sizeof
Lidza Louina [Fri, 4 Oct 2013 16:18:30 +0000 (12:18 -0400)]
staging: dgnc: changes arguments in sizeof

The arguments that were passed into sizeof were
generic. This patch changes this by putting
the actual item that we need a size of instead.

For example:
-   kzalloc(sizeof(struct dgnc_board), GFP_KERNEL);
+   kzalloc(sizeof(*brd), GFP_KERNEL);

Signed-off-by: Lidza Louina <lidza.louina@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: comedi: ni_6527: change MODULE_DESCRIPTION
H Hartley Sweeten [Tue, 1 Oct 2013 22:15:21 +0000 (15:15 -0700)]
staging: comedi: ni_6527: 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>
11 years agostaging: comedi: ni_6527: tidy up multi-line comments
H Hartley Sweeten [Tue, 1 Oct 2013 22:15:03 +0000 (15:15 -0700)]
staging: comedi: ni_6527: 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>
11 years agostaging: comedi: ni_6527: tidy up the comedi_driver declaration
H Hartley Sweeten [Tue, 1 Oct 2013 22:14:46 +0000 (15:14 -0700)]
staging: comedi: ni_6527: tidy up the comedi_driver declaration

For aesthetics, add some whitespace.

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>
11 years agostaging: comedi: ni_6527: tidy up ni6527_auto_attach()
H Hartley Sweeten [Tue, 1 Oct 2013 22:14:27 +0000 (15:14 -0700)]
staging: comedi: ni_6527: tidy up ni6527_auto_attach()

For aesthetics, allocate the private data memory before attempting
to enable the PCI device.

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>
11 years agostaging: comedi: ni_6527: tidy up the interrupt subdevice
H Hartley Sweeten [Tue, 1 Oct 2013 22:14:07 +0000 (15:14 -0700)]
staging: comedi: ni_6527: tidy up the interrupt subdevice

Do the request_irq() before setting up the subdevices. Only initialize
the interrupt subdevice if the irq is actually available.

Tidy up the whitespace in 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>
11 years agostaging: comedi: ni_6527: introduce ni6527_reset()
H Hartley Sweeten [Tue, 1 Oct 2013 22:13:48 +0000 (15:13 -0700)]
staging: comedi: ni_6527: introduce ni6527_reset()

Factor the board reset code out of the (*attach). Do the reset as
soon as possible to ensure the interrupts are disabled.

For convienence, use the ni6257_reset() during the (*detach) instead
of just disabling the interrupts.

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>
11 years agostaging: comedi: ni_6527: remove COMEDI_MITE dependancy
H Hartley Sweeten [Tue, 1 Oct 2013 22:13:32 +0000 (15:13 -0700)]
staging: comedi: ni_6527: remove COMEDI_MITE dependancy

The COMEDI_MITE driver is a wrapper for the National Instruments
PCI MITE ASIC. This driver includes the PCI boilerplate used to
remap the resources as well as the support code for bus mastered
DMA.

The ni_6527 does not support DMA and the COMEDI_MITE driver adds
unnecessary complexity.

Remove the need for the COMEDI_MITE driver by handling the ioremap
directly in the (*attach). Store the ioremap'ed address in 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>
11 years agostaging: comedi: ni_6527: tidy up ni6527_intr_insn_config()
H Hartley Sweeten [Tue, 1 Oct 2013 22:13:14 +0000 (15:13 -0700)]
staging: comedi: ni_6527: tidy up ni6527_intr_insn_config()

Handle the instruction (data[0]) with a switch to make it easier
to add additional instructions in the future.

To clarify the code, factor out the code that sets the rising/falling
edge detection.

Rename the CamelCase defines used for the rising/falling edge detection
registers.

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>
11 years agostaging: comedi: ni_6527: tidy up ni6527_intr_cancel()
H Hartley Sweeten [Tue, 1 Oct 2013 22:12:55 +0000 (15:12 -0700)]
staging: comedi: ni_6527: tidy up ni6527_intr_cancel()

For aesthetics, use a local variable for the __iomem base address
used to write to the registers.

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>
11 years agostaging: comedi: ni_6527: tidy up ni6527_intr_cmd()
H Hartley Sweeten [Tue, 1 Oct 2013 22:12:35 +0000 (15:12 -0700)]
staging: comedi: ni_6527: tidy up ni6527_intr_cmd()

For aesthetics, use a local variable for the __iomem base address
used to write to the registers.

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>
11 years agostaging: comedi: ni_6527: rename CamelCase defines for the control register
H Hartley Sweeten [Tue, 1 Oct 2013 22:12:19 +0000 (15:12 -0700)]
staging: comedi: ni_6527: rename CamelCase defines for the control register

Rename the CamelCase defines used for the interrupt control register.

To clarify the code a bit, add two new defines to enable/disable the
interrupts.

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>
11 years agostaging: comedi: ni_6527: rename CamelCase defines for the clear register
H Hartley Sweeten [Tue, 1 Oct 2013 22:11:58 +0000 (15:11 -0700)]
staging: comedi: ni_6527: rename CamelCase defines for the clear register

Rename the CamelCase defines used for the clear register.

To clarify the code a bit, add two new defines that group the bits needed
to clear the interrupts and reset the digital input deglitch filter.

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>
11 years agostaging: comedi: ni_6527: tidy up ni6527_interrupt()
H Hartley Sweeten [Tue, 1 Oct 2013 22:11:39 +0000 (15:11 -0700)]
staging: comedi: ni_6527: tidy up ni6527_interrupt()

Rename the CamelCase defines used for the interrupt status register.

The NI6527_STATUS_IRQ bit will be set whenever the device is asserting
an interrupt. Modify the function a bit so this is the only requirement
for the interrupt to be IRQ_HANDLED. Currently an OVERFLOW interrupt is
not handled, though it's unlikely this would occur without an EDGE
interrupt.

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>
11 years agostaging: comedi: ni_6527: use dev->read_subdev in interrupt handler
H Hartley Sweeten [Tue, 1 Oct 2013 22:11:21 +0000 (15:11 -0700)]
staging: comedi: ni_6527: use dev->read_subdev in interrupt handler

The comedi_subdevice in the interrupt handler is the dev->read_subdev
that was initialized during the attach. Use that instead of accessing
the dev->subdevices[] array 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>
11 years agostaging: comedi: ni_6527: tidy up ni6527_{di, do}_insn_bits()
H Hartley Sweeten [Tue, 1 Oct 2013 22:11:00 +0000 (15:11 -0700)]
staging: comedi: ni_6527: tidy up ni6527_{di, do}_insn_bits()

The digital input and output ports are different. Split the CamelCase
Port_Register() define into separate NI6527_DI_REG() and NI6527_DO_REG()
defines to make this clear.

Tidy up the functions 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>
11 years agostaging: comedi: ni_6527: tidy up ni6527_di_insn_config()
H Hartley Sweeten [Tue, 1 Oct 2013 22:10:41 +0000 (15:10 -0700)]
staging: comedi: ni_6527: tidy up ni6527_di_insn_config()

The core will validate the insn->n value based on the actual instruction
(data[0]) that is being handled. Remove the sanity check and change the
instruction handling into a switch. This follows the normal format for
(*insn_config) functions and make adding additional instructions easier.

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>
11 years agostaging: comedi: ni_6527: factor out the code that sets the filter enables
H Hartley Sweeten [Tue, 1 Oct 2013 22:10:22 +0000 (15:10 -0700)]
staging: comedi: ni_6527: factor out the code that sets the filter enables

To clarify the digital input subdevice (*insn_config) a bit, factor out the
code that sets the filter enables to enable deglitching the digital inputs.

Also, rename the CamelCase define used for the filter enable registers.

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>
11 years agostaging: comedi: ni_6527: factor out the code that sets the filter interval
H Hartley Sweeten [Tue, 1 Oct 2013 22:09:42 +0000 (15:09 -0700)]
staging: comedi: ni_6527: factor out the code that sets the filter interval

To clarify the digital input subdevice (*insn_config) a bit, factor out the
code that sets the filter interval for deglitching the digital inputs.

Also, rename the CamelCase define used for the filter interval registers.

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>
11 years agostaging: comedi: ni_6527: remove extra probe noise
H Hartley Sweeten [Tue, 1 Oct 2013 22:09:16 +0000 (15:09 -0700)]
staging: comedi: ni_6527: remove extra probe noise

The dev_info() showing the board id is just extra noise.

Remove it but make sure the probed id is correct. Rename the CamelCase
define used for the id register.

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>
11 years agostaging: comedi: ni_6527: remove unused DEBUG* defines
H Hartley Sweeten [Tue, 1 Oct 2013 22:08:58 +0000 (15:08 -0700)]
staging: comedi: ni_6527: remove unused DEBUG* defines

These defines are not used in the driver. 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>
11 years agostaging: comedi: ni_6527: remove unused NI6527_*_SIZE defines
H Hartley Sweeten [Tue, 1 Oct 2013 22:08:40 +0000 (15:08 -0700)]
staging: comedi: ni_6527: remove unused NI6527_*_SIZE defines

These defines are not used in the driver. 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>
11 years agostaging: comedi: ni_6527: remove DRIVER_NAME define
H Hartley Sweeten [Tue, 1 Oct 2013 22:08:10 +0000 (15:08 -0700)]
staging: comedi: ni_6527: remove DRIVER_NAME define

The request_irq() call should be using dev->board_name to better
identify the irq user.

Remove the DRIVER_NAME define and just open code the 'driver_name' in
the comedi_driver and the 'name' in the pci_driver declarations.

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>
11 years agostaging: comedi: ni_at_ao: fix board names
H Hartley Sweeten [Tue, 1 Oct 2013 00:55:33 +0000 (17:55 -0700)]
staging: comedi: ni_at_ao: fix board names

This driver works with "at-ao-6/10" boards not "ai-ao-6/10" boards.
Fix the names in 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>
11 years agostaging: comedi: ni_at_ao: change MODULE_DESCRIPTION
H Hartley Sweeten [Tue, 1 Oct 2013 00:55:14 +0000 (17:55 -0700)]
staging: comedi: ni_at_ao: 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>
11 years agostaging: comedi: ni_at_ao: tidy up multi-line comments
H Hartley Sweeten [Tue, 1 Oct 2013 00:54:58 +0000 (17:54 -0700)]
staging: comedi: ni_at_ao: tidy up multi-line comments

Cleanup 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>
11 years agostaging: comedi: ni_at_ao: tidy up atao_attach()
H Hartley Sweeten [Tue, 1 Oct 2013 00:54:42 +0000 (17:54 -0700)]
staging: comedi: ni_at_ao: tidy up atao_attach()

For aesthetics, add some whitespace to the subdevice init.

Remove the printk noise at the end of 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>
11 years agostaging: comedi: ni_at_ao: tidy up atao_ao_rinsn()
H Hartley Sweeten [Tue, 1 Oct 2013 00:54:25 +0000 (17:54 -0700)]
staging: comedi: ni_at_ao: tidy up atao_ao_rinsn()

For aesthetics, rename this function to help with greps.

Tidy up this function to follow the normal format for analog
output read back functions.

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>
11 years agostaging: comedi: ni_at_ao: tidy up atao_ao_winsn()
H Hartley Sweeten [Tue, 1 Oct 2013 00:54:08 +0000 (17:54 -0700)]
staging: comedi: ni_at_ao: tidy up atao_ao_winsn()

For aesthetics, rename this function to help with greps.

For channel 0, register group 1 only needs to be selected before
writing the values and restored to group 0 when the writes are
finished. Move the code out of the for () loop.

Use the comedi_ffset_munge() helper to handle the offset binary to
two's complement munging.

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>
11 years agostaging: comedi: ni_at_ao: introduce atao_select_reg_group()
H Hartley Sweeten [Tue, 1 Oct 2013 00:53:50 +0000 (17:53 -0700)]
staging: comedi: ni_at_ao: introduce atao_select_reg_group()

To clarify the code a bit, introduce a helper function to set/clear
the GRP2WR bit in the CFG1 register. This bit selects which group of
registers are used for the registers that share the same I/O addresses.

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>
11 years agostaging: comedi: ni_at_ao: move the atao_reset() function
H Hartley Sweeten [Tue, 1 Oct 2013 00:53:31 +0000 (17:53 -0700)]
staging: comedi: ni_at_ao: move the atao_reset() function

For aesthetics, move this function closer to it's only caller.

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>
11 years agostaging: comedi: ni_at_ao: move the boardinfo declaration
H Hartley Sweeten [Tue, 1 Oct 2013 00:53:11 +0000 (17:53 -0700)]
staging: comedi: ni_at_ao: move the boardinfo declaration

For aesthetics, move the boardinfo declaration closer to the struct
definition. Also, remove the cut-and-paste skel driver 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>
11 years agostaging: comedi: ni_at_ao: rename the rest of the register map
H Hartley Sweeten [Tue, 1 Oct 2013 00:52:53 +0000 (17:52 -0700)]
staging: comedi: ni_at_ao: rename the rest of the register map

For aesthetics, rename the remaining register map defines so they
follow the same format as the ones already renamed.

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>
11 years agostaging: comedi: ni_at_ao: use 8253.h helpers
H Hartley Sweeten [Tue, 1 Oct 2013 00:52:32 +0000 (17:52 -0700)]
staging: comedi: ni_at_ao: use 8253.h helpers

To better document the code, use the 8254.h helpers to set the
timers instead of doing the outb() instructions.

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>
11 years agostaging: comedi: ni_at_ao: tidy up the CFG3 register defines
H Hartley Sweeten [Tue, 1 Oct 2013 00:52:13 +0000 (17:52 -0700)]
staging: comedi: ni_at_ao: tidy up the CFG3 register defines

Rename the defines for the CFG3 register 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>
11 years agostaging: comedi: ni_at_ao: tidy up the calibration subdevice
H Hartley Sweeten [Tue, 1 Oct 2013 00:51:54 +0000 (17:51 -0700)]
staging: comedi: ni_at_ao: tidy up the calibration subdevice

The AT-AO-6/10 boards use DAC8800 TrimDACs to software calibrate the
analog output channels. These are exposed to the user as a calibration
subdevice.

Tidy up, and document, the calibration subdevice.

Since the TrimDACs are not readable, store the calibration values in the
private data for the user to read back as 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>
11 years agostaging: comedi: ni_at_ao: remove 'cfg2' from private data
H Hartley Sweeten [Tue, 1 Oct 2013 00:51:35 +0000 (17:51 -0700)]
staging: comedi: ni_at_ao: remove 'cfg2' from private data

This member of the private data is initialized to '0' during the
board reset then never changed. Just 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>
11 years agostaging: comedi: ni_at_ao: tidy up the STATUS register defines
H Hartley Sweeten [Tue, 1 Oct 2013 00:51:16 +0000 (17:51 -0700)]
staging: comedi: ni_at_ao: tidy up the STATUS register defines

Rename the defines for the STATUS register 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>
11 years agostaging: comedi: ni_at_ao: tidy up CFG1 register defines
H Hartley Sweeten [Tue, 1 Oct 2013 00:50:49 +0000 (17:50 -0700)]
staging: comedi: ni_at_ao: tidy up CFG1 register defines

Rename the defines for the CFG1 register 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>
11 years agostaging: comedi: ni_at_ao: tidy up digital i/o register defines
H Hartley Sweeten [Tue, 1 Oct 2013 00:50:30 +0000 (17:50 -0700)]
staging: comedi: ni_at_ao: tidy up digital i/o register defines

The digital in and digital out registers on this board share the same
address. They also effect the same digital i/o pins. To make this clear
combine the two 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>
11 years agostaging: comedi: ni_at_ao: tidy up the register map defines
H Hartley Sweeten [Tue, 1 Oct 2013 00:50:09 +0000 (17:50 -0700)]
staging: comedi: ni_at_ao: tidy up the register map defines

For aesthetics, sort the register map defines so the normal registers
are listed first and then alternate registers (when the GRP2WR bit is
set).

Convert the register bit defines into bit shifts to make them clear.

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>
11 years agostaging: comedi: ni_at_ao: remove ATAO_SIZE define
H Hartley Sweeten [Tue, 1 Oct 2013 00:49:36 +0000 (17:49 -0700)]
staging: comedi: ni_at_ao: remove ATAO_SIZE define

This define is only used during the board attach to specify the
I/O region length. 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>
11 years agostaging: vt6656: rxtx.c remove dead code s_uFillDataHead/pvTxDataHd.
Malcolm Priestley [Tue, 1 Oct 2013 15:07:25 +0000 (16:07 +0100)]
staging: vt6656: rxtx.c remove dead code s_uFillDataHead/pvTxDataHd.

uFillDataHead in is now dead so remove and pvTxDataHd.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: rxtx.c add no rts struct vnt_tx_datahead_ab
Malcolm Priestley [Tue, 1 Oct 2013 15:03:40 +0000 (16:03 +0100)]
staging: vt6656: rxtx.c add no rts struct vnt_tx_datahead_ab

Add no rts/cts vnt_tx_datahead_ab to union vnt_tx_data_head.

The need_mic now applies to all modes of packet type PK_TYPE_11B.

and return vnt_rxtx_datahead_ab in s_vGenerateTxParameter

This removes pvTxDataHd pointer assignment and calls to s_uFillDataHead.

Since pvTxDataHd is now null a small vendor hack to vDMA0_tx_80211/csMgmt_xmit
to do with Disassociation-packet is also changed correct head position.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: rxtx.c parse out vnt_rxtx_datahead_ab
Malcolm Priestley [Tue, 1 Oct 2013 15:00:20 +0000 (16:00 +0100)]
staging: vt6656: rxtx.c parse out vnt_rxtx_datahead_ab

Parse struct vnt_tx_datahead_ab from s_uFillDataHead and
move to struct vnt_rts_ab structure returning duration down
functions.

Both are returned in s_uFillDataHead at this stage as pvTxDataHd
is only null in s_bPacketToWirelessUsb.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: rxtx.c add no rts struct vnt_tx_datahead_a_fb
Malcolm Priestley [Tue, 1 Oct 2013 14:58:54 +0000 (15:58 +0100)]
staging: vt6656: rxtx.c add no rts struct vnt_tx_datahead_a_fb

Add no rts/cts vnt_tx_datahead_a_fb to union vnt_tx_data_head.

The need_mic now applies to all modes of packet type PK_TYPE_11A.

and return vnt_rxtx_datahead_a_fb in s_vGenerateTxParameter

This removes pvTxDataHd pointer assignment.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: rxtx.c parse out struct vnt_tx_datahead_a_fb
Malcolm Priestley [Tue, 1 Oct 2013 14:56:48 +0000 (15:56 +0100)]
staging: vt6656: rxtx.c parse out struct vnt_tx_datahead_a_fb

Parse struct vnt_tx_datahead_a_fb from s_uFillDataHead and
move to struct vnt_rts_a_fb structure returning duration down
functions.

This removes pvTxDataHd pointer assignment.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: rxtx.c Parse struct vnt_tx_datahead_g_fb
Malcolm Priestley [Tue, 1 Oct 2013 14:54:56 +0000 (15:54 +0100)]
staging: vt6656: rxtx.c Parse struct vnt_tx_datahead_g_fb

Parse struct vnt_tx_datahead_g_fb from s_uFillDataHead and
move to struct vnt_rts_g_fb/struct vnt_cts_fb structure returning
duration down functions.

This removes pvTxDataHd pointer assignment.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: rxtx.c Parse struct vnt_tx_datahead_g
Malcolm Priestley [Tue, 1 Oct 2013 14:52:16 +0000 (15:52 +0100)]
staging: vt6656: rxtx.c Parse struct vnt_tx_datahead_g

Parse struct vnt_tx_datahead_g from s_uFillDataHead and
move to struct vnt_rts_g/struct vnt_cts structure.

This removes pvTxDataHd pointer assignment.

The duration_id(uDuration) field is now returned in s_vGenerateTxParameter.

The return of s_uFillDataHead temporary or'ed to retain functionality of
other functions and is removed at the end of this patch series.

Since pvTxDataHd is now null a small vendor hack to vDMA0_tx_80211/csMgmt_xmit
to do with Disassociation-packet is also changed correct head position.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: rxtx.c change tx functions to return u16
Malcolm Priestley [Tue, 1 Oct 2013 14:50:24 +0000 (15:50 +0100)]
staging: vt6656: rxtx.c change tx functions to return u16

s_vGenerateTxParameter, s_vFillCTSHead, s_vFillRTSHead, vnt_rxtx_rts* functions
to return u16

Initially this is the duration_id field for ieee80211_hdr

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agoStaging: MTD: Micron SPINAND Driver support
Kamlakant Patel [Tue, 1 Oct 2013 09:33:58 +0000 (15:03 +0530)]
Staging: MTD: Micron SPINAND Driver support

This patch adds support for Micron SPINAND via MTD.

Signed-off-by: Mona Anonuevo <manonuevo@micron.com>
Signed-off-by: Kamlakant Patel <kamlakant.patel@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agoStaging: rtl8712: fix spaces before semicolons
Thomas Cort [Tue, 1 Oct 2013 15:26:55 +0000 (11:26 -0400)]
Staging: rtl8712: fix spaces before semicolons

Resolve all of the 'WARNING: space prohibited before semicolon'
checkpatch warnings for rtl8712.

Signed-off-by: Thomas Cort <linuxgeek@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: dwc2: Make dwc2_hw_params.host_channels large enough
Matthijs Kooijman [Thu, 3 Oct 2013 07:46:25 +0000 (09:46 +0200)]
staging: dwc2: Make dwc2_hw_params.host_channels large enough

The hardware offers a 4-bit register containing the number of host
channels. However, the values of these register mean 1-16 host channels,
not 0-15. Since the dwc2_hw_params struct stores the actual number of
host channels supported instead of the raw register value, it should be
5 bits wide instead of 4.

Before this commit, hardware with 16 host channels would overflow the
field, making it appear as 0 channels.

This bug was introduced in commit 9badec2 (staging: dwc2: interpret all
hwcfg and related register at init time).

Reported-by: Dinh Nguyen <dinguyen@altera.com>
Signed-off-by: Matthijs Kooijman <matthijs@stdin.nl>
Acked-by: Paul Zimmerman <paulz@synopsys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: speakup: str initialization replaced with NULL where it was initialized...
Shalin Mehta [Thu, 3 Oct 2013 08:08:42 +0000 (01:08 -0700)]
staging: speakup: str initialization replaced with NULL where it was initialized with int

Fixed warnings in all of three files where the string was initilized with an integer instead of NULL

Signed-off-by: Shalin Mehta <shalinmehta85@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: cvmx-usb.h: make comments to fit into 80 columns
Aaro Koskinen [Tue, 1 Oct 2013 20:43:20 +0000 (23:43 +0300)]
staging: octeon-usb: cvmx-usb.h: make comments to fit into 80 columns

Make comments to fit into 80 columns.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: cvmx-usb.c: make comments to fit into 80 columns
Aaro Koskinen [Tue, 1 Oct 2013 20:43:19 +0000 (23:43 +0300)]
staging: octeon-usb: cvmx-usb.c: make comments to fit into 80 columns

Make comments to fit into 80 columns.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: cvmx-usb: delete unused macros
Aaro Koskinen [Tue, 1 Oct 2013 20:43:18 +0000 (23:43 +0300)]
staging: octeon-usb: cvmx-usb: delete unused macros

Delete unused cvmx_read_csr / cvmx_write_csr macros.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: eliminate CVMX_PREFETCH_PREFX
Aaro Koskinen [Tue, 1 Oct 2013 20:43:17 +0000 (23:43 +0300)]
staging: octeon-usb: eliminate CVMX_PREFETCH_PREFX

Eliminate CVMX_PREFETCH_PREFX.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: eliminate CVMX_PREFETCH_PREF0
Aaro Koskinen [Tue, 1 Oct 2013 20:43:16 +0000 (23:43 +0300)]
staging: octeon-usb: eliminate CVMX_PREFETCH_PREF0

Eliminate CVMX_PREFETCH_PREF0.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: delete CVMX_PREFETCH128
Aaro Koskinen [Tue, 1 Oct 2013 20:43:15 +0000 (23:43 +0300)]
staging: octeon-usb: delete CVMX_PREFETCH128

Delete unused macro.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: inline CVMX_PREFETCH0
Aaro Koskinen [Tue, 1 Oct 2013 20:43:14 +0000 (23:43 +0300)]
staging: octeon-usb: inline CVMX_PREFETCH0

Inline CVMX_PREFETCH0 macro.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: replace CVMX_CLZ with __fls()
Aaro Koskinen [Tue, 1 Oct 2013 20:43:13 +0000 (23:43 +0300)]
staging: octeon-usb: replace CVMX_CLZ with __fls()

Replace CVMX_CLZ macro with __fls().

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: delete redundant flags from cvmx_usb_open_pipe()
Aaro Koskinen [Tue, 1 Oct 2013 20:43:12 +0000 (23:43 +0300)]
staging: octeon-usb: delete redundant flags from cvmx_usb_open_pipe()

Delete redudant flags parameter.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: delete redundant flags from __cvmx_usb_submit_transaction()
Aaro Koskinen [Tue, 1 Oct 2013 20:43:11 +0000 (23:43 +0300)]
staging: octeon-usb: delete redundant flags from __cvmx_usb_submit_transaction()

Delete redundant flags parameter.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: delete cvmx_usb_isochronous_flags
Aaro Koskinen [Tue, 1 Oct 2013 20:43:10 +0000 (23:43 +0300)]
staging: octeon-usb: delete cvmx_usb_isochronous_flags

Delete unused flags.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: octeon-usb: delete redundant flags from cvmx_usb_initialize()
Aaro Koskinen [Tue, 1 Oct 2013 20:43:09 +0000 (23:43 +0300)]
staging: octeon-usb: delete redundant flags from cvmx_usb_initialize()

The function will always figure out the used clock internally, so delete
a redudant parameter and the flag.

Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: silicom: fix space prohibited before semicolon
Tugce Sirin [Wed, 2 Oct 2013 22:39:57 +0000 (01:39 +0300)]
staging: silicom: fix space prohibited before semicolon

Signed-off-by: Tugce Sirin <ztugcesirin@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: nvec: fix space after if statement in nvec.c
Tugce Sirin [Wed, 2 Oct 2013 17:04:31 +0000 (20:04 +0300)]
staging: nvec: fix space after if statement in nvec.c

This patch fixes space after if statement in nvec/nvec.c

Signed-off-by: Tugce Sirin <ztugcesirin@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: lustre: fix bug with LL_MRF_RETURN in loop_make_request
Greg Kroah-Hartman [Tue, 1 Oct 2013 03:46:36 +0000 (20:46 -0700)]
staging: lustre: fix bug with LL_MRF_RETURN in loop_make_request

Turns out that LL_MRF_RETURN is "void" so loop_make_request() would fall
through to the error path for a successful call.  Either this never
matters, or the error path really doesn't do anything.

Fix it up to do what the code is written to look like it is doing, if
that really is what it should be doing is another story...

Cc: Peng Tao <tao.peng@emc.com>
Cc: Zhao Hongjiang <zhaohongjiang@huawei.com>
Cc: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: lustre: remove ll_mrf_ret
Greg Kroah-Hartman [Tue, 1 Oct 2013 03:14:42 +0000 (20:14 -0700)]
staging: lustre: remove ll_mrf_ret

It's just 'void' and only used in one place, so just remove it, it's
useless.

Cc: Peng Tao <tao.peng@emc.com>
Cc: Zhao Hongjiang <zhaohongjiang@huawei.com>
Cc: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: linux.c: Return negative error codes
Sachin Kamat [Fri, 27 Sep 2013 04:06:38 +0000 (09:36 +0530)]
staging: cxt1e1: linux.c: Return negative error codes

Return negative error codes as is followed in the rest of the
kernel.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: hwprobe.c: Return negative error codes
Sachin Kamat [Fri, 27 Sep 2013 04:06:37 +0000 (09:36 +0530)]
staging: cxt1e1: hwprobe.c: Return negative error codes

Return negative error codes as is followed in the rest of the
kernel.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: musycc.c: Return negative error codes
Sachin Kamat [Fri, 27 Sep 2013 04:06:36 +0000 (09:36 +0530)]
staging: cxt1e1: musycc.c: Return negative error codes

Return negative error codes as is followed in the rest of the
kernel.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: pmcc4_drv.c: Use NULL instead of 0
Sachin Kamat [Fri, 27 Sep 2013 04:06:35 +0000 (09:36 +0530)]
staging: cxt1e1: pmcc4_drv.c: Use NULL instead of 0

Pointers should be assigned NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: sbecrc.c: Use NULL instead of 0
Sachin Kamat [Fri, 27 Sep 2013 04:06:34 +0000 (09:36 +0530)]
staging: cxt1e1: sbecrc.c: Use NULL instead of 0

Pointers should be assigned NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: hwprobe.c: Use NULL instead of 0
Sachin Kamat [Fri, 27 Sep 2013 04:06:33 +0000 (09:36 +0530)]
staging: cxt1e1: hwprobe.c: Use NULL instead of 0

Pointers should be assigned NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: sbeproc.c: Use NULL instead of 0
Sachin Kamat [Fri, 27 Sep 2013 04:06:32 +0000 (09:36 +0530)]
staging: cxt1e1: sbeproc.c: Use NULL instead of 0

Pointers should be assigned NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: linux.c: Use NULL instead of 0
Sachin Kamat [Fri, 27 Sep 2013 04:06:31 +0000 (09:36 +0530)]
staging: cxt1e1: linux.c: Use NULL instead of 0

Pointers should be assigned NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: sbeid.c: Use NULL instead of 0
Sachin Kamat [Fri, 27 Sep 2013 04:06:30 +0000 (09:36 +0530)]
staging: cxt1e1: sbeid.c: Use NULL instead of 0

Pointers should be assigned NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: sbecom_inline_linux.h: Return NULL instead of 0
Sachin Kamat [Fri, 27 Sep 2013 04:06:29 +0000 (09:36 +0530)]
staging: cxt1e1: sbecom_inline_linux.h: Return NULL instead of 0

Functions returning pointer should return NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: cxt1e1: musycc.c: Use NULL instead of 0
Sachin Kamat [Fri, 27 Sep 2013 04:06:28 +0000 (09:36 +0530)]
staging: cxt1e1: musycc.c: Use NULL instead of 0

Pointers should be assigned NULL instead of 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: dgnc: Remove KERNEL_VERSION check
Sachin Kamat [Fri, 27 Sep 2013 09:50:26 +0000 (15:20 +0530)]
staging: dgnc: Remove KERNEL_VERSION check

This check is not required.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Lidza Louina <lidza.louina@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: imx-drm: Remove redundant of_match_ptr
Sachin Kamat [Sat, 28 Sep 2013 10:22:30 +0000 (15:52 +0530)]
staging: imx-drm: Remove redundant of_match_ptr

'imx_ldb_dt_ids' is always compiled in. Hence of_match_ptr() is
not needed.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agoStaging: sm7xxfb: fixed line break coding style issues
Martin Berglund [Fri, 27 Sep 2013 16:32:26 +0000 (18:32 +0200)]
Staging: sm7xxfb: fixed line break coding style issues

Fixed coding style issues.

Signed-off-by: Martin Berglund <martin@rogsta.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging/olpc: fix dependencies to fix build errors
Randy Dunlap [Sat, 28 Sep 2013 00:12:59 +0000 (17:12 -0700)]
staging/olpc: fix dependencies to fix build errors

Fix build errors when GPIO_CS5535=m and FB_OLPC_DCON=y
by preventing that kconfig combination.

These build errors are caused by having a kconfig bool symbol
(FB_OLPC_DCON_1) that depend on a tristate symbol (GPIO_CS5535),
but when the tristate symbol is =m, the bool symbol is =y.

drivers/built-in.o: In function `dcon_read_status_xo_1':
olpc_dcon_xo_1.c:(.text+0x359531): undefined reference to `cs5535_gpio_set'
drivers/built-in.o: In function `dcon_wiggle_xo_1':
olpc_dcon_xo_1.c:(.text+0x35959f): undefined reference to `cs5535_gpio_set'
olpc_dcon_xo_1.c:(.text+0x359610): undefined reference to `cs5535_gpio_clear'
drivers/built-in.o:olpc_dcon_xo_1.c:(.text+0x3596a1): more undefined references to `cs5535_gpio_clear' follow
drivers/built-in.o: In function `dcon_wiggle_xo_1':
olpc_dcon_xo_1.c:(.text+0x359708): undefined reference to `cs5535_gpio_set'
drivers/built-in.o: In function `dcon_init_xo_1':
olpc_dcon_xo_1.c:(.text+0x35989b): undefined reference to `cs5535_gpio_clear'
olpc_dcon_xo_1.c:(.text+0x3598b5): undefined reference to `cs5535_gpio_isset'
olpc_dcon_xo_1.c:(.text+0x359963): undefined reference to `cs5535_gpio_setup_event'
olpc_dcon_xo_1.c:(.text+0x359980): undefined reference to `cs5535_gpio_set_irq'
olpc_dcon_xo_1.c:(.text+0x359a36): undefined reference to `cs5535_gpio_set'

Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Daniel Drake <dsd@laptop.org>
Cc: Jens Frederich <jfrederich@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: rtl8712: remove unneeded NULL check
Dan Carpenter [Sat, 28 Sep 2013 09:58:33 +0000 (12:58 +0300)]
staging: rtl8712: remove unneeded NULL check

We knew "peventbuf" was a valid pointer and "peventbuf + 2" is also
non-NULL.  I have removed the check.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agoStaging: rtl8187se: fixed coding style issues
Adam Rall [Mon, 30 Sep 2013 00:11:14 +0000 (20:11 -0400)]
Staging: rtl8187se: fixed coding style issues

Fixed checkpatch.pl errors in r8180_dm.c.

Signed-off-by: Adam Rall <adam.rall4@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6655: don't leak when returning -EOPNOTSUPP in vt6655_hostap_ioctl
Jesper Juhl [Mon, 30 Sep 2013 20:22:11 +0000 (22:22 +0200)]
staging: vt6655: don't leak when returning -EOPNOTSUPP in vt6655_hostap_ioctl

Make sure we always free(param); and remove a redundant "goto out;"
just before we'll hit the label anyway.

Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agoStaging: vt6655: 80211mgr: Cleanup of brace coding style issues
Martin Berglund [Sat, 28 Sep 2013 19:03:24 +0000 (21:03 +0200)]
Staging: vt6655: 80211mgr: Cleanup of brace coding style issues

Cleanup of a few brace coding style issues.

Signed-off-by: Martin Berglund <martin@rogsta.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: covert RXvMngWorkItem to work queue
Malcolm Priestley [Fri, 27 Sep 2013 15:55:45 +0000 (16:55 +0100)]
staging: vt6656: covert RXvMngWorkItem to work queue

Tasklet to workqueue.
RxMngWorkItem -> rx_mng_work_item

Reduce atomic area of driver and dependency on system timer.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: convert RXvWorkItem to work queue
Malcolm Priestley [Fri, 27 Sep 2013 15:53:55 +0000 (16:53 +0100)]
staging: vt6656: convert RXvWorkItem to work queue

Tasklet to workqueue.
ReadWorkItem -> read_work_item

Reduce atomic area of driver.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: covert BSSvSecondCallBack to delayed_work.
Malcolm Priestley [Fri, 27 Sep 2013 15:51:13 +0000 (16:51 +0100)]
staging: vt6656: covert BSSvSecondCallBack to delayed_work.

timer to delay workqueue.
sTimerSecondCallback -> second_callback_work

The delayed work queue is declared in device.h

This timer is very heavy on the system.

Improves over performance of driver and reduce the atomic
area of driver.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: vt6656: device.h convert sTimerCommand to delayed_work
Malcolm Priestley [Fri, 27 Sep 2013 15:48:14 +0000 (16:48 +0100)]
staging: vt6656: device.h convert sTimerCommand to delayed_work

timer to delay workqueue.
sTimerCommand -> run_command_work

sTimerCommand is very heavy on the system timer.

Improves over performance of driver and reduce the atomic
area of driver.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: lustre: Don't leak 'buffer' in cfs_get_environ()
Jesper Juhl [Mon, 30 Sep 2013 20:44:37 +0000 (22:44 +0200)]
staging: lustre: Don't leak 'buffer' in cfs_get_environ()

If 'down_read_trylock' fails we'll curently leak the memory allocated to 'buffer'.
Fix the leak by simply kfree'ing 'buffer' before returning '-EDEADLK'.

Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agostaging: comedi: ni_at_ao: fix namespace clash of 'RSI' define
H Hartley Sweeten [Mon, 30 Sep 2013 16:26:38 +0000 (09:26 -0700)]
staging: comedi: ni_at_ao: fix namespace clash of 'RSI' define

As pointed out by Fengguang Wu, the RSI define in this driver clashes
with the one in arch/x86/include/uapi/asm/ptrace-abi.h.

This define isn't currently used by the driver so just rename it to fix
the clash.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Reported-by: Fengguang Wu <fengguang.wu@intel.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agoMerge 3.12-rc3 into staging-next
Greg Kroah-Hartman [Mon, 30 Sep 2013 01:42:21 +0000 (18:42 -0700)]
Merge 3.12-rc3 into staging-next

We want the staging fixes in here as well.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
11 years agoLinux 3.12-rc3
Linus Torvalds [Sun, 29 Sep 2013 22:02:38 +0000 (15:02 -0700)]
Linux 3.12-rc3

11 years agoMerge tag 'usb-3.12-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb
Linus Torvalds [Sun, 29 Sep 2013 20:47:35 +0000 (13:47 -0700)]
Merge tag 'usb-3.12-rc3' of git://git./linux/kernel/git/gregkh/usb

Pull USB fixes from Greg KH:
 "Here are a number of USB driver fixes for 3.12-rc3.

  These are all for host controller issues that have been reported, and
  there's a fix for an annoying error message that gets printed every
  time you remove a USB 3 device from the system that's been bugging me
  for a while"

* tag 'usb-3.12-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
  usb: dwc3: add support for Merrifield
  USB: fsl/ehci: fix failure of checking PHY_CLK_VALID during reinitialization
  USB: Fix breakage in ffs_fs_mount()
  fsl/usb: Resolve PHY_CLK_VLD instability issue for ULPI phy
  usb/core/devio.c: Don't reject control message to endpoint with wrong direction bit
  usb: chipidea: USB_CHIPIDEA should depend on HAS_DMA
  usb: chipidea: udc: free pending TD at removal procedure
  usb: chipidea: imx: Add usb_phy_shutdown at probe's error path
  usb: chipidea: Fix memleak for ci->hw_bank.regmap when removal
  usb: chipidea: udc: fix the oops after rmmod gadget
  USB: fix PM config symbol in uhci-hcd, ehci-hcd, and xhci-hcd
  USB: OHCI: accept very late isochronous URBs
  USB: UHCI: accept very late isochronous URBs
  USB: iMX21: accept very late isochronous URBs
  usbcore: check usb device's state before sending a Set SEL control transfer
  xhci: Fix race between ep halt and URB cancellation
  usb: Fix xHCI host issues on remote wakeup.
  xhci: Ensure a command structure points to the correct trb on the command ring
  xhci: Fix oops happening after address device timeout

11 years agoMerge tag 'tty-3.12-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty
Linus Torvalds [Sun, 29 Sep 2013 20:47:00 +0000 (13:47 -0700)]
Merge tag 'tty-3.12-rc3' of git://git./linux/kernel/git/gregkh/tty

Pull tty/serial fixes from Greg KH:
 "Here are some serial at tty driver fixes for 3.12-rc3

  The serial driver fixes some kref leaks, documentation is moved to the
  proper places, and the tty and n_tty fixes resolve some reported
  regressions.  There is still one outstanding tty regression fix that
  isn't in here yet, as I want to test it out some more, it will be sent
  for 3.12-rc4 if it checks out"

* tag 'tty-3.12-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
  tty: ar933x_uart: move devicetree binding documentation
  tty: Fix SIGTTOU not sent with tcflush()
  n_tty: Fix EOF push index when termios changes
  serial: pch_uart: remove unnecessary tty_port_tty_get
  serial: pch_uart: fix tty-kref leak in dma-rx path
  serial: pch_uart: fix tty-kref leak in rx-error path
  serial: tegra: fix tty-kref leak

11 years agoMerge tag 'staging-3.12-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh...
Linus Torvalds [Sun, 29 Sep 2013 20:46:18 +0000 (13:46 -0700)]
Merge tag 'staging-3.12-rc3' of git://git./linux/kernel/git/gregkh/staging

Pull staging fixes from Greg KH:
 "Here are some staging driver fixes, MAINTAINER updates, and a new
  device id.  All of these have been in the linux-next tree, and are
  pretty simple patches"

* tag 'staging-3.12-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
  staging: r8188eu: Add new device ID
  staging: imx-drm: Fix probe failure
  staging: vt6656: [BUG] iwctl_siwencodeext return if device not open
  staging: vt6656: [BUG] main_usb.c oops on device_close move flag earlier.
  staging: vt6656: rxtx.c [BUG] s_vGetFreeContext dead lock on null apTD.
  Staging: rtl8192u: r819xU_cmdpkt: checking NULL value after doing dev_alloc_skb
  staging: usbip: Orphan usbip
  staging: r8188eu: Add files for new drive: Cocci spatch "noderef"
  staging: r8188eu: Cocci spatch "noderef"
  staging: octeon-usb: Cocci spatch "noderef"
  staging: r8188eu: Add files for new drive: Cocci spatch "noderef"
  MAINTAINERS: staging: dgnc and dgap drivers: add maintainer
  staging: lustre: Cocci spatch "noderef"