- 17 Mar, 2014 40 commits
-
-
H Hartley Sweeten authored
Factor the code that allocates and initializes the subdevice private data out of the (*attach) to reduce the indent level and make the code easier to follow. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
H Hartley Sweeten authored
Use the helper function to allocate the subdevice private data. This sets the s->private variable for us and allows the comedi core to automatically kfree() the memory during the (*detach). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
H Hartley Sweeten authored
For aesthetics, use a pointer to the comedi_subdevice instead of accessing the dev->subdevices array directly. Move the local variable for the subdevice private data so that this function does not declare the variable twice. Change the kzalloc for the subdevice private data to remove the sizeof(struct foo). Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
H Hartley Sweeten authored
The COMEDI_CMD and COMEDI_CMDTEST ioctl functions both copy the chanlist passed by the user from __user memory space to kernel memory space. They then do some sanity checking of the chanlist with comedi_check_chanlist() before the subdevice (*do_cmdtest) and (*do_cmd) operations are called. Introduce a helper function to handle the memdup_user() and the sanity checking. Also, remove the unnecessary dev_dbg() when the memdup_user() or comedi_check_chanlist() fail. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
H Hartley Sweeten authored
The COMEDI_CMD and COMEDI_CMDTEST ioctl functions both copy the comedi_cmd passed by the user from __user memory space to kernel memory space. They then do some basic sanity checking of the cmd before the subdevice (*do_cmdtest) and (*do_cmd) operations are called. Introduce a helper function to handle the copy_from_user() and do the basic sanity checking. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Joshua Baldock authored
This is a patch to the CmHost.c file that fixes up parentheses and quoted string across lines warnings found by checkpatch.pl tool. Signed-off-by: Joshua Baldock <joshua.baldock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Davide Berardi authored
Fixed some line over 80 characters. Signed-off-by: Davide Berardi <berardi.dav@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Greg Kroah-Hartman authored
This resolves a merge issue with drivers/staging/cxt1e1/linux.c that was fixed in a report from Stephen Rothwell Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Aybuke Ozdemir authored
This patch fixes these error messages found by checkpatch.pl: ERROR: "foo* bar" should be "foo *bar" Signed-off-by: Aybuke Ozdemir <aybuke.147@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Aybuke Ozdemir authored
This patch fixes "do not use // C99 comments" errors in Typedefs.h Signed-off-by: Aybuke Ozdemir <aybuke.147@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Aybuke Ozdemir authored
Fix checkpatch.pl issue with line over 80 characters in power.c Signed-off-by: Aybuke Ozdemir <aybuke.147@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Aybuke Ozdemir authored
Fix checkpatch.pl issue with line over 80 characters in nokia_fw-bcm.c Signed-off-by: Aybuke Ozdemir <aybuke.147@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Gulsah Kose authored
Fix checkpatch.pl issues with trailing statement to next line in wb35reg.c Signed-off-by: Gulsah Kose <gulsah.1004@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Gulsah Kose authored
Fix checkpatch.pl issues with space prohibited between function name and open parenthesis in libsbew.h Signed-off-by: Gulsah Kose <gulsah.1004@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Gulsah Kose authored
This patch fixes "quoted string split across lines warning" warning in dgnc_cls.c Signed-off-by: Gulsah Kose <gulsah.1004@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Gulsah Kose authored
Fix checkpatch.pl issue with line over 80 characters in midi.c Signed-off-by: Gulsah Kose <gulsah.1004@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Himangi Saraogi authored
As suggested by Pablo, this patch uses a coccinelle script to remove the typedefs: typedef u8 BOOLEAN; <-- use "bool" instead. typedef u8 BYTE; <-- use "u8" typedef u8 *PBYTE; <-- use "u8 *" typedef u16 WORD; <-- use "u16" typedef u16 *PWORD; <-- use "u16 *" typedef u32 DWORD; <-- use "u32" typedef u32 *PDWORD; <-- use "u32 *" in common.h. The coccinelle script is: /* coccinelle script to remove typedefs. */ @remove_typedef@ @@ -typedef bool BOOLEAN; -typedef u8 BYTE; -typedef u8 *PBYTE; -typedef u16 WORD; -typedef u16 *PWORD; -typedef u32 DWORD; -typedef u32 *PDWORD; @fix_usage@ typedef BOOLEAN; @@ -BOOLEAN +bool @fix_usage1@ typedef BYTE; @@ -BYTE +u8 @fix_usage2@ typedef PBYTE; @@ -PBYTE +u8 * @fix_usage3@ typedef WORD; @@ -WORD +u16 @fix_usage4@ typedef PWORD; @@ -PWORD +u16 * @fix_usage5@ typedef DWORD; identifier f; @@ -DWORD +u32 @fix_usage6@ typedef PDWORD; @@ -PDWORD +u32 * Signed-off-by: Himangi Saraogi <himangi774@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Fix checkpatch.pl errors: ERROR: do not initialise statics to 0 or NULL Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Fix pointer declarations as the codingStyle of the kernel recommends in ieee80211/ieee80211_softmac.c Fix checkpatch.pl errors: ERROR: "foo* bar" should be "foo *bar" ERROR: "(foo*)" should be "(foo *)" Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Move trailing statements to next line as the codingStyle of the kernel recommends. Fix checkpatch.pl errors: ERROR: trailing statements should be on next line Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Delete some whitespaces (whitespace before a quoted newline, space at the start of a line and space before a tabs) as the codingStyle of the kernel recommends. Fix checkpatch.pl errors: WARNING: unnecessary whitespace before a quoted newline WARNING: please, no spaces at the start of a line WARNING: please, no space before tabs Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Add whitespaces around '&', '||' and '&&' as the codingStyle of the kernel recommends. Fix checkpatch.pl errors: ERROR: spaces required around that '||' (ctx:VxV) ERROR: spaces required around that '&&' (ctx:VxV) ERROR: need consistent spacing around '&' Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Add whitespaces around '+=' and '==' and fix coding style in these lines as the codingStyle of the kernel recommends. Fix checkpatch.pl errors: ERROR: spaces required around that '+=' (ctx:VxV ERROR: spaces required around that '==' (ctx:VxW) Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Fix checkpatch.pl error: ERROR: code indent should use tabs where possible Also fix some problems with tabs in an if-statement. Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Add whitespaces around commas and fix coding style in these lines as the codingStyle of the kernel recommends. Fix checkpatch.pl errors: ERROR: space required after that ',' Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Add whitespaces around '+', '-' and '=' as the codingStyle of the kernel recommends. Fix checkpatch.pl errors: ERROR: need consistent spacing around '+' ERROR: spaces required around that '=' (ctx:VxV) ERROR: need consistent spacing around '-' Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Delete spaces prohibited before semicolon, before ':' and after '!' and fix coding style in these lines when It is necessary. Fix checkpàtch.pl error and warning messages: WARNING: space prohibited before semicolon ERROR: space prohibited before that ':' ERROR: space prohibited after that '!' Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Delete space prohibited after open parenthesis and fix coding style in the lines changed when It is necessary Fix checkpatch.pl errors: ERROR: space prohibited after that open parenthesis '(' Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Delete space prohibited between function name and open parenthesis and fix coding style in the lines changed when It is necessary Fix checkpatch.pl warning message: WARNING: space prohibited between function name and open parenthesis '('. Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Add a space required before the open parenthesis in while and for structures as the codingStyle of the kernel recommends. Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Add a space required before the open parenthesis in conditional statements as the codingStyle of the kernel recommends. Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Delete braces are not necessary for single statement blocks and fix coding style in these lines when It is necessary. Fix checkpatch.pl warning: WARNING: braces {} are not necessary for single statement blocks Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Fix whitespaces in do-while statements and while statements as the codingStyle of the kernel recommends in ieee80211/ieee80211_softmac.c Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Fix whitespaces around else-statements and fix coding style in the lines when It is necessary as the codingStyle of the kernel recommends in ieee80211/ieee80211_softmac.c Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Fix whitespaces around braces in if-statement as the codingStyle of the kernel recommends in ieee80211/ieee80211_softmac.c Also, fix coding style in these lines when It is necessary. Fix checkpatch.pl errors: ERROR: space required before the open brace '{' Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
staging: rtl8187se: Remove unused functions 'rsn_authen_cipher_suite' and 'ext_ieee80211_send_beacon_wq' Remove unused functions rsn_authen_cipher_suite() and ext_ieee80211_send_beacon_wq() from ieee80211_softmac.c. Fix sparse warnings: drivers/staging/rtl8187se/ieee80211/ieee80211_softmac.c:27:11: warning: ‘rsn_authen_cipher_suite’ defined but not used [-Wunused-variable] drivers/staging/rtl8187se/ieee80211/ieee80211_softmac.c:327:13: warning: ‘ext_ieee80211_send_beacon_wq’ defined but not used [-Wunused-function] Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Move comments from inside if conditionals to the lines above the if-statement. Also delete unnecessary whitespace in these lines. Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Convert style of comments from C99-style to C89 and fix alignment in these lines as the CodingStyle recommends. Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Remove unnecessary blank lines in ieee80211/ieee80211_softmac.c (and add some necessary blank lines). Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-
Ana Rey authored
Delete all commented code in ieee80211/ieee80211_softmac.c that are not necessary. Also, remove the unused variable referenced in the commented code. Signed-off-by: Ana Rey <anarey@gmail.com> Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
-