summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2015-05-14staging: slicoss: fix occasionally writing out only half of a dma addressDavid Matlack2-5/+1
curaddrupper caches the last written upper 32-bits of a dma address (the device has one register for the upper 32-bits of all dma address registers). The problem is, not every dma address write checks and sets curaddrupper. This causes the driver to occasionally not write the upper 32-bits of a dma address to the device when it really should. I've seen this manifest particularly when the driver is trying to read config data from the device (RCONFIG) in order to checksum the device's eeprom. Since the device writes its config data to the wrong DMA address the driver reads 0 as the eeprom size and the eeprom checksum fails. This patch fixes the issue by removing curaddrupper and always writing the upper 32-bits of dma addresses. Signed-off-by: David Matlack <dmatlack@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-14staging: slicoss: remove slic_spinlock wrapperDavid Matlack3-80/+65
As per TODO. This commit introduces no functional changes. Signed-off-by: David Matlack <dmatlack@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-13staging: comedi: ni_mio_common: fix build warningH Hartley Sweeten1-2/+1
The kbuild test robot detected a build warning causes by commit f878071a. >> drivers/staging/comedi/drivers/ni_mio_common.c:2274:34: warning: right-hand operand of comma expression has no effect [-Wunused-value] That line should have been terminated by ';' and the following line removed. Not sure why it even builds on my test system... Reported-by: kbuild test robot 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>
2015-05-10android, lmk: avoid setting TIF_MEMDIE if process has already exitedDavid Rientjes1-5/+12
TIF_MEMDIE should not be set on a process if it does not have a valid ->mm, and this is protected by task_lock(). If TIF_MEMDIE gets set after the mm has detached, and the process fails to exit, then the oom killer will defer forever waiting for it to exit. Make sure that the mm is still valid before setting TIF_MEMDIE by way of mark_tsk_oom_victim(). Cc: "Arve Hjønnevåg" <arve@android.com> Cc: Riley Andrews <riandrews@android.com> Acked-by: Michal Hocko <mhocko@suse.cz> Signed-off-by: David Rientjes <rientjes@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: dgap: remove unused codeSudip Mukherjee1-17/+4
dgap_sindex() is being only called from dgap_getword() which searches for either ' ' or '\t' or '\n'. this part of the code with '^' at the beginning is never used. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: dgap: use remove functionSudip Mukherjee1-25/+24
the remove callback will be called in two cases, 1) if the driver is removed and 2) if the pci device is removed. as of now all the board cleanups were being done in the module unload section so if the module is unloaded everything works. But if the pci device is removed then the loaded driver will be left in an inconsistent state. So moved the cleanups in the remove callback and since there was no reference of dgap_driver in remove_one(), so had to define the pci_driver in the function. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: dgap: move function before removeSudip Mukherjee1-31/+30
move the cleanup function before the remove call as the next patch of the series is going to use that. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: lustre: cl_page: delete empty macrosJulia Lawall1-17/+0
CS_PAGE_INC etc. do nothing, so remove them. The semantic patch that performs this transformation is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression o,item,state; @@ ( - CS_PAGE_INC(o, item); | - CS_PAGE_DEC(o, item); | - CS_PAGESTATE_INC(o, state); | - CS_PAGESTATE_DEC(o, state); ) // </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: lustre: cl_page: drop unneeded variableJulia Lawall1-1/+0
Drop variable made unnecessary by conversion of obd free functions to kfree. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: lustre: llite: remove unuse variablesSudip Mukherjee2-4/+0
there variables were not used anywhere and was showing as build warning. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging/lustre: Always try kmalloc first for OBD_ALLOC_LARGEOleg Drokin4-21/+67
Create libcfs_kvzalloc and libcfs_kvzalloc_cpt that are designed to replace OBD_ALLOC_LARGE and OBD_CPT_ALLOC_LARGE. Not a drop-in replacement as they also take gfp flags armument for more flexibility. Signed-off-by: Oleg Drokin <green@linuxhacker.ru> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: rtl8192e: Change cpu_to_le16 to le16_to_cpuArno Tiemersma1-1/+1
Since the function auth_parse returns a u16, and struct rtllib_authentication.status is defined as an __le16, it seems that return cpu_to_le16(a->status); should be return le16_to_cpu(a->status); This change silences the following sparse warnings: drivers/staging/rtl8192e/rtllib_softmac.c:1817:16: warning: cast from restricted __le16 drivers/staging/rtl8192e/rtllib_softmac.c:1817:16: warning: incorrect type in return expression (different base types) drivers/staging/rtl8192e/rtllib_softmac.c:1817:16: expected unsigned short drivers/staging/rtl8192e/rtllib_softmac.c:1817:16: got restricted __le16 [usertype] <noident> Signed-off-by: Arno Tiemersma <arno.tiemersma@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: rtl8192e: use time_before() macroGujulan Elango, Hari Prasath (H.)1-1/+2
This patch replaces the condition check for time elapsed with a simplified time_before() macro Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: rtl8192e: Use time_after macroGujulan Elango, Hari Prasath (H.)1-2/+4
This patch replaces a condition check for time elapsed with a simple time_after macro Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: rtl8192e: fix wrong assignmentGujulan Elango, Hari Prasath (H.)1-1/+1
This patch addresses a spatch warning on assigning a negative value to a unsigned integer.Similar patch has been submitted by Larry Finger earlier to silence the same spatch warning in another file. Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com> Acked-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: comedi: coding style identation error fixJaime Arrocha1-2/+2
Errors found by checkpatch.pl. ERROR: code indent should use tabs where possible /drivers/staging/comedi/drivers/das16m1.c:49 /drivers/staging/comedi/drivers/das16m1.c:50 Signed-off-by: Jaime Arrocha <jarr@kerneldev.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: comedi: daqboard2000: Use preferred comment styleArno Tiemersma1-98/+98
Use the preferred block comment style for the copyright and driver description header comments. Signed-off-by: Arno Tiemersma <arno.tiemersma@gmail.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: comedi: gsc_hpdi: use a better MODULE_DESCRIPTION()Ian Abbott1-1/+1
Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: comedi: gsc_hpdi: use PCI_DEVICE_SUB()Ian Abbott1-2/+2
Use the `PCI_DEVICE_SUB()` macro in the initializer of the PCI module device table `gsc_hpdi_pci_table[]`. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: comedi: gsc_hpdi: prefer using the BIT() macroIan Abbott1-41/+41
Fix all the checkpatch issues "CHECK: Prefer using the BIT macro". Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: comedi: gsc_hpdi: usleep_range is preferred over udelayIan Abbott1-1/+1
Fix checkpatch issue: "CHECK: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.txt". `udelay()` is only called once from a place where sleeping is allowed. Replace it with a call to `usleep_range()` with a reasonable upper limit. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: comedi: gsc_hpdi: remove multiple board type supportIan Abbott1-34/+1
The code for determining which board type matches the PCI device ID is over-the-top since only a single board type is supported. Also, the method it uses match the PCI device ID to a board type is a little antiquated. Most comedi drivers for PCI devices use `driver_data` from the probed PCI device as an index into an array of supported board types, but "gsc_hpdi" uses a `for` loop to find an element of `hpdi_boards[]` that matches the PCI device. The only thing in `hpdi_boards[]` not used for finding a matching PCI device is the `name` member of `struct hpdi_board` which points to a string literal and ends up getting assigned to `dev->board_name`. Get rid of the multiple board type support, and set `dev->board_name` to point to the original string literal pointed to by `hpdi_boards[0].name`. This string is visible to userspace. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: comedi: gsc_hpdi: tidy up commentsIan Abbott1-25/+34
Use the usual style for block comments. Squash double spaces after comment opening sequence. Move some comments after opening braces to following line. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-10staging: remove i2o subsystemGreg Kroah-Hartman22-11435/+0
This subsystem isn't used anymore, and the hardware isn't around. It's been in staging for a while, and it's time for it to now be removed. Cc: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-09staging: comedi: ni_stc.h: final cleanupH Hartley Sweeten1-34/+47
1) Move the enum's to a better location and tidy up the whitespace. 2) Tidy up the defines used for some array sizes in the private data. 3) Add comments for the spinlock_t variables in the private data. 4) Move the forward declaration to the end of the file. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up the windowed_regs_67xx_61xxH Hartley Sweeten2-57/+47
Rename the CamelCase. For aesthetics, convert the enum into defines. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up the cs5529_command_bitsH Hartley Sweeten2-17/+20
For aesthetics, convert the enum into defines. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up the cs5529_configuration_bitsH Hartley Sweeten2-36/+30
For aesthetics, convert the enum into defines and the inline functions into macros. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: rename the NI-6143 register definesH Hartley Sweeten3-63/+66
Rename the CamelCase. 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>
2015-05-09staging: comedi: ni_stc.h: rename the NI-611x register definesH Hartley Sweeten2-27/+30
Rename the CamelCase. 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>
2015-05-09staging: comedi: ni_stc.h: remove unused _bit* definesH Hartley Sweeten1-17/+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>
2015-05-09staging: comedi: ni_mio_common: move ni_stc_dma_channel_select_bitfield()H Hartley Sweeten2-12/+11
Move this inline helper function from ni_stc.h. It does not need to be exposed outside of this file. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up G0_G1_Select register and bitsH Hartley Sweeten2-24/+15
Rename the CamelCase. Convert the inline helper functions into macros. Tidy up the driver code to use the new macros. For consistency, make the ni_set_gpct_dma_channel() helper follow the same style as the ni_set_ai_dma_channel() and ni_set_ao_dma_channel() helpers. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up AI_AO_Select register and bitsH Hartley Sweeten2-23/+18
Rename the CamelCase and convert the enum into macros. Tidy up the driver code to use the new macros. 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>
2015-05-09staging: comedi: ni_mio_common: remove BUG_ON(gpct_index ...) checksH Hartley Sweeten2-4/+0
The gpct_index will always be 0 or 1. Remove the unnecessary BUG_ON() checks. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up DAC[01]_Direct_Data registersH Hartley Sweeten2-3/+3
Rename the CamelCase and convert the defines into a macro. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up DAC_FIFO_Data registerH Hartley Sweeten2-2/+2
Rename the CamelCase. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up AO_Configuration register and bitsH Hartley Sweeten2-15/+15
Rename the CamelCase. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up Configuration_Memory_High register and bitsH Hartley Sweeten2-16/+12
Rename the CamelCase. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up Configuration_Memory_Low register and bitsH Hartley Sweeten2-10/+11
Rename the CamelCase. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up ADC_FIFO_Data_RegisterH Hartley Sweeten2-4/+4
Rename the CamelCase. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up 8255 register definesH Hartley Sweeten2-9/+4
Only the 'Port_A' define is used. Rename the CamelCase and remove the unused 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>
2015-05-09staging: comedi: ni_stc.h: tidy up Misc_Command register and bitsH Hartley Sweeten2-2/+6
Rename the CamelCase. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up Serial_Command register and bitsH Hartley Sweeten2-16/+26
Rename the CamelCase. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up XXX_Status register and bitsH Hartley Sweeten2-10/+7
Rename the CamelCase. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up Window_{Address,Data} definesH Hartley Sweeten2-9/+9
Rename the CamelCase. 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>
2015-05-09staging: comedi: ni_stc.h: remove unused GPCT register bit definesH Hartley Sweeten1-68/+0
The bit defines in this header for the GPCT registers are not used. The ones in ni_tio_internal.h are used instead. Remove them from this header. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up AI_*_Save_RegistersH Hartley Sweeten2-4/+4
Rename the CamelCase. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up Joint_Status_2_Register and bitsH Hartley Sweeten2-9/+7
Rename the CamelCase. Use the BIT() macro to define the bits. 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>
2015-05-09staging: comedi: ni_stc.h: tidy up DIO_Serial_Input_RegisterH Hartley Sweeten2-3/+4
Rename the CamelCase. 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>